Sender: nate AT cartsys DOT com Message-ID: <35A16A5D.B9ACF327@cartsys.com> Date: Mon, 06 Jul 1998 17:22:53 -0700 From: Nate Eldredge MIME-Version: 1.0 To: lqian AT uiuc DOT edu CC: djgpp AT delorie DOT com Subject: Re: DJGPP, \ and / References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Precedence: bulk Leiming Qian wrote: > > Hi, I am using Djgpp 2.0 in Windows 95, there is this problem that's > troubling me: it seems that programs like gdb still uses the UNIX / to > denote directory instead of using \ according to Windows convention, for > example: > > gdb H:\code\test.exe won't work, while > > gdb H:/code/test.exe would. > > The problem is I am using Codewright and UltraEdit (both are ``power'' > programming editors), they both provide one-click access, predefined menu > command or button command to common tasks like compiling and debugging, but > they all generate path information using \, thus gdb won't work correctly. > > Are there any options in Djgpp which can force those programs to recognize \ > notation? I think that's a bug in GDB. As a workaround, you can write a simple wrapper program which changes the slashes and calls `gdb', and use it instead: /* Untested */ #include #include #include int main(int argc, char *argv[]) { char *p; if (argv[1]) for (p = argv[1]; *p; p++) if (*p == '\\') *p = '/'; execlp("gdb", "gdb", argv[1], NULL); /* If we get here, something's wrong */ perror("execlp"); return 1; } -- Nate Eldredge nate AT cartsys DOT com