Qt6 QML Book/Qt Creator IDE/注册Qt开发套件

Registering your Qt Kit

注册Qt开发套件

The Qt Kit is probably the most difficult aspect when it comes to working with Qt Creator initially. A Qt Kit is a set of a Qt version, compiler and device and some other settings. It is used to uniquely identify the combination of tools for your project build. A typical kit for the desktop would contain a C++ compiler and a Qt version (e.g. Qt 6.xx.yy) and a device (“Desktop”). After you have created a project you need to assign a kit to a project before Qt Creator can build the project. Before you are able to create a kit first you need to have a compiler installed and have a Qt version registered. A Qt version is registered by specifying the path to the qmake executable. Qt Creator then queries qmake for information required to identify the Qt version. This is also true for Qt 6 where CMake is the preferred build tool.

Qt开发套件可能是初用Qt Creator时最难搞的。Qt开发套件是的配置包括Qt版本、编译器、设备和其他配置。它惟一标识项目构建的工具包。一个典型的桌面开发套件包含c++编译器和Qt版本(例如Qt 6.xx.yy)和设备(桌面)。创建项目后,需要在Qt Creator构建前指定项目开发套件。在创建开发套件前,需安装编译器并注册Qt版本。通过指定qmake可执行文件路径来注册Qt版本。Qt Creator会查询qmake以获取Qt版本所需信息。对于Qt 6也是这样,推荐使用CMake是作为首选构建工具。

Adding a kit and registering a Qt version is done in the Settings ‣ Build & Run entry. There you can also see which compilers are registered.

在设置构建和运行处,选择开发套件、注册Qt版本。这里也可以看到注册的编译器。

TIP

Please first check if your Qt Creator has already the correct Qt version registered and then ensure a Kit for your combination of compiler and Qt and device is specified. You can not build a project without a kit.

编译前,请先检查Qt Creator是否已经注册了正确的Qt版本,然后确保开发套件使用了正确的编译器、Qt版本和设备。没有开发套件你无法构建项目。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值