diff options
Diffstat (limited to 'games/bsnes')
-rw-r--r-- | games/bsnes/Makefile-qt.patch | 17 | ||||
-rw-r--r-- | games/bsnes/README | 2 | ||||
-rw-r--r-- | games/bsnes/bsnes-0.064-makefile.patch | 126 | ||||
-rw-r--r-- | games/bsnes/bsnes.SlackBuild | 63 | ||||
-rw-r--r-- | games/bsnes/bsnes.info | 8 |
5 files changed, 165 insertions, 51 deletions
diff --git a/games/bsnes/Makefile-qt.patch b/games/bsnes/Makefile-qt.patch deleted file mode 100644 index 7c37b026f5..0000000000 --- a/games/bsnes/Makefile-qt.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff -Naur src.orig/lib/nall/Makefile-qt src/lib/nall/Makefile-qt ---- src.orig/lib/nall/Makefile-qt 2009-06-21 13:25:40.000000000 +0000 -+++ src/lib/nall/Makefile-qt 2009-07-14 20:45:25.000000000 +0000 -@@ -7,11 +7,11 @@ - # $(qtlib) -- libraries for linking - - ifeq ($(moc),) --moc := moc -+moc := moc-qt4 - endif - - ifeq ($(rcc),) --rcc := rcc -+rcc := rcc-qt4 - endif - - ifeq ($(platform),x) diff --git a/games/bsnes/README b/games/bsnes/README index 724a924188..bfe2ebbacd 100644 --- a/games/bsnes/README +++ b/games/bsnes/README @@ -6,4 +6,4 @@ The emulator does not focus on things that would hinder accuracy. This includes speed and game-specific hacks for compatibility. As a result, the minimum system requirements for bsnes are very high. -This requires OpenAL. +Bsnes requires OpenAL. diff --git a/games/bsnes/bsnes-0.064-makefile.patch b/games/bsnes/bsnes-0.064-makefile.patch new file mode 100644 index 0000000000..754dfe23dd --- /dev/null +++ b/games/bsnes/bsnes-0.064-makefile.patch @@ -0,0 +1,126 @@ +diff --git a/snesfilter/Makefile b/snesfilter/Makefile +index 089b86e..08ba81b 100755 +--- a/../snesfilter/Makefile ++++ b/../snesfilter/Makefile +@@ -5,12 +5,12 @@ include nall/qt/Makefile + + c := $(compiler) -std=gnu99 + cpp := $(subst cc,++,$(compiler)) -std=gnu++0x +-flags := -O3 -I. -Iobj -fomit-frame-pointer $(qtinc) ++flags := $(CXXFLAGS) -I. -Iobj -fomit-frame-pointer $(qtinc) + link := + + ifeq ($(platform),x) + flags := -fPIC -fopenmp $(flags) +- link += -s -fopenmp -lpthread -lgomp ++ link += -fopenmp -lpthread -lgomp + else ifeq ($(platform),osx) + flags := -fPIC -fopenmp $(flags) + link += -fopenmp -lpthread -lgomp +@@ -73,9 +73,8 @@ endif + + install: + ifeq ($(platform),x) +- install -D -m 755 libsnesfilter.a $(DESTDIR)$(prefix)/lib +- install -D -m 755 libsnesfilter.so $(DESTDIR)$(prefix)/lib +- ldconfig -n $(DESTDIR)$(prefix)/lib ++ install -D -m 755 libsnesfilter.a $(DESTDIR)$(prefix)/lib/libsnesfilter.a ++ install -D -m 755 libsnesfilter.so $(DESTDIR)$(prefix)/lib/libsnesfilter.so + else ifeq ($(platform),osx) + cp libsnesfilter.dylib /usr/local/lib/libsnesfilter.dylib + endif +diff --git a/snesreader/Makefile b/snesreader/Makefile +index 761317b..868a0cc 100755 +--- a/../snesreader/Makefile ++++ b/../snesreader/Makefile +@@ -5,12 +5,11 @@ include nall/qt/Makefile + + c := $(compiler) -std=gnu99 + cpp := $(subst cc,++,$(compiler)) -std=gnu++0x +-flags := -O3 -I. -Iobj -fomit-frame-pointer ++flags := $(CXXFLAGS) -I. -Iobj -fomit-frame-pointer + link := + + ifeq ($(platform),x) + flags := -fPIC $(flags) +- link += -s + else ifeq ($(platform),osx) + flags := -fPIC $(flags) + endif +@@ -171,9 +170,8 @@ endif + + install: + ifeq ($(platform),x) +- install -D -m 755 libsnesreader.a $(DESTDIR)$(prefix)/lib +- install -D -m 755 libsnesreader.so $(DESTDIR)$(prefix)/lib +- ldconfig -n $(DESTDIR)$(prefix)/lib ++ install -D -m 755 libsnesreader.a $(DESTDIR)$(prefix)/lib/libsnesreader.a ++ install -D -m 755 libsnesreader.so $(DESTDIR)$(prefix)/lib/libsnesreader.so + else ifeq ($(platform),osx) + cp libsnesreader.dylib /usr/local/lib/libsnesreader.dylib + endif +diff --git a/src/Makefile b/src/Makefile +index c3c1fe9..4b5de6d 100755 +--- a/Makefile ++++ b/Makefile +@@ -4,7 +4,7 @@ ui := ui_qt + # compiler + c := $(compiler) -std=gnu99 + cpp := $(subst cc,++,$(compiler)) -std=gnu++0x +-flags := -O3 -fomit-frame-pointer -I. ++flags := $(CXXFLAGS) -fomit-frame-pointer -I. + link := + objects := + +@@ -17,7 +17,7 @@ objects := + + # platform + ifeq ($(platform),x) +- link += -s -ldl -lX11 -lXext ++ link += -ldl -lX11 -lXext + else ifeq ($(platform),osx) + else ifeq ($(platform),win) + link += -mwindows -mthreads +@@ -60,8 +60,8 @@ endif + install: + ifeq ($(platform),x) + install -D -m 755 ../bsnes $(DESTDIR)$(prefix)/bin/bsnes +- install -D -m 644 data/bsnes.png $(DESTDIR)$(prefix)/share/pixmaps/bsnes.png +- install -D -m 644 data/bsnes.desktop $(DESTDIR)$(prefix)/share/applications/bsnes.desktop ++ install -D -m 644 data/bsnes.png $(DESTDIR)/usr/share/pixmaps/bsnes.png ++ install -D -m 644 data/bsnes.desktop $(DESTDIR)/usr/share/applications/bsnes.desktop + endif + + uninstall: +diff --git a/supergameboy/Makefile b/supergameboy/Makefile +index 60409af..cbef9ac 100755 +--- a/../supergameboy/Makefile ++++ b/../supergameboy/Makefile +@@ -2,14 +2,13 @@ include nall/Makefile + + c := $(compiler) -std=gnu99 + cpp := $(subst cc,++,$(compiler)) -std=gnu++0x +-flags := -O3 -fomit-frame-pointer -I. -Icommon -Ilibgambatte/include -Ilibgambatte/src ++flags := $(CXXFLAGS) -fomit-frame-pointer -I. -Icommon -Ilibgambatte/include -Ilibgambatte/src + link := + + ifeq ($(platform),osx) + flags := -fPIC $(flags) + else ifeq ($(platform),x) + flags := -fPIC $(flags) +- link += -s + endif + + objects := supergameboy +@@ -113,9 +112,8 @@ install: + ifeq ($(platform),osx) + cp libsupergameboy.dylib /usr/local/lib/libsupergameboy.dylib + else +- install -D -m 755 libsupergameboy.a $(DESTDIR)$(prefix)/lib +- install -D -m 755 libsupergameboy.so $(DESTDIR)$(prefix)/lib +- ldconfig -n $(DESTDIR)$(prefix)/lib ++ install -D -m 755 libsupergameboy.a $(DESTDIR)$(prefix)/lib/libsupergameboy.a ++ install -D -m 755 libsupergameboy.so $(DESTDIR)$(prefix)/lib/libsupergameboy.so + endif + + clean: diff --git a/games/bsnes/bsnes.SlackBuild b/games/bsnes/bsnes.SlackBuild index 2b974ec2db..f56360481d 100644 --- a/games/bsnes/bsnes.SlackBuild +++ b/games/bsnes/bsnes.SlackBuild @@ -5,18 +5,16 @@ # Written by Larry Hajali <larryhaja[at]gmail[dot]com> PRGNAM=bsnes -VERSION=${VERSION:-0.058} +VERSION=${VERSION:-0.064} SRCVER=${VERSION:2} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} -# Automatically determine the architecture we're building on: if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; - arm*) ARCH=arm ;; - # Unless $ARCH is already set, use uname -m for all other archs: - *) ARCH=$( uname -m ) ;; + i?86) export ARCH=i486 ;; + arm*) export ARCH=arm ;; + *) export ARCH=$( uname -m ) ;; esac fi @@ -25,19 +23,18 @@ TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} -# Determine if we use pulseaudio with build. Default is no. -# Also backport bsnes for Slackware <= 13.0. -USE_PULSE=${USE_PULSE:-no} -OLD_SLACK=${OLD_SLACK:-no} - if [ "$ARCH" = "i486" ]; then SLKCFLAGS="-O2 -march=i486 -mtune=i686" + LIBDIRSUFFIX="" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" + LIBDIRSUFFIX="" elif [ "$ARCH" = "x86_64" ]; then SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" else SLKCFLAGS="-O2" + LIBDIRSUFFIX="" fi set -e @@ -49,7 +46,6 @@ rm -rf $PRGNAM-$VERSION mkdir $PRGNAM-$VERSION cd $PRGNAM-$VERSION tar xvf $CWD/${PRGNAM}_v${SRCVER}.tar.bz2 -cd src chown -R root:root . find . \ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ @@ -57,37 +53,46 @@ find . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; -# Use custom SLKCFLAGS. -sed -i "s|-O3|${SLKCFLAGS}|" Makefile +cd src -# For older Slackware versions that have *-qt4 extension. -if [ "$OLD_SLACK" == "yes" ]; then - patch -p1 < $CWD/Makefile-qt.patch -fi +# Patch makefile so SLKCFLAGS and LIBDIRSUFFIX are recognized. +cat $CWD/bsnes-0.064-makefile.patch | \ + sed -e "/^\+/s|/lib/|/lib${LIBDIRSUFFIX}/|g" | \ + patch -p1 -# Determine if we get rid of pulseaudio support. -if [ "$USE_PULSE" == "no" ]; then - sed -i \ - -e 's|audio\.pulseaudio ||' \ - -e '/pulse/d' Makefile -fi +# Remove pulseaudio as there is no package for it at SBo. +# Comment out or delete the following 4 lines to enable pulseaudio. +sed -i \ + -e 's|audio.pulseaudio ||' \ + -e 's|audio.pulseaudiosimple ||' \ + -e '/pulse/d' ui_qt/Makefile +CXXFLAGS="$SLKCFLAGS" \ make \ platform=x \ compiler=gcc \ - enable_gzip=true \ - enable_jma=true \ prefix=/usr make install DESTDIR=$PKG prefix=/usr +# Install plugins. +for i in snesfilter snesreader supergameboy; do + cd ../${i} + CXXFLAGS="$SLKCFLAGS" \ + make \ + platform=x \ + compiler=gcc \ + prefix=/usr + + make install DESTDIR=$PKG prefix=/usr + cd - +done + find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a \ - data/*.html \ - $PKG/usr/doc/$PRGNAM-$VERSION +cp -a data/*.html $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild find $PKG/usr/doc -type f -exec chmod 0644 {} \; diff --git a/games/bsnes/bsnes.info b/games/bsnes/bsnes.info index f71692cf8f..f8119805fd 100644 --- a/games/bsnes/bsnes.info +++ b/games/bsnes/bsnes.info @@ -1,10 +1,10 @@ PRGNAM="bsnes" -VERSION="0.058" +VERSION="0.064" HOMEPAGE="http://byuu.org/bsnes/" -DOWNLOAD="http://byuusan.kuro-hitsuji.net/bsnes_v058.tar.bz2" -MD5SUM="dfd42e658455f4470715b8cc32cceb3c" +DOWNLOAD="http://bsnes.googlecode.com/files/bsnes_v064.tar.bz2" +MD5SUM="4830e56e7805a869ddd405bc0d7badfb" DOWNLOAD_x86_64="" MD5SUM_x86_64="" MAINTAINER="Larry Hajali" EMAIL="larryhaja[at]gmail[dot]com" -APPROVED="Erik Hanson" +APPROVED="rworkman" |