Skip to content

Mac deploy

Mac deploy #30

Workflow file for this run

name: Mac deploy
on: [workflow_dispatch]
env:
BUILD_TYPE: Release # Change build type here.
VCPKG_BINARY_SOURCES: "clear;x-gha,readwrite"
VCPKG_ROOT: '${{ github.workspace }}/vcpkg'
jobs:
build:
runs-on: macos-12
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Export GitHub Actions cache environment variables
uses: actions/github-script@v7
with:
script: |
core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || '');
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '');
- name: Prepare dependencies
shell: bash
run: |
./vcpkg/bootstrap-vcpkg.sh -disableMetrics
brew reinstall autoconf
brew install automake autoconf-archive
- name: Install Qt
uses: jurplel/install-qt-action@v4
with:
version: 6.2.4 # Update Qt version here.
aqtversion: '>=0.9.7'
modules: 'qtimageformats'
tools: 'tools_ifw'
add-tools-to-path: 'true'
- name: Build
shell: bash
run: |
cd build
cmake ..
cmake --build . --config $BUILD_TYPE --target Degate
- name: Prepare binaries
shell: bash
run: |
cd build/out/bin/
$QT_ROOT_DIR/bin/macdeployqt ./Degate.app
- name: Upload Degate binaries
uses: actions/upload-artifact@v4
with:
name: Degate_binaries_Mac_x64
path: build/out/bin/
- name: Create Degate installer
shell: bash
# Update the Qt Installer Framework (ifw) version here (by providing the exe download link and changing the exe name/path).
run: |
cp -R build/out/bin/ etc/installer/packages/Degate/data
cd etc/installer
binarycreator --offline-only -c config/config.xml -p packages "mac_deploy_offline/Degate_offline_installer_Mac_x64"
binarycreator --online-only -c config/config.xml -p packages "mac_deploy_online/Degate_online_installer_Mac_x64"
- name: Upload Degate offline installer
uses: actions/upload-artifact@v4
with:
name: Degate_offline_installer_Mac_x64
path: etc/installer/mac_deploy_offline/
- name: Upload Degate online installer
uses: actions/upload-artifact@v4
with:
name: Degate_online_installer_Mac_x64
path: etc/installer/mac_deploy_online/
- name: Create Degate update
shell: bash
run: |
cd etc/installer
repogen -p packages repository
- name: Upload Degate update
uses: actions/upload-artifact@v4
with:
name: Degate_update_Mac_x64
path: etc/installer/repository
- name: Upload vcpkg build logs
if: failure()
uses: actions/upload-artifact@v4
with:
name: 'vcpkg-buildlogs-${{ matrix.triplet }}'
path: ${{ env.VCPKG_ROOT }}/buildtrees/**/*.log