fix Windows build libmygpo-qt5 (#5581)

This commit is contained in:
Pavel Vatagin 2017-01-10 03:25:13 +04:00 committed by John Maguire
parent b52c99755d
commit 09c4b05ec5
2 changed files with 4 additions and 1 deletions

View File

@ -25,7 +25,7 @@
#include <QtCore/qglobal.h> #include <QtCore/qglobal.h>
#ifndef MYGPO_EXPORT #ifndef MYGPO_STATIC
# if defined(MYGPO_MAKEDLL) # if defined(MYGPO_MAKEDLL)
/* We are building this library */ /* We are building this library */
# define MYGPO_EXPORT Q_DECL_EXPORT # define MYGPO_EXPORT Q_DECL_EXPORT
@ -33,6 +33,8 @@
/* We are using this library */ /* We are using this library */
# define MYGPO_EXPORT Q_DECL_IMPORT # define MYGPO_EXPORT Q_DECL_IMPORT
# endif # endif
#else
# define MYGPO_EXPORT
#endif #endif
#endif // MYGPO_EXPORT_H #endif // MYGPO_EXPORT_H

View File

@ -406,6 +406,7 @@ if(LIBMYGPO_QT5_FOUND)
set(MYGPOQT5_LIBRARIES ${LIBMYGPO_QT5_LIBRARIES}) set(MYGPOQT5_LIBRARIES ${LIBMYGPO_QT5_LIBRARIES})
set(MYGPOQT5_INCLUDE_DIRS ${LIBMYGPO_QT5_INCLUDE_DIRS}) set(MYGPOQT5_INCLUDE_DIRS ${LIBMYGPO_QT5_INCLUDE_DIRS})
else() else()
add_definitions(-DMYGPO_STATIC)
add_subdirectory(3rdparty/libmygpo-qt5) add_subdirectory(3rdparty/libmygpo-qt5)
set(MYGPOQT5_LIBRARIES mygpo-qt5) set(MYGPOQT5_LIBRARIES mygpo-qt5)
set(MYGPOQT5_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/libmygpo-qt5/src) set(MYGPOQT5_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/libmygpo-qt5/src)