public inbox for crossgcc@sourceware.org
 help / color / mirror / Atom feed
* cross-gcc problem when building libraries for pc-linux
@ 2000-12-15  8:40 Michael2.Roth
  2000-12-18 10:33 ` Kai Ruottu
  2000-12-26 22:58 ` gcc link to library built with Sun-CC Bin Zhou
  0 siblings, 2 replies; 3+ messages in thread
From: Michael2.Roth @ 2000-12-15  8:40 UTC (permalink / raw)
  To: crossgcc

Hi all,

perhaps someone can comment on my problem building a cross-GCC:

I'm trying to make a cygwin hosted GCC generating pc-linux target code (I used
--target=i686-pc-linux-gnu). Building the binutils works fine, the gcc-core
also. Trying the full gcc package results in the following error message

/usr/local/src/gcc-2.95.2/libiberty/strerror.c:461: conflicting types for
`sys_errlist'
/usr/local/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/../../../../i686-pc-linux-gnu/include/stdio.h:557:

previous declaration of `sys_errlist'
make[1]: *** [strerror.o] Error 1
make: *** [all-target-libiberty] Error 2

Well, if I ignore these (or similar) messages, install the compiler and then
take the libraries from the target system for linking, everything is working.
However, I would like to know why I cannot build these libraries locally.
Obviously, I took the wrong header files from the target system - but which ones
are correct? The target Linux runs egcs-2.91.66, and I simply took the header
files from /usr/include - perhaps I was wrong?

Thanks a lot,

Michael






------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: cross-gcc problem when building libraries for pc-linux
  2000-12-15  8:40 cross-gcc problem when building libraries for pc-linux Michael2.Roth
@ 2000-12-18 10:33 ` Kai Ruottu
  2000-12-26 22:58 ` gcc link to library built with Sun-CC Bin Zhou
  1 sibling, 0 replies; 3+ messages in thread
From: Kai Ruottu @ 2000-12-18 10:33 UTC (permalink / raw)
  To: Michael2.Roth; +Cc: crossgcc

Michael2.Roth@RSD.rohde-schwarz.com wrote:
> 
> perhaps someone can comment on my problem building a cross-GCC:
> 
> I'm trying to make a cygwin hosted GCC generating pc-linux target code (I used
> --target=i686-pc-linux-gnu). Building the binutils works fine, the gcc-core
> also. Trying the full gcc package results in the following error message
> 
> /usr/local/src/gcc-2.95.2/libiberty/strerror.c:461: conflicting types for
> `sys_errlist'
> /usr/local/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/../../../../i686-pc-linux-gnu/include/stdio.h:557:

 As you can see, the search paths go through the

    /usr/local/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/

and as already told by Nathan Knuth, pre-creating this directory is an essential
thing for any target stuff to be found... A bug seen with all the sources having
the 'relative search path' patches installed, like the Cygwin/Mingw ones.  BTW,
using the '--with-headers=...' while configuring as the workaround is overkill...

 I have many times claimed on this list that the plain vanilla gcc-2.95.2 sources
use the relative paths, but this seems to be pure bullshit... So it was a surprise
for me to look at the Mumit Khan's gcc-2.95.2-1 Win32-patches again when trying to
check whether the RedHat EDK sources have them already installed...

> previous declaration of `sys_errlist'
> make[1]: *** [strerror.o] Error 1
> make: *** [all-target-libiberty] Error 2

 The target-stuff checking during configure failed because the stuff was not found...
Linux headers and libs have the 'sys_errlist', but when not finding it, the obvious
thing is to assume that it doesn't exist... But when building the Makefile has those
'-I'-things which make the headers to be found, and the clash happens...

> Well, if I ignore these (or similar) messages, install the compiler and then
> take the libraries from the target system for linking, everything is working.
> However, I would like to know why I cannot build these libraries locally.
> Obviously, I took the wrong header files from the target system - but which ones
> are correct? The target Linux runs egcs-2.91.66, and I simply took the header
> files from /usr/include - perhaps I was wrong?

 You did the right things but the gcc-2.95.2 sources have bugs and a workaround like
using the 'make installdirs' or manually creating the '$prefix/lib/gcc-lib/$target/2.95.2'
is needed. I would assume the Cross-GCC FAQ mentioning this issue with gcc-2.95.2,
but perhaps it doesn't...

 Then there are the Cygwin 'gcc-2.95.2-[1234]' sources, which may have some bugs
fixed or not... The '-v' (during the build) and '-print-search-dirs' (stand-alone)
options used with the resulted 'xgcc' should tell what will be found and where...
 
Cheers, Kai



------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

* gcc link to library built with Sun-CC.
  2000-12-15  8:40 cross-gcc problem when building libraries for pc-linux Michael2.Roth
  2000-12-18 10:33 ` Kai Ruottu
@ 2000-12-26 22:58 ` Bin Zhou
  1 sibling, 0 replies; 3+ messages in thread
From: Bin Zhou @ 2000-12-26 22:58 UTC (permalink / raw)
  To: crossgcc, crossgcc

Hi all,

I am using gcc to build my project on Solaris 8 for Intel, gcc works fine,
the problem is that I need link to a library which is built with sun CC
compiler, will this work?

Thanks for help.
Binzhou



------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2000-12-26 22:58 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-12-15  8:40 cross-gcc problem when building libraries for pc-linux Michael2.Roth
2000-12-18 10:33 ` Kai Ruottu
2000-12-26 22:58 ` gcc link to library built with Sun-CC Bin Zhou

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).