mirror of https://github.com/CGAL/cgal
Explicit the dependencies of QGLViewer
This commit is contained in:
parent
6b300501aa
commit
fe24a4db68
|
|
@ -7,6 +7,8 @@
|
|||
# QGLVIEWER_DEFINITIONS - Compiler switches required for using QGLViewer
|
||||
#
|
||||
|
||||
find_package(Qt5 QUIET COMPONENTS OpenGL Xml)
|
||||
|
||||
# first look in user defined locations
|
||||
find_path(QGLVIEWER_INCLUDE_DIR
|
||||
NAMES QGLViewer/qglviewer.h
|
||||
|
|
@ -50,15 +52,17 @@ endif()
|
|||
|
||||
if(QGLVIEWER_LIBRARY_RELEASE)
|
||||
if(QGLVIEWER_LIBRARY_DEBUG)
|
||||
set(QGLVIEWER_LIBRARIES_ optimized ${QGLVIEWER_LIBRARY_RELEASE} debug ${QGLVIEWER_LIBRARY_DEBUG})
|
||||
set(QGLVIEWER_LIBRARIES_ Qt5::Xml Qt5::OpenGL optimized ${QGLVIEWER_LIBRARY_RELEASE} debug ${QGLVIEWER_LIBRARY_DEBUG})
|
||||
else()
|
||||
set(QGLVIEWER_LIBRARIES_ ${QGLVIEWER_LIBRARY_RELEASE})
|
||||
set(QGLVIEWER_LIBRARIES_ Qt5::Xml Qt5::OpenGL ${QGLVIEWER_LIBRARY_RELEASE})
|
||||
endif()
|
||||
|
||||
set(QGLVIEWER_LIBRARIES ${QGLVIEWER_LIBRARIES_} CACHE FILEPATH "The QGLViewer library")
|
||||
|
||||
endif()
|
||||
|
||||
message("QGLViewer: ${QGLVIEWER_LIBRARIES}")
|
||||
|
||||
IF(QGLVIEWER_INCLUDE_DIR AND QGLVIEWER_LIBRARIES)
|
||||
SET(QGLVIEWER_FOUND TRUE)
|
||||
ENDIF(QGLVIEWER_INCLUDE_DIR AND QGLVIEWER_LIBRARIES)
|
||||
|
|
|
|||
|
|
@ -14,6 +14,8 @@ get_filename_component(CGAL_CONFIG_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
|
|||
|
||||
set(CGAL_HEADER_ONLY TRUE)
|
||||
|
||||
set( CGAL_REQUESTED_COMPONENTS ${CGAL_FIND_COMPONENTS} )
|
||||
|
||||
# Save the current source directory. That variable can be changed by
|
||||
# a `CMakeLists.txt`, for `CMakeLists.txt` files that are created in
|
||||
# the binary directory.
|
||||
|
|
@ -75,6 +77,7 @@ endforeach()
|
|||
# Define the CGAL targets and theirs CGAL:: aliases
|
||||
#
|
||||
foreach(cgal_lib CGAL CGAL_Core CGAL_ImageIO CGAL_Qt5)
|
||||
set(WITH_${cgal_lib} TRUE)
|
||||
if(${cgal_lib}_FOUND AND NOT TARGET ${cgal_lib})
|
||||
add_library(${cgal_lib} INTERFACE)
|
||||
if(NOT TARGET CGAL::${cgal_lib})
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ find_package(CGAL COMPONENTS Qt5)
|
|||
include(${CGAL_USE_FILE})
|
||||
|
||||
|
||||
find_package(Qt5 QUIET COMPONENTS Xml OpenGL Svg)
|
||||
find_package(Qt5 QUIET COMPONENTS OpenGL)
|
||||
|
||||
find_package(OpenGL)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue