diff --git a/src/corelib/CMakeLists.txt b/src/corelib/CMakeLists.txt index 915a7ae08c..c1259150ab 100644 --- a/src/corelib/CMakeLists.txt +++ b/src/corelib/CMakeLists.txt @@ -266,6 +266,7 @@ qt_internal_add_module(Core Qt::GlobalConfigPrivate # special case PRECOMPILED_HEADER "global/qt_pch.h" + GENERATE_CPP_EXPORTS PUBLIC_LIBRARIES # special case: Qt::Platform # special case: # special case begin diff --git a/src/corelib/global/qglobal.h b/src/corelib/global/qglobal.h index 0ec3bbcb85..e44929b379 100644 --- a/src/corelib/global/qglobal.h +++ b/src/corelib/global/qglobal.h @@ -516,15 +516,12 @@ constexpr inline Deprecated_t Deprecated = {}; # ifndef QT_SHARED # define QT_SHARED # endif -# if defined(QT_BUILD_CORE_LIB) -# define Q_CORE_EXPORT Q_DECL_EXPORT -# else -# define Q_CORE_EXPORT Q_DECL_IMPORT -# endif -#else -# define Q_CORE_EXPORT #endif +QT_BEGIN_INCLUDE_NAMESPACE +#include +QT_END_INCLUDE_NAMESPACE + /* Some classes do not permit copies to be made of an object. These classes contains a private copy constructor and assignment