aboutsummaryrefslogtreecommitdiff
path: root/games/uqm
diff options
context:
space:
mode:
authorThierry Thomas <thierry@FreeBSD.org>2005-11-11 11:56:56 +0000
committerThierry Thomas <thierry@FreeBSD.org>2005-11-11 11:56:56 +0000
commit54cb5b41b935c23d53b94914cfd672fc873f59a1 (patch)
tree28f399b6bb55fa49af276efe9def2111f92f6c62 /games/uqm
parenta18409364542d71e060f92c317d0d31a7a7602ae (diff)
downloadports-54cb5b41b935c23d53b94914cfd672fc873f59a1.tar.gz
ports-54cb5b41b935c23d53b94914cfd672fc873f59a1.zip
Notes
Diffstat (limited to 'games/uqm')
-rw-r--r--games/uqm/Makefile40
-rw-r--r--games/uqm/files/patch-build-unix-config_proginfo_host25
-rw-r--r--games/uqm/pkg-plist14
3 files changed, 56 insertions, 23 deletions
diff --git a/games/uqm/Makefile b/games/uqm/Makefile
index c659ae03e34d..202cc6922791 100644
--- a/games/uqm/Makefile
+++ b/games/uqm/Makefile
@@ -7,9 +7,9 @@
# Ur-Quan Masters offers add-on packages that enhance the game. These are
# optional. The following add-ons exist at the moment:
#
-# Voice add-on (110 MB). Enable this with -DVOICEADDON
+# Voice add-on (110 MB). Enable this with -DWITH_VOICE
#
-# 3DO Music add-on (18 MB). Enable this with -DMUSICADDON
+# 3DO Music add-on (18 MB). Enable this with -DWITH_MUSIC
#
PORTNAME= uqm
@@ -33,64 +33,76 @@ NO_INSTALL_MANPAGES= yes
ONLY_FOR_ARCHS= i386
-.ifdef(VOICEADDON)
+OPTIONS= VOICE "Voice add-on (110MB)" Off \
+ MUSIC "Music add-on (18MB)" Off \
+ OPENAL "OpenAL support (experimental)" Off
+
+.include <bsd.port.pre.mk>
+
+.ifdef(WITH_VOICE)
DISTFILES+= ${PORTNAME}-${PORTVERSION}-voice.uqm
PLIST_SUB+= VOICEADDON=""
.else
PLIST_SUB+= VOICEADDON="@comment "
.endif
-.ifdef(MUSICADDON)
+.ifdef(WITH_MUSIC)
DISTFILES+= ${PORTNAME}-${PORTVERSION}-3domusic.uqm
PLIST_SUB+= MUSICADDON=""
.else
PLIST_SUB+= MUSICADDON="@comment "
.endif
-.include <bsd.port.pre.mk>
+.ifdef(WITH_OPENAL)
+LIB_DEPENDS+= openal.0:${PORTSDIR}/audio/openal
+.endif
.if ${OSVERSION} < 500000
BROKEN= "does not compile"
.endif
pre-everything::
-.ifdef(!VOICEADDON || !MUSICADDON)
+.ifdef(!WITH_VOICE || !WITH_MUSIC)
@${ECHO_MSG} ""
@${ECHO_MSG} "You may specify the following options:"
.endif
-.ifdef(!VOICEADDON)
+.ifdef(!WITH_VOICE)
@${ECHO_MSG} ""
- @${ECHO_MSG} "-DVOICEADDON"
+ @${ECHO_MSG} "-DWITH_VOICE"
@${ECHO_MSG} " Installs the voice add-on (110MB)."
.endif
-.ifdef(!MUSICADDON)
+.ifdef(!WITH_MUSIC)
@${ECHO_MSG} ""
- @${ECHO_MSG} "-DMUSICADDON"
+ @${ECHO_MSG} "-DWITH_MUSIC"
@${ECHO_MSG} " Installs the music add-on (18MB) containing the original"
@${ECHO_MSG} " 3do music files. Note that there is music without this"
- @${ECHO_MSG} " add-on, just not as much."
+ @${ECHO_MSG} " add-on, but it's of lower quality."
.endif
post-extract:
${MKDIR} ${WRKSRC}/content/packages
${CP} ${DISTDIR}/${PORTNAME}-${PORTVERSION}-content.uqm ${WRKSRC}/content/packages/
-.ifdef(VOICEADDON)
+.ifdef(WITH_VOICE)
${CP} ${DISTDIR}/${PORTNAME}-${PORTVERSION}-voice.uqm ${WRKSRC}/content/packages/
.endif
-.ifdef(MUSICADDON)
+.ifdef(WITH_MUSIC)
${CP} ${DISTDIR}/${PORTNAME}-${PORTVERSION}-3domusic.uqm ${WRKSRC}/content/packages/
.endif
do-configure:
@${ECHO_MSG} CHOICE_debug_VALUE=\'nodebug\' > ${WRKSRC}/config.state
@${ECHO_MSG} CHOICE_graphics_VALUE=\'opengl\' >> ${WRKSRC}/config.state
+.ifdef(WITH_OPENAL)
+ @${ECHO_MSG} CHOICE_sound_VALUE=\'openal\' >> ${WRKSRC}/config.state
+.else
@${ECHO_MSG} CHOICE_sound_VALUE=\'mixsdl\' >> ${WRKSRC}/config.state
+.endif
@${ECHO_MSG} CHOICE_ioformat_VALUE=\'stdio_zip\' >> ${WRKSRC}/config.state
@${ECHO_MSG} INPUT_install_prefix_VALUE=\'${PREFIX}\' >> ${WRKSRC}/config.state
@${ECHO_MSG} INPUT_install_bindir_VALUE=\''$$prefix/bin'\' >> ${WRKSRC}/config.state
@${ECHO_MSG} INPUT_install_libdir_VALUE=\''$$prefix/lib'\' >> ${WRKSRC}/config.state
@${ECHO_MSG} INPUT_install_sharedir_VALUE=\''$$prefix/share'\' >> ${WRKSRC}/config.state
- cd ${WRKSRC} && ${SETENV} LOCALBASE=${LOCALBASE} PREFIX=${PREFIX} ./build.sh uqm config
+ cd ${WRKSRC} && ${SETENV} LOCALBASE=${LOCALBASE} X11BASE=${X11BASE} PREFIX=${PREFIX} ./build.sh uqm config
do-build:
cd ${WRKSRC} && ./build.sh uqm
diff --git a/games/uqm/files/patch-build-unix-config_proginfo_host b/games/uqm/files/patch-build-unix-config_proginfo_host
index 943b0b9d7061..2498a94d2642 100644
--- a/games/uqm/files/patch-build-unix-config_proginfo_host
+++ b/games/uqm/files/patch-build-unix-config_proginfo_host
@@ -1,5 +1,5 @@
---- build/unix/config_proginfo_host.orig Sun Jul 3 17:23:50 2005
-+++ build/unix/config_proginfo_host Sun Jul 3 17:24:43 2005
+--- build/unix/config_proginfo_host.orig Fri May 13 17:22:09 2005
++++ build/unix/config_proginfo_host Mon Oct 24 23:26:50 2005
@@ -80,7 +80,7 @@
LIB_openal_CFLAGS=""
case "$HOST_SYSTEM" in
@@ -9,6 +9,27 @@
;;
MINGW32*)
LIB_openal_LDFLAGS="-lopenal32"
+@@ -94,16 +94,16 @@
+ ;;
+ esac
+ LIB_openal_VERSION=""
+-LIB_openal_DETECT="try_pkgconfig_lib openal openal"
+-LIB_openal_DEPEND_DETECT_BIN="pkgconfig"
++#LIB_openal_DETECT="try_pkgconfig_lib openal openal"
++#LIB_openal_DEPEND_DETECT_BIN="pkgconfig"
+
+
+ ### OpenGL ###
+ LIB_opengl_NAME="OpenGL"
+ case "$HOST_SYSTEM" in
+ FreeBSD|OpenBSD)
+- LIB_opengl_CFLAGS="-I/usr/X11R6/include -D_THREAD_SAFE"
+- LIB_opengl_LDFLAGS="-L/usr/X11R6/lib -lX11 -lXext -pthread -lGL"
++ LIB_opengl_CFLAGS="-I${X11BASE}/include -D_THREAD_SAFE"
++ LIB_opengl_LDFLAGS="-L${X11BASE}/lib -lX11 -lXext -pthread -lGL"
+ ;;
+ MINGW32*)
+ LIB_opengl_CFLAGS=""
@@ -132,8 +132,8 @@
LIB_vorbisfile_NAME="vorbisfile"
case "$HOST_SYSTEM" in
diff --git a/games/uqm/pkg-plist b/games/uqm/pkg-plist
index 57c4e2be6ee1..786ed3057f6f 100644
--- a/games/uqm/pkg-plist
+++ b/games/uqm/pkg-plist
@@ -1,12 +1,12 @@
bin/uqm
lib/uqm/uqm
-share/uqm/content/packages/uqm-0.4.0-content.uqm
-share/uqm/content/version
-%%VOICEADDON%%share/uqm/content/packages/uqm-0.4.0-voice.uqm
-%%MUSICADDON%%share/uqm/content/packages/uqm-0.4.0-3domusic.uqm
-@dirrm share/uqm/content/packages
-@dirrm share/uqm/content
-@dirrm share/uqm
+%%DATADIR%%/content/packages/uqm-0.4.0-content.uqm
+%%DATADIR%%/content/version
+%%VOICEADDON%%%%DATADIR%%/content/packages/uqm-0.4.0-voice.uqm
+%%MUSICADDON%%%%DATADIR%%/content/packages/uqm-0.4.0-3domusic.uqm
+@dirrm %%DATADIR%%/content/packages
+@dirrm %%DATADIR%%/content
+@dirrm %%DATADIR%%
@dirrm lib/uqm
%%PORTDOCS%%%%DOCSDIR%%/manual.txt
%%PORTDOCS%%@dirrm %%DOCSDIR%%