Thread View: gnu.gdb.bug
1 messages
1 total messages
Started by Gill Bates
Sun, 03 Mar 2002 04:11
cygwin gdb does not pass along exported enviornment variables
Author: Gill Bates
Date: Sun, 03 Mar 2002 04:11
Date: Sun, 03 Mar 2002 04:11
62 lines
2598 bytes
2598 bytes
I am suprised to discover:
WEASEL:> export Var1=1
WEASEL:> x
Var1=[1]
WEASEL:> gdb -nw x
GNU gdb 5.0 (20010428-3)
Copyright 2001 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for
details.
This GDB was configured as "i686-pc-cygwin"...
(gdb) run
Starting program: /home/harold/win32_1-0/mainsail/build/bin/x.exe
ntdll.dll: No such file or directory.
Var1=[NULL]
Program exited normally.
(gdb) quit
WEASEL:>
cat x.c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
int
main (int argc, char *argv[])
{
char *env;
env = getenv ("Var1");
printf ("Var1=[%s]\n", env==NULL?"NULL":env);
return 0;
}
gcc -g x.c -o x
gcc -dumpversion
2.95.3-5
Maybe the problem is due to:
ntdll.dll: No such file or directory.
But, dunno what that means either...
Also:
bash --version
GNU bash, version 2.05a.0(2)-release (i686-pc-cygwin)
Copyright 2001 Free Software Foundation, Inc.
Anybody know what's going on? is this normal behavior for cygwin-gdb.
It certainly does not work that way under Unix... Is there a gdb
command option to say "please pass along exported variables" ?
Thanks for any help!!!
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads