mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-05-14 16:55:27 +00:00
desktop: prepare linux aarch64 (#6107)
* scripts/*: adjust to be arch independent * github/workflows: build aarch64 --------- Co-authored-by: Evgeny Poberezkin <evgeny@poberezkin.com>
This commit is contained in:
@@ -89,8 +89,7 @@ sudo rm -rf /opt/hostedtoolcache/PyPy || :
|
||||
# 376MB
|
||||
sudo rm -rf /opt/hostedtoolcache/node || :
|
||||
# Remove Web browser packages
|
||||
sudo apt purge -y \
|
||||
firefox \
|
||||
google-chrome-stable \
|
||||
microsoft-edge-stable
|
||||
for pkg in firefox google-chrome-stable microsoft-edge-stable; do
|
||||
sudo apt purge -y "$pkg" || echo "Failed or not installed: $pkg"
|
||||
done
|
||||
df -h
|
||||
|
||||
@@ -7,7 +7,7 @@ function readlink() {
|
||||
}
|
||||
|
||||
OS=linux
|
||||
ARCH=${1:-`uname -a | rev | cut -d' ' -f2 | rev`}
|
||||
ARCH="$(uname -m)"
|
||||
GHC_VERSION=9.6.3
|
||||
|
||||
if [ "$ARCH" == "aarch64" ]; then
|
||||
|
||||
@@ -2,6 +2,9 @@
|
||||
|
||||
set -e
|
||||
|
||||
|
||||
ARCH="$(uname -m)"
|
||||
|
||||
function readlink() {
|
||||
echo "$(cd "$(dirname "$1")"; pwd -P)"
|
||||
}
|
||||
@@ -36,13 +39,13 @@ sed -i 's|Icon=.*|Icon=simplex|g' *imple*.desktop
|
||||
cp *imple*.desktop usr/share/applications/
|
||||
cp $multiplatform_dir/desktop/src/jvmMain/resources/distribute/*.appdata.xml usr/share/metainfo
|
||||
|
||||
if [ ! -f ../appimagetool-x86_64.AppImage ]; then
|
||||
wget --secure-protocol=TLSv1_3 https://github.com/simplex-chat/appimagetool/releases/download/continuous/appimagetool-x86_64.AppImage -O ../appimagetool-x86_64.AppImage
|
||||
chmod +x ../appimagetool-x86_64.AppImage
|
||||
if [ ! -f ../appimagetool-${ARCH}.AppImage ]; then
|
||||
wget --secure-protocol=TLSv1_3 https://github.com/simplex-chat/appimagetool/releases/download/continuous/appimagetool-${ARCH}.AppImage -O ../appimagetool-${ARCH}.AppImage
|
||||
chmod +x ../appimagetool-${ARCH}.AppImage
|
||||
fi
|
||||
if [ ! -f ../runtime-x86_64 ]; then
|
||||
wget --secure-protocol=TLSv1_3 https://github.com/simplex-chat/type2-runtime/releases/download/continuous/runtime-x86_64 -O ../runtime-x86_64
|
||||
chmod +x ../runtime-x86_64
|
||||
if [ ! -f ../runtime-${ARCH} ]; then
|
||||
wget --secure-protocol=TLSv1_3 https://github.com/simplex-chat/type2-runtime/releases/download/continuous/runtime-${ARCH} -O ../runtime-${ARCH}
|
||||
chmod +x ../runtime-${ARCH}
|
||||
fi
|
||||
|
||||
# Determenistic build
|
||||
@@ -56,7 +59,7 @@ sed -i -e '/skiko-awt-runtime-linux/d' ./usr/lib/app/simplex.cfg
|
||||
# Set all files to fixed time
|
||||
find . -exec touch -d "@$SOURCE_DATE_EPOCH" {} +
|
||||
|
||||
../appimagetool-x86_64.AppImage --verbose --no-appstream --runtime-file ../runtime-x86_64 .
|
||||
../appimagetool-${ARCH}.AppImage --verbose --no-appstream --runtime-file ../runtime-${ARCH} .
|
||||
mv *imple*.AppImage ../../
|
||||
|
||||
# Just a safeguard
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#!/usr/bin/env sh
|
||||
|
||||
ARCH="$(uname -m)"
|
||||
|
||||
scripts/desktop/build-lib-linux.sh
|
||||
cd apps/multiplatform
|
||||
./gradlew packageDeb
|
||||
@@ -39,6 +41,6 @@ rm -f ./extracted/opt/*imple*/lib/app/*skiko-awt-runtime-linux*
|
||||
sed -i -e '/skiko-awt-runtime-linux/d' ./extracted/opt/*imple*/lib/app/simplex.cfg
|
||||
find ./extracted/ -exec touch -d "@$SOURCE_DATE_EPOCH" {} +
|
||||
|
||||
dpkg-deb --build --root-owner-group --uniform-compression ./extracted ./release/main/deb/simplex_amd64.deb
|
||||
dpkg-deb --build --root-owner-group --uniform-compression ./extracted ./release/main/deb/simplex_${ARCH}.deb
|
||||
|
||||
strip-nondeterminism ./release/main/deb/simplex_amd64.deb
|
||||
strip-nondeterminism ./release/main/deb/simplex_${ARCH}.deb
|
||||
|
||||
@@ -2,16 +2,18 @@
|
||||
|
||||
set -e
|
||||
|
||||
ARCH="$(uname -m)"
|
||||
|
||||
function readlink() {
|
||||
echo "$(cd "$(dirname "$1")"; pwd -P)"
|
||||
}
|
||||
root_dir="$(dirname "$(dirname "$(readlink "$0")")")"
|
||||
vlc_dir=$root_dir/apps/multiplatform/common/src/commonMain/cpp/desktop/libs/linux-x86_64/vlc
|
||||
vlc_dir=$root_dir/apps/multiplatform/common/src/commonMain/cpp/desktop/libs/linux-${ARCH}/vlc
|
||||
|
||||
mkdir $vlc_dir || exit 0
|
||||
|
||||
vlc_tag='v3.0.21-1'
|
||||
vlc_url="https://github.com/simplex-chat/vlc/releases/download/${vlc_tag}/vlc-linux-x86_64.appimage"
|
||||
vlc_url="https://github.com/simplex-chat/vlc/releases/download/${vlc_tag}/vlc-linux-${ARCH}.appimage"
|
||||
|
||||
cd /tmp
|
||||
mkdir tmp 2>/dev/null || true
|
||||
|
||||
Reference in New Issue
Block a user