Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Mar 2015 11:51:07 +0000 (UTC)
From:      Jan Beich <jbeich@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r381324 - in head/games: assaultcube assaultcube/files bloodfrontier cube redeclipse sauerbraten
Message-ID:  <201503151151.t2FBp78j007457@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jbeich
Date: Sun Mar 15 11:51:06 2015
New Revision: 381324
URL: https://svnweb.freebsd.org/changeset/ports/381324
QAT: https://qat.redports.org/buildarchive/r381324/

Log:
  Improve style, consistency and fix minor issues in Cube-based ports
  
  - Convert to option helpers
  - Drop unused libGLU dependency (except for games/cube)
  - Track direct dependency on libX11 (for XFetchBytes)
  - Drop redundant MKDIR before COPYTREE_* macros [1]
  - Wrap cd related commands with parentheses [1]
  - Wrap lines exceeding 80 characters
  - Bump PORTREVISION to pick up changes in dependencies, plist (assaultcube)
    and catch regressions early [1]
  - games/assaultcube: CLIENT uses openal/vorbisfile *instead* of SDL_mixer
  - games/assaultcube: drop unused gettext-tools dependency [1]
  - games/assaultcube: convert to PLIST_DIRS [1]
  - games/assaultcube: add patch for source/src/bot/bot_waypoint.cpp
    file to fix "invalid source encoding" warning [1]
  - games/{cube,bloodfrontier}: MASTER or SERVER don't need libX11
  - games/redeclipse: tell how large the package is in IGNORE message
  - games/redeclipse: use PORTDATA to hold list of dirs for COPYTREE_SHARE
  
  Differential Revision:	https://reviews.freebsd.org/D1831
  PR:		197582 [1]
  PR:		197583 [2]
  Submitted by:	lightside@gmx.com [1]
  Requested by:	lightside@gmx.com [1]
  Reviewed by:	amdmi3, lightside@gmx.com (maintainers)
  Approved by:	maintainer timeout (1 month) [2]
  Approved by:	bapt (mentor)

Added:
  head/games/assaultcube/files/patch-source_src_bot_bot_waypoint.cpp   (contents, props changed)
Modified:
  head/games/assaultcube/Makefile
  head/games/bloodfrontier/Makefile
  head/games/cube/Makefile
  head/games/redeclipse/Makefile
  head/games/sauerbraten/Makefile

Modified: head/games/assaultcube/Makefile
==============================================================================
--- head/games/assaultcube/Makefile	Sun Mar 15 11:50:30 2015	(r381323)
+++ head/games/assaultcube/Makefile	Sun Mar 15 11:51:06 2015	(r381324)
@@ -3,7 +3,7 @@
 
 PORTNAME=	assaultcube
 PORTVERSION=	1.2.0.2
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	games
 MASTER_SITES=	SF/actiongame/AssaultCube%20Version%20${PORTVERSION}
 DISTNAME=	AssaultCube_v${PORTVERSION}
@@ -23,78 +23,60 @@ LICENSE_PERMS_ACUBE=	dist-mirror dist-se
 LICENSE_PERMS_CUBE=	dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
 LICENSE_PERMS_OTHER=	dist-mirror pkg-mirror auto-accept
 
-USES=		gmake openal:al tar:bzip2
+USES=		gmake tar:bzip2
 GNU_CONFIGURE=	yes
 ALL_TARGET=	libenet
 WRKSRC=		${WRKDIR}/AssaultCube_v${PORTVERSION}
 CONFIGURE_ARGS=	--enable-shared=no --enable-static=yes
 CONFIGURE_WRKSRC=	${WRKSRC}/source/enet
 BUILD_WRKSRC=	${WRKSRC}/source/src
+SUB_FILES=	${PLIST_FILES:Mbin/*:T}
 
 PORTDATA=	config packages scripts
 PORTDOCS=	*
+PLIST_DIRS=	%%DATADIR%%/packages/maps/servermaps/incoming
 
 OPTIONS_DEFINE=	DOCS
 OPTIONS_MULTI=	BUILD
 OPTIONS_MULTI_BUILD=	CLIENT DEDICATED MASTER
 OPTIONS_DEFAULT=	CLIENT DEDICATED
+
 CLIENT_DESC=	Build client
+CLIENT_USES=		gettext-runtime openal:al
+CLIENT_USE=		GL=gl SDL=image,sdl XORG=x11
+CLIENT_LIB_DEPENDS=	libvorbisfile.so:${PORTSDIR}/audio/libvorbis \
+			libcurl.so:${PORTSDIR}/ftp/curl
+CLIENT_ALL_TARGET=	client
+CLIENT_PLIST_FILES=	bin/${PORTNAME}_client libexec/${PORTNAME}_client \
+			share/pixmaps/${PORTNAME}.png
 DEDICATED_DESC=	Build dedicated server
+DEDICATED_ALL_TARGET=	server
+DEDICATED_PLIST_FILES=	bin/${PORTNAME}_server libexec/${PORTNAME}_server
 MASTER_DESC=	Build master server
+MASTER_ALL_TARGET=	master
+MASTER_PLIST_FILES=	bin/${PORTNAME}_master libexec/${PORTNAME}_master
 
 .include <bsd.port.options.mk>
 
 .if ${PORT_OPTIONS:MCLIENT}
-LIB_DEPENDS+=	libcurl.so:${PORTSDIR}/ftp/curl
-USES+=		gettext
-USE_GL=		yes
-USE_SDL=	image mixer sdl
-ALL_TARGET+=	client
-SUB_FILES+=	${PORTNAME}_client
-ACUBE_BIN+=	client
-
 DESKTOP_ENTRIES="AssaultCube" "${COMMENT}" \
 	"${PREFIX}/share/pixmaps/${PORTNAME}.png" "${PORTNAME}_client" \
 	"Game;" false
 .endif
 
-.if ${PORT_OPTIONS:MDEDICATED}
-ALL_TARGET+=	server
-SUB_FILES+=	${PORTNAME}_server
-ACUBE_BIN+=	server
-.endif
-
-.if ${PORT_OPTIONS:MMASTER}
-ALL_TARGET+=	master
-SUB_FILES+=	${PORTNAME}_master
-ACUBE_BIN+=	master
-.endif
-
-pre-install: .SILENT
-	# 	Current STAGEDIR doesn't create empty directories for package,
-	# in case of dynamically generated TMPPLIST, where these directories exist
-	${RMDIR} ${WRKSRC}/packages/maps/servermaps/incoming
-
 do-install:
-.for f in ${ACUBE_BIN}
-	${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME}_${f} ${STAGEDIR}${PREFIX}/bin
-	${INSTALL_PROGRAM} ${BUILD_WRKSRC}/ac_${f} ${STAGEDIR}${PREFIX}/libexec/${PORTNAME}_${f}
+.for f in ${PLIST_FILES:Mbin/*}
+	${INSTALL_SCRIPT} ${WRKDIR}/${f:T} ${STAGEDIR}${PREFIX}/${f}
 .endfor
-	@${MKDIR} ${STAGEDIR}${DATADIR}
-	cd ${WRKSRC} && ${COPYTREE_SHARE} "${PORTDATA}" ${STAGEDIR}${DATADIR}
-	@${MKDIR} ${STAGEDIR}${DOCSDIR}
-	cd ${WRKSRC}/docs && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR}
-.if ${PORT_OPTIONS:MCLIENT}
-	${INSTALL_DATA} ${WRKSRC}/docs/images/icon.png ${STAGEDIR}${PREFIX}/share/pixmaps/${PORTNAME}.png
-.endif
-
-post-install:
-.for f in ${ACUBE_BIN}
-	@${ECHO_CMD} bin/${PORTNAME}_${f} >> ${TMPPLIST}
-	@${ECHO_CMD} libexec/${PORTNAME}_${f} >> ${TMPPLIST}
+.for f in ${PLIST_FILES:Mlibexec/*}
+	${INSTALL_PROGRAM} ${BUILD_WRKSRC}/${f:T:S/${PORTNAME}/ac/} \
+		${STAGEDIR}${PREFIX}/${f}
 .endfor
 .if ${PORT_OPTIONS:MCLIENT}
-	@${ECHO_CMD} share/pixmaps/${PORTNAME}.png >> ${TMPPLIST}
+	${INSTALL_DATA} ${WRKSRC}/docs/images/icon.png \
+		${STAGEDIR}${PREFIX}/share/pixmaps/${PORTNAME}.png
 .endif
+	(cd ${WRKSRC} && ${COPYTREE_SHARE} "${PORTDATA}" ${STAGEDIR}${DATADIR})
+	(cd ${WRKSRC}/docs && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
 
 .include <bsd.port.mk>

Added: head/games/assaultcube/files/patch-source_src_bot_bot_waypoint.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/assaultcube/files/patch-source_src_bot_bot_waypoint.cpp	Sun Mar 15 11:51:06 2015	(r381324)
@@ -0,0 +1,11 @@
+--- source/src/bot/bot_waypoint.cpp.orig	2013-11-10 22:50:03.000000000 +0400
++++ source/src/bot/bot_waypoint.cpp	2015-02-13 07:33:14.000000000 +0400
+@@ -848,7 +848,7 @@
+ 
+      if (!pWP)
+      {
+-          conoutf("Error: Couldnīt find near waypoint");
++          conoutf("Error: Couldn't find near waypoint");
+           return;
+      }
+ 

Modified: head/games/bloodfrontier/Makefile
==============================================================================
--- head/games/bloodfrontier/Makefile	Sun Mar 15 11:50:30 2015	(r381323)
+++ head/games/bloodfrontier/Makefile	Sun Mar 15 11:51:06 2015	(r381324)
@@ -3,7 +3,7 @@
 
 PORTNAME=	bloodfrontier
 DISTVERSION=	B2
-PORTREVISION=	9
+PORTREVISION=	10
 CATEGORIES=	games
 MASTER_SITES=	SF/${PORTNAME}/Blood%20Frontier%20Beta%202
 DISTNAME=	${PORTNAME}-${DISTVERSION}-linux
@@ -18,11 +18,10 @@ GNU_CONFIGURE=	yes
 CONFIGURE_WRKSRC=	${WRKSRC}/src/enet
 BUILD_WRKSRC=	${WRKSRC}/src
 WRKSRC=		${WRKDIR}/${PORTNAME}
-USE_XORG=	x11
 
-ALL_TARGET=	libenet ${BINARIES}
+ALL_TARGET=	libenet
 
-SUB_FILES=	bfclient bfserver
+SUB_FILES=	${PLIST_FILES:Mbin/*:T}
 
 PORTDATA=	*
 
@@ -32,7 +31,15 @@ OPTIONS_MULTI_COMPONENTS=CLIENT DEDICATE
 OPTIONS_DEFAULT=	CLIENT DEDICATED OPTIMIZED_CFLAGS
 
 CLIENT_DESC=	Build client
+CLIENT_USE=			GL=gl SDL=image,mixer,sdl XORG=x11
+CLIENT_ALL_TARGET=		client
+CLIENT_PLIST_FILES=		bin/bfclient libexec/bfclient \
+				share/pixmaps/${PORTNAME}.ico
 DEDICATED_DESC= Build dedicated server
+DEDICATED_PLIST_FILES=		bin/bfserver libexec/bfserver
+DEDICATED_ALL_TARGET=		server
+OPTIMIZED_CFLAGS_CFLAGS=	-O3 -fomit-frame-pointer
+OPTIMIZED_CFLAGS_CXXFLAGS=	-O3 -fomit-frame-pointer
 
 .include <bsd.port.options.mk>
 
@@ -41,11 +48,6 @@ BROKEN=		Does not compile on ia64, power
 .endif
 
 .if ${PORT_OPTIONS:MCLIENT}
-USE_GL=		yes
-USE_SDL=	image mixer sdl
-PLIST_FILES+=	bin/bfclient libexec/bfclient share/pixmaps/${PORTNAME}.ico
-BINARIES+=	client
-
 DESKTOP_ENTRIES="Blood Frontier" \
 		"${COMMENT}" \
 		"${PREFIX}/share/pixmaps/${PORTNAME}.ico" \
@@ -54,25 +56,17 @@ DESKTOP_ENTRIES="Blood Frontier" \
 		""
 .endif
 
-.if ${PORT_OPTIONS:MDEDICATED}
-PLIST_FILES+=	bin/bfserver libexec/bfserver
-BINARIES+=	server
-.endif
-
-.if ${PORT_OPTIONS:MOPTIMIZED_CFLAGS}
-CFLAGS+=	-O3 -fomit-frame-pointer
-CXXFLAGS+=	-O3 -fomit-frame-pointer
-.endif
-
 do-install:
-.for f in ${BINARIES}
-	${INSTALL_SCRIPT} ${WRKDIR}/bf${f} ${STAGEDIR}${PREFIX}/bin
-	${INSTALL_PROGRAM} ${BUILD_WRKSRC}/bf${f} ${STAGEDIR}${PREFIX}/libexec
+.for f in ${PLIST_FILES:Mbin/*}
+	${INSTALL_SCRIPT} ${WRKDIR}/${f:T} ${STAGEDIR}${PREFIX}/${f}
+.endfor
+.for f in ${PLIST_FILES:Mlibexec/*}
+	${INSTALL_PROGRAM} ${BUILD_WRKSRC}/${f:T} ${STAGEDIR}${PREFIX}/${f:H}
 .endfor
 .if ${PORT_OPTIONS:MCLIENT}
-	${INSTALL_DATA} ${WRKSRC}/src/${PORTNAME}.ico ${STAGEDIR}${PREFIX}/share/pixmaps
+	${INSTALL_DATA} ${WRKSRC}/src/${PORTNAME}.ico \
+		${STAGEDIR}${PREFIX}/share/pixmaps
 .endif
-	${MKDIR} ${STAGEDIR}${DATADIR}
-	cd ${WRKSRC}/data && ${COPYTREE_SHARE} "." ${STAGEDIR}${DATADIR}/
+	(cd ${WRKSRC}/data && ${COPYTREE_SHARE} "." ${STAGEDIR}${DATADIR})
 
 .include <bsd.port.mk>

Modified: head/games/cube/Makefile
==============================================================================
--- head/games/cube/Makefile	Sun Mar 15 11:50:30 2015	(r381323)
+++ head/games/cube/Makefile	Sun Mar 15 11:51:06 2015	(r381324)
@@ -3,7 +3,7 @@
 
 PORTNAME=	cube
 DISTVERSION=	2005_08_29
-PORTREVISION=	15
+PORTREVISION=	16
 CATEGORIES=	games
 MASTER_SITES=	SF/${PORTNAME}/${PORTNAME}/${DISTVERSION}
 DISTFILES=	${CUBE_DATA} ${CUBE_SRC}
@@ -16,12 +16,11 @@ LIB_DEPENDS=	libenet.so:${PORTSDIR}/net/
 USES=		dos2unix gmake
 EXTRACT_AFTER_ARGS=--exclude enet
 ALL_TARGET=	#
-USE_XORG=	x11
 
 CFLAGS+=	-fsigned-char
 WRKSRC=		${WRKDIR}/${PORTNAME}_source/src
 
-SUB_FILES=	cube_client cube_server
+SUB_FILES=	${ALL_TARGET:S/^/${PORTNAME}_/}
 
 CUBE_DATA=	${PORTNAME}_${DISTVERSION}_unix.tar.gz
 CUBE_SRC=	${PORTNAME}_${DISTVERSION}_src.zip
@@ -30,40 +29,28 @@ OPTIONS_DEFINE=	OPTIMIZED_CFLAGS DOCS
 OPTIONS_MULTI=	FLAVOR
 OPTIONS_MULTI_FLAVOR=	CLIENT SERVER
 OPTIONS_DEFAULT=	CLIENT SERVER
+OPTIONS_SUB=	yes
 
 FLAVOR_DESC=	Clients and servers
 CLIENT_DESC=	Build client
-SERVER_DESC=	Build dedicated server
-
-OPTIONS_SUB=	yes
-
+CLIENT_USE=			GL=glu SDL=image,mixer,sdl XORG=x11
+CLIENT_LDFLAGS=			-lX11
+CLIENT_ALL_TARGET=		client
 OPTIMIZED_CFLAGS_CFLAGS=	-O3 -fomit-frame-pointer
+SERVER_DESC=	Build dedicated server
+SERVER_ALL_TARGET=		server
 
 .include <bsd.port.options.mk>
 
-.if ${PORT_OPTIONS:MCLIENT}
-USE_GL=		glu
-USE_SDL=	image mixer sdl
-ALL_TARGET+=	client
-CUBE_BIN+=	client
-LDFLAGS+=	-lX11
-.endif
-
-.if ${PORT_OPTIONS:MSERVER}
-ALL_TARGET+=	server
-CUBE_BIN+=	server
-.endif
-
 do-install:
-.for f in ${CUBE_BIN}
+.for f in ${ALL_TARGET}
 	${INSTALL_SCRIPT} ${WRKDIR}/cube_${f} ${STAGEDIR}${PREFIX}/bin
 	${INSTALL_PROGRAM} ${WRKSRC}/cube_${f} ${STAGEDIR}${PREFIX}/libexec
 .endfor
-	@${MKDIR} ${STAGEDIR}${DATADIR}
-	@(cd ${WRKDIR}/cube && ${COPYTREE_SHARE} "data packages" ${STAGEDIR}${DATADIR})
+	(cd ${WRKDIR}/cube && ${COPYTREE_SHARE} \
+		"data packages" ${STAGEDIR}${DATADIR})
+	(cd ${WRKDIR}/cube/docs && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
 	${INSTALL_DATA} ${WRKDIR}/cube/autoexec.cfg ${STAGEDIR}${DATADIR}
-	@${MKDIR} ${STAGEDIR}${DOCSDIR}
 	${INSTALL_DATA} ${WRKDIR}/cube/readme.html ${STAGEDIR}${DOCSDIR}
-	(cd ${WRKDIR}/cube/docs && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
 
 .include <bsd.port.mk>

Modified: head/games/redeclipse/Makefile
==============================================================================
--- head/games/redeclipse/Makefile	Sun Mar 15 11:50:30 2015	(r381323)
+++ head/games/redeclipse/Makefile	Sun Mar 15 11:51:06 2015	(r381324)
@@ -3,7 +3,7 @@
 
 PORTNAME=	redeclipse
 PORTVERSION=	1.4
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	games
 MASTER_SITES=	SF/${PORTNAME}/${PORTNAME}_${PORTVERSION:C/^([0-9]+\.[0-9]+)\..*/\1/}
 DISTNAME=	${PORTNAME}_${PORTVERSION}_nix
@@ -14,7 +14,7 @@ COMMENT=	Single-player and multi-player 
 LICENSE_COMB=	multi
 LICENSE=	MIT ZLIB
 
-MANUAL_PACKAGE_BUILD=	huge
+MANUAL_PACKAGE_BUILD=	huge (734MiB)
 
 USES=		tar:bzip2 gmake
 GNU_CONFIGURE=	yes
@@ -27,9 +27,9 @@ WRKSRC=		${WRKDIR}/${PORTNAME}-${PORTVER
 
 ALL_TARGET=	libenet
 
-SUB_FILES=	${PORTNAME} ${PORTNAME}_server
+SUB_FILES=	${PLIST_FILES:Mbin/*:T}
 
-PORTDATA=	*
+PORTDATA=	game data
 PORTDOCS=	*
 PLIST_DIRS=	%%DATADIR%%/data/brush
 
@@ -39,7 +39,15 @@ OPTIONS_MULTI_COMPONENTS=CLIENT DEDICATE
 OPTIONS_DEFAULT=CLIENT DEDICATED OPTIMIZED_CFLAGS
 
 CLIENT_DESC=	Build client
+CLIENT_USE=			GL=gl SDL=image,mixer,sdl XORG=x11
+CLIENT_ALL_TARGET=		client
+CLIENT_PLIST_FILES=		bin/${PORTNAME} libexec/${PORTNAME} \
+				share/pixmaps/${PORTNAME}.ico
 DEDICATED_DESC=	Build dedicated server
+DEDICATED_ALL_TARGET=		server
+DEDICATED_PLIST_FILES=		bin/${PORTNAME}_server libexec/${PORTNAME}_server
+OPTIMIZED_CFLAGS_CFLAGS=	-O3 -fomit-frame-pointer
+OPTIMIZED_CFLAGS_CXXFLAGS=	-O3 -fomit-frame-pointer
 
 .include <bsd.port.options.mk>
 
@@ -48,12 +56,6 @@ BROKEN=		does not build on sparc64
 .endif
 
 .if ${PORT_OPTIONS:MCLIENT}
-USE_GL=		yes
-USE_SDL=	image mixer sdl
-PLIST_FILES+=	bin/${PORTNAME} libexec/${PORTNAME} share/pixmaps/${PORTNAME}.ico
-BINARIES+=	${PORTNAME}
-ALL_TARGET+=	client
-
 DESKTOP_ENTRIES="Red Eclipse" \
 		"${COMMENT}" \
 		"${PREFIX}/share/pixmaps/${PORTNAME}.ico" \
@@ -62,28 +64,19 @@ DESKTOP_ENTRIES="Red Eclipse" \
 		""
 .endif
 
-.if ${PORT_OPTIONS:MDEDICATED}
-PLIST_FILES+=	bin/${PORTNAME}_server libexec/${PORTNAME}_server
-BINARIES+=	${PORTNAME}_server
-ALL_TARGET+=	server
-.endif
-
-.if ${PORT_OPTIONS:MOPTIMIZED_CFLAGS}
-CFLAGS+=	-O3 -fomit-frame-pointer
-CXXFLAGS+=	-O3 -fomit-frame-pointer
-.endif
-
 do-install:
-.for f in ${BINARIES}
-	${INSTALL_SCRIPT} ${WRKDIR}/${f} ${STAGEDIR}${PREFIX}/bin
-	${INSTALL_PROGRAM} ${BUILD_WRKSRC}/${f} ${STAGEDIR}${PREFIX}/libexec
+.for f in ${PLIST_FILES:Mbin/*}
+	${INSTALL_SCRIPT} ${WRKDIR}/${f:T} ${STAGEDIR}${PREFIX}/${f}
+.endfor
+.for f in ${PLIST_FILES:Mlibexec/*}
+	${INSTALL_PROGRAM} ${BUILD_WRKSRC}/${f:T} \
+		${STAGEDIR}${PREFIX}/${f:H}
 .endfor
-	${MKDIR} ${STAGEDIR}${DOCSDIR}
-	cd ${WRKSRC}/doc && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR}/
-	${MKDIR} ${STAGEDIR}${DATADIR}
-	cd ${WRKSRC} && ${COPYTREE_SHARE} "game data" ${STAGEDIR}${DATADIR}/
 .if ${PORT_OPTIONS:MCLIENT}
-	${INSTALL_DATA} ${WRKSRC}/src/${PORTNAME}.ico ${STAGEDIR}${PREFIX}/share/pixmaps/
+	${INSTALL_DATA} ${WRKSRC}/src/${PORTNAME}.ico \
+		${STAGEDIR}${PREFIX}/share/pixmaps
 .endif
+	(cd ${WRKSRC} && ${COPYTREE_SHARE} "${PORTDATA}" ${STAGEDIR}${DATADIR})
+	(cd ${WRKSRC}/doc && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
 
 .include <bsd.port.mk>

Modified: head/games/sauerbraten/Makefile
==============================================================================
--- head/games/sauerbraten/Makefile	Sun Mar 15 11:50:30 2015	(r381323)
+++ head/games/sauerbraten/Makefile	Sun Mar 15 11:51:06 2015	(r381324)
@@ -3,7 +3,7 @@
 
 PORTNAME=	sauerbraten
 PORTVERSION=	20130203
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	games
 MASTER_SITES=	SF/${PORTNAME}/${PORTNAME}/2013_01_04
 DISTNAME=	${PORTNAME}_2013_02_03_collect_edition_linux
@@ -30,37 +30,29 @@ PLIST_DIRS=	%%DATADIR%%/packages/brush
 OPTIONS_MULTI=	BUILD
 OPTIONS_MULTI_BUILD=	CLIENT DEDICATED MASTER
 OPTIONS_DEFAULT=	CLIENT DEDICATED
-CLIENT_DESC=	Build client
-DEDICATED_DESC=	Build dedicated server
-MASTER_DESC=	Build master server
 
-SUB_FILES=	sauer_client sauer_master sauer_server pkg-message
+SUB_FILES=	pkg-message ${PLIST_FILES:Mbin/*:T}
 
 OPTIONS_DEFINE=	DOCS
 
+CLIENT_DESC=	Build client
+CLIENT_USE=		GL=gl SDL=image,mixer,sdl XORG=x11
+CLIENT_ALL_TARGET=	client
+CLIENT_PLIST_FILES=	bin/sauer_client libexec/sauer_client
+DEDICATED_DESC=	Build dedicated server
+DEDICATED_ALL_TARGET=	server
+DEDICATED_PLIST_FILES=	bin/sauer_server libexec/sauer_server
+MASTER_DESC=	Build master server
+MASTER_ALL_TARGET=	master
+
 .include <bsd.port.options.mk>
 
 .if ${PORT_OPTIONS:MCLIENT}
-USE_GL=		yes
-USE_SDL=	image mixer sdl
-ALL_TARGET+=	client
-SAUER_BIN+=	client
-
 DESKTOP_ENTRIES="Sauerbraten" "${COMMENT}" \
 			"${PREFIX}/share/${PORTNAME}/data/cube.png" "sauer_client" \
 				"Game;" false
 .endif
 
-.if ${PORT_OPTIONS:MDEDICATED}
-ALL_TARGET+=	server
-SAUER_BIN+=	server
-.endif
-
-.if ${PORT_OPTIONS:MMASTER}
-ALL_TARGET+=	master
-SAUER_BIN+=	master
-.endif
-
 post-extract:
 	@${FIND} ${WRKSRC} -type d -name CVS -type d -print0 | \
 		${XARGS} -0 ${RM} -R
@@ -70,19 +62,13 @@ post-patch:
 		${CONFIGURE_WRKSRC}/${CONFIGURE_SCRIPT}
 
 do-install:
-.for f in ${SAUER_BIN}
-	${INSTALL_SCRIPT} ${WRKDIR}/sauer_${f} ${STAGEDIR}${PREFIX}/bin
-	${INSTALL_PROGRAM} ${BUILD_WRKSRC}/sauer_${f} ${STAGEDIR}${PREFIX}/libexec
+.for f in ${PLIST_FILES:Mbin/*}
+	${INSTALL_SCRIPT} ${WRKDIR}/${f:T} ${STAGEDIR}${PREFIX}/${f}
 .endfor
-	${MKDIR} ${STAGEDIR}${DATADIR}
-	cd ${WRKSRC} && ${COPYTREE_SHARE} "${PORTDATA}" ${STAGEDIR}${DATADIR}
-	${MKDIR} ${STAGEDIR}${DOCSDIR}
-	cd ${WRKSRC}/docs && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR}
-
-post-install:
-.for f in ${SAUER_BIN}
-	@${ECHO_CMD} bin/sauer_${f} >> ${TMPPLIST}
-	@${ECHO_CMD} libexec/sauer_${f} >> ${TMPPLIST}
+.for f in ${PLIST_FILES:Mlibexec/*}
+	${INSTALL_PROGRAM} ${BUILD_WRKSRC}/${f:T} ${STAGEDIR}${PREFIX}/${f:H}
 .endfor
+	(cd ${WRKSRC} && ${COPYTREE_SHARE} "${PORTDATA}" ${STAGEDIR}${DATADIR})
+	(cd ${WRKSRC}/docs && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
 
 .include <bsd.port.mk>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201503151151.t2FBp78j007457>