snes9x: fix linkage and gcc4 problems, closes #2154
authorManuel Teira <manuel.teira@telefonica.net>
Sun, 29 Apr 2007 19:23:42 +0000 (19:23 +0000)
committerKoen Kooi <koen@openembedded.org>
Sun, 29 Apr 2007 19:23:42 +0000 (19:23 +0000)
packages/snes9x/snes9x-sdl/gcc-4.1.patch [new file with mode: 0644]
packages/snes9x/snes9x-sdl_1.39.bb

diff --git a/packages/snes9x/snes9x-sdl/gcc-4.1.patch b/packages/snes9x/snes9x-sdl/gcc-4.1.patch
new file mode 100644 (file)
index 0000000..a63c051
--- /dev/null
@@ -0,0 +1,28 @@
+
+#
+# Patch managed by http://www.holgerschurig.de/patcher.html
+#
+
+--- snes9x-sdl-1.39/dsp1.h~gcc-4.1
++++ snes9x-sdl-1.39/dsp1.h
+@@ -233,8 +233,8 @@
+ void S9xResetDSP1 ();
+ uint8 S9xGetDSP (uint16 Address);
+ void S9xSetDSP (uint8 Byte, uint16 Address);
+-END_EXTERN_C
+ extern struct SDSP1 DSP1;
++END_EXTERN_C
+ #endif
+--- snes9x-sdl-1.39/unix/unix.cpp~gcc-4.1
++++ snes9x-sdl-1.39/unix/unix.cpp
+@@ -1046,7 +1046,7 @@
+ {
+ }
+-static uint8 Buf[MAX_BUFFER_SIZE];
++static uint8 Buf[MAX_BUFFER_SIZE] __attribute__((aligned(4)));
+ #define FIXED_POINT 0x10000
+ #define FIXED_POINT_SHIFT 16
index ce6f5fa..ea4eb44 100644 (file)
@@ -3,10 +3,11 @@ SECTION = "games"
 PRIORITY = "optional"
 DEPENDS = "virtual/libsdl zlib"
 LICENSE = "snes9x"
-PR = "r2"
+PR = "r3"
 
 SRC_URI = "http://www.vanille.de/mirror/snes9x-sdl-${PV}.tar.bz2 \
-          file://compile.patch;patch=1"
+          file://compile.patch;patch=1 \
+          file://gcc-4.1.patch;patch=1"
 S = "${WORKDIR}/snes9x-sdl-${PV}"
 
 do_compile() {