Currently qca links to the Carbon framework for building however the mac
specific code don't use any Carbon classes but CoreFoundation. This patch
aims to update the code and build script to link to the more generic
CoreFoundation framework which may also allow to build it on iOS (not
verified).
REVIEW: 121703
This solves a build failure with compilers such as GCC 4.2:
/usr/local/include/QtCrypto/qca_basic.h:598: error: comma at end of enumerator list
REVIEW: 122107
The previous code (present since the file was created) mixed different
checks that required different expansions:
* `if (ENV{foo})' will always evaluate to false even if $ENV{foo} is
set, and may even be a CMake bug.
* `if (EXISTS ...)' expects an actual string, not an variable that has
not been expanded.
It is not clear why the code expects QC_CERTSTORE_PATH to be an
environment variable instead of a regular variable passed to CMake in
the first place, but that can be changed in another commit.
REVIEW: 122062
It's not properly. Martin Klapetek is not QCA developer. So it's not
correct that he said "Ship it!".
Properly way
cmake -DQCA_SUFFIX=qt5 ...
and in CMakeLists.txt of your project.
find_package(Qca NAMES Qca-qt5)
This reverts commit c32bc6f1bc9befe5f89d3572eb28e0d591a2e3b2.
- if QT4_BUILD is not defined *and* Qt5Core is found build with soname
qca-qt5
- rename cmake package to reflect the suffix i.e. with a Qt5 build it is
find_package(Qca-qt5) rather than find_package(Qca)
- the imported cmake target also reflects suffix so "Qca-qt5" is the
cmake link target for qt5 and "Qca" for qt4 builds
this retains 100% compatibility with regular qca while also offering 100%
coinstallability of the qt5 build.
REVIEW: 121633
(this also fixes the flaky filewatch test that would fail for example on
ubuntu launchpad builds)
it can happen that (supposedly for filesystem reasons) there are two
changes signals arriving in the watcher code, by the time the first arrives
the file would however already be deleted, by the time the second arrives
it would thus notify of changes to a file that does not exist which is
silly and causes problems with the filewatchtest as it uses signal emission
counting to verify the behavior.
to prevent this problem from popping up there is an additional save guard
in the file_changed slot that will ignore a change if the path in question
doesn't exist AND there is no file being watched by the watcher.
REVIEW: 121588
On arm is not correct to do int* = char* and throw warning. int must
be aligned unlike i686 and x86_64 archs. Anyway the old way to init
structs is not sane.
Many linux distribution provides both version of Qt: Qt4 and Qt5.
These versions are binary is incompatible and any qt-based library
compiled against such Qt versions will be binary incompatible with
one another. In common case library name must not be related with
based libraries. In our case Linux users want to have both versions
QCA installed in their system. I will do not implicity rename Qt5
based QCA but just warn user and allow him explicity set QCA_SUFFIX.
libressl removed the SSL Compression functionality (which might
be considered insecure) and thus also compress_meth.
SSL_SESSION_get_compress_id is just a stub in libressl which always
returns 0 and in openssl it returns compress_meth.
REVIEW: 121107