Skip to content

Commit e615c33

Browse files
devnexenmjp41
authored andcommitted
Haiku debug build, rdynamic flag unsupported.
1 parent d3ecd66 commit e615c33

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

CMakeLists.txt

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -172,13 +172,14 @@ if(NOT DEFINED SNMALLOC_ONLY_HEADER_LIBRARY)
172172
set(CMAKE_EXE_LINKER_FLAGS_RELEASE "${CMAKE_EXE_LINKER_FLAGS_RELEASE} /DEBUG")
173173
else()
174174
add_compile_options(-fno-exceptions -fno-rtti -g -fomit-frame-pointer)
175-
# Static TLS model unsupported on Haiku
175+
# Static TLS model is unsupported on Haiku.
176+
# All symbols are always dynamic on haiku and -rdynamic is redundant (and unsupported).
176177
if (NOT CMAKE_SYSTEM_NAME MATCHES "Haiku")
177178
add_compile_options(-ftls-model=initial-exec)
178-
endif()
179-
if(SNMALLOC_CI_BUILD OR (${CMAKE_BUILD_TYPE} MATCHES "Debug"))
180-
# Get better stack traces in CI and Debug.
181-
target_link_libraries(snmalloc_lib INTERFACE "-rdynamic")
179+
if(SNMALLOC_CI_BUILD OR (${CMAKE_BUILD_TYPE} MATCHES "Debug"))
180+
# Get better stack traces in CI and Debug.
181+
target_link_libraries(snmalloc_lib INTERFACE "-rdynamic")
182+
endif()
182183
endif()
183184

184185
if(SNMALLOC_OPTIMISE_FOR_CURRENT_MACHINE)

0 commit comments

Comments
 (0)