diff options
author | pho <pho> | 2014-05-16 00:33:47 +0000 |
---|---|---|
committer | pho <pho> | 2014-05-16 00:33:47 +0000 |
commit | 4f45ac61f3cd811a4cc2c32dcceb5d6d45dfee13 (patch) | |
tree | 1c8665ad1cf955e34a7da37b6aedef5284a952e0 /audio | |
parent | 129c1a1d06a309e24e0795908a3e459944b78474 (diff) | |
download | pkgsrc-4f45ac61f3cd811a4cc2c32dcceb5d6d45dfee13.tar.gz |
Makefile: mpd requires gcc>=4.6 (see src/Compiler.h)
Makefile: Enable MacOS X audio output on Darwin
patches/patch-src_output_HttpdOutputPlugin.cxx:
Fix compilation error on Mach-O systems (or at least on Darwin 9)
patches/patch-src_system_ByteOrder.hxx:
Fix compilation error on Darwin/ppc
Diffstat (limited to 'audio')
-rw-r--r-- | audio/musicpd/Makefile | 11 | ||||
-rw-r--r-- | audio/musicpd/distinfo | 4 | ||||
-rw-r--r-- | audio/musicpd/patches/patch-src_output_HttpdOutputPlugin.cxx | 20 | ||||
-rw-r--r-- | audio/musicpd/patches/patch-src_system_ByteOrder.hxx | 26 |
4 files changed, 59 insertions, 2 deletions
diff --git a/audio/musicpd/Makefile b/audio/musicpd/Makefile index 7d0f8e7ef6c..fb9e7f23982 100644 --- a/audio/musicpd/Makefile +++ b/audio/musicpd/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.80 2014/05/05 00:47:37 ryoon Exp $ +# $NetBSD: Makefile,v 1.81 2014/05/16 00:33:47 pho Exp $ DISTNAME= mpd-0.18.10 PKGNAME= ${DISTNAME:S/mpd/musicpd/} @@ -20,6 +20,15 @@ USE_LIBTOOL= yes USE_TOOLS+= pkg-config USE_LANGUAGES= c c++ +# See ${WRKSRC}/src/Compiler.h: mpd requires gcc>=4.6 +GCC_REQD= 4.6 + +# MacOS X audio output is no longer enabled by default. +.include "../../mk/bsd.prefs.mk" +.if ${OPSYS} == "Darwin" +CONFIGURE_ARGS+= --enable-osx +.endif + CPPFLAGS.SunOS+= -std=gnu99 -D_XOPEN_SOURCE=600 -D__EXTENSIONS__ .include "options.mk" diff --git a/audio/musicpd/distinfo b/audio/musicpd/distinfo index 0362f5060fa..a19d611a0a9 100644 --- a/audio/musicpd/distinfo +++ b/audio/musicpd/distinfo @@ -1,5 +1,7 @@ -$NetBSD: distinfo,v 1.39 2014/04/18 12:46:57 wiz Exp $ +$NetBSD: distinfo,v 1.40 2014/05/16 00:33:47 pho Exp $ SHA1 (mpd-0.18.10.tar.xz) = 0923318cfda033bb4f89c219e6effa9d5b330c1d RMD160 (mpd-0.18.10.tar.xz) = 5bb43bbf1bb028ef1b075aec441a9e7cb6d1f633 Size (mpd-0.18.10.tar.xz) = 584312 bytes +SHA1 (patch-src_output_HttpdOutputPlugin.cxx) = 13ea3603f3d4027844eba3fb5561913774022711 +SHA1 (patch-src_system_ByteOrder.hxx) = 18dd0046bdd7cb7fef1979a40d6b51e7047cd66f diff --git a/audio/musicpd/patches/patch-src_output_HttpdOutputPlugin.cxx b/audio/musicpd/patches/patch-src_output_HttpdOutputPlugin.cxx new file mode 100644 index 00000000000..572686ceaa7 --- /dev/null +++ b/audio/musicpd/patches/patch-src_output_HttpdOutputPlugin.cxx @@ -0,0 +1,20 @@ +$NetBSD: patch-src_output_HttpdOutputPlugin.cxx,v 1.1 2014/05/16 00:33:47 pho Exp $ + +Inlining this method results in the following error on Mach-O systems +(or at least on Darwin 9): + + {standard input}:1322:FATAL:symbol: __ZZN11HttpdOutput7SendTagEPK3TagE5types + can't be a weak_definition (currently only supported in section of type + coalesced) + +--- src/output/HttpdOutputPlugin.cxx.orig 2014-05-16 00:08:45.000000000 +0000 ++++ src/output/HttpdOutputPlugin.cxx +@@ -479,7 +479,7 @@ httpd_output_pause(struct audio_output * + } + } + +-inline void ++void + HttpdOutput::SendTag(const Tag *tag) + { + assert(tag != nullptr); diff --git a/audio/musicpd/patches/patch-src_system_ByteOrder.hxx b/audio/musicpd/patches/patch-src_system_ByteOrder.hxx new file mode 100644 index 00000000000..3a21fd38b1d --- /dev/null +++ b/audio/musicpd/patches/patch-src_system_ByteOrder.hxx @@ -0,0 +1,26 @@ +$NetBSD: patch-src_system_ByteOrder.hxx,v 1.1 2014/05/16 00:33:47 pho Exp $ + +<endian.h> is a non-standard header that only Linux provides. + +--- src/system/ByteOrder.hxx.orig 2014-05-15 23:46:49.000000000 +0000 ++++ src/system/ByteOrder.hxx +@@ -40,8 +40,18 @@ + /* well-known big-endian */ + # define IS_LITTLE_ENDIAN false + # define IS_BIG_ENDIAN true ++#elif defined(__APPLE__) ++/* generic compile-time check for MacOS */ ++# include <machine/endian.h> ++# if BYTE_ORDER == LITTLE_ENDIAN ++# define IS_LITTLE_ENDIAN true ++# define IS_BIG_ENDIAN false ++# else ++# define IS_LITTLE_ENDIAN false ++# define IS_BIG_ENDIAN true ++# endif + #else +-/* generic compile-time check */ ++/* generic compile-time check for Linux */ + # include <endian.h> + # if __BYTE_ORDER == __LITTLE_ENDIAN + # define IS_LITTLE_ENDIAN true |