Is it me or lldb for mac os x (replacing gdb) does not allow you to pipe a file into the stdin, to be used by the process being debugged?
reading the instructions there is no reference to it.
I've gone through and installed gnu gdb, but would like to take advantage of what I suppose is improved lldb capability?
Loading a Program into lldb First we need to set the program to debug. As with gdb, you can start lldb and specify the file you wish to debug on the command line: $ lldb /Projects/Sketch/build/Debug/Sketch. app Current executable set to '/Projects/Sketch/build/Debug/Sketch.
LLDB is a debugging component used in the LLVM project which was developed by the LLVM developer group. Xcode uses the LLDB as the default debugging tool. The full form of LLDB is Low-level debugger. Breakpoints help a developer to stop the execution of the program at any point.
LLDB (low-level debugger) is part of LLVM The LLVM compiler (low level virtual machine) creates programming languages. LLDB is Apple's “from the ground up” replacement for GDB. The LLDB debugger is analogous to GDB: (The GNU Project Debugger).
(lldb) process launch -i <file>
Should do the trick. Note you can't say:
(lldb) run -i <file>
since run
is an alias for process launch --
so all its arguments are passed to the process being launched.
There's a general "help" facility that can show you more about all the lldb commands.
(lldb) help process launch
would have shown you this option.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With