This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: 2.95,2 bug; can not create cross compiler
- To: Mike Stump <mrs at windriver dot com>
- Subject: Re: 2.95,2 bug; can not create cross compiler
- From: "H . J . Lu" <hjl at lucon dot org>
- Date: Thu, 18 Nov 1999 11:38:15 -0800
- Cc: jbuck at synopsys dot COM, gcc-bugs at gcc dot gnu dot org, gcc at gcc dot gnu dot org,pfeifer at dbai dot tuwien dot ac dot at, schweitz at nortelnetworks dot com
- References: <199911181929.LAA25056@kankakee.wrs.com>
On Thu, Nov 18, 1999 at 11:29:42AM -0800, Mike Stump wrote:
> > Date: Thu, 18 Nov 1999 08:10:14 -0800 (PST)
> > From: hjl@lucon.org (H.J. Lu)
>
> > I don't use/like --with-headers. The header file is not the only
> > problem. I have run into those lib*.a lib*.so/crt*.o problems. Here
> > is a sanity check I use. BTW, you probably will only see those
> > problems when you use a full C library like glibc 2, libc 5,
> > ... Newlib is ok.
>
> > +if [ x${target} != x${build} -a x${build} = x${host} ]; then
> > + if [ ! -d ${prefix}/lib/gcc-lib/${target_alias}/${gcc_version} ]; then
> > + echo "Please create the directory:" 1>&2
> > + echo 1>&2
> > + echo " ${prefix}/lib/gcc-lib/${target_alias}/${gcc_version}" 1>&2
> > + echo 1>&2
> > + echo "first for successful cross-compilaition." 1>&2
> > + exit 1
> > + fi
> > +fi
> > +
>
> in a make file fragment for the OS. Works fine, except for the
> necessity of making the $(libsubdir)/$(unlibsubdir) directory in the
> install tree at _build_ time, though I guess copying the headers to
> sys-include is at least as bad, as it happens during configure (even
> before build). HJ, why didn't you just make the directory?
>
I am building the cross compiler to be installed under /usr/......
where only root can make a directory. But I don't like to compile gcc
as root. However, I do make the directory in my cross compiler rpm spec
file. I have something like
mkkdir -p ${prefix}/lib/gcc-lib/${target_alias}/${gcc_version}
before configuring the cross compiler since I usually build RPM as
root.
H.J.