1

I have an app that does explicit linking to a DLL, i.e. at run time. It is done this way instead of implicit linking because the DLL are plug-ins, and it's how we deliver bug fixes to customers, only providing them the new modified dlls.

By default when building a dll library in visual studio the .exp and .lib (import library file) are created along with the dll. I know there are workarounds to get rid of them, like change the folder where they are created or remove them afterwards, but, is there a way to prevent Visual Studio to generate these files?

FrankS101
  • 2,112
  • 6
  • 26
  • 40
  • 1
    The linker, not VS. And no, that's not possible. Just don't fret about it. – Hans Passant Dec 06 '16 at 17:17
  • @HansPassant Thanks anyway. That's also my feeling, but I will leave the question open just in case someone knows a way to do it. By the way, do you know what is the reason why they must be always created? – FrankS101 Dec 07 '16 at 07:38
  • Why are they created? Because features start at -100 points; there has to be a compelling justification for someone to write and test code that implements the feature. In this case, there is absolutely no compelling reason to allow turning off the generation of LIB files. If you don't want them, you just ignore them or delete them. (As an aside, I wonder if it is possible to specify the path to the import library that the linker will generate as a NUL file or some other transient garbage dump? Of course, even if it worked, it won't save any time, is an untested path, and would be pointless.) – Cody Gray - on strike Dec 07 '16 at 08:58

0 Answers0