mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-11 05:25:32 +03:00
Build: Only use -fstack-clash-protection with GCC
This is not yet supported by Clang, so let's disable it for non-GCC compilers for now. (CLion was whining about it.)
This commit is contained in:
parent
99e6c9b23d
commit
87bb00f6ab
Notes:
sideshowbarker
2024-07-18 21:59:28 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/87bb00f6abf
@ -154,9 +154,12 @@ set(CMAKE_CXX_LINK_FLAGS "-Wl,--hash-style=gnu,-z,relro,-z,now")
|
|||||||
set(CMAKE_SKIP_RPATH TRUE)
|
set(CMAKE_SKIP_RPATH TRUE)
|
||||||
|
|
||||||
add_compile_options(-Os -g1 -fno-exceptions -fstack-protector-strong -Wno-address-of-packed-member -Wundef -Wcast-qual -Wwrite-strings -Wimplicit-fallthrough -Wno-nonnull-compare -Wno-deprecated-copy -Wno-expansion-to-defined)
|
add_compile_options(-Os -g1 -fno-exceptions -fstack-protector-strong -Wno-address-of-packed-member -Wundef -Wcast-qual -Wwrite-strings -Wimplicit-fallthrough -Wno-nonnull-compare -Wno-deprecated-copy -Wno-expansion-to-defined)
|
||||||
add_compile_options(-fstack-clash-protection)
|
|
||||||
add_compile_options(-ffile-prefix-map=${CMAKE_SOURCE_DIR}=.)
|
add_compile_options(-ffile-prefix-map=${CMAKE_SOURCE_DIR}=.)
|
||||||
|
|
||||||
|
if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
|
||||||
|
add_compile_options(-fstack-clash-protection)
|
||||||
|
endif()
|
||||||
|
|
||||||
add_compile_definitions(DEBUG SANITIZE_PTRS)
|
add_compile_definitions(DEBUG SANITIZE_PTRS)
|
||||||
set(CMAKE_CXX_FLAGS_STATIC "${CMAKE_CXX_FLAGS} -static")
|
set(CMAKE_CXX_FLAGS_STATIC "${CMAKE_CXX_FLAGS} -static")
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pie -fpic")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pie -fpic")
|
||||||
|
Loading…
Reference in New Issue
Block a user