From 6dff236e0795e52800daac15929b5421308c9f16 Mon Sep 17 00:00:00 2001 From: David Rosca Date: Sun, 25 Feb 2018 22:26:37 +0100 Subject: [PATCH] Fix exporting QtSingleApplication --- .../qtsingleapplication/qtsingleapplication.h | 20 +++---------------- src/lib/CMakeLists.txt | 5 ----- 2 files changed, 3 insertions(+), 22 deletions(-) diff --git a/src/lib/3rdparty/qtsingleapplication/qtsingleapplication.h b/src/lib/3rdparty/qtsingleapplication/qtsingleapplication.h index 035dac6df..7c0cb4ee7 100644 --- a/src/lib/3rdparty/qtsingleapplication/qtsingleapplication.h +++ b/src/lib/3rdparty/qtsingleapplication/qtsingleapplication.h @@ -49,25 +49,11 @@ #include +#include "qzcommon.h" + class QtLocalPeer; -#if defined(Q_OS_WIN) -# if !defined(QT_QTSINGLEAPPLICATION_EXPORT) && !defined(QT_QTSINGLEAPPLICATION_IMPORT) -# define QT_QTSINGLEAPPLICATION_EXPORT -# elif defined(QT_QTSINGLEAPPLICATION_IMPORT) -# if defined(QT_QTSINGLEAPPLICATION_EXPORT) -# undef QT_QTSINGLEAPPLICATION_EXPORT -# endif -# define QT_QTSINGLEAPPLICATION_EXPORT __declspec(dllimport) -# elif defined(QT_QTSINGLEAPPLICATION_EXPORT) -# undef QT_QTSINGLEAPPLICATION_EXPORT -# define QT_QTSINGLEAPPLICATION_EXPORT __declspec(dllexport) -# endif -#else -# define QT_QTSINGLEAPPLICATION_EXPORT -#endif - -class QT_QTSINGLEAPPLICATION_EXPORT QtSingleApplication : public QApplication +class FALKON_EXPORT QtSingleApplication : public QApplication { Q_OBJECT diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt index 118617dc5..c12300112 100644 --- a/src/lib/CMakeLists.txt +++ b/src/lib/CMakeLists.txt @@ -3,15 +3,10 @@ add_definitions(-DFALKON_SHAREDLIBRARY) set(CMAKE_CXX_STANDARD 14) # Enable C++14, with cmake >= 3.1 set(CMAKE_CXX_EXTENSIONS OFF) # Don't enable gcc-specific extensions -if (WIN32) -add_definitions(-DQT_QTSINGLEAPPLICATION_EXPORT=) -endif() - set(SRCS 3rdparty/qtsingleapplication/qtsingleapplication.cpp 3rdparty/qtsingleapplication/qtlocalpeer.cpp ) -include_directories(${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/qtsingleapplication) if(CMAKE_BUILD_TYPE STREQUAL "Debug") set(SRCS ${SRCS} ${CMAKE_SOURCE_DIR}/tests/modeltest/modeltest.cpp)