[PATCH] Kbuild: Use $(objtree) for mkdir -p include/linux include/config

From: John Kacur
Date: Wed Jan 06 2010 - 17:16:38 EST


This fixes a problem where make sometimes creates the directories
include/linux include/config
in the local source tree, even though O=/outputdir was specified.

The solution is to give an absolute path using $(objtree)

Signed-off-by: John Kacur <jkacur@xxxxxxxxxx>
---
Makefile | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 1231094..2f3ba92 100644
--- a/Makefile
+++ b/Makefile
@@ -454,11 +454,11 @@ include $(srctree)/arch/$(SRCARCH)/Makefile
export KBUILD_DEFCONFIG KBUILD_KCONFIG

config: scripts_basic outputmakefile FORCE
- $(Q)mkdir -p include/linux include/config
+ $(Q)mkdir -p $(objtree)/include/linux $(objtree)/include/config
$(Q)$(MAKE) $(build)=scripts/kconfig $@

%config: scripts_basic outputmakefile FORCE
- $(Q)mkdir -p include/linux include/config
+ $(Q)mkdir -p $(objtree)/include/linux $(objtree)/include/config
$(Q)$(MAKE) $(build)=scripts/kconfig $@

else
--
1.6.0.6

--8323328-1073958386-1262817211=:3744--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/