aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tools/objtool/include
diff options
context:
space:
mode:
authorJosh Poimboeuf <jpoimboe@kernel.org>2025-03-14 12:29:07 -0700
committerPeter Zijlstra <peterz@infradead.org>2025-03-17 11:36:01 +0100
commit5a406031d0719d146d2033ee4270310b1ca9a1e3 (patch)
tree4df3c743470970860b84a076187c45bbf9357697 /tools/objtool/include
parentobjtool: Upgrade "Linked object detected" warning to error (diff)
downloadwireguard-linux-5a406031d0719d146d2033ee4270310b1ca9a1e3.tar.xz
wireguard-linux-5a406031d0719d146d2033ee4270310b1ca9a1e3.zip
objtool: Add --output option
Add option to allow writing the changed binary to a separate file rather than changing it in place. Libelf makes this suprisingly hard, so take the easy way out and just copy the file before editing it. Also steal the -o short option from --orc. Nobody will notice ;-) Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Link: https://lore.kernel.org/r/0da308d42d82b3bbed16a31a72d6bde52afcd6bd.1741975349.git.jpoimboe@kernel.org
Diffstat (limited to 'tools/objtool/include')
-rw-r--r--tools/objtool/include/objtool/builtin.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/objtool/include/objtool/builtin.h b/tools/objtool/include/objtool/builtin.h
index fcca6662c8b4..25cfa01758b9 100644
--- a/tools/objtool/include/objtool/builtin.h
+++ b/tools/objtool/include/objtool/builtin.h
@@ -35,6 +35,7 @@ struct opts {
bool mnop;
bool module;
bool no_unreachable;
+ const char *output;
bool sec_address;
bool stats;
bool verbose;