Skip to content

Commit cad13f4

Browse files
boybookwilliamyang98
authored andcommitted
[CI] Add support for MacOS arm (#5)
Add arm-macos github runner https://github.com/boybook #5
1 parent e519183 commit cad13f4

File tree

2 files changed

+70
-0
lines changed

2 files changed

+70
-0
lines changed

.github/workflows/arm-macos.yml

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
name: arm-macos
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches: [ "master", "dev" ]
7+
8+
env:
9+
BUILD_TYPE: Release
10+
BUILD_DIR: build
11+
PACKAGE_DIR: build-out
12+
OSX_TARGET: "12.0"
13+
14+
jobs:
15+
skip_check:
16+
continue-on-error: false
17+
runs-on: ubuntu-22.04
18+
outputs:
19+
should_skip: ${{ steps.skip_check.outputs.should_skip }}
20+
steps:
21+
- id: skip_check
22+
uses: fkirc/skip-duplicate-actions@v5
23+
with:
24+
concurrent_skipping: 'same_content'
25+
cancel_others: 'true'
26+
skip_after_successful_duplicate: 'true'
27+
paths_ignore: '["**/README.md", "**/docs/**", "**/LICENSE.txt", "vcpkg.json", "toolchains/windows/*", "toolchains/ubuntu/*"]'
28+
do_not_skip: '["workflow_dispatch", "schedule"]'
29+
30+
build:
31+
needs: skip_check
32+
if: needs.skip_check.outputs.should_skip != 'true'
33+
34+
runs-on: macos-14
35+
36+
steps:
37+
- uses: actions/checkout@v3
38+
with:
39+
submodules: recursive
40+
41+
- name: Update brew
42+
run: brew update
43+
44+
- name: Install dependencies
45+
run: brew bundle install --file=./toolchains/macos/Brewfile
46+
47+
- name: Install python mako
48+
run: pip3 install mako --break-system-packages
49+
50+
- name: Install volk
51+
run: git clone --recursive https://github.com/gnuradio/volk && cd volk && mkdir build && cd build && cmake -DCMAKE_OSX_DEPLOYMENT_TARGET=10.15 -DCMAKE_BUILD_TYPE=Release .. && make -j3 && sudo make install && cd ../../
52+
53+
- name: Configure CMake
54+
run: cmake . -B ${{github.workspace}}/${{env.BUILD_DIR}} --preset clang -DCMAKE_OSX_DEPLOYMENT_TARGET=${{env.OSX_TARGET}} -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
55+
56+
- name: Build
57+
run: cmake --build ${{github.workspace}}/${{env.BUILD_DIR}} --config ${{env.BUILD_TYPE}} --target dab_plugin
58+
59+
- name: Create package
60+
run: |
61+
mkdir -p ${{env.PACKAGE_DIR}}
62+
cp ${{env.BUILD_DIR}}/src/*.dylib ${{env.PACKAGE_DIR}}/
63+
cp README.md ${{env.PACKAGE_DIR}}/
64+
65+
- name: Upload files (Release)
66+
uses: actions/upload-artifact@v3
67+
with:
68+
name: sdrpp_dab_radio_plugin_macos_arm
69+
path: ${{github.workspace}}/${{env.PACKAGE_DIR}}

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
[![x86-windows](https://github.com/williamyang98/SDRPlusPlus-DAB-Radio-Plugin/actions/workflows/x86-windows.yml/badge.svg)](https://github.com/williamyang98/SDRPlusPlus-DAB-Radio-Plugin/actions/workflows/x86-windows.yml)
33
[![x86-ubuntu](https://github.com/williamyang98/SDRPlusPlus-DAB-Radio-Plugin/actions/workflows/x86-ubuntu.yml/badge.svg)](https://github.com/williamyang98/SDRPlusPlus-DAB-Radio-Plugin/actions/workflows/x86-ubuntu.yml)
44
[![x86-macos](https://github.com/williamyang98/SDRPlusPlus-DAB-Radio-Plugin/actions/workflows/x86-macos.yml/badge.svg)](https://github.com/williamyang98/SDRPlusPlus-DAB-Radio-Plugin/actions/workflows/x86-macos.yml)
5+
[![arm-macos](https://github.com/williamyang98/SDRPlusPlus-DAB-Radio-Plugin/actions/workflows/arm-macos.yml/badge.svg)](https://github.com/williamyang98/SDRPlusPlus-DAB-Radio-Plugin/actions/workflows/arm-macos.yml)
56

67
SDR++ DAB radio plugin.
78

0 commit comments

Comments
 (0)