Topologically sort $${MODULE}.depends when generating cmake files.

The contents of this eventually go into a CMake target
property IMPORTED_LINK_INTERFACE_LIBRARIES, which seems to expect
sorted input. Usually the contents is generated by CMake itself,
so generating content it expects is reasonable.

This fixes the qtactiveqt cmake unit test with MingW on linux.

Change-Id: I2a540bea5c3ac214ad4e1dfedfb7cbd2f863472b
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
This commit is contained in:
Stephen Kelly 2012-12-07 10:13:24 +01:00 committed by The Qt Project
parent 035c3b5781
commit 25f903bf28

View File

@ -17,7 +17,7 @@ defineReplace(cmakeModuleList) {
CMAKE_MODULE_NAME = $$cmakeModuleName($${MODULE}) CMAKE_MODULE_NAME = $$cmakeModuleName($${MODULE})
CMAKE_MODULE_DEPS = $$cmakeModuleList($$eval(QT.$${MODULE}.depends)) CMAKE_MODULE_DEPS = $$cmakeModuleList($$sort_depends(QT.$${MODULE}.depends, QT.))
CMAKE_PARTIAL_MODULE_DEPS = $$replace(CMAKE_MODULE_DEPS, ";", ";Qt5::") CMAKE_PARTIAL_MODULE_DEPS = $$replace(CMAKE_MODULE_DEPS, ";", ";Qt5::")
!isEmpty(CMAKE_PARTIAL_MODULE_DEPS):CMAKE_QT5_MODULE_DEPS = "Qt5::$${CMAKE_PARTIAL_MODULE_DEPS}" !isEmpty(CMAKE_PARTIAL_MODULE_DEPS):CMAKE_QT5_MODULE_DEPS = "Qt5::$${CMAKE_PARTIAL_MODULE_DEPS}"