Skip to content
Snippets Groups Projects
Commit ed352487 authored by Ammar Nejati's avatar Ammar Nejati
Browse files

GitLab CI/CD: Modify the build script for Windows

The build script is modified to run on the current Windows build
machines (including the Win10 VM).
parent 8df448b8
No related branches found
No related tags found
1 merge request!341Adapt the GitLab CI/CD for the new MS-Windows VM
Pipeline #45358 passed
...@@ -18,25 +18,20 @@ mac: ...@@ -18,25 +18,20 @@ mac:
- build/*dmg - build/*dmg
expire_in: 10 days expire_in: 10 days
# To test the GitLab process _locally_ on MS-Windows with powershell (pwsh),
# go to the root Git directory, and run:
# C:\GitLab-Runner\gitlab-runner.exe exec shell --shell pwsh --builds-dir <gitlab build-dir> <job-name>
windows: windows:
tags: tags:
- Windows - Windows
stage: build stage: build
variables:
GIT_DEPTH: 1 # shallow cloning
script: script:
- set OPTLIBS=C:\opt\x64 # run local Powershell script
- set CCACHE_DIR=C:\opt\ccache - ./winbuild.ps1
- New-Item -ItemType "directory" -Confirm:$false -Force:$true -Name "build"
- $Env:Path
- cd build
- cmd.exe "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvars64.bat"
- cmake --version
- cmake -G "Visual Studio 16 2019" -A x64 -T host=x64 -DLIB_MAN=OFF -DQTDIR=C:/Qt/5.14.1/msvc2017_64 -DCPACK_IFW_ROOT=C:\Qt\Tools\QtInstallerFramework\3.2 -DCMAKE_INCLUDE_PATH=%OPTLIBS%/include -DCMAKE_LIBRARY_PATH=%OPTLIBS%/lib -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER="cl.exe" -DCMAKE_CXX_COMPILER="cl.exe" -B. ..
- ccache -z
- ccache -p
- cmake --build . --config Release
- Get-Location
- ctest -C Release --output-on-failure
- cpack -C Release --verbose
artifacts: artifacts:
paths: paths:
- build/*.exe - build/*.exe
......
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