From 77c7015c00f81a0c66f68577bee334bb4b4c3e90 Mon Sep 17 00:00:00 2001 From: Magnus Jacobsson Date: Sun, 2 Jan 2022 19:35:05 +0100 Subject: [PATCH] gdtclft: use only GVDLL to enable dllexport storage-class attribute for Gdtclft_Init 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 | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/tclpkg/gdtclft/gdtclft.c b/tclpkg/gdtclft/gdtclft.c index 1b2004bfc..0de5b5059 100644 --- a/tclpkg/gdtclft/gdtclft.c +++ b/tclpkg/gdtclft/gdtclft.c @@ -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) { -- 2.40.0