um: Fix out-of-tree build
authorRichard Weinberger <richard@nod.at>
Sun, 28 Jun 2015 20:55:26 +0000 (22:55 +0200)
committerJiri Slaby <jslaby@suse.cz>
Fri, 22 Jul 2016 08:16:59 +0000 (10:16 +0200)
commit 0b5aedfe0e6654ec54f35109e1929a1cf7fc4cdd upstream.

Commit 30b11ee9a (um: Remove copy&paste code from init.h)
uncovered an issue wrt. out-of-tree builds.
For out-of-tree builds, we must not rely on relative paths.
Before 30b11ee9a it worked by chance as no host code included
generated header files.

Acked-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
arch/um/Makefile

index 1b3ad7d2430a4a7ea451a13260cb921c4d93c958..911b630d3268f40ded6548b960188d039bb925cf 100644 (file)
@@ -60,8 +60,8 @@ KBUILD_AFLAGS += $(ARCH_INCLUDE)
 
 USER_CFLAGS = $(patsubst $(KERNEL_DEFINES),,$(patsubst -I%,,$(KBUILD_CFLAGS))) \
                $(ARCH_INCLUDE) $(MODE_INCLUDE) $(filter -I%,$(CFLAGS)) \
-               -D_FILE_OFFSET_BITS=64 -idirafter include \
-               -D__KERNEL__ -D__UM_HOST__
+               -D_FILE_OFFSET_BITS=64 -idirafter $(srctree)/include \
+               -idirafter $(obj)/include -D__KERNEL__ -D__UM_HOST__
 
 #This will adjust *FLAGS accordingly to the platform.
 include $(srctree)/$(ARCH_DIR)/Makefile-os-$(OS)