pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/multimedia/mpv



Module Name:    pkgsrc
Committed By:   nia
Date:           Sun Aug 18 17:57:56 UTC 2019

Modified Files:
        pkgsrc/multimedia/mpv: Makefile distinfo options.mk
Added Files:
        pkgsrc/multimedia/mpv/patches: patch-video_out_wayland__common.c

Log Message:
mpv: Add Wayland support to options.mk.

This makes X11 optional. It shouldn't change the default options.


To generate a diff of this commit:
cvs rdiff -u -r1.85 -r1.86 pkgsrc/multimedia/mpv/Makefile
cvs rdiff -u -r1.53 -r1.54 pkgsrc/multimedia/mpv/distinfo
cvs rdiff -u -r1.17 -r1.18 pkgsrc/multimedia/mpv/options.mk
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/multimedia/mpv/patches/patch-video_out_wayland__common.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/multimedia/mpv/Makefile
diff -u pkgsrc/multimedia/mpv/Makefile:1.85 pkgsrc/multimedia/mpv/Makefile:1.86
--- pkgsrc/multimedia/mpv/Makefile:1.85 Sun Aug 11 13:22:04 2019
+++ pkgsrc/multimedia/mpv/Makefile      Sun Aug 18 17:57:55 2019
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.85 2019/08/11 13:22:04 wiz Exp $
+# $NetBSD: Makefile,v 1.86 2019/08/18 17:57:55 nia Exp $
 
 DISTNAME=      mpv-0.29.1
 PKGREVISION=   10
@@ -52,18 +52,7 @@ post-install:
 
 .include "options.mk"
 
-.include "../../mk/bsd.prefs.mk"
-.if ${OPSYS} != "Darwin"
-.include "../../graphics/MesaLib/buildlink3.mk"
-.include "../../x11/libdrm/buildlink3.mk"
-.include "../../x11/libXinerama/buildlink3.mk"
-.include "../../x11/libXrandr/buildlink3.mk"
-.include "../../x11/libXScrnSaver/buildlink3.mk"
-.include "../../x11/libXv/buildlink3.mk"
-.include "../../x11/libXxf86vm/buildlink3.mk"
 .include "../../mk/oss.buildlink3.mk"
-.endif
-
 .include "../../converters/libiconv/buildlink3.mk"
 .include "../../devel/waf/waf.mk"
 .include "../../devel/zlib/buildlink3.mk"

Index: pkgsrc/multimedia/mpv/distinfo
diff -u pkgsrc/multimedia/mpv/distinfo:1.53 pkgsrc/multimedia/mpv/distinfo:1.54
--- pkgsrc/multimedia/mpv/distinfo:1.53 Tue Jun  4 13:55:43 2019
+++ pkgsrc/multimedia/mpv/distinfo      Sun Aug 18 17:57:55 2019
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.53 2019/06/04 13:55:43 nia Exp $
+$NetBSD: distinfo,v 1.54 2019/08/18 17:57:55 nia Exp $
 
 SHA1 (mpv-0.29.1.tar.gz) = 83f2bc0eb5a8bec9a9d5efc7de0e19a442238ac5
 RMD160 (mpv-0.29.1.tar.gz) = 72a4fda3a72ac4fd37ed04435833fa2cf378a012
@@ -9,4 +9,5 @@ SHA1 (patch-audio_out_ao__oss.c) = 824c2
 SHA1 (patch-options_options.c) = 125282ede99098224fc9c16952b44c12b8b3e06b
 SHA1 (patch-player_main.c) = e794199990059cc95050032194bca70557c381d7
 SHA1 (patch-video_out_drm__common.c) = facb8d99fe31119618866c9af512a60e54b4ea6c
+SHA1 (patch-video_out_wayland__common.c) = 816ee9c59404a50af922b8e4f97fbcd02b20ba45
 SHA1 (patch-wscript) = a908365c0c63745e1d22010c26804789997d4377

Index: pkgsrc/multimedia/mpv/options.mk
diff -u pkgsrc/multimedia/mpv/options.mk:1.17 pkgsrc/multimedia/mpv/options.mk:1.18
--- pkgsrc/multimedia/mpv/options.mk:1.17       Fri May 31 15:55:11 2019
+++ pkgsrc/multimedia/mpv/options.mk    Sun Aug 18 17:57:55 2019
@@ -1,22 +1,29 @@
-# $NetBSD: options.mk,v 1.17 2019/05/31 15:55:11 nia Exp $
+# $NetBSD: options.mk,v 1.18 2019/08/18 17:57:55 nia Exp $
 
 PKG_OPTIONS_VAR=       PKG_OPTIONS.mpv
 
 .include "../../multimedia/libva/available.mk"
 .include "../../multimedia/libvdpau/available.mk"
 
-PKG_SUPPORTED_OPTIONS= alsa ass bluray caca lua pulseaudio rpi sdl2 v4l2
-PKG_SUGGESTED_OPTIONS= ass bluray lua sdl2
-PKG_SUGGESTED_OPTIONS.Linux+=  alsa
+PKG_OPTIONS_OPTIONAL_GROUPS=   gl
+PKG_OPTIONS_GROUP.gl=          opengl rpi
+
+PKG_SUPPORTED_OPTIONS+=                alsa ass bluray caca libdrm lua pulseaudio v4l2
+PKG_SUPPORTED_OPTIONS+=                sdl2 wayland x11
 
+.include "../../mk/bsd.fast.prefs.mk"
+PKG_SUGGESTED_OPTIONS=         ass bluray lua sdl2
+PKG_SUGGESTED_OPTIONS.Linux+=  alsa
+.if ${OPSYS} != "Darwin"
+PKG_SUGGESTED_OPTIONS+=                opengl libdrm x11
+.endif
 .if ${VAAPI_AVAILABLE} == "yes"
-PKG_SUPPORTED_OPTIONS+=        vaapi
-PKG_SUGGESTED_OPTIONS+=        vaapi
+PKG_SUPPORTED_OPTIONS+=                vaapi
+PKG_SUGGESTED_OPTIONS+=                vaapi
 .endif
-
 .if ${VDPAU_AVAILABLE} == "yes"
-PKG_SUPPORTED_OPTIONS+=        vdpau
-PKG_SUGGESTED_OPTIONS+=        vdpau
+PKG_SUPPORTED_OPTIONS+=                vdpau
+PKG_SUGGESTED_OPTIONS+=                vdpau
 .endif
 
 .include "../../mk/bsd.options.mk"
@@ -122,9 +129,21 @@ WAF_CONFIGURE_ARGS+=       --disable-vdpau
 .endif
 
 ###
-### Raspberry Pi support
+### libdrm support (video output)
+###
+.if !empty(PKG_OPTIONS:Mlibdrm)
+WAF_CONFIGURE_ARGS+=   --enable-drm
+.include "../../x11/libdrm/buildlink3.mk"
+.else
+WAF_CONFIGURE_ARGS+=   --disable-libdrm
+.endif
+
+###
+### OpenGL support (video output)
 ###
-.if !empty(PKG_OPTIONS:Mrpi)
+.if !empty(PKG_OPTIONS:Mopengl)
+.include "../../graphics/MesaLib/buildlink3.mk"
+.elif !empty(PKG_OPTIONS:Mrpi)
 BUILD_DEPENDS+=                raspberrypi-userland>=20170109:../../misc/raspberrypi-userland
 CFLAGS+=               "-L${PREFIX}/lib"
 SUBST_CLASSES+=                vc
@@ -133,3 +152,29 @@ SUBST_MESSAGE.vc=  Fixing path to VideoCo
 SUBST_FILES.vc=                waftools/checks/custom.py
 SUBST_SED.vc+=         -e 's;opt/vc;${PREFIX};g'
 .endif
+
+###
+### Wayland support (video output)
+###
+.if !empty(PKG_OPTIONS:Mwayland)
+WAF_CONFIGURE_ARGS+=   --enable-wayland
+.include "../../devel/wayland/buildlink3.mk"
+.include "../../devel/wayland-protocols/buildlink3.mk"
+.include "../../x11/libxkbcommon/buildlink3.mk"
+.else
+WAF_CONFIGURE_ARGS+=   --disable-wayland
+.endif
+
+###
+### X11 support (video output)
+###
+.if !empty(PKG_OPTIONS:Mx11)
+WAF_CONFIGURE_ARGS+=   --enable-x11
+.include "../../x11/libXinerama/buildlink3.mk"
+.include "../../x11/libXrandr/buildlink3.mk"
+.include "../../x11/libXScrnSaver/buildlink3.mk"
+.include "../../x11/libXv/buildlink3.mk"
+.include "../../x11/libXxf86vm/buildlink3.mk"
+.else
+WAF_CONFIGURE_ARGS+=   --disable-x11
+.endif

Added files:

Index: pkgsrc/multimedia/mpv/patches/patch-video_out_wayland__common.c
diff -u /dev/null pkgsrc/multimedia/mpv/patches/patch-video_out_wayland__common.c:1.1
--- /dev/null   Sun Aug 18 17:57:56 2019
+++ pkgsrc/multimedia/mpv/patches/patch-video_out_wayland__common.c     Sun Aug 18 17:57:55 2019
@@ -0,0 +1,22 @@
+$NetBSD: patch-video_out_wayland__common.c,v 1.1 2019/08/18 17:57:55 nia Exp $
+
+Allow building on systems without evdev.
+
+--- video/out/wayland_common.c.orig    2018-10-02 19:03:41.000000000 +0000
++++ video/out/wayland_common.c
+@@ -16,8 +16,14 @@
+  */
+ 
+ #include <poll.h>
+-#include <unistd.h>
++#if defined(__linux) || defined(__FreeBSD__)
+ #include <linux/input.h>
++#else
++#define BTN_LEFT      (0)
++#define BTN_MIDDLE    (1)
++#define BTN_RIGHT     (2)
++#endif
++#include <unistd.h>
+ #include "common/msg.h"
+ #include "input/input.h"
+ #include "input/keycodes.h"



Home | Main Index | Thread Index | Old Index