The following link errors can happen if the incorrect Chilkat C/C++ library is chosen.

For example, if you are using the TDM 4.7.1 compiler, but you downloaded the Chilkat lib for MinGW-4.6.3, then you would get these errors:

../lib/libchilkat-9.5.0.a(ChilkatTm.o):ChilkatTm.cpp:(.text+0x80): undefined reference to `_localtime32'
../lib/libchilkat-9.5.0.a(ChilkatTm.o):ChilkatTm.cpp:(.text+0x237): undefined reference to `_mktime32'
../lib/libchilkat-9.5.0.a(ChilkatTm.o):ChilkatTm.cpp:(.text+0x1df9): undefined reference to `_time32'
../lib/libchilkat-9.5.0.a(ChilkatTm.o):ChilkatTm.cpp:(.text+0x266): undefined reference to `_mktime32'
../lib/libchilkat-9.5.0.a(Psdk.o):Psdk.cpp:(.text+0xdab): undefined reference to `_time32'
../lib/libchilkat-9.5.0.a(DateParser.o):DateParser.cpp:(.text+0x3eec): undefined reference to `_time32'
../lib/libchilkat-9.5.0.a(DateParser.o):DateParser.cpp:(.text+0x42bc): undefined reference to `_time32'
../lib/libchilkat-9.5.0.a(DateParser.o):DateParser.cpp:(.text+0x43e8): undefined reference to `_time32'
../lib/libchilkat-9.5.0.a(DateParser.o):DateParser.cpp:(.text+0x43fe): undefined reference to `_gmtime32'
../lib/libchilkat-9.5.0.a(DateParser.o):DateParser.cpp:(.text+0x451c): undefined reference to `_time32'
../lib/libchilkat-9.5.0.a(TlsProtocol.o):TlsProtocol.cpp:(.text+0x2b41): undefined reference to `_time32'

Chilkat provides downloads for many different versions of MinGW and TDM here:  https://www.chilkatsoft.com/downloads_mingw.asp

An exact match is likely not necessary.  Matching the major version number, and matching the “dwarf”, “seh”, and “sjlj” is necessary, but an exact version match should not be necessary.  For example, the MinGW-w64 8.1.0 posix seh  should be valid for any MinGW 8.*.*, as long as it’s 64-bit and posix and seh..