[SOLVED] I've installed Qt 5.6 but Ubuntu just find Qt 5.2.1
-
Hi, I've installed Qt 5.6 8 weeks ago, and everything is fine.
Then I just need to add a plugin and it doesn't work, and they said that maybe I had an old Qt Version installed in my computer, so in my Ubuntu Terminal i wrote:qtcreator -version
It appears like i've not installed any qt version, so I did the apt-get
sudo apt-get install qtcreator
But now when I look for my Qt version it appears :
carles@carles-ThinkPad-S5-Yoga-15:~$ qtcreator -version Qt Creator 3.0.1 based on Qt 5.2.1
Anyone knows why ubuntu doesn't recognize the 5.6 version?
Thank you very much
-
Hi,
The version of Qt used to build Qt Creator has nothing to do with the version(s) of Qt you'll be using to write your applications.
How did you get that plugin ?
-
Hi SGaist,
I get this plugin (or extension) from GitHub repository: https://github.com/ashish157/QtKnobsFor building this extensions Qt >= 5.3 is required and so it seems I 've just had installed de Qt 5.2.1 it crashes when I do "make".
And sorry, but I not understand at all what you said about Qt versions: When I install Qt Creator, is it possible that any Qt versions was installed in my system (as I said, when I asked for it on terminal, it appears the message saying that "NO Qt version was installed").
Thanks a lot!
-
@carles.sole.grau said:
Hi, I've installed Qt 5.6 8 weeks ago
If you got this from the official qt.io site (e.g. https://www.qt.io/download-open-source/ ), then the installer already gave you a newer version of Qt Creator. You can find the executable in <Qt>/Tools/QtCreator/bin/
-
Hi JKSH, thank you but I was already aware of it,
in fact when I work, I use the Qt Creator 5.6 and it's working properly.The problem is that seems that from the terminal, Ubuntu doesn't recognize this installation.
-
@carles.sole.grau said:
The problem is that seems that from the terminal, Ubuntu doesn't recognize this installation.
That's expected. That is because the terminal will only "recognize" programs that were installed into the Ubuntu system directories. You use the
which
command to find out which version is used by the terminal:carles@carles-ThinkPad-S5-Yoga-15:~$ which qtcreator
Note: You should not install the version that you downloaded into the Ubuntu system directories, because it will conflict with the version that is managed by the Ubuntu Software Center.
If you want to use your newer version of Qt Creator from the terminal, you can specify its full path. For example:
carles@carles-ThinkPad-S5-Yoga-15:~$ /home/carles/Qt/Tools/QtCreator/bin/qtcreator -version
-
It worked! Thanks, now my terminal recognize it:
carles@carles-ThinkPad-S5-Yoga-15:~$ /home/carles/Qt/Tools/QtCreator/bin/qtcreator -version Qt Creator 3.6.1 based on Qt 5.6.0
And so, if I want to install the plugin, how can I specify that I want to do "make" to this version? (when I'm running "qmake", and then "make", it returns error because it's using the Ubuntu system directories version.
Thank you
-
@carles.sole.grau said:
It worked! Thanks, now my terminal recognize it:
Great! :)
And so, if I want to install the plugin, how can I specify that I want to do "make" to this version? (when I'm running "qmake", and then "make", it returns error because it's using the Ubuntu system directories version.
I recommend you open the project in Qt Creator. There, you can select the correct kit to build your plugin.
-
Ok, this step is the one I tried more than once but I don't get it.
Sorry for the ignorance, but, there is somewhere where this steps are explained? (because in the https://github.com/ashish157/QtKnobs, just said Run qmake && make && make install).
I will try it and I will said something.
Thanks a lot!
-
@carles.sole.grau said:
Sorry for the ignorance, but, there is somewhere where this steps are explained? (because in the https://github.com/ashish157/QtKnobs, just said Run qmake && make && make install).
Have you built a project in Qt Creator before? That's the same as running
qmake
andmake
. You just need to open the .pro file in Qt Creator, select Qt 5.6, and build. (See http://doc.qt.io/qtcreator/creator-building-targets.html to get started)For the last step, instead of calling
make install
, you just need to copy the Shared Object (.so) file in Qt Creator's folder. See http://doc.qt.io/qtcreator/adding-plugins.html -
I think that I almost have it.
I have been able to create de .so, but I don't know if I'm copying it in the correct folder because when I execute an example using the plugin:QQmlApplicationEngine failed to load component qrc:/main.qml:4 module "QtKnobs" is not installed
I copy the . so to: '/home/carles/Qt/Tools/QtCreator/lib/qtcreator/plugins/libqtknobsplugin.so'
I will keep on tryingThank you
Than you
-
Well, I finally get it, but for doing the make install, I have need to do it from the terminal on the building directory.
Thank you !