From 301538cf01cf0c1bf27075e8459894a0e37756d6 Mon Sep 17 00:00:00 2001 From: Stephen Kelly Date: Thu, 19 Jul 2012 10:40:25 +0200 Subject: [PATCH] Add another directory to the private INCLUDE_DIRS list. It should be possible to include both: * * Change-Id: I83ed5bba633b4a6b9bd38e315c987d78beecfb1b Reviewed-by: Oswald Buddenhagen --- mkspecs/cmake/Qt5BasicConfig.cmake.in | 10 ++++++++-- tests/auto/cmake/test_private_includes/main.cpp | 5 +++++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/mkspecs/cmake/Qt5BasicConfig.cmake.in b/mkspecs/cmake/Qt5BasicConfig.cmake.in index 6f19f5f..47416e9 100644 --- a/mkspecs/cmake/Qt5BasicConfig.cmake.in +++ b/mkspecs/cmake/Qt5BasicConfig.cmake.in @@ -10,10 +10,16 @@ set(Qt5$${CMAKE_MODULE_NAME}_LIBRARIES Qt5::$${CMAKE_MODULE_NAME}) !!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 \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}/Qt$${CMAKE_MODULE_NAME}\") +set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS + \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}\" + \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}/Qt$${CMAKE_MODULE_NAME}\" +) !!ELSE set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS \"$$CMAKE_INCLUDE_DIR\" \"$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}\") -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}\") +set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS + \"$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}\" + \"$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}/Qt$${CMAKE_MODULE_NAME}\" +) !!ENDIF set(Qt5$${CMAKE_MODULE_NAME}_DEFINITIONS -D$${MODULE_DEFINE}) diff --git a/tests/auto/cmake/test_private_includes/main.cpp b/tests/auto/cmake/test_private_includes/main.cpp index 4f4457bf..3319688 100644 --- a/tests/auto/cmake/test_private_includes/main.cpp +++ b/tests/auto/cmake/test_private_includes/main.cpp @@ -42,6 +42,7 @@ #include #include #include +#include int main(int argc, char **argv) { @@ -50,5 +51,9 @@ int main(int argc, char **argv) QPlatformScreen *screenHandle = app.screens().first()->handle(); screenHandle->geometry(); + QPixmap pixmap; + QPlatformPixmap *pixmapHandle = pixmap.handle(); + pixmapHandle->width(); + return 0; } -- 2.7.4