Using QCA with Qt5 -- How?
-
I'm trying to upgrade one of my applications from GTK+ 2 to Qt5 (because GTK 3 doesn't bear thinking about). One of the last major hurdles involves PGP/GPG encryption.
I'm running Debian testing, and libqca2 comes with it, so I don't need to build the library from scratch. What I do need to know, however, are these:
- The documentation says to use "#include <QtCrypto>", which makes sense, except that it doesn't work. I get "QtCrypto: No such file or directory". How do I get past this?
- What do I put in the .pro file in the "QT +=" line? I've tried "crypto", "qtcrypto", "qca", "qca2" and others, but nothing works. I can't find anything in the documentation that covers this.
- Are there any other tricks I should know?
Thanks,
.....Ron
-
Thanks. I was hoping to avoid that, but it seems necessary. With autoconf, you can use pkg-config to get past that, but Qt doesn't seem to have that facility.
It was complicated by the fact that the locate system in my Debian box can't locate QtCrypto, even though I know it's there.
Anyway, it turns out that I need#include <Qca-qt5/QtCrypto/QtCrypto>
Ugly, but it works.
Now the only thing I need is what to put in the .pro file in the QT+= line. Any ideas?
-
@rjmx said in Using QCA with Qt5 -- How?:
but Qt doesn't seem to have that facility.
Since Qt is a c++ library I would be surprised if there is a pkg-config c++ whatever.
You most likely mean the build system. For cmake see FindPkgConfig.cmake for qmake e.g. here: https://forum.qt.io/post/699604