Problems when adding serialport module in Qt project
-
@aha_1980 Done, I found the qmake for version 5 and run the qmake command.
Now, when I run themake make install
this error appears:
fatal error: qdeadlinetimer.h: File o directory non esistente compilation terminated.
Which can be the solution?
-
@douglas Looks good so far.
But let's move slowly. I re-read you post from 5 hours ago:
@aha_1980 Thanks. In Qt Creator I set Qt 5.7.1 in the "Qt Version" for the selected kit for my project. Now I can add the serialport module in my .pro file and build the app
If you can build the app, then you already have the serialport module!
but when I try to run it on my target device, the application does not start and the following error appears:
But you don't have the libraries on your target device.
-
@douglas In the most easy and hacky way, just copy the needed *.so files to the other Qt *.so files on your device.
Depending on your cross toolchain, there may be a more clean way (like building a new image), but that - as said - depends on you toolchain.
-
-
@Pablo-J.-Rogina , @aha_1980 thank you. I expected to find the libQt5SerialPort.so.5 (the missing library) inside the qtserialport folder generated after the steps:
$ git clone git://code.qt.io/qt/qtserialport.git $ mkdir qtserialport-build $ cd qtserialport-build $ qmake ../qtserialport/qtserialport.pro
but I couldn't find it. I searched into my host PC for that file, I found few results, but they are located into the Qt installation folder, they are not cross-compiled for my needs, I think.
When exactly that library should be created, or where it should be located?
Thanks!