From bc77f671ae93f4ea396c9cdaccc7b29fbd8aab1f Mon Sep 17 00:00:00 2001 From: Josef Rokos Date: Tue, 9 Feb 2016 10:33:08 +0100 Subject: [PATCH] Fixed MSVS build. --- core/core.pro | 3 ++- core/data/core_global.h | 12 ++++++++++++ core/data/permission.h | 3 ++- core/data/role.h | 3 ++- core/data/user.h | 3 ++- 5 files changed, 20 insertions(+), 4 deletions(-) create mode 100644 core/data/core_global.h diff --git a/core/core.pro b/core/core.pro index 0dd72c2..bdd8b7e 100644 --- a/core/core.pro +++ b/core/core.pro @@ -81,7 +81,8 @@ HEADERS += core.h\ samestringvalidator.h \ savefilterdialog.h \ filterdialog.h \ - itablemodel.h + itablemodel.h \ + data/core_global.h unix { target.path = /usr/lib diff --git a/core/data/core_global.h b/core/data/core_global.h new file mode 100644 index 0000000..b519481 --- /dev/null +++ b/core/data/core_global.h @@ -0,0 +1,12 @@ +#ifndef CORE_GLOBAL_H +#define CORE_GLOBAL_H + +#include + +#if defined(CORE_LIBRARY) +# define CORESHARED_EXPORT Q_DECL_EXPORT +#else +# define CORESHARED_EXPORT Q_DECL_IMPORT +#endif + +#endif // CORE_GLOBAL_H diff --git a/core/data/permission.h b/core/data/permission.h index c6dcfca..ba6b1c7 100644 --- a/core/data/permission.h +++ b/core/data/permission.h @@ -2,6 +2,7 @@ #define PERMISSION_H #include "core-data.h" +#include "core_global.h" #include #include @@ -12,7 +13,7 @@ #include #pragma db object -class Permission : public QObject +class CORESHARED_EXPORT Permission : public QObject { Q_OBJECT Q_PROPERTY(QString pluginId READ pluginId WRITE setPluginId) diff --git a/core/data/role.h b/core/data/role.h index 44d1a38..3119f5f 100644 --- a/core/data/role.h +++ b/core/data/role.h @@ -2,6 +2,7 @@ #define ROLE_H #include "core-data.h" +#include "core_global.h" #include #include @@ -12,7 +13,7 @@ #include #pragma db object -class Role : public QObject +class CORESHARED_EXPORT Role : public QObject { Q_OBJECT Q_PROPERTY(QString name READ name WRITE setName) diff --git a/core/data/user.h b/core/data/user.h index 0bce4d5..d7e8b85 100644 --- a/core/data/user.h +++ b/core/data/user.h @@ -2,6 +2,7 @@ #define USER_H #include "core-data.h" +#include "core_global.h" #include #include @@ -12,7 +13,7 @@ #include #pragma db object -class User : public QObject +class CORESHARED_EXPORT User : public QObject { Q_OBJECT Q_PROPERTY(QString login READ login WRITE setLogin)