Skip to content

Commit

Permalink
cmake: Define STDC_HEADERS for regex in mingw toolchain (#6873)
Browse files Browse the repository at this point in the history
  • Loading branch information
Biswa96 committed Apr 23, 2023
1 parent ed89707 commit 5dc2b7c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CMakeLists.txt
Expand Up @@ -297,6 +297,10 @@ if(WIN32)
# Suppress warnings for regex.c
set_source_files_properties(${REGEX_SOURCES} PROPERTIES COMPILE_FLAGS /w)
endif(MSVC)
if(MINGW)
# mingw provides stdlib.h
add_definitions(-DSTDC_HEADERS=1)
endif(MINGW)
else(WIN32)
set(REGEX_SOURCES "")
endif(WIN32)
Expand Down

0 comments on commit 5dc2b7c

Please sign in to comment.