From 704076b103897b3d7c0e168e0d32abd81b035981 Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Thu, 30 Dec 2021 02:34:05 -0500 Subject: games/zsnes: Remove statifier support (broken). Signed-off-by: B. Watson Signed-off-by: Willy Sudiarto Raharjo --- games/zsnes/zsnes.SlackBuild | 69 +++++++++++++++++--------------------------- 1 file changed, 26 insertions(+), 43 deletions(-) (limited to 'games/zsnes/zsnes.SlackBuild') diff --git a/games/zsnes/zsnes.SlackBuild b/games/zsnes/zsnes.SlackBuild index 0aaabd3fff729..2df9765ee80b4 100644 --- a/games/zsnes/zsnes.SlackBuild +++ b/games/zsnes/zsnes.SlackBuild @@ -23,6 +23,11 @@ # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +# 20211230 bkw: +# - statifier's never going to work on current/15.0, its author hasn't +# updated it since 2016. so get rid of the 64-bit download and code +# to support it. sorry. + # 20211215 bkw: BUILD=5 # - fix -current 32-bit build. # - new-style icons. @@ -65,8 +70,6 @@ if [ "$ARCH" = "i586" ]; then SLKCFLAGS="-O2 -march=i586 -mtune=i686" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" -elif [ "$ARCH" = "x86_64" ]; then - echo "=== $ARCH detected, using statified binary" else printf "\n Error: $PRGNAM won't compile on $ARCH\n\n" exit 1 @@ -88,47 +91,27 @@ chown -R root:root . find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \ \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+ -if [ "$ARCH" = "x86_64" ]; then - # Can't compile, so use a statified binary. This was prepared - # by compiling zsnes with the same configure flags as below, - # plus --disable-opengl, then converting with: - # $ statifier \ - # --set=LD_PRELOAD=/usr/lib/libudev.so:/usr/lib/libaoss.so:/usr/lib/libasound.so \ - # zsnes zsnes.static - # Unfortunately this won't work with OpenGL because the shared libs - # are driver-specific: I could preload the nvidia driver, but the - # result would only work on systems that use nvidia (not AMD or intel, - # or even nouveau). - mkdir -p $PKG/usr/games $PKG/usr/doc/$PRGNAM-$VERSION $PKG/usr/man/man1 - xz -d < $CWD/$PRGNAM.static.xz > $PKG/usr/games/$PRGNAM - chmod 755 $PKG/usr/games/$PRGNAM - - # Docs and man page still come from the source. - cp -a docs/* $PKG/usr/doc/$PRGNAM-$VERSION - cp -a linux/$PRGNAM.1 $PKG/usr/man/man1 -else - # GCC 4.7 fixes from Debian - cat $CWD/0012-Fix-build-with-gcc-4.7.patch | patch -p2 --verbose - - # Fix for libpng16 (thanks to Arch Linux) - # https://projects.archlinux.org/svntogit/community.git/plain/trunk/zsnes-1.51-libpng15.patch?h=packages/zsnes - patch -p1 < $CWD/zsnes-1.51-libpng15.patch - - CFLAGS="$SLKCFLAGS -fcommon -std=c++11" \ - force_arch="$ARCH" \ - ./configure \ - --prefix=/usr \ - --enable-release \ - --disable-cpucheck \ - --disable-debugger - - CFLAGS="$SLKCFLAGS -fcommon -std=c++11" \ - force_arch="$ARCH" \ - make - make install DESTDIR=$PKG - mv $PKG/usr/bin $PKG/usr/games # configure ignores --bindir, grr! - strip $PKG/usr/games/$PRGNAM -fi +# GCC 4.7 fixes from Debian +cat $CWD/0012-Fix-build-with-gcc-4.7.patch | patch -p2 --verbose + +# Fix for libpng16 (thanks to Arch Linux) +# https://projects.archlinux.org/svntogit/community.git/plain/trunk/zsnes-1.51-libpng15.patch?h=packages/zsnes +patch -p1 < $CWD/zsnes-1.51-libpng15.patch + +CFLAGS="$SLKCFLAGS -fcommon -std=c++11" \ +force_arch="$ARCH" \ +./configure \ + --prefix=/usr \ + --enable-release \ + --disable-cpucheck \ + --disable-debugger + +CFLAGS="$SLKCFLAGS -fcommon -std=c++11" \ +force_arch="$ARCH" \ +make +make install DESTDIR=$PKG +mv $PKG/usr/bin $PKG/usr/games # configure ignores --bindir, grr! +strip $PKG/usr/games/$PRGNAM # Man page belongs in section 6, since this is a game. mkdir -p $PKG/usr/man/man6 -- cgit v1.2.3