[PATCH wayland v1 1/1] wayland-scanner.pc.in: prepend pc_sysrootdir

Pekka Paalanen ppaalanen at gmail.com
Fri Sep 16 07:53:32 UTC 2016


On Thu, 15 Sep 2016 15:22:12 -0700
Joe Konno <joe.konno at linux.intel.com> wrote:

> From: Joe Konno <joe.konno at intel.com>
> 
> In a cross-compilation environment with packages depending on
> wayland-scanner, ensure the path to wayland-scanner is correct. Without
> this patch, the path will _not_ point to the target environment but to
> the host's, potentially leading to breakage.
> 
> https://bugs.freedesktop.org/show_bug.cgi?id=97828
> 
> Signed-off-by: Joe Konno <joe.konno at intel.com>
> ---
>  src/wayland-scanner.pc.in | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/wayland-scanner.pc.in b/src/wayland-scanner.pc.in
> index 7b2a4c92e0e3..ec11a0bc982c 100644
> --- a/src/wayland-scanner.pc.in
> +++ b/src/wayland-scanner.pc.in
> @@ -2,7 +2,7 @@ prefix=@prefix@
>  exec_prefix=@exec_prefix@
>  datarootdir=@datarootdir@
>  pkgdatadir=@datadir@/@PACKAGE@
> -wayland_scanner=@bindir@/wayland-scanner
> +wayland_scanner=${pc_sysrootdir}/@bindir@/wayland-scanner
>  
>  Name: Wayland Scanner
>  Description: Wayland scanner

Hi,

ok, so pc_sysrootdir points to the sysroot. I would just like to
confirm that this really does what you intend. wayland-scanner is a
build tool to be run on the host. Such tools get installed into the
sysroot even when compiled for the host, not the target, yes?

I read both http://dev.gentoo.org/~mgorny/pkg-config-spec.html and
https://autotools.io/pkgconfig/cross-compiling.html but couldn't
actually understand what is going on, perhaps because I never
cross-compile.

Hence I cannot offer a Reviewed-by, but I can offer:
Acked-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>

(Not for the 1.12.0 release.)

Are you using binary-compatible arches for both host and target? I'd
like to see a test on a setup where the binaries are completely
incompatible so that the host != target difference is obvious.


Thanks,
pq
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 811 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/wayland-devel/attachments/20160916/4d93af07/attachment-0001.sig>


More information about the wayland-devel mailing list