WIP: Parallelize macOS CI builds by splitting arm64 and x86_64 into separate jobs (#12562)

* Parallelize macOS CI builds by splitting arm64 and x86_64 into separate jobs

* fix shell errors

* Delete intermediate per-arch artifacts
This commit is contained in:
SoftFever
2026-03-03 19:29:59 +08:00
committed by GitHub
parent 1f19ff67a3
commit b7033a4c92
5 changed files with 157 additions and 72 deletions

View File

@@ -30,16 +30,16 @@ jobs:
with:
lfs: 'true'
- name: set outputs
id: set_outputs
env:
# Normalize macOS runner names so self-hosted and GitHub-hosted produce the same cache key
cache-os: ${{ contains(inputs.os, 'macos') && 'macos-arm64' || inputs.os }}
dep-folder-name: ${{ !contains(inputs.os, 'macos') && '/OrcaSlicer_dep' || '' }}
output-cmd: ${{ inputs.os == 'windows-latest' && '$env:GITHUB_OUTPUT' || '"$GITHUB_OUTPUT"'}}
run: |
echo cache-key=${{ env.cache-os }}-cache-orcaslicer_deps-build-${{ hashFiles('deps/**') }} >> ${{ env.output-cmd }}
echo cache-path=${{ github.workspace }}/deps/build${{ env.dep-folder-name }} >> ${{ env.output-cmd }}
- name: set outputs
id: set_outputs
env:
# Keep macOS cache keys and paths architecture-specific.
cache-os: ${{ contains(inputs.os, 'macos') && format('macos-{0}', inputs.arch) || inputs.os }}
dep-folder-name: ${{ contains(inputs.os, 'macos') && format('/{0}', inputs.arch) || '/OrcaSlicer_dep' }}
output-cmd: ${{ inputs.os == 'windows-latest' && '$env:GITHUB_OUTPUT' || '"$GITHUB_OUTPUT"'}}
run: |
echo cache-key=${{ env.cache-os }}-cache-orcaslicer_deps-build-${{ hashFiles('deps/**') }} >> ${{ env.output-cmd }}
echo cache-path=${{ github.workspace }}/deps/build${{ env.dep-folder-name }} >> ${{ env.output-cmd }}
- name: load cache
id: cache_deps