[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-ia64-devel] Re: [Xen-devel] [PATCH 2 of 2] cross-build fixes in ioemu-remote
Ian Jackson wrote: [Fri Aug 01 2008, 12:26:54PM EDT] > Aron Griffis writes ("Re: [Xen-ia64-devel] Re: [Xen-devel] [PATCH 2 of 2] > cross-build fixes in ioemu-remote"): > > - --interp-prefix=$(CROSS_SYS_ROOT) > > + --interp-prefix=$(CROSS_SYS_ROOT) \ > > + --install='env PATH="$(CROSS_BIN_PATH):$$$$PATH" > > install' > > This is a bit bizarre (not to mention the fact that the number > of $'s will depend on undocumented properties of the way qemu's > configure inteprets that option). qemu's configure uses quoting properly and applies no interpretation on the way through. The dollars are doubled once for the Makefile where this is set, once for the inner Makefile where it is used. However... there is a Solaris hack in configure that will break with any --install option other than a bare word. And I agree with you anyway, it's a fragile approach. > Why not just set PATH directly and export it ? qemu expects "gcc" and the like to refer to the host toolchain. I think we only want the PATH set for install. Ideally there would be an /usr/bin/ia64-linux-gnu-install to accompany the others and use the right strip, but oh well. > But in general I think this is a reasonable approach. How about... # HG changeset patch # User Aron Griffis <aron@xxxxxx> # Date 1217610812 14400 # Node ID 714215c06a98ea845e3f25371945d62abb1c18c7 # Parent f69a23b209c4ab04827051734e37f095607400ed add cross-install to find the right "strip" Signed-off-by: Aron Griffis <aron@xxxxxx> diff --git a/tools/Makefile b/tools/Makefile --- a/tools/Makefile +++ b/tools/Makefile @@ -38,8 +38,10 @@ # For the sake of linking, set the sys-root ifneq ($(CROSS_COMPILE),) +CROSS_BIN_PATH ?= /usr/$(CROSS_COMPILE:-=)/bin CROSS_SYS_ROOT ?= /usr/$(CROSS_COMPILE:-=)/sys-root -export CROSS_SYS_ROOT +export CROSS_SYS_ROOT # exported for check/funcs.sh +export CROSS_BIN_PATH # exported for cross-install.sh endif .PHONY: all @@ -57,7 +59,8 @@ ifneq ($(XEN_COMPILE_ARCH),$(XEN_TARGET_ARCH)) IOEMU_CONFIGURE_CROSS ?= --cpu=$(XEN_TARGET_ARCH) \ --cross-prefix=$(CROSS_COMPILE) \ - --interp-prefix=$(CROSS_SYS_ROOT) + --interp-prefix=$(CROSS_SYS_ROOT) \ + --install=$(CURDIR)/cross-install endif ioemu/config-host.mak: diff --git a/tools/cross-install b/tools/cross-install new file mode 100755 --- /dev/null +++ b/tools/cross-install @@ -0,0 +1,8 @@ +#!/bin/sh + +# prepend CROSS_BIN_PATH to find the right "strip" +if [ -n "$CROSS_BIN_PATH" ]; then + PATH="$CROSS_BIN_PATH:$PATH" +fi + +exec install "$@" _______________________________________________ Xen-ia64-devel mailing list Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-ia64-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |