]> granicus.if.org Git - graphviz/commitdiff
fix multiple definitions of tcldot_builtins variables
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Fri, 19 Feb 2021 15:38:08 +0000 (07:38 -0800)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 24 Apr 2021 15:47:30 +0000 (08:47 -0700)
Similar to preceding commits, this fixes an issue where MinGW was seeing
 __declspec alternatives but implementing GCC semantics and hence treating
declarations as definitions.

tclpkg/tcldot/tcldot_builtins.c

index ab71b0871973148e6edbba164e25a1b535d245ad..26e28c6125a31decf9a70527e5f4ccaeedd65373 100644 (file)
 #include <gvc/gvplugin.h>
 
 #if defined(GVDLL) && !defined(ENABLE_LTDL)
-#define extern __declspec(dllimport)
+#define IMPORT __declspec(dllimport)
+#else
+#define IMPORT /* nothing */
 #endif
 
-extern gvplugin_library_t gvplugin_dot_layout_LTX_library;
-extern gvplugin_library_t gvplugin_neato_layout_LTX_library;
+IMPORT extern gvplugin_library_t gvplugin_dot_layout_LTX_library;
+IMPORT extern gvplugin_library_t gvplugin_neato_layout_LTX_library;
 #ifdef HAVE_LIBGD
-extern gvplugin_library_t gvplugin_gd_LTX_library;
+IMPORT extern gvplugin_library_t gvplugin_gd_LTX_library;
 #endif
 #ifdef HAVE_PANGOCAIRO
-extern gvplugin_library_t gvplugin_pango_LTX_library;
+IMPORT extern gvplugin_library_t gvplugin_pango_LTX_library;
 #endif
-extern gvplugin_library_t gvplugin_core_LTX_library;
+IMPORT extern gvplugin_library_t gvplugin_core_LTX_library;
 
 
 lt_symlist_t lt_preloaded_symbols[] = {