aboutsummaryrefslogtreecommitdiffstats
path: root/games/openttd
diff options
context:
space:
mode:
authordanfe <danfe@FreeBSD.org>2011-10-17 11:44:38 +0800
committerdanfe <danfe@FreeBSD.org>2011-10-17 11:44:38 +0800
commita025d7d94ff460c224d95d590d4a2e3bb6924d3e (patch)
treeb7fc9c985c0604a87d61f4fe3e0579adadfb01b2 /games/openttd
parentfa66b510ea6ca6fa919f07f91057c3a4f156f680 (diff)
downloadfreebsd-ports-gnome-a025d7d94ff460c224d95d590d4a2e3bb6924d3e.tar.gz
freebsd-ports-gnome-a025d7d94ff460c224d95d590d4a2e3bb6924d3e.tar.zst
freebsd-ports-gnome-a025d7d94ff460c224d95d590d4a2e3bb6924d3e.zip
- Add new knob, WITH_OPEN_GAME_FILES, to register run-time dependencies on
libre graphics, music, and sound ports - While I'm here, find a better way to suppress vendor CFLAGS with sed(1): instead of anchoring line numbers, look for specific text string PR: ports/157355
Diffstat (limited to 'games/openttd')
-rw-r--r--games/openttd/Makefile14
1 files changed, 11 insertions, 3 deletions
diff --git a/games/openttd/Makefile b/games/openttd/Makefile
index 5a5970084302..4bcf9c94aa20 100644
--- a/games/openttd/Makefile
+++ b/games/openttd/Makefile
@@ -52,6 +52,11 @@ LIB_DEPENDS+= freetype.9:${PORTSDIR}/print/freetype2 \
fontconfig.1:${PORTSDIR}/x11-fonts/fontconfig
USE_SDL= sdl
.endif
+.if defined(WITH_OPEN_GAME_FILES)
+RUN_DEPENDS= ${LOCALBASE}/share/${PORTNAME}/data/opengfx/opengfx.obg:${PORTSDIR}/games/opengfx \
+ ${LOCALBASE}/share/${PORTNAME}/gm/openmsx/openmsx.obm:${PORTSDIR}/games/openmsx \
+ ${LOCALBASE}/share/${PORTNAME}/data/opensfx/opensfx.obs:${PORTSDIR}/games/opensfx
+.endif
SUB_FILES= pkg-message
MAN6= ${PORTNAME}.6
@@ -77,12 +82,15 @@ pre-everything::
.if !defined(WITH_DEDICATED_SERVER_ONLY)
@${ECHO_MSG} "Define WITH_DEDICATED_SERVER_ONLY to build CLI-based dedicated server"
.endif
+.if !defined(WITH_OPEN_GAME_FILES)
+ @${ECHO_MSG} "Define WITH_OPEN_GAME_FILES to install with libre graphics, music, and sound"
+.endif
post-patch:
# Remove extra (vendor-provided) CFLAGS and LDFLAGS and make the port more
-# LOCALBASE safe (don't forget to update XXXX,YYYYd part when upgrading!)
- @${REINPLACE_CMD} -e '1360,1361d ; s,/usr/local,${LOCALBASE},' \
- ${WRKSRC}/config.lib
+# LOCALBASE safe
+ @${REINPLACE_CMD} -e '/-O2 -fomit-frame-pointer/d ; \
+ s,/usr/local,${LOCALBASE},' ${WRKSRC}/config.lib
# Use custom liblzma.pc for when we use liblzma from base
.if ${OSVERSION} >= 900012 || (${OSVERSION} >= 800505 && ${OSVERSION} < 900000)
@${REINPLACE_CMD} -e \