[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: suppressing gdb subprocess control characters? (was Re: emacs gdb su
From: |
Peter Dyballa |
Subject: |
Re: suppressing gdb subprocess control characters? (was Re: emacs gdb subproccess ignores printf (stdout isn't flushed ?) on OS X) |
Date: |
Mon, 21 Feb 2005 01:21:04 +0100 |
Am 21.02.2005 um 00:08 schrieb Mike Garey:
^[[2A
^[[0Khello, world!
gdb or Emacs or both think they're running in a DEC terminal or such,
so they're sending ANSI escape codes to it to position the text
somewhere on the terminal's screen, or to set it bold, blinking, ...
Since I haven't used gdb for so many years I actually have no idea --
have you seen the invisible directory .MacOSX in you home directory? It
contains a file environment.plist. To edit it you'll need some of the
Developer Tools, the Property List Editor, in
/Developer/Applications/Utilities. Just type in Terminal (or Carbon
Emacs) "open ~/.MacOSX/environment.plist" and it'll appear. Now you
could add a new environment variable TERM and give it the value emacs,
or dumb. But be careful: some applications might fail after a new login
(that's needed to make the new setting/sibling active)!
A less dangerous setting would be in the gdb section. AFAIR you can
trim its run-time environment. Maybe here's a choice to set the
TERMinal value to something dumb, something that can't be controlled by
ANSI escape sequences. Just read a bit of the documentation!
--
Greetings
Pete
One doesn't expect governments to obey the law because of some
higher moral development. One expects them to obey the law because
they know that if they don't, those who aren't shot will be hanged.
--Michael Shirley