diff options
author | SanskritFritz | 2015-06-14 00:37:40 +0200 |
---|---|---|
committer | SanskritFritz | 2015-06-14 00:37:40 +0200 |
commit | cd0f5ed7ddde9e40386a32d727cf38eb47507c7d (patch) | |
tree | c9ab6137f4d925d6a9e317c1082ac08ac27f7620 | |
download | aur-cd0f5ed7ddde9e40386a32d727cf38eb47507c7d.tar.gz |
Initial import
-rw-r--r-- | .SRCINFO | 29 | ||||
-rwxr-xr-x | PKGBUILD | 37 | ||||
-rwxr-xr-x | d2x-rebirth.desktop | 10 | ||||
-rwxr-xr-x | d2x-rebirth.install | 117 |
4 files changed, 193 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..323b4cf23dcb --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,29 @@ +pkgbase = d2x-rebirth + pkgdesc = An enhanced engine to play with Descent2 datas + pkgver = 0.58.1 + pkgrel = 1 + url = http://www.dxx-rebirth.com/ + install = d2x-rebirth.install + arch = i686 + arch = x86_64 + license = custom:D1x + license = LGPL + license = custom:as-is + makedepends = scons + makedepends = unzip + depends = sdl + depends = sdl_mixer + depends = mesa + depends = physfs + noextract = d2xr-sc55-music.dxa + source = http://www.dxx-rebirth.com/download/dxx/d2x-rebirth_v0.58.1-src.tar.gz + source = d2x-rebirth.desktop + source = d2x-rebirth.install + source = http://www.dxx-rebirth.com/download/dxx/res/d2xr-sc55-music.dxa + md5sums = 584187fdd922d732e47a64451085eaca + md5sums = 3771fe1979a98ed32e7a9c9be8aa80a6 + md5sums = 6836b665ac0c67117c810de77ca5e739 + md5sums = b5bd2bea4cf904d54bddad36222aa92f + +pkgname = d2x-rebirth + diff --git a/PKGBUILD b/PKGBUILD new file mode 100755 index 000000000000..0a799e133406 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,37 @@ +# Contributor : zico <zico@dxx-rebirth.com> + +pkgname=d2x-rebirth +pkgver=0.58.1 +pkgrel=1 +pkgdesc="An enhanced engine to play with Descent2 datas" +arch=('i686' 'x86_64') +url="http://www.dxx-rebirth.com/" +license=('custom:D1x' 'LGPL' 'custom:as-is') +depends=('sdl' 'sdl_mixer' 'mesa' 'physfs') +makedepends=('scons' 'unzip') +install=$pkgname.install +source=(http://www.dxx-rebirth.com/download/dxx/${pkgname}_v${pkgver}-src.tar.gz $pkgname.desktop $pkgname.install http://www.dxx-rebirth.com/download/dxx/res/d2xr-sc55-music.dxa) +noextract=(d2xr-sc55-music.dxa) +md5sums=('584187fdd922d732e47a64451085eaca' + '3771fe1979a98ed32e7a9c9be8aa80a6' + '6836b665ac0c67117c810de77ca5e739' + 'b5bd2bea4cf904d54bddad36222aa92f') + +package() { + cd $srcdir/${pkgname}_v${pkgver}-src + sed -ie "/^PREFIX =/s|/usr/local/|/usr/|" SConstruct + scons sharepath="/usr/share/$pkgname" || return 1 + + mkdir -p $pkgdir/usr/bin/ + mkdir -p $pkgdir/usr/share/$pkgname/ + mkdir -p $pkgdir/usr/share/pixmaps/ + mkdir -p $pkgdir/usr/share/applications/ + mkdir -p $pkgdir/usr/share/licenses/$pkgname/ + + install -m755 $pkgname $pkgdir/usr/bin/ + cd $srcdir/ + install -m644 $srcdir/${pkgname}_v${pkgver}-src/$pkgname.xpm $pkgdir/usr/share/pixmaps/ + install -m644 $srcdir/$pkgname.desktop $pkgdir/usr/share/applications/ + install -m644 $srcdir/${pkgname}_v${pkgver}-src/COPYING.txt $pkgdir/usr/share/licenses/$pkgname/ + install -m644 d2xr-sc55-music.dxa $pkgdir/usr/share/$pkgname/ +} diff --git a/d2x-rebirth.desktop b/d2x-rebirth.desktop new file mode 100755 index 000000000000..25bc8ab4871e --- /dev/null +++ b/d2x-rebirth.desktop @@ -0,0 +1,10 @@ +[Desktop Entry] +Version=1.0 +Type=Application +Categories=Game;ActionGame; +Name=Descent 2 X Rebirth +GenericName=FP Action Game +Comment=First person action game controlling a ship with 6 degrees of freedom +Comment[fr]=Jeu à la première personne où l'on contrôle un vaisseau qui permet de se déplacer avec 6 degrés de liberté +Exec=d2x-rebirth +Icon=d2x-rebirth diff --git a/d2x-rebirth.install b/d2x-rebirth.install new file mode 100755 index 000000000000..4ac737bab015 --- /dev/null +++ b/d2x-rebirth.install @@ -0,0 +1,117 @@ +post_install() { + function install_datas() { + read -p "I'm about to install Descent 2 datas to /usr/share/d2x-rebirth/, would you like to continue (Y/n) ? " + case $REPLY in + n|N) return 1;; + esac + + type unarj &> /dev/null + if (($?)); then + echo 'I need unarj to continue'; + read -p 'Do you want install it (Y/n) ? ' + case $REPLY in + n|N) return 1;; + esac + pacman -Sy unarj || return 2 + fi + + cont=1 + while (($cont)); do + echo 'Give me the complete path to "descent2.sow" file (example, with the cd drive : /path/to/drive/d2data/descent2.sow)' + read + if [ -z "$REPLY" ]; then return 2; fi + if [ -f "$REPLY" ]; then + cont=0; + else + echo -e "Bad path (Enter to abort)\n" + fi + done + + descent_file="$REPLY" + + cd /usr/share/d2x-rebirth/ + unarj e "$descent_file" &> /dev/null + if (($?)); then echo -e '!! Error with unarj !!\n' >&2; return 2; fi + rm *.exe *.dll *.txt *.bat descent.cfg descentg.ini \ + descent.hi *.doc eregcard.ini &>/dev/null + + read -p 'Would you like to include movies files (need 210 MB more space) (N/y) ? ' + case $REPLY in + y|Y) :;; + *) return 0;; + esac + + cont=1 + while (($cont)); do + echo 'Give me the complete path to the directory that contains those movies (example, with the cd drive : /path/to/drive/d2data/)' + read + if [ -z "$REPLY" ]; then return 2; fi + if [ -d "$REPLY" ]; then + cont=0; + else + echo -e "Bad path (Enter to abort)\n" + fi + done + + movies_path="$REPLY" + cp "$movies_path"/*-h.mvl . &> /dev/null + + chmod 644 * &> /dev/null + return 0 + } + + old_path=`pwd` + install_datas + ret=$? + cd $old_path + + if (($ret)); then + echo 'Put your Descent 2 datas either to /usr/share/d2x-rebirth/ or ~/.d2x-rebirth/' + + cat << EOF +Following files are needed to run the game: + +descent2.ham +descent2.hog +descent2.s11 +descent2.s22 +alien1.pig +alien2.pig +fire.pig +groupa.pig +ice.pig +water.pig + +And these movies files (but not mandatory): + +intro-h.mvl and/or intro-l.mvl +other-h.mvl and/or other-l.mvl +robots-h.mvl and/or robots-l.mvl + +These files - except the Movies (*.mvl) - are archived in the file descent2.sow +This file is an ARJ-archive and can be extracted with an archiver like unarj + +You don't own the full game, yet? +Just visit GOOD OLD GAMES via: +http://www.gog.com/en/gamecard/descent_1_descent_2/pp/fc074d501302eb2b93e2554793fcaf50b3bf7291 +and download it for a very low price! DRM-FREE! + +You can get AddOns for the game from http://www.dxx-rebirth.com/addons/ + +EOF + + fi +} + +post_upgrade() { +post_install +} + +pre_remove() { +/bin/true +} + +op=$1 +shift + +$op "$@" |