From fd55b530d7ce9c3c6f2eb3bf792eefad47b0823c Mon Sep 17 00:00:00 2001 From: Lars Bilke <lars.bilke@ufz.de> Date: Fri, 5 May 2017 10:23:36 +0200 Subject: [PATCH] [CMake,DE] Corrected dependencies. --- Applications/DataExplorer/Base/CMakeLists.txt | 4 +--- Applications/DataExplorer/DataExplorer.cmake | 20 ++++++++++--------- .../DataExplorer/DataView/CMakeLists.txt | 12 ++++------- .../DataView/DiagramView/CMakeLists.txt | 6 ++---- .../DataView/StratView/CMakeLists.txt | 4 +++- .../DataExplorer/VtkVis/CMakeLists.txt | 3 ++- 6 files changed, 23 insertions(+), 26 deletions(-) diff --git a/Applications/DataExplorer/Base/CMakeLists.txt b/Applications/DataExplorer/Base/CMakeLists.txt index 2e251d09b10..e2529a875b2 100644 --- a/Applications/DataExplorer/Base/CMakeLists.txt +++ b/Applications/DataExplorer/Base/CMakeLists.txt @@ -36,9 +36,7 @@ add_library(QtBase ${HEADERS} ) -target_link_libraries(QtBase - Qt5::Widgets - GeoLib) +target_link_libraries(QtBase Qt5::Widgets) set_property(TARGET QtBase PROPERTY FOLDER "DataExplorer") diff --git a/Applications/DataExplorer/DataExplorer.cmake b/Applications/DataExplorer/DataExplorer.cmake index 813750fed96..7d2b58a4f35 100644 --- a/Applications/DataExplorer/DataExplorer.cmake +++ b/Applications/DataExplorer/DataExplorer.cmake @@ -54,21 +54,25 @@ add_executable(DataExplorer ) target_link_libraries(DataExplorer - Qt5::Core - Qt5::Gui - Qt5::Widgets - Qt5::Xml - Qt5::Network + BaseLib + GeoLib + MeshGeoToolsLib + MeshLib ApplicationsLib ApplicationsFileIO DataHolderLib + OGSFileConverterLib + QtBase QtDataView QtDiagramView - QtStratView VtkVis Threads::Threads - OGSFileConverterLib vtkGUISupportQt + Qt5::Core + Qt5::Gui + Qt5::Widgets + Qt5::Xml + Qt5::Network logog ) @@ -94,8 +98,6 @@ if(GEOTIFF_FOUND) target_link_libraries(DataExplorer ${GEOTIFF_LIBRARIES} ) endif() -add_dependencies (DataExplorer VtkVis) - if(MSVC) # Set linker flags set(CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} /NODEFAULTLIB:MSVCRT /IGNORE:4099") diff --git a/Applications/DataExplorer/DataView/CMakeLists.txt b/Applications/DataExplorer/DataView/CMakeLists.txt index 66b214180b1..9ec327f0e54 100644 --- a/Applications/DataExplorer/DataView/CMakeLists.txt +++ b/Applications/DataExplorer/DataView/CMakeLists.txt @@ -134,19 +134,15 @@ add_library(QtDataView ) target_link_libraries(QtDataView - Qt5::Core - Qt5::Gui - ApplicationsFileIO - DataHolderLib - QtBase - QtDiagramView - QtStratView + PUBLIC GeoLib MeshGeoToolsLib MeshLib QtBase VtkVis + PRIVATE BaseLib MathLib ApplicationsFileIO QtDiagramView QtStratView + DataHolderLib logog Qt5::Core Qt5::Gui ) ADD_VTK_DEPENDENCY(QtDataView) if(GEOTIFF_FOUND) - target_link_libraries( QtDataView ${GEOTIFF_LIBRARIES} ) + target_link_libraries(QtDataView PRIVATE ${GEOTIFF_LIBRARIES}) endif () # GEOTIFF_FOUND set_property(TARGET QtDataView PROPERTY FOLDER "DataExplorer") diff --git a/Applications/DataExplorer/DataView/DiagramView/CMakeLists.txt b/Applications/DataExplorer/DataView/DiagramView/CMakeLists.txt index 9157b88ec85..c5a43f148db 100644 --- a/Applications/DataExplorer/DataView/DiagramView/CMakeLists.txt +++ b/Applications/DataExplorer/DataView/DiagramView/CMakeLists.txt @@ -41,10 +41,8 @@ add_library(QtDiagramView ) target_link_libraries(QtDiagramView - Qt5::Gui - GeoLib - QtBase - ) + PRIVATE BaseLib GeoLib QtBase DataHolderLib Qt5::Gui logog +) set_property(TARGET QtDiagramView PROPERTY FOLDER "DataExplorer") diff --git a/Applications/DataExplorer/DataView/StratView/CMakeLists.txt b/Applications/DataExplorer/DataView/StratView/CMakeLists.txt index e93feced53f..625ec00ee50 100644 --- a/Applications/DataExplorer/DataView/StratView/CMakeLists.txt +++ b/Applications/DataExplorer/DataView/StratView/CMakeLists.txt @@ -32,7 +32,9 @@ add_library(QtStratView ${UIS} ) -target_link_libraries(QtStratView Qt5::Gui QtBase) +target_link_libraries(QtStratView + PRIVATE BaseLib GeoLib DataHolderLib QtBase Qt5::Gui +) set_property(TARGET QtStratView PROPERTY FOLDER "DataExplorer") diff --git a/Applications/DataExplorer/VtkVis/CMakeLists.txt b/Applications/DataExplorer/VtkVis/CMakeLists.txt index 94fc77c16e0..b5d1f087d61 100644 --- a/Applications/DataExplorer/VtkVis/CMakeLists.txt +++ b/Applications/DataExplorer/VtkVis/CMakeLists.txt @@ -136,7 +136,8 @@ if(GEOTIFF_FOUND) endif() # GEOTIFF_FOUND target_link_libraries(VtkVis - PUBLIC Qt5::Gui QtDataView + PUBLIC BaseLib GeoLib MeshLib DataHolderLib QtBase + PRIVATE MathLib ApplicationsFileIO QtDataView Qt5::Gui logog INTERFACE ${VTK_LIBRARIES} ) set_property(TARGET VtkVis PROPERTY FOLDER "DataExplorer") -- GitLab