delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2002/06/06/01:58:04

Date: Thu, 6 Jun 2002 08:15:19 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Larry Palmer <acts AT concentric DOT net>
cc: djgpp AT delorie DOT com
Subject: Re: Is it correct that GDB cannot be run inside emacs in windows98 environment?
In-Reply-To: <ufss30bdb2b6bc@corp.supernews.com>
Message-ID: <Pine.SUN.3.91.1020606080823.15110G-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Wed, 5 Jun 2002, Larry Palmer wrote:

> I'm used to working on sparcstations, doing all my coding in emacs and
> running gdb for source line debugging inside the editor (meta-x gdb).  I'm
> trying to set up a windows development environment (keeping dual-boot
> windows and linux systems both constantly healthy and up to date has just
> gotten to be too time consuming, and I want to cut down to one OS), but I'd
> like to preserve that way of working.  I'm starting to get the impression
> that this won't be possible however - that I can use emacs, and gdb, but not
> both together, because they require separate processes.

More accurately, the Emacs GUD interface to debuggers requires support 
for asynchronous subprocesses.  The DJGPP port of Emacs doesn't support 
that.

> Is that correct?

Yes, unfortunately.

> Or is my info out of date, or have I possibly
> misunderstood?  Is there any way to debug with GDB inside emacs under
> windows 98?  I'm using emacs 21.2.1 by the way, although I've tried older
> versions as well.  Basically the process just hangs as soon as I type "run",
> and pretty much results in a fairly imminent reboot.

What port of Emacs is that?  If that's the Windows port (so-called 
NTEmacs), then async subprocesses _are_ supported, but you need a Windows 
port of GDB to be able to use it from Emacs.  That's because the pipe 
simulation in NTEmacs is incompatible with the DJGPP termios library used 
by GDB, and so the DJGPP port of GDB simply doesn't know its standard I/O 
handles are redirected to a pipe, and still uses BIOS functions to read 
input and write output.  That's why the session hangs.

In sum, debugging DJGPP programs from within Emacs on Windows is 
currently impossible.  What I normally do is run GDB from the command 
line in another DOS box, while using Emacs to navigate the sources.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019