1 # Maintainer: George Rawlinson <grawlinson@archlinux.org>
2 # Maintainer: Peter Cai <peter at typeblog dot net>
3 # Thanks: Kevin MacMartin <prurigro at gmail dot com>
5 pkgname=shattered-pixel-dungeon
8 pkgdesc='A roguelike dungeon crawler with randomized levels and enemies, and hundreds of items'
10 url='https://shatteredpixel.com/shatteredpd/'
12 depends=('bash' 'xorg-xrandr' 'java-runtime>=11' 'hicolor-icon-theme')
13 makedepends=('git' 'jdk11-openjdk' 'gradle')
14 _commit='ff40272da050f5fc446d16c6ff6b9496fe21d908'
16 "$pkgname::git+https://github.com/00-Evan/shattered-pixel-dungeon#commit=$_commit"
22 '94e110340bddcdf64d74922e9ddf4c0f37e72466ea61edcde61f903680f57b10d81ff804b95f2467e4364a577f7c845d66137fedfc700d11638defe6a3359a93'
23 'c0b0d7d7319159716f1e49620c3c9a0bea9dea149cb1b88da0294a343341075557fe86bd45965a23aa34054ee6c454dd9a0b73273e6cafaf75de3d3fa3ef0ab1'
24 '194480092028d1ab10b7bdb036233ba11984bd994346f9f6b925b7516da80f7214f8dff86e27054a5f9b792d1192732938d88f2121fd5207ad0a93aa5d571e0a')
29 git describe --tags | sed 's/^v//'
35 patch -p1 -i "$srcdir/gradle-repro.patch"
41 # Force the system to build the package using JDK 11
42 export PATH="/usr/lib/jvm/java-11-openjdk/bin/:$PATH"
43 export JAVA_HOME="/usr/lib/jvm/java-11-openjdk"
45 gradle desktop:release
52 install -vDm755 "$srcdir/wrapper.sh" "$pkgdir/usr/bin/$pkgname"
55 install -vDm644 "desktop/build/libs/desktop-$pkgver.jar" "$pkgdir/usr/share/$pkgname/$pkgname.jar"
58 install -vDm644 -t "$pkgdir/usr/share/applications" "$srcdir/$pkgname.desktop"
61 for i in 16 32 48 64 128 256; do
62 install -vDm644 "desktop/src/main/assets/icons/icon_${i}.png" "$pkgdir/usr/share/icons/hicolor/${i}x${i}/apps/$pkgname.png"
64 install -vDm644 android/src/main/res/mipmap-xxxhdpi/ic_launcher.png "$pkgdir/usr/share/icons/hicolor/192x192/apps/$pkgname.png"