blob: de874b59bfa21352f3ea2108c4dd89ed39bae795 (
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
|
# Maintainer: bemxio <bemxiov at protonmail dot com>
pkgname="craftworld-toolkit"
pkgdesc="Tools for working with the LittleBigPlanet series"
pkgver=0.1.1
pkgrel=4
arch=(x86_64 aarch64)
url="https://github.com/ennuo/toolkit"
#license=(MIT)
depends=('java-runtime>=17')
makedepends=('java-environment>=17' maven gendesk)
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/ennuo/toolkit/archive/refs/tags/v${pkgver}.tar.gz" craftworld-toolkit)
md5sums=(4d4aaa0a684229a4c4e183443aaf320a a94b935d56e687c1f57adfe095d7a98a)
prepare() {
# generate a .desktop file
gendesk -f -n \
--pkgname "Craftworld Toolkit" \
--pkgdesc "${pkgdesc}" \
--exec craftworld-toolkit \
--icon craftworld-toolkit.png \
--categories "Development;Utility"
}
build() {
# move into the source directory
cd "toolkit-${pkgver}"
# build the project
JAVA_HOME="/usr/lib/jvm/default" mvn package
}
package() {
# move into the source directory
cd "toolkit-${pkgver}"
# copy the main .jar file
install -Dm644 "toolkit/target/toolkit-${pkgver%.*}.jar" "${pkgdir}/usr/share/java/${pkgname}/toolkit.jar"
# copy the extracted icon and the generated .desktop file
install -Dm644 toolkit/src/main/resources/icon.png "${pkgdir}/usr/share/pixmaps/${pkgname}.png"
install -Dm644 '../Craftworld Toolkit.desktop' "${pkgdir}/usr/share/applications/${pkgname}.desktop"
# install the script
install -Dm755 "../${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
}
|