From: Stephen Leake <stephen_leake@member.fsf.org>
Subject: Starting multiple GUD session; doc problem
Date: Thu, 23 Nov 2006 12:03:14 -0500 [thread overview]
Message-ID: <ur6vu6qp9.fsf@member.fsf.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 976 bytes --]
I just tried to start two gdb sessions in one CVS Emacs session for
the first time (I've done this many times in Emacs 21). I got the
error message:
"gdb: Multiple debugging is only supported with "gdb --fullname"
So I dutifully added "--fullname" to the gdb command line:
gdb --annotate=3 --fullname gds-main_models_test.exe
and got the same error message. I read the GUD and GDB entries in the
Emacs manual, and the help message for `gdb'; no success. Finally I
read the Emacs lisp source code for gud, and found this comment in
gud.el (gud-gdb-marker-filter):
;; Check for annotations and change gud-minor-mode to 'gdba if
;; they are found.
It seems the real issue is the presence or absence of "--annotate=3",
not the presence of "--fullname". In fact, "--fullname" is not
necessary if compilation-search-path is set to include the source
directories.
So I suggest the attached patch to the Emacs manual (building.texi)
and a couple gud doc strings.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: gud.diff --]
[-- Type: text/x-patch, Size: 3601 bytes --]
Index: lisp/progmodes/gdb-ui.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/progmodes/gdb-ui.el,v
retrieving revision 1.191
diff -c -r1.191 gdb-ui.el
*** lisp/progmodes/gdb-ui.el 10 Nov 2006 09:38:11 -0000 1.191
--- lisp/progmodes/gdb-ui.el 23 Nov 2006 16:29:12 -0000
***************
*** 214,220 ****
;;;###autoload
(defun gdba (command-line)
! "Run gdb on program FILE in buffer *gud-FILE*.
The directory containing FILE becomes the initial working directory
and source-file directory for your debugger.
--- 214,220 ----
;;;###autoload
(defun gdba (command-line)
! "Run gdb in GUI mode on program FILE in buffer *gud-FILE*.
The directory containing FILE becomes the initial working directory
and source-file directory for your debugger.
Index: lisp/progmodes/gud.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/progmodes/gud.el,v
retrieving revision 1.116
diff -c -r1.116 gud.el
*** lisp/progmodes/gud.el 5 Sep 2006 03:40:54 -0000 1.116
--- lisp/progmodes/gud.el 23 Nov 2006 16:29:15 -0000
***************
*** 680,687 ****
default this command starts GDB using a graphical interface. See
`gdba' for more information.
! To run GDB in text command mode, set `gud-gdb-command-name' to
! \"gdb --fullname\" and include the pathname, if necessary."
(interactive (list (gud-query-cmdline 'gdb)))
(if (and gud-comint-buffer
--- 680,686 ----
default this command starts GDB using a graphical interface. See
`gdba' for more information.
! To run GDB in text command mode, delete \"--annotate=3\" from `gud-gdb-command-name'."
(interactive (list (gud-query-cmdline 'gdb)))
(if (and gud-comint-buffer
Index: man/building.texi
===================================================================
RCS file: /sources/emacs/emacs/man/building.texi,v
retrieving revision 1.109
diff -c -r1.109 building.texi
*** man/building.texi 7 Oct 2006 23:38:51 -0000 1.109
--- man/building.texi 23 Nov 2006 16:29:17 -0000
***************
*** 827,838 ****
@vindex gud-gdb-command-name
@findex gdba
! You can also run GDB in text command mode, like other debuggers. To
! do this, set @code{gud-gdb-command-name} to @code{"gdb --fullname"} or
! edit the startup command in the minibuffer to say that. You need to
! do use text command mode to run multiple debugging sessions within one
! Emacs session. If you have customized @code{gud-gdb-command-name} in
! that way, you can use @kbd{M-x gdba} to invoke GDB in graphical mode.
@menu
* GDB-UI Layout:: Control the number of displayed buffers.
--- 827,845 ----
@vindex gud-gdb-command-name
@findex gdba
! You can also run GDB in text command mode, like other debuggers.
! Emacs automatically switches to GUI mode if it sees annotations in the
! gdb output. GDB generates annotations when started with the command
! line option @code{"--annotate=3"}, which is set by default in
! @code{gud-gdb-command-name}. To run in text mode, you must customize
! @code{gud-gdb-command-name} to delete this option, or delete it from
! the startup command in the minibuffer.
!
! You need to use text command mode for the first and subsequent
! debugging sessions if you plan to run multiple debugging sessions
! within one Emacs session. If you have customized
! @code{gud-gdb-command-name} in that way, you can specify
! @code{"--annotate=3"} to invoke GDB in graphical mode.
@menu
* GDB-UI Layout:: Control the number of displayed buffers.
[-- Attachment #3: Type: text/plain, Size: 15 bytes --]
--
-- Stephe
[-- Attachment #4: Type: text/plain, Size: 142 bytes --]
_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel
next reply other threads:[~2006-11-23 17:03 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-11-23 17:03 Stephen Leake [this message]
2006-11-25 0:48 ` Starting multiple GUD session; doc problem Nick Roberts
2006-11-25 13:24 ` Stephen Leake
2006-11-25 14:43 ` Andreas Schwab
2006-11-26 4:53 ` Nick Roberts
2006-11-26 10:08 ` Stephen Leake
2006-11-26 2:01 ` Richard Stallman
2006-11-26 8:39 ` Nick Roberts
2006-11-26 9:38 ` Stephen Leake
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ur6vu6qp9.fsf@member.fsf.org \
--to=stephen_leake@member.fsf.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.