Streamlined Qt CLI installation

In Qt Online Installer 4.0, an option was introduced to install the Qt framework and tools using a command line interface (CLI). This enables installation of the components without a graphical interface, and also without user interaction. However, knowing the correct installable package names can be challenging, and listing all the required add-ons, sources, tools, etc. requires a lot of effort. That is why we have improved the command line installation by introducing alias installation in Qt Online Installer 4.8.

Alias installation guide

Since Qt Online Installer version 4.8.0, you can use alias packages to install the most common configurations. Alias packages are a shortcut to include the actual packages for an easier installation experience. For example command

qt-online-installer-windows-x64-4.8.0.exe install qt6.8.0-sdk

will install Qt 6.8.0-related win64_mingw binaries, add-ons, sources and extensions, together with QtCreator and related tools.

You can still install individual packages as before. If the argument given to command install is not found from alias list, installer will automatically start to search for relevant individual package. You can also force the commands to use either alias or individual package name by typing --type alias, or --type package.
for example

qt-online-installer-windows-x64-4.8.0.exe install qt6.8.0-sdk --type alias

You can also search available aliases and check what it contains:

qt-online-installer-windows-x64-4.8.0.exe search 6.8.0

gives output (snipped):

Name: qt6.8.0-essentials-dev
Display name: Qt 6.8.0 (Beta4) Windows x86_64 Essential Components (dev)
Description: Qt 6.8.0 (Beta4) Windows x86_64 Essential Libraries, Headers, and Tools (dev)
Version: 6.8.0
Components:
Required aliases: qt6.8.0-essentials
Optional components:
Optional aliases:
========================================
Name: qt6.8.0-full
Display name: Qt 6.8.0 (Beta4) Windows x86_64 All Components with Sources
Description: Qt 6.8.0 (Beta4) Windows x86_64 All Libraries, Headers, Tools, and Sources
Version: 6.8.0
Components: qt.qt6.680.src,extensions.qtwebengine.680.src
Required aliases: qt6.8.0-essentials,qt6.8.0-addons,qt6.8.0-extensions
Optional components: extensions.qtinsighttracker.680.src
Optional aliases:

The mandatory license acceptance, dialog confirmations etc. still apply, so installation without user interaction would be:

qt-online-installer-windows-x64-4.8.0.exe --root C:\Qt\installation_dir --accept-licenses 
--default-answer --confirm-command install qt6.8.0-full-dbg

 


Documentation about command line usage can be found from Get and Install Qt with Command Line Interface

Happy installing!


Blog Topics:

Comments