Only use ThinLTO for shared libraries.
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Deukhoofd 2020-09-12 16:59:07 +02:00
parent 4f8ca03a39
commit 38f36699ac
Signed by: Deukhoofd
GPG Key ID: F63E044490819F6F
1 changed files with 4 additions and 4 deletions

View File

@ -16,12 +16,12 @@ option(PRETTYTRACES "Whether full stacktraces should be included. Note that this
set(LIBTYPE STATIC)
if (SHARED)
set(LIBTYPE SHARED)
endif (SHARED)
if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
add_compile_options(-flto=thin)
add_link_options(-flto=thin)
endif ()
endif ()
endif (SHARED)
if (NOT WINDOWS)
# Include debug symbols in all linux builds