mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-19 14:25:27 +00:00
CICD: Move MacOS / iOS Build Qt Resources into GitHub.
Move the Qt resources required for the build for MacOS and iOS into GitHub, into their own repositories. This removes the need to publish them on an external file server and download them from there for every build. It will also make it easier for contributors to update these resources if needed. Signed-off-by: Michael Keller <github@ike.ch>
This commit is contained in:
parent
f4e61aa5dc
commit
331d6712c6
3 changed files with 36 additions and 22 deletions
6
.github/workflows/android.yml
vendored
6
.github/workflows/android.yml
vendored
|
@ -11,13 +11,13 @@ on:
|
|||
branches:
|
||||
- master
|
||||
|
||||
env:
|
||||
BUILD_ROOT: ${{ github.workspace }}/..
|
||||
KEYSTORE_FILE: ${{ github.workspace }}/../subsurface.keystore
|
||||
|
||||
jobs:
|
||||
buildAndroid:
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
BUILD_ROOT: ${{ github.workspace }}/..
|
||||
KEYSTORE_FILE: ${{ github.workspace }}/../subsurface.keystore
|
||||
container:
|
||||
image: docker://subsurface/android-build:5.15.2
|
||||
|
||||
|
|
35
.github/workflows/ios.yml
vendored
35
.github/workflows/ios.yml
vendored
|
@ -12,7 +12,7 @@ on:
|
|||
- master
|
||||
|
||||
jobs:
|
||||
iOSBuild:
|
||||
build:
|
||||
runs-on: macOS-11
|
||||
steps:
|
||||
- name: switch to Xcode 11
|
||||
|
@ -24,25 +24,34 @@ jobs:
|
|||
- name: setup Homebrew
|
||||
run: brew install autoconf automake libtool pkg-config
|
||||
|
||||
- name: set our Qt build
|
||||
run: |
|
||||
env
|
||||
curl -L --output Qt-5.14.1-ios.tar.xz https://f002.backblazeb2.com/file/Subsurface-Travis/Qt-5.14.1-ios.tar.xz
|
||||
mkdir -p $HOME/Qt
|
||||
xzcat Qt-5.14.1-ios.tar.xz | tar -x -C $HOME/Qt -f -
|
||||
- name: checkout Qt resources
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
repository: subsurface/qt-ios
|
||||
ref: main
|
||||
path: qt-ios
|
||||
|
||||
- name: store dummy version and build number for test build
|
||||
id: version_number
|
||||
run: |
|
||||
echo "100" > latest-subsurface-buildnumber
|
||||
echo "CICD-test-build" > latest-subsurface-buildnumber-extension
|
||||
version=$(scripts/get-version)
|
||||
echo "version=$version" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: build Subsurface-mobile for iOS
|
||||
env:
|
||||
SUBSURFACE_REPO_PATH: ${{ github.workspace }}
|
||||
run: |
|
||||
cd ${SUBSURFACE_REPO_PATH}/..
|
||||
git config --global --add safe.directory ${SUBSURFACE_REPO_PATH}
|
||||
git config --global --add safe.directory ${SUBSURFACE_REPO_PATH}/libdivecomputer
|
||||
ln -s $HOME/Qt Qt
|
||||
cd ${{ github.workspace }}/..
|
||||
git config --global --add safe.directory $GITHUB_WORKSPACE
|
||||
git config --global --add safe.directory $GITHUB_WORKSPACE/libdivecomputer
|
||||
export IOS_QT=$GITHUB_WORKSPACE/qt-ios
|
||||
echo "build for simulator"
|
||||
bash -x $GITHUB_WORKSPACE/packaging/ios/build.sh -simulator
|
||||
# We need this in order to be able to access the file and publish it
|
||||
mv build-Subsurface-mobile-Qt_5_14_1_for_iOS-Release/Release-iphonesimulator/Subsurface-mobile.app ${{ github.workspace }}/Subsurface-mobile-${{ steps.version_number.outputs.version }}.app
|
||||
|
||||
- name: publish artifacts
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: Subsurface-iOS-${{ steps.version_number.outputs.version }}
|
||||
path: Subsurface-mobile-*.app
|
||||
|
|
17
.github/workflows/mac.yml
vendored
17
.github/workflows/mac.yml
vendored
|
@ -11,12 +11,13 @@ on:
|
|||
branches:
|
||||
- master
|
||||
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: macOS-11
|
||||
steps:
|
||||
- name: checkout sources
|
||||
uses: actions/checkout@v1
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: atomically create or retrieve the build number and assemble release notes
|
||||
id: version_number
|
||||
|
@ -37,15 +38,19 @@ jobs:
|
|||
|
||||
- name: setup Homebrew
|
||||
run: brew install hidapi libxslt libjpg libmtp create-dmg confuse
|
||||
- name: set our Qt build
|
||||
run: |
|
||||
curl -O https://f002.backblazeb2.com/file/Subsurface-Travis/Qt5.15.13-mac.tar.xz
|
||||
tar -xJf Qt*-mac.tar.xz
|
||||
|
||||
- name: checkout Qt resources
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
repository: subsurface/qt-mac
|
||||
ref: main
|
||||
path: qt-mac
|
||||
|
||||
- name: build Subsurface
|
||||
id: build
|
||||
run: |
|
||||
cd ${GITHUB_WORKSPACE}/..
|
||||
export QT_ROOT=${GITHUB_WORKSPACE}/Qt5.15.13
|
||||
export QT_ROOT=${GITHUB_WORKSPACE}/qt-mac/Qt5.15.13
|
||||
export QT_QPA_PLATFORM_PLUGIN_PATH=$QT_ROOT/plugins
|
||||
export PATH=$QT_ROOT/bin:$PATH
|
||||
export CMAKE_PREFIX_PATH=$QT_ROOT/lib/cmake
|
||||
|
|
Loading…
Add table
Reference in a new issue