[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RFC PATCH 0/8] sysroot support
From: |
Thierry Reding |
Subject: |
Re: [RFC PATCH 0/8] sysroot support |
Date: |
Fri, 23 Jul 2010 09:23:30 +0200 |
User-agent: |
Mutt/1.5.20 (2009-06-14) |
* Charles Wilson wrote:
> On 7/22/2010 2:36 PM, Paolo Bonzini wrote:
> > This patch series is on top of 04329d83555b5f8d2fd02428418a79ea392b2d91.
> > The basic idea is to look for -L= and -R= to expand the sysroot, and for
> > the sysroot to remove it in .la files.
> >
> > Some missing testcases are hinted at in sysroot.at. I think they would
> > already work with the patch as is. However, I haven't retested this at
> > all, so I trust my old runs from mid 2009 which were done with Fedora 12
> > and its mingw cross-compilation environment.
> >
> > Sorry for the delay.
>
> Thanks for the patch. I haven't been able to test it yet, but looking
> through it, it appears that the 'use case' is:
>
> on $build, when building a libtoolized project, you configure as:
>
> path/to/configure --build=$build --host=$host \
> --prefix=$sysroot_of_compiler$prefix_for_host \
> ...
>
> and then compile and install as usual (somehow arranging that -sysroot
> is passed to libtool, whenever appropriate). Is that correct?
>
>
> The reason I ask, is it sure would be nice if one could instead do this:
>
> path/to/configure --build=$build --host=$host \
> --prefix=$prefix_for_host \
> ...
>
> and the compile as usual -- but when installing, do
>
> make install prefix=$sysroot_of_compiler$prefix_for_host
>
> (again, somehow arranging for libtool to get the -sysroot option).
>
> This way, there is little danger that the value of $sysroot_of_compiler
> would get hardcoded into any of the binaries, especially as they may one
> day be deployed to $host where they will live in $prefix_for_host,
> without a $sysroot_of_compiler in sight.
>
> Or am I misunderstanding something?
The latter is, I think, the most common approach. With automake-based projects
the final step is usually:
make install DESTDIR=$sysroot
which really ends up being the same as you mentioned.
In my setup I also use one cross-compiler for different sysroots, so I pass
'--sysroot $sysroot' via CFLAGS/LDFLAGS into the configure script. AFAIK this
merely substitutes the default compiler sysroot. Looking at Paolo's patches
this should be supported. I hope to get around to testing the patches
sometime soon.
Thierry
signature.asc
Description: Digital signature
- [RFC PATCH 0/8] sysroot support, Paolo Bonzini, 2010/07/22
- [RFC PATCH 1/8] handle sysroot flags, Paolo Bonzini, 2010/07/22
- [RFC PATCH 2/8] fix buglet, Paolo Bonzini, 2010/07/22
- [RFC PATCH 3/8] provide shell functions to configure, Paolo Bonzini, 2010/07/22
- [RFC PATCH 4/8] Add --with-sysroot, Paolo Bonzini, 2010/07/22
- [RFC PATCH 5/8] add a basic sysroot test, Paolo Bonzini, 2010/07/22
- [RFC PATCH 6/8] teach libtool -L= and -R=, Paolo Bonzini, 2010/07/22
- [RFC PATCH 7/8] handle sysrooted paths when reading dependencies to la files, Paolo Bonzini, 2010/07/22
- [RFC PATCH 8/8] emit sysrooted paths when installing .la files, Paolo Bonzini, 2010/07/22
- Re: [RFC PATCH 0/8] sysroot support, Charles Wilson, 2010/07/23