Changeset View
Standalone View
games/barony/Makefile
# $FreeBSD$ | # $FreeBSD$ | ||||
PORTNAME= barony | PORTNAME= barony | ||||
DISTVERSIONPREFIX= v | DISTVERSIONPREFIX= v | ||||
DISTVERSION= 3.1.4 | DISTVERSION= 3.1.4 | ||||
CATEGORIES= games | CATEGORIES= games | ||||
MASTER_SITES= http://www.baronygame.com/ | |||||
AMDmi3: MASTER_SITES is where you fetch distfiles from. This is bogus in presence of USE_GITHUB. See… | |||||
MAINTAINER= David Carlier <devnexen@gmail.com> | MAINTAINER= devnexen@gmail.com | ||||
COMMENT= 3D roguelike game | COMMENT= 3D roguelike game | ||||
LICENSE= GPLv3 | LICENSE= GPLv3 | ||||
Not Done Inline ActionsAdd LICENSE_FILE tobik: Add `LICENSE_FILE` | |||||
LIB_DEPENDS= libvorbisfile.so:audio/libvorbis \ | LIB_DEPENDS= libvorbisfile.so:audio/libvorbis \ | ||||
libpng.so:graphics/png | libpng.so:graphics/png \ | ||||
libogg.so:audio/libogg | |||||
USES= cmake compiler:c++11-lib openal:al pkgconfig | USES= cmake compiler:c++11-lib openal:al localbase:ldflags pkgconfig | ||||
Not Done Inline ActionsThe indentation after the variables looks seriously off in the entire file (hard to tell in Phabricator). Indent with one tab or two if needed. tobik: The indentation after the variables looks seriously off in the entire file (hard to tell in… | |||||
USE_GL= gl glu | USE_GL= gl glu | ||||
Not Done Inline Actionsmixer2 (aka SDL2_mixer) is commented out in the source i.e., unused. jbeich: `mixer2` (aka `SDL2_mixer`) is commented out in the source i.e., unused. | |||||
USE_SDL= sdl2 image2 mixer2 ttf2 | USE_SDL= sdl2 image2 net2 ttf2 | ||||
LLD_UNSAFE= yes | |||||
USE_GITHUB= yes | USE_GITHUB= yes | ||||
GH_ACCOUNT= TurningWheel | GH_ACCOUNT= TurningWheel | ||||
Not Done Inline ActionsConvert CMAKE_ARGS=-D<VAR>=ON to CMAKE_ON=<VAR> per /usr/ports/CHANGES from 20171231. jbeich: Convert `CMAKE_ARGS=-D<VAR>=ON` to `CMAKE_ON=<VAR>` per `/usr/ports/CHANGES` from `20171231`. | |||||
GH_PROJECT= Barony | GH_PROJECT= Barony | ||||
Not Done Inline ActionsUSES=localbase preferred AMDmi3: USES=localbase preferred | |||||
Not Done Inline ActionsMaybe qualify type e.g., -DEDITOR_EXE_NAME:STRING="barony-editor" jbeich: Maybe qualify [type](https://cmake.org/cmake/help/v3.0/prop_cache/TYPE.html) e.g., `… | |||||
Not Done Inline ActionsSee above about CMAKE_ON. jbeich: See above about `CMAKE_ON`. | |||||
LDFLAGS+= -L${LOCALBASE}/lib | CMAKE_ON= OPENAL_ENABLED DATA_DIR | ||||
CMAKE_ARGS= -DOPENAL_ENABLED=ON \ | CMAKE_ARGS= -DEDITOR_EXE_NAME:STRING="barony-editor" | ||||
Not Done Inline ActionsNot needed. AMDmi3: Not needed. | |||||
-DEDITOR_EXE_NAME="barony-editor" \ | |||||
-DCMAKE_INSTALL_BINDIR="${LOCALBASE}/bin" \ | |||||
-DDATA_DIR=ON | |||||
post-install: | LDFLAGS+= -Wl,--as-needed | ||||
${SED} -e 's:%%PREFIX%%:${PREFIX}:g' \ | |||||
${FILESDIR}/barony.sh > ${STAGEDIR}${PREFIX}/bin/barony | |||||
${CHMOD} +x ${STAGEDIR}${PREFIX}/bin/barony | |||||
Not Done Inline ActionsTargets after all definitions please. AMDmi3: Targets after all definitions please. | |||||
SUB_FILES= barony.sh | |||||
Not Done Inline ActionsBetter use SUB_FILES=barony.sh - this will automatically process placeholders from files/barony.sh.in and place resulting file under ${WRKDIR}/barony.sh. Then you'll just have to install it with ${INSTALL_SCRIPT}. Also, instead of a huge effort to rename game binary, you can just move it into libexec/ here: ${MV} ${STAGEDIR}${PREFIX}/bin/${PORTNAME} ${STAGEDIR}${PREFIX}/libexec/${PORTNAME} and call it from the wrapper script. AMDmi3: Better use `SUB_FILES=barony.sh` - this will automatically process placeholders from… | |||||
Not Done Inline Actionsshare/barony is ${DATADIR_REL} or ${DATADIR} (absolute path). If you plan to use bin/${PORTNAME} maybe convert this one as well. jbeich: `share/barony` is `${DATADIR_REL}` or `${DATADIR}` (absolute path). If you plan to use… | |||||
PLIST_FILES= bin/barony \ | PLIST_FILES= bin/${PORTNAME} \ | ||||
bin/barony-bin \ | |||||
bin/barony-editor \ | bin/barony-editor \ | ||||
share/games/barony/lang/en.ttf \ | libexec/${PORTNAME} \ | ||||
share/games/barony/lang/en.txt | ${DATADIR}/lang/en.ttf \ | ||||
Not Done Inline ActionsNot consistent with PLIST_FILES: libexec/${PORTNAME} vs. libexec/barony. jbeich: Not consistent with `PLIST_FILES`: `libexec/${PORTNAME}` vs. `libexec/barony`. | |||||
${DATADIR}/lang/en.txt | |||||
Not Done Inline ActionsNot consistent with PLIST_FILES: bin/${PORTNAME} vs. bin/barony. jbeich: Not consistent with `PLIST_FILES`: `bin/${PORTNAME}` vs. `bin/barony`. | |||||
post-install: | |||||
${MV} ${STAGEDIR}${PREFIX}/bin/${PORTNAME} \ | |||||
${STAGEDIR}${PREFIX}/libexec/${PORTNAME} | |||||
${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME}.sh \ | |||||
${STAGEDIR}${PREFIX}/bin/${PORTNAME} | |||||
.include <bsd.port.mk> | .include <bsd.port.mk> |
MASTER_SITES is where you fetch distfiles from. This is bogus in presence of USE_GITHUB. See not about WWW: in pkg-descr