From 9698a09782ef97b1140ae8ab35de2f4a1168795b Mon Sep 17 00:00:00 2001 From: Jonathan Bagg Date: Tue, 28 Feb 2017 17:19:34 -0500 Subject: [PATCH] Add Q_DECL_EXPORT / IMPORT --- qtzeroconf.pro | 1 + qzeroconf.h | 13 ++++++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/qtzeroconf.pro b/qtzeroconf.pro index 2d00737..c8da408 100644 --- a/qtzeroconf.pro +++ b/qtzeroconf.pro @@ -7,6 +7,7 @@ include($$PWD/qtzeroconf.pri) TEMPLATE = lib TARGET = $$qtLibraryTarget(QtZeroConf$$QT_LIBINFIX) CONFIG += module create_prl +DEFINES+= QT_BUILD_ZEROCONF_LIB mac:QMAKE_FRAMEWORK_BUNDLE_NAME = $$TARGET target.path = $$PREFIX/lib diff --git a/qzeroconf.h b/qzeroconf.h index a5d64af..c496206 100644 --- a/qzeroconf.h +++ b/qzeroconf.h @@ -30,6 +30,17 @@ #include #include #include +#include + +#ifndef QT_STATIC +# ifdef QT_BUILD_ZEROCONF_LIB +# define Q_ZEROCONF_EXPORT Q_DECL_EXPORT +# else +# define Q_ZEROCONF_EXPORT Q_DECL_IMPORT +# endif +#else +# define Q_ZEROCONF_EXPORT +#endif struct QZeroConfService { @@ -45,7 +56,7 @@ struct QZeroConfService class QZeroConfPrivate; -class QZeroConf : public QObject +class Q_ZEROCONF_EXPORT QZeroConf : public QObject { Q_OBJECT