diff options
author | Brad King <brad.king@kitware.com> | 2009-02-24 22:07:04 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2009-02-24 22:07:04 (GMT) |
commit | 1353ed0bd8d2d530fda16b3c407f085b3f77af9d (patch) | |
tree | ec698bc44941c10a1ddf8548f4304c992d3d3061 /Utilities/CMakeLists.txt | |
parent | cf55e01adadfa569715fac21373c7fda089b3fe8 (diff) | |
download | CMake-1353ed0bd8d2d530fda16b3c407f085b3f77af9d.zip CMake-1353ed0bd8d2d530fda16b3c407f085b3f77af9d.tar.gz CMake-1353ed0bd8d2d530fda16b3c407f085b3f77af9d.tar.bz2 |
BUG: Fix cmake-gui docs generation PATH feature
Automatic addition of the Qt DLL location to PATH can be done only for
generators that use a Windows shell.
Diffstat (limited to 'Utilities/CMakeLists.txt')
-rw-r--r-- | Utilities/CMakeLists.txt | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/Utilities/CMakeLists.txt b/Utilities/CMakeLists.txt index 499bb42..6f7845e 100644 --- a/Utilities/CMakeLists.txt +++ b/Utilities/CMakeLists.txt @@ -32,14 +32,17 @@ MACRO(ADD_DOCS target dependency) ENDMACRO(ADD_DOCS target dependency) # Help cmake-gui find the Qt DLLs on Windows. -IF(BUILD_QtDialog AND WIN32 AND EXISTS "${QT_QMAKE_EXECUTABLE}") +SET(WIN_SHELL_GENS "Visual Studio|NMake|MinGW|Watcom|Borland") +IF(BUILD_QtDialog AND "${CMAKE_GENERATOR}" MATCHES "${WIN_SHELL_GENS}" + AND EXISTS "${QT_QMAKE_EXECUTABLE}" AND NOT CMAKE_NO_AUTO_QT_ENV) GET_FILENAME_COMPONENT(Qt_BIN_DIR "${QT_QMAKE_EXECUTABLE}" PATH) IF(EXISTS "${Qt_BIN_DIR}/QtCore4.dll") # Tell the macro to set the path before running cmake-gui. STRING(REPLACE ";" "\\;" _PATH "PATH=${Qt_BIN_DIR};%PATH%") SET(cmake-gui-PATH COMMAND set "${_PATH}") ENDIF(EXISTS "${Qt_BIN_DIR}/QtCore4.dll") -ENDIF(BUILD_QtDialog AND WIN32 AND EXISTS "${QT_QMAKE_EXECUTABLE}") +ENDIF(BUILD_QtDialog AND "${CMAKE_GENERATOR}" MATCHES "${WIN_SHELL_GENS}" + AND EXISTS "${QT_QMAKE_EXECUTABLE}" AND NOT CMAKE_NO_AUTO_QT_ENV) # add the docs for the executables ADD_DOCS(ctest ${CMake_SOURCE_DIR}/Utilities/Doxygen/authors.txt) |