Skip to content

Commit

Permalink
GHA
Browse files Browse the repository at this point in the history
  • Loading branch information
MrAlex94 committed Jul 17, 2023
1 parent 3d79f0a commit 8fd0bd3
Showing 1 changed file with 26 additions and 20 deletions.
46 changes: 26 additions & 20 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ jobs:
if: ${{ inputs.TRIGGER_EVENT == 'workflow_dispatch' }}
env:
LINK: https://github.com/mozilla/sccache/releases/download
SCCACHE_VERSION: "v0.5.3"
SCCACHE_VERSION: "v0.5.4"
run: |
SCCACHE_FILE=sccache-$SCCACHE_VERSION-x86_64-unknown-linux-musl
mkdir -p $HOME/.local/bin
Expand Down Expand Up @@ -233,7 +233,7 @@ jobs:
if: ${{ inputs.TRIGGER_EVENT == 'workflow_dispatch' }}
env:
LINK: https://github.com/mozilla/sccache/releases/download
SCCACHE_VERSION: "v0.5.3"
SCCACHE_VERSION: "v0.5.4"
run: |
SCCACHE_FILE=sccache-$SCCACHE_VERSION-x86_64-unknown-linux-musl
mkdir -p $HOME/.local/bin
Expand Down Expand Up @@ -481,7 +481,7 @@ jobs:
if: ${{ inputs.TRIGGER_EVENT == 'workflow_dispatch' }}
env:
LINK: https://github.com/mozilla/sccache/releases/download
SCCACHE_VERSION: "v0.5.3"
SCCACHE_VERSION: "v0.5.4"
run: |
SCCACHE_FILE=sccache-$SCCACHE_VERSION-x86_64-unknown-linux-musl
mkdir -p $HOME/.local/bin
Expand Down Expand Up @@ -571,12 +571,17 @@ jobs:
retention-days: 1
build-macos-multi-stage-2:
name: macOS Stage 2
runs-on: tartelet
runs-on: ${{ matrix.runs-on }}
concurrency:
group: "${{ github.head_ref }}-macos-multi-stage-2"
cancel-in-progress: true
env:
ARCH: aarch64-apple-darwin
strategy:
matrix:
include:
- runs-on: macos-13-xl
arch: x86_64-apple-darwin
- runs-on: tartelet
arch: aarch64-apple-darwin
needs:
- build-macos-multi-stage-1
steps:
Expand All @@ -585,23 +590,23 @@ jobs:
- name: ⏬ Download Stage 1 macOS artifact
uses: actions/download-artifact@v3
with:
name: macos-${{ env.ARCH }}-stage-1-${{ github.run_id }}
path: obj-${{ env.ARCH }}/dist/
name: macos-${{ matrix.arch }}-stage-1-${{ github.run_id }}
path: obj-${{ matrix.arch }}/dist/
- name: "\U0001F3D7 Run PGO"
run: |
ls obj-${{ env.ARCH }}/dist/
ls obj-${{ env.ARCH }}/dist/waterfox
sudo xattr -dr com.apple.quarantine ./obj-${{ env.ARCH }}/dist/waterfox/Waterfox.app
sudo spctl --add ./obj-${{ env.ARCH }}/dist/waterfox/Waterfox.app
find ./obj-${{ env.ARCH }}/dist/waterfox/ -type f -exec /bin/sh -c "file {} | grep -q executable && chmod +x {}" \;
ls obj-${{ matrix.arch }}/dist/
ls obj-${{ matrix.arch }}/dist/waterfox
sudo xattr -dr com.apple.quarantine ./obj-${{ matrix.arch }}/dist/waterfox/Waterfox.app
sudo spctl --add ./obj-${{ matrix.arch }}/dist/waterfox/Waterfox.app
find ./obj-${{ matrix.arch }}/dist/waterfox/ -type f -exec /bin/sh -c "file {} | grep -q executable && chmod +x {}" \;
rm .mozconfig
./mach --no-interactive bootstrap --application-choice=browser
LLVM_PROFDATA=$HOME/.mozbuild/clang/bin/llvm-profdata JARLOG_FILE=en-US.log ./mach python build/pgo/profileserver.py --binary ./obj-${{ env.ARCH }}/dist/waterfox/Waterfox.app/Contents/MacOS/waterfox
LLVM_PROFDATA=$HOME/.mozbuild/clang/bin/llvm-profdata JARLOG_FILE=en-US.log ./mach python build/pgo/profileserver.py --binary ./obj-${{ matrix.arch }}/dist/waterfox/Waterfox.app/Contents/MacOS/waterfox
- name: "\U0001F199 Upload Stage 2 Artifact"
if: ${{ inputs.TRIGGER_EVENT == 'workflow_dispatch' }}
uses: actions/upload-artifact@v3
with:
name: macos-${{ env.ARCH }}-stage-2-${{ github.run_id }}
name: macos-${{ matrix.arch }}-stage-2-${{ github.run_id }}
path: |
merged.profdata
en-US.log
Expand All @@ -614,6 +619,7 @@ jobs:
strategy:
matrix:
arch:
- x86_64-apple-darwin
- aarch64-apple-darwin
concurrency:
group: "${{ github.ref }}-${{ matrix.arch }}-macos-multi"
Expand All @@ -629,7 +635,7 @@ jobs:
if: ${{ inputs.TRIGGER_EVENT == 'workflow_dispatch' }}
env:
LINK: https://github.com/mozilla/sccache/releases/download
SCCACHE_VERSION: "v0.5.3"
SCCACHE_VERSION: "v0.5.4"
run: |
SCCACHE_FILE=sccache-$SCCACHE_VERSION-x86_64-unknown-linux-musl
mkdir -p $HOME/.local/bin
Expand Down Expand Up @@ -713,7 +719,7 @@ jobs:
if [ -d "$PWD"/waterfox/browser/locales/en-GB ]; then
./mach package-multi-locale --locales ar cs da de el en-GB en-US es-ES es-MX fr hu id it ja ko lt nl nn-NO pl pt-BR pt-PT ru sv-SE th vi zh-CN zh-TW
fi
- name: "\U0001F199 Upload Stage 1 Artifacts"
- name: "\U0001F199 Upload Stage 3 Artifacts"
if: ${{ inputs.TRIGGER_EVENT == 'workflow_dispatch' }}
uses: actions/upload-artifact@v3
with:
Expand All @@ -727,7 +733,7 @@ jobs:
if: ${{ inputs.TRIGGER_EVENT == 'workflow_dispatch' }}
needs:
- build-macos-multi-stage-3
runs-on: tartelet
runs-on: macos-13-xl
env:
ARCH-X64: x86_64-apple-darwin
ARCH-ARM64: aarch64-apple-darwin
Expand All @@ -745,7 +751,7 @@ jobs:
- name: ⏬ Download Stage 1 X64 artifact
uses: actions/download-artifact@v3
with:
name: macos-${{ env.ARCH-X64 }}-stage-1-${{ github.run_id }}
name: macos-${{ env.ARCH-X64 }}-stage-3-${{ github.run_id }}
path: "./obj-${{ env.ARCH-X64 }}/dist/"
- name: ⏬ Download Stage 3 ARM64 artifact
uses: actions/download-artifact@v3
Expand Down Expand Up @@ -888,7 +894,7 @@ jobs:
if: ${{ inputs.TRIGGER_EVENT == 'workflow_dispatch' }}
env:
LINK: https://github.com/mozilla/sccache/releases/download
SCCACHE_VERSION: "v0.5.3"
SCCACHE_VERSION: "v0.5.4"
run: |
SCCACHE_FILE=sccache-$SCCACHE_VERSION-x86_64-unknown-linux-musl
mkdir -p $HOME/.local/bin
Expand Down

0 comments on commit 8fd0bd3

Please sign in to comment.