mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-21 23:20:20 +00:00
Meta: Disable rpath generation for MacOS
This commit is contained in:
parent
1219c65249
commit
42323d769a
Notes:
sideshowbarker
2024-07-19 00:29:28 +09:00
Author: https://github.com/ADKaster Commit: https://github.com/SerenityOS/serenity/commit/42323d769a5 Pull-request: https://github.com/SerenityOS/serenity/pull/4582 Issue: https://github.com/SerenityOS/serenity/issues/4418 Issue: https://github.com/SerenityOS/serenity/issues/4483 Issue: https://github.com/SerenityOS/serenity/issues/4569
1 changed files with 11 additions and 1 deletions
|
@ -99,12 +99,22 @@ foreach(lang ASM C CXX OBJC OBJCXX)
|
|||
unset(CMAKE_SHARED_MODULE_LOADER_${lang}_FLAG )
|
||||
unset(CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG)
|
||||
unset(CMAKE_${lang}_SYSROOT_FLAG)
|
||||
# MacOS Workaround. Don't generate install_name flag when cross compiling
|
||||
set(CMAKE_${lang}_CREATE_SHARED_LIBRARY
|
||||
"<CMAKE_${lang}_COMPILER> <LANGUAGE_COMPILE_FLAGS> <CMAKE_SHARED_LIBRARY_CREATE_${lang}_FLAGS> <LINK_FLAGS> -o <TARGET> <OBJECTS> <LINK_LIBRARIES>")
|
||||
endforeach()
|
||||
|
||||
set(CMAKE_INSTALL_NAME_TOOL "true")
|
||||
set(CMAKE_INSTALL_NAME_TOOL "")
|
||||
set(CMAKE_SHARED_LIBRARY_SUFFIX ".so")
|
||||
set(CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS "-shared")
|
||||
|
||||
# Note: MacOS has different rpath rules from linux.
|
||||
# We disable it completely for MacOS hosts to avoid having to track down all the individual flags to unset
|
||||
# This will need to be revisited when the Loader supports RPATH/RUN_PATH.
|
||||
if (CMAKE_SYSTEM_NAME MATCHES Darwin)
|
||||
set(CMAKE_SKIP_RPATH TRUE)
|
||||
endif()
|
||||
|
||||
#FIXME: -fstack-protector
|
||||
|
||||
add_compile_options(-Os -g1 -fno-exceptions -fno-rtti -Wno-address-of-packed-member -Wundef -Wcast-qual -Wwrite-strings -Wimplicit-fallthrough -Wno-nonnull-compare -Wno-deprecated-copy -Wno-expansion-to-defined)
|
||||
|
|
Loading…
Reference in a new issue