diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2022-10-30 14:47:16 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2022-10-30 14:47:16 +0100 |
commit | d4d578596a41742b28005f418f37e5a4fe2cd8b3 (patch) | |
tree | 434758782bfbe8d3f2d8dd6bb62b6b3783982f23 /CMakeLists.txt | |
parent | 3c714eeb03ea7832187729657bcf476f20ef0279 (diff) |
enable highentropyva on gnu/llvm
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index c8c084d1..46f9376c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -73,6 +73,12 @@ endfunction() if(WIN32) add_definitions(-D_CRT_SECURE_NO_WARNINGS -DNOMINMAX -DWIN32_LEAN_AND_MEAN -D_HAS_EXCEPTIONS=0) + if(NOT MSVC) + add_link_options(-Wl,--nxcompat -Wl,--dynamicbase) + if(CMAKE_SIZEOF_VOID_P GREATER_EQUAL 8) + add_link_options(-Wl,--high-entropy-va) + endif() + endif() endif() if(MSVC) @@ -94,6 +100,7 @@ else() endif() if(CMAKE_CXX_COMPILER_ID MATCHES "Clang$") + add_compile_options(-Wno-reserved-macro-identifier) endif() |