mingw-distro
mingw-distro copied to clipboard
binutils 2.41 still complains about `libdep.a`
Two users have independently reported that building different projects (Lua, wxWidgets) fails with a dialog box complaining:
c:\mingw\lib\bfd-plugins\libdep.a
is either not designed to run on Windows or it contains an error. Try installing the program again using the original installation media or contact your system administrator or the software vendor for support. Error status0xc000012f
.
This appears to have been fixed upstream as https://sourceware.org/bugzilla/show_bug.cgi?id=27113 . However, I'm not 100% certain, because that bug and fix talks about libdep.dll.a
. (The difference may be that I build the distro statically.)
It would be helpful to:
- Get a minimal, self-contained repro (I don't want to try building Lua or wxWidgets)
- Verify whether the trunk version of binutils makes this problem go away
- If it doesn't, verify whether deleting
libdep.a
makes this problem go away (as I can easily add that to the build script)
Minimal reproduction:
echo. > empty.c
gcc -c -o empty.o empty.c
ar -rc libempty.a empty.o
binutils 2.38 has been released and contains the claimed fix, so I just need to build it.
Still repros with binutils 2.41.
Hi @StephanTLavavej I've been working around this for years. But sadly, do not know how to repair it. When I build GCC for embedded targets like arm
, avr
or others on MSys2
, I need to actually delete the plugins
folder. This is because the plugins load libdep.a
and that program (regardless of how I build binutils
) wants to load some DLLs dynamically.
I use your standalone MinGW EVN for building since your GCC is dependency-free, which is rare.
Unfortunatley, I have not yet found the place in source code where the program dynamically loads and remain still doing workarounds like this.
This should be reported upstream to binutils.