diff --git a/cmake/DD4hepBuild.cmake b/cmake/DD4hepBuild.cmake index 3876dbb130529c0505cb8e0ca81fa2b6450e54d2..4f24dc07991933ec879366e56e74aba4c4642008 100644 --- a/cmake/DD4hepBuild.cmake +++ b/cmake/DD4hepBuild.cmake @@ -44,6 +44,10 @@ macro(dd4hep_set_compiler_flags) endif() endif() + if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") + set(CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS "${CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS} -undefined dynamic_lookup") + endif() + endmacro(dd4hep_set_compiler_flags) #--------------------------------------------------------------------------------------------------- # dd4hep_debug