Re: fixincludes needed on linux?

Olivier Galibert (galibert@pobox.com)
Fri, 16 Oct 1998 09:37:40 +0200


On Thu, Oct 15, 1998 at 10:37:30AM -0700, Bruce Korb wrote:
> Summary: OS and machine names need to be surrounded with "__"
> and "#endif" directives ought not have labels.
>

The interesting ones:

> --- /usr/include/rpc/types.h Fri Feb 17 21:34:09 1995
> +++ include/rpc/types.h Thu Oct 15 08:07:35 1998
> @@ -1,3 +1,7 @@
> +#ifdef __cplusplus
> +extern "C" {
> +#endif
> +
> /* @(#)types.h 2.3 88/08/15 4.0 RPCSRC */
> /*
> * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
> @@ -76,3 +80,6 @@
> #endif
>
> #endif /* _RPC_TYPES_H */
> +#ifdef __cplusplus
> +}
> +#endif

> --- /usr/src/linux/include/linux/stddef.h Wed Dec 1 04:44:15 1993
> +++ include/root/usr/src/linux/include/linux/stddef.h Thu Oct 15 08:08:02 1998
> @@ -3,7 +3,10 @@
>
> #ifndef _SIZE_T
> #define _SIZE_T
> -typedef unsigned int size_t;
> +#ifndef __SIZE_TYPE__
> +#define __SIZE_TYPE__ long unsigned int
> +#endif
> +typedef __SIZE_TYPE__ size_t;
> #endif
>
> #undef NULL

> --- /usr/include/stdio.h Wed May 29 01:39:51 1996
> +++ include/stdio.h Thu Oct 15 08:07:45 1998
> @@ -1,3 +1,5 @@
> +#define __need___va_list
> +#include <stdarg.h>
> /* This is part of the iostream/stdio library, providing -*- C -*- I/O.
> Define ANSI C stdio on top of C++ iostreams.
> Copyright (C) 1991 Per Bothner.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/