diff options
author | Slashbunny | 2009-08-12 22:17:38 -0400 |
---|---|---|
committer | Slashbunny | 2009-08-12 22:17:38 -0400 |
commit | 656757ae26ab4a1aa0f8acbfc12ad76137f99d28 (patch) | |
tree | 388c481614dcea503e2095649cb0dcd595bf23ef | |
download | aur-656757ae26ab4a1aa0f8acbfc12ad76137f99d28.tar.gz |
Initial commit of personal PKGBUILDs for Arch Linux
-rw-r--r-- | .SRCINFO | 49 | ||||
-rw-r--r-- | .gitignore | 5 | ||||
-rw-r--r-- | PKGBUILD | 157 | ||||
-rw-r--r-- | nwmouse.nwlogger.patch | 22 | ||||
-rw-r--r-- | nwn.desktop | 12 | ||||
-rw-r--r-- | nwn.install | 35 | ||||
-rw-r--r-- | nwn.launcher | 29 |
7 files changed, 309 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..32afd70e27b6 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,49 @@ +pkgbase = nwn-diamond + pkgdesc = Neverwinter Nights is an RPG from Bioware. This requires the Diamond Collection DVD Release. + pkgver = 1.69 + pkgrel = 2 + url = http://nwn.bioware.com/ + install = nwn.install + arch = i686 + arch = x86_64 + license = custom + makedepends = unzip + makedepends = p7zip + makedepends = perl + depends = binkplayer + depends = libelf + depends = libgl + depends = libstdc++5 + depends = libxcursor + depends = mesa + depends = perl + depends = sdl_mixer + provides = nwn + conflicts = nwn + source = http://nwdownloads.bioware.com/neverwinternights/linux/gold/nwclientgold.tar.gz + source = http://nwdownloads.bioware.com/neverwinternights/linux/161/nwclienthotu.tar.gz + source = http://files.bioware.com/neverwinternights/updates/linux/169/English_linuxclient169_xp2.tar.gz + source = http://home.roadrunner.com/~nwmovies/nwuser/nwuser-latest.tar.gz + source = http://home.roadrunner.com/~nwmovies/nwmovies/nwmovies-latest.tar.gz + source = http://home.roadrunner.com/~nwmovies/nwmouse/nwmouse-latest.tar.gz + source = http://home.roadrunner.com/~nwmovies/nwlogger/nwlogger-latest.tar.gz + source = http://home.roadrunner.com/~nwmovies/cursors.tar.gz + source = nwn.launcher + source = nwn.desktop + source = nwn.install + source = nwmouse.nwlogger.patch + md5sums = 0a059d55225fc32f905e86191d88a11f + md5sums = 376cdece07106ea058d42b531f3146bb + md5sums = b021f0da3b3e00848521926716fdf487 + md5sums = 0ff1296e4afb43844b6eb2544e40cab9 + md5sums = 2225a729051290fd2e1789b40d270f03 + md5sums = 099627511d9d4d2a062c4f81ad508f3f + md5sums = 981d5cd5ec13aa888e4c0a2ba7f9a231 + md5sums = 7be935418f0ececb5660f53b7a902b38 + md5sums = d28e09031cc8f56406f6878e36683e36 + md5sums = bd7f80f5faa5ee1203371b4e8ec40638 + md5sums = e7b2a5b92d5ef05b89946b69d325d152 + md5sums = 95d96bf43557405586c7dab01ffc8d8c + +pkgname = nwn-diamond + diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..e4f398dc5b3a --- /dev/null +++ b/.gitignore @@ -0,0 +1,5 @@ +src/ +pkg/ +*.pkg.tar.xz +*.pkg.tar +*.src.tar.gz diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..e33d3d60cbcd --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,157 @@ +# Contributor: Slash <demodevil5[at]yahoo[dot]com> +# Contributor: Adam Griffiths <adam_griffithsAATTdart.net.au> + +pkgname=nwn-diamond +pkgver=1.69 +pkgrel=2 +pkgdesc="Neverwinter Nights is an RPG from Bioware. This requires the Diamond Collection DVD Release." +url="http://nwn.bioware.com/" +license=('custom') +arch=('i686' 'x86_64') +if [ "$CARCH" = "x86_64" ]; then + depends=('binkplayer' 'lib32-libelf' 'lib32-libgl' 'lib32-libstdc++5' 'lib32-libxcursor' 'lib32-mesa' 'perl' 'lib32-sdl_mixer') +else + depends=('binkplayer' 'libelf' 'libgl' 'libstdc++5' 'libxcursor' 'mesa' 'perl' 'sdl_mixer') +fi +makedepends=('unzip' 'p7zip' 'perl') +provides=('nwn') +conflicts=('nwn') +install=nwn.install +source=("http://nwdownloads.bioware.com/neverwinternights/linux/gold/nwclientgold.tar.gz" \ +"http://nwdownloads.bioware.com/neverwinternights/linux/161/nwclienthotu.tar.gz" \ +"http://files.bioware.com/neverwinternights/updates/linux/169/English_linuxclient169_xp2.tar.gz" \ +"http://home.roadrunner.com/~nwmovies/nwuser/nwuser-latest.tar.gz" \ +"http://home.roadrunner.com/~nwmovies/nwmovies/nwmovies-latest.tar.gz" \ +"http://home.roadrunner.com/~nwmovies/nwmouse/nwmouse-latest.tar.gz" \ +"http://home.roadrunner.com/~nwmovies/nwlogger/nwlogger-latest.tar.gz" \ +"http://home.roadrunner.com/~nwmovies/cursors.tar.gz" \ +"nwn.launcher" "nwn.desktop" "nwn.install" "nwmouse.nwlogger.patch") +md5sums=('0a059d55225fc32f905e86191d88a11f' + '376cdece07106ea058d42b531f3146bb' + 'b021f0da3b3e00848521926716fdf487' + '0ff1296e4afb43844b6eb2544e40cab9' + '2225a729051290fd2e1789b40d270f03' + '099627511d9d4d2a062c4f81ad508f3f' + '981d5cd5ec13aa888e4c0a2ba7f9a231' + '7be935418f0ececb5660f53b7a902b38' + 'd28e09031cc8f56406f6878e36683e36' + 'bd7f80f5faa5ee1203371b4e8ec40638' + 'e7b2a5b92d5ef05b89946b69d325d152' + '95d96bf43557405586c7dab01ffc8d8c') + +# Directory where the NWN Diamond DVD is Mounted +_dvdpath=/media/dvd + +# NWN Diamond CD-Keys (Neverwinter Nights, Shadows of Undrentide, and Hordes of the Underdark) +_key_nwn=xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx +_key_sou=xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx +_key_hou=xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx + +build() +{ + cd $srcdir/ + + # Create Destination Directory + install -d $pkgdir/opt/nwn + + # Extract Data Files from DVD ROM + unzip $_dvdpath/Data_Shared.zip -d $pkgdir/opt/nwn/ || return 1 + unzip $_dvdpath/Data_linux.zip -d $pkgdir/opt/nwn/ || return 1 + unzip -o $_dvdpath/data/XP1.zip -d $pkgdir/opt/nwn/ || return 1 + unzip -o $_dvdpath/data/XP2.zip -d $pkgdir/opt/nwn/ || return 1 + + # Extract Game Clients + tar -zxvf $srcdir/nwclientgold.tar.gz -C $pkgdir/opt/nwn/ + tar -zxvf $srcdir/nwclienthotu.tar.gz -C $pkgdir/opt/nwn/ + + # Extract Kingmaker Files + 7z x $_dvdpath/KingmakerSetup.exe -xr0\!*PLUGINSDIR* -xr\!*.exe -xr\!*.dat \ + -o$srcdir/kingmakertmp/ + + # Install Kingmaker Files + cp -r $srcdir/kingmakertmp/\$0/* \ + $pkgdir/opt/nwn/ + + # Extract Latest Patch + tar -zxvf $srcdir/English_linuxclient169_xp2.tar.gz -C $pkgdir/opt/nwn + + # Check the Installation + cd $pkgdir/opt/nwn/ + ./fixinstall + + # Remove Unneeded Files & Directories + rm -r $pkgdir/opt/nwn/SDL-1.2.5/ + + # Install CD Key File + cat << EOF > $pkgdir/opt/nwn/nwncdkey.ini +;These are your CD Keys for Neverwinter Nights. +;DO NOT share these CD Keys with ANYONE. +;Apart from this installation, or when registering with the Official Neverwinter Nights Community Site [http://nwn.bioware.com], BioWare and Infogrames will NEVER ask you for this CD Key. + +[CDKEY] +Key3=$_key_hou +Key2=$_key_sou +Key1=$_key_nwn +EOF + + cd $srcdir/ + + # Patch nwmouse and nwlogger so they build properly + patch -p1 < $srcdir/nwmouse.nwlogger.patch + + # Movies in Linux Client Support for NWN + ./nwmovies_install.pl /usr/lib/libSDL.so + install -D -m 755 -t $pkgdir/opt/nwn/ \ + $srcdir/nwmovies/{nwmovies.so,nwmovies.pl} + install -D -m 755 $srcdir/nwmovies/binklib.so \ + $pkgdir/opt/nwn/nwmovies/binklib.so + install -D -m 755 $srcdir/nwmovies/libdis/libdisasm.so \ + $pkgdir/opt/nwn/nwmovies/libdis/libdisasm.so + + # SymLink BinkPlayer to the NWN Directory so the Movie Launcher (nwmovies.pl) can find it + ln -s /usr/bin/binkplayer $pkgdir/opt/nwn/BinkPlayer + + # Per-User Settings Support for NWN + ./nwuser_install.pl + install -D -m 755 $srcdir/nwuser/nwuser.so \ + $pkgdir/opt/nwn/nwuser.so + + # Hardware Mouse Cursors Support for NWN + ./nwmouse_install.pl + install -D -m 755 $srcdir/nwmouse/nwmouse.so \ + $pkgdir/opt/nwn/nwmouse.so + install -D -m 755 $srcdir/nwmouse/libdis/libdisasm.so \ + $pkgdir/opt/nwn/nwmouse/libdis/libdisasm.so + + # Client-Side Chat Window Logging Support for NWN + ./nwlogger_install.pl + install -D -m 755 $srcdir/nwlogger/nwlogger.so \ + $pkgdir/opt/nwn/nwlogger.so + install -D -m 755 $srcdir/nwlogger/libdis/libdisasm.so \ + $pkgdir/opt/nwn/nwlogger/libdis/libdisasm.so + + # Install Cursors + install -d $pkgdir/opt/nwn/nwmouse/cursors/ + tar -zxvf $srcdir/cursors.tar.gz -C $pkgdir/opt/nwn/nwmouse/cursors/ + + # Install Custom License + install -D -m 644 $_dvdpath/EULA.txt \ + $pkgdir/usr/share/licenses/$pkgname/EULA.txt + + # Install Launcher (Client) + install -D -m 755 $startdir/nwn.launcher \ + $pkgdir/usr/bin/nwn + + # Install Desktop File + install -D -m 644 $srcdir/nwn.desktop \ + $pkgdir/usr/share/applications/nwn.desktop + + # Install Icon File + install -D -m 644 $_dvdpath/nwn.ico \ + $pkgdir/usr/share/pixmaps/nwn.ico + + # Fix Whacky Permissions + chown -R root:root $pkgdir/ + chmod -R o+r $pkgdir/ +} + diff --git a/nwmouse.nwlogger.patch b/nwmouse.nwlogger.patch new file mode 100644 index 000000000000..8020eda905c6 --- /dev/null +++ b/nwmouse.nwlogger.patch @@ -0,0 +1,22 @@ +diff -uNr a/nwlogger/nwlogger_cookie.c b/nwlogger/nwlogger_cookie.c +--- a/nwlogger/nwlogger_cookie.c 2004-03-09 14:40:36.000000000 -0500 ++++ b/nwlogger/nwlogger_cookie.c 2009-01-03 23:12:46.732146888 -0500 +@@ -16,7 +16,6 @@ + #include <elf.h> + #include <libelf.h> + +-#include <linux/user.h> + #include <link.h> + + #include "libdis.h" +diff -uNr a/nwmouse/nwmouse_cookie.c b/nwmouse/nwmouse_cookie.c +--- a/nwmouse/nwmouse_cookie.c 2004-09-24 14:17:42.000000000 -0400 ++++ b/nwmouse/nwmouse_cookie.c 2009-01-03 23:12:19.165487280 -0500 +@@ -16,7 +16,6 @@ + #include <elf.h> + #include <libelf.h> + +-#include <linux/user.h> + #include <link.h> + + #include "libdis.h" diff --git a/nwn.desktop b/nwn.desktop new file mode 100644 index 000000000000..34f775cccbd0 --- /dev/null +++ b/nwn.desktop @@ -0,0 +1,12 @@ +[Desktop Entry] +Encoding=UTF-8 +Name=Neverwinter Nights Diamond +GenericName=Neverwinter Nights +Comment=Play Neverwinter Nights Diamond +Exec=/usr/bin/nwn +Icon=/usr/share/pixmaps/nwn.ico +StartupNotify=true +Terminal=false +Type=Application +Categories=Qt;KDE;GNOME;Application;Game; + diff --git a/nwn.install b/nwn.install new file mode 100644 index 000000000000..e8bfa88fe72b --- /dev/null +++ b/nwn.install @@ -0,0 +1,35 @@ + +post_install() { + echo ">>> If you use software mixing on your sound card, uncomment the" + echo ">>> first export statement in /usr/bin/nwn to make that work" + echo ">>>" + echo ">>> Some of the additional modules create .ini files the first time" + echo ">>> they start. You may have to restart nwn a few times for it" + echo ">>> load successfully. This is normal. Run 'nwn' from a terminal the" + echo ">>> first few times until the game starts running correctly." + echo ">>>" + echo ">>> If something throws an error saying it cannot create the .ini file, " + echo ">>> try modifying the export LD_PRELOAD line in /usr/bin/nwn to" + echo ">>> include just one additional library at a time. For example:" + echo ">>>" + echo ">>> export LD_PRELOAD=./nwuser.so (start nwn)" + echo ">>> export LD_PRELOAD=./nwuser.so:./nwmouse.so (start nwn)" + echo ">>> export LD_PRELOAD=./nwuser.so:./nwmouse.so:./nwmovies.so (start nwn)" + echo ">>> ... etc" + echo ">>>" + echo ">>> Now when you start NWN again, all the extra modules should load successfully." +} + +post_upgrade() { + post_install $1 +} + +pre_remove() { + /bin/true +} + +op=$1 +shift + +$op $* + diff --git a/nwn.launcher b/nwn.launcher new file mode 100644 index 000000000000..6a38ff7b6058 --- /dev/null +++ b/nwn.launcher @@ -0,0 +1,29 @@ +#!/bin/sh + +cd "/opt/nwn" + +# Uncomment to make SDL Sound work on Software Mixers +#export SDL_AUDIODRIVER=esd +export SDL_MOUSE_RELATIVE=0 +export SDL_VIDEO_X11_DGAMOUSE=0 + +# Hardware Mouse Cursor +export XCURSOR_PATH=/opt/nwn +export XCURSOR_THEME=nwmouse + +# Enable AA on NVidia cards (/usr/share/doc/NVIDIA_GLX-1.0/README.txt) +# 3 = 1.5 x 1.5 super sampling +# 4 = 2x2 super sampling +export __GL_FSAA_MODE=4 + +# Add Miles Sound Codec to Library Path +export LD_LIBRARY_PATH=./miles:$LD_LIBRARY_PATH + +# Per-User Settings Support, Hardware Mouse Cursor Support, Linux Movies Support, Client Side Chat Logging Support +export LD_PRELOAD=./nwuser.so:./nwmouse.so:./nwmovies.so:./nwlogger.so + +# Run Neverwinter Nights +./nwmain $* + +exit $? + |