mirror of
https://github.com/ton-blockchain/ton
synced 2025-03-09 15:40:10 +00:00
test appimages on arm64 linux
This commit is contained in:
parent
4c87ebeda2
commit
ffb95de4f1
3 changed files with 107 additions and 2 deletions
57
.github/workflows/build-ton-linux-arm64-appimage.yml
vendored
Normal file
57
.github/workflows/build-ton-linux-arm64-appimage.yml
vendored
Normal file
|
@ -0,0 +1,57 @@
|
||||||
|
name: Ubuntu TON build (AppImages, arm64)
|
||||||
|
|
||||||
|
on: [push,workflow_dispatch,workflow_call]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-22.04-arm
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Check out repository
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
submodules: 'recursive'
|
||||||
|
|
||||||
|
- name: Install system libraries
|
||||||
|
run: |
|
||||||
|
sudo apt update
|
||||||
|
sudo apt install -y build-essential git cmake ninja-build zlib1g-dev libsecp256k1-dev libmicrohttpd-dev libsodium-dev liblz4-dev
|
||||||
|
sudo apt remove libgsl-dev
|
||||||
|
|
||||||
|
- name: Install clang-16
|
||||||
|
run: |
|
||||||
|
wget https://apt.llvm.org/llvm.sh
|
||||||
|
chmod +x llvm.sh
|
||||||
|
sudo ./llvm.sh 16 all
|
||||||
|
|
||||||
|
- name: Build TON
|
||||||
|
run: |
|
||||||
|
git submodule sync --recursive
|
||||||
|
git submodule update
|
||||||
|
cp assembly/native/build-ubuntu-appimages.sh .
|
||||||
|
chmod +x build-ubuntu-appimages.sh
|
||||||
|
./build-ubuntu-appimages.sh -a
|
||||||
|
|
||||||
|
- name: Make AppImages
|
||||||
|
run: |
|
||||||
|
cp assembly/appimage/create-appimages-arm64.sh .
|
||||||
|
cp assembly/appimage/AppRun .
|
||||||
|
cp assembly/appimage/ton.png .
|
||||||
|
chmod +x create-appimages-arm64.sh
|
||||||
|
./create-appimages.sh
|
||||||
|
rm -rf artifacts
|
||||||
|
|
||||||
|
|
||||||
|
- name: Build TON libs
|
||||||
|
run: |
|
||||||
|
cp assembly/native/build-ubuntu-portable-libs.sh .
|
||||||
|
chmod +x build-ubuntu-portable-libs.sh
|
||||||
|
./build-ubuntu-portable-libs.sh -a
|
||||||
|
cp ./artifacts/libtonlibjson.so appimages/artifacts/
|
||||||
|
cp ./artifacts/libemulator.so appimages/artifacts/
|
||||||
|
|
||||||
|
- name: Upload artifacts
|
||||||
|
uses: actions/upload-artifact@master
|
||||||
|
with:
|
||||||
|
name: ton-arm64-linux
|
||||||
|
path: appimages/artifacts
|
|
@ -21,8 +21,8 @@ jobs:
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install -y build-essential git cmake ninja-build zlib1g-dev libsecp256k1-dev libmicrohttpd-dev libsodium-dev liblz4-dev libjemalloc-dev
|
sudo apt-get install -y build-essential git cmake ninja-build zlib1g-dev libsecp256k1-dev libmicrohttpd-dev libsodium-dev liblz4-dev libjemalloc-dev
|
||||||
|
|
||||||
|
- if: matrix.os != 'ubuntu-24.04-arm'
|
||||||
- if: matrix.os != 'ubuntu-24.04'
|
name: Install llvm-16
|
||||||
run: |
|
run: |
|
||||||
wget https://apt.llvm.org/llvm.sh
|
wget https://apt.llvm.org/llvm.sh
|
||||||
chmod +x llvm.sh
|
chmod +x llvm.sh
|
||||||
|
|
48
assembly/appimage/create-appimages-arm64.sh
Normal file
48
assembly/appimage/create-appimages-arm64.sh
Normal file
|
@ -0,0 +1,48 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
if [ ! -d "artifacts" ]; then
|
||||||
|
echo "No artifacts found."
|
||||||
|
exit 2
|
||||||
|
fi
|
||||||
|
|
||||||
|
rm -rf appimages
|
||||||
|
|
||||||
|
mkdir -p appimages/artifacts
|
||||||
|
|
||||||
|
wget -nc https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-aarch64.AppImage
|
||||||
|
chmod +x ./appimagetool-aarch64.AppImage
|
||||||
|
|
||||||
|
cd appimages
|
||||||
|
for file in ../artifacts/*; do
|
||||||
|
if [[ -f "$file" && "$file" != *.so ]]; then
|
||||||
|
appName=$(basename "$file")
|
||||||
|
echo $appName
|
||||||
|
# prepare AppDir
|
||||||
|
mkdir -p $appName.AppDir/usr/{bin,lib}
|
||||||
|
cp ../AppRun $appName.AppDir/AppRun
|
||||||
|
sed -i "s/app/$appName/g" $appName.AppDir/AppRun
|
||||||
|
chmod +x ./$appName.AppDir/AppRun
|
||||||
|
printf '[Desktop Entry]\nName='$appName'\nExec='$appName'\nIcon='$appName'\nType=Application\nCategories=Utility;\n' > $appName.AppDir/$appName.desktop
|
||||||
|
cp ../ton.png $appName.AppDir/$appName.png
|
||||||
|
cp $file $appName.AppDir/usr/bin/
|
||||||
|
cp ../build/openssl_3/libcrypto.so.3 \
|
||||||
|
/lib/aarch64-linux-gnu/libatomic.so.1 \
|
||||||
|
/lib/aarch64-linux-gnu/libsodium.so.23 \
|
||||||
|
/lib/aarch64-linux-gnu/libz.so.1 \
|
||||||
|
/lib/aarch64-linux-gnu/liblz4.so.1 \
|
||||||
|
/lib/aarch64-linux-gnu/libmicrohttpd.so.12 \
|
||||||
|
/lib/aarch64-linux-gnu/libreadline.so.8 \
|
||||||
|
/lib/aarch64-linux-gnu/libstdc++.so.6 \
|
||||||
|
$appName.AppDir/usr/lib/
|
||||||
|
|
||||||
|
chmod +x ./$appName.AppDir/usr/bin/$appName
|
||||||
|
# create AppImage
|
||||||
|
./../appimagetool-aarch64.AppImage -l $appName.AppDir
|
||||||
|
mv $appName-aarch64.AppImage artifacts/$appName
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
ls -larth artifacts
|
||||||
|
cp -r ../artifacts/{smartcont,lib} artifacts/
|
||||||
|
pwd
|
||||||
|
ls -larth artifacts
|
Loading…
Add table
Add a link
Reference in a new issue