aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Lainé <jeremy.laine@m4x.org>2012-06-07 09:57:41 +0200
committerJeremy Lainé <jeremy.laine@m4x.org>2012-06-07 09:57:41 +0200
commit2b1c240707ed4c7b071a79a84bbcd454a12a5c85 (patch)
treecbd3391a6e02be02d50c9b8558c4198c52b9f749
parent9dfa2fea94bf6eaf0758a1f937cf3de52253b872 (diff)
downloadqxmpp-2b1c240707ed4c7b071a79a84bbcd454a12a5c85.tar.gz
in the absence of QXMPP_STATIC, use shared library import
Since building a shared library is the default, handle the absence of QXMPP_STATIC as meaning QXMPP_SHARED.
-rw-r--r--README4
-rw-r--r--src/base/QXmppGlobal.h6
2 files changed, 7 insertions, 3 deletions
diff --git a/README b/README
index 333ba73d..35d15a73 100644
--- a/README
+++ b/README
@@ -26,6 +26,10 @@ You can pass the following arguments to qmake:
QXMPP_USE_THEORA=1 to enable theora video codec
QXMPP_USE_VPX=1 to enable vpx video codec
+Note: by default QXmpp is built as a shared library. If you decide to build
+a static library instead, you will need to pass -DQXMPP_STATIC when building
+your programs against QXmpp.
+
Building using Qt Creator:
Open the qxmpp.pro file in Qt Creator and hit "Build All" to build all
diff --git a/src/base/QXmppGlobal.h b/src/base/QXmppGlobal.h
index 0e9afb3a..fa44cfbd 100644
--- a/src/base/QXmppGlobal.h
+++ b/src/base/QXmppGlobal.h
@@ -27,14 +27,14 @@
#include <QString>
-#if defined(QXMPP_SHARED)
+#if defined(QXMPP_STATIC)
+# define QXMPP_EXPORT
+#else
# if defined(QXMPP_BUILD)
# define QXMPP_EXPORT Q_DECL_EXPORT
# else
# define QXMPP_EXPORT Q_DECL_IMPORT
# endif
-#else
-# define QXMPP_EXPORT
#endif
/// This macro expands a numeric value of the form 0xMMNNPP (MM =