Linux kbuild/kconfig development
 help / color / mirror / Atom feed
* [Patch] UML build: fix missing posix_types.h
@ 2008-07-31 12:10 WANG Cong
  2008-07-31 20:16 ` Sam Ravnborg
  0 siblings, 1 reply; 2+ messages in thread
From: WANG Cong @ 2008-07-31 12:10 UTC (permalink / raw)
  To: LKML; +Cc: jdike, sam, linux-kbuild, user-mode-linux-devel, Andrew Morton


When building UML with 'O=foo' specified, I got:

CC      kernel/bounds.s
  In file included from
/home/wangcong/Projects/linux-2.6/include/linux/types.h:11,
                 from
/home/wangcong/Projects/linux-2.6/include/linux/page-flags.h:8,
                 from
/home/wangcong/Projects/linux-2.6/kernel/bounds.c:9:
/home/wangcong/Projects/linux-2.6/include/linux/posix_types.h:47:29:
error: asm/posix_types.h: No such file or directory
In file included from
/home/wangcong/Projects/linux-2.6/include/linux/page-flags.h:8,
                 from
/home/wangcong/Projects/linux-2.6/kernel/bounds.c:9:
/home/wangcong/Projects/linux-2.6/include/linux/types.h:12:23: error:
asm/types.h: No such file or directory
In file included from
/home/wangcong/Projects/linux-2.6/include/linux/page-flags.h:8,

Below patch fixed it, note, it is only tested for x86 and um.

Signed-off-by: WANG Cong <wangcong@zeuux.org>
Cc: sam@ravnborg.org
Cc: jdike@addtoit.com

---
diff --git a/Makefile b/Makefile
index aa527a4..39130d1 100644
--- a/Makefile
+++ b/Makefile
@@ -930,7 +930,8 @@ ifneq ($(KBUILD_SRC),)
 		/bin/false; \
 	fi;
 	$(Q)if [ ! -d include2 ]; then mkdir -p include2; fi;
-	$(Q)if [ -e $(srctree)/include/asm-$(SRCARCH)/system.h ]; then  \
+	$(Q)if [ -e $(srctree)/include/asm-$(SRCARCH)/system.h -o \
+		 -e $(objtree)/include/asm-$(SRCARCH)/system.h ] ; then \
 	    ln -fsn $(srctree)/include/asm-$(SRCARCH) include2/asm;     \
 	    fi
 endif



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Patch] UML build: fix missing posix_types.h
  2008-07-31 12:10 [Patch] UML build: fix missing posix_types.h WANG Cong
@ 2008-07-31 20:16 ` Sam Ravnborg
  0 siblings, 0 replies; 2+ messages in thread
From: Sam Ravnborg @ 2008-07-31 20:16 UTC (permalink / raw)
  To: WANG Cong; +Cc: LKML, jdike, linux-kbuild, user-mode-linux-devel, Andrew Morton

On Thu, Jul 31, 2008 at 01:10:28PM +0100, WANG Cong wrote:
> 
> When building UML with 'O=foo' specified, I got:
> 
> CC      kernel/bounds.s
>   In file included from
> /home/wangcong/Projects/linux-2.6/include/linux/types.h:11,
>                  from
> /home/wangcong/Projects/linux-2.6/include/linux/page-flags.h:8,
>                  from
> /home/wangcong/Projects/linux-2.6/kernel/bounds.c:9:
> /home/wangcong/Projects/linux-2.6/include/linux/posix_types.h:47:29:
> error: asm/posix_types.h: No such file or directory
> In file included from
> /home/wangcong/Projects/linux-2.6/include/linux/page-flags.h:8,
>                  from
> /home/wangcong/Projects/linux-2.6/kernel/bounds.c:9:
> /home/wangcong/Projects/linux-2.6/include/linux/types.h:12:23: error:
> asm/types.h: No such file or directory
> In file included from
> /home/wangcong/Projects/linux-2.6/include/linux/page-flags.h:8,
> 
> Below patch fixed it, note, it is only tested for x86 and um.
> 
> Signed-off-by: WANG Cong <wangcong@zeuux.org>
> Cc: sam@ravnborg.org
> Cc: jdike@addtoit.com
> 
> ---
> diff --git a/Makefile b/Makefile
> index aa527a4..39130d1 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -930,7 +930,8 @@ ifneq ($(KBUILD_SRC),)
>  		/bin/false; \
>  	fi;
>  	$(Q)if [ ! -d include2 ]; then mkdir -p include2; fi;
> -	$(Q)if [ -e $(srctree)/include/asm-$(SRCARCH)/system.h ]; then  \
> +	$(Q)if [ -e $(srctree)/include/asm-$(SRCARCH)/system.h -o \
> +		 -e $(objtree)/include/asm-$(SRCARCH)/system.h ] ; then \
>  	    ln -fsn $(srctree)/include/asm-$(SRCARCH) include2/asm;     \
>  	    fi
>  endif

I have a similar patch locally. I just check for errno.h so I 
do not have to do the extra check in objtree.
Will push tonight.

	Sam

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-07-31 20:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-31 12:10 [Patch] UML build: fix missing posix_types.h WANG Cong
2008-07-31 20:16 ` Sam Ravnborg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox