summaryrefslogtreecommitdiff
path: root/sys/arch/i386
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2005-12-14 21:46:32 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2005-12-14 21:46:32 +0000
commit3fce9befb1d4f65739adc427683f5a6357ee102f (patch)
treebda10871810ec2e3c47c06cfa6e07b88df5efe02 /sys/arch/i386
parent6ffc06fbc8f7e1d2c6134ab0d4563b6a189b983c (diff)
convert _FOO_SOURCE -> __FOO_VISIBLE in machine. OK deraadt@
Diffstat (limited to 'sys/arch/i386')
-rw-r--r--sys/arch/i386/include/limits.h14
-rw-r--r--sys/arch/i386/include/signal.h8
-rw-r--r--sys/arch/i386/include/stdarg.h7
-rw-r--r--sys/arch/i386/include/types.h6
4 files changed, 20 insertions, 15 deletions
diff --git a/sys/arch/i386/include/limits.h b/sys/arch/i386/include/limits.h
index ba28ec5d05d..9915dfd884c 100644
--- a/sys/arch/i386/include/limits.h
+++ b/sys/arch/i386/include/limits.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: limits.h,v 1.9 2003/06/02 23:27:47 millert Exp $ */
+/* $OpenBSD: limits.h,v 1.10 2005/12/14 21:46:30 millert Exp $ */
/* $NetBSD: limits.h,v 1.11 1995/12/21 01:08:59 mycroft Exp $ */
/*
@@ -35,20 +35,22 @@
#ifndef _MACHINE_LIMITS_H_
#define _MACHINE_LIMITS_H_
+#include <sys/cdefs.h>
+
#define MB_LEN_MAX 1 /* no multibyte characters */
-#if !defined(_ANSI_SOURCE)
+#if __POSIX_VISIBLE || __XPG_VISIBLE
#define SIZE_MAX UINT_MAX /* max value for a size_t */
#define SSIZE_MAX INT_MAX /* max value for a ssize_t */
+#endif
-#if !defined(_POSIX_SOURCE) && !defined(_XOPEN_SOURCE)
-#define SIZE_T_MAX UINT_MAX /* max value for a size_t */
+#if __BSD_VISIBLE
+#define SIZE_T_MAX UINT_MAX /* max value for a size_t (historic) */
#define UQUAD_MAX 0xffffffffffffffffULL /* max unsigned quad */
#define QUAD_MAX 0x7fffffffffffffffLL /* max signed quad */
#define QUAD_MIN (-0x7fffffffffffffffLL-1) /* min signed quad */
-#endif /* !_POSIX_SOURCE && !_XOPEN_SOURCE */
-#endif /* !_ANSI_SOURCE */
+#endif /* __BSD_VISIBLE */
#endif /* _MACHINE_LIMITS_H_ */
diff --git a/sys/arch/i386/include/signal.h b/sys/arch/i386/include/signal.h
index e76b5574f07..d8443d8c091 100644
--- a/sys/arch/i386/include/signal.h
+++ b/sys/arch/i386/include/signal.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: signal.h,v 1.4 2003/06/02 23:27:47 millert Exp $ */
+/* $OpenBSD: signal.h,v 1.5 2005/12/14 21:46:30 millert Exp $ */
/* $NetBSD: signal.h,v 1.6 1996/01/08 13:51:43 mycroft Exp $ */
/*
@@ -35,9 +35,11 @@
#ifndef _I386_SIGNAL_H_
#define _I386_SIGNAL_H_
+#include <sys/cdefs.h>
+
typedef int sig_atomic_t;
-#ifndef _ANSI_SOURCE
+#if __BSD_VISIBLE
/*
* Get the "code" values
*/
@@ -81,5 +83,5 @@ struct sigcontext {
#define sc_pc sc_eip
#define sc_ps sc_eflags
-#endif /* !_ANSI_SOURCE */
+#endif /* __BSD_VISIBLE */
#endif /* !_I386_SIGNAL_H_ */
diff --git a/sys/arch/i386/include/stdarg.h b/sys/arch/i386/include/stdarg.h
index 4c51b5768bd..c3e66cbb59a 100644
--- a/sys/arch/i386/include/stdarg.h
+++ b/sys/arch/i386/include/stdarg.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: stdarg.h,v 1.6 2003/06/02 23:27:47 millert Exp $ */
+/* $OpenBSD: stdarg.h,v 1.7 2005/12/14 21:46:30 millert Exp $ */
/* $NetBSD: stdarg.h,v 1.12 1995/12/25 23:15:31 mycroft Exp $ */
/*-
@@ -35,6 +35,7 @@
#ifndef _I386_STDARG_H_
#define _I386_STDARG_H_
+#include <sys/cdefs.h>
#include <machine/ansi.h>
typedef _BSD_VA_LIST_ va_list;
@@ -53,9 +54,7 @@ typedef _BSD_VA_LIST_ va_list;
#define va_arg(ap, type) \
(*(type *)((ap) += __va_size(type), (ap) - __va_size(type)))
-#if !defined(_ANSI_SOURCE) && \
- (!defined(_POSIX_C_SOURCE) && !defined(_XOPEN_SOURCE) || \
- defined(_ISOC99_SOURCE) || (__STDC_VERSION__ - 0) >= 199901L)
+#if __ISO_C_VISIBLE >= 1999
#define va_copy(dest, src) \
((dest) = (src))
#endif
diff --git a/sys/arch/i386/include/types.h b/sys/arch/i386/include/types.h
index 05449d122b8..dca5257b991 100644
--- a/sys/arch/i386/include/types.h
+++ b/sys/arch/i386/include/types.h
@@ -1,5 +1,5 @@
/* $NetBSD: types.h,v 1.12 1995/12/24 01:08:03 mycroft Exp $ */
-/* $OpenBSD: types.h,v 1.18 2004/11/26 21:23:05 miod Exp $ */
+/* $OpenBSD: types.h,v 1.19 2005/12/14 21:46:30 millert Exp $ */
/*-
* Copyright (c) 1990 The Regents of the University of California.
@@ -37,16 +37,18 @@
#include <sys/cdefs.h>
-#if !defined(_ANSI_SOURCE) && !defined(_POSIX_SOURCE)
+#if defined(_KERNEL)
typedef struct label_t {
int val[6];
} label_t;
#endif
+#if __BSD_VISIBLE
typedef unsigned long vaddr_t;
typedef unsigned long paddr_t;
typedef unsigned long vsize_t;
typedef unsigned long psize_t;
+#endif
/*
* Basic integral types. Omit the typedef if