Mercurial > octave
changeset 28782:0ee399c4659c stable
__debug_octave__.m: Check for "lldb" on Mac (bug #59156).
author | Markus Mützel <markus.muetzel@gmx.de> |
---|---|
date | Tue, 22 Sep 2020 19:42:16 +0200 |
parents | fd7839a6c59f |
children | 5cfc3e1b7ff4 9d7f90354b4f |
files | scripts/testfun/__debug_octave__.m |
diffstat | 1 files changed, 15 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/testfun/__debug_octave__.m Tue Sep 22 19:59:55 2020 -0700 +++ b/scripts/testfun/__debug_octave__.m Tue Sep 22 19:42:16 2020 +0200 @@ -50,16 +50,27 @@ endif if (nargin == 0) - status = system ("gdb --version"); - if (status != 0) - error ("unable to execute gdb"); - endif if (ismac ()) + status = system ("lldb --version"); + if (status != 0) + error ("unable to execute lldb"); + endif command_string = "osascript -e 'tell application \"Terminal\" to do script \"lldb -p %d\"'"; + elseif (isunix ()) + status = system ("gdb --version"); + if (status != 0) + error ("unable to execute gdb"); + endif command_string = "x-terminal-emulator -e gdb -p %d"; + elseif (ispc ()) + status = system ("gdb --version"); + if (status != 0) + error ("unable to execute gdb"); + endif command_string = "cmd /c start gdb -p %d"; + else error ("unknown system -- unable to determine how to start debugger"); endif