diff options
author | Samuli Piippo <samuli.piippo@qt.io> | 2023-01-18 09:38:07 +0000 |
---|---|---|
committer | Samuli Piippo <samuli.piippo@qt.io> | 2023-09-21 12:25:28 +0300 |
commit | a9b04a9324cc9962e009c201593d2e1963f69aef (patch) | |
tree | f55f962dc44c4a55decf2d3289e524cf229c2dd9 | |
parent | aefe8391be3f928796e158ff764c394d17296697 (diff) |
qbsp: add mkspec to container toolchain kit
QtCreator has been fixed, so mkspec can be added also to container
toolchain. Also use empty build device for non-container toolchain,
which defaults to desktop device. This allows simpler installer
script to be maintained.
Change-Id: I249b8ee56fc4e4600c85c668ae2addf33c4c2686
Reviewed-by: Mikko Gronoff <mikko.gronoff@qt.io>
(cherry picked from commit 5e92c0eaf453885ae0958bc48845732a76bab528)
-rw-r--r-- | meta-boot2qt/files/qbsp/toolchain_installscript.qs | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/meta-boot2qt/files/qbsp/toolchain_installscript.qs b/meta-boot2qt/files/qbsp/toolchain_installscript.qs index 5e0c9677..d3c87bec 100644 --- a/meta-boot2qt/files/qbsp/toolchain_installscript.qs +++ b/meta-boot2qt/files/qbsp/toolchain_installscript.qs @@ -162,7 +162,9 @@ RUN sh *.sh -d /opt/toolchain -y && rm *.sh\n"); "UNDOEXECUTE", "@SDKToolBinary@", "rmCMake", "--id", component.name]); + var deviceId = ""; if (container) { + deviceId = component.name; component.addOperation("Execute", ["@SDKToolBinary@", "addDev", "--id", component.name, @@ -177,14 +179,16 @@ RUN sh *.sh -d /opt/toolchain -y && rm *.sh\n"); "@SDKToolBinary@", "rmDev", "--id", component.name]); } - var addKitOperations = + component.addOperation("Execute", ["@SDKToolBinary@", "addKit", "--id", component.name, "--name", platform, + "--mkspec", "linux-oe-g++", "--qt", component.name, "--debuggerid", component.name, "--sysroot", dockerPrefix + path + "/sysroots/" + sysroot, "--devicetype", "QdbLinuxOsType", + "--builddevice", deviceId, "--Ctoolchain", toolchainId + ".gcc", "--Cxxtoolchain", toolchainId + ".g++", "--cmake", component.name, @@ -194,17 +198,9 @@ RUN sh *.sh -d /opt/toolchain -y && rm *.sh\n"); "--cmake-config", "CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX}", "--cmake-config", "QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable}", "--cmake-config", "CMAKE_TOOLCHAIN_FILE:FILEPATH=" + path + "/sysroots/" + hostSysroot + "/usr/lib/cmake/Qt6/qt.toolchain.cmake", - "--cmake-config", "CMAKE_MAKE_PROGRAM:FILEPATH=" + path + "/sysroots/"+ hostSysroot + "/usr/bin/ninja" + executableExt]; - - if (container) { - addKitOperations.push("--builddevice", component.name); - } - if (!container) { - addKitOperations.push("--mkspec", "linux-oe-g++"); - } - - addKitOperations.push("UNDOEXECUTE", "@SDKToolBinary@", "rmKit", "--id", component.name); - component.addOperation("Execute", addKitOperations); + "--cmake-config", "CMAKE_MAKE_PROGRAM:FILEPATH=" + path + "/sysroots/"+ hostSysroot + "/usr/bin/ninja" + executableExt, + "UNDOEXECUTE", + "@SDKToolBinary@", "rmKit", "--id", component.name]); if (container) { var settingsFile = installer.value("QtCreatorInstallerSettingsFile"); |