aports/orphan/spigot-mc/APKBUILD

37 lines
1.3 KiB
Plaintext

# Contributor: Alex Denes <caskd@redxen.eu>
# Maintainer:
pkgname=spigot
pkgver=1.16.5
pkgrel=0
_buildno=126
pkgdesc="Spigot server implementation"
url="https://www.spigotmc.org/wiki/buildtools/#linux"
arch="noarch"
license="propietary"
depends="openjdk8-jre"
makedepends="git openjdk8 bash" # TODO: Find a way to use packaged maven
subpackages="$pkgname-openrc"
source="
$pkgname-BuildTools-$_buildno.jar::https://hub.spigotmc.org/jenkins/job/BuildTools/$_buildno/artifact/target/BuildTools.jar
spigot.initd
"
builddir="$srcdir/"
options="!check"
build() {
/usr/lib/jvm/java-8-openjdk/jre/bin/java -jar "$pkgname-BuildTools-$_buildno.jar" --rev "$pkgver"
cat > spigot.sh <<EOF
#!/bin/sh
/usr/lib/jvm/java-8-openjdk/jre/bin/java -jar "/usr/lib/spigot/spigot-$pkgver.jar" \$@
EOF
}
package() {
install -Dm755 "$builddir"/spigot.sh "$pkgdir"/usr/bin/spigot
install -Dm755 "$srcdir"/spigot.initd "$pkgdir"/etc/init.d/spigot
install -Dm644 "$builddir"/spigot-$pkgver.jar "$pkgdir"/usr/lib/spigot/spigot-$pkgver.jar
}
sha512sums="92fe99a967d3899cd7415c867128d755ab23dfd2cbb945806db52013c21105e694ec30ddd9e1599bd7b47101ceb2b5a73f8034f4ce09e1d9b97d29af9183e82a spigot-BuildTools-126.jar
d9ae3a5c28ba56d5e90ad3bee0fa8745aba85de0849d86b2d5cbd371e5386733e65b535147559e026d847af64b09c04da6d120f18a09d581281422754b3a1f8d spigot.initd"