summaryrefslogtreecommitdiff
path: root/user/mednafen
diff options
context:
space:
mode:
Diffstat (limited to 'user/mednafen')
-rw-r--r--user/mednafen/APKBUILD22
-rw-r--r--user/mednafen/ppc.patch11
-rw-r--r--user/mednafen/ppc64.patch13
3 files changed, 39 insertions, 7 deletions
diff --git a/user/mednafen/APKBUILD b/user/mednafen/APKBUILD
index 097454cad..0666bec0f 100644
--- a/user/mednafen/APKBUILD
+++ b/user/mednafen/APKBUILD
@@ -1,7 +1,7 @@
# Contributor: Horst Burkhardt <horst@adelielinux.org>
# Maintainer: Horst Burkhardt <horst@adelielinux.org>
pkgname=mednafen
-pkgver=1.21.3
+pkgver=1.22.1
pkgrel=0
pkgdesc="an emulator for various home gaming consoles"
url="https://mednafen.github.io/"
@@ -12,18 +12,26 @@ license="GPL-2.0-only"
depends=""
makedepends="alsa-lib-dev flac-dev libogg-dev libsndfile-dev libvorbis-dev
lzo-dev sdl2-dev zlib-dev"
-source="https://mednafen.github.io/releases/files/$pkgname-$pkgver.tar.xz"
+source="https://mednafen.github.io/releases/files/$pkgname-$pkgver.tar.xz
+ ppc.patch
+ ppc64.patch
+ "
builddir="$srcdir/$pkgname"
build() {
- cd "$builddir"
- ./configure --prefix=/usr --enable-ss=no
- make
+ ./autogen.sh
+ export CXXFLAGS="$CXXFLAGS -fno-omit-frame-pointer"
+ ./configure \
+ --prefix=/usr \
+ --enable-ss=no \
+ --enable-snes-faust=no
+ make
}
package() {
- cd "$builddir"
make DESTDIR="$pkgdir" install
}
-sha512sums="987c14edae68901f8a693c9f7317063daf4274bb0b650ed05cd01cf4ceb38d76e6ff5446c324447f73727096c74d0bf7f545cdeadfb6291d67656d659de26715 mednafen-1.21.3.tar.xz"
+sha512sums="4e6890b984a812e188a42582e79dfdac28e101ce3bd658044b68f267d5c8b3799ea3f4de3dcac5314a615f17591a537b51e64f6bd165fec01f028b201eb32763 mednafen-1.22.1.tar.xz
+264b22be3af9db57d0e8676d77b57338308764c79a5eae1c7bd3bb211c5e190ec0797e34a952039175395c0b8819e6285f2ac5f652ee0d5b9d1e0eaf43eca6e9 ppc.patch
+84cbff76b16960ec67fec785fc6e8d541db342e9567fb6f4d42c84ced3fc0f0dfe702a8a7fd7af4f84835f8efe289e7cb9cf18766e4196525686eaa23b02537c ppc64.patch"
diff --git a/user/mednafen/ppc.patch b/user/mednafen/ppc.patch
new file mode 100644
index 000000000..0f795f169
--- /dev/null
+++ b/user/mednafen/ppc.patch
@@ -0,0 +1,11 @@
+--- mednafen/configure.ac.old 2019-01-28 06:52:37.000000000 +0000
++++ mednafen/configure.ac 2019-03-24 22:30:31.180000000 +0000
+@@ -765,7 +765,7 @@
+ AM_CONDITIONAL(ARCH_X86_32, true)
+ ;;
+
+- powerpc)
++ powerpc*|ppc*)
+ AC_DEFINE([ARCH_POWERPC], [1], [Define if we are compiling for PPC architectures.])
+ AM_CONDITIONAL(ARCH_POWERPC, true)
+
diff --git a/user/mednafen/ppc64.patch b/user/mednafen/ppc64.patch
new file mode 100644
index 000000000..734af47de
--- /dev/null
+++ b/user/mednafen/ppc64.patch
@@ -0,0 +1,13 @@
+musl is always ELFv2, no matter endianness.
+
+--- mednafen/src/snes/src/lib/libco/ppc.c.old 2019-01-28 06:52:37.000000000 +0000
++++ mednafen/src/snes/src/lib/libco/ppc.c 2019-03-25 03:42:05.330000000 +0000
+@@ -40,7 +40,7 @@
+ /* Whether function calls are indirect through a descriptor,
+ or are directly to function */
+ #ifndef LIBCO_PPCDESC
+- #if !_CALL_SYSV && (_CALL_AIX || _CALL_AIXDESC || LIBCO_PPC64)
++ #if !_CALL_SYSV && (_CALL_AIX || _CALL_AIXDESC || (LIBCO_PPC64 && _CALL_ELF == 1))
+ #define LIBCO_PPCDESC 1
+ #endif
+ #endif