diff options
Diffstat (limited to 'games/fargoal')
-rw-r--r-- | games/fargoal/Makefile | 48 | ||||
-rw-r--r-- | games/fargoal/distinfo | 5 | ||||
-rw-r--r-- | games/fargoal/files/fargoal | 14 | ||||
-rw-r--r-- | games/fargoal/files/fargoal-sh.in | 19 | ||||
-rw-r--r-- | games/fargoal/files/patch-Makefile | 23 | ||||
-rw-r--r-- | games/fargoal/files/patch-game.c | 11 | ||||
-rw-r--r-- | games/fargoal/pkg-descr | 4 | ||||
-rw-r--r-- | games/fargoal/pkg-plist | 105 |
8 files changed, 110 insertions, 119 deletions
diff --git a/games/fargoal/Makefile b/games/fargoal/Makefile index 4bb96a9fbe16..9626f5fa1747 100644 --- a/games/fargoal/Makefile +++ b/games/fargoal/Makefile @@ -6,43 +6,43 @@ # PORTNAME= fargoal -PORTVERSION= 20030731b -PORTREVISION= 2 +PORTVERSION= 20040629 CATEGORIES= games MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} MASTER_SITE_SUBDIR= squidfighter DISTNAME= ${PORTNAME}${PORTVERSION} -MAINTAINER= ports@FreeBSD.org +MAINTAINER= alejandro@varnet.biz COMMENT= Remake of classic roguelike game "Sword of Fargoal" LIB_DEPENDS= alleg.42:${PORTSDIR}/devel/allegro -WRKSRC= ${WRKDIR}/fargoal/src -USE_X_PREFIX= yes +WRKSRC= ${WRKDIR}/${PORTNAME}/src + USE_ZIP= yes USE_GMAKE= yes +SUB_FILES= ${PORTNAME}-sh + do-install: - ${MKDIR} ${PREFIX}/share/fargoal - ${MKDIR} ${PREFIX}/share/fargoal/data - @${INSTALL_DATA} ${WRKSRC}/../data/sof.cfg ${PREFIX}/share/fargoal/data/sof.cfg - ${MKDIR} ${PREFIX}/share/fargoal/gfx -.for i in black.bmp chars.bmp chars_ep.bmp dmz_chars.bmp dmz_layout.bmp \ - dmz_tiles.bmp layout.bmp layout_ep.bmp originalchars.bmp \ - originalset.bmp sword.dat tiles.bmp tiles_ep.bmp - @${INSTALL_DATA} ${WRKSRC}/../gfx/${i} ${PREFIX}/share/fargoal/gfx/${i} -.endfor - ${MKDIR} ${PREFIX}/share/fargoal/sfx -.for i in attack beacon boom chop clang claw climb clink crash crunch \ - ding down fight gnarl gold intro item levelup move pit potion \ - sacrifice shred shriek slain slash spell step teleport thump \ - ugh up victory - @${INSTALL_DATA} ${WRKSRC}/../sfx/${i}.wav ${PREFIX}/share/fargoal/sfx/${i}.wav +# Script + @${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME}-sh ${PREFIX}/bin/${PORTNAME} + +# Program + @${INSTALL_PROGRAM} ${WRKSRC}/../sword ${PREFIX}/libexec/${PORTNAME} + +# Data +.for f in agreement.txt data gfx sfx + @${MKDIR} ${DATADIR} + @${CP} -R ${WRKSRC}/../${f} ${DATADIR} .endfor - @${INSTALL_PROGRAM} ${WRKSRC}/../sword ${PREFIX}/bin/sword - @${SED} s^%%FARGOAL_ROOT%%^${PREFIX}/share/fargoal^g \ - < ${FILESDIR}/fargoal > ${WRKDIR}/fargoal/fargoal - @${INSTALL_SCRIPT} ${WRKDIR}/fargoal/fargoal ${PREFIX}/bin/fargoal + +post-install: +# Fix permissions + @${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${DATADIR} + @${FIND} ${DATADIR} -type f -print0 | \ + ${XARGS} -0 ${CHMOD} ${SHAREMODE} + @${FIND} ${DATADIR} -type d -print0 | \ + ${XARGS} -0 ${CHMOD} ${BINMODE} .include <bsd.port.mk> diff --git a/games/fargoal/distinfo b/games/fargoal/distinfo index 753db3c83103..9dda5a26a136 100644 --- a/games/fargoal/distinfo +++ b/games/fargoal/distinfo @@ -1,2 +1,3 @@ -MD5 (fargoal20030731b.zip) = 9b24008b30b2c4b075998bd082de9459 -SIZE (fargoal20030731b.zip) = 764328 +MD5 (fargoal20040629.zip) = a72efd5f9b83d7932497721d08306ce6 +SHA256 (fargoal20040629.zip) = 956398936873b74c3758f59f841d70df7834d2537f2bc9f0a91f9ba395e60899 +SIZE (fargoal20040629.zip) = 792975 diff --git a/games/fargoal/files/fargoal b/games/fargoal/files/fargoal deleted file mode 100644 index d84c611d0d99..000000000000 --- a/games/fargoal/files/fargoal +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh - -if [ -d ~/.fargoal ]; then - cd ~/.fargoal - sword -else - mkdir ~/.fargoal - cd ~/.fargoal - mkdir data - cp -r %%FARGOAL_ROOT%%/data/* data/ - ln -s %%FARGOAL_ROOT%%/gfx gfx - ln -s %%FARGOAL_ROOT%%/sfx sfx - sword -fi diff --git a/games/fargoal/files/fargoal-sh.in b/games/fargoal/files/fargoal-sh.in new file mode 100644 index 000000000000..2c445c6443b0 --- /dev/null +++ b/games/fargoal/files/fargoal-sh.in @@ -0,0 +1,19 @@ +#!/bin/sh + +# The executable needs to be run from its data directory, and needs to store +# configuration in it. We therefore mirror the data directory hierarchy in +# ~/.fargoal, and create symlinks to the data files. + +cd %%DATADIR%% || exit 1 + +find * -type d -exec mkdir -p ~/.fargoal/{} \; || exit 1 + +test -f ~/.fargoal/data/sof.cfg || cp data/sof.cfg ~/.fargoal/data && \ +chmod u+w ~/.fargoal/data/sof.cfg + +find * -type f -exec ln -s %%DATADIR%%/{} ~/.fargoal/{} \; 2>/dev/null || \ +exit 1 + +cd ~/.fargoal || exit 1 + +exec %%PREFIX%%/libexec/fargoal "$@" diff --git a/games/fargoal/files/patch-Makefile b/games/fargoal/files/patch-Makefile index f1f7ce8ded87..8d4b6e9ef0b3 100644 --- a/games/fargoal/files/patch-Makefile +++ b/games/fargoal/files/patch-Makefile @@ -1,16 +1,15 @@ ---- Makefile.orig Thu Jul 31 10:06:51 2003 -+++ Makefile Sat Dec 13 15:44:52 2003 -@@ -1,8 +1,10 @@ +--- Makefile.orig Tue Jun 29 16:45:02 2004 ++++ Makefile Thu Aug 11 15:12:26 2005 +@@ -1,4 +1,4 @@ -CC=gcc -+CC ?= gcc +all: ../sword -+ - ../sword: char.o config.o credits.o game.o gfx.o main.o map.o menu.o message.o monster.o player.o save.o scroller.o spell.o + ../sword: char.o config.o credits.o game.o gfx.o main.o map.o menu.o message.o monster.o player.o save.o scroller.o spell.o $(CC) -o $@ $(LDFLAGS) $^ $(LDLIBS) include makefile.dep --CFLAGS = -W -Wall -O3 --CXXFLAGS = -W -Wall -O3 -+CFLAGS += -W -Wall `allegro-config --cflags` -DALLEGRO_LINUX -+CXXFLAGS += -W -Wall `allegro-config --cflags` -DALLEGRO_LINUX - LDFLAGS = -s - LDLIBS = `allegro-config --libs` +@@ -10,5 +10,5 @@ + CFLAGS += -DMINGW + else + LDLIBS := `allegro-config --libs` +-CFLAGS += `allegro-config --cflags` -DLINUX ++CFLAGS += `allegro-config --cflags` -DLINUX -DALLEGRO_LINUX + endif diff --git a/games/fargoal/files/patch-game.c b/games/fargoal/files/patch-game.c deleted file mode 100644 index 3cd4c996639d..000000000000 --- a/games/fargoal/files/patch-game.c +++ /dev/null @@ -1,11 +0,0 @@ ---- game.c Thu Jul 31 10:06:51 2003 -+++ game.c Mon Nov 17 09:50:58 2003 -@@ -363,7 +363,7 @@ - try_load_sample (boom, "sfx/boom.wav"); - try_load_sample (crash, "sfx/crash.wav"); - try_load_sample (gold, "sfx/gold.wav"); -- try_load_sample (pit, "sfx/pit.wav"); -+ try_load_sample (pit, "sfx/crash.wav"); /* pit.wav is corrupt? */ - try_load_sample (spell, "sfx/spell.wav"); - try_load_sample (step, "sfx/step.wav"); - try_load_sample (attack, "sfx/attack.wav"); diff --git a/games/fargoal/pkg-descr b/games/fargoal/pkg-descr index 744a1395e114..67359b4899a8 100644 --- a/games/fargoal/pkg-descr +++ b/games/fargoal/pkg-descr @@ -2,10 +2,6 @@ This game is a remake of the classic roguelike game "Sword of Fargoal", created by Jeff McCord for the Commodore 64 in 1983. This remake was written for the 2003 remakes.org competition. -Note: this port installs both the Sword of Fargoal executable, -'sword', and a wrapper script, 'fargoal', which allows each -user to keep their own savefiles in their ~/.fargoal directory. - WWW: http://squidfighter.sourceforge.net/fargoal/ -Chris diff --git a/games/fargoal/pkg-plist b/games/fargoal/pkg-plist index 4d7a15c3ffdb..494f9d121740 100644 --- a/games/fargoal/pkg-plist +++ b/games/fargoal/pkg-plist @@ -1,53 +1,54 @@ bin/fargoal -bin/sword -share/fargoal/data/sof.cfg -share/fargoal/gfx/black.bmp -share/fargoal/gfx/chars.bmp -share/fargoal/gfx/chars_ep.bmp -share/fargoal/gfx/dmz_chars.bmp -share/fargoal/gfx/dmz_layout.bmp -share/fargoal/gfx/dmz_tiles.bmp -share/fargoal/gfx/layout.bmp -share/fargoal/gfx/layout_ep.bmp -share/fargoal/gfx/originalchars.bmp -share/fargoal/gfx/originalset.bmp -share/fargoal/gfx/sword.dat -share/fargoal/gfx/tiles.bmp -share/fargoal/gfx/tiles_ep.bmp -share/fargoal/sfx/attack.wav -share/fargoal/sfx/beacon.wav -share/fargoal/sfx/boom.wav -share/fargoal/sfx/chop.wav -share/fargoal/sfx/clang.wav -share/fargoal/sfx/claw.wav -share/fargoal/sfx/climb.wav -share/fargoal/sfx/clink.wav -share/fargoal/sfx/crash.wav -share/fargoal/sfx/crunch.wav -share/fargoal/sfx/ding.wav -share/fargoal/sfx/down.wav -share/fargoal/sfx/fight.wav -share/fargoal/sfx/gnarl.wav -share/fargoal/sfx/gold.wav -share/fargoal/sfx/intro.wav -share/fargoal/sfx/item.wav -share/fargoal/sfx/levelup.wav -share/fargoal/sfx/move.wav -share/fargoal/sfx/pit.wav -share/fargoal/sfx/potion.wav -share/fargoal/sfx/sacrifice.wav -share/fargoal/sfx/shred.wav -share/fargoal/sfx/shriek.wav -share/fargoal/sfx/slain.wav -share/fargoal/sfx/slash.wav -share/fargoal/sfx/spell.wav -share/fargoal/sfx/step.wav -share/fargoal/sfx/teleport.wav -share/fargoal/sfx/thump.wav -share/fargoal/sfx/ugh.wav -share/fargoal/sfx/up.wav -share/fargoal/sfx/victory.wav -@dirrm share/fargoal/data -@dirrm share/fargoal/gfx -@dirrm share/fargoal/sfx -@dirrm share/fargoal +libexec/fargoal +%%DATADIR%%/agreement.txt +%%DATADIR%%/data/sof.cfg +%%DATADIR%%/gfx/black.bmp +%%DATADIR%%/gfx/chars.bmp +%%DATADIR%%/gfx/chars_ep.bmp +%%DATADIR%%/gfx/dmz_chars.bmp +%%DATADIR%%/gfx/dmz_layout.bmp +%%DATADIR%%/gfx/dmz_tiles.bmp +%%DATADIR%%/gfx/layout.bmp +%%DATADIR%%/gfx/layout_ep.bmp +%%DATADIR%%/gfx/originalchars.bmp +%%DATADIR%%/gfx/originalset.bmp +%%DATADIR%%/gfx/sword.dat +%%DATADIR%%/gfx/tiles.bmp +%%DATADIR%%/gfx/tiles_ep.bmp +%%DATADIR%%/sfx/attack.wav +%%DATADIR%%/sfx/beacon.wav +%%DATADIR%%/sfx/boom.wav +%%DATADIR%%/sfx/chop.wav +%%DATADIR%%/sfx/clang.wav +%%DATADIR%%/sfx/claw.wav +%%DATADIR%%/sfx/climb.wav +%%DATADIR%%/sfx/clink.wav +%%DATADIR%%/sfx/crash.wav +%%DATADIR%%/sfx/crunch.wav +%%DATADIR%%/sfx/ding.wav +%%DATADIR%%/sfx/down.wav +%%DATADIR%%/sfx/fight.wav +%%DATADIR%%/sfx/gnarl.wav +%%DATADIR%%/sfx/gold.wav +%%DATADIR%%/sfx/intro.wav +%%DATADIR%%/sfx/item.wav +%%DATADIR%%/sfx/levelup.wav +%%DATADIR%%/sfx/move.wav +%%DATADIR%%/sfx/pit.wav +%%DATADIR%%/sfx/potion.wav +%%DATADIR%%/sfx/sacrifice.wav +%%DATADIR%%/sfx/shred.wav +%%DATADIR%%/sfx/shriek.wav +%%DATADIR%%/sfx/slain.wav +%%DATADIR%%/sfx/slash.wav +%%DATADIR%%/sfx/spell.wav +%%DATADIR%%/sfx/step.wav +%%DATADIR%%/sfx/teleport.wav +%%DATADIR%%/sfx/thump.wav +%%DATADIR%%/sfx/ugh.wav +%%DATADIR%%/sfx/up.wav +%%DATADIR%%/sfx/victory.wav +@dirrm %%DATADIR%%/sfx +@dirrm %%DATADIR%%/gfx +@dirrm %%DATADIR%%/data +@dirrm %%DATADIR%% |