Skip to content
Snippets Groups Projects
Commit 6a1ea1f7 authored by Pospelov, Gennady's avatar Pospelov, Gennady
Browse files

Modernize CMake machinery regarding qcustomplot

parent f4894192
No related branches found
No related tags found
No related merge requests found
......@@ -94,11 +94,9 @@ set(${library_name}_LIBRARY ${library_name} PARENT_SCOPE)
# --- dependencies ---------
target_include_directories(${library_name} PUBLIC
${CMAKE_SOURCE_DIR}/ThirdParty/GUI # for qt-manhattan-style
${qcustomplot_INCLUDE_DIRS}
${CMAKE_SOURCE_DIR})
target_link_libraries(${library_name}
${ManhattanStyle_LIBRARY}
${qcustomplot_LIBRARY}
${BornAgainCore_LIBRARY}
${ba3d_LIBRARY}
Qt5::Widgets
......@@ -107,6 +105,7 @@ target_link_libraries(${library_name}
Qt5::Designer
Qt5::PrintSupport
Qt5::Network
qcustomplot
)
# --- Installation ---------
......
......@@ -3,22 +3,7 @@
############################################################################
set(library_name qcustomplot)
set(source_files qcustomplot.h qcustomplot.cpp)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC ON)
add_library(
${library_name}
STATIC
${source_files} ${mocfiles}
)
set(${library_name}_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE)
set(${library_name}_LIBRARY ${library_name} PARENT_SCOPE)
target_link_libraries(${library_name} ${Qt5Widgets_LIBRARIES})
target_link_libraries(${library_name}
Qt5::Widgets
Qt5::PrintSupport
)
add_library(${library_name} STATIC qcustomplot.h qcustomplot.cpp)
target_link_libraries(${library_name} PUBLIC Qt5::Widgets Qt5::PrintSupport)
target_include_directories(${library_name} PUBLIC ${CMAKE_CURRENT_LIST_DIR})
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