C++ – Is it possible to strip debug information from a COFF library file (.lib)

clinkervisual studio

I am linking with a number of 3rd party .lib files, and I get a large number of LNK4099 warnings at link time. It appears that this warning message cannot be supressed, so I believe that if I remove all debug information from the .lib files, the warning will not be shown. Is there a way to remove the debug information? These are libraries that I do not have the source code for.

I am using VS2005 C++ (on Windows of course).

Best Answer

I don't think it is possible, at least with not with conventional tools. I would recommend you contact the vendor and request that they rebuild the .lib file without debug information.