diff options
author | amdmi3 <amdmi3@FreeBSD.org> | 2013-11-08 08:24:43 +0800 |
---|---|---|
committer | amdmi3 <amdmi3@FreeBSD.org> | 2013-11-08 08:24:43 +0800 |
commit | 42ff453797feebc7645bc6d2337c921ecbdc78dc (patch) | |
tree | f8f98db73fcdab6f2cab104b92251f07b9d82719 | |
parent | f8e25c2a81a8030bc4f14257b420852efbec8bbd (diff) | |
download | freebsd-ports-gnome-42ff453797feebc7645bc6d2337c921ecbdc78dc.tar.gz freebsd-ports-gnome-42ff453797feebc7645bc6d2337c921ecbdc78dc.tar.zst freebsd-ports-gnome-42ff453797feebc7645bc6d2337c921ecbdc78dc.zip |
- Support staging
- Use new LIB_DEPENDS syntax
- Add DESKTOP_ENTRIES
-rw-r--r-- | games/xonotic/Makefile | 63 |
1 files changed, 34 insertions, 29 deletions
diff --git a/games/xonotic/Makefile b/games/xonotic/Makefile index cab27cea4da2..61d27b06b457 100644 --- a/games/xonotic/Makefile +++ b/games/xonotic/Makefile @@ -9,11 +9,11 @@ MASTER_SITES= http://nl.dl.xonotic.org/ \ http://mirror.bitmissile.com/xonotic/releases/ MAINTAINER= amdmi3@FreeBSD.org -COMMENT= A fast-paced, chaotic, and intense multiplayer first person shooter +COMMENT= Fast-paced, chaotic, and intense multiplayer first person shooter -LIB_DEPENDS= curl:${PORTSDIR}/ftp/curl \ - png15:${PORTSDIR}/graphics/png \ - jpeg:${PORTSDIR}/graphics/jpeg +LIB_DEPENDS= libcurl.so:${PORTSDIR}/ftp/curl \ + libpng.so:${PORTSDIR}/graphics/png \ + libjpeg.so:${PORTSDIR}/graphics/jpeg MANUAL_PACKAGE_BUILD= huge @@ -26,40 +26,45 @@ MAKE_ARGS= DP_FS_BASEDIR="${DATADIR}" \ OPTIM_RELEASE="${CFLAGS} -fno-strict-aliasing -funroll-loops" \ STRIP="${STRIP_CMD}" MAKE_JOBS_UNSAFE=yes -ALL_TARGET= # -BINARIES= # +ALL_TARGET= # empty USE_GCC= yes -OPTIONS_DEFAULT=CLIENT DEDICATED +PORTDATA= * + OPTIONS_MULTI= COMPONENTS OPTIONS_MULTI_COMPONENTS=CLIENT DEDICATED +OPTIONS_DEFAULT=CLIENT DEDICATED + CLIENT_DESC= Build client DEDICATED_DESC= Build dedicated server -NO_STAGE= yes +CLIENT_LIB_DEPENDS+= libmodplug.so:${PORTSDIR}/audio/libmodplug \ + libtheora.so:${PORTSDIR}/multimedia/libtheora \ + libvorbis.so:${PORTSDIR}/audio/libvorbis \ + libogg.so:${PORTSDIR}/audio/libogg + .include <bsd.port.options.mk> .if ${PORT_OPTIONS:MCLIENT} -LIB_DEPENDS+= modplug:${PORTSDIR}/audio/libmodplug \ - theora:${PORTSDIR}/multimedia/libtheora \ - vorbis:${PORTSDIR}/audio/libvorbis \ - ogg:${PORTSDIR}/audio/libogg USE_SDL= sdl ALL_TARGET+= sdl-release -BINARIES+= xonotic-sdl +PLIST_FILES+= bin/${PORTNAME} + +DESKTOP_ENTRIES="Xonotic" \ + "${COMMENT}" \ + "${PREFIX}/share/pixmaps/${PORTNAME}.ico" \ + "${PORTNAME}" \ + "Game;Shooter;" \ + "" + +PLIST_FILES+= share/pixmaps/${PORTNAME}.ico .endif .if ${PORT_OPTIONS:MDEDICATED} ALL_TARGET+= sv-release -BINARIES+= xonotic-dedicated +PLIST_FILES+= bin/${PORTNAME}-dedicated .endif -.for f in ${BINARIES} -PLIST_FILES+= bin/${f} -.endfor - -PORTDATA= * - post-patch: @${REINPLACE_CMD} -e 's,/usr/X11R6,${LOCALBASE},' \ ${WRKSRC}/${MAKEFILE} ${WRKSRC}/makefile.inc @@ -68,18 +73,18 @@ post-patch: @${ECHO_CMD} >> ${WRKSRC}/prvm_offsets.h # silence 'no newline' warnings do-install: -.for f in ${BINARIES} - ${INSTALL_PROGRAM} ${WRKSRC}/${f:C/xonotic/darkplaces/} ${PREFIX}/bin/${f} -.endfor -.if !defined(NOPORTDATA) - ${MKDIR} ${DATADIR}/data - ${INSTALL_DATA} ${WRKDIR}/Xonotic/data/*.pk3 ${DATADIR}/data/ +.if ${PORT_OPTIONS:MCLIENT} + ${INSTALL_PROGRAM} ${WRKSRC}/darkplaces-sdl ${STAGEDIR}${PREFIX}/bin/${PORTNAME} + ${INSTALL_DATA} ${WRKDIR}/Xonotic/misc/logos/icons_ico/xonotic.ico ${STAGEDIR}${PREFIX}/share/pixmaps/ +.endif .if ${PORT_OPTIONS:MDEDICATED} - cd ${WRKDIR}/Xonotic && ${COPYTREE_SHARE} server ${DATADIR} + ${INSTALL_PROGRAM} ${WRKSRC}/darkplaces-dedicated ${STAGEDIR}${PREFIX}/bin/${PORTNAME}-dedicated + cd ${WRKDIR}/Xonotic && ${COPYTREE_SHARE} "server" ${STAGEDIR}${DATADIR}/ # Fixup lost +x permissions on scripts after COPYTREE_SHARE - ${FIND} ${DATADIR}/server -type f -name *.sh -o -name rcon*.pl | \ + ${FIND} ${STAGEDIR}${DATADIR}/server -type f -name *.sh -o -name rcon*.pl | \ ${XARGS} ${CHMOD} +x .endif -.endif + ${MKDIR} ${STAGEDIR}${DATADIR}/data + ${INSTALL_DATA} ${WRKDIR}/Xonotic/data/*.pk3 ${STAGEDIR}${DATADIR}/data/ .include <bsd.port.mk> |