Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to find Version of Qt?

How do I know which version of Qt I am using? When I open Qt Creator it shows "Welcome to Qt Creator 2.3". In the build setting, however, it shows Qt Version 4.7.1.

like image 918
user3472783 Avatar asked Apr 14 '14 11:04

user3472783


People also ask

How do I find my Qt version?

Qt Creator automatically detects the Qt versions that are registered by your system or by installers. To view detailed information for each Qt version, select it in the list and select Details in the Qt version for section. To add Qt versions, select Tools > Options > Build & Run > Qt Versions.

How do you check if I have Qt installed?

That being said, under a Linux system we can simply use the following script to determine whether Qt is installed: if ! test -x /usr/bin/qmake then # The Qt library is missing... echo "error: This script requires Qt to be installed." exit 1 fi # The Qt library is installed ...do your thing...

How do I find my Qt version Mac?

When running /usr/sbin/system_profiler SPFrameworksDataType, the version of the QTkit is 7.6. 6. The value of the macro QT_VERSION_STR in qglobal.

Where Qt is installed Linux?

For the per user install, the default installation will be a subdirectory called Qt in the current working directory. For the global install, the default location is /opt/Qt.


2 Answers

qmake-qt5 --version

or

qmake --version

like image 62
Geremia Avatar answered Oct 04 '22 05:10

Geremia


Starting with Qt 5.3 you can use:

qtdiag 

This prints a bunch of useful information. The first line includes the version:

Qt 5.5.1 (x86_64-little_endian-lp64 shared (dynamic) release build; by GCC 5.3.1 20160407) on "xcb"  
like image 27
David Avatar answered Oct 04 '22 06:10

David