aboutsummaryrefslogtreecommitdiff
path: root/games/nestopia
diff options
context:
space:
mode:
authorDugan Chen <thedoogster [t] gmail [dot] com>2017-12-17 18:35:37 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2017-12-17 18:35:37 +0700
commitfe223ce487c466de0b99b61cf49bb93b1bd02ca9 (patch)
tree363994949cbd82b710212d3d30bd3855e08d430a /games/nestopia
parent900ae7465e6d72914088a8715fffb90d73a37e9c (diff)
games/nestopia: Updated for version 1.48.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'games/nestopia')
-rw-r--r--games/nestopia/CMakeLists.txt.patch11
-rw-r--r--games/nestopia/Makefile.patch22
-rw-r--r--games/nestopia/nestopia.SlackBuild27
-rw-r--r--games/nestopia/nestopia.info6
4 files changed, 32 insertions, 34 deletions
diff --git a/games/nestopia/CMakeLists.txt.patch b/games/nestopia/CMakeLists.txt.patch
new file mode 100644
index 000000000000..66ba330ec0a8
--- /dev/null
+++ b/games/nestopia/CMakeLists.txt.patch
@@ -0,0 +1,11 @@
+--- CMakeLists.txt.orig 2017-12-16 19:36:37.881668295 -0800
++++ CMakeLists.txt 2017-12-16 19:36:51.612529617 -0800
+@@ -424,7 +424,7 @@
+ install( FILES source/unix/icons/svg/nespad.svg DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/icons/hicolor/scalable/apps )
+
+ # documentation
+-install( FILES AUTHORS ChangeLog README.md README.unix DESTINATION ${CMAKE_INSTALL_DOCDIR} )
++install( FILES AUTHORS ChangeLog README.md DESTINATION ${CMAKE_INSTALL_DOCDIR} )
+ install( FILES readme.html DESTINATION ${CMAKE_INSTALL_DOCDIR}/html )
+
+ option( ENABLE_DOC "Install full documentation suite" )
diff --git a/games/nestopia/Makefile.patch b/games/nestopia/Makefile.patch
deleted file mode 100644
index 26bf7391d2e3..000000000000
--- a/games/nestopia/Makefile.patch
+++ /dev/null
@@ -1,22 +0,0 @@
---- Makefile.orig 2013-07-29 16:43:11.000000000 -0700
-+++ Makefile 2014-03-23 23:09:17.353715034 -0700
-@@ -181,14 +181,13 @@
-
- install:
- mkdir -p $(DATADIR)/icons
-- mkdir -p $(PREFIX)/share/pixmaps
-- install -m 0755 $(BIN) $(BINDIR)
-- install -m 0644 source/unix/icons/nestopia.desktop $(DATADIR)
-- install -m 0644 NstDatabase.xml $(DATADIR)
-+ install -Dm 0755 $(BIN) $(BINDIR)/$(BIN)
-+ install -Dm 0644 source/unix/icons/nestopia.desktop $(DATADIR)/nestopia.desktop
-+ install -Dm 0644 NstDatabase.xml $(DATADIR)/NstDatabase.xml
- install -m 0644 source/unix/icons/*.png $(DATADIR)/icons
- install -m 0644 source/unix/icons/*.svg $(DATADIR)/icons
-- install -m 0644 source/unix/icons/nestopia.svg $(PREFIX)/share/pixmaps
-- xdg-desktop-menu install --novendor $(DATADIR)/nestopia.desktop
-+ install -Dm 0644 source/unix/icons/nestopia.svg $(PREFIX)/share/pixmaps/nestopia.svg
-+ install -Dm 0644 $(DATADIR)/nestopia.desktop $(PREFIX)/share/applications/nestopia.desktop
-
- uninstall:
- xdg-desktop-menu uninstall $(DATADIR)/nestopia.desktop
diff --git a/games/nestopia/nestopia.SlackBuild b/games/nestopia/nestopia.SlackBuild
index f45e53f23334..9b148e105275 100644
--- a/games/nestopia/nestopia.SlackBuild
+++ b/games/nestopia/nestopia.SlackBuild
@@ -5,13 +5,13 @@
# Written by Dugan Chen (thedoogster@gmail.com)
PRGNAM=nestopia
-VERSION=${VERSION:-1.46.2}
+VERSION=${VERSION:-1.48}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
- i?86) ARCH=i486 ;;
+ i?86) ARCH=i586 ;;
arm*) ARCH=arm ;;
*) ARCH=$( uname -m ) ;;
esac
@@ -53,17 +53,26 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-patch < $CWD/Makefile.patch
-sed -i "s/-O3 -g3/-g3 ${SLKCFLAGS}/g" Makefile
-make -j1 PREFIX=/usr
-make install PREFIX=$PKG/usr
+patch --verbose < $CWD/CMakeLists.txt.patch
+
+mkdir -p build
+cd build
+ cmake \
+ -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
+ -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_BUILD_TYPE=Release .. \
+ -DENABLE_DOC=ON
+ make
+ make install DESTDIR=$PKG
+cd ..
+
+mkdir -p $PKG/usr/doc
+mv $PKG/usr/share/doc/$PRGNAM $PKG/usr/doc/$PRGNAM-$VERSION
find $PKG -print0 | xargs -0 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 COPYING README.md README.unix changelog.txt readme.html $PKG/usr/doc/$PRGNAM-$VERSION
-cp -ar doc/ $PKG/usr/doc/$PRGNAM-$VERSION/api/
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install
diff --git a/games/nestopia/nestopia.info b/games/nestopia/nestopia.info
index e431da32af85..e6c57ca4369a 100644
--- a/games/nestopia/nestopia.info
+++ b/games/nestopia/nestopia.info
@@ -1,8 +1,8 @@
PRGNAM="nestopia"
-VERSION="1.46.2"
+VERSION="1.48"
HOMEPAGE="http://0ldsk00l.ca/nestopia/"
-DOWNLOAD="http://downloads.sourceforge.net/project/nestopiaue/1.46/nestopia-1.46.2.tgz"
-MD5SUM="561ec0e71117cbf7514db235394cd958"
+DOWNLOAD="http://downloads.sourceforge.net/project/nestopiaue/1.48/nestopia-1.48.tgz"
+MD5SUM="028172125a16625f51d470293babacb2"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="SDL2"