aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJay Berkenbilt <ejb@ql.org>2023-05-21 02:50:09 +0200
committerJay Berkenbilt <ejb@ql.org>2023-05-21 03:26:01 +0200
commit2028e35928ee8725128f52cae999ac6829dee2fc (patch)
tree1d296d1be09e427f2bb07d51780057e428843c0e
parent4bc7b6ceba27cd5b1debd469c23824ef534589fa (diff)
downloadqpdf-2028e35928ee8725128f52cae999ac6829dee2fc.tar.zst
Actually run windows builds in Release mode in CI
-rwxr-xr-xbuild-scripts/build-windows2
-rwxr-xr-xcmake-win13
2 files changed, 8 insertions, 7 deletions
diff --git a/build-scripts/build-windows b/build-scripts/build-windows
index e27dddf6..5f56be00 100755
--- a/build-scripts/build-windows
+++ b/build-scripts/build-windows
@@ -30,7 +30,7 @@ unzip doc.zip
unzip qpdf-external-libs-bin.zip
cd build
-../cmake-win $tool ci
+../cmake-win $tool ci $config
cmake --build . --verbose -j$(nproc) "${cmake_xargs[@]}"
ctest --verbose "${ctest_xargs[@]}"
cpack -G NSIS -C $config
diff --git a/cmake-win b/cmake-win
index 2da055c5..f8e9f512 100755
--- a/cmake-win
+++ b/cmake-win
@@ -3,6 +3,7 @@ set -e
whoami=$(basename $0)
tool=$1
mode=$2
+config=${3-RelWithDebInfo}
dir=$(realpath --relative-to . $(dirname $0))
if [ "$dir" = "." ]; then
@@ -12,13 +13,13 @@ fi
declare -a args
case $tool in
msvc)
- args=(-DCMAKE_BUILD_TYPE=RelWithDebInfo)
+ args=(-DCMAKE_BUILD_TYPE=$config)
if cl 2>&1 | grep -q 'for x86'; then
args=("${args[@]}" -A win32)
fi
;;
mingw)
- args=(-G 'MSYS Makefiles' -DCMAKE_BUILD_TYPE=RelWithDebInfo)
+ args=(-G 'MSYS Makefiles' -DCMAKE_BUILD_TYPE=$config)
;;
*)
echo 1>&2 "Usage: $whoami {msvc|mingw}"
@@ -36,9 +37,9 @@ cmake "${args[@]}" $dir
set +x
if [ "$tool" = "msvc" ]; then
echo ""
- echo "*****************************************************************"
- echo "*** Remember to pass --config RelWithDebInfo to cmake --build ***"
- echo "*** and -C RelWithDebInfo to ctest ***"
- echo "*****************************************************************"
+ echo "***"
+ echo "*** Remember to pass --config $config to cmake --build"
+ echo "*** and -C $config to ctest"
+ echo "***"
echo ""
fi