unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: Klaus Zeitler <kzeitler@lucent.com>, emacs-devel@gnu.org
Subject: Re: gdb call with core
Date: Fri, 12 May 2006 10:26:02 -0400	[thread overview]
Message-ID: <87ac9ntjcj.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <ur72z74c0.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 12 May 2006 16:36:15 +0300")

Eli> What happens if you type "M-x cd RET <path-to-core-dir> RET", before
Eli> invoking GDB (you may need to switch to a buffer that doesn't visit
Eli> any file, before you invoke `cd')?  Does it work then?
>> 
>> No, emacs always changes the default dir to the dir where the image resides.

Yes, and I've found it to be a pain as well.

> I can see why this is reasonable.  Why do you think it's bad?

He gave one example, there are plenty of others: I often want to run an
executable /dir1/foo under GDB (in Emacs) but in the current dir rather than
in /dir1, so I have to do M-x gdb ... and then inside GDB I need to change
back to where I was.  Also I've sometimes used .gdbinit files specific to
the place where I run the executable rather than where I compile it.

It's pretty easy to do M-x cd before doing M-x gdb (and it's not much more
typing since the extra dir you type in M-x cd is saved in the M-x gdb step)
if that's what you want, so I'd rather get rid of this annoying
`auto-cd' behavior of GUD.


        Stefan

  reply	other threads:[~2006-05-12 14:26 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-05-12  9:57 gdb call with core Klaus Zeitler
2006-05-12 11:25 ` Eli Zaretskii
2006-05-12 11:50   ` Klaus Zeitler
2006-05-12 13:36     ` Eli Zaretskii
2006-05-12 14:26       ` Stefan Monnier [this message]
2006-05-13  6:59         ` Nick Roberts
2006-05-13 16:25           ` Stefan Monnier
2006-05-13 21:45             ` Nick Roberts
2006-05-15  6:14       ` Klaus Zeitler
2006-05-15 20:37         ` Eli Zaretskii
     [not found] ` <17509.46549.5651.16043@localhost.localdomain>
2006-05-12 12:03   ` Klaus Zeitler

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ac9ntjcj.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=emacs-devel@gnu.org \
    --cc=kzeitler@lucent.com \
    /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 public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).