From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stephen Leake Newsgroups: gmane.emacs.devel Subject: Starting multiple GUD session; doc problem Date: Thu, 23 Nov 2006 12:03:14 -0500 Message-ID: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: sea.gmane.org 1164407367 11666 80.91.229.2 (24 Nov 2006 22:29:27 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 24 Nov 2006 22:29:27 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Nov 24 23:29:23 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1GnjXg-0005JO-4E for ged-emacs-devel@m.gmane.org; Fri, 24 Nov 2006 23:29:08 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GnjXf-000614-Hq for ged-emacs-devel@m.gmane.org; Fri, 24 Nov 2006 17:29:07 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1GnjXS-0005zM-0J for emacs-devel@gnu.org; Fri, 24 Nov 2006 17:28:54 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1GnjXO-0005vh-1J for emacs-devel@gnu.org; Fri, 24 Nov 2006 17:28:53 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GnjXN-0005vV-Ly for emacs-devel@gnu.org; Fri, 24 Nov 2006 17:28:49 -0500 Original-Received: from [199.232.41.67] (helo=mx20.gnu.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1GnjXN-0002cQ-Hf for emacs-devel@gnu.org; Fri, 24 Nov 2006 17:28:49 -0500 Original-Received: from [207.172.157.102] (helo=smtp02.lnh.mail.rcn.net) by mx20.gnu.org with esmtp (Exim 4.52) id 1GnI0o-0006Be-Oj for emacs-devel@gnu.org; Thu, 23 Nov 2006 12:05:23 -0500 Original-Received: from mr08.lnh.mail.rcn.net ([207.172.157.28]) by smtp02.lnh.mail.rcn.net with ESMTP; 23 Nov 2006 12:03:22 -0500 X-IronPort-AV: i="4.09,453,1157342400"; d="diff'?scan'208"; a="353704749:sNHT42879652" Original-Received: from smtp01.lnh.mail.rcn.net (smtp01.lnh.mail.rcn.net [207.172.4.11]) by mr08.lnh.mail.rcn.net (MOS 3.7.5a-GA) with ESMTP id HRL87300; Thu, 23 Nov 2006 12:03:19 -0500 (EST) Original-Received: from 208-59-165-113.c3-0.slvr-ubr1.lnh-slvr.md.cable.rcn.com (HELO ACS1100007992) ([208.59.165.113]) by smtp01.lnh.mail.rcn.net with ESMTP; 23 Nov 2006 12:03:17 -0500 X-IronPort-AV: i="4.09,453,1157342400"; d="diff'?scan'208"; a="317553350:sNHT53696468" Original-To: emacs-devel User-Agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3 (windows-nt) X-Junkmail-Status: score=10/50, host=mr08.lnh.mail.rcn.net X-Junkmail-SD-Raw: score=unknown, refid=str=0001.0A090203.4565D38C.001E,ss=1,fgs=0, ip=207.172.4.11, so=2006-05-09 23:27:51, dmn=5.2.121/2006-09-27 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:62743 Archived-At: --=-=-= 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. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=gud.diff 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. --=-=-= -- -- Stephe --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel --=-=-=--