summaryrefslogtreecommitdiff
path: root/games/fceux
diff options
context:
space:
mode:
authorMatteo Bernardini <ponce@slackbuilds.org>2012-09-17 20:15:01 +0200
committerRobby Workman <rworkman@slackbuilds.org>2012-09-17 23:34:12 -0500
commit63fb4f0580b81fa6b10833d39920a5ac441fb895 (patch)
tree0dd65368bb9ec5e021c88e97f2456e010b445e9f /games/fceux
parent0713c4ca79748b6ab0365ff92cdf0dd7e19180ca (diff)
downloadslackbuilds-63fb4f0580b81fa6b10833d39920a5ac441fb895.tar.gz
games/fceux: Updated to subversion revision r2668.
Rewritten the patch to fix underlinking. Modified the definition of CFLAGS to let the build system get them. Various cleanups. Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'games/fceux')
-rw-r--r--games/fceux/fceux-2.1.5-underlink.patch22
-rw-r--r--games/fceux/fceux-r2668.patch31
-rw-r--r--games/fceux/fceux.SlackBuild37
-rw-r--r--games/fceux/fceux.info8
4 files changed, 54 insertions, 44 deletions
diff --git a/games/fceux/fceux-2.1.5-underlink.patch b/games/fceux/fceux-2.1.5-underlink.patch
deleted file mode 100644
index 0a09440838..0000000000
--- a/games/fceux/fceux-2.1.5-underlink.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-diff -up fceu2.1.5/SConstruct.00 fceu2.1.5/SConstruct
---- fceu2.1.5/SConstruct.00 2011-06-11 08:32:32.807001855 -0700
-+++ fceu2.1.5/SConstruct 2011-06-11 08:33:05.347001851 -0700
-@@ -11,7 +11,7 @@ opts.AddVariables(
- BoolVariable('LUA', 'Enable Lua support', 1),
- BoolVariable('NEWPPU', 'Enable new PPU core', 1),
- BoolVariable('CREATE_AVI', 'Enable avi creation support (SDL only)', 1),
-- BoolVariable('LOGO', 'Enable a logoscreen when creating avis (SDL only)', '1'),
-+ BoolVariable('LOGO', 'Enable a logoscreen when creating avis (SDL only)', '0'),
- BoolVariable('GTK', 'Enable GTK2 GUI (SDL only)', 1),
- BoolVariable('GTK3', 'Enable GTK3 GUI (BROKEN/EXPERIMENTAL)', 0),
- )
-@@ -70,6 +70,9 @@ else:
- env.ParseConfig('pkg-config --cflags --libs gtk+-3.0')
- env.Append(CPPDEFINES=["_GTK3"])
- env.Append(CCFLAGS = ["-D_GTK"])
-+ env.Append(LIBS =["-lz"])
-+ env.Append(LIBS =["-ldl"])
-+
- ### Lua platform defines
- ### Applies to all files even though only lua needs it, but should be ok
- if env['LUA']:
diff --git a/games/fceux/fceux-r2668.patch b/games/fceux/fceux-r2668.patch
new file mode 100644
index 0000000000..8209efd941
--- /dev/null
+++ b/games/fceux/fceux-r2668.patch
@@ -0,0 +1,31 @@
+diff -Naur fceur2668.orig/SConstruct fceur2668/SConstruct
+--- fceur2668.orig/SConstruct 2012-09-11 11:58:00.000000000 +0200
++++ fceur2668/SConstruct 2012-09-17 11:11:09.082042995 +0200
+@@ -19,7 +19,7 @@
+ BoolVariable('LUA', 'Enable Lua support', 1),
+ BoolVariable('NEWPPU', 'Enable new PPU core', 1),
+ BoolVariable('CREATE_AVI', 'Enable avi creation support (SDL only)', 1),
+- BoolVariable('LOGO', 'Enable a logoscreen when creating avis (SDL only)', '1'),
++ BoolVariable('LOGO', 'Enable a logoscreen when creating avis (SDL only)', '0'),
+ BoolVariable('GTK', 'Enable GTK2 GUI (SDL only)', 1),
+ BoolVariable('GTK3', 'Enable GTK3 GUI (SDL only)', 0),
+ BoolVariable('CLANG', 'Compile with llvm-clang instead of gcc', 0)
+@@ -30,8 +30,8 @@
+ env = Environment(options = opts)
+
+ #### Uncomment this for a public release ###
+-# env.Append(CPPDEFINES=["PUBLIC_RELEASE"])
+-# env['DEBUG'] = 0
++env.Append(CPPDEFINES=["PUBLIC_RELEASE"])
++env['DEBUG'] = 0
+ ############################################
+
+ # LSB_FIRST must be off for PPC to compile
+@@ -97,6 +97,7 @@
+ env.ParseConfig('pkg-config --cflags --libs gtk+-3.0')
+ env.Append(CPPDEFINES=["_GTK3"])
+ env.Append(CCFLAGS = ["-D_GTK"])
++ env.Append(LIBS =["-lz","-ldl"])
+
+ ### Lua platform defines
+ ### Applies to all files even though only lua needs it, but should be ok
diff --git a/games/fceux/fceux.SlackBuild b/games/fceux/fceux.SlackBuild
index fe285aac5a..682a580ee7 100644
--- a/games/fceux/fceux.SlackBuild
+++ b/games/fceux/fceux.SlackBuild
@@ -5,7 +5,7 @@
# Written by M.Dinslage (daedra1980@gmail.com)
PRGNAM=fceux
-VERSION=${VERSION:-2.1.5}
+VERSION=${VERSION:-r2668}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -23,16 +23,16 @@ PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
if [ "$ARCH" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ SLKCFLAGS="'-O2', '-march=i486', '-mtune=i686'"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
- SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ SLKCFLAGS="'-O2', '-march=i686', '-mtune=i686'"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
- SLKCFLAGS="-O2 -fPIC"
+ SLKCFLAGS="'-O2', '-fPIC'"
LIBDIRSUFFIX="64"
else
- SLKCFLAGS="-O2"
+ SLKCFLAGS="'-O2'"
LIBDIRSUFFIX=""
fi
@@ -41,10 +41,9 @@ set -e # Exit on most errors
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
-rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/$PRGNAM-$VERSION.src.tar.bz2
+rm -rf fceu$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.src.tar.?z*
cd fceu$VERSION
-patch -p1 < $CWD/fceux-2.1.5-underlink.patch
chown -R root:root .
find . \
\( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
@@ -52,26 +51,28 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
+# Fix underlinking and disable debug with a patch
+patch -p1 < $CWD/fceux-r2668.patch
+# Default prefix is /usr, set our CFLAGS
+sed -i \
+ -e "s|/local||" \
+ -e "s|'-Wall'|${SLKCFLAGS}, '-Wall'|" \
+ SConstruct
+
scons
#Install binary
-mkdir -p $PKG/usr/games
-install -m 0755 bin/fceux $PKG/usr/games
+install -m 0755 -D bin/$PRGNAM $PKG/usr/games/$PRGNAM
-#install man pages
+#install the man page
mkdir -p $PKG/usr/man/man6
-install -m 0644 documentation/fceux.6 $PKG/usr/man/man6
+gzip -c documentation/$PRGNAM.6 > $PKG/usr/man/man6/$PRGNAM.6.gz
find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
-find $PKG/usr/man -type f -exec gzip -9 {} \;
-for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
-
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a \
- bin/fceux.chm COPYING INSTALL README-SDL TODO-PROJECT \
- $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a documentation/* COPYING *.txt *.md $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
#Add icon and application launcher
diff --git a/games/fceux/fceux.info b/games/fceux/fceux.info
index e028b23a57..57ee14d833 100644
--- a/games/fceux/fceux.info
+++ b/games/fceux/fceux.info
@@ -1,10 +1,10 @@
PRGNAM="fceux"
-VERSION="2.1.5"
+VERSION="r2668"
HOMEPAGE="http://fceux.com/web/home.html"
-DOWNLOAD="http://downloads.sourceforge.net/fceultra/fceux-2.1.5.src.tar.bz2"
-MD5SUM="e8b20e62bbbb061b1a59d51b47c827bd"
+DOWNLOAD="http://ponce.cc/slackware/sources/repo/fceux-r2668.src.tar.xz"
+MD5SUM="42dd2194ddf292baf9a55475faf27d9d"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
-REQUIRES="scons"
+REQUIRES="lua scons"
MAINTAINER="M.Dinslage"
EMAIL="daedra1980@gmail.com"