Merge pull request #3005 from pullmoll/mog

New package: mog-0.63
This commit is contained in:
Jürgen Buchmüller 2015-11-19 11:58:41 +01:00
commit 128f76ae4d
5 changed files with 99 additions and 0 deletions

1
srcpkgs/mog-data Symbolic link
View File

@ -0,0 +1 @@
mog

View File

@ -0,0 +1,48 @@
--- build/linux/Makefile 2009-03-13 14:20:17.000000000 +0100
+++ build/linux/Makefile 2015-11-18 18:51:17.614646183 +0100
@@ -3,11 +3,12 @@
PREFIX = /usr
EXTRADIR = ./build/linux
-GAMEDIR = $(PREFIX)/games
-STARTUP = $(GAMEDIR)/$(EXE)
-BINDIR = $(PREFIX)/share/games/$(EXE)
-ICNDIR = $(PREFIX)/share/pixmaps
-APPDIR = $(PREFIX)/share/applications
+GAMEDIR = $(DESTDIR)/$(PREFIX)/share
+BINDIR = $(DESTDIR)/$(PREFIX)/share/mog
+ICNDIR = $(DESTDIR)/$(PREFIX)/share/pixmaps
+APPDIR = $(DESTDIR)/$(PREFIX)/share/applications
+USRBIN = $(DESTDIR)/$(PREFIX)/bin
+STARTUP = $(USRBIN)/mog
DATA = graphics rooms sound leeme.txt liesmich.txt readme.txt MoG-FAQ.txt LICENSE
ICON = mog.png
@@ -27,8 +27,6 @@
$(SRC)/shrines.o $(SRC)/sound.o
CC = g++
-CFLAGS = -g3 -O3 -Wno-write-strings `sdl-config --cflags`
-LDFLAGS = `sdl-config --libs` -lSDL_image -lSDL_mixer -lSDL_sound
RM = rm -f
CP = cp -r
MD = mkdir -p
@@ -42,8 +40,7 @@
$(CC) $(CFLAGS) -c $< -o $@
$(EXE): $(OBJS)
- $(CC) $(LDFLAGS) $^ -o $@
- @$(STRIP) $@
+ $(CC) $(LDFLAGS) $^ @LIBS@ -o $@
@$(ECHO) " o If there are no errors, the game compiled succesfully"
clean:
@@ -55,6 +54,7 @@
@$(CP) "$(EXE)" $(DATA) "$(BINDIR)"
@$(ECHO) " o Creating startup script $(STARTUP)"
@$(MD) "$(GAMEDIR)"
+ @$(MD) "$(USRBIN)"
@$(ECHO) "#!/bin/sh" >"$(STARTUP)"
- @$(ECHO) "cd \"$(BINDIR)\" && ./$(EXE); cd -" >>"$(STARTUP)"
+ @$(ECHO) "cd /usr/share/mog && ./$(EXE); cd -" >>"$(STARTUP)"
@$(CHMOD) 755 "$(STARTUP)"

View File

@ -0,0 +1,12 @@
--- sources/path.cpp 2008-09-13 21:31:49.000000000 +0200
+++ sources/path.cpp 2015-11-18 19:02:00.715596008 +0100
@@ -10,7 +10,9 @@
#include <stdio.h>
#include <string.h>
+#if !defined(NAME_MAX)
#define NAME_MAX 256
+#endif
/* Paths: */

37
srcpkgs/mog/template Normal file
View File

@ -0,0 +1,37 @@
# Template file for 'mog'
pkgname=mog
version=0.63
revision=1
_build=1548
wrksrc=${pkgname}-${version}.${_build}
build_style=gnu-makefile
makedepends="SDL_image-devel SDL_mixer-devel SDL_sound-devel"
depends="mog-data>=${version}_${revision}"
short_desc="Remake of classic MSX game The Maze of Galious"
maintainer="Jürgen Buchmüller <pullmoll@t-online.de>"
license="GPL-2"
homepage="http://www.braingames.getput.com/mog/"
distfiles="http://urchlay.naptime.net/~urchlay/src/mog.src_${version}-${_build}.tgz"
checksum=707bbc1b167a55989916f803dbe55c288652fb54df6194be029c41be99e9ec3a
CFLAGS="-g3 -O3 -Wno-write-strings -I${XBPS_CROSS_BASE}/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT"
pre_build() {
local libs="-L${XBPS_CROSS_BASE}/usr/lib"
libs+=" -lstdc++ -lm"
libs+=" -lSDL_image"
libs+=" -lSDL_mixer"
libs+=" -lSDL_sound"
libs+=" -lSDL -lpthread"
sed -i build/linux/Makefile -e "s;@LIBS@;${libs};"
}
mog-data_package() {
short_desc+=" - data files"
noarch=yes
pkg_install() {
vmove usr/share/mog/graphics
vmove usr/share/mog/sound
vmove usr/share/mog/rooms
}
}

1
srcpkgs/mog/update Normal file
View File

@ -0,0 +1 @@
pattern='mog.src_\K[\d]+\.[\d]+'