How to strip unwanted symbols from a static library or object file on Windows
Asked Answered
S

1

8

Is there an equivalent of the GNU "strip" tool for Windows?

I'd like to strip out the names of any internal symbols from a static library, so that running dumpbin /symbols mylib.lib will no longer list the symbols with internal linkage.

On Linux, the strip command is typically used to do this. You can strip individual symbols by name, but also by type: running strip --strip-unneeded libmylib.a will remove any debuginfo sections from mylib.a's object files, as well as its internal symbols.

Soundless answered 16/10, 2016 at 22:20 Comment(0)
M
0

7 Years later but this can be done using MSVC Clang-LLVM and llvm-strip.exe

Mudfish answered 5/10 at 18:52 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.