Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=frugalware-current.git;a=commitdiff;h=ed5f10ab75c119e28fd1e3683180a8635bd3bb4c

commit ed5f10ab75c119e28fd1e3683180a8635bd3bb4c
Author: James Buren <[EMAIL PROTECTED]>
Date:   Wed Jul 2 14:26:05 2008 -0500

pcsx-1.5-1-i686
* new package

diff --git a/source/games-extra/pcsx/FrugalBuild 
b/source/games-extra/pcsx/FrugalBuild
new file mode 100644
index 0000000..40af686
--- /dev/null
+++ b/source/games-extra/pcsx/FrugalBuild
@@ -0,0 +1,42 @@
+# Compiling Time: 0.03 SBU
+# Maintainer: James Buren <[EMAIL PROTECTED]>
+
+pkgname=pcsx
+pkgver=1.5
+pkgrel=1
+pkgdesc="An open source playstation emulator, uses psemu style plugins."
+url="http://www.pcsx.net/";
+rodepends=('psemu-padjoy' 'psemu-cdr' 'psemu-cdriso' 'psemu-peops-spu' 
'psemu-peops-softgpu')
+depends=('gtk+2' 'glibc' 'freetype2' 'libxau' 'libxdmcp' 'libxdamage' 
'libxext' 'libxml2')
+options=('scriptlet')
+groups=('games-extra')
+archs=('i686')
+_F_archive_name=PcsxSrc
+_F_desktop_categories="Games;Emulator;"
+up2date="Flasttar $url/files.shtml"
+source=($url/downloads/$_F_archive_name-$pkgver.tgz \
+       $pkgname-$pkgver-home.patch $pkgname-$pkgver-gcc41.patch $pkgname)
+sha1sums=('ce7200a3ee79e04685c6fe666b1bb7e49f8a4a17' \
+          'cc97ee21b287f43ec27d099f6211b34ad57038ac' \
+          'ea6547c2b8c099a663a6989af395928b5486de9c' \
+          '22bc0874a44adbbeeab40b95b07d01ff625a4446')
+
+build()
+{
+       Fcd $_F_archive_name-$pkgver
+       Fpatchall
+       cd Linux || Fdie
+       # adjust paths for system level and local level paths
+       Fsed "Plugin/" "/usr/lib/psemu/plugins/" LnxMain.c
+       Fsed "Bios/" "/usr/lib/psemu/bios/" LnxMain.c
+       Fsed "Pcsx.cfg" "~/.pcsx/config" LnxMain.c
+       Fconf
+       make OPTIMIZE="${CFLAGS}" || Fdie
+       Fexe /usr/bin/$pkgname
+       Fexerel $pkgname /usr/bin/$pkgname-bin
+       Ffilerel .pixmaps/* /usr/share/$pkgname
+       Fdocrel ../Docs/*
+       Fdesktop2
+}
+
+# optimization OK
diff --git a/source/games-extra/pcsx/pcsx b/source/games-extra/pcsx/pcsx
new file mode 100644
index 0000000..6c3883a
--- /dev/null
+++ b/source/games-extra/pcsx/pcsx
@@ -0,0 +1,37 @@
+#!/bin/sh
+
+if [ ! -f ~/.pcsx/config ]; then
+       echo "Setting up PCSX..."
+       mkdir -p ~/.pcsx/{memcards,bios,cfg,plugins}
+       cd ~/.pcsx
+       ln -s /usr/bin/pcsx-bin pcsx
+       ln -s /usr/lib/psemu/plugins/* plugins
+       ln -s /usr/share/pcsx .pixmaps
+       cat > ~/.pcsx/config << EOF
+       Bios = HLE
+       Gpu = libgpuPeopsSoftX.so.1.0.18
+       Spu = libspuPeopsALSA.so.1.0.9
+       Cdr = libcdriso-1.3.so
+       Pad1 = libpadJoy-0.8.so
+       Pad2 = libpadJoy-0.8.so
+       Mcd1 = ${HOME}/.pcsx/memcards/Mcd001.mcr
+       Mcd2 = ${HOME}/.pcsx/memcards/Mcd002.mcr
+       PluginsDir = ${HOME}/.pcsx/plugins/
+       BiosDir = ${HOME}/.pcsx/bios/
+       Xa = 0
+       Sio = 0
+       Mdec = 0
+       PsxAuto = 1
+       PsxType = 0
+       Cdda = 0
+       Cpu = 0
+       PsxOut = 0
+       SpuIrq = 0
+       CdTiming = 0
+EOF
+fi
+
+cd ~/.pcsx
+ln -s /usr/lib/psemu/plugins/* plugins &> /dev/null
+ln -s /usr/lib/psemu/cfg/* cfg &> /dev/null
+exec ./pcsx "$@"
diff --git a/source/games-extra/pcsx/pcsx-1.5-gcc41.patch 
b/source/games-extra/pcsx/pcsx-1.5-gcc41.patch
new file mode 100644
index 0000000..eff40e9
--- /dev/null
+++ b/source/games-extra/pcsx/pcsx-1.5-gcc41.patch
@@ -0,0 +1,22 @@
+--- PsxBios.c.old      2006-05-02 21:22:52.000000000 +0200
++++ PsxBios.c  2006-05-02 21:41:56.000000000 +0200
+@@ -2253,7 +2253,7 @@
+               if (ptr) psxRu32ref(base) = SWAPu32((u32)ptr - (u32)psxM); \
+               else psxRu32ref(base) = 0; \
+       } else { \
+-              if (psxRu32(base)) (u8*)ptr = (u8*)(psxM + psxRu32(base)); \
++              if (psxRu32(base)) *(u8**)&ptr = (u8*)(psxM + psxRu32(base)); \
+               else ptr = NULL; \
+       } \
+       base+=4;
+--- R3000A.h.old       2006-05-02 21:44:36.000000000 +0200
++++ R3000A.h   2006-05-02 21:45:07.000000000 +0200
+@@ -135,7 +135,7 @@
+
+ psxRegisters psxRegs;
+
+-#define _i32(x) (long)x
++#define _i32(x) *(long *)&x
+ #define _u32(x) x
+
+ #define _i16(x) (short)x
diff --git a/source/games-extra/pcsx/pcsx-1.5-home.patch 
b/source/games-extra/pcsx/pcsx-1.5-home.patch
new file mode 100644
index 0000000..e490758
--- /dev/null
+++ b/source/games-extra/pcsx/pcsx-1.5-home.patch
@@ -0,0 +1,11 @@
+--- Linux/LnxMain.c.orig       2003-08-14 00:55:01.529872992 -0400
++++ Linux/LnxMain.c    2003-08-14 00:54:56.000000000 -0400
+@@ -48,7 +48,7 @@
+       bindtextdomain(PACKAGE, "./Langs");
+       textdomain(PACKAGE);
+ #endif
+-      strcpy(cfgfile, "Pcsx.cfg");
++      sprintf(cfgfile, "%s/.pcsx/config", getenv("HOME"));
+
+       for (i=1; i<argc; i++) {
+               if (!strcmp(argv[i], "-runcd")) runcd = 1;
_______________________________________________
Frugalware-git mailing list
[email protected]
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to