From 9321f90c223e2f6c789c424fd8448409b3dd7f05 Mon Sep 17 00:00:00 2001 From: Dan Horák Date: Aug 09 2011 07:33:47 +0000 Subject: big-endian build fix --- diff --git a/quake3-1.36-build.patch b/quake3-1.36-build.patch new file mode 100644 index 0000000..491cb99 --- /dev/null +++ b/quake3-1.36-build.patch @@ -0,0 +1,26 @@ +diff -up quake3-1.36/code/qcommon/q_platform.h.build quake3-1.36/code/qcommon/q_platform.h +--- quake3-1.36/code/qcommon/q_platform.h.build 2011-08-09 09:15:14.000000000 +0200 ++++ quake3-1.36/code/qcommon/q_platform.h 2011-08-09 09:16:06.000000000 +0200 +@@ -184,10 +184,10 @@ Foundation, Inc., 51 Franklin St, Fifth + #define ARCH_STRING "ppc64" + #elif defined __powerpc__ + #define ARCH_STRING "ppc" +-#elif defined __s390__ +-#define ARCH_STRING "s390" + #elif defined __s390x__ + #define ARCH_STRING "s390x" ++#elif defined __s390__ ++#define ARCH_STRING "s390" + #elif defined __ia64__ + #define ARCH_STRING "ia64" + #elif defined __alpha__ +@@ -348,6 +348,9 @@ float FloatSwap (const float *f); + #error "Endianness defined as both big and little" + #elif defined( Q3_BIG_ENDIAN ) + ++void CopyShortSwap(void *dest, void *src); ++void CopyLongSwap(void *dest, void *src); ++ + #define CopyLittleShort(dest, src) CopyShortSwap(dest, src) + #define CopyLittleLong(dest, src) CopyLongSwap(dest, src) + #define LittleShort(x) ShortSwap(x) diff --git a/quake3.spec b/quake3.spec index aa9df2f..23d87aa 100644 --- a/quake3.spec +++ b/quake3.spec @@ -1,6 +1,6 @@ Name: quake3 Version: 1.36 -Release: 11.svn2102%{?dist} +Release: 12.svn2102%{?dist} Summary: Quake 3 Arena engine (ioquake3 version) Group: Amusements/Games License: GPLv2+ @@ -35,6 +35,8 @@ Patch1: quake3-1.34-rc4-demo-pak.patch # patches from Debian for openarena compatibility (increase some buffer sizes) Patch2: 0011-Double-the-maximum-number-of-cvars.patch Patch3: 0012-Increase-the-command-buffer-from-16K-to-128K-followi.patch +# big-endian build fix +Patch4: quake3-1.36-build.patch BuildRequires: SDL-devel libXt-devel openal-soft-devel libjpeg-devel BuildRequires: speex-devel libvorbis-devel curl-devel desktop-file-utils BuildRequires: zlib-devel @@ -138,6 +140,7 @@ Padman menu entry, which will automatically download the necessary datafiles %patch1 -p1 %patch2 -p1 %patch3 -p1 +%patch4 -p1 # Add jpeg_memsrc cp -p %{SOURCE15} %{SOURCE16} ./code/renderer/ @@ -270,6 +273,9 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %changelog +* Tue Aug 09 2011 Dan Horák - 1.36-12.svn2102 +- big-endian build fix + * Thu Jul 28 2011 Hans de Goede - 1.36-11.svn2102 - Update to 1.36 svn snapshot r2102 - This fixes 2 security issues where a malicious server could execute arbitrary