do not introduce QtCore4 in ssl.pri

It is not correct to add QtCore4 in ssl.pri when -lz is removed
for qt-zlib.

In mingw-cross-env we add QtCore4 to OPENSSL_LIBS so the zlib
dependency of openssl is satisfied in case of qt-zlib. This
is necessary for the time being because the QtCore4 in the link
command that qmake generates appears before the contents of
OPENSSL_LIBS.
This commit is contained in:
Mark Brand 2010-02-21 11:14:53 +01:00
parent ac9c343857
commit 7f68c53a0b
2 changed files with 10 additions and 11 deletions

View File

@ -501,20 +501,17 @@ index aa36890..f009761 100644
+ win32:!win32-g++:LIBS += zdll.lib
}
diff --git a/src/network/ssl/ssl.pri b/src/network/ssl/ssl.pri
index 72ea80f..899aa30 100644
index 72ea80f..cf31a5b 100644
--- a/src/network/ssl/ssl.pri
+++ b/src/network/ssl/ssl.pri
@@ -35,5 +35,11 @@ symbian {
@@ -34,6 +34,7 @@ symbian {
# Include Qt's default CA bundle
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
+ }
- # Add optional SSL libs
+ # Add optional SSL libs, but not accidently system zlib
+ !contains(QT_CONFIG, system-zlib):OPENSSL_LIBS -= -lz
LIBS_PRIVATE += $$OPENSSL_LIBS
+
}
diff --git a/src/plugins/imageformats/jpeg/jpeg.pro b/src/plugins/imageformats/jpeg/jpeg.pro
index ebc79cc..30a19c6 100644

View File

@ -93,9 +93,11 @@ define $(PKG)_BUILD
# We prefer static mingw-cross-env system libs for static build:
# -system-zlib -system-libpng -system-libjpeg -system-libtiff -system-libmng -system-sqlite
# There is no -system-gif option. NB -system-libmng will not link in shared build.
# Linking PSQL shared plugin requires PSQL_LIBS. Harmless for static build.
# Linking QtNetwork4.dll requires OPENSSL_LIBS. Harmless for static build.
# QtCore4 provides qt-zlib to openssl. Harmless for system-zlib.
# Linking qsqlpsql4.dll plugin requires PSQL_LIBS. Harmless for static build.
cd '$(1)' && \
OPENSSL_LIBS="`'$(TARGET)-pkg-config' --libs-only-l openssl`" \
OPENSSL_LIBS="`'$(TARGET)-pkg-config' --libs-only-l openssl` -lQtCore4" \
PSQL_LIBS="-lpq -lsecur32 `'$(TARGET)-pkg-config' --libs-only-l openssl`" ./configure \
-opensource \
-confirm-license \