diff options
| author | Jeremy Lainé <jeremy.laine@m4x.org> | 2012-04-21 16:10:49 +0000 |
|---|---|---|
| committer | Jeremy Lainé <jeremy.laine@m4x.org> | 2012-04-21 16:10:49 +0000 |
| commit | 3618c4e248bc1aba1028f3c4ba0cfd8eecbe716d (patch) | |
| tree | 6767751d7c2def925588d5440b79591ab426e1e8 | |
| parent | bab569167711d4eb8175d1148d0e672c9435f4fd (diff) | |
| download | qxmpp-3618c4e248bc1aba1028f3c4ba0cfd8eecbe716d.tar.gz | |
fix win32 shared library linking
| -rw-r--r-- | qxmpp.pri | 21 |
1 files changed, 11 insertions, 10 deletions
@@ -4,12 +4,18 @@ QT += network xml QXMPP_VERSION = 0.4.0 QXMPP_INCLUDEPATH = $$PWD/src/base $$PWD/src/client $$PWD/src/server +# Determine library name CONFIG(debug, debug|release) { QXMPP_LIBRARY_NAME = qxmpp_d } else { QXMPP_LIBRARY_NAME = qxmpp } +# Determine library type (lib or staticlib) +isEmpty(QXMPP_LIBRARY_TYPE) { + QXMPP_LIBRARY_TYPE = staticlib +} + # Libraries used internally by QXmpp android { @@ -25,24 +31,19 @@ android { } # Libraries for apps which use QXmpp -symbian { +QXMPP_LIBS = -l$${QXMPP_LIBRARY_NAME} +contains(QXMPP_LIBRARY_TYPE,staticlib) { # Symbian needs a .lib extension to recognise the library as static - QXMPP_LIBS = -l$${QXMPP_LIBRARY_NAME}.lib -} else { - QXMPP_LIBS = -l$${QXMPP_LIBRARY_NAME} -} + symbian: QXMPP_LIBS = -l$${QXMPP_LIBRARY_NAME}.lib -# Determine library type (lib or staticlib) -isEmpty(QXMPP_LIBRARY_TYPE) { - QXMPP_LIBRARY_TYPE = staticlib -} -contains(QXMPP_LIBRARY_TYPE,staticlib) { # FIXME: we should be able to use the link_prl option to automatically pull # in the extra libraries which the qxmpp library needs, but this does not # seem to work on win32, so we specify the dependencies here: QXMPP_LIBS += $$QXMPP_INTERNAL_LIBS DEFINES += QXMPP_STATIC } else { + # Windows needs the major library version + win32: QXMPP_LIBS = -l$${QXMPP_LIBRARY_NAME}0 DEFINES += QXMPP_SHARED } |
