diff options
author | Sam Lawrance <lawrance@FreeBSD.org> | 2006-02-12 04:08:19 +0000 |
---|---|---|
committer | Sam Lawrance <lawrance@FreeBSD.org> | 2006-02-12 04:08:19 +0000 |
commit | f7cc5b5fa8c50d7969118aef8d9b900c3cdb3aa2 (patch) | |
tree | 9e3a2ee15c220428fae306f457387c7150da46a0 /games/wop | |
parent | 5e3ee7055f5542ddb5c1fdafdd7c3b6776ab6b86 (diff) | |
download | ports-f7cc5b5fa8c50d7969118aef8d9b900c3cdb3aa2.tar.gz ports-f7cc5b5fa8c50d7969118aef8d9b900c3cdb3aa2.zip |
Notes
Diffstat (limited to 'games/wop')
-rw-r--r-- | games/wop/Makefile | 15 | ||||
-rw-r--r-- | games/wop/distinfo | 6 | ||||
-rw-r--r-- | games/wop/files/extra-patch-src-global.hpp | 11 | ||||
-rw-r--r-- | games/wop/pkg-plist | 4 |
4 files changed, 27 insertions, 9 deletions
diff --git a/games/wop/Makefile b/games/wop/Makefile index d9b09c39e460..5cbc4392fad4 100644 --- a/games/wop/Makefile +++ b/games/wop/Makefile @@ -6,7 +6,7 @@ # PORTNAME= wop -PORTVERSION= 0.4 +PORTVERSION= 0.4.1 CATEGORIES= games MASTER_SITES= http://wormsofprey.org/download/ DISTFILES= ${PORTNAME}-${PORTVERSION}-src${EXTRACT_SUFX} \ @@ -15,12 +15,12 @@ DISTFILES= ${PORTNAME}-${PORTVERSION}-src${EXTRACT_SUFX} \ MAINTAINER= amdmi3@mail.ru COMMENT= Free real-time Worms game -BUILD_DEPENDS= makedepend:${PORTSDIR}/devel/imake-6 +BUILD_DEPENDS= makedepend:${X_IMAKE_PORT} USE_BZIP2= yes USE_SDL= sdl net mixer ttf image USE_GMAKE= yes -USE_REINPLACE= yes +USE_GCC= 3.4+ MAKE_ENV= "CXX=${CXX}" @@ -29,7 +29,7 @@ DATAVERSION= 2005-12-21 .include <bsd.port.pre.mk> .if ${OSVERSION} < 500000 -BROKEN= "Does not compile on < 5.x" +EXTRA_PATCHES= ${FILESDIR}/extra-patch-src-global.hpp .endif post-patch: @@ -39,11 +39,16 @@ post-patch: @${REINPLACE_CMD} -e 's|= g++|?= g++|g' ${WRKSRC}/sdlwidgets/Makefile ${WRKSRC}/src/Makefile @${REINPLACE_CMD} -e 's|/etc/woprc|${PREFIX}/etc/woprc|' ${WRKSRC}/src/wopsettings.cpp @${REINPLACE_CMD} -e 's|\./data|${DATADIR}|' ${WRKSRC}/woprc + @${REINPLACE_CMD} -e '/stdint.h/ d' ${WRKSRC}/src/attachableobject.cpp do-install: ${INSTALL_PROGRAM} ${WRKSRC}/bin/wop ${PREFIX}/bin - ${INSTALL_DATA} ${WRKSRC}/woprc ${PREFIX}/etc + ${INSTALL_DATA} ${WRKSRC}/woprc ${PREFIX}/etc/woprc.sample + if [ ! -f ${PREFIX}/etc/woprc ]; then \ + ${INSTALL_DATA} ${WRKSRC}/woprc ${PREFIX}/etc; \ + fi + @echo "Installing data files..." @cd ${WRKDIR}/${PORTNAME}data-${DATAVERSION}; \ ${FIND} . -type d -exec ${MKDIR} ${DATADIR}/{} \; ; \ ${FIND} . -type f -exec ${INSTALL_DATA} {} ${DATADIR}/{} \; diff --git a/games/wop/distinfo b/games/wop/distinfo index ce0da24a99e9..e10c41c337d8 100644 --- a/games/wop/distinfo +++ b/games/wop/distinfo @@ -1,6 +1,6 @@ -MD5 (wop-0.4-src.tar.bz2) = f508cf330815eb727552b88303d40ec5 -SHA256 (wop-0.4-src.tar.bz2) = 96127385234861e78b41085e9f0490423a813bf0eb31e7c4b157725a14879349 -SIZE (wop-0.4-src.tar.bz2) = 275247 +MD5 (wop-0.4.1-src.tar.bz2) = 339c6a832a5add5c0867a0aca6c935bb +SHA256 (wop-0.4.1-src.tar.bz2) = 787f60362d605ba4fb3df2f513605587a84015153777c05c84679ef3ed23d82b +SIZE (wop-0.4.1-src.tar.bz2) = 279613 MD5 (wopdata-2005-12-21.tar.bz2) = 0bf42f28e03dcac5c8066b46d7733907 SHA256 (wopdata-2005-12-21.tar.bz2) = cd6b8eb9f77f709d7a52b913d8a665bd202c53ceca9cf96b4c9f9adc17d8a6b2 SIZE (wopdata-2005-12-21.tar.bz2) = 4217006 diff --git a/games/wop/files/extra-patch-src-global.hpp b/games/wop/files/extra-patch-src-global.hpp new file mode 100644 index 000000000000..41e8d81f1441 --- /dev/null +++ b/games/wop/files/extra-patch-src-global.hpp @@ -0,0 +1,11 @@ +--- src/global.hpp.orig Tue Jun 28 17:55:19 2005 ++++ src/global.hpp Fri Feb 10 00:42:31 2006 +@@ -44,7 +44,7 @@ + + void makePace(); + +-inline int ROUND( const real x ) { return static_cast<int>( round( x )); } ++#define ROUND(x) (int)((x)-floor(x) < 0.5 ? floor(x) : ceil(x)) + + // already defined somewhere else + //template<class T> T min( const T a, const T b ) { return a < b ? a : b; } diff --git a/games/wop/pkg-plist b/games/wop/pkg-plist index 58b254f96358..7f8787ea4d70 100644 --- a/games/wop/pkg-plist +++ b/games/wop/pkg-plist @@ -1,5 +1,7 @@ bin/wop -etc/woprc +@unexec if cmp -s %D/etc/woprc %D/etc/woprc.sample; then rm -f %D/etc/woprc; fi +etc/woprc.sample +@exec if [ ! -f %D/etc/woprc ]; then cp -p %D/etc/woprc.sample %D/etc/woprc; fi %%DATADIR%%/images/avatar/worm/remote_control/eyes_rc_left.pnm %%DATADIR%%/images/avatar/worm/remote_control/eyes_rc_right.pnm %%DATADIR%%/images/avatar/worm/remote_control/gun_rc_left.pnm |