Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

⬆️ (toolchain): Upgrade to gcc 13.3 Rel1 #69

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 15 additions & 29 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,50 +9,36 @@ concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
HOMEBREW_GITHUB_API_TOKEN: ${{ secrets.OSX_CROSS_ARM_HOMEBREW_GITHUB_API_TOKEN }}
PULL_REQUEST: ${{ github.event.pull_request.number }}
BRANCH: ${{ github.event.pull_request.head.ref }}

jobs:
pr-pull:
if: contains(github.event.pull_request.labels.*.name, 'pr-pull')
runs-on: macos-latest
runs-on: ubuntu-22.04
permissions:
contents: write
pull-requests: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
token: "${{ secrets.OSX_CROSS_ARM_HOMEBREW_GITHUB_API_TOKEN }}"

- name: Set up Homebrew
uses: Homebrew/actions/setup-homebrew@master

- name: Cache Homebrew Bundler RubyGems
id: cache
uses: actions/cache@v4
with:
path: ${{ steps.set-up-homebrew.outputs.gems-path }}
key: ${{ runner.os }}-rubygems-${{ steps.set-up-homebrew.outputs.gems-hash }}
restore-keys: ${{ runner.os }}-rubygems-

- name: Install Homebrew Bundler RubyGems
if: steps.cache.outputs.cache-hit != 'true'
run: brew install-bundler-gems

- name: Set up git
run: |
git config --global user.name "osxCrossTestBot"
git config --global user.email "osxCrossTestBot@leka.io"
uses: Homebrew/actions/git-user-config@master
with:
username: osxCrossTestBot

- name: Pull bottles
run: brew pr-pull --debug --tap=$GITHUB_REPOSITORY $PULL_REQUEST
env:
HOMEBREW_GITHUB_API_TOKEN: ${{ github.token }}
PULL_REQUEST: ${{ github.event.pull_request.number }}
run: brew pr-pull --debug --tap="$GITHUB_REPOSITORY" "$PULL_REQUEST"

- name: Push commits
uses: Homebrew/actions/git-try-push@master
with:
token: ${{ secrets.OSX_CROSS_ARM_HOMEBREW_GITHUB_API_TOKEN }}
token: ${{ github.token }}
branch: master

- name: Delete branch
if: github.event.pull_request.head.repo.fork == false
run: git push --delete origin $BRANCH
env:
BRANCH: ${{ github.event.pull_request.head.ref }}
run: git push --delete origin "$BRANCH"
10 changes: 2 additions & 8 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,7 @@ on:
branches:
- main
- master

pull_request:
types: [opened, synchronize, reopened]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand All @@ -18,7 +16,7 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [macos-12, macos-13, macos-14]
os: [macos-13, macos-14]
runs-on: ${{ matrix.os }}
steps:
- name: Set up Homebrew
Expand All @@ -33,10 +31,6 @@ jobs:
key: ${{ runner.os }}-rubygems-${{ steps.set-up-homebrew.outputs.gems-hash }}
restore-keys: ${{ runner.os }}-rubygems-

- name: Install Homebrew Bundler RubyGems
if: steps.cache.outputs.cache-hit != 'true'
run: brew install-bundler-gems

- run: brew test-bot --only-cleanup-before

- run: brew test-bot --only-setup
Expand All @@ -50,5 +44,5 @@ jobs:
if: always() && github.event_name == 'pull_request'
uses: actions/upload-artifact@v4
with:
name: bottles
name: bottles-${{ matrix.os }}
path: "*.bottle.*"
20 changes: 7 additions & 13 deletions Formula/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -2,30 +2,24 @@

class ArmGccBinAT13 < Formula
@tar_file = if Hardware::CPU.arm?
"arm-gnu-toolchain-13.2.rel1-darwin-arm64-arm-none-eabi.tar.xz"
"arm-gnu-toolchain-13.3.rel1-darwin-arm64-arm-none-eabi.tar.xz"
else
"arm-gnu-toolchain-13.2.rel1-darwin-x86_64-arm-none-eabi.tar.xz"
"arm-gnu-toolchain-13.3.rel1-darwin-x86_64-arm-none-eabi.tar.xz"
end

@tar_file_sha = if Hardware::CPU.arm?
"39c44f8af42695b7b871df42e346c09fee670ea8dfc11f17083e296ea2b0d279"
"fb6921db95d345dc7e5e487dd43b745e3a5b4d5c0c7ca4f707347148760317b4"
else
"075faa4f3e8eb45e59144858202351a28706f54a6ec17eedd88c9fb9412372cc"
"1ab00742d1ed0926e6f227df39d767f8efab46f5250505c29cb81f548222d794"
end

desc "Pre-built GNU toolchain for Arm Cortex-M and Cortex-R processors"
homepage "https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads"
url "https://developer.arm.com/-/media/Files/downloads/gnu/13.2.rel1/binrel/#{@tar_file}"
url "https://developer.arm.com/-/media/Files/downloads/gnu/13.3.rel1/binrel/#{@tar_file}"
sha256 @tar_file_sha

bottle do
root_url "https://github.com/osx-cross/homebrew-arm/releases/download/[email protected]"
sha256 cellar: :any_skip_relocation, arm64_sonoma: "91ec58e4f00cf911ed4d12534591b776e9b1217ceb3b5b5f582da76646f70de7"
sha256 cellar: :any_skip_relocation, ventura: "6e8834c9c8bd67023b438451588ac679b2c520139ff9daec0692f184923078ec"
sha256 cellar: :any_skip_relocation, monterey: "b2ea7549fb70b7a69438a814c84bd9ef637b33ee93ec135842e82b787aa1db34"
end

depends_on "xz" unless Hardware::CPU.arm?
depends_on "zstd" unless Hardware::CPU.arm?

keg_only <<~KEG_ONLY_EOS
it may interfere with another version of arm-gcc-bin.
Expand All @@ -38,6 +32,6 @@ def install
end

test do
assert_match "Arm GNU Toolchain #{version}", `#{opt_prefix}/bin/arm-none-eabi-gcc --version`
assert_match "Arm GNU Toolchain #{version}".strip.downcase, `#{opt_prefix}/bin/arm-none-eabi-gcc --version`.strip.downcase
end
end