remove WITH_XXX cache options

This commit is contained in:
Maxime Gimeno 2020-10-05 15:19:55 +02:00
parent 27589e4b26
commit fa2e8ec0a4
3 changed files with 3 additions and 47 deletions

View File

@ -526,7 +526,7 @@ message("== Detect external libraries ==")
# External libs configured when Qt5 lib of cgal are required # External libs configured when Qt5 lib of cgal are required
# Coin is used in KDS, but no FindCoin or FindCOIN exists # Coin is used in KDS, but no FindCoin or FindCOIN exists
# There exists FindIPE, FindMKL, but they are only used to support supporting libs # There exists FindIPE, FindMKL, but they are only used to support supporting libs
list (INSERT CGAL_SUPPORTING_3RD_PARTY_LIBRARIES 0 GMP MPFR ZLIB OpenGL LEDA MPFI RS RS3 OpenNL Eigen3 ESBTL Coin3D NTL IPE) list (INSERT CGAL_SUPPORTING_3RD_PARTY_LIBRARIES 0 LEDA )
# Where CMake is run several times, to avoid duplicates # Where CMake is run several times, to avoid duplicates
list(REMOVE_DUPLICATES CGAL_SUPPORTING_3RD_PARTY_LIBRARIES) list(REMOVE_DUPLICATES CGAL_SUPPORTING_3RD_PARTY_LIBRARIES)
@ -562,13 +562,8 @@ if(CGAL_DISABLE_GMP)
unset(MPFR_FOUND CACHE) unset(MPFR_FOUND CACHE)
unset(WITH_CGAL_Core) unset(WITH_CGAL_Core)
unset(WITH_CGAL_Core CACHE) unset(WITH_CGAL_Core CACHE)
unset(WITH_GMP)
unset(WITH_GMP CACHE)
unset(CGAL_USE_GMP) unset(CGAL_USE_GMP)
unset(CGAL_USE_GMP CACHE) unset(CGAL_USE_GMP CACHE)
unset(WITH_MPFR)
unset(WITH_MPFR CACHE)
# Nasty trick to make sure <gmp.h> is not used when CGAL_DISABLE_GMP is TRUE # Nasty trick to make sure <gmp.h> is not used when CGAL_DISABLE_GMP is TRUE
file(WRITE "${CMAKE_BINARY_DIR}/include/gmp.h" file(WRITE "${CMAKE_BINARY_DIR}/include/gmp.h"
"#error GMP is disabled by the CMake option CGAL_DISABLE_GMP") "#error GMP is disabled by the CMake option CGAL_DISABLE_GMP")

View File

@ -333,45 +333,6 @@ if( NOT CGAL_MACROS_FILE_INCLUDED )
endmacro() endmacro()
macro( use_essential_libs )
# Comment: This is subject to be changed in the future
# - either more specific (giving precise include_dir- and link-order)
# - or even less specific if order becomes less relevant
# Eric Berberich 2012/06/29
if(NOT CGAL_DISABLE_GMP)
if(RS_FOUND)
use_component( RS )
endif()
if(MPFI_FOUND)
use_component( MPFI )
endif()
if(MPFR_FOUND)
use_component( MPFR )
endif()
if (GMPXX_FOUND)
use_component( GMPXX )
endif()
if(GMP_FOUND)
use_component( GMP )
endif()
endif(NOT CGAL_DISABLE_GMP)
if(LEDA_FOUND)
use_component( LEDA )
endif()
if(NTL_FOUND)
use_component( NTL )
endif()
endmacro()
function( cgal_setup_module_path ) function( cgal_setup_module_path )
# Avoid to modify the modules path twice # Avoid to modify the modules path twice
if(NOT CGAL_MODULE_PATH_IS_SET) if(NOT CGAL_MODULE_PATH_IS_SET)

View File

@ -35,10 +35,10 @@ if(BRANCH_BUILD)
foreach(package_dir ${packages_dirs}) foreach(package_dir ${packages_dirs})
set(inc_dir ${package_dir}/include) set(inc_dir ${package_dir}/include)
if(IS_DIRECTORY ${inc_dir} if(IS_DIRECTORY ${inc_dir}
AND IS_DIRECTORY ${package_dir}/package_info) AND IS_DIRECTORY ${package_dir}/package_info)
list(APPEND CGAL_INCLUDE_DIRS ${inc_dir}) list(APPEND CGAL_INCLUDE_DIRS ${inc_dir})
if(EXISTS ${inc_dir}/CGAL/config.h) if(EXISTS ${inc_dir}/CGAL/config.h)
set(CGAL_FOUND TRUE) set(CGAL_FOUND TRUE)
endif() endif()
endif() endif()
endforeach() endforeach()