aboutsummaryrefslogtreecommitdiffstats
path: root/games
diff options
context:
space:
mode:
Diffstat (limited to 'games')
-rw-r--r--games/Makefile1
-rw-r--r--games/meritous/Makefile38
-rw-r--r--games/meritous/distinfo3
-rw-r--r--games/meritous/files/patch-Makefile26
-rw-r--r--games/meritous/files/patch-src-levelblit.c30
-rw-r--r--games/meritous/pkg-descr3
-rw-r--r--games/meritous/pkg-plist89
7 files changed, 190 insertions, 0 deletions
diff --git a/games/Makefile b/games/Makefile
index 3b5b731b067e..34d679b88aab 100644
--- a/games/Makefile
+++ b/games/Makefile
@@ -491,6 +491,7 @@
SUBDIR += masterserver
SUBDIR += memonix
SUBDIR += meqcc
+ SUBDIR += meritous
SUBDIR += merlin
SUBDIR += mindfocus
SUBDIR += mindguard
diff --git a/games/meritous/Makefile b/games/meritous/Makefile
new file mode 100644
index 000000000000..60c62bd25cde
--- /dev/null
+++ b/games/meritous/Makefile
@@ -0,0 +1,38 @@
+# New ports collection makefile for: meritous
+# Date created: 24 Nov 2008
+# Whom: Dmitry Marakasov <amdmi3@FreeBSD.org>
+#
+# $FreeBSD$
+#
+
+PORTNAME= meritous
+PORTVERSION= 1.2
+CATEGORIES= games
+MASTER_SITES= http://www.asceai.net/files/ \
+ http://www.amdmi3.ru/distfiles/
+DISTNAME= ${PORTNAME}_v${PORTVERSION:C/\.//}_src
+
+MAINTAINER= amdmi3@FreeBSD.org
+COMMENT= Action-adventure dungeon crawl game
+
+USE_BZIP2= yes
+USE_GMAKE= yes
+USE_SDL= sdl mixer image
+ALL_TARGET= default
+
+PORTDOCS= *
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|dat/|${DATADIR}/|' ${WRKSRC}/src/*.c
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/meritous ${PREFIX}/bin
+ ${MKDIR} ${DATADIR}
+ cd ${WRKSRC}/dat && ${COPYTREE_SHARE} \* ${DATADIR}
+
+.if !defined(NOPORTDOCS)
+ ${MKDIR} ${DOCSDIR}
+ ${INSTALL_DATA} ${WRKSRC}/readme.txt ${DOCSDIR}
+.endif
+
+.include <bsd.port.mk>
diff --git a/games/meritous/distinfo b/games/meritous/distinfo
new file mode 100644
index 000000000000..d0f3f4acc253
--- /dev/null
+++ b/games/meritous/distinfo
@@ -0,0 +1,3 @@
+MD5 (meritous_v12_src.tar.bz2) = 88e439c773ee0e334fd2b256100983b8
+SHA256 (meritous_v12_src.tar.bz2) = 20b2086240c810c04fd0ce4a24f9d9c9dacbac47da61c26758943f1fdef7571d
+SIZE (meritous_v12_src.tar.bz2) = 2469389
diff --git a/games/meritous/files/patch-Makefile b/games/meritous/files/patch-Makefile
new file mode 100644
index 000000000000..95a69cceefe3
--- /dev/null
+++ b/games/meritous/files/patch-Makefile
@@ -0,0 +1,26 @@
+--- Makefile.orig 2008-01-15 05:44:55.000000000 +0300
++++ Makefile 2008-11-24 02:09:08.000000000 +0300
+@@ -18,8 +18,8 @@
+ # You should have received a copy of the GNU General Public License
+ # along with Meritous. If not, see <http://www.gnu.org/licenses/>.
+ #
+-LDFLAGS = `sdl-config --libs` -lSDL_image -lSDL_mixer -lz
+-CCFLAGS = -O2 -Wall `sdl-config --cflags` -g
++LDFLAGS = `${SDL_CONFIG} --libs` -lSDL_image -lSDL_mixer -lz
++CCFLAGS = ${CFLAGS} -Wall `${SDL_CONFIG} --cflags`
+ #
+ OBJS = src/levelblit.o \
+ src/mapgen.o \
+@@ -35,10 +35,10 @@
+ default: meritous
+
+ %.o: %.c
+- gcc -c -o $@ $? ${CCFLAGS}
++ ${CC} -c -o $@ $? ${CCFLAGS}
+
+ meritous: ${OBJS}
+- gcc -o $@ $+ ${LDFLAGS}
++ ${CC} -o $@ $+ ${LDFLAGS}
+
+ clean:
+ rm ${OBJS}
diff --git a/games/meritous/files/patch-src-levelblit.c b/games/meritous/files/patch-src-levelblit.c
new file mode 100644
index 000000000000..631283b75505
--- /dev/null
+++ b/games/meritous/files/patch-src-levelblit.c
@@ -0,0 +1,30 @@
+--- src/levelblit.c.orig 2008-01-15 05:54:41.000000000 +0300
++++ src/levelblit.c 2008-11-24 02:16:34.000000000 +0300
+@@ -27,7 +27,11 @@
+ #include <SDL.h>
+ #include <SDL_image.h>
+ #include <assert.h>
+-
++
++#include <unistd.h>
++#include <err.h>
++#include <sys/stat.h>
++
+ #include "mapgen.h"
+ #include "demon.h"
+ #include "gamemap.h"
+@@ -378,6 +382,14 @@
+
+ int main(int argc, char **argv)
+ {
++ {
++ if (chdir(getenv("HOME")) != 0)
++ err(1, "cannot cd to $HOME");
++ if (mkdir(".meritous", 0755) != 0 && errno != EEXIST)
++ err(1, "cannot mkdir $HOME/.meritous");
++ if (chdir(".meritous") != 0)
++ err(1, "cannot cd to $HOME/.meritous");
++ }
+ int on_title = 1;
+ int executable_running = 1;
+ SDL_Surface *title, *title_pr, *asceai;
diff --git a/games/meritous/pkg-descr b/games/meritous/pkg-descr
new file mode 100644
index 000000000000..346c767d23a2
--- /dev/null
+++ b/games/meritous/pkg-descr
@@ -0,0 +1,3 @@
+Meritous is an action-adventure dungeon crawl game.
+
+WWW: http://www.asceai.net/meritous/
diff --git a/games/meritous/pkg-plist b/games/meritous/pkg-plist
new file mode 100644
index 000000000000..0c0896cfcd78
--- /dev/null
+++ b/games/meritous/pkg-plist
@@ -0,0 +1,89 @@
+bin/meritous
+%%DATADIR%%/a/circuitcharge.wav
+%%DATADIR%%/a/circuitrecover.wav
+%%DATADIR%%/a/circuitrelease.wav
+%%DATADIR%%/a/crystal.wav
+%%DATADIR%%/a/crystal2.wav
+%%DATADIR%%/a/enemyhit.wav
+%%DATADIR%%/a/mons0shot.wav
+%%DATADIR%%/a/mons10shot.wav
+%%DATADIR%%/a/mons1shot.wav
+%%DATADIR%%/a/mons2shot.wav
+%%DATADIR%%/a/mons3shot.wav
+%%DATADIR%%/a/mons4shot.wav
+%%DATADIR%%/a/mons5shot.wav
+%%DATADIR%%/a/mons6shot.wav
+%%DATADIR%%/a/mons7shot.wav
+%%DATADIR%%/a/mons8shot.wav
+%%DATADIR%%/a/mons9shot.wav
+%%DATADIR%%/a/playerhurt.wav
+%%DATADIR%%/a/shieldhit.wav
+%%DATADIR%%/a/teleport.wav
+%%DATADIR%%/a/tone.wav
+%%DATADIR%%/d/bossroom.loc
+%%DATADIR%%/d/centre.loc
+%%DATADIR%%/d/cstream.loc
+%%DATADIR%%/d/fbossroom.loc
+%%DATADIR%%/d/font.dat
+%%DATADIR%%/d/helpfile.txt
+%%DATADIR%%/d/icon_bitmask.dat
+%%DATADIR%%/d/weapon.loc
+%%DATADIR%%/i/agate.png
+%%DATADIR%%/i/artifacts.png
+%%DATADIR%%/i/asceai.png
+%%DATADIR%%/i/automap.png
+%%DATADIR%%/i/boss1.png
+%%DATADIR%%/i/boss2.png
+%%DATADIR%%/i/boss3.png
+%%DATADIR%%/i/boss4.png
+%%DATADIR%%/i/boss_icon.png
+%%DATADIR%%/i/circuits_1.png
+%%DATADIR%%/i/fin.png
+%%DATADIR%%/i/gem.png
+%%DATADIR%%/i/glitter.png
+%%DATADIR%%/i/hidden_monster.png
+%%DATADIR%%/i/icon.png
+%%DATADIR%%/i/inrange.png
+%%DATADIR%%/i/linetest.png
+%%DATADIR%%/i/meter.png
+%%DATADIR%%/i/mons1.png
+%%DATADIR%%/i/mons10.png
+%%DATADIR%%/i/mons2.png
+%%DATADIR%%/i/mons3.png
+%%DATADIR%%/i/mons4.png
+%%DATADIR%%/i/mons5.png
+%%DATADIR%%/i/mons6.png
+%%DATADIR%%/i/mons7.png
+%%DATADIR%%/i/mons8.png
+%%DATADIR%%/i/mons9.png
+%%DATADIR%%/i/overview.png
+%%DATADIR%%/i/player.png
+%%DATADIR%%/i/reticle.png
+%%DATADIR%%/i/star1.png
+%%DATADIR%%/i/star2.png
+%%DATADIR%%/i/star3.png
+%%DATADIR%%/i/stream.png
+%%DATADIR%%/i/teleflash.png
+%%DATADIR%%/i/theend.png
+%%DATADIR%%/i/tileset.png
+%%DATADIR%%/i/title.png
+%%DATADIR%%/i/true_end.png
+%%DATADIR%%/i/wuss_ending.png
+%%DATADIR%%/m/CT_BOSS.MOD
+%%DATADIR%%/m/Cv_boss.mod
+%%DATADIR%%/m/FINALBAT.s3m
+%%DATADIR%%/m/Fr_boss.mod
+%%DATADIR%%/m/ICEFRONT.S3M
+%%DATADIR%%/m/Wood.s3m
+%%DATADIR%%/m/amblight.xm
+%%DATADIR%%/m/cave.xm
+%%DATADIR%%/m/cave06.s3m
+%%DATADIR%%/m/cavern.xm
+%%DATADIR%%/m/fear2.mod
+%%DATADIR%%/m/iller_knarkloader_final.xm
+%%DATADIR%%/m/rpg_bat1.xm
+@dirrm %%DATADIR%%/m
+@dirrm %%DATADIR%%/i
+@dirrm %%DATADIR%%/d
+@dirrm %%DATADIR%%/a
+@dirrm %%DATADIR%%