ci: Add MAGE build for windows.

This commit is contained in:
Pierre-Antoine Rouby committed 2023-07-31 15:16:19 +02:00
1 parent 216bb3dd4c
commit 099ed29d06
2 files changed
+39 -2

No files matched your search

+29 -2
View File
@@ -8,7 +8,7 @@ stages:
# BUILD #
#########
build-mage:
build-mage-linux:
stage: build
tags:
- linux
@@ -29,6 +29,31 @@ build-mage:
- mage/src/build/mage_extraire
- mage/src/build/mailleurPF
build-mage-windows:
stage: build
tags:
- wine
rules:
- if: $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
variables:
GIT_SUBMODULE_STRATEGY: recursive
GIT_SUBMODULE_DEPTH: 1
script:
- cd mage/src/
- sed s/add_compile_definitions(win)/add_compile_definitions(windows)/ CMakeLists.txt > __tmp__
- echo set(CMAKE_Fortran_COMPILER "C:/Program\ Files/gcc/bin/gfortran.exe") > CMakeLists.txt
- echo set(CMAKE_MAKE_PROGRAM "C:/Program Files\ \(x86\)/GnuWin32/bin/make.exe") >> CMakeLists.txt
- type __tmp__ >> CMakeLists.txt
- mkdir build
- cd build
- cmake -G "MinGW Makefiles" ..
- make
artifacts:
paths:
- mage/src/build/mage.exe
- mage/src/build/mage_extraire.exe
- mage/src/build/mailleurPF.exe
build:
stage: build
tags:
@@ -74,7 +99,7 @@ linux-package:
artifacts: true
- job: build
artifacts: true
- job: build-mage
- job: build-mage-linux
artifacts: true
rules:
- if: $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
@@ -95,6 +120,8 @@ windows-package:
artifacts: true
- job: build
artifacts: true
- job: build-mage-windows
artifacts: true
rules:
- if: $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
artifacts: