-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathbuild-linux-aarch64.sh
68 lines (49 loc) · 1.98 KB
/
build-linux-aarch64.sh
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
#!/bin/bash
set -e
pushd native
cmake -DCMAKE_TOOLCHAIN_FILE=arm64-linux-gcc.cmake -B build-aarch64 .
cmake --build build-aarch64 --config Release
popd
APPIMAGE_VERSION="13"
umask 022
source .jdk-versions.sh
rm -rf build/linux-aarch64
mkdir -p build/linux-aarch64
if ! [ -f linux_aarch64_jre.tar.gz ] ; then
curl -Lo linux_aarch64_jre.tar.gz $LINUX_AARCH64_LINK
fi
echo "$LINUX_AARCH64_CHKSUM linux_aarch64_jre.tar.gz" | sha256sum -c
# Note: Host umask may have checked out this directory with g/o permissions blank
chmod -R u=rwX,go=rX appimage
# ...ditto for the build process
chmod 644 target/Elvarg.jar
cp native/build-aarch64/src/Elvarg build/linux-aarch64/
cp target/Elvarg.jar build/linux-aarch64/
cp packr/linux-aarch64-config.json build/linux-aarch64/config.json
cp target/filtered-resources/app.desktop build/linux-aarch64/
cp appimage/app.png build/linux-aarch64/
tar zxf linux_aarch64_jre.tar.gz
mv jdk-$LINUX_AMD64_VERSION-jre build/linux-aarch64/jre
pushd build/linux-aarch64
mkdir -p jre/lib/amd64/server/
ln -s ../../server/libjvm.so jre/lib/amd64/server/ # packr looks for libjvm at this hardcoded path
# Symlink AppRun -> RuneLite
ln -s Elvarg AppRun
# Ensure RuneLite is executable to all users
chmod 755 Elvarg
popd
if ! [ -f appimagetool-x86_64.AppImage ] ; then
curl -Lo appimagetool-x86_64.AppImage \
https://github.com/AppImage/AppImageKit/releases/download/$APPIMAGE_VERSION/appimagetool-x86_64.AppImage
chmod +x appimagetool-x86_64.AppImage
fi
echo "df3baf5ca5facbecfc2f3fa6713c29ab9cefa8fd8c1eac5d283b79cab33e4acb appimagetool-x86_64.AppImage" | sha256sum -c
if ! [ -f runtime-aarch64 ] ; then
curl -Lo runtime-aarch64 \
https://github.com/AppImage/AppImageKit/releases/download/$APPIMAGE_VERSION/runtime-aarch64
fi
echo "d2624ce8cc2c64ef76ba986166ad67f07110cdbf85112ace4f91611bc634c96a runtime-aarch64" | sha256sum -c
ARCH=arm_aarch64 ./appimagetool-x86_64.AppImage \
--runtime-file runtime-aarch64 \
build/linux-aarch64/ \
Elvarg-aarch64.AppImage