Add arm-nacl port.
[glibc.git] / sysdeps / nacl / bits / posix_opt.h
blob2a5d6fd70ab8d2d14b8b0142a622bcb06943ecaf
1 /* Define POSIX options for NaCl.
2 Copyright (C) 2015 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public License as
7 published by the Free Software Foundation; either version 2.1 of the
8 License, or (at your option) any later version.
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; see the file COPYING.LIB. If
17 not, see <http://www.gnu.org/licenses/>. */
19 #ifndef _BITS_POSIX_OPT_H
20 #define _BITS_POSIX_OPT_H 1
22 /* Job control is supported. (Not really, but the APIs exist.) */
23 #define _POSIX_JOB_CONTROL 1
25 /* Processes have a saved set-user-ID and a saved set-group-ID. */
26 #define _POSIX_SAVED_IDS 1
28 /* Priority scheduling is supported. ??? */
29 #define _POSIX_PRIORITY_SCHEDULING 200809L
31 /* Synchronizing file data is supported. ??? */
32 #define _POSIX_SYNCHRONIZED_IO 200809L
34 /* The fsync function is present. */
35 #define _POSIX_FSYNC 200809L
37 /* Mapping of files to memory is supported. */
38 #define _POSIX_MAPPED_FILES 200809L
40 /* Locking of all memory is not supported. */
41 #define _POSIX_MEMLOCK -1
43 /* Locking of ranges of memory is not supported. */
44 #define _POSIX_MEMLOCK_RANGE -1
46 /* Setting of memory protections is supported. */
47 #define _POSIX_MEMORY_PROTECTION 200809L
49 /* Some filesystems allow all users to change file ownership. */
50 #define _POSIX_CHOWN_RESTRICTED 0
52 /* `c_cc' member of 'struct termios' structure can be disabled by
53 using the value _POSIX_VDISABLE. ??? */
54 #define _POSIX_VDISABLE '\0'
56 /* Filenames are not silently truncated. */
57 #define _POSIX_NO_TRUNC 1
59 /* X/Open realtime support is not fully available. This requires the
60 following set of POSIX.1 features, not all of which NaCl supports:
61 _POSIX_FSYNC
62 _POSIX_MEMLOCK
63 _POSIX_MEMLOCK_RANGE
64 _POSIX_MESSAGE_PASSING
65 _POSIX_PRIORITIZED_IO
66 _POSIX_PRIORITY_SCHEDULING
67 _POSIX_SHARED_MEMORY_OBJECTS
68 _POSIX_SYNCHRONIZED_IO
70 #define _XOPEN_REALTIME -1
72 /* X/Open thread realtime support is not available. This requires the
73 following set of POSIX.1 features, none of which NaCl supports:
74 _POSIX_THREAD_PRIO_INHERIT
75 _POSIX_THREAD_PRIO_PROTECT
76 _POSIX_THREAD_PRIORITY_SCHEDULING
77 _POSIX_THREAD_ROBUST_PRIO_INHERIT
78 _POSIX_THREAD_ROBUST_PRIO_PROTECT
80 #define _XOPEN_REALTIME_THREADS -1
82 /* XPG4.2 shared memory is not supported.
83 ??? What is this? shm* interfaces?
85 #define _XOPEN_SHM -1
87 /* POSIX threads are supported. */
88 #define _POSIX_THREADS 200809L
90 /* We have the reentrant functions described in POSIX. */
91 #define _POSIX_REENTRANT_FUNCTIONS 1
92 #define _POSIX_THREAD_SAFE_FUNCTIONS 200809L
94 /* We do not provide priority scheduling for threads. */
95 #define _POSIX_THREAD_PRIORITY_SCHEDULING -1
97 /* We support user-defined stack sizes. */
98 #define _POSIX_THREAD_ATTR_STACKSIZE 200809L
100 /* We support user-defined stacks. */
101 #define _POSIX_THREAD_ATTR_STACKADDR 200809L
103 /* We do not support priority inheritence. */
104 #define _POSIX_THREAD_PRIO_INHERIT -1
106 /* We do not support priority protection. */
107 #define _POSIX_THREAD_PRIO_PROTECT -1
109 #ifdef __USE_XOPEN2K8
110 /* We do not support priority inheritence for robust mutexes. */
111 # define _POSIX_THREAD_ROBUST_PRIO_INHERIT -1
113 /* We do not support priority protection for robust mutexes. */
114 # define _POSIX_THREAD_ROBUST_PRIO_PROTECT -1
115 #endif
117 /* We support POSIX.1b semaphores. */
118 #define _POSIX_SEMAPHORES 200809L
120 /* Real-time signals are supported. ??? */
121 #define _POSIX_REALTIME_SIGNALS 200809L
123 /* We support asynchronous I/O. */
124 #define _POSIX_ASYNCHRONOUS_IO 200809L
125 #define _POSIX_ASYNC_IO 1
126 /* Alternative name for Unix98. */
127 #define _LFS_ASYNCHRONOUS_IO 1
128 /* Support for prioritization is not available. */
129 #define _POSIX_PRIORITIZED_IO -1
131 /* The LFS support in asynchronous I/O is also available. */
132 #define _LFS64_ASYNCHRONOUS_IO 1
134 /* The rest of the LFS is also available. */
135 #define _LFS_LARGEFILE 1
136 #define _LFS64_LARGEFILE 1
137 #define _LFS64_STDIO 1
139 /* POSIX shared memory objects are implemented. */
140 #define _POSIX_SHARED_MEMORY_OBJECTS 200809L
142 /* Process CPU-time clocks are not supported. */
143 #define _POSIX_CPUTIME -1
145 /* Thread CPU-time locks are supported. */
146 #define _POSIX_THREAD_CPUTIME 200809L
148 /* GNU libc provides regular expression handling. */
149 #define _POSIX_REGEXP 1
151 /* Reader/Writer locks are available. */
152 #define _POSIX_READER_WRITER_LOCKS 200809L
154 /* We have a POSIX shell. */
155 #define _POSIX_SHELL 1
157 /* We support the Timeouts option. */
158 #define _POSIX_TIMEOUTS 200809L
160 /* We support spinlocks. */
161 #define _POSIX_SPIN_LOCKS 200809L
163 /* The `spawn' function family is supported. */
164 #define _POSIX_SPAWN 200809L
166 /* We have POSIX timers. */
167 #define _POSIX_TIMERS 200809L
169 /* The barrier functions are available. */
170 #define _POSIX_BARRIERS 200809L
172 /* POSIX message queues are not available. */
173 #define _POSIX_MESSAGE_PASSING -1
175 /* Thread process-shared synchronization is not supported. */
176 #define _POSIX_THREAD_PROCESS_SHARED -1
178 /* The monotonic clock is available. */
179 #define _POSIX_MONOTONIC_CLOCK 200809L
181 /* The clock selection interfaces are available. ??? Actually only
182 clock_nanosleep works, and pthread_condattr_setclock does not. */
183 #define _POSIX_CLOCK_SELECTION 200809L
185 /* Advisory information interfaces are available. */
186 #define _POSIX_ADVISORY_INFO 200809L
188 /* IPv6 support is available. */
189 #define _POSIX_IPV6 200809L
191 /* Raw socket support is available. */
192 #define _POSIX_RAW_SOCKETS 200809L
194 /* We have at least one terminal. */
195 #define _POSIX2_CHAR_TERM 200809L
197 /* Neither process nor thread sporadic server interfaces is available. */
198 #define _POSIX_SPORADIC_SERVER -1
199 #define _POSIX_THREAD_SPORADIC_SERVER -1
201 /* trace.h is not available. */
202 #define _POSIX_TRACE -1
203 #define _POSIX_TRACE_EVENT_FILTER -1
204 #define _POSIX_TRACE_INHERIT -1
205 #define _POSIX_TRACE_LOG -1
207 /* Typed memory objects are not available. */
208 #define _POSIX_TYPED_MEMORY_OBJECTS -1
210 #endif /* bits/posix_opt.h */