You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Microsoft C++ Linker includes a flag /VERBOSE:UNUSEDLIBS that writes additional information to stdout about .lib files that were unused. A similar flag /VERBOSE:UNUSEDDELAYLOAD can point to delay-load DLL references whose code was unused.
The text was updated successfully, but these errors were encountered:
I tried a quick prototype of this but run into a problem that I can't figure out how to get the contents of stdout from the Link task's tool task execution. Without this ability to reflect on stdout it's going to be difficult to feed back into a build break.
A minimum viable product would be to enable the two linker flags noted above when ReferenceTrimmer is installed, then document common libraries seen in the output and how to disable them. The linker output shows all .lib files even if they are DLL import libraries and not code bundles, and will usually include things like user32.lib and ws2_32.lib, which need specific guidance to fix (can be in a doc file - involves modifying the default AdditionalDependencies property to only list needed import libraries).
The Microsoft C++ Linker includes a flag /VERBOSE:UNUSEDLIBS that writes additional information to stdout about .lib files that were unused. A similar flag
/VERBOSE:UNUSEDDELAYLOAD
can point to delay-load DLL references whose code was unused.The text was updated successfully, but these errors were encountered: