aboutsummaryrefslogtreecommitdiffstats
path: root/games
diff options
context:
space:
mode:
authorpav <pav@FreeBSD.org>2003-11-16 08:38:24 +0800
committerpav <pav@FreeBSD.org>2003-11-16 08:38:24 +0800
commitf19e43d86f829825695e5ed97c4f4c220ace651a (patch)
tree6d889cea228172ab3ba9ad0ace1c6c49b75ac4a5 /games
parent72c82416d39fbaa1f9e61eff768e17ab2b532e8c (diff)
downloadfreebsd-ports-gnome-f19e43d86f829825695e5ed97c4f4c220ace651a.tar.gz
freebsd-ports-gnome-f19e43d86f829825695e5ed97c4f4c220ace651a.tar.zst
freebsd-ports-gnome-f19e43d86f829825695e5ed97c4f4c220ace651a.zip
- Unbreak on -CURRENT
- Remove Sourceforge mastersite. This release seems to never get there. - Use USE_SDL - Convert perl patching to sed inplace Approved by: marcus (backup mentor)
Diffstat (limited to 'games')
-rw-r--r--games/nil/Makefile23
-rw-r--r--games/nil/files/patch-nil-anim_helpers.cpp11
-rw-r--r--games/nil/files/patch-nil-animation.h11
-rw-r--r--games/nil/files/patch-nil-world.h15
4 files changed, 45 insertions, 15 deletions
diff --git a/games/nil/Makefile b/games/nil/Makefile
index c6cfde611ee8..c424d727a1f9 100644
--- a/games/nil/Makefile
+++ b/games/nil/Makefile
@@ -8,9 +8,8 @@
PORTNAME= nil
PORTVERSION= 000928
CATEGORIES= games
-MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} \
- ${MASTER_SITE_LOCAL}
-MASTER_SITE_SUBDIR= ${PORTNAME} sobomax
+MASTER_SITES= ${MASTER_SITE_LOCAL}
+MASTER_SITE_SUBDIR= sobomax
MAINTAINER= ports@FreeBSD.org
COMMENT= A multiplayer game that can be described as Quake in 2D or Worms done right
@@ -19,25 +18,19 @@ LIB_DEPENDS= SDL_mixer.2:${PORTSDIR}/audio/sdl_mixer
WRKSRC= ${WRKDIR}/${PORTNAME}/${PORTNAME}
-SDL_CONFIG?= ${LOCALBASE}/bin/sdl11-config
-
USE_GMAKE= yes
GNU_CONFIGURE= yes
-MAKE_ENV= SDL_CONFIG="${SDL_CONFIG}"
-
-.include <bsd.port.pre.mk>
-
-.if ${OSVERSION} >= 500113
-BROKEN= "Does not compile (bad C++ code)"
-.endif
+USE_REINPLACE= yes
+USE_SDL= yes
pre-patch:
@${FIND} ${WRKSRC} \( -name "*.[ch]" -or -name "*.cpp" \) | \
- ${XARGS} ${PERL} -pi -e 's|"SDL/|"|g ; s|<SDL/|<|g'
+ ${XARGS} ${REINPLACE_CMD} -e 's|"SDL/|"|g ; s|<SDL/|<|g'
@${FIND} ${WRKSRC}/.. -type d -name CVS | ${XARGS} ${RM} -rf
+ @${REINPLACE_CMD} -e 's|iostream.h|iostream|' ${WRKSRC}/nil/systemheaders.h
post-configure:
- @${PERL} -pi -e "s|%%PREFIX%%|${PREFIX}|g" ${WRKSRC}/nil/configuration.cpp
+ @${REINPLACE_CMD} -e "s|%%PREFIX%%|${PREFIX}|g" ${WRKSRC}/nil/configuration.cpp
post-install:
@${MKDIR} ${PREFIX}/share/nil
@@ -48,4 +41,4 @@ post-install:
@${ECHO_MSG} "See ${PREFIX}/share/nil/README for usage instructions."
@${ECHO_MSG} ""
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>
diff --git a/games/nil/files/patch-nil-anim_helpers.cpp b/games/nil/files/patch-nil-anim_helpers.cpp
new file mode 100644
index 000000000000..66b7deebadb0
--- /dev/null
+++ b/games/nil/files/patch-nil-anim_helpers.cpp
@@ -0,0 +1,11 @@
+--- nil/anim_helpers.cpp.orig Sat Nov 15 16:43:08 2003
++++ nil/anim_helpers.cpp Sat Nov 15 16:57:35 2003
+@@ -210,7 +210,7 @@
+ }
+
+ if (hit != end())
+- return hit;
++ return &(*hit);
+ else {
+ logmsg(lt_debug,"Unable to find a suitable aim_id for elevation: %.2f (%i angles were tried)",elevation,size());
+ return NULL;
diff --git a/games/nil/files/patch-nil-animation.h b/games/nil/files/patch-nil-animation.h
new file mode 100644
index 000000000000..72fe65510a49
--- /dev/null
+++ b/games/nil/files/patch-nil-animation.h
@@ -0,0 +1,11 @@
+--- nil/animation.h.orig Sat Nov 15 16:18:52 2003
++++ nil/animation.h Sat Nov 15 16:26:19 2003
+@@ -25,7 +25,7 @@
+ class Animator;
+ class Animation {
+ public:
+- friend Animator;
++ friend class Animator;
+
+ Animation();
+ ~Animation();
diff --git a/games/nil/files/patch-nil-world.h b/games/nil/files/patch-nil-world.h
new file mode 100644
index 000000000000..52ae1a629044
--- /dev/null
+++ b/games/nil/files/patch-nil-world.h
@@ -0,0 +1,15 @@
+--- nil/world.h.orig Sat Nov 15 16:28:04 2003
++++ nil/world.h Sat Nov 15 16:34:01 2003
+@@ -34,10 +34,8 @@
+ int flags;
+ union {
+ int object_id;
+- struct abspos {
+- float x_pos;
+- float y_pos;
+- };
++ float x_pos;
++ float y_pos;
+ };
+ };
+