Skip to content
Snippets Groups Projects
Verified Commit f359e1e7 authored by Lars Bilke's avatar Lars Bilke
Browse files

[ci] Added mac build.

parent cb3b7f76
No related branches found
No related tags found
No related merge requests found
......@@ -11,13 +11,16 @@ variables:
PRECOMMIT_IMAGE: $CI_REGISTRY_IMAGE/pre-commit
include:
# extends
- local: '/scripts/ci/extends/container-maker-setup.yml'
- local: '/scripts/ci/extends/vs2019-environment.yml'
- local: '/scripts/ci/extends/test-artifacts.yml'
# jobs
- local: '/scripts/ci/jobs/pre-commit.yml'
- local: '/scripts/ci/jobs/build_image.yml'
- local: '/scripts/ci/jobs/build.yml'
- local: '/scripts/ci/jobs/build-win.yml'
- local: '/scripts/ci/jobs/build-mac.yml'
- local: '/scripts/ci/jobs/checks.yml'
- local: '/scripts/ci/jobs/container.yml'
- local: '/scripts/ci/jobs/gui.yml'
build mac:
stage: test
tags:
- mac
variables:
BUILD_DIR: "build-mac"
CCACHE_DIR: "$CI_PROJECT_DIR/.ccache"
cache:
paths:
- .ccache
extends: .test-artifacts
before_script:
- mkdir -p $BUILD_DIR
- cd $BUILD_DIR
script:
- cmake .. -G Ninja -DCMAKE_BUILD_TYPE=Release -DOGS_BUILD_PROCESSES=GroundwaterFlow
- cmake --build . > >(tee make.output)
- cmake --build . --target tests
- cmake --build . --target ctest
- cp Testing/**/Test.xml Tests/ctest.xml
......@@ -6,12 +6,15 @@ compiler warnings:
dependencies:
- build
- build win
- build mac
script:
- exit_code=0
- cd build
- "if [[ $(cat make.output | grep warning -i) ]]; then echo 'There were compiler warnings:'; cat make.output | grep warning -i; exit_code=1; fi"
- "if [[ $(cat make.output | grep warning -i) ]]; then echo 'There were GCC compiler warnings:'; cat make.output | grep warning -i; exit_code=1; fi"
- cd ../build-win
- "if [[ $(cat make.output | grep ': warning' -i) ]]; then echo 'There were compiler warnings:'; cat make.output | grep ': warning' -i; exit_code=1; fi"
- "if [[ $(cat make.output | grep ': warning' -i) ]]; then echo 'There were MSVC compiler warnings:'; cat make.output | grep ': warning' -i; exit_code=1; fi"
- cd ../build-mac
- "if [[ $(cat make.output | grep warning -i) ]]; then echo 'There were Clang (macOS) compiler warnings:'; cat make.output | grep warning -i; exit_code=1; fi"
- exit $exit_code
......@@ -23,16 +26,16 @@ ctest results:
- singularity
dependencies:
- build
- "build win"
- build win
- build mac
script:
- singularity run docker://$XUNIT_TO_JUNIT_IMAGE -s:./build/Tests/ctest.xml > build/ctest-junit.xml
- singularity run docker://$XUNIT_TO_JUNIT_IMAGE -s:./build-win/Tests/ctest.xml > build-win/ctest-junit.xml
- singularity run docker://$XUNIT_TO_JUNIT_IMAGE -s:./build-win/Tests/ctest.xml > build-mac/ctest-junit.xml
artifacts:
paths:
- build/ctest-junit.xml
- build-win/ctest-junit.xml
expire_in: 1 week
reports:
junit:
- build/ctest-junit.xml
- build-win/ctest-junit.xml
- build-mac/ctest-junit.xml
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment