Created
May 14, 2019 12:12
-
-
Save tsutsui/63af3152f7ad96aeb7d500fff9fc5da8 to your computer and use it in GitHub Desktop.
Add ALSA audio output support for pkgsrc/multimedia/mpv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
? patches/patch-audio_out_ao__alsa.c | |
Index: distinfo | |
=================================================================== | |
RCS file: /cvsroot/pkgsrc/multimedia/mpv/distinfo,v | |
retrieving revision 1.51 | |
diff -u -p -d -r1.51 distinfo | |
--- distinfo 5 Feb 2019 12:07:57 -0000 1.51 | |
+++ distinfo 14 May 2019 12:10:53 -0000 | |
@@ -4,6 +4,7 @@ SHA1 (mpv-0.29.1.tar.gz) = 83f2bc0eb5a8b | |
RMD160 (mpv-0.29.1.tar.gz) = 72a4fda3a72ac4fd37ed04435833fa2cf378a012 | |
SHA512 (mpv-0.29.1.tar.gz) = ec57c9ceaaf2915ee237dd5a1c5ea5d22725d8611e28a9b998e5bb0d8ab5bdf3631d0267fc7b54da31cb1eaa145ef35841e68846bd41c3b9e1024902e92fd086 | |
Size (mpv-0.29.1.tar.gz) = 3059503 bytes | |
+SHA1 (patch-audio_out_ao__alsa.c) = c4661d0d22550d6e4eb2b7a42dd04dbcc58123b0 | |
SHA1 (patch-audio_out_ao__oss.c) = 824c214d0d4464b94e46a922ede4045ae537a534 | |
SHA1 (patch-player_main.c) = e794199990059cc95050032194bca70557c381d7 | |
SHA1 (patch-video_out_drm__common.c) = facb8d99fe31119618866c9af512a60e54b4ea6c | |
Index: options.mk | |
=================================================================== | |
RCS file: /cvsroot/pkgsrc/multimedia/mpv/options.mk,v | |
retrieving revision 1.16 | |
diff -u -p -d -r1.16 options.mk | |
--- options.mk 26 Nov 2018 12:24:47 -0000 1.16 | |
+++ options.mk 14 May 2019 12:10:53 -0000 | |
@@ -5,8 +5,8 @@ PKG_OPTIONS_VAR= PKG_OPTIONS.mpv | |
.include "../../multimedia/libva/available.mk" | |
.include "../../multimedia/libvdpau/available.mk" | |
-PKG_SUPPORTED_OPTIONS= ass bluray caca lua pulseaudio rpi sdl2 v4l2 | |
-PKG_SUGGESTED_OPTIONS= ass bluray lua pulseaudio | |
+PKG_SUPPORTED_OPTIONS= alsa ass bluray caca lua pulseaudio rpi sdl2 v4l2 | |
+PKG_SUGGESTED_OPTIONS= alsa ass bluray lua pulseaudio | |
.if ${VAAPI_AVAILABLE} == "yes" | |
PKG_SUPPORTED_OPTIONS+= vaapi | |
@@ -21,6 +21,16 @@ PKG_SUGGESTED_OPTIONS+= vdpau | |
.include "../../mk/bsd.options.mk" | |
### | |
+### ALSA support (audio output) | |
+### | |
+.if !empty(PKG_OPTIONS:Malsa) | |
+WAF_CONFIGURE_ARGS+= --enable-alsa | |
+.include "../../audio/alsa-lib/buildlink3.mk" | |
+.else | |
+WAF_CONFIGURE_ARGS+= --disable-alsa | |
+.endif | |
+ | |
+### | |
### libbluray support | |
### | |
.if !empty(PKG_OPTIONS:Mbluray) | |
--- /dev/null 2019-05-14 21:09:13.424794345 +0900 | |
+++ patches/patch-audio_out_ao__alsa.c 2019-05-14 21:09:10.890047804 +0900 | |
@@ -0,0 +1,18 @@ | |
+$NetBSD$ | |
+ | |
+- pull a compat definition of ESTRPIPE for non-Linux OSes | |
+ from alsa-lib-1.1.4.1/include/type_compat.h | |
+ | |
+--- audio/out/ao_alsa.c.orig 2018-10-02 19:03:41.000000000 +0000 | |
++++ audio/out/ao_alsa.c | |
+@@ -49,6 +49,10 @@ | |
+ #define HAVE_CHMAP_API 0 | |
+ #endif | |
+ | |
++#ifndef ESTRPIPE | |
++#define ESTRPIPE EPIPE | |
++#endif | |
++ | |
+ #include "ao.h" | |
+ #include "internal.h" | |
+ #include "audio/format.h" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment