Thursday, May 2, 2024
 Popular · Latest · Hot · Upcoming
22
rated 0 times [  22] [ 0]  / answers: 1 / hits: 33939  / 2 Years ago, sat, october 1, 2022, 5:01:47

I want to build applications requiring Qt5 via CMake.



Which libraries do I have to install to achieve that?



What I have tried so far is searching for anything containing qt 5 core and dev, but have turned up empty:



apt-cache search qt | grep dev | grep core


only returns



libtulip-dev - Tulip graph library - core development files


The only thing seeming half-way to fit is "libqt5core5a", but installing that doesn't provide any development libraries...



Do I need any additional repositories? The ones from Kubuntu maybe?



Searching the web didn't yet give me any proper answers too (probably not the right keywords, I know, but :o). I e.g. found this question: What package do I need to build a Qt 5 & CMake application?, but there is no qtcore5-dev package in trusty repositories it seems...



Edit: Upon further experimenting, I did have qmake installed, but the 4.8.6 version (qt4-qmake). Trying to install the 5.x version brought no joy, though - (sudo apt-get purge qt4-qmake && sudo apt-get install qt5-qmake) - qmake now reports:



qmake: could not exec '/usr/lib/x86_64-linux-gnu/qt4/bin/qmake': No such file or directory


Is there something broken in the repositories here?


More From » 14.04

 Answers
3

Seems



> apt-file search Qt5CoreConfig.cmake


was what I was missing. This got me



qtbase5-dev: /usr/lib/x86_64-linux-gnu/cmake/Qt5Core/Qt5CoreConfig.cmake


Installing that seems to lead to CMake finding Qt5. qmake still reports the same problem when directly called though...some remnant from qt4 still installed it seems...



Edit: As for the qmake problem, this is fixed by



sudo apt-get install qt5-default

[#22714] Sunday, October 2, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
huovie

Total Points: 234
Total Questions: 99
Total Answers: 105

Location: Central African Republic
Member since Sun, Feb 26, 2023
1 Year ago
huovie questions
Mon, Aug 2, 21, 01:46, 3 Years ago
Thu, Feb 2, 23, 10:58, 1 Year ago
Thu, Oct 21, 21, 08:55, 3 Years ago
Sun, Dec 5, 21, 23:57, 2 Years ago
;