aboutsummaryrefslogtreecommitdiff
path: root/games/nil
diff options
context:
space:
mode:
authorPav Lucistnik <pav@FreeBSD.org>2003-11-16 00:38:24 +0000
committerPav Lucistnik <pav@FreeBSD.org>2003-11-16 00:38:24 +0000
commitb4ae4c146196e5f702562cdd74c37cb183b04244 (patch)
tree92679f648f51b48da364dd1485eec17e578e3b4a /games/nil
parent6beb8fd966a65b742894777320b7727a66fcf46b (diff)
downloadports-b4ae4c146196e5f702562cdd74c37cb183b04244.tar.gz
ports-b4ae4c146196e5f702562cdd74c37cb183b04244.zip
Notes
Diffstat (limited to 'games/nil')
-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;
+ };
+ };
+