summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Dempsky <matthew@cvs.openbsd.org>2012-05-30 19:34:31 +0000
committerMatthew Dempsky <matthew@cvs.openbsd.org>2012-05-30 19:34:31 +0000
commit78417ba1588e1ec3ce52fd344de0b609e869f3ef (patch)
treec3ec4947a311e49e6644c983b1b1a8ed92cd5ce1
parent4549bc77a3f6e2d94d47fedb36869999184c528d (diff)
Move the _SC_* and _CS_* configurable system variables and strings
from sys/unistd.h to unistd.h. From Brad; ok millert and me
-rw-r--r--include/unistd.h140
-rw-r--r--sys/sys/unistd.h140
2 files changed, 141 insertions, 139 deletions
diff --git a/include/unistd.h b/include/unistd.h
index 1e398a4c3f4..61b10f06ff3 100644
--- a/include/unistd.h
+++ b/include/unistd.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: unistd.h,v 1.71 2012/05/14 23:21:35 matthew Exp $ */
+/* $OpenBSD: unistd.h,v 1.72 2012/05/30 19:34:30 matthew Exp $ */
/* $NetBSD: unistd.h,v 1.26.4.1 1996/05/28 02:31:51 mrg Exp $ */
/*-
@@ -147,6 +147,144 @@
/* Define the POSIX.2 version we target for compliance. */
#define _POSIX2_VERSION 199212L
+/* the sysconf(3) variable values are part of the ABI */
+
+/* configurable system variables */
+#define _SC_ARG_MAX 1
+#define _SC_CHILD_MAX 2
+#define _SC_CLK_TCK 3
+#define _SC_NGROUPS_MAX 4
+#define _SC_OPEN_MAX 5
+#define _SC_JOB_CONTROL 6
+#define _SC_SAVED_IDS 7
+#define _SC_VERSION 8
+#define _SC_BC_BASE_MAX 9
+#define _SC_BC_DIM_MAX 10
+#define _SC_BC_SCALE_MAX 11
+#define _SC_BC_STRING_MAX 12
+#define _SC_COLL_WEIGHTS_MAX 13
+#define _SC_EXPR_NEST_MAX 14
+#define _SC_LINE_MAX 15
+#define _SC_RE_DUP_MAX 16
+#define _SC_2_VERSION 17
+#define _SC_2_C_BIND 18
+#define _SC_2_C_DEV 19
+#define _SC_2_CHAR_TERM 20
+#define _SC_2_FORT_DEV 21
+#define _SC_2_FORT_RUN 22
+#define _SC_2_LOCALEDEF 23
+#define _SC_2_SW_DEV 24
+#define _SC_2_UPE 25
+#define _SC_STREAM_MAX 26
+#define _SC_TZNAME_MAX 27
+#define _SC_PAGESIZE 28
+#define _SC_PAGE_SIZE _SC_PAGESIZE /* 1170 compatibility */
+#define _SC_FSYNC 29
+#define _SC_XOPEN_SHM 30
+#define _SC_SEM_NSEMS_MAX 31
+#define _SC_SEM_VALUE_MAX 32
+#define _SC_HOST_NAME_MAX 33
+#define _SC_MONOTONIC_CLOCK 34
+#define _SC_2_PBS 35
+#define _SC_2_PBS_ACCOUNTING 36
+#define _SC_2_PBS_CHECKPOINT 37
+#define _SC_2_PBS_LOCATE 38
+#define _SC_2_PBS_MESSAGE 39
+#define _SC_2_PBS_TRACK 40
+#define _SC_ADVISORY_INFO 41
+#define _SC_AIO_LISTIO_MAX 42
+#define _SC_AIO_MAX 43
+#define _SC_AIO_PRIO_DELTA_MAX 44
+#define _SC_ASYNCHRONOUS_IO 45
+#define _SC_ATEXIT_MAX 46
+#define _SC_BARRIERS 47
+#define _SC_CLOCK_SELECTION 48
+#define _SC_CPUTIME 49
+#define _SC_DELAYTIMER_MAX 50
+#define _SC_IOV_MAX 51
+#define _SC_IPV6 52
+#define _SC_MAPPED_FILES 53
+#define _SC_MEMLOCK 54
+#define _SC_MEMLOCK_RANGE 55
+#define _SC_MEMORY_PROTECTION 56
+#define _SC_MESSAGE_PASSING 57
+#define _SC_MQ_OPEN_MAX 58
+#define _SC_MQ_PRIO_MAX 59
+#define _SC_PRIORITIZED_IO 60
+#define _SC_PRIORITY_SCHEDULING 61
+#define _SC_RAW_SOCKETS 62
+#define _SC_READER_WRITER_LOCKS 63
+#define _SC_REALTIME_SIGNALS 64
+#define _SC_REGEXP 65
+#define _SC_RTSIG_MAX 66
+#define _SC_SEMAPHORES 67
+#define _SC_SHARED_MEMORY_OBJECTS 68
+#define _SC_SHELL 69
+#define _SC_SIGQUEUE_MAX 70
+#define _SC_SPAWN 71
+#define _SC_SPIN_LOCKS 72
+#define _SC_SPORADIC_SERVER 73
+#define _SC_SS_REPL_MAX 74
+#define _SC_SYNCHRONIZED_IO 75
+#define _SC_SYMLOOP_MAX 76
+#define _SC_THREAD_ATTR_STACKADDR 77
+#define _SC_THREAD_ATTR_STACKSIZE 78
+#define _SC_THREAD_CPUTIME 79
+#define _SC_THREAD_DESTRUCTOR_ITERATIONS 80
+#define _SC_THREAD_KEYS_MAX 81
+#define _SC_THREAD_PRIO_INHERIT 82
+#define _SC_THREAD_PRIO_PROTECT 83
+#define _SC_THREAD_PRIORITY_SCHEDULING 84
+#define _SC_THREAD_PROCESS_SHARED 85
+#define _SC_THREAD_ROBUST_PRIO_INHERIT 86
+#define _SC_THREAD_ROBUST_PRIO_PROTECT 87
+#define _SC_THREAD_SPORADIC_SERVER 88
+#define _SC_THREAD_STACK_MIN 89
+#define _SC_THREAD_THREADS_MAX 90
+#define _SC_THREADS 91
+#define _SC_TIMEOUTS 92
+#define _SC_TIMER_MAX 93
+#define _SC_TIMERS 94
+#define _SC_TRACE 95
+#define _SC_TRACE_EVENT_FILTER 96
+#define _SC_TRACE_EVENT_NAME_MAX 97
+#define _SC_TRACE_INHERIT 98
+#define _SC_TRACE_LOG 99
+#define _SC_GETGR_R_SIZE_MAX 100
+#define _SC_GETPW_R_SIZE_MAX 101
+#define _SC_LOGIN_NAME_MAX 102
+#define _SC_THREAD_SAFE_FUNCTIONS 103
+#define _SC_TRACE_NAME_MAX 104
+#define _SC_TRACE_SYS_MAX 105
+#define _SC_TRACE_USER_EVENT_MAX 106
+#define _SC_TTY_NAME_MAX 107
+#define _SC_TYPED_MEMORY_OBJECTS 108
+#define _SC_V6_ILP32_OFF32 109
+#define _SC_V6_ILP32_OFFBIG 110
+#define _SC_V6_LP64_OFF64 111
+#define _SC_V6_LPBIG_OFFBIG 112
+#define _SC_V7_ILP32_OFF32 113
+#define _SC_V7_ILP32_OFFBIG 114
+#define _SC_V7_LP64_OFF64 115
+#define _SC_V7_LPBIG_OFFBIG 116
+#define _SC_XOPEN_CRYPT 117
+#define _SC_XOPEN_ENH_I18N 118
+#define _SC_XOPEN_LEGACY 119
+#define _SC_XOPEN_REALTIME 120
+#define _SC_XOPEN_REALTIME_THREADS 121
+#define _SC_XOPEN_STREAMS 122
+#define _SC_XOPEN_UNIX 123
+#define _SC_XOPEN_UUCP 124
+#define _SC_XOPEN_VERSION 125
+
+#define _SC_PHYS_PAGES 500
+#define _SC_AVPHYS_PAGES 501
+#define _SC_NPROCESSORS_CONF 502
+#define _SC_NPROCESSORS_ONLN 503
+
+/* configurable system strings */
+#define _CS_PATH 1
+
#ifndef NULL
#ifdef __GNUG__
#define NULL __null
diff --git a/sys/sys/unistd.h b/sys/sys/unistd.h
index 30bcf342ca2..8ac826a4317 100644
--- a/sys/sys/unistd.h
+++ b/sys/sys/unistd.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: unistd.h,v 1.21 2012/05/14 23:21:35 matthew Exp $ */
+/* $OpenBSD: unistd.h,v 1.22 2012/05/30 19:34:30 matthew Exp $ */
/* $NetBSD: unistd.h,v 1.10 1994/06/29 06:46:06 cgd Exp $ */
/*
@@ -67,7 +67,7 @@ struct __tfork {
};
#endif
-/* the pathconf(2) and sysconf(3) variable values are part of the ABI */
+/* the pathconf(2) variable values are part of the ABI */
/* configurable pathname variables */
#define _PC_LINK_MAX 1
@@ -80,140 +80,4 @@ struct __tfork {
#define _PC_NO_TRUNC 8
#define _PC_VDISABLE 9
-/* configurable system variables */
-#define _SC_ARG_MAX 1
-#define _SC_CHILD_MAX 2
-#define _SC_CLK_TCK 3
-#define _SC_NGROUPS_MAX 4
-#define _SC_OPEN_MAX 5
-#define _SC_JOB_CONTROL 6
-#define _SC_SAVED_IDS 7
-#define _SC_VERSION 8
-#define _SC_BC_BASE_MAX 9
-#define _SC_BC_DIM_MAX 10
-#define _SC_BC_SCALE_MAX 11
-#define _SC_BC_STRING_MAX 12
-#define _SC_COLL_WEIGHTS_MAX 13
-#define _SC_EXPR_NEST_MAX 14
-#define _SC_LINE_MAX 15
-#define _SC_RE_DUP_MAX 16
-#define _SC_2_VERSION 17
-#define _SC_2_C_BIND 18
-#define _SC_2_C_DEV 19
-#define _SC_2_CHAR_TERM 20
-#define _SC_2_FORT_DEV 21
-#define _SC_2_FORT_RUN 22
-#define _SC_2_LOCALEDEF 23
-#define _SC_2_SW_DEV 24
-#define _SC_2_UPE 25
-#define _SC_STREAM_MAX 26
-#define _SC_TZNAME_MAX 27
-#define _SC_PAGESIZE 28
-#define _SC_PAGE_SIZE _SC_PAGESIZE /* 1170 compatibility */
-#define _SC_FSYNC 29
-#define _SC_XOPEN_SHM 30
-#define _SC_SEM_NSEMS_MAX 31
-#define _SC_SEM_VALUE_MAX 32
-#define _SC_HOST_NAME_MAX 33
-#define _SC_MONOTONIC_CLOCK 34
-#define _SC_2_PBS 35
-#define _SC_2_PBS_ACCOUNTING 36
-#define _SC_2_PBS_CHECKPOINT 37
-#define _SC_2_PBS_LOCATE 38
-#define _SC_2_PBS_MESSAGE 39
-#define _SC_2_PBS_TRACK 40
-#define _SC_ADVISORY_INFO 41
-#define _SC_AIO_LISTIO_MAX 42
-#define _SC_AIO_MAX 43
-#define _SC_AIO_PRIO_DELTA_MAX 44
-#define _SC_ASYNCHRONOUS_IO 45
-#define _SC_ATEXIT_MAX 46
-#define _SC_BARRIERS 47
-#define _SC_CLOCK_SELECTION 48
-#define _SC_CPUTIME 49
-#define _SC_DELAYTIMER_MAX 50
-#define _SC_IOV_MAX 51
-#define _SC_IPV6 52
-#define _SC_MAPPED_FILES 53
-#define _SC_MEMLOCK 54
-#define _SC_MEMLOCK_RANGE 55
-#define _SC_MEMORY_PROTECTION 56
-#define _SC_MESSAGE_PASSING 57
-#define _SC_MQ_OPEN_MAX 58
-#define _SC_MQ_PRIO_MAX 59
-#define _SC_PRIORITIZED_IO 60
-#define _SC_PRIORITY_SCHEDULING 61
-#define _SC_RAW_SOCKETS 62
-#define _SC_READER_WRITER_LOCKS 63
-#define _SC_REALTIME_SIGNALS 64
-#define _SC_REGEXP 65
-#define _SC_RTSIG_MAX 66
-#define _SC_SEMAPHORES 67
-#define _SC_SHARED_MEMORY_OBJECTS 68
-#define _SC_SHELL 69
-#define _SC_SIGQUEUE_MAX 70
-#define _SC_SPAWN 71
-#define _SC_SPIN_LOCKS 72
-#define _SC_SPORADIC_SERVER 73
-#define _SC_SS_REPL_MAX 74
-#define _SC_SYNCHRONIZED_IO 75
-#define _SC_SYMLOOP_MAX 76
-#define _SC_THREAD_ATTR_STACKADDR 77
-#define _SC_THREAD_ATTR_STACKSIZE 78
-#define _SC_THREAD_CPUTIME 79
-#define _SC_THREAD_DESTRUCTOR_ITERATIONS 80
-#define _SC_THREAD_KEYS_MAX 81
-#define _SC_THREAD_PRIO_INHERIT 82
-#define _SC_THREAD_PRIO_PROTECT 83
-#define _SC_THREAD_PRIORITY_SCHEDULING 84
-#define _SC_THREAD_PROCESS_SHARED 85
-#define _SC_THREAD_ROBUST_PRIO_INHERIT 86
-#define _SC_THREAD_ROBUST_PRIO_PROTECT 87
-#define _SC_THREAD_SPORADIC_SERVER 88
-#define _SC_THREAD_STACK_MIN 89
-#define _SC_THREAD_THREADS_MAX 90
-#define _SC_THREADS 91
-#define _SC_TIMEOUTS 92
-#define _SC_TIMER_MAX 93
-#define _SC_TIMERS 94
-#define _SC_TRACE 95
-#define _SC_TRACE_EVENT_FILTER 96
-#define _SC_TRACE_EVENT_NAME_MAX 97
-#define _SC_TRACE_INHERIT 98
-#define _SC_TRACE_LOG 99
-#define _SC_GETGR_R_SIZE_MAX 100
-#define _SC_GETPW_R_SIZE_MAX 101
-#define _SC_LOGIN_NAME_MAX 102
-#define _SC_THREAD_SAFE_FUNCTIONS 103
-#define _SC_TRACE_NAME_MAX 104
-#define _SC_TRACE_SYS_MAX 105
-#define _SC_TRACE_USER_EVENT_MAX 106
-#define _SC_TTY_NAME_MAX 107
-#define _SC_TYPED_MEMORY_OBJECTS 108
-#define _SC_V6_ILP32_OFF32 109
-#define _SC_V6_ILP32_OFFBIG 110
-#define _SC_V6_LP64_OFF64 111
-#define _SC_V6_LPBIG_OFFBIG 112
-#define _SC_V7_ILP32_OFF32 113
-#define _SC_V7_ILP32_OFFBIG 114
-#define _SC_V7_LP64_OFF64 115
-#define _SC_V7_LPBIG_OFFBIG 116
-#define _SC_XOPEN_CRYPT 117
-#define _SC_XOPEN_ENH_I18N 118
-#define _SC_XOPEN_LEGACY 119
-#define _SC_XOPEN_REALTIME 120
-#define _SC_XOPEN_REALTIME_THREADS 121
-#define _SC_XOPEN_STREAMS 122
-#define _SC_XOPEN_UNIX 123
-#define _SC_XOPEN_UUCP 124
-#define _SC_XOPEN_VERSION 125
-
-#define _SC_PHYS_PAGES 500
-#define _SC_AVPHYS_PAGES 501
-#define _SC_NPROCESSORS_CONF 502
-#define _SC_NPROCESSORS_ONLN 503
-
-/* configurable system strings */
-#define _CS_PATH 1
-
#endif /* !_SYS_UNISTD_H_ */