Subject: Re: PowerMacintosh, anyone?
To: None <port-powerpc@NetBSD.ORG>
From: Nagae Hidetake <nagae@mickey.ai.kyutech.ac.jp>
List: port-powerpc
Date: 12/09/1997 09:50:25
From: Christoph Badura <bad@ora.de>
Subject: Re: PowerMacintosh, anyone?
Date: Tue, 9 Dec 1997 00:20:55 +0100 (MET)

> In hanse-ml.netbsd.port-powerpc you write:
> 
> >   The file `crt0.o' is needed to generate *executable* files.  You
> >don't need it to generate *object* files.
> 
> Wolfgang wants to say that you can generate crt0.o from the sources with
> your cross-compiler toolchain.

   I think so.

   We can generate `crt0.o' from `crt0.c' with the cross-compiler.
Mr. Sunagawa is wondering if he need `crt0.o' to build cross-compiler
itself.  If so, this is the problem of chicken-and-egg.  In fact,
`INSTALL' of GCC says to get these libraries via ftp.

   What I want to say is that the cross-compiler doesn't need the
target's libraries to generate `.o' files.  They are needed to
generate `a.out'.  To build the cross-compiler, we need the host's
`crt0.o', not the target's one.  So we can generate `crt0.o' from
`crt0.c' without the target's libraries.

   1. Build the cross-compiler.  We don't need the target's libraries
      in this step.  (It is linked with the host's libraries.)

   2. Build the target's libraries with the cross-compiler.  In this
      step, we generate only `.o' files.

   3. Now we get the full cross-compiler.


   BTW, Sunagawa-san, did you see this file?

	ftp://ftp.netbsd.org/pub/arch/powerpc/tools/README
----
Nagae Hidetake  mailto:nagae@mickey.ai.kyutech.ac.jp
                http://www.tk.airnet.ne.jp/nagae/
    Kyushu Institute of Technology, Fukuoka, Japan