]> granicus.if.org Git - graphviz/commitdiff
gdtclft: use only GVDLL to enable dllexport storage-class attribute for Gdtclft_Init
authorMagnus Jacobsson <Magnus.Jacobsson@berotec.se>
Sun, 2 Jan 2022 18:35:05 +0000 (19:35 +0100)
committerMagnus Jacobsson <Magnus.Jacobsson@berotec.se>
Wed, 12 Jan 2022 07:51:02 +0000 (08:51 +0100)
Instead of using __CYGWIN__ and __WIN32__, rely on that GVDLL is
correctly set for all platforms.

Towards https://gitlab.com/graphviz/graphviz/-/issues/2173.

tclpkg/gdtclft/gdtclft.c

index 1b2004bfc6f675cb3680b16c526ca3baea3fc397..0de5b5059d399cf081de7fda30b4a3b7eb9ef2e5 100644 (file)
@@ -1252,15 +1252,12 @@ tclGdTextCmd(Tcl_Interp * interp, int argc, Tcl_Obj * CONST objv[])
 /* 
  * Initialize the package.
  */
-#ifdef __CYGWIN__
-int Gdtclft_Init(Tcl_Interp * interp)
-#else
-#ifdef __WIN32__
+#ifdef GVDLL
 __declspec(dllexport) int Gdtclft_Init(Tcl_Interp *interp)
 #else
 int Gdtclft_Init(Tcl_Interp * interp)
 #endif
-#endif
+
 {
 #ifdef USE_TCL_STUBS
     if (Tcl_InitStubs(interp, TCL_VERSION, 0) == NULL) {