This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: DOS/Windows-specific code: main.c
- To: Christopher Faylor <cgf at redhat dot com>
- Subject: Re: DOS/Windows-specific code: main.c
- From: Keith Seitz <keiths at cygnus dot com>
- Date: Tue, 8 May 2001 08:16:20 -0700 (PDT)
- cc: <gdb at sources dot redhat dot com>
On Tue, 8 May 2001, Christopher Faylor wrote:
> >If so, why is that needed? Doesn't Cygwin support the native Windows
> >file names with drive letters?
>
> Actually CYGWIN converts the HOME environment variable to "posix" format
> well before the code ever reaches here. I believe that this code is
> to accomodate gdbtk which might change the environment variable back
> to MS-DOS format explicitly. I remember trying to get rid of this
> years ago. Keith Seitz told me that I couldn't do that.
As I recall, HOME used to be set to a windows stye path. We certainly do
not set HOME anywhere. In fact, I see that in several places in gdbtk, we
*explicitly* convert HOME to cygwin/posix path from Windows-style path.
> Or, maybe this isn't needed anymore. Keith do you remember this? I
> think it may have been the first piece of email we ever exchanged.
We also used to get NULL from getenv when you do not start it up from a
shell (i.e, you double-click the icon). Perhaps all of this has changed
(for the better) now. I don't think this was gdbtk-specific. It was a
problem looking for gdb.ini on windows.
If cygwin dll _always_ sets HOME (as you imply), then we should be able to
just get rid of all of this. Just need to verify that ~/gdb.ini is found
and loaded on windows (both with a shell and without).
Keith