From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: gud.el gdb --cd and libtool Date: Sat, 09 Nov 2002 06:55:08 -0500 Sender: emacs-devel-admin@gnu.org Message-ID: References: Reply-To: rms@gnu.org NNTP-Posting-Host: main.gmane.org X-Trace: main.gmane.org 1036844501 15113 80.91.224.249 (9 Nov 2002 12:21:41 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Sat, 9 Nov 2002 12:21:41 +0000 (UTC) Cc: emacs-devel@gnu.org Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18AUcN-0003vc-00 for ; Sat, 09 Nov 2002 13:21:39 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 18AUmK-0003vC-00 for ; Sat, 09 Nov 2002 13:31:56 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 18AUWJ-0001ZA-00; Sat, 09 Nov 2002 07:15:23 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10) id 18AUIQ-000519-00 for emacs-devel@gnu.org; Sat, 09 Nov 2002 07:01:02 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10) id 18AUEW-0004I7-00 for emacs-devel@gnu.org; Sat, 09 Nov 2002 06:57:31 -0500 Original-Received: from fencepost.gnu.org ([199.232.76.164]) by monty-python.gnu.org with esmtp (Exim 4.10) id 18AUCj-00041a-00 for emacs-devel@gnu.org; Sat, 09 Nov 2002 06:55:09 -0500 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.10) id 18AUCi-0001Az-00; Sat, 09 Nov 2002 06:55:08 -0500 Original-To: jas@extundo.com In-reply-to: (message from Simon Josefsson on Fri, 08 Nov 2002 11:35:21 +0100) Errors-To: emacs-devel-admin@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.devel:9281 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:9281 Does this change fix it? *** gud.el.~1.161.~ Mon Oct 21 15:26:25 2002 --- gud.el Sat Nov 9 05:53:52 2002 *************** *** 406,413 **** (interactive (list (gud-query-cmdline 'gdb))) (gud-common-init command-line ! #'(lambda (file args) ! `("-cd" ,(expand-file-name default-directory) . ,args)) 'gud-gdb-marker-filter 'gud-gdb-find-file) (set (make-local-variable 'gud-minor-mode) 'gdb) --- 406,412 ---- (interactive (list (gud-query-cmdline 'gdb))) (gud-common-init command-line ! #'(lambda (file args) args) 'gud-gdb-marker-filter 'gud-gdb-find-file) (set (make-local-variable 'gud-minor-mode) 'gdb) *************** *** 2233,2238 **** --- 2232,2238 ---- (defun gud-common-init (command-line massage-args marker-filter &optional find-file) (let* ((words (split-string command-line)) (program (car words)) + (dir default-directory) ;; Extract the file name from WORDS ;; and put t in its place. ;; Later on we will put the modified file name arg back there. *************** *** 2256,2261 **** --- 2256,2262 ---- file-subst))) (filepart (and file-word (concat "-" (file-name-nondirectory file))))) (pop-to-buffer (concat "*gud" filepart "*")) + (setq default-directory dir) ;; Set default-directory to the file's directory. (and file-word gud-chdir-before-run