diff options
author | Clinton Stimpson <clinton@elemtech.com> | 2010-03-17 04:28:03 (GMT) |
---|---|---|
committer | Clinton Stimpson <clinton@elemtech.com> | 2010-03-17 04:40:44 (GMT) |
commit | 5e1a2408fedd379467693b3548d46dad464f72ad (patch) | |
tree | ec643d5a882fb7af8b9eb0ad0ddc65eaf5cfb0cd /Modules/Qt4ConfigDependentSettings.cmake | |
parent | 7f98d73457f6d5314a59759830a3d44df59aa669 (diff) | |
download | CMake-5e1a2408fedd379467693b3548d46dad464f72ad.zip CMake-5e1a2408fedd379467693b3548d46dad464f72ad.tar.gz CMake-5e1a2408fedd379467693b3548d46dad464f72ad.tar.bz2 |
ENH: Modify how OpenGL is searched for, that is, use FindOpenGL.cmake.
Diffstat (limited to 'Modules/Qt4ConfigDependentSettings.cmake')
-rw-r--r-- | Modules/Qt4ConfigDependentSettings.cmake | 22 |
1 files changed, 5 insertions, 17 deletions
diff --git a/Modules/Qt4ConfigDependentSettings.cmake b/Modules/Qt4ConfigDependentSettings.cmake index 1c5293d..01f740f 100644 --- a/Modules/Qt4ConfigDependentSettings.cmake +++ b/Modules/Qt4ConfigDependentSettings.cmake @@ -60,25 +60,13 @@ IF(WIN32 AND NOT QT_IS_STATIC) SET(QT_DEFINITIONS ${QT_DEFINITIONS} -DQT_DLL) ENDIF(WIN32 AND NOT QT_IS_STATIC) +IF(NOT QT_IS_STATIC) + RETURN() +ENDIF(NOT QT_IS_STATIC) # QtOpenGL dependencies -QT_QUERY_QMAKE(QMAKE_LIBS_OPENGL "QMAKE_LIBS_OPENGL") -IF(Q_WS_MAC) -# On the Mac OpenGL is probably frameworks and QMAKE_LIBS_OPENGL can be -# e.g. "-framework OpenGL -framework AGL". The separate_arguments() call in -# the other branch makes "-framework;-OpenGL;-framework;-lAGL" appear in the -# linker command. So we need to protect the "-framework foo" as -# non-separatable strings. We do this by replacing the space after -# "-framework" with an underscore, then calling separate_arguments(), and -# then we replace the underscores again with spaces. So we get proper linker -# commands. Alex - STRING(REGEX REPLACE "-framework +" "-framework_" QMAKE_LIBS_OPENGL "${QMAKE_LIBS_OPENGL}") - SEPARATE_ARGUMENTS(QMAKE_LIBS_OPENGL) - STRING(REGEX REPLACE "-framework_" "-framework " QMAKE_LIBS_OPENGL "${QMAKE_LIBS_OPENGL}") -ELSE(Q_WS_MAC) - SEPARATE_ARGUMENTS(QMAKE_LIBS_OPENGL) -ENDIF(Q_WS_MAC) -SET (QT_QTOPENGL_LIB_DEPENDENCIES ${QT_QTOPENGL_LIB_DEPENDENCIES} ${QMAKE_LIBS_OPENGL}) +find_package(OpenGL) +SET (QT_QTOPENGL_LIB_DEPENDENCIES ${OPENGL_glu_LIBRARY} ${OPENGL_gl_LIBRARY}) ## system png |