Difference between revisions of "Installing Qt binary packages"

From GeopsyWiki
Jump to navigation Jump to search
 
(18 intermediate revisions by the same user not shown)
Line 1: Line 1:
Note that Geopsy package is developed and tested with Qt 4.5.0 or higher. At the time of writing this documentation, Qt 4.5.0 is not the standard version of most of the distribution listed here below. It will not be the case in a close future.
+
Note that Geopsy package (3.5.0) is developed and tested with Qt 5.15.2 and Qt 6.5. Successful builds were reported with Qt 5.11. Error were encountered with Qt 5.9. If a sufficiently recent Qt is not available on your platform you can follow this tutorial to install binaries provided directly from [https://qt.io Qt].
  
== Ubuntu ==
+
== Downloading online installer ==
  
''TODO: graphical presentation''
+
[https://qt.io qt.io] is a fancy commercial website but not really handy to get access to the open-source Qt package
  
== Gentoo ==
+
* Go to [https://qt.io Qt]
 +
* Click on "Download. Try. Buy" green button in the top right corner
 +
* Scroll down to "Download open source"
 +
* Scroll down to bottom of the page
 +
* Click on "Download the Qt Online Installer" green button
 +
* Select your platform and click on "Qt Online Installer for ..."
  
Install Qt:
+
Great you have the file. Simple no?
  
  emerge -av qt
+
== Change permissions and run the installer ==
  
You can wait for half an hour or so. Then, you are ready to install geopsy software. At the present time, to get Qt 4.5.1, you have to accept unstable keywords.
+
* Change permission to be able to execute it (for Linux)
  
   ACCEPT_KEYWORDS="~x86" emerge -av qt
+
   $ chmod a+x qt-unified-linux-x64-4.0.0-online.run
  
or
+
* And start the installer
  
   ACCEPT_KEYWORDS="~xamd64" emerge -av qt
+
   $ ./qt-unified-linux-x64-4.0.0-online.run
  
== Fedora ==
+
* Under Windows, double-click on the .exe file
  
''TODO: graphical presentation''
+
* You have to create a Qt account (as simple as breathing, isn't it?), if you have already one enter your credentials.
 +
* Click on "Next"
 +
* Certify that you have read and approve the obligations of using Open Source Qt
 +
* Click on "Next"
 +
* You receive a great "Welcome", nothing to do
 +
* Click on "Next"
 +
* Make your choice if you want or not to send pseudonymous,... it is up to you
 +
* Click on "Next"
 +
* A very important step: select the destination path, choose it carefully. It is better to avoid moving or renaming it later on.
 +
* Select "Custom installation"
 +
* Click on "Next"
 +
* Select only these components:
 +
  Qt
 +
    Qt 5.15.2 (or higher)
 +
  Developer and Designer Tools
 +
    Qt Creator 9.0.1 (or higher)
 +
    MinGW 8.1.0 64-bit (or higher)
 +
* Accept the license
 +
* Click on "Next"
 +
* Click on "Install"
  
Tested on Fedore Core 10 for i386 target.
+
Now the the real installation starts. It may last a little bit.
  
Package to install:
+
== The final touch ==
  
qt-devel
+
Qt and the whole Qt Creator development environment is now installed.
  
By default, Qt 4 on Fedora comes with suffix ''-qt4'' added to development tools (qmake, lrelease,...)
+
  $ ls /path/you/chose/for/Qt
The best option is to define alias in your profile or symbolic links to these binaries
+
    5.14.2          dist  Examples            installer.dat      Licenses        MaintenanceTool.dat  network.xml  Tools
 +
    components.xml  Docs  InstallationLog.txt  installerResources  MaintenanceTool  MaintenanceTool.ini  QtIcon.png
  
cd
+
The interesting part of Qt is in folder 5.14.2 (or another version)
test -d bin || mkdir bin
 
cd bin
 
ln -s /usr/bin/qmake-qt4 qmake
 
ln -s /usr/bin/lrelease-qt4 lrelease
 
  
Add ''~/bin'' to you PATH ([[Setting PATH variable|more information]])
+
  $ ls /path/you/chose/for/Qt/5.14.2/gcc_64
 +
    bin/          include/      mkspecs/      plugins/      translations/
 +
    doc/          lib/          phrasebooks/  qml/
  
Check that ''qmake'' is available.
+
'qmake' building tool is in 'bin'. Add this path to your PATH
  
qmake -v
+
  export PATH=/path/you/chose/for/Qt/5.14.2/gcc_64/bin:$PATH
  
== open SUSE ==
+
If you do not want to pollute your .bashrc, create a file "env" where you intend to build geopsypack:
  
''TODO: graphical presentation''
+
  #!/bin/bash
 +
  export PATH=/path/you/chose/for/Qt/5.14.2/gcc_64/bin:$PATH
 +
 
 +
Whenever you want to start building geopsypack, source this file.
 +
 
 +
  source ./env

Latest revision as of 08:26, 18 September 2023

Note that Geopsy package (3.5.0) is developed and tested with Qt 5.15.2 and Qt 6.5. Successful builds were reported with Qt 5.11. Error were encountered with Qt 5.9. If a sufficiently recent Qt is not available on your platform you can follow this tutorial to install binaries provided directly from Qt.

Downloading online installer

qt.io is a fancy commercial website but not really handy to get access to the open-source Qt package

  • Go to Qt
  • Click on "Download. Try. Buy" green button in the top right corner
  • Scroll down to "Download open source"
  • Scroll down to bottom of the page
  • Click on "Download the Qt Online Installer" green button
  • Select your platform and click on "Qt Online Installer for ..."

Great you have the file. Simple no?

Change permissions and run the installer

  • Change permission to be able to execute it (for Linux)
 $ chmod a+x qt-unified-linux-x64-4.0.0-online.run
  • And start the installer
 $ ./qt-unified-linux-x64-4.0.0-online.run
  • Under Windows, double-click on the .exe file
  • You have to create a Qt account (as simple as breathing, isn't it?), if you have already one enter your credentials.
  • Click on "Next"
  • Certify that you have read and approve the obligations of using Open Source Qt
  • Click on "Next"
  • You receive a great "Welcome", nothing to do
  • Click on "Next"
  • Make your choice if you want or not to send pseudonymous,... it is up to you
  • Click on "Next"
  • A very important step: select the destination path, choose it carefully. It is better to avoid moving or renaming it later on.
  • Select "Custom installation"
  • Click on "Next"
  • Select only these components:
 Qt
   Qt 5.15.2 (or higher)
 Developer and Designer Tools
   Qt Creator 9.0.1 (or higher)
   MinGW 8.1.0 64-bit (or higher)
  • Accept the license
  • Click on "Next"
  • Click on "Install"

Now the the real installation starts. It may last a little bit.

The final touch

Qt and the whole Qt Creator development environment is now installed.

 $ ls /path/you/chose/for/Qt
   5.14.2          dist  Examples             installer.dat       Licenses         MaintenanceTool.dat  network.xml  Tools
   components.xml  Docs  InstallationLog.txt  installerResources  MaintenanceTool  MaintenanceTool.ini  QtIcon.png

The interesting part of Qt is in folder 5.14.2 (or another version)

 $ ls /path/you/chose/for/Qt/5.14.2/gcc_64
    bin/          include/      mkspecs/      plugins/      translations/ 
    doc/          lib/          phrasebooks/  qml/ 

'qmake' building tool is in 'bin'. Add this path to your PATH

 export PATH=/path/you/chose/for/Qt/5.14.2/gcc_64/bin:$PATH

If you do not want to pollute your .bashrc, create a file "env" where you intend to build geopsypack:

 #!/bin/bash
 export PATH=/path/you/chose/for/Qt/5.14.2/gcc_64/bin:$PATH

Whenever you want to start building geopsypack, source this file.

 source ./env