Skip to content
Merged
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
35 changes: 34 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,40 @@ jobs:
name: SerialPortConnector-Linux
path: SerialPortConnector*.AppImage

build-macos:
runs-on: macos-latest # ARM64 runner, builds universal binary

steps:
- uses: actions/checkout@v4

- name: Install Qt
uses: jurplel/install-qt-action@v4
with:
version: '5.15.2'
host: 'mac'
target: 'desktop'
cache: true

- name: Build
run: |
mkdir build && cd build
qmake ../SerialPortConnector.pro CONFIG+=release
make -j$(sysctl -n hw.ncpu)

- name: Deploy
run: |
cd build
macdeployqt SerialPortConnector.app -dmg
mv SerialPortConnector.dmg ../SerialPortConnector-macOS.dmg

- name: Upload macOS artifact
uses: actions/upload-artifact@v4
with:
name: SerialPortConnector-macOS
path: SerialPortConnector-macOS.dmg

create-release:
needs: [build-windows, build-linux]
needs: [build-windows, build-linux, build-macos]
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')

Expand All @@ -181,5 +213,6 @@ jobs:
files: |
SerialPortConnector-Windows.zip
SerialPortConnector-Linux/*.AppImage
SerialPortConnector-macOS/*.dmg
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}