MINGW : multiple definition of `inet_ntop'
Description of problem:
inet_ntop
is defined in libgnutls.a
and in libws2_32.a
Version of gnutls used:
3.6.8, 3.6.7
Works with gnutls 3.6.6
Distributor of gnutls
Debian 10
How reproducible:
Steps to Reproduce:
Compile gnutls in static library
Compile and link a sample application with x86_64-w64-mingw32-gcc
Actual results:
/usr/bin/x86_64-w64-mingw32-ld: /usr/lib/gcc/x86_64-w64-mingw32/8.3-win32/../../../../x86_64-w64-mingw32/lib/libws2_32.a(libws2_32s00182.o):(.text+0x0): multiple definition of `inet_ntop'; /home/btc/vc/x86_64-w64-mingw32-vc/lib/libgnutls.a(inet_ntop.o):inet_ntop.c:(.text+0x30): first defined here
collect2: error: ld returned 1 exit status