2013-05-31 16:40:56 +02:00
|
|
|
# Created by: Alexey Dokuchaev <danfe@FreeBSD.org>
|
2005-06-03 13:09:13 +02:00
|
|
|
# $FreeBSD$
|
|
|
|
|
|
|
|
PORTNAME= nexuiz
|
2009-10-04 19:18:02 +02:00
|
|
|
PORTVERSION= 2.5.2
|
2013-10-17 03:57:47 +02:00
|
|
|
PORTREVISION= 13
|
2005-06-03 13:09:13 +02:00
|
|
|
CATEGORIES= games
|
2010-12-02 06:43:36 +01:00
|
|
|
MASTER_SITES= SF/${PORTNAME}/NexuizRelease/Nexuiz%20${PORTVERSION} \
|
|
|
|
SF/${PORTNAME}/mappack/nexmappack_r2:mappack
|
2006-06-28 12:57:21 +02:00
|
|
|
DISTNAME= ${PORTNAME}-${PORTVERSION:S/.//g}
|
2007-06-13 14:34:55 +02:00
|
|
|
DISTFILES= ${DISTNAME}${EXTRACT_SUFX}
|
2005-06-03 13:09:13 +02:00
|
|
|
|
2011-09-14 05:02:55 +02:00
|
|
|
MAINTAINER= amdmi3@FreeBSD.org
|
2013-05-31 16:40:56 +02:00
|
|
|
COMMENT= Fast-paced, chaotic, and intense multiplayer first person shooter
|
2005-06-03 13:09:13 +02:00
|
|
|
|
2013-10-17 03:57:47 +02:00
|
|
|
LIB_DEPENDS= libcurl.so:${PORTSDIR}/ftp/curl \
|
|
|
|
libjpeg.so:${PORTSDIR}/graphics/jpeg
|
2012-05-12 15:01:55 +02:00
|
|
|
|
2010-12-02 06:43:36 +01:00
|
|
|
LICENSE= GPLv2
|
|
|
|
|
2012-05-12 15:01:55 +02:00
|
|
|
MANUAL_PACKAGE_BUILD= huge
|
2005-06-03 13:09:13 +02:00
|
|
|
|
2014-03-10 15:49:26 +01:00
|
|
|
SUES= zip
|
2005-10-12 17:51:24 +02:00
|
|
|
WRKSRC= ${WRKDIR}/Nexuiz/sources/darkplaces
|
2008-06-18 21:18:44 +02:00
|
|
|
MAKEFILE= BSDmakefile
|
|
|
|
MAKE_ARGS= DP_FS_BASEDIR="${DATADIR}" CC="${CC}" \
|
2009-10-08 18:23:32 +02:00
|
|
|
DP_PRELOAD_DEPENDENCIES=yes DP_LINK_TO_LIBJPEG=yes \
|
|
|
|
CFLAGS_LIBJPEG="-I${LOCALBASE}/include" \
|
2012-05-12 15:01:55 +02:00
|
|
|
OPTIM_RELEASE="${CFLAGS} -fno-strict-aliasing -funroll-loops" \
|
|
|
|
STRIP="${STRIP_CMD}"
|
|
|
|
MAKE_JOBS_UNSAFE=yes
|
2013-10-17 03:57:47 +02:00
|
|
|
ALL_TARGET= # empty
|
|
|
|
|
|
|
|
PORTDATA= *
|
2005-06-03 13:09:13 +02:00
|
|
|
|
2013-05-31 16:40:56 +02:00
|
|
|
OPTIONS_DEFINE= MAPPACK
|
2013-10-17 03:57:47 +02:00
|
|
|
OPTIONS_MULTI= COMPONENTS
|
|
|
|
OPTIONS_MULTI_COMPONENTS=CLIENT SDL_CLIENT DEDICATED
|
|
|
|
OPTIONS_DEFAULT=MAPPACK CLIENT SDL_CLIENT DEDICATED
|
|
|
|
|
2013-05-31 16:40:56 +02:00
|
|
|
MAPPACK_DESC= Install community map pack
|
2013-10-17 03:57:47 +02:00
|
|
|
CLIENT_DESC= Build GLX client
|
|
|
|
SDL_CLIENT_DESC=Build SDL client
|
|
|
|
DEDICATED_DESC= Build dedicated server
|
2005-06-03 13:09:13 +02:00
|
|
|
|
2013-10-17 03:57:47 +02:00
|
|
|
CLIENT_LIB_DEPENDS= libmodplug.so:${PORTSDIR}/audio/libmodplug \
|
|
|
|
libpng.so:${PORTSDIR}/graphics/png \
|
|
|
|
libtheora.so:${PORTSDIR}/multimedia/libtheora
|
|
|
|
SDL_CLIENT_LIB_DEPENDS= ${CLIENT_LIB_DEPENDS}
|
|
|
|
MAPPACK_DISTFILES= nexmappack_r2${EXTRACT_SUFX}:mappack
|
2005-06-03 13:09:13 +02:00
|
|
|
|
2013-05-31 16:40:56 +02:00
|
|
|
.include <bsd.port.options.mk>
|
2009-08-11 00:27:16 +02:00
|
|
|
|
2013-05-31 16:40:56 +02:00
|
|
|
.if ${PORT_OPTIONS:MCLIENT}
|
- Remove unneeded dependency from gtk12/gtk20 [1]
- Remove USE_XLIB/USE_X_PREFIX/USE_XPM in favor of USE_XORG
- Remove X11BASE support in favor of LOCALBASE or PREFIX
- Use USE_LDCONFIG instead of INSTALLS_SHLIB
- Remove unneeded USE_GCC 3.4+
Thanks to all Helpers:
Dmitry Marakasov, Chess Griffin, beech@, dinoex, rafan, gahr,
ehaupt, nox, itetcu, flz, pav
PR: 116263
Tested on: pointyhat
Approved by: portmgr (pav)
2008-04-19 19:56:05 +02:00
|
|
|
USE_GL= glut
|
|
|
|
USE_XORG= x11 xpm xxf86vm xxf86dga xext
|
2005-06-03 13:09:13 +02:00
|
|
|
ALL_TARGET+= cl-release
|
2013-10-17 03:57:47 +02:00
|
|
|
PLIST_FILES+= bin/${PORTNAME}-glx
|
|
|
|
|
|
|
|
DESKTOP_ENTRIES="Nexuiz" \
|
|
|
|
"${COMMENT}" \
|
|
|
|
"${PREFIX}/share/pixmaps/${PORTNAME}.ico" \
|
|
|
|
"${PORTNAME}-glx" \
|
|
|
|
"Game;Shooter;" \
|
|
|
|
""
|
2005-06-03 13:09:13 +02:00
|
|
|
.endif
|
|
|
|
|
2013-05-31 16:40:56 +02:00
|
|
|
.if ${PORT_OPTIONS:MSDL_CLIENT}
|
2005-06-03 13:09:13 +02:00
|
|
|
USE_SDL= sdl
|
|
|
|
ALL_TARGET+= sdl-release
|
2013-10-17 03:57:47 +02:00
|
|
|
PLIST_FILES+= bin/${PORTNAME}-sdl
|
|
|
|
|
|
|
|
# override of DESKTOP_ENTRIES for GLX client is intented
|
|
|
|
DESKTOP_ENTRIES="Nexuiz" \
|
|
|
|
"${COMMENT}" \
|
|
|
|
"${PREFIX}/share/pixmaps/${PORTNAME}.ico" \
|
|
|
|
"${PORTNAME}-sdl" \
|
|
|
|
"Game;Shooter;" \
|
|
|
|
""
|
2005-06-03 13:09:13 +02:00
|
|
|
.endif
|
|
|
|
|
2013-10-17 03:57:47 +02:00
|
|
|
.if ${PORT_OPTIONS:MCLIENT} || ${PORT_OPTIONS:MSDL_CLIENT}
|
|
|
|
PLIST_FILES+= share/pixmaps/${PORTNAME}.ico
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if ${PORT_OPTIONS:MDEDICATED}
|
2005-06-03 13:09:13 +02:00
|
|
|
ALL_TARGET+= sv-release
|
2013-10-17 03:57:47 +02:00
|
|
|
PLIST_FILES+= bin/${PORTNAME}-dedicated
|
2005-06-03 13:09:13 +02:00
|
|
|
.endif
|
|
|
|
|
2008-06-18 21:38:27 +02:00
|
|
|
post-extract:
|
2013-10-17 03:57:47 +02:00
|
|
|
@${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} \
|
|
|
|
${WRKDIR}/Nexuiz/sources/enginesource20091001.zip \
|
2005-10-12 17:51:24 +02:00
|
|
|
-d ${WRKDIR}/Nexuiz/sources
|
2008-06-18 21:38:27 +02:00
|
|
|
|
|
|
|
post-patch:
|
2009-08-11 00:27:16 +02:00
|
|
|
@${REINPLACE_CMD} -e 's,/usr/X11R6,${LOCALBASE},' \
|
|
|
|
${WRKSRC}/${MAKEFILE} ${WRKSRC}/makefile.inc
|
|
|
|
@${REINPLACE_CMD} -e '/LDFLAGS_BSDSV/s,$$,-L${LOCALBASE}/lib,' \
|
|
|
|
${WRKSRC}/makefile.inc
|
2010-05-23 14:38:45 +02:00
|
|
|
# Fix for libpng 1.4
|
|
|
|
@${REINPLACE_CMD} -e 's,gray_1_2_4_to_8,expand_&,g' \
|
|
|
|
${WRKSRC}/image_png.c
|
2005-06-03 13:09:13 +02:00
|
|
|
|
|
|
|
do-install:
|
2013-10-17 03:57:47 +02:00
|
|
|
.if ${PORT_OPTIONS:MCLIENT}
|
|
|
|
${INSTALL_PROGRAM} ${WRKDIR}/Nexuiz/sources/darkplaces/darkplaces-glx ${STAGEDIR}${PREFIX}/bin/${PORTNAME}-glx
|
|
|
|
.endif
|
|
|
|
.if ${PORT_OPTIONS:MSDL_CLIENT}
|
|
|
|
${INSTALL_PROGRAM} ${WRKDIR}/Nexuiz/sources/darkplaces/darkplaces-sdl ${STAGEDIR}${PREFIX}/bin/${PORTNAME}-sdl
|
|
|
|
.endif
|
|
|
|
.if ${PORT_OPTIONS:MCLIENT} || ${PORT_OPTIONS:MSDL_CLIENT}
|
|
|
|
${INSTALL_DATA} ${WRKDIR}/Nexuiz/sources/darkplaces/nexuiz.ico ${STAGEDIR}${PREFIX}/share/pixmaps
|
2007-06-13 14:34:55 +02:00
|
|
|
.endif
|
2013-10-17 03:57:47 +02:00
|
|
|
.if ${PORT_OPTIONS:MDEDICATED}
|
|
|
|
${INSTALL_PROGRAM} ${WRKDIR}/Nexuiz/sources/darkplaces/darkplaces-dedicated ${STAGEDIR}${PREFIX}/bin/${PORTNAME}-dedicated
|
|
|
|
cd ${WRKDIR}/Nexuiz && ${COPYTREE_SHARE} "server" ${STAGEDIR}${DATADIR}
|
2009-10-04 19:18:02 +02:00
|
|
|
# Fixup lost +x permissions on scripts after COPYTREE_SHARE
|
2013-10-17 03:57:47 +02:00
|
|
|
${FIND} ${STAGEDIR}${DATADIR}/server -type f -name *.sh -o -name rcon*.pl | \
|
2009-08-11 00:27:16 +02:00
|
|
|
${XARGS} ${CHMOD} +x
|
|
|
|
.endif
|
2013-10-17 03:57:47 +02:00
|
|
|
cd ${WRKDIR}/Nexuiz && ${COPYTREE_SHARE} "data havoc" ${STAGEDIR}${DATADIR}
|
|
|
|
.if ${PORT_OPTIONS:MMAPPACK}
|
|
|
|
${INSTALL_DATA} ${WRKDIR}/data/*.pk3 ${STAGEDIR}${DATADIR}/data
|
|
|
|
.endif
|
2005-06-03 13:09:13 +02:00
|
|
|
|
2013-05-31 16:40:56 +02:00
|
|
|
.include <bsd.port.mk>
|