aboutsummaryrefslogtreecommitdiff
path: root/audio/playgsf
diff options
context:
space:
mode:
authorEmanuel Haupt <ehaupt@FreeBSD.org>2013-04-03 08:37:47 +0000
committerEmanuel Haupt <ehaupt@FreeBSD.org>2013-04-03 08:37:47 +0000
commit3ec5fd26a47984efb4ce2840657e0f251ea8f22f (patch)
tree774606d7d7ee0739deb991e3e2ec910e84d8cd65 /audio/playgsf
parent091d8dff2a793c50aa50e44d701dd87414bdbb82 (diff)
downloadports-3ec5fd26a47984efb4ce2840657e0f251ea8f22f.tar.gz
ports-3ec5fd26a47984efb4ce2840657e0f251ea8f22f.zip
- Enable build on amd64
- Fix build on 9.1 - Heed CC, CXX, CPPFLAGS, LDFLAGS in all subdir - Drop ABI version in LIB_DEPENDS Approved by: portmgr (miwi)
Notes
Notes: svn path=/head/; revision=315699
Diffstat (limited to 'audio/playgsf')
-rw-r--r--audio/playgsf/Makefile21
-rw-r--r--audio/playgsf/files/extrapatch-VBA__Util.cpp12
-rw-r--r--audio/playgsf/files/patch-VBA__GBA.cpp17
-rw-r--r--audio/playgsf/files/patch-libresample-0.1.3__Makefile.in13
-rw-r--r--audio/playgsf/pkg-message5
5 files changed, 57 insertions, 11 deletions
diff --git a/audio/playgsf/Makefile b/audio/playgsf/Makefile
index db862db0f4ab..307f96cd923b 100644
--- a/audio/playgsf/Makefile
+++ b/audio/playgsf/Makefile
@@ -3,7 +3,7 @@
PORTNAME= playgsf
PORTVERSION= 0.7.1
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= audio
MASTER_SITES= http://projects.raphnet.net/playgsf/ \
CRITICAL
@@ -11,29 +11,32 @@ MASTER_SITES= http://projects.raphnet.net/playgsf/ \
MAINTAINER= ehaupt@FreeBSD.org
COMMENT= Command-line player for gsf audio files
-LIB_DEPENDS= ao.4:${PORTSDIR}/audio/libao
+LIB_DEPENDS= ao:${PORTSDIR}/audio/libao
USE_GMAKE= yes
+USE_DOS2UNIX= yes
GNU_CONFIGURE= yes
MAKE_JOBS_SAFE= yes
-# disable optimization flags to avoid a possible bug in gcc
-# (gcc tries to allocate memory in an endless loop)
-CFLAGS+= -O0
-
CFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
MAKE_ENV+= LIBS="${LDFLAGS}"
CONFIGURE_ENV+= LIBS="${LDFLAGS}"
+CONFIGURE_ARGS+= --enable-ccore --disable-optimisations
PLIST_FILES= bin/playgsf
-# contains x86 assembler
-ONLY_FOR_ARCHS= i386
+ONLY_FOR_ARCHS= i386 amd64
PORTSCOUT= skipv:0.7.2
+.include <bsd.port.pre.mk>
+
+.if ${OSVERSION} >= 901000
+EXTRA_PATCHES= ${FILESDIR}/extrapatch-VBA__Util.cpp
+.endif
+
post-patch:
@${REINPLACE_CMD} \
-e 's|\(@LDFLAGS@\)|\1 ${LDFLAGS}|' \
@@ -51,4 +54,4 @@ do-install:
post-install:
${CAT} ${PKGMESSAGE}
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
diff --git a/audio/playgsf/files/extrapatch-VBA__Util.cpp b/audio/playgsf/files/extrapatch-VBA__Util.cpp
new file mode 100644
index 000000000000..096a5f6f0262
--- /dev/null
+++ b/audio/playgsf/files/extrapatch-VBA__Util.cpp
@@ -0,0 +1,12 @@
+--- ./VBA/Util.cpp.orig 2013-04-02 11:32:02.322879639 +0200
++++ ./VBA/Util.cpp 2013-04-02 11:33:58.107884638 +0200
+@@ -1484,7 +1484,8 @@
+
+ gzFile utilGzOpen(const char *file, const char *mode)
+ {
+- utilGzWriteFunc = (int (ZEXPORT *)(void *,void * const, unsigned int))gzwrite;
++ // utilGzWriteFunc = (int (ZEXPORT *)(void *,void * const, unsigned int))gzwrite;
++ utilGzWriteFunc = (int (ZEXPORT *)(gzFile_s*, void * const, unsigned int))gzwrite;
+ utilGzReadFunc = gzread;
+ utilGzCloseFunc = gzclose;
+
diff --git a/audio/playgsf/files/patch-VBA__GBA.cpp b/audio/playgsf/files/patch-VBA__GBA.cpp
new file mode 100644
index 000000000000..b97fbe111df9
--- /dev/null
+++ b/audio/playgsf/files/patch-VBA__GBA.cpp
@@ -0,0 +1,17 @@
+--- ./VBA/GBA.cpp.orig 2013-04-02 11:31:53.610879624 +0200
++++ ./VBA/GBA.cpp 2013-04-02 11:31:53.631880125 +0200
+@@ -1054,12 +1054,12 @@
+ {
+ rom = (u8 *)malloc(0x200);
+ loadedsize=0;
+- i = (int)utilLoad(szFile,utilIsGBAImage,whereToLoad,size);
++ i = (long)utilLoad(szFile,utilIsGBAImage,whereToLoad,size);
+ }
+ else
+ {
+ rom = utilLoad(szFile,utilIsGBAImage,whereToLoad,size);
+- i = (int) rom;
++ i = (long) rom;
+ }
+
+ //loadedsize = sizeof(*rom);
diff --git a/audio/playgsf/files/patch-libresample-0.1.3__Makefile.in b/audio/playgsf/files/patch-libresample-0.1.3__Makefile.in
new file mode 100644
index 000000000000..d33cee871dd0
--- /dev/null
+++ b/audio/playgsf/files/patch-libresample-0.1.3__Makefile.in
@@ -0,0 +1,13 @@
+--- ./libresample-0.1.3/Makefile.in.orig 2013-03-30 04:01:28.000000000 +0100
++++ ./libresample-0.1.3/Makefile.in 2013-03-30 14:03:51.000000000 +0100
+@@ -3,8 +3,8 @@
+ # systems, use this file as a template to create a
+ # working Makefile.
+
+-CC = @CC@
+-CFLAGS = @CFLAGS@ -Wall
++CC ?= @CC@
++CFLAGS ?= @CFLAGS@ -Wall
+
+ LIBS = @LIBS@ -lm
+
diff --git a/audio/playgsf/pkg-message b/audio/playgsf/pkg-message
index 3a1307dfbfdc..24d1b598f4f0 100644
--- a/audio/playgsf/pkg-message
+++ b/audio/playgsf/pkg-message
@@ -1,4 +1,5 @@
================================================================================
-A huge gsf file collection can be found at:
- http://www.caitsith2.com/gsf/ or http://www.zophar.net/gsf/
+A huge gsf collection can be found at:
+ * http://www.caitsith2.com/gsf/
+ * http://www.zophar.net/gsf/
================================================================================