summaryrefslogtreecommitdiffstats
path: root/abs/extra/snes9x
diff options
context:
space:
mode:
authorCecil Hugh Watson <knoppmyth@gmail.com>2009-09-26 01:57:08 (GMT)
committerCecil Hugh Watson <knoppmyth@gmail.com>2009-09-26 01:57:08 (GMT)
commit7b29169fff9e7c624890c5edffe85def8a293136 (patch)
tree47753889faa3a2063b66d1c7e7681e703eb1b39a /abs/extra/snes9x
parentc491dea779dac29afff3578bf8245943817c2339 (diff)
downloadlinhes_pkgbuild-7b29169fff9e7c624890c5edffe85def8a293136.zip
linhes_pkgbuild-7b29169fff9e7c624890c5edffe85def8a293136.tar.gz
linhes_pkgbuild-7b29169fff9e7c624890c5edffe85def8a293136.tar.bz2
LinHES 6.01.00
Diffstat (limited to 'abs/extra/snes9x')
-rw-r--r--abs/extra/snes9x/PKGBUILD42
-rw-r--r--abs/extra/snes9x/snes9x-fixes2.patch29
-rwxr-xr-xabs/extra/snes9x/snes9x.install13
3 files changed, 84 insertions, 0 deletions
diff --git a/abs/extra/snes9x/PKGBUILD b/abs/extra/snes9x/PKGBUILD
new file mode 100644
index 0000000..928081b
--- /dev/null
+++ b/abs/extra/snes9x/PKGBUILD
@@ -0,0 +1,42 @@
+# Maintainer: Alexander Baldeck <alexander@archlinux.org>
+pkgname=snes9x
+pkgver=1.51
+pkgrel=1
+pkgdesc="A portable Emulator for the Super Nintento Entertainment System"
+arch=(i686 x86_64)
+url="http://www.snes9x.com"
+license="Freeware"
+# remove nasm on non x86 platforms
+depends=('zlib' 'libpng' 'sdl' 'nasm' 'mesa')
+install=snes9x.install
+source=(http://www.geocities.co.jp/SiliconValley-PaloAlto/2560/release/${pkgname}-${pkgver}-src.tar.bz2 \
+ snes9x-fixes2.patch)
+build() {
+ mkdir -p ${startdir}/pkg/usr/bin
+
+ cd ${startdir}/src/${pkgname}-${pkgver}-src
+ #patch -Np1 -i ${startdir}/src/snes9x-fixes2.patch || return 1
+
+ # build snes9x with opengl
+ ./configure --prefix=/usr \
+ --with-sdd1-decomp \
+ --with-opengl \
+ --with-netplay
+ make || return 1
+ install -D ${startdir}/src/${pkgname}-${pkgver}-src/osnes9x ${startdir}/pkg/usr/bin/osnes9x
+
+ # build snes9x with glide
+ #cd $startdir/src/$pkgname-$pkgver-src
+ #./configure --prefix=/usr --with-sdd1-decomp --with-glide
+ #make || return 1
+ #install -D ${startdir}/src/${pkgname}-${pkgver}-src/osnes9x ${startdir}/pkg/usr/bin/3dfxsnes9x
+
+ # build snes9x without opengl
+ ./configure --prefix=/usr \
+ --with-sdd1-decomp \
+ --with-netplay
+ make clean || return 1
+ make || return 1
+ install -D ${startdir}/src/${pkgname}-${pkgver}-src/snes9x ${startdir}/pkg/usr/bin/snes9x
+}
+md5sums=('a1038cc761f400318cdced960972f8a7' '395bea78242afc82b3756225fe4ff954')
diff --git a/abs/extra/snes9x/snes9x-fixes2.patch b/abs/extra/snes9x/snes9x-fixes2.patch
new file mode 100644
index 0000000..6007bb6
--- /dev/null
+++ b/abs/extra/snes9x/snes9x-fixes2.patch
@@ -0,0 +1,29 @@
+--- snes9x-1.5-src.orig/unix/opengl.cpp 2006-06-30 13:34:57.000000000 +0000
++++ snes9x-1.5-src/unix/opengl.cpp 2006-09-01 08:48:39.000000000 +0000
+@@ -214,7 +214,7 @@
+
+ // Strip dots from the version string
+ char *ptr;
+- while (ptr = strchr (ver, '.'))
++ while ((ptr = strchr (ver, '.')))
+ memmove (ptr, ptr + 1, strlen (ptr + 1) + 1);
+
+ // Pad the string with zeros to 4 digits
+@@ -381,7 +381,7 @@
+ int i = 0;
+ for (uint32 y = 0; y < pheight; y++)
+ {
+- uint16 *ptr = (uint16 *) (GFX.Screen + (y + startl) * GFX.Pitch2) + startx;
++ uint16 *ptr = (uint16 *) (GFX.Screen + (y + startl) * GFX.Pitch) + startx;
+ for (uint32 x = 0; x < pwidth; x++)
+ {
+ int color = *ptr++;
+@@ -399,7 +399,7 @@
+ for (uint32 y = 0; y < pheight; y++)
+ {
+ memmove (basetexbuffer + sizeof (uint16) * texture_size * y,
+- (GFX.Screen + (y + startl) * GFX.Pitch2) + startx,
++ (GFX.Screen + (y + startl) * GFX.Pitch) + startx,
+ sizeof (uint16) * texture_size);
+ }
+ data = basetexbuffer;
diff --git a/abs/extra/snes9x/snes9x.install b/abs/extra/snes9x/snes9x.install
new file mode 100755
index 0000000..1528f50
--- /dev/null
+++ b/abs/extra/snes9x/snes9x.install
@@ -0,0 +1,13 @@
+post_install() {
+ echo ">> If you wish to use Snes9x with OpenGL try osnes9x"
+ /bin/true
+}
+
+post_upgrade() {
+ echo ">> If you wish to use Snes9x with OpenGL try osnes9x"
+ /bin/true
+}
+
+op=$1
+shift
+$op $*