From be0f80223664114ea57364951ab28a664fe6cd9c Mon Sep 17 00:00:00 2001 From: Laurent Rineau Date: Tue, 7 Jun 2022 16:34:02 +0200 Subject: [PATCH] Warn only if CGAL_TEST_SUITE is set and CGAL_DATA_DIR is not --- Installation/lib/cmake/CGAL/CGALConfig.cmake | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Installation/lib/cmake/CGAL/CGALConfig.cmake b/Installation/lib/cmake/CGAL/CGALConfig.cmake index 4f3a16b5026..6edefb1810f 100644 --- a/Installation/lib/cmake/CGAL/CGALConfig.cmake +++ b/Installation/lib/cmake/CGAL/CGALConfig.cmake @@ -89,7 +89,9 @@ if (NOT CGAL_DATA_DIR) if (EXISTS "${CMAKE_SOURCE_DIR}/../../data") set(CGAL_DATA_DIR "${CMAKE_SOURCE_DIR}/../../data") else() - message(WARNING "CGAL_DATA_DIR cannot be deduced, set the variable CGAL_DATA_DIR to set the default value of CGAL::data_file_path()") + if(CGAL_TEST_SUITE) + message(WARNING "CGAL_DATA_DIR cannot be deduced, set the variable CGAL_DATA_DIR to set the default value of CGAL::data_file_path()") + endif() endif() endif() endif()