Here is the patch starting from checkin [9c32a526ed] for your convenience.

Enjoy,
Harald

<verbatim>
Index: tls.c
==================================================================
--- tls.c
+++ tls.c
@@ -1774,11 +1774,11 @@
  *	 create the ssl command, initialise ssl context
  *
  *-------------------------------------------------------------------
  */

-int Tls_Init(Tcl_Interp *interp) {
+DLLEXPORT int Tls_Init(Tcl_Interp *interp) {
 	const char tlsTclInitScript[] = {
 #include "tls.tcl.h"
             0x00
 	};

@@ -1834,11 +1834,11 @@
  *		A standard Tcl error code.
  *
  *------------------------------------------------------*
  */

-int Tls_SafeInit(Tcl_Interp *interp) {
+DLLEXPORT int Tls_SafeInit(Tcl_Interp *interp) {
 	dprintf("Called");
 	return(Tls_Init(interp));
 }

 /*

Index: tls.h
==================================================================
--- tls.h
+++ tls.h
@@ -21,9 +21,9 @@
 #include <tcl.h>

 /*
  * Initialization routines -- our entire public C API.
  */
-int Tls_Init(Tcl_Interp *interp);
-int Tls_SafeInit(Tcl_Interp *interp);
+DLLEXPORT int Tls_Init(Tcl_Interp *interp);
+DLLEXPORT int Tls_SafeInit(Tcl_Interp *interp);

 #endif /* _TLS_H */

ADDED   win/README.txt
Index: win/README.txt
==================================================================
--- win/README.txt
+++ win/README.txt
@@ -0,0 +1,66 @@
+	Windows DLL Build instructions using nmake build system
+	2020-10-15
+
+Properties:
+- 32 bit DLL
+- VisualStudio 2015
+Note: Vuisual C++ 6 does not build OpenSSL (long long syntax error)
+- Cygwin32 (temporary helper, please help to replace by tclsh)
+- OpenSSL statically linked to TCLTLS DLL.
+Note: Dynamic linking also works but results in a DLL dependeny on OPENSSL DLL's
+
+1) Build OpenSSL static libraries:
+
+OpenSSL source distribtution unpacked in:

+
+- Install Perl from
+  to C:\perl
+  (ActivePerl failed due to missing 32 bit console module)
+- Install NASM Assembler:
+

+  to C:\Program Files (x86)\NASM
+
+-> Visual Studio x86 native prompt.
+
+set Path=%PATH%;C:\Program Files
+
+perl Configure VC-WIN32 no-shared no-filenames threads
+
+nmake
+nmake test
+namke install
+
+2) Build TCLTLS
+
+Unzip distribution in:

+
+-> start cygwin bash prompt
+
+cd
+./gen_dh_params > dh_params.h
+
+od -A n -v -t xC < 'tls.tcl' > tls.tcl.h.new.1
+sed @g' < tls.tcl.h.new.1 > tls.tcl.h
+rm -f tls.tcl.h.new.1
+
+-> Visual Studio x86 native prompt.
+
+cd
+
+nmake -f makefile.vc
+
+nmake -f makefile.vc install
+
+tls.c:
+Lines 1779, 1839: replace
+int Tls_Init by
+DLLEXPORT int  Tls_Init
+
+tls.h: same change
+
+lappend auto_path
+package require tls
+

ADDED   win/makefile.vc
Index: win/makefile.vc
==================================================================
--- win/makefile.vc
+++ win/makefile.vc
@@ -0,0 +1,24 @@
+# call nmake with additional parameter SSL_INSTALL_FOLDER= with the
+# OpenSSL instalation folder following.
+
+PROJECT=tls
+DOTVERSION = 1.7.22
+
+PRJ_INCLUDES	= -I"$(SSL_INSTALL_FOLDER)\include"
+PRJ_DEFINES =  -D NO_SSL2 -D NO_SSL3 -D _CRT_SECURE_NO_WARNINGS
+
+PRJ_LIBS = \
+	\
+	\
+	WS2_32.LIB GDI32.LIB ADVAPI32.LIB CRYPT32.LIB USER32.LIB
+
+PRJ_OBJS = $(TMP_DIR)\tls.obj \
+               $(TMP_DIR)\tlsBIO.obj \
+               $(TMP_DIR)\tlsIO.obj \
+               $(TMP_DIR)\tlsX509.obj
+
+!include "rules-ext.vc"
+!include "targets.vc"
+
+pkgindex: default-pkgindex
+

ADDED   win/targets.vc
Index: win/targets.vc
==================================================================
--- win/targets.vc
+++ win/targets.vc
@@ -0,0 +1,98 @@
+#------------------------------------------------------------- -*- makefile -*-
+# targets.vc --
+#
+# Part of the nmake based build system for Tcl and its extensions.
+# This file defines some standard targets for the convenience of extensions
+# and can be optionally included by the extension makefile.
+# See TIP 477 for docs.
+
+$(PROJECT): setup pkgindex $(PRJLIB)
+
+!ifdef PRJ_STUBOBJS
+$(PROJECT): $(PRJSTUBLIB)
+$(PRJSTUBLIB): $(PRJ_STUBOBJS)
+	$(LIBCMD) $**
+
+$(PRJ_STUBOBJS):
+	$(CCSTUBSCMD) %s
+!endif # PRJ_STUBOBJS
+
+!ifdef PRJ_MANIFEST
+$(PROJECT): $(PRJLIB).manifest
+$(PRJLIB).manifest: $(PRJ_MANIFEST)
+	@nmakehlp -s << $** >$@
+@MACHINE@	  $(MACHINE:IX86=X86)
+<<
+!endif
+
+!if "$(PROJECT)" != "tcl" && "$(PROJECT)" != "tk"
+$(PRJLIB): $(PRJ_OBJS) $(RESFILE)
+!if $(STATIC_BUILD)
+       $(LIBCMD) $**
+!else
+       $(DLLCMD) $**
+       $(_VC_MANIFEST_EMBED_DLL)
+!endif
+       -@del $*.exp
+!endif
+
+!if "$(PRJ_HEADERS)" != "" && "$(PRJ_OBJS)" != ""
+$(PRJ_OBJS): $(PRJ_HEADERS)
+!endif
+
+# If parent makefile has defined stub objects, add their installation
+# to the default install
+!if "$(PRJ_STUBOBJS)" != ""
+default-install: default-install-stubs
+!endif
+
+# Unlike the other default targets, these cannot be in rules.vc because
+# the executed command depends on existence of macro PRJ_HEADERS_PUBLIC
+# that the parent makefile will not define until after including rules-ext.vc
+!if "$(PRJ_HEADERS_PUBLIC)" != ""
+default-install: default-install-headers
+default-install-headers:
+	@echo Installing headers to '$(INCLUDE_INSTALL_DIR)'
+	@for %f in ($(PRJ_HEADERS_PUBLIC)) do @$(COPY) %f "$(INCLUDE_INSTALL_DIR)"
+!endif
+
+!if "$(DISABLE_STANDARD_TARGETS)" == ""
+DISABLE_STANDARD_TARGETS = 0
+!endif
+
+!if "$(DISABLE_TARGET_setup)" == ""
+DISABLE_TARGET_setup = 0
+!endif
+!if "$(DISABLE_TARGET_install)" == ""
+DISABLE_TARGET_install = 0
+!endif
+!if "$(DISABLE_TARGET_clean)" == ""
+DISABLE_TARGET_clean = 0
+!endif
+!if "$(DISABLE_TARGET_test)" == ""
+DISABLE_TARGET_test = 0
+!endif
+!if "$(DISABLE_TARGET_shell)" == ""
+DISABLE_TARGET_shell = 0
+!endif
+
+!if !$(DISABLE_STANDARD_TARGETS)
+!if !$(DISABLE_TARGET_setup)
+setup: default-setup
+!endif
+!if !$(DISABLE_TARGET_install)
+install: default-install
+!endif
+!if !$(DISABLE_TARGET_clean)
+clean: default-clean
+realclean: hose
+hose: default-hose
+distclean: realclean default-distclean
+!endif
+!if !$(DISABLE_TARGET_test)
+test: default-test
+!endif
+!if !$(DISABLE_TARGET_shell)
+shell: default-shell
+!endif
+!endif # DISABLE_STANDARD_TARGETS

</verbatim>