public inbox for crossgcc@sourceware.org
 help / color / mirror / Atom feed
* RE: Trying to build a cross compiler from linux to netbsd...
@ 2001-01-04  4:25 David Korn
  2001-04-01  0:00 ` David Korn
  0 siblings, 1 reply; 28+ messages in thread
From: David Korn @ 2001-01-04  4:25 UTC (permalink / raw)
  To: 'karuottu@freenet.hut.fi', Alexandre Oliva; +Cc: munroe, crossgcc

>-----Original Message-----
>From: Kai Ruottu [ mailto:kai.ruottu@luukku.com ]
>Sent: 03 January 2001 11:09


>---------------------- clip --------------------------------
>"Some options which only apply to building cross compilers:
>
>--with-headers=dir -- Specifies a directory which has target include
>    files. This options is required when building a cross compiler, if
>    ${prefix}/${target}/sys-include doesn't pre-exist. These include
>    files will be copied into the gcc install directory. Fixincludes
>    will be run on these files to make them compatible with gcc. "
>---------------------- clip --------------------------------
>
>can cause thoughts like (from Dave Korn):
>
>>  The words 'REQUIRED when building a cross compiler" and
>>"if $prefix/$target/sys-include doesn't exist" makes it seem like you
>>*must* use --with-headers, or put the headers into sys-include.
>
> When using my "bad English", the missing "the" in the clause would
>say clearly that the "target include files" cannot mean the standard
>C headers for the target, only some 'unspecified headers for the target'
>which need some fixing and must either be preinstalled into
>'${prefix}/${target}/sys-include', or pointed with '--with-headers'.

  Kai, your English is excellent! I think it's simply a matter of the
word 'the' being omitted/elided/implicit in that sentence; it's a somewhat
colloquial/slang kind of english usage. We tend to be a bit imprecise
with our definite articles. Of course, I cannot know for sure the intent
behind the original phrasing; this is just how I interpret it.

> My understanding for the purpose of the 'sys-include' is that it is
>the equivalent of '/usr/local/include' for a native compiler, ie. it
>was aimed for the system-specific or 3rd-party headers, searched before
>the standard C-headers (the 'sys-' comes from the 'system-specific').

  Surely unfixed headers are of no use at all ?

  There seems to be an awful lot of include directories around. I find (in
order of search path)

     $prefix/lib/gcc-lib/$target/$version/include
        - contains  fixinc'ed headers after 'make install'
     $prefix/$target/sys-include
        - contains original target headers
     $prefix/$target/include
        - nothing gets put here by gcc build/install at all.

 Now, I don't understand why we need this many directories.  It seems that
the documentation has not been kept up to date with the way things work.

> But for the 'universal case', I wouldn't suggest anybody to use the
>'--with-headers=' before the question "Why?" has been answered. There
>must be some sane reason to try to fix the standard C-headers for the
>target...

  Because libgcc needs to be built with fixed headers during the build
process before install has taken place ? 

       DaveK

-- 
The Boulder Pledge: "Under no circumstances will I ever purchase anything 
offered to me as the result of an unsolicited email message. Nor will I 
forward chain letters, petitions, mass mailings, or virus warnings to large 
numbers of others. This is my contribution to the survival of the online
community."


**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.

This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.

www.mimesweeper.com
**********************************************************************

------
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] 28+ messages in thread
* RE: Trying to build a cross compiler from linux to netbsd...
@ 2001-01-04  4:22 David Korn
  2001-04-01  0:00 ` David Korn
  0 siblings, 1 reply; 28+ messages in thread
From: David Korn @ 2001-01-04  4:22 UTC (permalink / raw)
  To: crossgcc

>-----Original Message-----
>From: Rod Stewart [ mailto:stewart@nexus.carleton.ca ]
>Sent: 03 January 2001 02:58

  [snip entire body of letter]

>-Rms


  :) You may cause some confusion signing your name this way when talking
about gcc <vbg>

        DaveK
-- 
The Boulder Pledge: "Under no circumstances will I ever purchase anything 
offered to me as the result of an unsolicited email message. Nor will I 
forward chain letters, petitions, mass mailings, or virus warnings to large 
numbers of others. This is my contribution to the survival of the online
community." 


**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.

This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.

www.mimesweeper.com
**********************************************************************

------
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] 28+ messages in thread
* Trying to build a cross compiler from linux to netbsd...
@ 2001-01-02 18:52 Dick Munroe
  2001-01-02 18:57 ` Rod Stewart
                   ` (3 more replies)
  0 siblings, 4 replies; 28+ messages in thread
From: Dick Munroe @ 2001-01-02 18:52 UTC (permalink / raw)
  To: crossgcc

using egcs 1.0.3a (other compilers aren't an option, unfortunately, the
vendor says that this is the only one guaranteed to work).  Anyway, we
have Linux boxes and need to cross compile to Netbsd (more particularly,
i386 a.out format executables).  The following is one attempt:

Binutils builds with:

../binutils-2.10.1/configure --host=i686-pc-linux-gnu --target=i386-aout
--prefix=/home/usr/local

so that much of the cross compiler tools seems to work fine (the tools
may not, but that's for later).

Trying to build egcs 1.0.3a with:

../egcs-1.0.3a/configure --host=i686-pc-linux-gnu --target=i386-aout
--prefix=/home/usr/local

Which ultimately generates the following error:

ln collect2 ld
/home/egcs/gcc/xgcc -B/home/egcs/gcc/ -DCROSS_COMPILE -DIN_GCC    -g -O2

-I./include  -I. -I../../egcs-1.0.3a/gcc -I../../egcs-1.0.3a/gcc/config
\
-c ../../egcs-1.0.3a/gcc/objc/hash.c -o objc/hash.o
In file included from ../../egcs-1.0.3a/gcc/objc/hash.c:31:
../../egcs-1.0.3a/gcc/objc/runtime.h:31: stdio.h: No such file or
directory
../../egcs-1.0.3a/gcc/objc/runtime.h:32: ctype.h: No such file or
directory
In file included from ../../egcs-1.0.3a/gcc/objc/runtime.h:38,
                 from ../../egcs-1.0.3a/gcc/objc/hash.c:31:
include/objc/objc-api.h:33: stdio.h: No such file or directory
make[1]: *** [objc/hash.o] Error 1
make[1]: Leaving directory `/home/egcs/gcc'
make: *** [all-gcc] Error 2

and checking objc-api.h, it requires stdio.h and ctype.h and, equally
obviously it's not finding them.  configure.in and makefile.in are a
second (more like sixth) language to me so I'm having problems figuring
out exactly what's going on here, but it looks as if xgcc isn't picking
up the system include files and hasn't supplied links to the needed ones
during the initial configure phase and I can't figure out how to get the
-idirafter (which was my initial thought on fixing the problem) put in
the right place.

I've tried a couple other things with no success, specifically:

../egcs-1.0.3a/configure --host=I386-unknown-linux-gnu
--target=i386-unknown-netbsd --prefix=/home/usr/local

Which generates a different error but related in the sense that there is
no include file for machine/ansi.h (required for all netbsd-like
compiles).

cp ../../egcs-1.0.3a/gcc/README-fixinc include/README
chmod a+r include/README
touch stmp-int-hdrs
rm -f SYSCALLS.c tmp-SYSCALLS.s
cat ../../egcs-1.0.3a/gcc/sys-types.h ../../egcs-1.0.3a/gcc/sys-protos.h
> SYSCALLS.c
/home/egcs/gcc/xgcc -B/home/egcs/gcc/ -DCROSS_COMPILE -DIN_GCC    -g -O2
-I./include     -I. -I../../egcs-1.0.3a/gcc -I../../egcs-1.
0.3a/gcc/config \
  -aux-info SYSCALLS.c.X -S -o tmp-SYSCALLS.s SYSCALLS.c
In file included from SYSCALLS.c:86:
include/stddef.h:28: machine/ansi.h: No such file or directory
make[1]: *** [SYSCALLS.c.X] Error 1
make[1]: Leaving directory `/home/egcs/gcc'
make: *** [all-gcc] Error 2

So clearly I'm missing the boat on something and what is the question.

Any and all help will be appreciated.

TIA

Dick Munroe






------
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] 28+ messages in thread

end of thread, other threads:[~2001-04-01  0:00 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-01-04  4:25 Trying to build a cross compiler from linux to netbsd David Korn
2001-04-01  0:00 ` David Korn
  -- strict thread matches above, loose matches on Subject: below --
2001-01-04  4:22 David Korn
2001-04-01  0:00 ` David Korn
2001-01-02 18:52 Dick Munroe
2001-01-02 18:57 ` Rod Stewart
2001-04-01  0:00   ` Rod Stewart
2001-01-02 19:37 ` Alexandre Oliva
2001-01-03  4:32   ` Kai Ruottu
2001-01-03  4:38     ` Alexandre Oliva
2001-01-03 14:21       ` Kai Ruottu
2001-01-03 14:48         ` Alexandre Oliva
2001-01-04  2:55           ` Kai Ruottu
2001-04-01  0:00             ` Kai Ruottu
2001-04-01  0:00           ` Alexandre Oliva
2001-04-01  0:00         ` Kai Ruottu
2001-04-01  0:00       ` Alexandre Oliva
2001-04-01  0:00     ` Kai Ruottu
2001-01-03  8:33   ` Dick Munroe
2001-01-04  2:55     ` Kai Ruottu
2001-01-05  3:59       ` Kai Ruottu
2001-04-01  0:00         ` Kai Ruottu
2001-04-01  0:00       ` Kai Ruottu
2001-04-01  0:00     ` Dick Munroe
2001-04-01  0:00   ` Alexandre Oliva
2001-01-03  4:33 ` Kai Ruottu
2001-04-01  0:00   ` Kai Ruottu
2001-04-01  0:00 ` Dick Munroe

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).