Convert file.lib to file .a (QT MinGW)
you can transform a .lib file (using a file.dll) .a in a file?
I'll explain, I have a .lib file that I need to use in a project in qt mingw.
So I need the file .ae not the .lib file.
Is there a converter or a way to do this?
MinGW supports libraries in both formats: .a and .lib
The file format is not the problem. The problem is that the .lib file was probably compiled using MSVC which means that it might or might not be compatible with MinGW, depending on what compiler settings were used and what interface does the lib expose (C or C++), which features were used (eg. STL) and how it links to the CRT.
If you know all these things are ok then you can go ahead and link to the .lib just as you would to the .a
If you don't know these things the "safe" way is to recompile the library using MinGW. There is no "converter".
Word of caution: don't "try and see if it works" if you're not sure. It might "seem" to work but if it's not compatible it will lead to very subtle and hard to debug problems.
OK. he said the manufacturer of the library.
I wrote that is not compatible with mingw.
Thanks for the help you have given me.
I have the same problem as you. How did you solve it? How did you recompile the library using MinGW
Hi and welcome
It really depends on the library.
Some can be recompiled with mingw some are nearly impossible.
So there is not one answer that covers all LIBS.
Thanks for the answer. How can I tell from the .lib or .dll file if it is possible to recompile them? I'm using a 3rd party library provided by the hardware company.
For recompilation you need to have the source code.
If it is not available you need to know the compilation parameters from the lib-supplier as already discussed 2 years ago in the original post.