Skip to content

Commit

Permalink
Add MacOS on Apple Silicon as a supported platform
Browse files Browse the repository at this point in the history
  • Loading branch information
SeanTAllen committed Jan 30, 2024
1 parent 7116cb4 commit ce66cfe
Show file tree
Hide file tree
Showing 7 changed files with 119 additions and 3 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/nightlies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,48 @@ jobs:
topic: ${{ github.repository }} scheduled job failure
content: ${{ github.server_url}}/${{ github.repository }}/actions/runs/${{ github.run_id }} failed.

arm64_macos:
runs-on: macos-14

name: arm64-apple-darwin
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Restore Libs Cache
id: restore-libs
uses: actions/cache/restore@v3
with:
path: build/libs
key: libs-arm64-macos-14-${{ hashFiles('Makefile', 'CMakeLists.txt', 'libs/CMakeLists.txt') }}
- name: Build Libs
if: steps.restore-libs.outputs.cache-hit != 'true'
run: make libs build_flags=-j8
- name: Save Libs Cache
if: steps.restore-libs.outputs.cache-hit != 'true'
uses: actions/cache/save@v3
with:
path: build/libs
key: libs-arm64-macos-14-${{ hashFiles('Makefile', 'CMakeLists.txt', 'libs/CMakeLists.txt') }}
- name: Install Cloudsmith
run: pip3 install --upgrade cloudsmith-cli
- name: Nightly
run: bash .ci-scripts/arm64-nightly.bash
env:
CLOUDSMITH_API_KEY: ${{ secrets.CLOUDSMITH_API_KEY }}
TRIPLE_VENDOR: apple
TRIPLE_OS: darwin
- name: Send alert on failure
if: ${{ failure() }}
uses: zulip/github-actions-zulip/send-message@b62d5a0e48a4d984ea4fce5dd65ba691963d4db4
with:
api-key: ${{ secrets.ZULIP_SCHEDULED_JOB_FAILURE_API_KEY }}
email: ${{ secrets.ZULIP_SCHEDULED_JOB_FAILURE_EMAIL }}
organization-url: 'https://ponylang.zulipchat.com/'
to: notifications
type: stream
topic: ${{ github.repository }} scheduled job failure
content: ${{ github.server_url}}/${{ github.repository }}/actions/runs/${{ github.run_id }} failed.

x86_64-windows:
runs-on: windows-2022
defaults:
Expand Down
35 changes: 35 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,41 @@ jobs:
- name: Test with Release Runtime
run: make test-ci config=release usedebugger=lldb

arm64-macos:
runs-on: macos-14

name: arm64 Apple Darwin
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Restore Libs Cache
id: restore-libs
uses: actions/cache/restore@v3
with:
path: build/libs
key: libs-arm64-macos-14-${{ hashFiles('Makefile', 'CMakeLists.txt', 'libs/CMakeLists.txt') }}
- name: Build Libs
if: steps.restore-libs.outputs.cache-hit != 'true'
run: make libs build_flags=-j8
- name: Save Libs Cache
if: steps.restore-libs.outputs.cache-hit != 'true'
uses: actions/cache/save@v3
with:
path: build/libs
key: libs-arm64-macos-14-${{ hashFiles('Makefile', 'CMakeLists.txt', 'libs/CMakeLists.txt') }}
- name: Build Debug Runtime
run: |
make configure arch=armv8 config=debug
make build config=debug
- name: Test with Debug Runtime
run: make test-ci config=debug usedebugger=lldb
- name: Build Release Runtime
run: |
make configure arch=armv8 config=release
make build config=release
- name: Test with Release Runtime
run: make test-ci config=release usedebugger=lldb

x86_64-windows:
runs-on: windows-2022
defaults:
Expand Down
34 changes: 34 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,40 @@ jobs:
TRIPLE_VENDOR: apple
TRIPLE_OS: darwin

arm64_macos:
needs:
- pre-artefact-creation

runs-on: macos-14

name: arm64-apple-darwin
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Restore Libs Cache
id: restore-libs
uses: actions/cache/restore@v3
with:
path: build/libs
key: libs-arm64-macos-14-${{ hashFiles('Makefile', 'CMakeLists.txt', 'libs/CMakeLists.txt') }}
- name: Build Libs
if: steps.restore-libs.outputs.cache-hit != 'true'
run: make libs build_flags=-j8
- name: Save Libs Cache
if: steps.restore-libs.outputs.cache-hit != 'true'
uses: actions/cache/save@v3
with:
path: build/libs
key: libs-arm64-macos-14-${{ hashFiles('Makefile', 'CMakeLists.txt', 'libs/CMakeLists.txt') }}
- name: Install Cloudsmith
run: pip3 install --upgrade cloudsmith-cli
- name: Release
run: bash .ci-scripts/arm64-release.bash
env:
CLOUDSMITH_API_KEY: ${{ secrets.CLOUDSMITH_API_KEY }}
TRIPLE_VENDOR: apple
TRIPLE_OS: darwin

x86_64-windows:
needs:
- pre-artefact-creation
Expand Down
5 changes: 5 additions & 0 deletions .release-notes/welcome-back-m1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
## Add support for MacOS on Apple Silicon

Back in August of 2023, we had to drop MacOS on Apple Silicon as a supported platform as we had no Apple Silicon test and build environment. We lost our existing environment when we had to migrate off of CirrusCI.

GitHub recently announced that they now have Apple Silicon MacOS machines so, we are back in business and MacOS on Apple Silicon is once again a supported platform.
2 changes: 1 addition & 1 deletion INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ If you get that error, it means that the Glibc we compiled ponyc with isn't comp

## macOS

Prebuilt macOS packages are available for macOS on Intel via [ponyup](https://github.com/ponylang/ponyup). You can also install nightly builds using ponyup.
Prebuilt macOS packages are available for macOS via [ponyup](https://github.com/ponylang/ponyup). You can also install nightly builds using ponyup.

To install the most recent ponyc on macOS:

Expand Down
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Pony is still pre-1.0 and as such, semi-regularly introduces breaking changes. T
### Operating Systems

* Linux
* macOS (x86 only)
* macOS
* Windows 10

### CPUs
Expand All @@ -28,7 +28,6 @@ Best effort platforms mean that there is support for the platform in the codebas

* DragonFlyBSD (x86 only)
* FreeBSD (x86 only)
* macOS (Apple Silicon only)

## More Information

Expand Down
1 change: 1 addition & 0 deletions RELEASE_PROCESS.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ You can verify that the release artifacts were successfully built and uploaded b

Package names will be:

* ponyc-arm64-apple-darwin.tar.gz
* ponyc-x86-64-apple-darwin.tar.gz
* ponyc-x86-64-pc-windows-msvc.zip
* ponyc-x86-64-unknown-linux-fedora39.tar.gz
Expand Down

0 comments on commit ce66cfe

Please sign in to comment.