QT 6.2.4对于Ubuntu上的QNX710 20.04 -QT版本未正确安装
我尝试构建 Qt 6.2.4,通过 qt-unified-linux-x64-4.3.0-1-online.run 在 Virtual Box 中的 Ubuntu 20.04 LTS 上安装。
我在 ~/Qt6 for Desktop gcc 64 位和源代码中安装了 Qt 6.2.4。
QNX 7.1 安装在 ~/qnx710 中。
我获取了 qnxsdp-env.sh:
$ . ~/qnx710/qnxsdp-env.sh
我将 Qt6.2.4、Ninja 和 CMake 添加到了 PATH:
$ export PATH=$PATH:~/Qt6/6.2.4/gcc_64/bin
$ export PATH=$PATH:~/Qt6/Tools/Ninja
$ export PATH=$PATH:~/Qt6/Tools/CMake/bin
从 https://doc.qt.io/qt-6/building-qt-for-qnx.html#creating-a-toolchain-file-for-qnx
$ cat ~/cmake_support/toolchains/qnx.aarch64le.cmake
set(CMAKE_SYSTEM_NAME QNX)
set(arch gcc_ntoaarch64le)
set(CMAKE_C_COMPILER qcc)
set(CMAKE_C_COMPILER_TARGET ${arch})
set(CMAKE_CXX_COMPILER q++)
set(CMAKE_CXX_COMPILER_TARGET ${arch})
set(CMAKE_SYSROOT $ENV{QNX_TARGET})
创建了构建目录并配置了qt:
$ mkdir ~/Qt6/6.2.4/qnx_build
$ cd ~/Qt6/6.2.4/qnx_build
$ cmake -GNinja -DCMAKE_TOOLCHAIN_FILE=~/cmake_support/toolchains/qnx.aarch64le.cmake -DQT_HOST_PATH=~/Qt6/6.2.4/gcc_64 -DCMAKE_INSTALL_PREFIX=~/Qt6/6.2.4/qnx ../Src
编译并安装
$ cmake --build . --parallel && cmake --install .
这一切都很顺利。
然后我尝试将新的 Qt 版本添加到 Qt Creator,但是由于 Qt 版本未正确安装而失败,请运行 make install。 详细信息:Qt 版本无效。
当然,一旦创建了套件,它就会失败并且无法使用。
知道如何解决这个问题吗?
I tried to build Qt 6.2.4, installed via qt-unified-linux-x64-4.3.0-1-online.run on Ubuntu 20.04 LTS in a Virtual Box.
I installed Qt 6.2.4 in ~/Qt6 for Desktop gcc 64-bit and in source code.
QNX 7.1 is installed in ~/qnx710.
I sourced qnxsdp-env.sh:
$ . ~/qnx710/qnxsdp-env.sh
I added Qt6.2.4, Ninja and CMake to PATH:
$ export PATH=$PATH:~/Qt6/6.2.4/gcc_64/bin
$ export PATH=$PATH:~/Qt6/Tools/Ninja
$ export PATH=$PATH:~/Qt6/Tools/CMake/bin
Copied the qnx.cmake example from https://doc.qt.io/qt-6/building-qt-for-qnx.html#creating-a-toolchain-file-for-qnx
$ cat ~/cmake_support/toolchains/qnx.aarch64le.cmake
set(CMAKE_SYSTEM_NAME QNX)
set(arch gcc_ntoaarch64le)
set(CMAKE_C_COMPILER qcc)
set(CMAKE_C_COMPILER_TARGET ${arch})
set(CMAKE_CXX_COMPILER q++)
set(CMAKE_CXX_COMPILER_TARGET ${arch})
set(CMAKE_SYSROOT $ENV{QNX_TARGET})
Created a build directory and configured qt:
$ mkdir ~/Qt6/6.2.4/qnx_build
$ cd ~/Qt6/6.2.4/qnx_build
$ cmake -GNinja -DCMAKE_TOOLCHAIN_FILE=~/cmake_support/toolchains/qnx.aarch64le.cmake -DQT_HOST_PATH=~/Qt6/6.2.4/gcc_64 -DCMAKE_INSTALL_PREFIX=~/Qt6/6.2.4/qnx ../Src
Compile and install
$ cmake --build . --parallel && cmake --install .
This all went fine.
Then I tried to add the new Qt Version to Qt Creator, but this fails with Qt version is not properly installed, please run make install.
Details: Invalid Qt version.
And of course, once creating a kit, it fails and can't be used.
Any idea how to fix this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
QT版本确实未正确安装。
Qmake期望目标库的特定目录,
因此要修复QT创建者,我只需要创建一个符号链接:
The Qt version was indeed not properly installed.
qmake expects a specific directory for target libraries
So to fix QT Creator, I simply had to create a symbolic link: