Subject: Re: gnu/usr.bin/gcc3/backend needs a cc and more ...
To: Jeremy C. Reed <firstname.lastname@example.org>
From: James Chacon <jmc@NetBSD.org>
Date: 02/10/2005 17:17:17
On Thu, Feb 10, 2005 at 03:02:54PM -0800, Jeremy C. Reed wrote:
> (Please CC me on replies. Thank you.)
> On Thu, 10 Feb 2005, James Chacon wrote:
> > > 1) lex not available for tools/binutils/build. My workaround was to set
> > > LEX=/home/reed/netbsd/hp700/tools/bin/nblex (This is already salo's PR #
> > > toolchain/29197.)
> > I'll look into this one tonight. Been meaning to work through a few of
> > these cross PR's
> > > 2) My cc is installed using pkgsrc and is not at /usr/bin/. So
> > > HOST_CC=/usr/gcc3/bin/cc. This is not a real problem.
> > That's documented I beleive
> I don't see it in BUILDING. And it is mentioned in tools/compat/README but
> only in the "SOLARIS" section (but tools/compat/README is for
> cross-compiling notes).
> > > 3) tools/file build needs a C++ preprocessor. So I defined
> > > CXXCPP=/home/reed/netbsd/hp700/tools/bin/hppa--netbsd-cpp
> > > I hope that is okay. Maybe I should have set to my /usr/gcc3/bin/cpp?
> > >
> > > Anyways, should this be set automatically? (Probably not since in tools.)
> > Hmmm...probably no reason it can't use the one that's spit out from
> > tools/gcc3
> Other than maybe the new cpp is not correct for the native cc used for
> building tools/file.
> Also, maybe tools/file somewhere can define CXXCPP automatically to
> HOST_CPP or other CPP. (I didn't even know there was a difference between
> C and C++ preprocessor.)
> > > 4) tools/groff needs C++. So I set
> > > HOST_CXX=/home/reed/netbsd/hp700/tools/bin/hppa--netbsd-c++ (since I had
> > > done similar with cpp above). But that still failed with:
> > >
> > > /home/reed/netbsd/hp700/tools/lib/gcc-lib/hppa--netbsd/3.3.3/../../../../hppa--n
> > > etbsd/bin/ld: crt0.o: No such file: No such file or directory
> > >
> > > So I used HOST_CXX=/usr/gcc3/bin/c++ and that worked.
> > I beleive this is documented also (that you need a C++ compiler). If it's
> > not fully documented about HOST_CXX file a PR for that.
> This HOST_CXX could probably be documented. I can commit a note about it.
> doc/BUILDING.mdoc says:
> The host system must have at least C and C++
> compilers in order to create the toolchain
> .Nm ( make
> is not required); all other tools are created as part of the
> build process.
> Maybe I could add:
> (Define HOST_CC and HOST_CXX in your environment to point to your
> compilers if in non-standard places or if you need to choose a specific
> Or maybe that could go in the "Environment variables" section.
Both can't hurt. Reference it under the build process to see environment
variables if you need to override/manually set these.