From bcad3557b6b01f02526ee4d08a95fae0bb49a51f Mon Sep 17 00:00:00 2001 From: cochcoder Date: Thu, 16 Jan 2025 23:10:07 -0500 Subject: [PATCH] Initial appimage arm64 builds --- .github/workflows/build_all.yml | 6 ++++++ .github/workflows/build_check_cache.yml | 2 +- .github/workflows/build_deps.yml | 10 +++++----- .github/workflows/build_orca.yml | 12 ++++++------ 4 files changed, 18 insertions(+), 12 deletions(-) diff --git a/.github/workflows/build_all.yml b/.github/workflows/build_all.yml index 3d748eb79a..9167553a6e 100644 --- a/.github/workflows/build_all.yml +++ b/.github/workflows/build_all.yml @@ -48,7 +48,13 @@ jobs: matrix: include: - os: ubuntu-20.04 + arch: x86_64 + - os: ubuntu-20.04 + arch: aarch64 - os: ubuntu-24.04 + arch: x86_64 + - os: ubuntu-24.04 + arch: aarch64 - os: windows-latest - os: macos-14 arch: x86_64 diff --git a/.github/workflows/build_check_cache.yml b/.github/workflows/build_check_cache.yml index f71cc9b281..3de4f669cb 100644 --- a/.github/workflows/build_check_cache.yml +++ b/.github/workflows/build_check_cache.yml @@ -31,7 +31,7 @@ jobs: id: set_outputs env: underscore-arch: ${{ inputs.os == 'macos-14' && '_' || ''}}${{ inputs.os == 'macos-14' && inputs.arch || '' }} # if is macos, make a string that does "_{arch}", else output nothing - dash-arch: ${{ inputs.os == 'macos-14' && '-' || ''}}${{ inputs.os == 'macos-14' && inputs.arch || '' }} # if is macos, make a string that does "-{arch}", else output nothing + dash-arch: ${{ (inputs.os == 'macos-14' || inputs.os == 'ubuntu-20.04' || inputs.os == 'ubuntu-24.04') && '-' || '' }}${{ (inputs.os == 'macos-14' || inputs.os == 'ubuntu-20.04' || inputs.os == 'ubuntu-24.04') && inputs.arch || '' }} # if is ubuntu/macos, make a string that does "-{arch}", else output nothing dep-folder-name: ${{ (inputs.os == 'windows-latest' || inputs.os == 'macos-14') && 'OrcaSlicer_dep' || 'destdir' }} output-cmd: ${{ inputs.os == 'windows-latest' && '$env:GITHUB_OUTPUT' || '"$GITHUB_OUTPUT"'}} run: | diff --git a/.github/workflows/build_deps.yml b/.github/workflows/build_deps.yml index 6c0dc9479c..30434a32e7 100644 --- a/.github/workflows/build_deps.yml +++ b/.github/workflows/build_deps.yml @@ -84,7 +84,7 @@ jobs: ./build_release_macos.sh -dpx -a ${{ inputs.arch }} -t 10.15 -1 brew install zstd - + # Note for later: may need libtool and libpng++-dev dependencies for arm builds - name: Install Ubuntu Build Dependencies if: inputs.os == 'ubuntu-20.04' || inputs.os == 'ubuntu-24.04' working-directory: ${{ github.workspace }} @@ -103,13 +103,13 @@ jobs: if: inputs.os == 'ubuntu-20.04' || inputs.os == 'ubuntu-24.04' working-directory: ${{ github.workspace }} run: | - mkdir -p ${{ github.workspace }}/deps/build - mkdir -p ${{ github.workspace }}/deps/build/destdir + mkdir -p ${{ github.workspace }}/deps/build_${{ inputs.arch }} + mkdir -p ${{ github.workspace }}/deps/build_${{ inputs.arch }}/destdir sudo ./BuildLinux.sh -ur sudo chown $USER -R ./ ./BuildLinux.sh -dr - cd deps/build - tar -czvf OrcaSlicer_dep_ubuntu_$(date +"%Y%m%d").tar.gz destdir + cd deps/build_${{ inputs.arch }} + tar -czvf OrcaSlicer_dep_ubuntu_$(date +"%Y%m%d")_${{ inputs.arch }}.tar.gz destdir # Upload Artifacts diff --git a/.github/workflows/build_orca.yml b/.github/workflows/build_orca.yml index b31fdbcd70..fa58ba2dd3 100644 --- a/.github/workflows/build_orca.yml +++ b/.github/workflows/build_orca.yml @@ -264,12 +264,12 @@ jobs: ubuntu-ver-str: ${{ (inputs.os == 'ubuntu-24.04' && '_Ubuntu2404') || '' }} run: | ./BuildLinux.sh -isr - mv -n ./build/OrcaSlicer_Linux_V${{ env.ver_pure }}.AppImage ./build/OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}.AppImage - chmod +x ./build/OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}.AppImage + mv -n ./build_${{ inputs.arch }}/OrcaSlicer_Linux_V${{ env.ver_pure }}_${{ inputs.arch }}.AppImage ./build_${{ inputs.arch }}/OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}_${{ inputs.arch }}.AppImage + chmod +x ./build_${{ inputs.arch }}/OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}_${{ inputs.arch }}.AppImage - name: Build orca_custom_preset_tests if: github.ref == 'refs/heads/main' && inputs.os == 'ubuntu-20.04' - working-directory: ${{ github.workspace }}/build/src + working-directory: ${{ github.workspace }}/build_${{ inputs.arch }}/src shell: bash run: | ./OrcaSlicer_profile_validator -p ${{ github.workspace }}/resources/profiles -g 1 @@ -284,7 +284,7 @@ jobs: uses: actions/upload-artifact@v4 with: name: OrcaSlicer_Linux_ubuntu_${{ env.ubuntu-ver }}_${{ env.ver }} - path: './build/OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}.AppImage' + path: './build_${{ inputs.arch }}/OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}_${{ inputs.arch }}.AppImage' - name: Deploy Ubuntu release if: ${{ ! env.ACT && github.ref == 'refs/heads/main' && (inputs.os == 'ubuntu-20.04' || inputs.os == 'ubuntu-24.04') }} @@ -294,8 +294,8 @@ jobs: with: upload_url: https://uploads.github.com/repos/SoftFever/OrcaSlicer/releases/137995723/assets{?name,label} release_id: 137995723 - asset_path: ./build/OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}.AppImage - asset_name: OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}.AppImage + asset_path: ./build_${{ inputs.arch }}/OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}_${{ inputs.arch }}.AppImage + asset_name: OrcaSlicer_Linux_AppImage${{ env.ubuntu-ver-str }}_${{ env.ver }}_${{ inputs.arch }}.AppImage asset_content_type: application/octet-stream max_releases: 1 # optional, if there are more releases than this matching the asset_name, the oldest ones are going to be deleted