diff options
author | hans <hans@pkgsrc.org> | 2012-01-11 19:06:24 +0000 |
---|---|---|
committer | hans <hans@pkgsrc.org> | 2012-01-11 19:06:24 +0000 |
commit | 5125e8b85eebbc5e53a38d8521fa72922d7b6137 (patch) | |
tree | 3d555515838700a7ec78fd7d9859ba0522906db2 /audio | |
parent | 2413cecf581f2b573c6bd3b8b54c7e1843a56543 (diff) | |
download | pkgsrc-5125e8b85eebbc5e53a38d8521fa72922d7b6137.tar.gz |
Fix build on SunOS.
Diffstat (limited to 'audio')
-rw-r--r-- | audio/moc-devel/Makefile | 9 | ||||
-rw-r--r-- | audio/moc-devel/distinfo | 3 | ||||
-rw-r--r-- | audio/moc-devel/patches/patch-playlist__file.c | 52 | ||||
-rw-r--r-- | audio/moc/Makefile | 9 | ||||
-rw-r--r-- | audio/moc/distinfo | 3 | ||||
-rw-r--r-- | audio/moc/patches/patch-playlist__file.c | 52 |
6 files changed, 124 insertions, 4 deletions
diff --git a/audio/moc-devel/Makefile b/audio/moc-devel/Makefile index 4192e39a56b..df79c7b6036 100644 --- a/audio/moc-devel/Makefile +++ b/audio/moc-devel/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.7 2011/04/22 13:42:56 obache Exp $ +# $NetBSD: Makefile,v 1.8 2012/01/11 19:08:55 hans Exp $ DISTNAME= moc-2.5.0-alpha3 PKGNAME= ${DISTNAME:S/-alpha/./:moc%=moc-devel%} @@ -37,6 +37,13 @@ SUBST_MESSAGE.oss= Fixing hardcoded audio device. post-extract: ${CP} ${FILESDIR}/getline.c ${WRKSRC} +.include "../../mk/bsd.prefs.mk" +.if ${OPSYS} == "SunOS" +BUILDLINK_TRANSFORM+= rm:-Wl,--export-dynamic +.endif + +LIBS.SunOS+= -lsocket + .include "../../audio/libid3tag/buildlink3.mk" .include "../../audio/libmad/buildlink3.mk" .include "../../devel/gettext-lib/buildlink3.mk" diff --git a/audio/moc-devel/distinfo b/audio/moc-devel/distinfo index 245535b85ee..301696986b1 100644 --- a/audio/moc-devel/distinfo +++ b/audio/moc-devel/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.5 2011/09/12 06:27:21 dholland Exp $ +$NetBSD: distinfo,v 1.6 2012/01/11 19:08:55 hans Exp $ SHA1 (moc-2.5.0-alpha3.tar.bz2) = 59251b6239ad38f3f5ba8a1f73d1e90246765ab7 RMD160 (moc-2.5.0-alpha3.tar.bz2) = 7a603538e2080f3e182a543bc82100a09a56c2fe @@ -10,3 +10,4 @@ SHA1 (patch-ad) = 44b3ede2c3d69857e84a67ede997b429cce61a29 SHA1 (patch-ae) = f7b98f7af3843432bab24049b17c8639a0dfce59 SHA1 (patch-af) = 0176dff0c460a12a563df10685818face3c4b3d5 SHA1 (patch-ag) = 818df09cf6d06165cbd1c62681a3b5d84daa30bf +SHA1 (patch-playlist__file.c) = 1026a40068a75e5076d3b6d661e5c47f7f0a418e diff --git a/audio/moc-devel/patches/patch-playlist__file.c b/audio/moc-devel/patches/patch-playlist__file.c new file mode 100644 index 00000000000..526245b813f --- /dev/null +++ b/audio/moc-devel/patches/patch-playlist__file.c @@ -0,0 +1,52 @@ +$NetBSD: patch-playlist__file.c,v 1.1 2012/01/11 19:08:55 hans Exp $ + +--- playlist_file.c.orig 2007-07-30 16:58:46.000000000 +0200 ++++ playlist_file.c 2011-12-30 17:36:48.654368031 +0100 +@@ -91,8 +91,10 @@ static int plist_load_m3u (struct plist + return 0; + } + ++#ifndef __sun + if (flock(fileno(file), LOCK_SH) == -1) + logit ("Can't flock() the playlist file: %s", strerror(errno)); ++#endif + + while ((line = read_line(file))) { + if (!strncmp(line, "#EXTINF:", sizeof("#EXTINF:")-1)) { +@@ -190,9 +192,12 @@ static int plist_load_m3u (struct plist + free (line); + } + ++#ifndef __sun + if (flock(fileno(file), LOCK_UN) == -1) + logit ("Can't flock() (unlock) the playlist file: %s", + strerror(errno)); ++#endif ++ + fclose (file); + + return added; +@@ -432,8 +437,10 @@ static int plist_save_m3u (struct plist + return 0; + } + ++#ifndef __sun + if (flock(fileno(file), LOCK_EX) == -1) + logit ("Can't flock() the playlist file: %s", strerror(errno)); ++#endif + + if (fprintf(file, "#EXTM3U\r\n") < 0) { + error ("Error writing playlist: %s", strerror(errno)); +@@ -481,9 +488,12 @@ static int plist_save_m3u (struct plist + } + } + ++#ifndef __sun + if (flock(fileno(file), LOCK_UN) == -1) + logit ("Can't flock() (unlock) the playlist file: %s", + strerror(errno)); ++#endif ++ + if (fclose(file)) { + error ("Error writing playlist: %s", strerror(errno)); + return 0; diff --git a/audio/moc/Makefile b/audio/moc/Makefile index 294befed653..bba435c5a6e 100644 --- a/audio/moc/Makefile +++ b/audio/moc/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.16 2011/04/22 13:42:56 obache Exp $ +# $NetBSD: Makefile,v 1.17 2012/01/11 19:06:24 hans Exp $ DISTNAME= moc-2.4.3 PKGREVISION= 3 @@ -38,6 +38,13 @@ SUBST_MESSAGE.oss= Fixing hardcoded audio device. #pre-configure: # cd ${WRKSRC} && autoreconf -v -i +.include "../../mk/bsd.prefs.mk" +.if ${OPSYS} == "SunOS" +BUILDLINK_TRANSFORM+= rm:-Wl,--export-dynamic +.endif + +LIBS.SunOS+= -lsocket + .include "../../audio/libid3tag/buildlink3.mk" .include "../../audio/libmad/buildlink3.mk" .include "../../devel/gettext-lib/buildlink3.mk" diff --git a/audio/moc/distinfo b/audio/moc/distinfo index a170da16faf..28c83603288 100644 --- a/audio/moc/distinfo +++ b/audio/moc/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.7 2011/09/04 14:31:58 joerg Exp $ +$NetBSD: distinfo,v 1.8 2012/01/11 19:06:24 hans Exp $ SHA1 (moc-2.4.3.tar.bz2) = d9b54636f51f5366e94b684ddff3e869b1c634ac RMD160 (moc-2.4.3.tar.bz2) = 34470535b16ab329a9055b05550028ceb0a860f7 @@ -6,3 +6,4 @@ Size (moc-2.4.3.tar.bz2) = 459706 bytes SHA1 (patch-ab) = 91c80cc251cd1c245613e3c41907629a7934bda3 SHA1 (patch-ac) = d8c11caf51841021bc3d9999e1454922e89a370c SHA1 (patch-ad) = 9a242fdc116fa173354d4ebd93d624c8c4580b6a +SHA1 (patch-playlist__file.c) = 1026a40068a75e5076d3b6d661e5c47f7f0a418e diff --git a/audio/moc/patches/patch-playlist__file.c b/audio/moc/patches/patch-playlist__file.c new file mode 100644 index 00000000000..2ddbeea3fab --- /dev/null +++ b/audio/moc/patches/patch-playlist__file.c @@ -0,0 +1,52 @@ +$NetBSD: patch-playlist__file.c,v 1.1 2012/01/11 19:06:25 hans Exp $ + +--- playlist_file.c.orig 2007-07-30 16:58:46.000000000 +0200 ++++ playlist_file.c 2011-12-30 17:36:48.654368031 +0100 +@@ -91,8 +91,10 @@ static int plist_load_m3u (struct plist + return 0; + } + ++#ifndef __sun + if (flock(fileno(file), LOCK_SH) == -1) + logit ("Can't flock() the playlist file: %s", strerror(errno)); ++#endif + + while ((line = read_line(file))) { + if (!strncmp(line, "#EXTINF:", sizeof("#EXTINF:")-1)) { +@@ -190,9 +192,12 @@ static int plist_load_m3u (struct plist + free (line); + } + ++#ifndef __sun + if (flock(fileno(file), LOCK_UN) == -1) + logit ("Can't flock() (unlock) the playlist file: %s", + strerror(errno)); ++#endif ++ + fclose (file); + + return added; +@@ -432,8 +437,10 @@ static int plist_save_m3u (struct plist + return 0; + } + ++#ifndef __sun + if (flock(fileno(file), LOCK_EX) == -1) + logit ("Can't flock() the playlist file: %s", strerror(errno)); ++#endif + + if (fprintf(file, "#EXTM3U\r\n") < 0) { + error ("Error writing playlist: %s", strerror(errno)); +@@ -481,9 +488,12 @@ static int plist_save_m3u (struct plist + } + } + ++#ifndef __sun + if (flock(fileno(file), LOCK_UN) == -1) + logit ("Can't flock() (unlock) the playlist file: %s", + strerror(errno)); ++#endif ++ + if (fclose(file)) { + error ("Error writing playlist: %s", strerror(errno)); + return 0; |