This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


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

-fpic/PIC clarification [Re: as.exe: bfd assertion fail... ]


On Tue, 15 Jun 1999, Mumit Khan wrote:

> This was a bug caused by -fPIC, which is unnecessary on x86-win32 where 
> all code is position independent. This has been fixed for a while now
> (I released egcs-1.1.2 Cygwin/Mingw binaries March 17), so I suggest 
> you upgrade your compiler. Quite a few other problems found in egcs-1.1 
> are fixed 1.1.2 as well.
>   
>   http://www.xraylith.wisc.edu/~khan/software/gnu-win32/
> 

Donn Terry just sent me a note pointing out my incorrect statement. What 
I meant to say was that -fPIC/pic in the usual sense conflicts with the 
MS DLL design, and makes no sense on x86-win32 (except perhaps on Interix).
It involves the issue about static vs dynamic fixup of shared libraries
and so on. Recent GCC versions simply ignore the flag, along with a 
warning, instead of silently creating bad code.

To recap, DO NOT use -fPIC/pic with egcs-1.1 if you don't want bad code.
With egcs-1.1.2 and newer, GCC will ignore this flag, ie, no bad code, 
and tell you that it's being ignored.

Apologies about the confusion.

Regards,
Mumit



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com


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