diff --git a/src/clientkit/dialog_ux_state_aggregator.hh b/src/clientkit/dialog_ux_state_aggregator.hh index b66c5002..640e7d53 100644 --- a/src/clientkit/dialog_ux_state_aggregator.hh +++ b/src/clientkit/dialog_ux_state_aggregator.hh @@ -25,15 +25,16 @@ #include "clientkit/dialog_ux_state_aggregator_interface.hh" #include "clientkit/interaction_control_manager_interface.hh" #include "clientkit/session_manager_interface.hh" +#include "nugu.h" namespace NuguClientKit { using namespace NuguCapability; -class DialogUXStateAggregator : public IASRListener, - public ITTSListener, - public IChipsListener, - public IInteractionControlManagerListener { +class NUGU_API DialogUXStateAggregator : public IASRListener, + public ITTSListener, + public IChipsListener, + public IInteractionControlManagerListener { public: explicit DialogUXStateAggregator(ISessionManager* session_manager); virtual ~DialogUXStateAggregator(); diff --git a/src/clientkit/speech_recognizer_aggregator.hh b/src/clientkit/speech_recognizer_aggregator.hh index 7924d832..e98867a8 100644 --- a/src/clientkit/speech_recognizer_aggregator.hh +++ b/src/clientkit/speech_recognizer_aggregator.hh @@ -18,12 +18,13 @@ #define __SPEECH_RECOGNIZER_AGGREGATOR_H__ #include "clientkit/speech_recognizer_aggregator_interface.hh" +#include "nugu.h" namespace NuguClientKit { -class SpeechRecognizerAggregator : public ISpeechRecognizerAggregator, - public IWakeupListener, - public IASRListener { +class NUGU_API SpeechRecognizerAggregator : public ISpeechRecognizerAggregator, + public IWakeupListener, + public IASRListener { public: SpeechRecognizerAggregator(); virtual ~SpeechRecognizerAggregator(); diff --git a/src/core/directive_sequencer.hh b/src/core/directive_sequencer.hh index 00912438..dd0daa50 100644 --- a/src/core/directive_sequencer.hh +++ b/src/core/directive_sequencer.hh @@ -18,21 +18,22 @@ #define __NUGU_DIRECTIVE_SEQUENCER_H__ #include -#include #include +#include #include #include "clientkit/directive_sequencer_interface.hh" +#include "nugu.h" namespace NuguCore { using namespace NuguClientKit; -class LookupTable; -class DialogDirectiveList; +class NUGU_API LookupTable; +class NUGU_API DialogDirectiveList; -class DirectiveSequencer : public IDirectiveSequencer { +class NUGU_API DirectiveSequencer : public IDirectiveSequencer { public: DirectiveSequencer(); diff --git a/src/core/focus_manager.hh b/src/core/focus_manager.hh index d1275388..d1494eb4 100644 --- a/src/core/focus_manager.hh +++ b/src/core/focus_manager.hh @@ -23,19 +23,20 @@ #include #include "clientkit/focus_manager_interface.hh" +#include "nugu.h" namespace NuguCore { using namespace NuguClientKit; -class IFocusResourceObserver { +class NUGU_API IFocusResourceObserver { public: virtual ~IFocusResourceObserver() = default; virtual void onFocusChanged(const std::string& type, const std::string& name, FocusState state) = 0; }; -class FocusResource { +class NUGU_API FocusResource { public: FocusResource(const std::string& type, const std::string& name, int request_priority, int release_priority, IFocusResourceListener* listener, IFocusResourceObserver* observer); virtual ~FocusResource() = default; @@ -55,8 +56,8 @@ public: IFocusResourceObserver* observer; }; -class FocusManager : public IFocusManager, - public IFocusResourceObserver { +class NUGU_API FocusManager : public IFocusManager, + public IFocusResourceObserver { public: FocusManager(); virtual ~FocusManager() = default; diff --git a/src/core/interaction_control_manager.hh b/src/core/interaction_control_manager.hh index e1e5be01..6d23e1d9 100644 --- a/src/core/interaction_control_manager.hh +++ b/src/core/interaction_control_manager.hh @@ -26,7 +26,7 @@ namespace NuguCore { using namespace NuguClientKit; -class InteractionControlManager : public IInteractionControlManager { +class NUGU_API InteractionControlManager : public IInteractionControlManager { public: using Requesters = std::set; diff --git a/src/core/media_player.hh b/src/core/media_player.hh index 45b2c06d..6a39c94e 100644 --- a/src/core/media_player.hh +++ b/src/core/media_player.hh @@ -22,13 +22,14 @@ #include "base/nugu_media.h" #include "base/nugu_player.h" #include "clientkit/media_player_interface.hh" +#include "nugu.h" namespace NuguCore { using namespace NuguClientKit; class MediaPlayerPrivate; -class MediaPlayer : public IMediaPlayer { +class NUGU_API MediaPlayer : public IMediaPlayer { public: explicit MediaPlayer(int volume = NUGU_SET_VOLUME_MAX); virtual ~MediaPlayer(); diff --git a/src/core/nugu_timer.hh b/src/core/nugu_timer.hh index 45769d0e..6e5ce33a 100644 --- a/src/core/nugu_timer.hh +++ b/src/core/nugu_timer.hh @@ -18,13 +18,14 @@ #define __NUGU_TIMER_HH__ #include "clientkit/nugu_timer_interface.hh" +#include "nugu.h" namespace NuguCore { using namespace NuguClientKit; -class NUGUTimerPrivate; -class NUGUTimer : public INuguTimer { +class NUGU_API NUGUTimerPrivate; +class NUGU_API NUGUTimer : public INuguTimer { public: NUGUTimer(bool singleshot = false); virtual ~NUGUTimer(); diff --git a/src/core/playstack_manager.hh b/src/core/playstack_manager.hh index 0f3a5d37..585cac7d 100644 --- a/src/core/playstack_manager.hh +++ b/src/core/playstack_manager.hh @@ -21,6 +21,7 @@ #include #include "clientkit/playsync_manager_interface.hh" +#include "nugu.h" #include "nugu_timer.hh" namespace NuguCore { @@ -33,7 +34,7 @@ enum class PlayStackRemoveMode { Later }; -class IPlayStackManagerListener { +class NUGU_API IPlayStackManagerListener { public: virtual ~IPlayStackManagerListener() = default; @@ -41,13 +42,13 @@ public: virtual void onStackRemoved(const std::string& ps_id) = 0; }; -class IStackTimer : public NUGUTimer { +class NUGU_API IStackTimer : public NUGUTimer { public: virtual ~IStackTimer() = default; virtual bool isStarted() = 0; }; -class PlayStackManager { +class NUGU_API PlayStackManager { public: using PlayStack = std::pair, std::vector>; using PlayStackHoldTimes = struct _PlayStackHoldTimes { diff --git a/src/core/playsync_manager.hh b/src/core/playsync_manager.hh index 9f3c0c1b..3db398d4 100644 --- a/src/core/playsync_manager.hh +++ b/src/core/playsync_manager.hh @@ -23,6 +23,7 @@ #include #include "base/nugu_directive.h" +#include "nugu.h" #include "clientkit/playsync_manager_interface.hh" #include "interaction_control_manager.hh" @@ -32,8 +33,8 @@ namespace NuguCore { using namespace NuguClientKit; -class PlaySyncManager : public IPlaySyncManager, - public IPlayStackManagerListener { +class NUGU_API PlaySyncManager : public IPlaySyncManager, + public IPlayStackManagerListener { public: PlaySyncManager(); virtual ~PlaySyncManager(); diff --git a/src/core/routine_manager.hh b/src/core/routine_manager.hh index ea7a8e35..ad317de0 100644 --- a/src/core/routine_manager.hh +++ b/src/core/routine_manager.hh @@ -25,13 +25,14 @@ #include #include "clientkit/routine_manager_interface.hh" +#include "nugu.h" #include "nugu_timer.hh" namespace NuguCore { using namespace NuguClientKit; -class RoutineManager : public IRoutineManager { +class NUGU_API RoutineManager : public IRoutineManager { public: using RoutineAction = struct _RoutineAction { std::string type; diff --git a/src/core/session_manager.hh b/src/core/session_manager.hh index d61245ba..f063f988 100644 --- a/src/core/session_manager.hh +++ b/src/core/session_manager.hh @@ -21,12 +21,13 @@ #include #include "clientkit/session_manager_interface.hh" +#include "nugu.h" namespace NuguCore { using namespace NuguClientKit; -class SessionManager : public ISessionManager { +class NUGU_API SessionManager : public ISessionManager { public: using ActiveDialogs = std::vector>; using Sessions = std::map; diff --git a/tests/core/CMakeLists.txt b/tests/core/CMakeLists.txt index 67a7a784..4ba7ecbf 100644 --- a/tests/core/CMakeLists.txt +++ b/tests/core/CMakeLists.txt @@ -18,6 +18,13 @@ SET(test_core_media_player_srcs ../../src/core/nugu_timer.cc ../../src/core/media_player.cc) +# doesn't work timer mock in msvc cause of PDB issue. +IF(MSVC) + LIST(REMOVE_ITEM UNIT_TESTS + "test_core_nugu_timer" + "test_core_media_player") +ENDIF() + FOREACH(test ${UNIT_TESTS}) SET(SRC ${test}.cc) IF (${test}_srcs) diff --git a/tests/core/test_core_focus_manager.cc b/tests/core/test_core_focus_manager.cc index 518cb758..7fcfb68a 100644 --- a/tests/core/test_core_focus_manager.cc +++ b/tests/core/test_core_focus_manager.cc @@ -17,6 +17,7 @@ #include #include #include +#include #include