From d5e8312ed9393473bfc55c1520956df83a2bc213 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Tue, 23 Nov 2010 19:12:55 +0000 Subject: Reapply 61c0c52a8c6c "qemu-xen: build adjustments" The changeset qemu-xen: build adjustments to support out-of-tree builds works after all. Sorry for the noise. Signed-off-by: Ian Jackson --- tools/Makefile | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) (limited to 'tools/Makefile') diff --git a/tools/Makefile b/tools/Makefile index b5ca635409..9a97324abd 100644 --- a/tools/Makefile +++ b/tools/Makefile @@ -81,20 +81,15 @@ IOEMU_CONFIGURE_CROSS ?= --cpu=$(XEN_TARGET_ARCH) \ --interp-prefix=$(CROSS_SYS_ROOT) endif -ioemu/config-host.mak: - cd ioemu && XEN_TARGET_ARCH=$(XEN_TARGET_ARCH) sh configure \ - --prefix=$(PREFIX) $(IOEMU_CONFIGURE_CROSS) - -subdir-all-ioemu subdir-install-ioemu: ioemu/config-host.mak - -subdir-clean-ioemu: - $(MAKE) -C ioemu distclean +QEMU_ROOT := $(shell if [ -d "$(CONFIG_QEMU)" ]; then echo "$(CONFIG_QEMU)"; else echo .; fi) +ifneq ($(QEMU_ROOT),.) +export QEMU_ROOT +endif ioemu-dir-find: set -ex; \ if test -d $(CONFIG_QEMU); then \ - rm -f ioemu-dir; \ - ln -sf $(CONFIG_QEMU) ioemu-dir; \ + mkdir -p ioemu-dir; \ else \ if [ ! -d ioemu-remote ]; then \ rm -rf ioemu-remote ioemu-remote.tmp; \ @@ -115,7 +110,7 @@ ioemu-dir-find: $(absolutify_xen_root); \ $(buildmakevars2shellvars); \ cd ioemu-dir; \ - ./xen-setup $(IOEMU_CONFIGURE_CROSS) + $(QEMU_ROOT)/xen-setup $(IOEMU_CONFIGURE_CROSS) .PHONY: ioemu-dir-force-update ioemu-dir-force-update: -- cgit v1.2.3