-
-
Notifications
You must be signed in to change notification settings - Fork 668
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
WIP: ENH: Add macOS ARM GitHub Actions configuration
- Loading branch information
Showing
1 changed file
with
97 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,97 @@ | ||
name: ITK.macOS.Arm64 | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
- 'release*' | ||
paths-ignore: | ||
- '*.md' | ||
- LICENSE | ||
- NOTICE | ||
- Documentation/* | ||
- Utilities/Debugger/* | ||
- Utilities/ITKv5Preparation/* | ||
- Utilities/Maintenance/* | ||
pull_request: | ||
paths-ignore: | ||
- '*.md' | ||
- LICENSE | ||
- NOTICE | ||
- Documentation/* | ||
- Utilities/Debugger/* | ||
- Utilities/ITKv5Preparation/* | ||
- Utilities/Maintenance/* | ||
|
||
env: | ||
ExternalDataVersion: 5.3.0 | ||
|
||
jobs: | ||
macOS: | ||
runs-on: macos-14 | ||
timeout-minutes: 0 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 5 | ||
clean: true | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.11' | ||
|
||
- name: Install dependencies | ||
run: | | ||
set -x | ||
python3 -m pip install ninja | ||
python3 -m pip install --upgrade setuptools | ||
python3 -m pip install scikit-ci-addons | ||
python3 -m pip install lxml | ||
- name: Download dashboard script and testing data | ||
run: | | ||
set -x | ||
git clone -b dashboard --single-branch https://github.com/InsightSoftwareConsortium/ITK.git ITK-dashboard | ||
curl -L https://github.com/InsightSoftwareConsortium/ITK/releases/download/v${{ env.ExternalDataVersion }}/InsightData-${{ env.ExternalDataVersion }}.tar.gz -O | ||
cmake -E tar xfz InsightData-${{ env.ExternalDataVersion }}.tar.gz | ||
cmake -E rename InsightToolkit-${{ env.ExternalDataVersion }}/.ExternalData/MD5 ${{ github.workspace }}/.ExternalData/MD5 | ||
- name: Configure CTest script | ||
run: | | ||
cat > ITK-dashboard/dashboard.cmake << EOF | ||
set(CTEST_BUILD_CONFIGURATION "Release") | ||
set(CTEST_CMAKE_GENERATOR "Ninja") | ||
set(dashboard_cache " | ||
BUILD_SHARED_LIBS:BOOL=ON | ||
BUILD_EXAMPLES:BOOL=ON | ||
ITK_WRAP_PYTHON:BOOL=OFF | ||
") | ||
include(${{ github.workspace }}/ITK-dashboard/azure_dashboard.cmake) | ||
EOF | ||
cat ITK-dashboard/dashboard.cmake | ||
- name: Build and test | ||
run: | | ||
set -x | ||
c++ --version | ||
cmake --version | ||
ctest -S ${{ github.workspace }}/ITK-dashboard/dashboard.cmake -VV -j 4 | ||
env: | ||
CTEST_OUTPUT_ON_FAILURE: 1 | ||
|
||
- name: Format CTest output in JUnit format | ||
if: always() | ||
run: | | ||
ci_addons ctest_junit_formatter ${{ github.workspace }}-build > ${{ github.workspace }}/JUnitTestResults.xml | ||
- name: Publish test results | ||
uses: mikepenz/action-junit-report@v2 | ||
if: always() | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
report_paths: '${{ github.workspace }}/JUnitTestResults.xml' |