Add a way to not generate INCLUDE_DIRS variables.

ActiveQt needs this, and it sets the no_module_headers flag.

We still need to set the include_dirs variable in the
no_module_headers case, so that its dependencies are added to it.

Change-Id: I2cad5ee792eed51d36b7c8e2c616763516a5fc10
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
This commit is contained in:
Stephen Kelly 2012-11-29 22:49:52 +01:00 committed by The Qt Project
parent def3285615
commit 2bda681eb6

View File

@ -12,6 +12,7 @@ set(Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING "$$eval(QT.$${MODULE}.MAJOR_VERSION)
set(Qt5$${CMAKE_MODULE_NAME}_LIBRARIES Qt5::$${CMAKE_MODULE_NAME})
!!IF !no_module_headers
!!IF isEmpty(CMAKE_INCLUDE_DIR_IS_ABSOLUTE)
set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$$CMAKE_INCLUDE_DIR\" \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}\")
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS
@ -25,6 +26,10 @@ set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS
\"$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}/Qt$${CMAKE_MODULE_NAME}\"
)
!!ENDIF
!!ELSE
set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS)
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS)
!!ENDIF
set(Qt5$${CMAKE_MODULE_NAME}_DEFINITIONS -D$${MODULE_DEFINE})
set(Qt5$${CMAKE_MODULE_NAME}_COMPILE_DEFINITIONS $${MODULE_DEFINE})