I get this warning trying to compile open source library with MinGW (msys2) in Windows
*** Warning: linker path does not have real file for library -lcrypt32.
*** I have the capability to make that library automatically link in when
*** you link to this library. But I can only do this if you have a
*** shared version of the library, which you do not appear to have
*** because I did check the linker path looking for a file starting
*** with libcrypt32 and none of the candidates passed a file format test
*** using a file magic. Last file checked: C:/msys64/mingw32/i686-w64-mingw32/lib/libcrypt32.a
Because of this error I can't compile shared library only static.
File C:/msys64/mingw32/i686-w64-mingw32/lib/libcrypt32.a
exists and normally links in another libraries under the same environment
The warning message is displayed by libtool
in case when it cannot find appropriate library candidate for linking. In my case the source of problem is my locale. Installed libtool
uses output of objdump
to check if found candidate is import library and expects output in English:
if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null |
$EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64|coff-arm|coff-arm64|coff-i386|coff-x86-64)' >/dev/null; then
So setting language to English before making library solved my problem: LANG=en_US.UTF-8 make