This is the mail archive of the crossgcc@cygnus.com mailing list for the crossgcc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Missing environ definition in EGCS 1.1.1 build


"Michael K. Elwood" <mkelwood@mail.qsicorp.com> writes:
> I'm trying to build a EGCS 1.1.1 cross compiler for H8/300, hosted on 
> WinNT (mingw32).

Brave man! 

> When the build gets to the link for cc1.exe, it croaks, complaining 
> that _environ is undefined. I searched a bit; toplev.c and a couple 
> other files define
> 
> extern char **environ
> 
> which I assume points to a list of environment variable strings. I 
> couldn't find where environ is actually defined. Is this supposed to 
> be passed in from the environment? Where is the actual definition?
> 

This, ``extern int errno'' and a few others are causes of much grief 
in lots of software. These can be macros, and maintainers need to keep 
that in mind, especially when they're dealing with multi-threaded 
systems and/or weird ones (MS runtime qualifies for both).

You may want to take a look at my mingw patches for gdb 4.17.1.

  ftp://ftp.xraylith.wisc.edu/pub/khan/gnu-win32/mingw32/ports/

This and other problems are fixed as well.

Regards,
Mumit

_______________________________________________
New CrossGCC FAQ: http://www.objsw.com/CrossGCC
_______________________________________________
To remove yourself from the crossgcc list, send
mail to crossgcc-request@cygnus.com with the
text 'unsubscribe' (without the quotes) in the
body of the message.