From ac55a7a0a89fe9a1f39e33ee3445b644c68fa0c1 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 14 Nov 2017 10:39:14 +0200 Subject: Further work on build2 build, support for non-static plugin on Windows --- odb/plugin.cxx | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'odb/plugin.cxx') diff --git a/odb/plugin.cxx b/odb/plugin.cxx index c046c2f..c0fee9f 100644 --- a/odb/plugin.cxx +++ b/odb/plugin.cxx @@ -38,7 +38,11 @@ using cutl::fs::invalid_path; typedef vector paths; +#if defined(_WIN32) && !defined(ODB_STATIC_PLUGIN) +__declspec(dllexport) +#endif int plugin_is_GPL_compatible; + unique_ptr options_; paths profile_paths_; path file_; // File being compiled. @@ -290,7 +294,11 @@ static char const* const odb_version = ODB_COMPILER_VERSION_STR; typedef vector strings; -extern "C" int +extern "C" +#if defined(_WIN32) && !defined(ODB_STATIC_PLUGIN) +__declspec(dllexport) +#endif +int plugin_init (plugin_name_args* plugin_info, plugin_gcc_version*) { int r (0); -- cgit v1.1