aboutsummaryrefslogtreecommitdiff
path: root/games/sdlquake2
diff options
context:
space:
mode:
authorBaptiste Daroussin <bapt@FreeBSD.org>2012-06-12 16:35:45 +0000
committerBaptiste Daroussin <bapt@FreeBSD.org>2012-06-12 16:35:45 +0000
commit3a283e24f296371e9b753c09e3e62a92ef3d8703 (patch)
tree88e0a2bbddafb5c9bdc18e8e02c5e59fb9f9d471 /games/sdlquake2
parent7a0a8929bea1c510b4f30261d294a78b556b49d7 (diff)
downloadports-3a283e24f296371e9b753c09e3e62a92ef3d8703.tar.gz
ports-3a283e24f296371e9b753c09e3e62a92ef3d8703.zip
Convert to new options framework
Notes
Notes: svn path=/head/; revision=299119
Diffstat (limited to 'games/sdlquake2')
-rw-r--r--games/sdlquake2/Makefile24
1 files changed, 13 insertions, 11 deletions
diff --git a/games/sdlquake2/Makefile b/games/sdlquake2/Makefile
index 50fe684b20b7..2282451d9b8c 100644
--- a/games/sdlquake2/Makefile
+++ b/games/sdlquake2/Makefile
@@ -19,9 +19,11 @@ LIB_DEPENDS= execinfo.1:${PORTSDIR}/devel/libexecinfo
USE_BZIP2= yes
USE_GMAKE= yes
-OPTIONS= CLIENT "Build client" on \
- DEDICATED "Build dedicated server" on \
- GAME "Build a main game .so file" off
+OPTIONS_DEFINE= CLIENT DEDICATED GAME
+OPTIONS_DEFAULT= CLIENT DEDICATED
+CLIENT_DESC= Build client
+DEDICATED_DESC= Build dedicated server
+GAME_DESC= Build a main game .so file
LIBDIR= ${PREFIX}/lib/${PORTNAME}
MAKE_ENV= LIBDIR="${LIBDIR}"
@@ -29,9 +31,9 @@ PLIST_SUB= LIBDIR=${LIBDIR:S/${PREFIX}\///}
.include "${.CURDIR}/../quake2-data/Makefile.include"
-.include <bsd.port.pre.mk>
+.include <bsd.port.options.mk>
-.if defined(WITH_CLIENT)
+.if ${PORT_OPTIONS:MCLIENT}
LIB_DEPENDS+= jpeg.11:${PORTSDIR}/graphics/jpeg \
png15:${PORTSDIR}/graphics/png
USE_GL= yes
@@ -43,14 +45,14 @@ PLIST_SUB+= CLIENT=""
PLIST_SUB+= CLIENT="@comment "
.endif
-.if defined(WITH_DEDICATED)
+.if ${PORT_OPTIONS:MDEDICATED}
MAKE_ENV+= BUILD_DEDICATED=YES
PLIST_SUB+= DEDICATED=""
.else
PLIST_SUB+= DEDICATED="@comment "
.endif
-.if defined(WITH_GAME)
+.if ${PORT_OPTIONS:MGAME}
MAKE_ENV+= BUILD_GAME=YES
PLIST_SUB+= GAME=""
.else
@@ -59,14 +61,14 @@ PLIST_SUB+= GAME="@comment "
do-install:
${MKDIR} ${LIBDIR}/baseq2
-.if defined(WITH_CLIENT)
+.if ${PORT_OPTIONS:MCLIENT}
${INSTALL_PROGRAM} ${WRKSRC}/quake2 ${PREFIX}/bin/${PORTNAME}
${INSTALL_PROGRAM} ${WRKSRC}/ref_sdlgl.so ${LIBDIR}
.endif
-.if defined(WITH_DEDICATED)
+.if ${PORT_OPTIONS:MDEDICATED}
${INSTALL_PROGRAM} ${WRKSRC}/q2ded ${PREFIX}/bin/${PORTNAME}-ded
.endif
-.if defined(WITH_GAME)
+.if ${PORT_OPTIONS:MGAME}
${INSTALL_PROGRAM} ${WRKSRC}/baseq2/game.so ${LIBDIR}/baseq2
.endif
@@ -75,4 +77,4 @@ post-install:
@${CAT} ${PKGMESSAGE}
@${ECHO_CMD}
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>