diff options
author | TheGreatRambler <31906920+TheGreatRambler@users.noreply.github.com> | 2022-05-10 22:35:00 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-10 22:35:00 -0700 |
commit | e209fcbc3fc66db775ec65d85dbd64a6069c1681 (patch) | |
tree | 309dea1b26a6b055adb5bd551df3d7fb393d5259 /CMakeLists.txt | |
parent | 4a24f6cf2a287f91597378b97bf80cf1e4f9ecb2 (diff) | |
download | binaryen-e209fcbc3fc66db775ec65d85dbd64a6069c1681.tar.gz binaryen-e209fcbc3fc66db775ec65d85dbd64a6069c1681.tar.bz2 binaryen-e209fcbc3fc66db775ec65d85dbd64a6069c1681.zip |
Fix setting of stack size when building with clang for windows (#4654)
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index c7b45da0d..050e0ff43 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -273,7 +273,11 @@ else() if(WIN32) add_compile_flag("-D_GNU_SOURCE") add_compile_flag("-D__STDC_FORMAT_MACROS") - add_link_flag("-Wl,--stack,8388608") + if(CMAKE_CXX_COMPILER_ID MATCHES "Clang") + add_link_flag("-Wl,/stack:8388608") + else() + add_link_flag("-Wl,--stack,8388608") + endif() elseif(NOT EMSCRIPTEN) add_compile_flag("-fPIC") endif() |