Skip to content
Snippets Groups Projects
Commit 2bcdc41f authored by Wuttke, Joachim's avatar Wuttke, Joachim
Browse files

Note on static linkage of RootMinimizer

parent 6a79e7a1
No related branches found
No related tags found
No related merge requests found
############################################################################
# CMakeLists.txt file for building libRootMinimizers package
############################################################################
set(library_name RootMinimizers)
# --- source and include files ---------
set(include_dirs
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/base
......@@ -19,7 +15,6 @@ file(GLOB source_files
"base/*.cxx"
)
# --- definitions ---------
add_definitions(-DWARNINGMSG)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DMATH_NO_PLUGIN_MANAGER -DHAS_MINUIT2 -DR__HAS_MATHMORE")
if(NOT WIN32)
......@@ -28,12 +23,16 @@ else()
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4244 /wd4267")
endif()
# --- making library ------------
add_library(${library_name} STATIC ${source_files})
# For the time being, it has to be STATIC
# because we don't have a DLL for the GSL library yet.
# (at least not up to date and from reliable source
# TODO: try https://www.nuget.org/packages/gsl-msvc14-x64)
# The ROOT code in directory mathcore depends on GSL.
set(${library_name}_INCLUDE_DIRS ${include_dirs} CACHE INTERNAL "")
set(${library_name}_LIBRARY ${library_name} CACHE INTERNAL "")
# --- external dependencies ---
target_include_directories(${library_name} PUBLIC ${GSL_INCLUDE_DIR} ${Boost_INCLUDE_DIRS})
target_link_libraries(${library_name} ${GSL_LIBRARIES} ${Boost_LIBRARIES})
target_include_directories(${library_name} PUBLIC ${include_dirs})
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment