From 00f52cab540104921f5f63ef7fec6c792322ef37 Mon Sep 17 00:00:00 2001 From: Johnson Shih Date: Fri, 20 Jul 2018 13:54:32 -0700 Subject: [PATCH 1/3] add missing export variable --- include/class_loader/class_loader.hpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/class_loader/class_loader.hpp b/include/class_loader/class_loader.hpp index de79c633..b751f022 100644 --- a/include/class_loader/class_loader.hpp +++ b/include/class_loader/class_loader.hpp @@ -330,6 +330,8 @@ class ClassLoader boost::recursive_mutex load_ref_count_mutex_; int plugin_ref_count_; boost::recursive_mutex plugin_ref_count_mutex_; + + CLASS_LOADER_PUBLIC static bool has_unmananged_instance_been_created_; }; From 1f922b1c6c6c93f0fa7b1459aba16b7bbd52c192 Mon Sep 17 00:00:00 2001 From: Johnson Shih Date: Tue, 14 Aug 2018 17:51:53 -0700 Subject: [PATCH 2/3] add missing export declaration to AbstractMetaObjectBase --- include/class_loader/meta_object.hpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/class_loader/meta_object.hpp b/include/class_loader/meta_object.hpp index ef658cd4..8183c9ac 100644 --- a/include/class_loader/meta_object.hpp +++ b/include/class_loader/meta_object.hpp @@ -36,6 +36,8 @@ #define CLASS_LOADER__META_OBJECT_HPP_ #include +#include "class_loader/visibility_control.hpp" + #include #include #include @@ -54,7 +56,7 @@ typedef std::vector ClassLoaderVector; * @class AbstractMetaObjectBase * @brief A base class for MetaObjects that excludes a polymorphic type parameter. Subclasses are class templates though. */ -class AbstractMetaObjectBase +class CLASS_LOADER_PUBLIC AbstractMetaObjectBase { public: /** From bc603003d97430066b2328ac51560ba2ef55c03c Mon Sep 17 00:00:00 2001 From: Johnson Shih Date: Tue, 14 Aug 2018 18:20:32 -0700 Subject: [PATCH 3/3] Always built SHARE for Windows, others fall back to default --- CMakeLists.txt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 3b9a2583..7580a954 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -56,7 +56,12 @@ set(${PROJECT_NAME}_HDRS include/class_loader/multi_library_class_loader.hpp include/class_loader/register_macro.hpp ) -add_library(${PROJECT_NAME} ${${PROJECT_NAME}_SRCS} ${${PROJECT_NAME}_HDRS}) +if(WIN32) + add_library(${PROJECT_NAME} SHARED ${${PROJECT_NAME}_SRCS} ${${PROJECT_NAME}_HDRS}) +else() + add_library(${PROJECT_NAME} ${${PROJECT_NAME}_SRCS} ${${PROJECT_NAME}_HDRS}) +endif() + target_link_libraries(${PROJECT_NAME} ${Boost_LIBRARIES} ${console_bridge_LIBRARIES} ${Poco_LIBRARIES}) if(WIN32) # Causes the visibility macros to use dllexport rather than dllimport