From 4f5851c763e1ed5294601a70b1cb8c1f2341f98f Mon Sep 17 00:00:00 2001 From: Ozaq Date: Tue, 12 Sep 2023 08:27:54 +0200 Subject: [PATCH] Build only once on windows but disabled unit tests --- scripts/ci/build_msvc_python310.cmd | 17 +++++++++-------- scripts/ci/build_msvc_python311.cmd | 17 +++++++++-------- 2 files changed, 18 insertions(+), 16 deletions(-) diff --git a/scripts/ci/build_msvc_python310.cmd b/scripts/ci/build_msvc_python310.cmd index cde8fda2ee..3240c54304 100755 --- a/scripts/ci/build_msvc_python310.cmd +++ b/scripts/ci/build_msvc_python310.cmd @@ -2,12 +2,13 @@ call "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build call C:\Python\Python310\python.exe -m venv venv310 call venv310\Scripts\activate.bat pip install -r requirements.txt -mkdir build -set PYTHONPATH=%cd%\python_modules\jupedsim;%cd%\build\lib\Release -cd build -echo %PYTHONPATH% -cmake .. -DBUILD_TESTS=ON -DCMAKE_UNITY_BUILD=ON -cmake --build . --config Release -cmake --build . --config Release --target unittests -cd .. +:: Build time in CI is currently too long to justify building twice just for unit tests +::mkdir build +::set PYTHONPATH=%cd%\python_modules\jupedsim;%cd%\build\lib\Release +::cd build +::echo %PYTHONPATH% +::cmake .. -DBUILD_TESTS=ON -DCMAKE_UNITY_BUILD=ON +::cmake --build . --config Release +::cmake --build . --config Release --target unittests +::cd .. python -m build -w diff --git a/scripts/ci/build_msvc_python311.cmd b/scripts/ci/build_msvc_python311.cmd index 0326fb3eea..7c6e14066a 100755 --- a/scripts/ci/build_msvc_python311.cmd +++ b/scripts/ci/build_msvc_python311.cmd @@ -2,12 +2,13 @@ call "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build call C:\Python\Python311\python.exe -m venv venv311 call venv311\Scripts\activate.bat pip install -r requirements.txt -mkdir build -set PYTHONPATH=%cd%\python_modules\jupedsim;%cd%\build\lib\Release -cd build -echo %PYTHONPATH% -cmake .. -DBUILD_TESTS=ON -DCMAKE_UNITY_BUILD=ON -cmake --build . --config Release -cmake --build . --config Release --target unittests -cd .. +:: Build time in CI is currently too long to justify building twice just for unit tests +::mkdir build +::set PYTHONPATH=%cd%\python_modules\jupedsim;%cd%\build\lib\Release +::cd build +::echo %PYTHONPATH% +::cmake .. -DBUILD_TESTS=ON -DCMAKE_UNITY_BUILD=ON +::cmake --build . --config Release +::cmake --build . --config Release --target unittests +::cd .. python -m build -w