blob: e65074376ac060091f13def111804fa91e6273d9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
# Maintainer: Alex Szczuczko <alex@szc.ca>
pkgname=wasteland2 #-gog ???
pkgver=2.3.0.5
pkgrel=1
pkgdesc="The Director's Cut of the sequel to an adventure in post-nuclear America"
arch=("x86_64")
url="https://wasteland.inxile-entertainment.com/store"
license=("custom:commercial")
depends=('glibc' 'glu' 'libx11' 'libxau' 'libxcb' 'libxcursor' 'libxdmcp' 'libxext' 'libxfixes' 'libxrandr' 'libxrender' 'libgl' 'pulseaudio')
source=("${pkgname}.desktop"
"gog_wasteland_2_director_s_cut_${pkgver}.sh::file://gog_wasteland_2_director_s_cut${pkgver}.sh")
# bsdtar doesn't seem to like this .sh
noextract=("gog_wasteland_2_director_s_cut_${pkgver}.sh")
sha256sums=("1400b3e11c34cbfc57e3b5cba9501a3319ddb57f066d9d09bb7799a59fb0efc0"
"50646ca22f72fbd0eaf4c64b36bd53a2eecc5117a9d21e60253799b81412c3d6")
# Disable compression of the package
PKGEXT='.pkg.tar'
prepare() {
unzip -qd "$srcdir" "$srcdir/gog_wasteland_2_director_s_cut_${pkgver}.sh" || true
mv "$srcdir/data/noarch" "$srcdir/Wasteland 2"
}
package() {
# Binaries
install -Dm755 "$srcdir/Wasteland 2/game/WL2" "$pkgdir/opt/$pkgname/game/WL2"
# Data
# Hardlink files to save the disk space and time spent copying them (they are very large)
cp -Ral -t "$pkgdir/opt/$pkgname/game/" "$srcdir/Wasteland 2/game/WL2_Data"
find "$pkgdir/opt/$pkgname/game/WL2_Data" -type d -print0 | xargs -0 chmod 755
find "$pkgdir/opt/$pkgname/game/WL2_Data" -type f -print0 | xargs -0 chmod 644
# Docs
install -m755 -d "$pkgdir/opt/$pkgname/docs/"
find "$srcdir/Wasteland 2/docs/" -maxdepth 1 -type f -print0 | \
xargs -0 install -m644 -t "$pkgdir/opt/$pkgname/docs/"
# Icon
install -m755 -d "$pkgdir/opt/$pkgname/"
install -m644 -t "$pkgdir/opt/$pkgname/" "$srcdir/Wasteland 2/support/icon.png"
#
# System integration
#
# /bin
install -m755 -d "$pkgdir/usr/bin/"
ln -s "/opt/$pkgname/game/WL2" "$pkgdir/usr/bin/$pkgname"
# License
install -m755 -d "$pkgdir/usr/share/licenses/$pkgname/"
ln -s "/opt/$pkgname/docs/End User License Agreement.txt" "$pkgdir/usr/share/licenses/$pkgname/EULA"
# Icon
install -m755 -d "$pkgdir/usr/share/pixmaps/"
ln -s "/opt/$pkgname/icon.png" "$pkgdir/usr/share/pixmaps/${pkgname}.png"
# .desktop File
install -m755 -d "$pkgdir/usr/share/applications/"
install -m644 -t "$pkgdir/usr/share/applications/" "$srcdir/${pkgname}.desktop"
# Doc
install -m755 -d "$pkgdir/usr/share/doc/"
ln -s "/opt/$pkgname/docs" "$pkgdir/usr/share/doc/$pkgname"
}
|