summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author Matteo Bernardini2017-06-23 07:23:48 +0200
committer Matteo Bernardini2018-06-09 08:38:20 +0200
commit14081a87e49a69edcf27ee93e3518f2cd8b38825 (patch)
treefa940790aed88ad4f8ada24d751d14bdee5839c1
parent81c344443219574587ae3d6bccb8f19c1bd346af (diff)
downloadold.slackbuilds-pcsxr.tar.gz
games/pcsxr: Patch for the newer zlib.pcsxr
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
-rw-r--r--games/pcsxr/pcsxr.SlackBuild3
-rw-r--r--games/pcsxr/zlib129fix.patch34
2 files changed, 37 insertions, 0 deletions
diff --git a/games/pcsxr/pcsxr.SlackBuild b/games/pcsxr/pcsxr.SlackBuild
index 49eba27447..af5d3b9f33 100644
--- a/games/pcsxr/pcsxr.SlackBuild
+++ b/games/pcsxr/pcsxr.SlackBuild
@@ -69,6 +69,9 @@ 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 {} \;
+# Thanks fedora
+patch -p1 < $CWD/zlib129fix.patch
+
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
LDFLAGS="$SLKLDFLAGS" \
diff --git a/games/pcsxr/zlib129fix.patch b/games/pcsxr/zlib129fix.patch
new file mode 100644
index 0000000000..632e1ceffe
--- /dev/null
+++ b/games/pcsxr/zlib129fix.patch
@@ -0,0 +1,34 @@
+diff --git a/pcsxr/configure.ac b/pcsxr/configure.ac
+index 300bb18..128b4f9 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -113,6 +113,9 @@ if test "x$have_xtest" = xno; then
+ AC_MSG_ERROR([unable to find xtest headers])
+ fi
+
++AC_CHECK_LIB(z, uncompress2,
++[ AC_DEFINE([HAVE_UNCOMPRESS2], [1], [Define if libz supports uncompress2]) ])
++
+ AM_CONDITIONAL(USE_LIBCDIO, false)
+
+ AC_ARG_ENABLE(libcdio, [ --enable-libcdio use GNU libcdio for CD-ROM support (default=no)],
+diff --git a/pcsxr/libpcsxcore/cdriso.c b/pcsxr/libpcsxcore/cdriso.c
+index 04e866d..fb7f28a 100644
+--- a/libpcsxcore/cdriso.c
++++ b/libpcsxcore/cdriso.c
+@@ -1219,6 +1219,7 @@ static int cdread_sub_mixed(FILE *f, unsigned int base, void *dest, int sector)
+ return ret;
+ }
+
++#ifndef HAVE_UNCOMPRESS2
+ static int uncompress2(void *out, unsigned long *out_size, void *in, unsigned long in_size)
+ {
+ static z_stream z;
+@@ -1249,6 +1250,7 @@ static int uncompress2(void *out, unsigned long *out_size, void *in, unsigned lo
+ *out_size -= z.avail_out;
+ return ret == 1 ? 0 : ret;
+ }
++#endif
+
+ static int cdread_compressed(FILE *f, unsigned int base, void *dest, int sector)
+ {