[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [Qemu-trivial] [PATCH 2/2] Makefile: use full path for
From: |
Stefano Stabellini |
Subject: |
Re: [Qemu-devel] [Qemu-trivial] [PATCH 2/2] Makefile: use full path for qapi-generated directory |
Date: |
Wed, 30 Nov 2011 13:03:39 +0000 |
User-agent: |
Alpine 2.00 (DEB 1167 2008-08-23) |
On Wed, 30 Nov 2011, Stefan Hajnoczi wrote:
> On Tue, Nov 29, 2011 at 10:47 PM, Michael Roth
> <address@hidden> wrote:
> > Generally $(BUILD_DIR) == $(CURDIR), but that isn't necessarilly the
> > case, so use $(BUILD_DIR)/qapi-generated for generated files to
> > avoid potentionally sticking generating files in odd places outside
> > the build's include paths.
> > ---
> > Ã?ÃÂ Makefile | Ã?ÃÂ Ã?ÃÂ 2 +-
> > Ã?ÃÂ 1 files changed, 1 insertions(+), 1 deletions(-)
>
> Reviewed-by: Stefan Hajnoczi <address@hidden>
>
> Not applied to trivial tree yet. I want to let Stefano, Stefan Weil,
> or Anthony take a look too since we were all discussing these changes
> yesterday.
While I think that the change is correct (certainly better than the
original patch), unfortunately still doesn't solve the problem
entirely.
Steps to repro, assuming "qemu" is the source tree and "temp" is the
empty build directory:
- cd qemu; ./configure; make
- cd ../temp; ./configure --source-path=../qemu; make
Result:
Makefile:9: config-devices.mak: No such file or directory
In order to fix the issue, we need to make sure that config-devices.mak
is relative to $(BUILD_DIR) in the Makefile.
Signed-off-by: Stefano Stabellini <address@hidden>
diff --git a/Makefile b/Makefile
index 301c75e..b9f8de7 100644
--- a/Makefile
+++ b/Makefile
@@ -43,15 +43,15 @@ DOCS=
endif
SUBDIR_MAKEFLAGS=$(if $(V),,--no-print-directory) BUILD_DIR=$(BUILD_DIR)
-SUBDIR_DEVICES_MAK=$(patsubst %, %/config-devices.mak, $(TARGET_DIRS))
-SUBDIR_DEVICES_MAK_DEP=$(patsubst %, %/config-devices.mak.d, $(TARGET_DIRS))
+SUBDIR_DEVICES_MAK=$(patsubst %, %/config-devices.mak,
$(BUILD_DIR)/$(TARGET_DIRS))
+SUBDIR_DEVICES_MAK_DEP=$(patsubst %, %/config-devices.mak.d,
$(BUILD_DIR)/$(TARGET_DIRS))
config-all-devices.mak: $(SUBDIR_DEVICES_MAK)
$(call quiet-command,cat $(SUBDIR_DEVICES_MAK) | grep =y | sort -u >
$@," GEN $@")
-include $(SUBDIR_DEVICES_MAK_DEP)
-%/config-devices.mak: default-configs/%.mak
+$(BUILD_DIR)/%/config-devices.mak: default-configs/%.mak
$(call quiet-command,$(SHELL) $(SRC_PATH)/scripts/make_device_config.sh
$@ $<, " GEN $@")
@if test -f $@; then \
if cmp -s address@hidden $@; then \
- [Qemu-devel] [PATCH] fix out of tree build, Stefano Stabellini, 2011/11/22
- Re: [Qemu-devel] [Qemu-trivial] [PATCH] fix out of tree build, Stefan Hajnoczi, 2011/11/23
- Re: [Qemu-devel] [PATCH] fix out of tree build, Stefan Weil, 2011/11/28
- Re: [Qemu-devel] [PATCH] fix out of tree build, Anthony Liguori, 2011/11/28
- Re: [Qemu-devel] [PATCH] fix out of tree build, Stefan Weil, 2011/11/28
- Re: [Qemu-devel] [PATCH] fix out of tree build, Stefano Stabellini, 2011/11/29
- [Qemu-devel] [PATCH 1/2] qapi: fix guardname generation, Michael Roth, 2011/11/29
- [Qemu-devel] [PATCH 2/2] Makefile: use full path for qapi-generated directory, Michael Roth, 2011/11/29
- Re: [Qemu-devel] [Qemu-trivial] [PATCH 2/2] Makefile: use full path for qapi-generated directory, Stefan Hajnoczi, 2011/11/30
- Re: [Qemu-devel] [Qemu-trivial] [PATCH 2/2] Makefile: use full path for qapi-generated directory,
Stefano Stabellini <=
- Re: [Qemu-devel] [Qemu-trivial] [PATCH 2/2] Makefile: use full path for qapi-generated directory, Stefan Weil, 2011/11/30
- Re: [Qemu-devel] [Qemu-trivial] [PATCH 1/2] qapi: fix guardname generation, Stefan Hajnoczi, 2011/11/30