Fix platform definition directory in top-level build

QT_BUILD_DIR should be used instead of CMAKE_BINARY_DIR as a base
directory for platform definition when building a non-prefixed
build since artifacts are copied to qtbase directory for top-level
build.

Amends 478f5fcde6

Pick-to: 6.1 6.2
Task-number: QTBUG-94973
Change-Id: I5cce16fdc7f760b954222ae67a4b85d4beea7f13
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
This commit is contained in:
Alexey Edelev 2021-07-06 15:50:06 +02:00
parent fd30881989
commit 9bbca531eb

View File

@ -383,7 +383,7 @@ set(QT_PLATFORM_DEFINITION_BUILD_INTERFACE_BASE_DIR
# Used by qtbase and consumers in non-prefix builds via BUILD_INTERFACE
if(NOT QT_WILL_INSTALL)
set(QT_PLATFORM_DEFINITION_BUILD_INTERFACE_BASE_DIR
"${CMAKE_BINARY_DIR}/${INSTALL_MKSPECSDIR}"
"${QT_BUILD_DIR}/${INSTALL_MKSPECSDIR}"
)
endif()