From mboxrd@z Thu Jan 1 00:00:00 1970 From: ramsdell@mitre.org (John D. Ramsdell) Subject: [PATCH] Use stddef.h in Mini-OS to define size_t Date: 01 May 2006 11:10:29 -0400 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Grzegorz Milos Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org Please patch Mini-OS so that it uses stddef.h to define size_t and NULL. This problem fixes errors that occur when linking Mini-OS with ANSI standard code that uses stddef.h. John diff -ur oxen-3.0-testing/extras/mini-os/include/lib.h nxen-3.0-testing/extras/mini-os/include/lib.h --- oxen-3.0-testing/extras/mini-os/include/lib.h 2006-04-14 22:21:55.000000000 -0400 +++ nxen-3.0-testing/extras/mini-os/include/lib.h 2006-04-28 13:37:44.000000000 -0400 @@ -56,6 +56,7 @@ #define _LIB_H_ #include +#include #include /* printing */ diff -ur oxen-3.0-testing/extras/mini-os/include/os.h nxen-3.0-testing/extras/mini-os/include/os.h --- oxen-3.0-testing/extras/mini-os/include/os.h 2006-04-14 22:21:55.000000000 -0400 +++ nxen-3.0-testing/extras/mini-os/include/os.h 2006-04-28 13:39:13.000000000 -0400 @@ -7,9 +7,6 @@ #ifndef _OS_H_ #define _OS_H_ -#define NULL 0 - - #if __GNUC__ == 2 && __GNUC_MINOR__ < 96 #define __builtin_expect(x, expected_value) (x) #endif diff -ur oxen-3.0-testing/extras/mini-os/include/types.h nxen-3.0-testing/extras/mini-os/include/types.h --- oxen-3.0-testing/extras/mini-os/include/types.h 2006-04-14 22:21:55.000000000 -0400 +++ nxen-3.0-testing/extras/mini-os/include/types.h 2006-04-28 13:39:17.000000000 -0400 @@ -34,8 +34,6 @@ typedef unsigned long u64; #endif -typedef unsigned int size_t; - /* FreeBSD compat types */ typedef unsigned char u_char; typedef unsigned int u_int;