summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorGoliathLabs2020-07-09 13:07:41 +0200
committerGoliathLabs2020-07-09 13:07:41 +0200
commited2148ea2685ffae8b575195e63345bcac82fff3 (patch)
treee6a3825c4284197a8ad179446b8e1ad3718613c2
parentffa920d29c41a42dceced94479ed099efba151f5 (diff)
downloadaur-ed2148ea2685ffae8b575195e63345bcac82fff3.tar.gz
Initial commit
-rw-r--r--.SRCINFO22
-rw-r--r--PKGBUILD58
-rw-r--r--arx-fatalis-data-demo.install10
-rwxr-xr-xinstall-demo138
4 files changed, 30 insertions, 198 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 3fa111b59cb4..180dc7cdbd00 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,19 +1,23 @@
pkgbase = arx-fatalis-data-demo
- pkgdesc = Arx Fatalis game data from official free demo
- pkgver = 0
+ pkgdesc = Arx Fatalis game data from official freeware demo (for use with arx-libertatis)
+ pkgver = 5122
pkgrel = 1
- url = http://www.arkane-studios.com/uk/arx.php
- install = arx-fatalis-data-demo.install
- arch = i686
- arch = x86_64
+ url = https://arx-libertatis.org/
+ arch = any
license = custom:freeware
makedepends = cabextract
makedepends = libarchive
- provides = arx-fatalis-data
+ optdepends = arx-libertatis: native Linux game executable
+ provides = arxfatalis-data
+ conflicts = arxfatalis-data-gog
+ conflicts = arxfatalis-data-copy
conflicts = arx-fatalis-data-gog
conflicts = arx-fatalis-data-copy
- source = install-demo
- md5sums = d6bc2486243986694426260d2d76f5cb
+ replaces = arx-fatalis-data-demo
+ source = https://downloads.ag.ru/demos/5122/arx_demo_english.zip
+ source = https://raw.githubusercontent.com/arx/ArxLibertatis/master/scripts/arx-install-data
+ sha512sums = 0cbf0d6da1a373ed29edc49c65ed431117c868ec7bcab04166abd59f5d799460faec506baf191c83fa7c61372888009abb260d8a50e28507a5ec8ab7913a9ad7
+ sha512sums = c3b8c2571d204f6a99b053aea3fc6b1db05d89429a40d45bad173b72fa303f64b85d73ef1730f4d229138fb0c9b75c85203c4bebc4b145ec847e9de83a82cbaf
pkgname = arx-fatalis-data-demo
diff --git a/PKGBUILD b/PKGBUILD
index 481892304384..f4346b840838 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,51 +1,27 @@
-# Maintainer: Sam S. <smls75@gmail.com>
+# Maintainer: Felix Golatofski <contact@xdfr.de>
+# Contributor: Sam S. <smls75@gmail.com>
pkgname=arx-fatalis-data-demo
-pkgver=0
+pkgver=5122
pkgrel=1
-pkgdesc='Arx Fatalis game data from official free demo'
-url='http://www.arkane-studios.com/uk/arx.php'
-arch=('i686' 'x86_64')
+pkgdesc='Arx Fatalis game data from official freeware demo (for use with arx-libertatis)'
+url='https://arx-libertatis.org/'
+arch=('any')
license=('custom:freeware')
+provides=('arxfatalis-data')
+replaces=('arx-fatalis-data-demo')
+conflicts=('arxfatalis-data-gog' 'arxfatalis-data-copy'
+ 'arx-fatalis-data-gog' 'arx-fatalis-data-copy')
makedepends=('cabextract' 'libarchive')
-provides=('arx-fatalis-data')
-conflicts=('arx-fatalis-data-gog' 'arx-fatalis-data-copy')
-source=("install-demo")
-md5sums=('d6bc2486243986694426260d2d76f5cb')
-install='arx-fatalis-data-demo.install'
-PKGEXT='.pkg.tar'
-
+optdepends=('arx-libertatis: native Linux game executable')
_gamepkg="arx_demo_english.zip"
+source=("https://downloads.ag.ru/demos/5122/$_gamepkg"
+ "https://raw.githubusercontent.com/arx/ArxLibertatis/master/scripts/arx-install-data")
+sha512sums=('0cbf0d6da1a373ed29edc49c65ed431117c868ec7bcab04166abd59f5d799460faec506baf191c83fa7c61372888009abb260d8a50e28507a5ec8ab7913a9ad7'
+ 'c3b8c2571d204f6a99b053aea3fc6b1db05d89429a40d45bad173b72fa303f64b85d73ef1730f4d229138fb0c9b75c85203c4bebc4b145ec847e9de83a82cbaf')
package() {
- cd $srcdir
- _get_local_source "$_gamepkg" || {
- error "Unable to find the game demo archive. Please download it from one of
- the sites listed at
- http://wiki.arx-libertatis.org/Getting_the_game_data#Demo ,
- rename it to 'arx_demo_english.zip', and copy or symlink it into one
- of the above directories."
- exit 1; }
-
- msg "Starting setup..."
- chmod +x install-demo
- ./install-demo "$_gamepkg" "$pkgdir/usr/share/arx"
- mkdir "$pkgdir/usr/share/games" && ln -s "/usr/share/arx/" "$pkgdir/usr/share/games/arx"
-}
-
-
-# Locate a file or folder provided by the user, and symlink it into $srcdir
-_get_local_source() {
- msg "Looking for '$1'..."
- declare -A _search=(['build dir']="$startdir"
- ['$LOCAL_PACKAGE_SOURCES']="$LOCAL_PACKAGE_SOURCES")
- for _key in "${!_search[@]}"; do local _dir="${_search["$_key"]}"
- if [ -z "$_dir" ]; then _dir="<undefined>"; fi
- echo -n " - in $_key ['$_dir'] ... ";
- if [ -e "$_dir/$1" ]; then
- echo "FOUND"; ln -sfT "$(readlink -f "$_dir/$1")" "$srcdir/$1"; break; fi
- echo "NOT FOUND"
- done
- if [ ! -e "$srcdir/$1" ]; then return 1; fi
+ chmod +x arx-install-data
+ ./arx-install-data --batch $_gamepkg "$pkgdir"/usr/share/arx
}
diff --git a/arx-fatalis-data-demo.install b/arx-fatalis-data-demo.install
deleted file mode 100644
index cc0ad4328b57..000000000000
--- a/arx-fatalis-data-demo.install
+++ /dev/null
@@ -1,10 +0,0 @@
-
-post_install() {
- echo "This package only installs the (proprietary) game demo data, no"
- echo "game binaries."
- echo "To actually play the demo, compile and install Arx Libertatis,"
- echo "the community-driven open-source port of Arx Fatalis for Linux"
- echo "based on the publically released Arx Fatalis 1.21 source code."
- echo " -> http://arx-libertatis.org"
- echo " -> AUR package: arx-libertatis"
-}
diff --git a/install-demo b/install-demo
deleted file mode 100755
index db11cbe2f99c..000000000000
--- a/install-demo
+++ /dev/null
@@ -1,138 +0,0 @@
-#!/bin/sh
-
-die() {
- echo "$@" >&2
- exit 1
-}
-
-# Handle arguments
-
-[ "$1" = "--help" ] || [ "$1" = "-h" ] || zipfile="$(readlink -m "$1")"
-
-[ "$zipfile" != "" ] || die "\
-Usage: install-demo path/to/arx_demo_english.zip [output_dir]
-
-This script can be used to install the Arx Fatalis demo data.
-Files will be verified and renamed as needed by Arx Libertatis.
-
-For demo download locations see http://wiki.arx-libertatis.org/Getting_the_game_data#Demo"
-
-if [ "$2" = "" ]
- then destdir="$(pwd)"
- else destdir="$(readlink -m "$2")"
-fi
-
-cd "$(dirname "$0")"
-here="$(pwd)"
-
-echo "Installing Arx Fatalis demo data from \"$zipfile\" to \"$destdir\".
-"
-
-# Check for required commands
-
-cabextract=`which cabextract 2> /dev/null`
-unzip=`which unzip 2> /dev/null`
-bsdtar=`which bsdtar 2> /dev/null`
-md5sum=`which md5sum 2> /dev/null`
-
-[ -f "$cabextract" ] \
- || die "Please install cabextract (http://www.cabextract.org.uk/)"
-
-[ -f "$unzip" ] || [ -f "$bsdtar" ] \
- || die "Please install unzip (http://www.info-zip.org/)" \
- "or bsdtar from libarchive (http://libarchive.github.com/)"
-
-[ -f "$zipfile" ] || die "Input file \"$zipfile\" not found."
-
-extract_cab() {
- "$cabextract" "$1"
-}
-
-extract_zip() {
- if [ -f "$unzip" ]
- then "$unzip" "$1"
- else "$bsdtar" xvf "$1"
- fi
-}
-
-# Verify input file
-
-if [ -f "$md5sum" ]
- then
- checksum="$(md5sum -b "$zipfile" | sed 's/ .*//')"
- expected='3c59a5799e1237b1b181c96e8c09155a'
- if [ "$checksum" = "$expected" ]
- then echo "Checksum matched."
- else echo "Got checksum $checksum, expected $expected."
- fi
- else echo "Missing md5sum, cannot verify that you have the correct archive."
-fi
-
-# Prepare output and temp dirs
-
-mkdir -p "$destdir" || exit 1
-
-tempdir="$destdir/arx-install-demo-temp"
-
-rm -rf "$tempdir" 2> /dev/null
-mkdir "$tempdir" || exit 1
-cd "$tempdir" || exit 1
-
-# Extract files
-
-extract_zip "$zipfile"
-
-extract_cab Setup1.cab
-extract_cab Setup2.cab
-extract_cab Setup3.cab
-
-# Install required files
-
-doinstall() {
- mv -fv "$1" "$destdir/$2"
- chmod "--reference=$destdir" "$destdir/$2" > /dev/null 2>&1
- chmod -x "$destdir/$2" > /dev/null 2>&1
-}
-
-mkdir -pv "$destdir/misc"
-doinstall "bin/Arx.ttf" "misc/arx.ttf"
-doinstall "bin/Logo.bmp" "misc/logo.bmp"
-doinstall "bin/data2.pak" "data2.pak"
-doinstall "bin/LOC.pak" "loc.pak"
-doinstall "data.pak" "data.pak"
-doinstall "SFX.pak" "sfx.pak"
-doinstall "SPEECH.pak" "speech.pak"
-
-# Cleanup temporary files
-
-rm -rf "$tempdir"
-
-echo "
-Done:"
-
-# Verify installed files
-
-[ -f "$md5sum" ] || ( echo "Could not verify checksum, md5sum not available." ; exit )
-
-cd "$destdir"
-checksums=`"$md5sum" -b data2.pak data.pak loc.pak misc/arx.ttf misc/logo.bmp sfx.pak speech.pak`
-
-checksums_demo="\
-958b78f8f370b06d769843137138c461 *data2.pak
-5d7ba6e6c79ebf7fbb232eaced9e8ad9 *data.pak
-2ae16d3925c597dca70f960f175def3a *loc.pak
-9a95ff96795c034524ba1c2e94ea12c7 *misc/arx.ttf
-aa3dfbd4bc9c863d10a0c5345ae5a4c9 *misc/logo.bmp
-ea1b3e6d6f4906905d4a34f07e9a59ac *sfx.pak
-62ca7b1751c0615ee131a94f0856b389 *speech.pak"
-
-[ "$checksums" = "$checksums_demo" ] || die "
-Checksum mismatch, expected
-
-$checksums_demo
-
- got
-
-$checksums"
-
-echo "Checksum match."