Skip to content

Commit 3df26b4

Browse files
committed
Apply Win32 workaronds
1 parent 6760c62 commit 3df26b4

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

.github/workflows/ci.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ jobs:
66
runs-on: windows-latest
77
steps:
88
- uses: actions/checkout@v4
9-
# Also enable GKREGEX, because building with Ninja does not count as MSVC hence it doesn't get enabled by default
10-
- run: cmake -Bbuild -GNinja -DCMAKE_C_COMPILER=clang -DGKREGEX=ON
9+
- run: cmake -Bbuild -GNinja -DCMAKE_C_COMPILER=clang
1110
# -DCMAKE_CXX_COMPILER=clang++
1211
- run: cmake --build build
1312

CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ unset(abs)
99
include(GKlibSystem.cmake)
1010

1111
include_directories(".")
12+
13+
# Don't worry, this will be removed
1214
if(MSVC)
1315
include_directories("win32")
1416
file(GLOB win32_sources RELATIVE "win32" "*.c")

GKlibSystem.cmake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@ option(NO_X86 "enable NO_X86 support" OFF)
1717

1818

1919
# Add compiler flags.
20-
if(MSVC)
20+
if(WIN32)
2121
set(GKlib_COPTS "/Ox")
2222
set(GKlib_COPTIONS "-DWIN32 -DMSC -D_CRT_SECURE_NO_DEPRECATE -DUSE_GKREGEX")
2323
elseif(MINGW)
2424
set(GKlib_COPTS "-DUSE_GKREGEX")
2525
else()
2626
set(GKlib_COPTIONS "-DLINUX -D_FILE_OFFSET_BITS=64")
27-
endif(MSVC)
27+
endif(WIN32)
2828
if(CYGWIN)
2929
set(GKlib_COPTIONS "${GKlib_COPTIONS} -DCYGWIN")
3030
endif(CYGWIN)
@@ -125,7 +125,7 @@ endif(HAVE_GETLINE)
125125

126126

127127
# Custom check for TLS.
128-
if(MSVC)
128+
if(WIN32)
129129
set(GKlib_COPTIONS "${GKlib_COPTIONS} -D__thread=__declspec(thread)")
130130

131131
# This if checks if that value is cached or not.

0 commit comments

Comments
 (0)