From 4326ac496f4033db603c624bdd10bb2faed99e91 Mon Sep 17 00:00:00 2001
From: Frank Gaede <frank.gaede@desy.de>
Date: Tue, 10 Sep 2013 11:05:57 +0000
Subject: [PATCH]  - added ${CMAKE_DL_LIBS} for dlopen

---
 DDSense/CMakeLists.txt | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/DDSense/CMakeLists.txt b/DDSense/CMakeLists.txt
index 440a61852..e1c3c0f96 100644
--- a/DDSense/CMakeLists.txt
+++ b/DDSense/CMakeLists.txt
@@ -38,11 +38,11 @@ file(GLOB exsrc example/*.cpp)
 #  list(REMOVE_ITEM sources ${CMAKE_CURRENT_SOURCE_DIR}/src/Geant4XML.cpp)
 #endif()
 add_library(DD4hepSenseExample SHARED ${exsrc} )
-target_link_libraries(DD4hepSenseExample  DD4hepSense ${Geant4_LIBRARIES})
+target_link_libraries(DD4hepSenseExample  DD4hepSense ${Geant4_LIBRARIES} ${CMAKE_DL_LIBS} )
 
 #-----------------------------------------------------------------------------------
 add_executable(ddsense_example example/ddsense_example.cpp )
-target_link_libraries(ddsense_example DD4hepSense)
+target_link_libraries(ddsense_example DD4hepSense ${CMAKE_DL_LIBS} )
 
 
 #--- install target-------------------------------------
-- 
GitLab