gdb, I can run automatically the binary as (as per this post):
gdb -ex run /bin/true
What's the equivalent parameter for
echo run | lldb /bin/true
but I'd like to back to debugger console instead.
Reverse Engineering Stack Exchange is a question and answer site for researchers and developers who explore the principles of a system through analysis of its structure, function, and operation. It only takes a minute to sign up.Sign up to join this community
LLDB >= 3.4 has the
--one-line command line option that can be used to launch your program automatically:
lldb -o run /bin/true
For reference here are two relevant snippets from
... -o --one-line Tells the debugger to execute this one-line lldb command after any file provided on the command line has been loaded. ... Notes: Multiple "-s" and "-o" options can be provided. They will be processed from left to right in order, with the source files and commands interleaved. ...
And for reviewing command line options in a web browser -- here's a link to the lldb-3.4 man page.
Note that with LLDB < 3.4 (and also newer versions) you can use the
--source option to bootstrap commands like
run -- for example:
$ echo run > autorun $ lldb -s autorun -- /bin/echo arg1 arg2