diff options
author | Mark Brand <mabrand@mabrand.nl> | 2010-02-17 15:56:48 (GMT) |
---|---|---|
committer | Mark Brand <mabrand@mabrand.nl> | 2010-02-17 15:56:48 (GMT) |
commit | 754f8ef7c327378ee4f1d15c0a391d56ca71365c (patch) | |
tree | a2eaa31f3eb7a5cbf22b0cf91f8035b3e10e63e1 /src/qt-win32.patch | |
parent | 644262b03338e2a4e93b1c9b40b3e77a925a0864 (diff) | |
download | mxe-754f8ef7c327378ee4f1d15c0a391d56ca71365c.zip mxe-754f8ef7c327378ee4f1d15c0a391d56ca71365c.tar.gz mxe-754f8ef7c327378ee4f1d15c0a391d56ca71365c.tar.bz2 |
simplified linking to openssl in package qt
We have been building Qt with "-openssl-linked". A patch was needed to adjust
OPENSSL_LIBS to keep a shared Qt build from failing at the point where
QtNetwork4.dll is linked. The patch is not needed if we use "-openssl" instead.
Because libssl and its dependencies are static libraries in mingw-cross-env,
a simple "-openssl" also causes libssl and dependencies to be embedded
(imported) into QNetwork4.dll, but it does so without requiring the patch.
Details:
The patch solved a problem that is a feature of a specific recipe of
Qt build ingredients:
(1) -shared
(2) -openssl-linked
(3) -qt-zlib
in an environment were:
(4) openssl is static
(5) “system” zlib is static
At least 1-3 are needed to see the problem. I suspect that 4 and 5 are needed as
well.
What I think I understand:
“-shared” means that QtNetwork4.dll will be built, which is the locus of the
problem.
“-openssl-linked” means that libssl and its dependencies are to be embedded in
QtNetwork4.dll. OPENSSL_LIBS supplies the list of dependencies.
“-qt-zlib” means that QtCore4 contains a zlib implementation.
Given this recipe for QtNetwork4.dll, the zlib implementation of “-lz” conflicts
with the zlib implementation of “-lQtCore4”.
The patch removed "-lz" from OPENSSL_LIBS and replaced it with "-lQtCore" in the
same position. Adding "-lQtCore" in this way is not a robust solution. For example,
it will break a debug build.
Diffstat (limited to 'src/qt-win32.patch')
-rw-r--r-- | src/qt-win32.patch | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/src/qt-win32.patch b/src/qt-win32.patch index 613f897..cbcca2f 100644 --- a/src/qt-win32.patch +++ b/src/qt-win32.patch @@ -547,22 +547,6 @@ index aa36890..f009761 100644 + unix|win32-g++:LIBS_PRIVATE += -lz + win32:!win32-g++:LIBS += zdll.lib } -diff --git a/src/network/ssl/ssl.pri b/src/network/ssl/ssl.pri -index 72ea80f..899aa30 100644 ---- a/src/network/ssl/ssl.pri -+++ b/src/network/ssl/ssl.pri -@@ -35,5 +35,11 @@ symbian { - RESOURCES += network.qrc - - # Add optional SSL libs -+ !contains(QT_CONFIG, system-zlib):contains(OPENSSL_LIBS, -lz) { -+ # Use the zlib in QtCore -+ OPENSSL_LIBS -= -lz -+ OPENSSL_LIBS += -lQtCore4 -+ } - LIBS_PRIVATE += $$OPENSSL_LIBS -+ - } diff --git a/src/plugins/imageformats/jpeg/jpeg.pro b/src/plugins/imageformats/jpeg/jpeg.pro index ebc79cc..30a19c6 100644 --- a/src/plugins/imageformats/jpeg/jpeg.pro |