summaryrefslogtreecommitdiff
path: root/audio/musicpd
diff options
context:
space:
mode:
authorpho <pho>2014-05-16 00:33:47 +0000
committerpho <pho>2014-05-16 00:33:47 +0000
commit64aae53ed1969029bda0de71fd3e968920707edc (patch)
treecae43116f209972f129bead6822d21b367ba3755 /audio/musicpd
parent9d26e61c01dd8c892819967efc78b768a9a36107 (diff)
downloadpkgsrc-64aae53ed1969029bda0de71fd3e968920707edc.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/musicpd')
-rw-r--r--audio/musicpd/Makefile11
-rw-r--r--audio/musicpd/distinfo4
-rw-r--r--audio/musicpd/patches/patch-src_output_HttpdOutputPlugin.cxx20
-rw-r--r--audio/musicpd/patches/patch-src_system_ByteOrder.hxx26
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