diff options
author | Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org> | 2001-07-14 15:20:39 +0000 |
---|---|---|
committer | Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org> | 2001-07-14 15:20:39 +0000 |
commit | 87f81525238225e7ae7bb2cb8af7c9db9f1752f9 (patch) | |
tree | a17bc9be0be51a8f2174e57dc183bb020e2d28e7 /games/halflifeserver/Makefile | |
parent | e94f56093383bc06c847bca1927afee8597dff93 (diff) | |
download | ports-87f81525238225e7ae7bb2cb8af7c9db9f1752f9.tar.gz ports-87f81525238225e7ae7bb2cb8af7c9db9f1752f9.zip |
Notes
Diffstat (limited to 'games/halflifeserver/Makefile')
-rw-r--r-- | games/halflifeserver/Makefile | 67 |
1 files changed, 32 insertions, 35 deletions
diff --git a/games/halflifeserver/Makefile b/games/halflifeserver/Makefile index 129aeb500d30..573999f97655 100644 --- a/games/halflifeserver/Makefile +++ b/games/halflifeserver/Makefile @@ -6,8 +6,7 @@ # PORTNAME= hlds -PORTVERSION= 3.1.0.6 -PORTREVISION= 2 +PORTVERSION= 3.1.0.7 CATEGORIES= games linux MASTER_SITES= http://games.velocity.net/files/Halflife/ \ ftp://ftp.gmd.de/people/cla/hl/hl-newest/linux/ \ @@ -15,7 +14,7 @@ MASTER_SITES= http://games.velocity.net/files/Halflife/ \ http://ftp1download.gamespy.com/fileplanet/fpnew/action/half-life/official/ \ http://fileplanet.games-world.net/dl/ftp1.gamespy.com/fpnew/action/half-life/official/ \ ftp://ftp.fh-rosenheim.de/pub/games/halflife/servers/ -DISTNAME= hlds_l3106 +DISTFILES= hlds_l3106.tar.gz hlds_l3107_upgrade.tar.gz MAINTAINER= pat@databits.net @@ -31,45 +30,43 @@ INSTALL_DIR= ${INSTALL} -d -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} LDCONFIG_LINUX= ${LINUXBASE}/sbin/ldconfig HLDSDIR= /usr/games/hlds_l/ -HL_DIRS= valve/maps valve/events valve/dlls valve/cl_dlls \ - tfc/tfstats tfc/sound/weapons tfc/sound/vox \ - tfc/sound/misc tfc/models/player/spy \ - tfc/models/player/soldier tfc/models/player/sniper \ - tfc/models/player/scout tfc/models/player/pyro \ - tfc/models/player/medic tfc/models/player/hvyweapon \ - tfc/models/player/engineer tfc/models/player/demo \ - tfc/models/player/civilian tfc/maps tfc/manual \ - tfc/events/wpn tfc/events/misc tfc/events/explode \ - tfc/events/door tfc/dlls tfc/cl_dlls HL_PROGRAM= hlds_run +SORT?= /usr/bin/sort pre-patch: # remove trailing ^M - @find -E ${WRKSRC} -type f \ - -iregex ".*\.(bat|cfg|gam|htm|html|inf|ini|lst|sc|scr|txt)" \ - -exec ${PERL} -pi -ne 's!\r\n!\n!' {} 1>/dev/null 2>&1 \; + @find -E ${WRKSRC} -type f \ + -iregex ".*\.(bat|cfg|gam|htm|html|inf|ini|lst|sc|scr|txt)" \ + -exec ${PERL} -pi -ne 's!\r\n!\n!' {} 1>/dev/null 2>&1 \; -do-install: install-files scan-libs +do-install: install-parse-plist install-run-scripts scan-libs -install-files: -# directories -.for directory in ${HL_DIRS} - @${INSTALL_DIR} ${PREFIX}${HLDSDIR}${directory} +# Contributed by <lioux@FreeBSD.org> +install-parse-plist: generate-plist + @${PERL} -e 'open(FHANDLER,"${TMPPLIST}");' \ + -e 'open(FDIR,">${WRKDIR}/dirs.sh.tmp");' \ + -e 'open(FFILES,">${WRKDIR}/files.sh");' \ + -e 'while (!eof(FHANDLER)) {' \ + -e 'chop($$file = <FHANDLER>);' \ + -e '$$dir = $$file_partial = $$file;' \ + -e '$$file_partial =~ s!^${HLDSDIR:S!^/!!}!!;' \ + -e 'print FDIR "${INSTALL_DIR}", \ + " ", "\"${PREFIX}/$$dir\"", \ + "\n" if $$dir =~ s!(^\@dirrm\s+)!!;' \ + -e 'print FFILES "${INSTALL_DATA}", \ + " ", "\"${WRKSRC}/$$file_partial\"", \ + " ", "\"${PREFIX}/$$file\"", \ + "\n" if ($$file !~ m!^\@!);' \ + -e '}' \ + -e 'close(FFILES);' \ + -e 'close(FDIR);' \ + -e 'close(FHANDLER);' + @${SORT} ${WRKDIR}/dirs.sh.tmp > ${WRKDIR}/dirs.sh + +install-run-scripts: +.for script in dirs files + @${SH} ${WRKDIR}/${script}.sh .endfor -# if you change the PLIST, please re-think the following -# files - @for file in `${SED} -E -e "s!^\@.+!!" -e "s!%%HLDSDIR%%!!" ${PLIST}` ;\ - do \ - ${INSTALL_DATA} ${WRKSRC}/$${file} ${PREFIX}${HLDSDIR}$${file} ;\ - done -# trim/set permissions - @${CHMOD} ${BINMODE} ${PREFIX}${HLDSDIR}${HL_PROGRAM} -# libraries -# this should go in a pkg-install, should be checked later - @if ! (${GREP} -E \"^${HLDSDIR}$$\" ${PREFIX}/etc/ld.so.conf >/dev/null 2>/dev/null) ;\ - then \ - ${ECHO} ${HLDSDIR} >> ${PREFIX}/etc/ld.so.conf ;\ - fi scan-libs: @${LDCONFIG_LINUX} |