aboutsummaryrefslogtreecommitdiff
path: root/games/linux-quake3/Makefile
diff options
context:
space:
mode:
authorEdwin Groothuis <edwin@FreeBSD.org>2005-11-22 05:48:51 +0000
committerEdwin Groothuis <edwin@FreeBSD.org>2005-11-22 05:48:51 +0000
commit07efa6b5c4fdaec8b7159f5b8c106caf7696a470 (patch)
tree824edefdcc2efa41ce3cfc23946863ea39760045 /games/linux-quake3/Makefile
parent1e53364329090f5759a144db2c9d2e4a1b0d5b7d (diff)
[UPDATE] games/q3server: integrate with "quake3-data", rename to "linux-quake3"
Changes: * Rename to "linux-quake3" (also rename the port directory). * Integrate with "quake3-data". * Clean-up/rewrite. * Take maintainership. Changes: * Do not take maintainership. * Use a subdirectory under "libexec". * Use the same DIST_SUBDIR as "quake3-data" (becauses they use a common file). Changes: * Remove ".in" files and the "files" directory (build scripts in do-build). Changes: * Fix the wrapper scripts (weren't passing their arguments to the real binaries). PR: ports/86186 Submitted by: Alejandro Pulver <alejandro@varnet.biz> Approved by: maintainer timeout
Notes
Notes: svn path=/head/; revision=148997
Diffstat (limited to 'games/linux-quake3/Makefile')
-rw-r--r--games/linux-quake3/Makefile142
1 files changed, 66 insertions, 76 deletions
diff --git a/games/linux-quake3/Makefile b/games/linux-quake3/Makefile
index 33a6c620ffef..34856b02c070 100644
--- a/games/linux-quake3/Makefile
+++ b/games/linux-quake3/Makefile
@@ -5,97 +5,87 @@
# $FreeBSD$
#
-PORTNAME= q3ded
-PORTVERSION= 1.32b
-PORTREVISION= 1
+PORTNAME= quake3
+DISTVERSION= 1.32b-3
CATEGORIES= games linux
-MASTER_SITES= ftp://ftp.bluesnews.com/idstuff/quake3/linux/ \
- ftp://ftp.idsoftware.com/idstuff/quake3/linux/
-DISTNAME= linuxq3apoint-${PORTVERSION}.x86
+MASTER_SITES= ftp://ftp.idsoftware.com/idstuff/quake3/linux/
+PKGNAMEPREFIX= linux-
+DISTNAME= linuxq3apoint-${DISTVERSION}.x86
EXTRACT_SUFX= .run
+DIST_SUBDIR= ${Q3PKGNAMEPREFIX}data
MAINTAINER= pat@FreeBSD.org
-COMMENT= Quake III Arena Dedicated Server for Linux
+COMMENT= Quake III Arena for Linux
ONLY_FOR_ARCHS= i386
USE_LINUX= yes
-USE_PERL5= yes
-NO_CDROM= "Size; the data set is much too big"
-NO_BUILD= yes
NO_WRKSUBDIR= yes
-Q3BASE= games
-Q3DIR= ${Q3BASE}/quake3/
-PLIST_SUB+= Q3DIR="${Q3DIR}" Q3BASE="${Q3BASE}"
-INSTALL_DIR= ${INSTALL} -d -o ${BINOWN} -g ${BINGRP} -m 755
+
+OPTIONS= CLIENT "Install OpenGL client" on \
+ PUNKBUSTER "Install PunkBuster" on \
+ SMP "Install threaded version" on
+
+BINDIR= ${PREFIX}/libexec/${PKGNAMEPREFIX}${PORTNAME}
+PLIST_SUB+= BINDIR="${BINDIR:S/${PREFIX}\///}"
+
+LATEST_LINK= ${PKGNAMEPREFIX}${PORTNAME}
do-extract:
- @${RM} -rf ${WRKDIR}
@${MKDIR} ${WRKDIR}
- @cd ${WRKDIR} && ${TAIL} +266 ${_DISTDIR}/${DISTNAME}${EXTRACT_SUFX} | \
- ${TAR} zxvf - >/dev/null
+ @cd ${WRKDIR} && ${TAIL} +356 ${_DISTDIR}/${DISTNAME}${EXTRACT_SUFX} | \
+ ${TAR} zxf -
-pre-patch:
-# remove trailing ^M
- @${FIND} -E ${WRKSRC} -type f \
- -iregex ".*\.(bat|cfg|gam|htm|html|inf|ini|lst|sc|scr|txt|url)" \
- -exec ${PERL} -pi -ne 's!\r\n!\n!' {} 1>/dev/null 2>&1 \;
+.include "${.CURDIR}/../quake3-data/Makefile.include"
-do-install:
- @${INSTALL_DIR} ${PREFIX}/${Q3DIR}/pb ${PREFIX}/${Q3DIR}/baseq3 \
- ${PREFIX}/${Q3DIR}/missionpack
-.for bpak in 1 2 3 4 5 6 7 8
- @${INSTALL_DATA} ${WRKSRC}/baseq3/pak${bpak}.pk3 \
- ${PREFIX}/${Q3DIR}/baseq3
-.endfor
-.for mpak in 1 2 3
- @${INSTALL_DATA} ${WRKSRC}/missionpack/pak${mpak}.pk3 \
- ${PREFIX}/${Q3DIR}/missionpack
-.endfor
-.for exec in q3ded quake3.x86 quake3-smp.x86
- @${INSTALL} -c -o nobody -g nogroup -m 500 ${WRKSRC}/bin/x86/${exec} \
- ${PREFIX}/${Q3DIR}
-.endfor
-.for pb in pbag.so pbcl.so pbsv.so
- @${INSTALL_DATA} ${WRKSRC}/pb/${pb} ${PREFIX}/${Q3DIR}/pb
-.endfor
+.include <bsd.port.pre.mk>
-post-install:
-.if !defined(NOPORTDOCS)
- @${INSTALL_DIR} ${PREFIX}/${Q3DIR}/Docs/LinuxFAQ \
- ${PREFIX}/${Q3DIR}/Docs/PunkBuster/admins \
- ${PREFIX}/${Q3DIR}/Docs/PunkBuster/players \
- ${PREFIX}/${Q3DIR}/pb/htm
-.for docs in CHANGES-1.32.txt INSTALL Q3A_EULA.txt README-Id-7-26-01.html \
- README-linux.txt quake3.xpm
- @${INSTALL_DATA} ${WRKSRC}/${docs} ${PREFIX}/${Q3DIR}
-.endfor
-.for faq in INSTALL index.html udp_wide_README.txt udp_wide_broadcast.patch
- @${INSTALL_DATA} ${WRKSRC}/Docs/LinuxFAQ/${faq} \
- ${PREFIX}/${Q3DIR}/Docs/LinuxFAQ
-.endfor
-.for admins in index.htm tabout1.gif tadvanced1.gif tbasics1.gif \
- tcommands1.gif tcommands2.gif tenabling1.gif tfaq1.gif tgame1.gif \
- tintro1.gif tlogo.gif tmonitoring1.gif tpbint1.gif tpbsub1.gif \
- tplayer1.gif tquick1.gif tremote1.gif tscreen1.gif tsettings1.gif \
- ttitle1.gif ttoc1.gif tupdating1.gif
- @${INSTALL_DATA} ${WRKSRC}/Docs/PunkBuster/admins/${admins} \
- ${PREFIX}/${Q3DIR}/Docs/PunkBuster/admins
-.endfor
-.for players in index.htm sbrowser1.jpg skeyboard1.gif stilde1.gif tabout1.gif \
- tbasics1.gif tbutton1.gif tbutton2.gif tcommands1.gif tcommands2.gif \
- tenabling1.gif tfaq1.gif tfinding1.gif tgame1.gif tintro1.gif \
- tlogo.gif tmonitoring1.gif tname1.gif tpbint1.gif tpbsub1.gif \
- tquick1.gif tremote1.gif tscreen1.gif tsettings1.gif ttaking1.gif \
- ttitle1.gif ttoc1.gif tupdating1.gif tusing1.gif
- @${INSTALL_DATA} ${WRKSRC}/Docs/PunkBuster/players/${players} \
- ${PREFIX}/${Q3DIR}/Docs/PunkBuster/players
+PROGS= q3ded
+
+.if defined(WITH_CLIENT)
+PROGS+= quake3.x86
+PLIST_SUB+= CLIENT=""
+.else
+PLIST_SUB+= CLIENT="@comment "
+.endif
+
+.if defined(WITH_PUNKBUSTER)
+PLIST_SUB+= PUNKBUSTER=""
+.else
+PLIST_SUB+= PUNKBUSTER="@comment "
+.endif
+
+.if defined(WITH_SMP)
+PROGS+= quake3-smp.x86
+PLIST_SUB+= SMP=""
+.else
+PLIST_SUB+= SMP="@comment "
+.endif
+
+do-build:
+.for f in ${PROGS}
+ @(${ECHO_CMD} "#!${SH}"; \
+ ${ECHO_CMD} "cd ${DATADIR} || exit 1"; \
+ ${ECHO_CMD} "exec ${BINDIR}/${f:R} \"$$@\"") > ${WRKDIR}/${f:R}
.endfor
-.for pbhtm in la001293.htm lc000993.htm ls000993.htm ma001293.htm mc000993.htm \
- ms000993.htm wa001293.htm wc000993.htm ws000993.htm
- @${INSTALL_DATA} ${WRKSRC}/pb/htm/${pbhtm} ${PREFIX}/${Q3DIR}/pb/htm
+
+do-install:
+ @${MKDIR} ${BINDIR}
+.for f in ${PROGS}
+ @${INSTALL_PROGRAM} ${WRKSRC}/bin/Linux/x86/${f} ${BINDIR}/${f:R}
+ @${INSTALL_SCRIPT} ${WRKDIR}/${f:R} ${PREFIX}/bin/linux-${f:R}
.endfor
- @${INSTALL_DATA} ${WRKSRC}/pb/PB_EULA.txt ${PREFIX}/${Q3DIR}/pb
+.if defined(WITH_PUNKBUSTER)
+ @${CP} -Rp ${WRKSRC}/pb ${DATADIR}
+ @${RM} ${DATADIR}/pb/PB_EULA.txt
+.endif
+.if !defined(NOPORTDOCS)
+ @${MKDIR} ${DOCSDIR}
+ @${INSTALL_DATA} ${WRKSRC}/README-linux.txt ${DOCSDIR}
+ @${CP} -Rp ${WRKSRC}/Docs/LinuxFAQ ${DOCSDIR}
+. if defined(WITH_PUNKBUSTER)
+ @${CP} -Rp ${WRKSRC}/Docs/PunkBuster ${DOCSDIR}
+ @${INSTALL_DATA} ${WRKSRC}/pb/PB_EULA.txt ${DOCSDIR}/PunkBuster
+. endif
.endif
- @${CAT} ${PKGMESSAGE}
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>