diff options
author | alepulver <alepulver@FreeBSD.org> | 2006-09-19 03:58:07 +0800 |
---|---|---|
committer | alepulver <alepulver@FreeBSD.org> | 2006-09-19 03:58:07 +0800 |
commit | 40c776f622242bb1c322a0dd4f67747ea33c26b9 (patch) | |
tree | 8fa4c5a5f6ec38049cabb4049ad9242e285e072a /games | |
parent | 1e62fd3c14cef971947f994de3f7fb295feba77d (diff) | |
download | freebsd-ports-gnome-40c776f622242bb1c322a0dd4f67747ea33c26b9.tar.gz freebsd-ports-gnome-40c776f622242bb1c322a0dd4f67747ea33c26b9.tar.zst freebsd-ports-gnome-40c776f622242bb1c322a0dd4f67747ea33c26b9.zip |
- Bump PORTREVISION.
- Install wrapper script as PORTNAME (easier to find for users).
- Rename directory from ~/.legacy to ~/.doomlegacy.
- Do not use /usr/local, /usr/X11R6, /usr/local/include/SDL11 and -lSDL-1.1
directly. Use variables/command output instead.
- Improve wrapper script: only create ~/.doomlegacy once, do not symlink WAD
files since it looks in DOOMWADDIR (environment variable).
- Remove ONLY_FOR_ARCHS=i386 (builds at least on amd64).
PR: ports/103156
Approved by: maintainer (timeout)
Diffstat (limited to 'games')
-rw-r--r-- | games/doomlegacy/Makefile | 19 | ||||
-rw-r--r-- | games/doomlegacy/files/legacy.in | 28 | ||||
-rw-r--r-- | games/doomlegacy/pkg-plist | 2 |
3 files changed, 27 insertions, 22 deletions
diff --git a/games/doomlegacy/Makefile b/games/doomlegacy/Makefile index e0d07229c6a8..a474ff7ee4db 100644 --- a/games/doomlegacy/Makefile +++ b/games/doomlegacy/Makefile @@ -6,10 +6,9 @@ PORTNAME= doomlegacy PORTVERSION= 142 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= games -MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} -MASTER_SITE_SUBDIR= ${PORTNAME} +MASTER_SITES= SF DISTNAME= legacy_${PORTVERSION}_src DISTFILES= ${DISTNAME}${EXTRACT_SUFX} ${WADFILE} EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX} @@ -19,8 +18,6 @@ COMMENT= DooM Legacy: popular DooM clone! EXTRACT_DEPENDS=unzip:${PORTSDIR}/archivers/unzip -ONLY_FOR_ARCHS= i386 - USE_GL= yes USE_GMAKE= yes USE_SDL= mixer sdl @@ -40,6 +37,14 @@ DATADIR= ${PREFIX}/lib/${PORTNAME} post-extract: ${UNZIP_CMD} -q ${DISTDIR}/${WADFILE} -d ${WRKDIR}/bin +post-patch: + @${REINPLACE_CMD} -e \ + 's|-I/usr/local/include/SDL11|`${SDL_CONFIG} --cflags`|; \ + s|-lSDL-1\.1|`${SDL_CONFIG} --libs`|; \ + s|/usr/local|${LOCALBASE}|; \ + s|/usr/X11R6|${X11BASE}|' \ + ${WRKSRC}/${MAKEFILE} + pre-build: cd ${WRKSRC}/linux_x/sndserv && ${GMAKE} clean @@ -53,7 +58,7 @@ do-install: ${INSTALL} -c -s -o root -g kmem -m 2555 ${WRKDIR}/bin/lsdldoom \ ${DATADIR} ${INSTALL_DATA} ${WRKDIR}/bin/legacy.dat ${DATADIR} - ${INSTALL_SCRIPT} ${WRKDIR}/legacy ${PREFIX}/bin + ${INSTALL_SCRIPT} ${WRKDIR}/legacy ${PREFIX}/bin/${PORTNAME} post-install: .ifndef(NOPORTDOCS) @@ -67,7 +72,7 @@ post-install: .include <bsd.port.pre.mk> -.if defined(WITH_X86_ASM) +.if defined(WITH_X86_ASM) && ${ARCH} == "i386" BUILD_DEPENDS+= nasm:${PORTSDIR}/devel/nasm MAKE_ARGS+= USEASM=1 .endif diff --git a/games/doomlegacy/files/legacy.in b/games/doomlegacy/files/legacy.in index d43a1a0165d5..731a6fde9a20 100644 --- a/games/doomlegacy/files/legacy.in +++ b/games/doomlegacy/files/legacy.in @@ -1,20 +1,20 @@ #!/bin/sh # The executable needs to run from a directory with the Doom Legacy data -# files, libraries and executables, and Doom WAD files. So we mirror the Doom -# Legacy and Doom (WAD files) data directory to ~/.legacy, and create symlinks -# to the data files. +# files, libraries and executables. So we mirror the Doom Legacy data +# directory to ~/.doomlegacy, and create symlinks to the data files. -cd %%DATADIR%% || exit 1 +DOOMWADDIR="%%DMDIR%%"; export DOOMWADDIR -mkdir -p ~/.legacy -find * -type f -exec ln -sf %%DATADIR%%/{} ~/.legacy/{} \; || exit 1 +if [ -d ~/.doomlegacy ] +then + echo "Using existing ~/.doomlegacy directory." +else + echo "Creating ~/.doomlegacy directory." + cd %%DATADIR%% || exit 1 + find * -type d -exec mkdir -p ~/.doomlegacy/{} \; + find * -type f -exec ln -sf %%DATADIR%%/{} ~/.doomlegacy/{} \; +fi -cd %%DMDIR%% || exit 1 - -find * -type d -exec mkdir -p ~/.legacy/{} \; || exit 1 -find * -type f -exec ln -sf %%DMDIR%%/{} ~/.legacy/{} \; || exit 1 - -cd ~/.legacy || exit 1 - -exec ./lsdldoom -nocheckwadversion $* +cd ~/.doomlegacy || exit 1 +exec ./lsdldoom -nocheckwadversion "$@" diff --git a/games/doomlegacy/pkg-plist b/games/doomlegacy/pkg-plist index 17d4b60acd32..6ee12a9408de 100644 --- a/games/doomlegacy/pkg-plist +++ b/games/doomlegacy/pkg-plist @@ -1,4 +1,4 @@ -bin/legacy +bin/doomlegacy %%DATADIR%%/legacy.dat %%DATADIR%%/llsndserv %%DATADIR%%/lsdldoom |