From: Luca Heltai Date: Mon, 2 May 2022 11:44:17 +0000 (+0300) Subject: Trying to fix FindCGAL. X-Git-Tag: v9.4.0-rc1~284^2~1 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6945366299c1f3091bc0e3394a8605c7e89c2c93;p=dealii.git Trying to fix FindCGAL. --- diff --git a/cmake/modules/FindCGAL.cmake b/cmake/modules/FindCGAL.cmake index abc1dc244a..8262f941a7 100644 --- a/cmake/modules/FindCGAL.cmake +++ b/cmake/modules/FindCGAL.cmake @@ -33,14 +33,26 @@ IF(DEAL_II_HAVE_CXX17) LIST(REMOVE_ITEM CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/modules/) FIND_PACKAGE(CGAL) LIST(APPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/modules/) + IF(CGAL_HEADER_ONLY) + SET(CGAL_LIBS "-NOTFOUND") + ELSE(CGAL_HEADER_ONLY) + SET(CGAL_LIBS "${CGAL_CONFIGURED_LIBRARIES}") + ENDIF(CGAL_HEADER_ONLY) ELSE(DEAL_II_HAVE_CXX17) SET(CGAL_FOUND FALSE) SET(CGAL_INCLUDE_DIRS "-NOTFOUND") + SET(CGAL_LIBS "-NOTFOUND") MESSAGE(STATUS "CGAL wrappers require C++17. Disabling CGAL Support.") ENDIF(DEAL_II_HAVE_CXX17) DEAL_II_PACKAGE_HANDLE(CGAL - INCLUDE_DIRS REQUIRED CGAL_INCLUDE_DIRS - USER_INCLUDE_DIRS REQUIRED CGAL_INCLUDE_DIRS - CLEAR CGAL_INCLUDE_DIRS + INCLUDE_DIRS + REQUIRED CGAL_INCLUDE_DIRS + LIBRARIES + OPTIONAL CGAL_LIBS + USER_INCLUDE_DIRS + REQUIRED CGAL_INCLUDE_DIRS + CLEAR + CGAL_INCLUDE_DIRS + CGAL_LIBS )