diff --git a/src/blacksound/blacksound.pro b/src/blacksound/blacksound.pro index 39739d7c9..f6242c436 100644 --- a/src/blacksound/blacksound.pro +++ b/src/blacksound/blacksound.pro @@ -19,7 +19,7 @@ precompile_header:!isEmpty(PRECOMPILED_HEADER) { DEFINES += USING_PCH } -DEFINES += LOG_IN_FILE +DEFINES += LOG_IN_FILE BUILD_BLACKSOUND_LIB HEADERS += *.h SOURCES += *.cpp diff --git a/src/blacksound/blacksoundexport.h b/src/blacksound/blacksoundexport.h new file mode 100644 index 000000000..b490ef411 --- /dev/null +++ b/src/blacksound/blacksoundexport.h @@ -0,0 +1,27 @@ +/* Copyright (C) 2015 + * swift project Community / Contributors + * + * This file is part of swift project. It is subject to the license terms in the LICENSE file found in the top-level + * directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project, + * including this file, may be copied, modified, propagated, or distributed except according to the terms + * contained in the LICENSE file. + */ + +//! \file + +#ifndef BLACKSOUND_MACROS_H +#define BLACKSOUND_MACROS_H + +#include + +#ifndef WITH_STATIC +# if defined(BUILD_BLACKSOUND_LIB) +# define BLACKSOUND_EXPORT Q_DECL_EXPORT +# else +# define BLACKSOUND_EXPORT Q_DECL_IMPORT +# endif +#else +# define BLACKSOUND_EXPORT +#endif + +#endif // BLACKSOUND_MACROS_H diff --git a/src/blacksound/soundgenerator.h b/src/blacksound/soundgenerator.h index 9637bfdcf..461abc598 100644 --- a/src/blacksound/soundgenerator.h +++ b/src/blacksound/soundgenerator.h @@ -12,6 +12,7 @@ #ifndef BLACKSOUND_SOUNDGENERATOR_H #define BLACKSOUND_SOUNDGENERATOR_H +#include "blacksoundexport.h" #include "blackmisc/aviation/selcal.h" #include "blackmisc/audio/audiodeviceinfo.h" #include "blackmisc/pq/time.h" @@ -28,7 +29,7 @@ namespace BlackSound { //! Playing simple sounds - class CSoundGenerator : public QIODevice + class BLACKSOUND_EXPORT CSoundGenerator : public QIODevice { Q_OBJECT