summaryrefslogtreecommitdiff
path: root/Tools
diff options
context:
space:
mode:
author0dminnimda <0dminnimda@gmail.com>2022-07-28 08:58:59 +0300
committerGitHub <noreply@github.com>2022-07-28 07:58:59 +0200
commit64701f6e89ab04d2253c3dea38d8ab1cc008e35d (patch)
treeebc152db502098f6fcf0531f83a851a7a878fccc /Tools
parente9d5959e1d760d61462bd24477c5fbb457f4212a (diff)
downloadcython-64701f6e89ab04d2253c3dea38d8ab1cc008e35d.tar.gz
Add GitHub Actions build jobs for Windows (GH-4324)
There are still test failures, but at least it allows us to see the test results in GHA.
Diffstat (limited to 'Tools')
-rw-r--r--Tools/ci-run.sh13
1 files changed, 11 insertions, 2 deletions
diff --git a/Tools/ci-run.sh b/Tools/ci-run.sh
index 4309fd4ad..da6a87c1c 100644
--- a/Tools/ci-run.sh
+++ b/Tools/ci-run.sh
@@ -108,7 +108,16 @@ export PATH="/usr/lib/ccache:$PATH"
# Most modern compilers allow the last conflicting option
# to override the previous ones, so '-O0 -O3' == '-O3'
# This is true for the latest msvc, gcc and clang
-CFLAGS="-O0 -ggdb -Wall -Wextra"
+if [[ $OSTYPE == "msys" ]]; then # for MSVC cl
+ # /wd disables warnings
+ # 4711 warns that function `x` was selected for automatic inline expansion
+ # 4127 warns that a conditional expression is constant, should be fixed here https://github.com/cython/cython/pull/4317
+ # (off by default) 5045 warns that the compiler will insert Spectre mitigations for memory load if the /Qspectre switch is specified
+ # (off by default) 4820 warns about the code in Python\3.9.6\x64\include ...
+ CFLAGS="-Od /Z7 /W4 /wd4711 /wd4127 /wd5045 /wd4820"
+else
+ CFLAGS="-O0 -ggdb -Wall -Wextra"
+fi
if [[ $NO_CYTHON_COMPILE != "1" && $PYTHON_VERSION != "pypy"* ]]; then
@@ -141,7 +150,7 @@ fi
if [[ $TEST_CODE_STYLE == "1" ]]; then
make -C docs html || exit 1
-elif [[ $PYTHON_VERSION != "pypy"* ]]; then
+elif [[ $PYTHON_VERSION != "pypy"* && $OSTYPE != "msys" ]]; then
# Run the debugger tests in python-dbg if available
# (but don't fail, because they currently do fail)
PYTHON_DBG=$(python -c 'import sys; print("%d.%d" % sys.version_info[:2])')