mirror of https://github.com/CGAL/cgal
Bugfix in check_cgal_component for its first call.
This commit is contained in:
parent
221c9462db
commit
38ca4dd5e0
|
|
@ -92,6 +92,9 @@ set(CGAL_INCLUDE_DIRS "@CGAL_INCLUDE_DIRS@" )
|
|||
set(CGAL_MODULES_DIR "@CGAL_MODULES_DIR@" )
|
||||
set(CGAL_LIBRARIES_DIR "@CGAL_LIBRARIES_DIR@" )
|
||||
|
||||
set(ENABLE_HEADER_ONLY "@ENABLE_HEADER_ONLY@" )
|
||||
set(CGAL_QT5_QTMOCCMAKE_FILES "@CGAL_QT5_QTMOCCMAKE_FILES@")
|
||||
|
||||
set(CGAL_VERSION "${CGAL_MAJOR_VERSION}.${CGAL_MINOR_VERSION}.${CGAL_BUILD_VERSION}")
|
||||
|
||||
set(CGAL_USE_FILE "${CGAL_MODULES_DIR}/UseCGAL.cmake" )
|
||||
|
|
@ -127,10 +130,14 @@ macro(check_cgal_component COMPONENT)
|
|||
if(TARGET CGAL::${CGAL_LIB} OR ENABLE_HEADER_ONLY)
|
||||
set( ${CGAL_LIB}_FOUND TRUE )
|
||||
if ("${CGAL_LIB}" STREQUAL "CGAL_Qt5" AND ENABLE_HEADER_ONLY)
|
||||
message("TOTOTOTTO " ${CGAL_QT5_QTMOCCMAKE_FILES})
|
||||
if(Qt5_FOUND)
|
||||
message("TOTOTOTO " ${CGAL_QT5_QTMOCCMAKE_FILES})
|
||||
foreach(qtmoc_file ${CGAL_QT5_QTMOCCMAKE_FILES})
|
||||
include(${qtmoc_file})
|
||||
endforeach()
|
||||
else(Qt5_FOUND)
|
||||
message(FATAL_ERROR "You need to find package Qt5 before to find package CGAL to compile demo in header only mode.")
|
||||
endif(Qt5_FOUND)
|
||||
endif()
|
||||
else()
|
||||
set( ${CGAL_LIB}_FOUND FALSE )
|
||||
|
|
|
|||
|
|
@ -456,10 +456,6 @@ if( NOT CGAL_MACROS_FILE_INCLUDED )
|
|||
|
||||
endforeach()
|
||||
|
||||
file( APPEND ${CMAKE_BINARY_DIR}/CGALConfig.cmake "set(ENABLE_HEADER_ONLY \"${ENABLE_HEADER_ONLY}\" CACHE BOOL \"Enable cgal header only\" FORCE)\n")
|
||||
|
||||
file( APPEND ${CMAKE_BINARY_DIR}/CGALConfig.cmake "set(CGAL_QT5_QTMOCCMAKE_FILES \"${CGAL_QT5_QTMOCCMAKE_FILES}\" CACHE INTERNAL \"CGAL qt5 qtmoc cmake files\" FORCE)\n")
|
||||
|
||||
endmacro()
|
||||
|
||||
macro ( fetch_env_var VAR )
|
||||
|
|
@ -472,16 +468,6 @@ if( NOT CGAL_MACROS_FILE_INCLUDED )
|
|||
endif()
|
||||
endmacro()
|
||||
|
||||
macro ( cgal_include_moc_files )
|
||||
# set(mocfiles "")
|
||||
# set(RESOURCE_FILES "")
|
||||
if ( ENABLE_HEADER_ONLY )
|
||||
foreach(qtmoc_file ${CGAL_QT5_QTMOCCMAKE_FILES})
|
||||
include(${qtmoc_file})
|
||||
endforeach()
|
||||
endif()
|
||||
endmacro()
|
||||
|
||||
## All the following macros are probably unused. -- Laurent Rineau, 2011/07/21
|
||||
|
||||
# Composes a tagged list of libraries: a list with interpersed keywords or tags
|
||||
|
|
|
|||
Loading…
Reference in New Issue