mirror of
https://github.com/OpenMW/openmw.git
synced 2025-06-26 17:41:33 +00:00
[CI] Overhaul mac CI flow
This commit is contained in:
parent
12f3596220
commit
faa9af4428
9 changed files with 49 additions and 24 deletions
8
.github/workflows/push.yml
vendored
8
.github/workflows/push.yml
vendored
|
@ -73,7 +73,7 @@ jobs:
|
|||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install Building Dependencies
|
||||
run: CI/before_install.osx.sh
|
||||
run: CI/before_install.macos.sh
|
||||
|
||||
- name: Prime ccache
|
||||
uses: hendrikmuhs/ccache-action@v1
|
||||
|
@ -82,11 +82,9 @@ jobs:
|
|||
max-size: 1000M
|
||||
|
||||
- name: Configure
|
||||
run: CI/before_script.osx.sh
|
||||
run: CI/before_script.macos.sh
|
||||
- name: Build
|
||||
run: |
|
||||
cd build
|
||||
make -j $(sysctl -n hw.logicalcpu) package
|
||||
run: CI/macos/build.sh
|
||||
|
||||
Output-Envs:
|
||||
name: Read .env file and expose it as output
|
||||
|
|
|
@ -507,14 +507,11 @@ Ubuntu_GCC_integration_tests_asan:
|
|||
paths:
|
||||
- ccache/
|
||||
script:
|
||||
- CI/before_install.osx.sh
|
||||
- export CCACHE_BASEDIR="$(pwd)"
|
||||
- export CCACHE_DIR="$(pwd)/ccache"
|
||||
- mkdir -pv "${CCACHE_DIR}"
|
||||
- ccache -z -M "${CCACHE_SIZE}"
|
||||
- CI/before_script.osx.sh
|
||||
- cd build; make -j $(sysctl -n hw.logicalcpu) package
|
||||
- for dmg in *.dmg; do mv "$dmg" "${dmg%.dmg}_${CI_COMMIT_REF_NAME##*/}.dmg"; done
|
||||
- CI/before_install.macos.sh
|
||||
- CI/macos/ccache_prep.sh
|
||||
- CI/before_script.macos.sh
|
||||
- CI/macos/build.sh
|
||||
- for dmg in *.dmg; do mv "$dmg" "${dmg%.dmg}_${CI_COMMIT_REF_NAME##*/}_${DMG_IDENTIFIER}.dmg"; done
|
||||
- |
|
||||
if [[ -n "${AWS_ACCESS_KEY_ID}" ]]; then
|
||||
echo "[default]" > ~/.s3cfg
|
||||
|
@ -529,21 +526,22 @@ Ubuntu_GCC_integration_tests_asan:
|
|||
s3cmd put "${dmg}" s3://openmw-artifacts/${artifactDirectory}
|
||||
done
|
||||
fi
|
||||
- ccache -s
|
||||
- CI/macos/ccache_save.sh
|
||||
artifacts:
|
||||
paths:
|
||||
- build/OpenMW-*.dmg
|
||||
|
||||
macOS14_Xcode15_x86-64:
|
||||
macOS14_Xcode15_amd64:
|
||||
extends: .MacOS
|
||||
image: macos-14-xcode-15
|
||||
tags:
|
||||
- saas-macos-medium-m1
|
||||
cache:
|
||||
key: macOS14_Xcode15_x86-64.v1
|
||||
key: macOS14_Xcode15_amd64.v1
|
||||
variables:
|
||||
CCACHE_SIZE: 3G
|
||||
MACOS_X86_64: true
|
||||
DMG_IDENTIFIER: amd64
|
||||
MACOS_AMD64: true
|
||||
|
||||
macOS14_Xcode15_arm64:
|
||||
extends: .MacOS
|
||||
|
@ -553,6 +551,7 @@ macOS14_Xcode15_arm64:
|
|||
cache:
|
||||
key: macOS14_Xcode15_arm64.v1
|
||||
variables:
|
||||
DMG_IDENTIFIER: arm64
|
||||
CCACHE_SIZE: 3G
|
||||
|
||||
.Compress_And_Upload_Symbols_Base:
|
||||
|
@ -979,7 +978,7 @@ Windows_MSBuild_CacheInit:
|
|||
- flatpak build-bundle ./repo openmw.flatpak org.openmw.OpenMW.devel
|
||||
cache:
|
||||
key: flatpak
|
||||
paths:
|
||||
paths:
|
||||
- ".flatpak-builder"
|
||||
artifacts:
|
||||
untracked: false
|
||||
|
|
|
@ -4,8 +4,8 @@ export HOMEBREW_NO_EMOJI=1
|
|||
export HOMEBREW_NO_INSTALL_CLEANUP=1
|
||||
export HOMEBREW_AUTOREMOVE=1
|
||||
|
||||
if [[ "${MACOS_X86_64}" ]]; then
|
||||
./CI/macos/before_install.x86_64.sh
|
||||
if [[ "${MACOS_AMD64}" ]]; then
|
||||
./CI/macos/before_install.amd64.sh
|
||||
else
|
||||
./CI/macos/before_install.arm.sh
|
||||
./CI/macos/before_install.arm64.sh
|
||||
fi
|
|
@ -41,14 +41,14 @@ declare -a BUILD_OPTS=(
|
|||
-D BUILD_OPENCS=TRUE
|
||||
-D BUILD_ESMTOOL=TRUE
|
||||
-D BUILD_BSATOOL=TRUE
|
||||
-D BUILD_ESSIMPORTER=TRU
|
||||
-D BUILD_ESSIMPORTER=TRUE
|
||||
-D BUILD_NIFTEST=TRUE
|
||||
-D BUILD_NAVMESHTOOL=TRUE
|
||||
-D BUILD_BULLETOBJECTTOOL=TRUE
|
||||
-G"Unix Makefiles"
|
||||
)
|
||||
|
||||
if [[ "${MACOS_X86_64}" ]]; then
|
||||
if [[ "${MACOS_AMD64}" ]]; then
|
||||
CMAKE_CONF_OPTS+=(
|
||||
-D CMAKE_OSX_ARCHITECTURES="x86_64"
|
||||
)
|
||||
|
@ -64,7 +64,7 @@ else
|
|||
)
|
||||
fi
|
||||
|
||||
if [[ "${MACOS_X86_64}" ]]; then
|
||||
if [[ "${MACOS_AMD64}" ]]; then
|
||||
arch -x86_64 cmake \
|
||||
"${CMAKE_CONF_OPTS[@]}" \
|
||||
"${BUILD_OPTS[@]}" \
|
9
CI/macos/build.sh
Executable file
9
CI/macos/build.sh
Executable file
|
@ -0,0 +1,9 @@
|
|||
#!/bin/sh -ex
|
||||
|
||||
cd build
|
||||
|
||||
if [[ "${MACOS_AMD64}" ]]; then
|
||||
arch -x86_64 make -j $(sysctl -n hw.logicalcpu) package
|
||||
else
|
||||
make -j $(sysctl -n hw.logicalcpu) package
|
||||
fi
|
12
CI/macos/ccache_prep.sh
Executable file
12
CI/macos/ccache_prep.sh
Executable file
|
@ -0,0 +1,12 @@
|
|||
#!/bin/sh -ex
|
||||
|
||||
export CCACHE_BASEDIR="$(pwd)"
|
||||
export CCACHE_DIR="$(pwd)/ccache"
|
||||
mkdir -pv "${CCACHE_DIR}"
|
||||
ccache -z -M "${CCACHE_SIZE}"
|
||||
|
||||
if [[ "${MACOS_AMD64}" ]]; then
|
||||
arch -x86_64 ccache -z -M "${CCACHE_SIZE}"
|
||||
else
|
||||
ccache -z -M "${CCACHE_SIZE}"
|
||||
fi
|
7
CI/macos/ccache_save.sh
Executable file
7
CI/macos/ccache_save.sh
Executable file
|
@ -0,0 +1,7 @@
|
|||
#!/bin/sh -ex
|
||||
|
||||
if [[ "${MACOS_AMD64}" ]]; then
|
||||
arch -x86_64 ccache -s
|
||||
else
|
||||
ccache -s
|
||||
fi
|
Loading…
Reference in a new issue