This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: introduce configure --with-sysroot


On Aug 22, 2002, Daniel Jacobowitz <drow@mvista.com> wrote:

> I second H-P's comment about --with-installed-sysroot.

Tell you what...  --with-sysroot might just as well refrain from
copying anything, and GCC could set itself up so as to use the very
pathname that was passed.  Then, we'd just have to tweak our build
scripts to do the copying from the outside.  I happen to find this
more elegant, even.

The only potential gotcha is that one must pass ugly pathnames as
arguments to --with-sysroot to get a relocatable tree: they must start
with ${gcc_tooldir} = ${libdir}/${libsubdir}/../../../..., and the
${libsubdir} part is not easy to guess right from the outside.

Alternatively, gcc could attempt to make the pathname relative, just
like it does for gcc_tooldir, but I dislike this option.  Perhaps we
could only make it relocatable if it starts with ${exec_prefix}.
How's that?

That said, I'd rather get the patch in with minimal changes, and
proceed from there.  I know what we have now works, and most of it has
been used successfully for a while.  Introducing changes may break
things in unexpected ways :-)

>> It also introduces %R as a spec

> I love it - I hadn't thought of this approach at all.

I liked it when I first saw it too.  I don't know who gets the credit
for it, though :-(

> Now, what would
> be really useful would be if I could specify where the sysroot would be
> copied

See the alternative I propose above.

> I've got the necessary patches to GNU ld to do this.

Cool!  Don't tell me you also have patches that will let us not have
to tweak the libc.so script in the target root, like we currently have
to do!  This would be awesome. ;-)

> I can clean them up and submit them if you want.

Sure, please do!  If we can unify on a single --with-sysroot option,
even better.

>> sysroot.  The latter searched for headers, crt*.o and libraries within
>> the sysroot, even after the entire tree was (i.e., the sysroot is
> 					     ^ moved, presumably.

yup

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                 aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist                Professional serial bug killer


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]