diff --git a/.gitmodules b/.gitmodules index 7ea8d46e61db1e01bf873a33197a822fdda39e7a..a3e069e3f6400cf56773a54931654bfe414f7350 100644 --- a/.gitmodules +++ b/.gitmodules @@ -4,9 +4,6 @@ [submodule "vtkdiff"] path = ThirdParty/vtkdiff url = https://github.com/ufz/vtkdiff.git -[submodule "ThirdParty/tclap"] - path = ThirdParty/tclap - url = https://github.com/ufz/tclap.git [submodule "ThirdParty/metis"] path = ThirdParty/metis url = https://github.com/scibuilder/metis.git diff --git a/Applications/CLI/CMakeLists.txt b/Applications/CLI/CMakeLists.txt index 494c0255a654092ce708c1253cab6be5c0e72555..a8eb184cc7d70cafbc864d97d0046ac78aaf55c8 100644 --- a/Applications/CLI/CMakeLists.txt +++ b/Applications/CLI/CMakeLists.txt @@ -59,6 +59,7 @@ target_link_libraries(ogs $<$<TARGET_EXISTS:ogs_embedded_python>:ogs_embedded_python> $<$<TARGET_EXISTS:MPI::MPI_CXX>:MPI::MPI_CXX> $<$<TARGET_EXISTS:InSituLib>:InSituLib> + tclap ) target_compile_definitions(ogs diff --git a/Applications/Utils/FileConverter/CMakeLists.txt b/Applications/Utils/FileConverter/CMakeLists.txt index 26e2ccaffe9f6ab4ac89f265ab9bf4d166fc4eeb..a18a9718c2cc7942bc0d371d1a9b772ca0bb132f 100644 --- a/Applications/Utils/FileConverter/CMakeLists.txt +++ b/Applications/Utils/FileConverter/CMakeLists.txt @@ -28,7 +28,7 @@ endif() foreach(TOOL ${TOOLS}) add_executable(${TOOL} ${TOOL}.cpp) - target_link_libraries(${TOOL} ApplicationsFileIO GitInfoLib MeshLib) + target_link_libraries(${TOOL} ApplicationsFileIO GitInfoLib MeshLib tclap) endforeach() set_target_properties(${TOOLS} PROPERTIES FOLDER Utilities) install(TARGETS ${TOOLS} RUNTIME DESTINATION bin COMPONENT Utilities) diff --git a/Applications/Utils/GeoTools/CMakeLists.txt b/Applications/Utils/GeoTools/CMakeLists.txt index d925823fca5f6091198826bd0738fbb9fa31ae6c..efa9100d7efa7678817f98269a2a34d773a32763 100644 --- a/Applications/Utils/GeoTools/CMakeLists.txt +++ b/Applications/Utils/GeoTools/CMakeLists.txt @@ -9,6 +9,7 @@ foreach(TOOL ${TOOLS}) GeoLib GitInfoLib ApplicationsFileIO + tclap Qt5::Core) endforeach() set_target_properties(${TOOLS} PROPERTIES FOLDER Utilities) diff --git a/Applications/Utils/MeshEdit/CMakeLists.txt b/Applications/Utils/MeshEdit/CMakeLists.txt index 7e6ab0849ea71b461a8e322f7a26273e6dce1ee2..45322b4a65c66e49d9c60a8b407586bb615d66ab 100644 --- a/Applications/Utils/MeshEdit/CMakeLists.txt +++ b/Applications/Utils/MeshEdit/CMakeLists.txt @@ -30,14 +30,14 @@ if(OGS_BUILD_GUI) ${PROJECT_SOURCE_DIR}/ThirdParty/paraview/vtkCleanUnstructuredGrid.cpp) target_include_directories(RemoveGhostData PRIVATE ${PROJECT_SOURCE_DIR}/ThirdParty/paraview) - target_link_libraries(RemoveGhostData GitInfoLib MeshLib) + target_link_libraries(RemoveGhostData GitInfoLib MeshLib tclap) set_target_properties(RemoveGhostData PROPERTIES FOLDER Utilities) install(TARGETS RemoveGhostData RUNTIME DESTINATION bin COMPONENT Utilities) endif() foreach(TOOL ${TOOLS}) add_executable(${TOOL} ${TOOL}.cpp) - target_link_libraries(${TOOL} GitInfoLib MeshLib) + target_link_libraries(${TOOL} GitInfoLib MeshLib tclap) endforeach() set_target_properties(${TOOLS} PROPERTIES FOLDER Utilities) install(TARGETS ${TOOLS} RUNTIME DESTINATION bin COMPONENT Utilities) diff --git a/Applications/Utils/MeshGeoTools/CMakeLists.txt b/Applications/Utils/MeshGeoTools/CMakeLists.txt index fbe634be3d0d0820b9f7e15b96aecec7c9af6f1c..324e80d8fdb4d63cb0306a3b98e976f5f4c55607 100644 --- a/Applications/Utils/MeshGeoTools/CMakeLists.txt +++ b/Applications/Utils/MeshGeoTools/CMakeLists.txt @@ -20,7 +20,9 @@ foreach(TOOL ${TOOLS}) ApplicationsFileIO GitInfoLib MeshLib - MeshGeoToolsLib) + MeshGeoToolsLib + tclap + ) endforeach() if(TARGET VerticalSliceFromLayers) diff --git a/Applications/Utils/ModelPreparation/CMakeLists.txt b/Applications/Utils/ModelPreparation/CMakeLists.txt index 683b6ebf448a11c5aa562d71e7180f5ae703f02b..dea0a6c8b16c5f9a60dc625c0dade39a633fc740 100644 --- a/Applications/Utils/ModelPreparation/CMakeLists.txt +++ b/Applications/Utils/ModelPreparation/CMakeLists.txt @@ -2,7 +2,7 @@ set(TOOLS ComputeNodeAreasFromSurfaceMesh convertVtkDataArrayToVtkDataArray createNeumannBc scaleProperty) foreach(TOOL ${TOOLS}) add_executable(${TOOL} ${TOOL}.cpp) - target_link_libraries(${TOOL} GitInfoLib MeshLib) + target_link_libraries(${TOOL} GitInfoLib MeshLib tclap) endforeach() set_target_properties(${TOOLS} PROPERTIES FOLDER Utilities) install(TARGETS ${TOOLS} RUNTIME DESTINATION bin COMPONENT Utilities) diff --git a/Applications/Utils/ModelPreparation/PartitionMesh/CMakeLists.txt b/Applications/Utils/ModelPreparation/PartitionMesh/CMakeLists.txt index 44b852e052c0b0a028e7182beb2eb5d7cfa92ed3..26815713ce4c80c1e2bb460c95fe2f44ee46353f 100644 --- a/Applications/Utils/ModelPreparation/PartitionMesh/CMakeLists.txt +++ b/Applications/Utils/ModelPreparation/PartitionMesh/CMakeLists.txt @@ -1,5 +1,5 @@ add_executable(partmesh PartitionMesh.cpp Metis.cpp NodeWiseMeshPartitioner.cpp) set_target_properties(partmesh PROPERTIES FOLDER Utilities) -target_link_libraries(partmesh GitInfoLib MeshLib) +target_link_libraries(partmesh GitInfoLib MeshLib tclap) add_dependencies(partmesh mpmetis) install(TARGETS partmesh RUNTIME DESTINATION bin COMPONENT ogs_partmesh) diff --git a/Applications/Utils/OGSFileConverter/CMakeLists.txt b/Applications/Utils/OGSFileConverter/CMakeLists.txt index e7ead14d3127f4d05e203cb687e733dedc0d7e32..df1df12b7dd3819d5d3024e4a812804b294d3507 100644 --- a/Applications/Utils/OGSFileConverter/CMakeLists.txt +++ b/Applications/Utils/OGSFileConverter/CMakeLists.txt @@ -9,7 +9,7 @@ set_target_properties(OGSFileConverterLib PROPERTIES AUTOMOC TRUE AUTOUIC TRUE) add_executable(OGSFileConverter main.cpp) target_link_libraries(OGSFileConverter - PUBLIC ApplicationsFileIO GitInfoLib OGSFileConverterLib) + PUBLIC ApplicationsFileIO GitInfoLib OGSFileConverterLib tclap) add_autogen_include(OGSFileConverterLib) diff --git a/Applications/Utils/PostProcessing/CMakeLists.txt b/Applications/Utils/PostProcessing/CMakeLists.txt index 68b8de9194421427a0e01fc17f5db41ce20fbadf..56d7df38bd1cc33c07067741f9965e7375adf2e8 100644 --- a/Applications/Utils/PostProcessing/CMakeLists.txt +++ b/Applications/Utils/PostProcessing/CMakeLists.txt @@ -1,13 +1,13 @@ if(OGS_BUILD_PROCESS_LIE) add_executable(postLIE postLIE.cpp) - target_link_libraries(postLIE GitInfoLib LIECommon) + target_link_libraries(postLIE GitInfoLib LIECommon tclap) set_target_properties(postLIE PROPERTIES FOLDER Utilities) install(TARGETS postLIE RUNTIME DESTINATION bin COMPONENT Utilities) endif() if(OGS_BUILD_GUI) add_executable(Raster2PointCloud Raster2PointCloud.cpp) - target_link_libraries(Raster2PointCloud GitInfoLib ApplicationsFileIO BaseLib GeoLib VtkVis QtDataView) + target_link_libraries(Raster2PointCloud GitInfoLib ApplicationsFileIO BaseLib GeoLib VtkVis QtDataView tclap) set_target_properties(Raster2PointCloud PROPERTIES FOLDER Utilities) install(TARGETS Raster2PointCloud RUNTIME DESTINATION bin COMPONENT Utilities) endif() diff --git a/Applications/Utils/SWMMConverter/CMakeLists.txt b/Applications/Utils/SWMMConverter/CMakeLists.txt index 77f9e68a993793e6bd5c1328c6699e3d6ffb75b1..ba04ef30831b3cb82da6bc83a85ab76e32e166b1 100644 --- a/Applications/Utils/SWMMConverter/CMakeLists.txt +++ b/Applications/Utils/SWMMConverter/CMakeLists.txt @@ -4,7 +4,9 @@ target_link_libraries(SWMMConverter GeoLib GitInfoLib MeshLib - SwmmInterface) + SwmmInterface + tclap +) include_directories(${PROJECT_SOURCE_DIR}/Applications/FileIO) set_target_properties(SWMMConverter PROPERTIES FOLDER Utilities) install(TARGETS SWMMConverter RUNTIME DESTINATION bin COMPONENT Utilities) diff --git a/Applications/Utils/SimpleMeshCreation/CMakeLists.txt b/Applications/Utils/SimpleMeshCreation/CMakeLists.txt index ebef70b4a168798aaadfe119aefa7fc13785584a..b75f2d0e41d6b53616ab87a2f299f366a9e577d9 100644 --- a/Applications/Utils/SimpleMeshCreation/CMakeLists.txt +++ b/Applications/Utils/SimpleMeshCreation/CMakeLists.txt @@ -5,7 +5,7 @@ endif() foreach(TOOL ${TOOLS}) add_executable(${TOOL} ${TOOL}.cpp) - target_link_libraries(${TOOL} ApplicationsFileIO GitInfoLib MeshLib) + target_link_libraries(${TOOL} ApplicationsFileIO GitInfoLib MeshLib tclap) endforeach() set_target_properties(${TOOLS} PROPERTIES FOLDER Utilities) install(TARGETS ${TOOLS} RUNTIME DESTINATION bin COMPONENT Utilities) diff --git a/CMakeLists.txt b/CMakeLists.txt index 44c7796bc873f3bc00844da04886f19bc2ea6f00..72503191ce9b235a226e3b5ece3f2f18c6de2338 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -223,7 +223,6 @@ add_subdirectory(ThirdParty) include_directories( SYSTEM ${CMAKE_CURRENT_SOURCE_DIR}/ThirdParty - ${CMAKE_CURRENT_SOURCE_DIR}/ThirdParty/tclap/include ${CMAKE_CURRENT_SOURCE_DIR}/ThirdParty/json/include ) diff --git a/Tests/xdmfdiff/CMakeLists.txt b/Tests/xdmfdiff/CMakeLists.txt index 65e64bf69f695d8a1a9c7573e30e557f5022f643..267a0d71306b8aceb83e80c2a3d750460034b880 100644 --- a/Tests/xdmfdiff/CMakeLists.txt +++ b/Tests/xdmfdiff/CMakeLists.txt @@ -1,3 +1,3 @@ add_executable(xdmfdiff xdmfdiff.cpp) -target_link_libraries(xdmfdiff OgsXdmf std::filesystem) +target_link_libraries(xdmfdiff OgsXdmf std::filesystem tclap) install(PROGRAMS $<TARGET_FILE:xdmfdiff> DESTINATION bin COMPONENT ogs_extras) diff --git a/ThirdParty/tclap b/ThirdParty/tclap deleted file mode 160000 index 03abc3a3327214137c6ffd5b9a6efe23f0927cc2..0000000000000000000000000000000000000000 --- a/ThirdParty/tclap +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 03abc3a3327214137c6ffd5b9a6efe23f0927cc2 diff --git a/scripts/cmake/Find.cmake b/scripts/cmake/Find.cmake index 7cd90c940ebaa2e0f773de0b748ab7d7b4261a90..a1cd935fa3009b4076daa6dea956a663c43a0122 100644 --- a/scripts/cmake/Find.cmake +++ b/scripts/cmake/Find.cmake @@ -36,9 +36,19 @@ CPMAddPackage( NAME spdlog GITHUB_REPOSITORY gabime/spdlog VERSION 1.8.2 - # DOWNLOAD_ONLY YES ) +CPMAddPackage( + NAME tclap + GITHUB_REPOSITORY ufz/tclap + GIT_TAG 03abc3a3327214137c6ffd5b9a6efe23f0927cc2 + DOWNLOAD_ONLY YES +) +if(tclap_ADDED) + add_library(tclap INTERFACE IMPORTED) + target_include_directories(tclap INTERFACE ${tclap_SOURCE_DIR}/include) +endif() + ###################### ### Find tools ### ###################### diff --git a/scripts/cmake/SubmoduleSetup.cmake b/scripts/cmake/SubmoduleSetup.cmake index 1f0580bf2e75e2b7e9585c1f62f3ceef0fd7b5be..dbfa1f68185143ca47946cd261476c50d41f3795 100644 --- a/scripts/cmake/SubmoduleSetup.cmake +++ b/scripts/cmake/SubmoduleSetup.cmake @@ -12,7 +12,6 @@ set(REQUIRED_SUBMODULES ThirdParty/cmake-modules ThirdParty/iphreeqc/src ThirdParty/json-cmake - ThirdParty/tclap ThirdParty/tetgen ${OGS_ADDITIONAL_SUBMODULES_TO_CHECKOUT} )