fcntl_darwin_amd64.go (101980B)
1 // Code generated by 'ccgo fcntl/gen.c -crt-import-path "" -export-defines "" -export-enums "" -export-externs X -export-fields F -export-structs "" -export-typedefs "" -header -hide _OSSwapInt16,_OSSwapInt32,_OSSwapInt64 -ignore-unsupported-alignment -o fcntl/fcntl_darwin_amd64.go -pkgname fcntl', DO NOT EDIT. 2 3 package fcntl 4 5 import ( 6 "math" 7 "reflect" 8 "sync/atomic" 9 "unsafe" 10 ) 11 12 var _ = math.Pi 13 var _ reflect.Kind 14 var _ atomic.Value 15 var _ unsafe.Pointer 16 17 const ( 18 AT_EACCESS = 0x0010 // fcntl.h:138:1: 19 AT_FDCWD = -2 // fcntl.h:133:1: 20 AT_FDONLY = 0x0400 // fcntl.h:144:1: 21 AT_REALDEV = 0x0200 // fcntl.h:143:1: 22 AT_REMOVEDIR = 0x0080 // fcntl.h:141:1: 23 AT_SYMLINK_FOLLOW = 0x0040 // fcntl.h:140:1: 24 AT_SYMLINK_NOFOLLOW = 0x0020 // fcntl.h:139:1: 25 CPF_IGNORE_MODE = 0x0002 // fcntl.h:201:1: 26 CPF_MASK = 3 // fcntl.h:202:1: 27 CPF_OVERWRITE = 0x0001 // fcntl.h:200:1: 28 FAPPEND = 8 // fcntl.h:186:1: 29 FASYNC = 64 // fcntl.h:187:1: 30 FCNTL_FS_SPECIFIC_BASE = 0x00010000 // fcntl.h:297:1: 31 FD_CLOEXEC = 1 // fcntl.h:306:1: 32 FFDSYNC = 4194304 // fcntl.h:189:1: 33 FFSYNC = 128 // fcntl.h:188:1: 34 FNDELAY = 4 // fcntl.h:191:1: 35 FNONBLOCK = 4 // fcntl.h:190:1: 36 FREAD = 0x0001 // fcntl.h:110:1: 37 FWRITE = 0x0002 // fcntl.h:111:1: 38 F_ADDFILESIGS = 61 // fcntl.h:246:1: 39 F_ADDFILESIGS_FOR_DYLD_SIM = 83 // fcntl.h:279:1: 40 F_ADDFILESIGS_RETURN = 97 // fcntl.h:285:1: 41 F_ADDSIGS = 59 // fcntl.h:243:1: 42 F_ALLOCATEALL = 0x00000004 // fcntl.h:330:1: 43 F_ALLOCATECONTIG = 0x00000002 // fcntl.h:329:1: 44 F_BARRIERFSYNC = 85 // fcntl.h:282:1: 45 F_CHECK_LV = 98 // fcntl.h:286:1: 46 F_CHKCLEAN = 41 // fcntl.h:225:1: 47 F_DUPFD = 0 // fcntl.h:210:1: 48 F_DUPFD_CLOEXEC = 67 // fcntl.h:302:1: 49 F_FINDSIGS = 78 // fcntl.h:276:1: 50 F_FLUSH_DATA = 40 // fcntl.h:224:1: 51 F_FREEZE_FS = 53 // fcntl.h:238:1: 52 F_FULLFSYNC = 51 // fcntl.h:236:1: 53 F_GETCODEDIR = 72 // fcntl.h:264:1: 54 F_GETFD = 1 // fcntl.h:211:1: 55 F_GETFL = 3 // fcntl.h:213:1: 56 F_GETLK = 7 // fcntl.h:217:1: 57 F_GETLKPID = 66 // fcntl.h:256:1: 58 F_GETNOSIGPIPE = 74 // fcntl.h:267:1: 59 F_GETOWN = 5 // fcntl.h:215:1: 60 F_GETPATH = 50 // fcntl.h:235:1: 61 F_GETPATH_MTMINFO = 71 // fcntl.h:262:1: 62 F_GETPATH_NOFIRMLINK = 102 // fcntl.h:294:1: 63 F_GETPROTECTIONCLASS = 63 // fcntl.h:251:1: 64 F_GETPROTECTIONLEVEL = 77 // fcntl.h:274:1: 65 F_GLOBAL_NOCACHE = 55 // fcntl.h:240:1: 66 F_LOG2PHYS = 49 // fcntl.h:234:1: 67 F_LOG2PHYS_EXT = 65 // fcntl.h:254:1: 68 F_NOCACHE = 48 // fcntl.h:233:1: 69 F_NODIRECT = 62 // fcntl.h:248:1: 70 F_PATHPKG_CHECK = 52 // fcntl.h:237:1: 71 F_PEOFPOSMODE = 3 // fcntl.h:334:1: 72 F_PREALLOCATE = 42 // fcntl.h:226:1: 73 F_PUNCHHOLE = 99 // fcntl.h:288:1: 74 F_RDADVISE = 44 // fcntl.h:228:1: 75 F_RDAHEAD = 45 // fcntl.h:229:1: 76 F_RDLCK = 1 // fcntl.h:309:1: 77 F_SETBACKINGSTORE = 70 // fcntl.h:261:1: 78 F_SETFD = 2 // fcntl.h:212:1: 79 F_SETFL = 4 // fcntl.h:214:1: 80 F_SETLK = 8 // fcntl.h:218:1: 81 F_SETLKW = 9 // fcntl.h:219:1: 82 F_SETLKWTIMEOUT = 10 // fcntl.h:221:1: 83 F_SETNOSIGPIPE = 73 // fcntl.h:266:1: 84 F_SETOWN = 6 // fcntl.h:216:1: 85 F_SETPROTECTIONCLASS = 64 // fcntl.h:252:1: 86 F_SETSIZE = 43 // fcntl.h:227:1: 87 F_SINGLE_WRITER = 76 // fcntl.h:271:1: 88 F_SPECULATIVE_READ = 101 // fcntl.h:292:1: 89 F_THAW_FS = 54 // fcntl.h:239:1: 90 F_TRANSCODEKEY = 75 // fcntl.h:269:1: 91 F_TRIM_ACTIVE_FILE = 100 // fcntl.h:290:1: 92 F_UNLCK = 2 // fcntl.h:310:1: 93 F_VOLPOSMODE = 4 // fcntl.h:336:1: 94 F_WRLCK = 3 // fcntl.h:311:1: 95 LOCK_EX = 0x02 // fcntl.h:421:1: 96 LOCK_NB = 0x04 // fcntl.h:422:1: 97 LOCK_SH = 0x01 // fcntl.h:420:1: 98 LOCK_UN = 0x08 // fcntl.h:423:1: 99 O_ACCMODE = 0x0003 // fcntl.h:99:1: 100 O_ALERT = 0x20000000 // fcntl.h:502:1: 101 O_APPEND = 0x0008 // fcntl.h:114:1: 102 O_ASYNC = 0x0040 // fcntl.h:121:1: 103 O_CLOEXEC = 0x1000000 // fcntl.h:165:1: 104 O_CREAT = 0x0200 // fcntl.h:125:1: 105 O_DIRECTORY = 0x100000 // fcntl.h:157:1: 106 O_DP_GETRAWENCRYPTED = 0x0001 // fcntl.h:174:1: 107 O_DP_GETRAWUNENCRYPTED = 0x0002 // fcntl.h:175:1: 108 O_DSYNC = 0x400000 // _o_dsync.h:29:1: 109 O_EVTONLY = 0x8000 // fcntl.h:149:1: 110 O_EXCL = 0x0800 // fcntl.h:127:1: 111 O_EXLOCK = 0x0020 // fcntl.h:120:1: 112 O_FSYNC = 128 // fcntl.h:122:1: 113 O_NDELAY = 4 // fcntl.h:192:1: 114 O_NOCTTY = 0x20000 // fcntl.h:153:1: 115 O_NOFOLLOW = 0x0100 // fcntl.h:123:1: 116 O_NONBLOCK = 0x0004 // fcntl.h:113:1: 117 O_POPUP = 0x80000000 // fcntl.h:501:1: 118 O_RDONLY = 0x0000 // fcntl.h:96:1: 119 O_RDWR = 0x0002 // fcntl.h:98:1: 120 O_SHLOCK = 0x0010 // fcntl.h:119:1: 121 O_SYMLINK = 0x200000 // fcntl.h:158:1: 122 O_SYNC = 0x0080 // _o_sync.h:29:1: 123 O_TRUNC = 0x0400 // fcntl.h:126:1: 124 O_WRONLY = 0x0001 // fcntl.h:97:1: 125 SEEK_CUR = 1 // _seek_set.h:34:1: 126 SEEK_DATA = 4 // _seek_set.h:44:1: 127 SEEK_END = 2 // _seek_set.h:35:1: 128 SEEK_HOLE = 3 // _seek_set.h:40:1: 129 SEEK_SET = 0 // _seek_set.h:33:1: 130 S_IEXEC = 64 // _s_ifmt.h:72:1: 131 S_IFBLK = 0060000 // _s_ifmt.h:39:1: 132 S_IFCHR = 0020000 // _s_ifmt.h:37:1: 133 S_IFDIR = 0040000 // _s_ifmt.h:38:1: 134 S_IFIFO = 0010000 // _s_ifmt.h:36:1: 135 S_IFLNK = 0120000 // _s_ifmt.h:41:1: 136 S_IFMT = 0170000 // _s_ifmt.h:35:1: 137 S_IFREG = 0100000 // _s_ifmt.h:40:1: 138 S_IFSOCK = 0140000 // _s_ifmt.h:42:1: 139 S_IFWHT = 0160000 // _s_ifmt.h:44:1: 140 S_IREAD = 256 // _s_ifmt.h:70:1: 141 S_IRGRP = 0000040 // _s_ifmt.h:55:1: 142 S_IROTH = 0000004 // _s_ifmt.h:60:1: 143 S_IRUSR = 0000400 // _s_ifmt.h:50:1: 144 S_IRWXG = 0000070 // _s_ifmt.h:54:1: 145 S_IRWXO = 0000007 // _s_ifmt.h:59:1: 146 S_IRWXU = 0000700 // _s_ifmt.h:49:1: 147 S_ISGID = 0002000 // _s_ifmt.h:65:1: 148 S_ISTXT = 512 // _s_ifmt.h:69:1: 149 S_ISUID = 0004000 // _s_ifmt.h:64:1: 150 S_ISVTX = 0001000 // _s_ifmt.h:66:1: 151 S_IWGRP = 0000020 // _s_ifmt.h:56:1: 152 S_IWOTH = 0000002 // _s_ifmt.h:61:1: 153 S_IWRITE = 128 // _s_ifmt.h:71:1: 154 S_IWUSR = 0000200 // _s_ifmt.h:51:1: 155 S_IXGRP = 0000010 // _s_ifmt.h:57:1: 156 S_IXOTH = 0000001 // _s_ifmt.h:62:1: 157 S_IXUSR = 0000100 // _s_ifmt.h:52:1: 158 X_BSD_I386__TYPES_H_ = 0 // _types.h:29:1: 159 X_BSD_MACHINE_TYPES_H_ = 0 // types.h:32:1: 160 X_BSD_MACHINE__TYPES_H_ = 0 // _types.h:29:1: 161 X_CDEFS_H_ = 0 // cdefs.h:68:1: 162 X_DARWIN_FEATURE_64_BIT_INODE = 1 // cdefs.h:745:1: 163 X_DARWIN_FEATURE_ONLY_UNIX_CONFORMANCE = 1 // cdefs.h:771:1: 164 X_DARWIN_FEATURE_UNIX_CONFORMANCE = 3 // cdefs.h:779:1: 165 X_FILESEC_T = 0 // _filesec_t.h:29:1: 166 X_FILE_OFFSET_BITS = 64 // <builtin>:25:1: 167 X_INT16_T = 0 // _int16_t.h:29:1: 168 X_INT32_T = 0 // _int32_t.h:29:1: 169 X_INT64_T = 0 // _int64_t.h:29:1: 170 X_INT8_T = 0 // _int8_t.h:29:1: 171 X_INTPTR_T = 0 // _intptr_t.h:29:1: 172 X_LP64 = 1 // <predefined>:1:1: 173 X_MACHTYPES_H_ = 0 // types.h:67:1: 174 X_MODE_T = 0 // _mode_t.h:29:1: 175 X_Nonnull = 0 // cdefs.h:243:1: 176 X_Null_unspecified = 0 // cdefs.h:246:1: 177 X_Nullable = 0 // cdefs.h:240:1: 178 X_OFF_T = 0 // _off_t.h:29:1: 179 X_PID_T = 0 // _pid_t.h:29:1: 180 X_SIZE_T = 0 // _size_t.h:29:1: 181 X_SYS_FCNTL_H_ = 0 // fcntl.h:71:1: 182 X_SYS__PTHREAD_TYPES_H_ = 0 // _pthread_types.h:30:1: 183 X_SYS__TYPES_H_ = 0 // _types.h:30:1: 184 X_UINTPTR_T = 0 // _uintptr_t.h:29:1: 185 X_U_INT16_T = 0 // _u_int16_t.h:29:1: 186 X_U_INT32_T = 0 // _u_int32_t.h:29:1: 187 X_U_INT64_T = 0 // _u_int64_t.h:29:1: 188 X_U_INT8_T = 0 // _u_int8_t.h:29:1: 189 ) 190 191 const ( /* fcntl.h:512:1: */ 192 FILESEC_OWNER = 1 193 FILESEC_GROUP = 2 194 FILESEC_UUID = 3 195 FILESEC_MODE = 4 196 FILESEC_ACL = 5 197 FILESEC_GRPUUID = 6 198 199 // XXX these are private to the implementation 200 FILESEC_ACL_RAW = 100 201 FILESEC_ACL_ALLOCSIZE = 101 202 ) 203 204 type Ptrdiff_t = int64 /* <builtin>:3:26 */ 205 206 type Size_t = uint64 /* <builtin>:9:23 */ 207 208 type Wchar_t = int32 /* <builtin>:15:24 */ 209 210 type X__int128_t = struct { 211 Flo int64 212 Fhi int64 213 } /* <builtin>:21:43 */ // must match modernc.org/mathutil.Int128 214 type X__uint128_t = struct { 215 Flo uint64 216 Fhi uint64 217 } /* <builtin>:22:44 */ // must match modernc.org/mathutil.Int128 218 219 type X__builtin_va_list = uintptr /* <builtin>:46:14 */ 220 type X__float128 = float64 /* <builtin>:47:21 */ 221 222 var X__darwin_check_fd_set_overflow uintptr /* <builtin>:146:5: */ 223 224 // Copyright (c) 2000 Apple Computer, Inc. All rights reserved. 225 // 226 // @APPLE_LICENSE_HEADER_START@ 227 // 228 // This file contains Original Code and/or Modifications of Original Code 229 // as defined in and that are subject to the Apple Public Source License 230 // Version 2.0 (the 'License'). You may not use this file except in 231 // compliance with the License. Please obtain a copy of the License at 232 // http://www.opensource.apple.com/apsl/ and read it before using this 233 // file. 234 // 235 // The Original Code and all software distributed under the License are 236 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 237 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 238 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 239 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 240 // Please see the License for the specific language governing rights and 241 // limitations under the License. 242 // 243 // @APPLE_LICENSE_HEADER_END@ 244 // Copyright (c) 2000-2013 Apple Inc. All rights reserved. 245 // 246 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 247 // 248 // This file contains Original Code and/or Modifications of Original Code 249 // as defined in and that are subject to the Apple Public Source License 250 // Version 2.0 (the 'License'). You may not use this file except in 251 // compliance with the License. The rights granted to you under the License 252 // may not be used to create, or enable the creation or redistribution of, 253 // unlawful or unlicensed copies of an Apple operating system, or to 254 // circumvent, violate, or enable the circumvention or violation of, any 255 // terms of an Apple operating system software license agreement. 256 // 257 // Please obtain a copy of the License at 258 // http://www.opensource.apple.com/apsl/ and read it before using this file. 259 // 260 // The Original Code and all software distributed under the License are 261 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 262 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 263 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 264 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 265 // Please see the License for the specific language governing rights and 266 // limitations under the License. 267 // 268 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 269 // Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved 270 // - 271 // Copyright (c) 1983, 1990, 1993 272 // The Regents of the University of California. All rights reserved. 273 // (c) UNIX System Laboratories, Inc. 274 // All or some portions of this file are derived from material licensed 275 // to the University of California by American Telephone and Telegraph 276 // Co. or Unix System Laboratories, Inc. and are reproduced herein with 277 // the permission of UNIX System Laboratories, Inc. 278 // 279 // Redistribution and use in source and binary forms, with or without 280 // modification, are permitted provided that the following conditions 281 // are met: 282 // 1. Redistributions of source code must retain the above copyright 283 // notice, this list of conditions and the following disclaimer. 284 // 2. Redistributions in binary form must reproduce the above copyright 285 // notice, this list of conditions and the following disclaimer in the 286 // documentation and/or other materials provided with the distribution. 287 // 3. All advertising materials mentioning features or use of this software 288 // must display the following acknowledgement: 289 // This product includes software developed by the University of 290 // California, Berkeley and its contributors. 291 // 4. Neither the name of the University nor the names of its contributors 292 // may be used to endorse or promote products derived from this software 293 // without specific prior written permission. 294 // 295 // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 296 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 297 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 298 // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 299 // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 300 // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 301 // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 302 // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 303 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 304 // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 305 // SUCH DAMAGE. 306 // 307 // @(#)fcntl.h 8.3 (Berkeley) 1/21/94 308 309 // This file includes the definitions for open and fcntl 310 // described by POSIX for <fcntl.h>; it also includes 311 // related kernel definitions. 312 // Copyright (c) 2003-2007 Apple Inc. All rights reserved. 313 // 314 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 315 // 316 // This file contains Original Code and/or Modifications of Original Code 317 // as defined in and that are subject to the Apple Public Source License 318 // Version 2.0 (the 'License'). You may not use this file except in 319 // compliance with the License. The rights granted to you under the License 320 // may not be used to create, or enable the creation or redistribution of, 321 // unlawful or unlicensed copies of an Apple operating system, or to 322 // circumvent, violate, or enable the circumvention or violation of, any 323 // terms of an Apple operating system software license agreement. 324 // 325 // Please obtain a copy of the License at 326 // http://www.opensource.apple.com/apsl/ and read it before using this file. 327 // 328 // The Original Code and all software distributed under the License are 329 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 330 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 331 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 332 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 333 // Please see the License for the specific language governing rights and 334 // limitations under the License. 335 // 336 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 337 338 // Copyright (c) 2000-2018 Apple Inc. All rights reserved. 339 // 340 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 341 // 342 // This file contains Original Code and/or Modifications of Original Code 343 // as defined in and that are subject to the Apple Public Source License 344 // Version 2.0 (the 'License'). You may not use this file except in 345 // compliance with the License. The rights granted to you under the License 346 // may not be used to create, or enable the creation or redistribution of, 347 // unlawful or unlicensed copies of an Apple operating system, or to 348 // circumvent, violate, or enable the circumvention or violation of, any 349 // terms of an Apple operating system software license agreement. 350 // 351 // Please obtain a copy of the License at 352 // http://www.opensource.apple.com/apsl/ and read it before using this file. 353 // 354 // The Original Code and all software distributed under the License are 355 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 356 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 357 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 358 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 359 // Please see the License for the specific language governing rights and 360 // limitations under the License. 361 // 362 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 363 // Copyright 1995 NeXT Computer, Inc. All rights reserved. 364 // Copyright (c) 1991, 1993 365 // The Regents of the University of California. All rights reserved. 366 // 367 // This code is derived from software contributed to Berkeley by 368 // Berkeley Software Design, Inc. 369 // 370 // Redistribution and use in source and binary forms, with or without 371 // modification, are permitted provided that the following conditions 372 // are met: 373 // 1. Redistributions of source code must retain the above copyright 374 // notice, this list of conditions and the following disclaimer. 375 // 2. Redistributions in binary form must reproduce the above copyright 376 // notice, this list of conditions and the following disclaimer in the 377 // documentation and/or other materials provided with the distribution. 378 // 3. All advertising materials mentioning features or use of this software 379 // must display the following acknowledgement: 380 // This product includes software developed by the University of 381 // California, Berkeley and its contributors. 382 // 4. Neither the name of the University nor the names of its contributors 383 // may be used to endorse or promote products derived from this software 384 // without specific prior written permission. 385 // 386 // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 387 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 388 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 389 // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 390 // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 391 // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 392 // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 393 // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 394 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 395 // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 396 // SUCH DAMAGE. 397 // 398 // @(#)cdefs.h 8.8 (Berkeley) 1/9/95 399 400 // This SDK is designed to work with clang and specific versions of 401 // gcc >= 4.0 with Apple's patch sets 402 403 // Compatibility with compilers and environments that don't support compiler 404 // feature checking function-like macros. 405 406 // The __CONCAT macro is used to concatenate parts of symbol names, e.g. 407 // with "#define OLD(foo) __CONCAT(old,foo)", OLD(foo) produces oldfoo. 408 // The __CONCAT macro is a bit tricky -- make sure you don't put spaces 409 // in between its arguments. __CONCAT can also concatenate double-quoted 410 // strings produced by the __STRING macro, but this only works with ANSI C. 411 412 // In non-ANSI C environments, new programs will want ANSI-only C keywords 413 // deleted from the program and old programs will want them left alone. 414 // When using a compiler other than gcc, programs using the ANSI C keywords 415 // const, inline etc. as normal identifiers should define -DNO_ANSI_KEYWORDS. 416 // When using "gcc -traditional", we assume that this is the intent; if 417 // __GNUC__ is defined but __STDC__ is not, we leave the new keywords alone. 418 419 // __unused denotes variables and functions that may not be used, preventing 420 // the compiler from warning about it if not used. 421 422 // __used forces variables and functions to be included even if it appears 423 // to the compiler that they are not used (and would thust be discarded). 424 425 // __cold marks code used for debugging or that is rarely taken 426 // and tells the compiler to optimize for size and outline code. 427 428 // __deprecated causes the compiler to produce a warning when encountering 429 // code using the deprecated functionality. 430 // __deprecated_msg() does the same, and compilers that support it will print 431 // a message along with the deprecation warning. 432 // This may require turning on such warning with the -Wdeprecated flag. 433 // __deprecated_enum_msg() should be used on enums, and compilers that support 434 // it will print the deprecation warning. 435 // __kpi_deprecated() specifically indicates deprecation of kernel programming 436 // interfaces in Kernel.framework used by KEXTs. 437 438 // __unavailable causes the compiler to error out when encountering 439 // code using the tagged function of variable. 440 441 // Delete pseudo-keywords wherever they are not available or needed. 442 443 // We use `__restrict' as a way to define the `restrict' type qualifier 444 // without disturbing older software that is unaware of C99 keywords. 445 446 // Compatibility with compilers and environments that don't support the 447 // nullability feature. 448 449 // __disable_tail_calls causes the compiler to not perform tail call 450 // optimization inside the marked function. 451 452 // __not_tail_called causes the compiler to prevent tail call optimization 453 // on statically bound calls to the function. It has no effect on indirect 454 // calls. Virtual functions, objective-c methods, and functions marked as 455 // "always_inline" cannot be marked as __not_tail_called. 456 457 // __result_use_check warns callers of a function that not using the function 458 // return value is a bug, i.e. dismissing malloc() return value results in a 459 // memory leak. 460 461 // __swift_unavailable causes the compiler to mark a symbol as specifically 462 // unavailable in Swift, regardless of any other availability in C. 463 464 // __abortlike is the attribute to put on functions like abort() that are 465 // typically used to mark assertions. These optimize the codegen 466 // for outlining while still maintaining debugability. 467 468 // Declaring inline functions within headers is error-prone due to differences 469 // across various versions of the C language and extensions. __header_inline 470 // can be used to declare inline functions within system headers. In cases 471 // where you want to force inlining instead of letting the compiler make 472 // the decision, you can use __header_always_inline. 473 // 474 // Be aware that using inline for functions which compilers may also provide 475 // builtins can behave differently under various compilers. If you intend to 476 // provide an inline version of such a function, you may want to use a macro 477 // instead. 478 // 479 // The check for !__GNUC__ || __clang__ is because gcc doesn't correctly 480 // support c99 inline in some cases: 481 // http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55965 482 483 // Compiler-dependent macros that bracket portions of code where the 484 // "-Wunreachable-code" warning should be ignored. Please use sparingly. 485 486 // Compiler-dependent macros to declare that functions take printf-like 487 // or scanf-like arguments. They are null except for versions of gcc 488 // that are known to support the features properly. Functions declared 489 // with these attributes will cause compilation warnings if there is a 490 // mismatch between the format string and subsequent function parameter 491 // types. 492 493 // Source compatibility only, ID string not emitted in object file 494 495 // __alloc_size can be used to label function arguments that represent the 496 // size of memory that the function allocates and returns. The one-argument 497 // form labels a single argument that gives the allocation size (where the 498 // arguments are numbered from 1): 499 // 500 // void *malloc(size_t __size) __alloc_size(1); 501 // 502 // The two-argument form handles the case where the size is calculated as the 503 // product of two arguments: 504 // 505 // void *calloc(size_t __count, size_t __size) __alloc_size(1,2); 506 507 // COMPILATION ENVIRONMENTS -- see compat(5) for additional detail 508 // 509 // DEFAULT By default newly complied code will get POSIX APIs plus 510 // Apple API extensions in scope. 511 // 512 // Most users will use this compilation environment to avoid 513 // behavioral differences between 32 and 64 bit code. 514 // 515 // LEGACY Defining _NONSTD_SOURCE will get pre-POSIX APIs plus Apple 516 // API extensions in scope. 517 // 518 // This is generally equivalent to the Tiger release compilation 519 // environment, except that it cannot be applied to 64 bit code; 520 // its use is discouraged. 521 // 522 // We expect this environment to be deprecated in the future. 523 // 524 // STRICT Defining _POSIX_C_SOURCE or _XOPEN_SOURCE restricts the 525 // available APIs to exactly the set of APIs defined by the 526 // corresponding standard, based on the value defined. 527 // 528 // A correct, portable definition for _POSIX_C_SOURCE is 200112L. 529 // A correct, portable definition for _XOPEN_SOURCE is 600L. 530 // 531 // Apple API extensions are not visible in this environment, 532 // which can cause Apple specific code to fail to compile, 533 // or behave incorrectly if prototypes are not in scope or 534 // warnings about missing prototypes are not enabled or ignored. 535 // 536 // In any compilation environment, for correct symbol resolution to occur, 537 // function prototypes must be in scope. It is recommended that all Apple 538 // tools users add either the "-Wall" or "-Wimplicit-function-declaration" 539 // compiler flags to their projects to be warned when a function is being 540 // used without a prototype in scope. 541 542 // These settings are particular to each product. 543 // Platform: MacOSX 544 // #undef __DARWIN_ONLY_UNIX_CONFORMANCE (automatically set for 64-bit) 545 546 // The __DARWIN_ALIAS macros are used to do symbol renaming; they allow 547 // legacy code to use the old symbol, thus maintaining binary compatibility 548 // while new code can use a standards compliant version of the same function. 549 // 550 // __DARWIN_ALIAS is used by itself if the function signature has not 551 // changed, it is used along with a #ifdef check for __DARWIN_UNIX03 552 // if the signature has changed. Because the __LP64__ environment 553 // only supports UNIX03 semantics it causes __DARWIN_UNIX03 to be 554 // defined, but causes __DARWIN_ALIAS to do no symbol mangling. 555 // 556 // As a special case, when XCode is used to target a specific version of the 557 // OS, the manifest constant __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ 558 // will be defined by the compiler, with the digits representing major version 559 // time 100 + minor version times 10 (e.g. 10.5 := 1050). If we are targeting 560 // pre-10.5, and it is the default compilation environment, revert the 561 // compilation environment to pre-__DARWIN_UNIX03. 562 563 // symbol suffixes used for symbol versioning 564 565 // symbol versioning macros 566 567 // symbol release macros 568 // Copyright (c) 2010 Apple Inc. All rights reserved. 569 // 570 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 571 // 572 // This file contains Original Code and/or Modifications of Original Code 573 // as defined in and that are subject to the Apple Public Source License 574 // Version 2.0 (the 'License'). You may not use this file except in 575 // compliance with the License. The rights granted to you under the License 576 // may not be used to create, or enable the creation or redistribution of, 577 // unlawful or unlicensed copies of an Apple operating system, or to 578 // circumvent, violate, or enable the circumvention or violation of, any 579 // terms of an Apple operating system software license agreement. 580 // 581 // Please obtain a copy of the License at 582 // http://www.opensource.apple.com/apsl/ and read it before using this file. 583 // 584 // The Original Code and all software distributed under the License are 585 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 586 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 587 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 588 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 589 // Please see the License for the specific language governing rights and 590 // limitations under the License. 591 // 592 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 593 594 // POSIX.1 requires that the macros we test be defined before any standard 595 // header file is included. This permits us to convert values for feature 596 // testing, as necessary, using only _POSIX_C_SOURCE. 597 // 598 // Here's a quick run-down of the versions: 599 // defined(_POSIX_SOURCE) 1003.1-1988 600 // _POSIX_C_SOURCE == 1L 1003.1-1990 601 // _POSIX_C_SOURCE == 2L 1003.2-1992 C Language Binding Option 602 // _POSIX_C_SOURCE == 199309L 1003.1b-1993 603 // _POSIX_C_SOURCE == 199506L 1003.1c-1995, 1003.1i-1995, 604 // and the omnibus ISO/IEC 9945-1: 1996 605 // _POSIX_C_SOURCE == 200112L 1003.1-2001 606 // _POSIX_C_SOURCE == 200809L 1003.1-2008 607 // 608 // In addition, the X/Open Portability Guide, which is now the Single UNIX 609 // Specification, defines a feature-test macro which indicates the version of 610 // that specification, and which subsumes _POSIX_C_SOURCE. 611 612 // Deal with IEEE Std. 1003.1-1990, in which _POSIX_C_SOURCE == 1L. 613 614 // Deal with IEEE Std. 1003.2-1992, in which _POSIX_C_SOURCE == 2L. 615 616 // Deal with various X/Open Portability Guides and Single UNIX Spec. 617 618 // Deal with all versions of POSIX. The ordering relative to the tests above is 619 // important. 620 621 // POSIX C deprecation macros 622 // Copyright (c) 2010 Apple Inc. All rights reserved. 623 // 624 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 625 // 626 // This file contains Original Code and/or Modifications of Original Code 627 // as defined in and that are subject to the Apple Public Source License 628 // Version 2.0 (the 'License'). You may not use this file except in 629 // compliance with the License. The rights granted to you under the License 630 // may not be used to create, or enable the creation or redistribution of, 631 // unlawful or unlicensed copies of an Apple operating system, or to 632 // circumvent, violate, or enable the circumvention or violation of, any 633 // terms of an Apple operating system software license agreement. 634 // 635 // Please obtain a copy of the License at 636 // http://www.opensource.apple.com/apsl/ and read it before using this file. 637 // 638 // The Original Code and all software distributed under the License are 639 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 640 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 641 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 642 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 643 // Please see the License for the specific language governing rights and 644 // limitations under the License. 645 // 646 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 647 648 // Set a single macro which will always be defined and can be used to determine 649 // the appropriate namespace. For POSIX, these values will correspond to 650 // _POSIX_C_SOURCE value. Currently there are two additional levels corresponding 651 // to ANSI (_ANSI_SOURCE) and Darwin extensions (_DARWIN_C_SOURCE) 652 653 // If the developer has neither requested a strict language mode nor a version 654 // of POSIX, turn on functionality provided by __STDC_WANT_LIB_EXT1__ as part 655 // of __DARWIN_C_FULL. 656 657 // long long is not supported in c89 (__STRICT_ANSI__), but g++ -ansi and 658 // c99 still want long longs. While not perfect, we allow long longs for 659 // g++. 660 661 // **************************************** 662 // 663 // Public darwin-specific feature macros 664 // 665 666 // _DARWIN_FEATURE_64_BIT_INODE indicates that the ino_t type is 64-bit, and 667 // structures modified for 64-bit inodes (like struct stat) will be used. 668 669 // _DARWIN_FEATURE_64_ONLY_BIT_INODE indicates that the ino_t type may only 670 // be 64-bit; there is no support for 32-bit ino_t when this macro is defined 671 // (and non-zero). There is no struct stat64 either, as the regular 672 // struct stat will already be the 64-bit version. 673 674 // _DARWIN_FEATURE_ONLY_VERS_1050 indicates that only those APIs updated 675 // in 10.5 exists; no pre-10.5 variants are available. 676 677 // _DARWIN_FEATURE_ONLY_UNIX_CONFORMANCE indicates only UNIX conforming API 678 // are available (the legacy BSD APIs are not available) 679 680 // _DARWIN_FEATURE_UNIX_CONFORMANCE indicates whether UNIX conformance is on, 681 // and specifies the conformance level (3 is SUSv3) 682 683 // This macro casts away the qualifier from the variable 684 // 685 // Note: use at your own risk, removing qualifiers can result in 686 // catastrophic run-time failures. 687 688 // __XNU_PRIVATE_EXTERN is a linkage decoration indicating that a symbol can be 689 // used from other compilation units, but not other libraries or executables. 690 691 // Architecture validation for current SDK 692 693 // Similar to OS_ENUM/OS_CLOSED_ENUM/OS_OPTIONS/OS_CLOSED_OPTIONS 694 // 695 // This provides more advanced type checking on compilers supporting 696 // the proper extensions, even in C. 697 698 // Copyright (c) 2003-2007 Apple Inc. All rights reserved. 699 // 700 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 701 // 702 // This file contains Original Code and/or Modifications of Original Code 703 // as defined in and that are subject to the Apple Public Source License 704 // Version 2.0 (the 'License'). You may not use this file except in 705 // compliance with the License. The rights granted to you under the License 706 // may not be used to create, or enable the creation or redistribution of, 707 // unlawful or unlicensed copies of an Apple operating system, or to 708 // circumvent, violate, or enable the circumvention or violation of, any 709 // terms of an Apple operating system software license agreement. 710 // 711 // Please obtain a copy of the License at 712 // http://www.opensource.apple.com/apsl/ and read it before using this file. 713 // 714 // The Original Code and all software distributed under the License are 715 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 716 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 717 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 718 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 719 // Please see the License for the specific language governing rights and 720 // limitations under the License. 721 // 722 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 723 724 // Copyright (c) 2000-2003 Apple Computer, Inc. All rights reserved. 725 // 726 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 727 // 728 // This file contains Original Code and/or Modifications of Original Code 729 // as defined in and that are subject to the Apple Public Source License 730 // Version 2.0 (the 'License'). You may not use this file except in 731 // compliance with the License. The rights granted to you under the License 732 // may not be used to create, or enable the creation or redistribution of, 733 // unlawful or unlicensed copies of an Apple operating system, or to 734 // circumvent, violate, or enable the circumvention or violation of, any 735 // terms of an Apple operating system software license agreement. 736 // 737 // Please obtain a copy of the License at 738 // http://www.opensource.apple.com/apsl/ and read it before using this file. 739 // 740 // The Original Code and all software distributed under the License are 741 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 742 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 743 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 744 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 745 // Please see the License for the specific language governing rights and 746 // limitations under the License. 747 // 748 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 749 750 // This header file contains integer types. It's intended to also contain 751 // flotaing point and other arithmetic types, as needed, later. 752 753 type X__int8_t = int8 /* _types.h:37:33 */ 754 type X__uint8_t = uint8 /* _types.h:41:33 */ 755 type X__int16_t = int16 /* _types.h:42:33 */ 756 type X__uint16_t = uint16 /* _types.h:43:33 */ 757 type X__int32_t = int32 /* _types.h:44:33 */ 758 type X__uint32_t = uint32 /* _types.h:45:33 */ 759 type X__int64_t = int64 /* _types.h:46:33 */ 760 type X__uint64_t = uint64 /* _types.h:47:33 */ 761 762 type X__darwin_intptr_t = int64 /* _types.h:49:33 */ 763 type X__darwin_natural_t = uint32 /* _types.h:50:33 */ 764 765 // The rune type below is declared to be an ``int'' instead of the more natural 766 // ``unsigned long'' or ``long''. Two things are happening here. It is not 767 // unsigned so that EOF (-1) can be naturally assigned to it and used. Also, 768 // it looks like 10646 will be a 31 bit standard. This means that if your 769 // ints cannot hold 32 bits, you will be in trouble. The reason an int was 770 // chosen over a long is that the is*() and to*() routines take ints (says 771 // ANSI C), but they use __darwin_ct_rune_t instead of int. By changing it 772 // here, you lose a bit of ANSI conformance, but your programs will still 773 // work. 774 // 775 // NOTE: rune_t is not covered by ANSI nor other standards, and should not 776 // be instantiated outside of lib/libc/locale. Use wchar_t. wchar_t and 777 // rune_t must be the same type. Also wint_t must be no narrower than 778 // wchar_t, and should also be able to hold all members of the largest 779 // character set plus one extra value (WEOF). wint_t must be at least 16 bits. 780 781 type X__darwin_ct_rune_t = int32 /* _types.h:70:33 */ // ct_rune_t 782 783 // mbstate_t is an opaque object to keep conversion state, during multibyte 784 // stream conversions. The content must not be referenced by user programs. 785 type X__mbstate_t = struct { 786 F__ccgo_pad1 [0]uint64 787 F__mbstate8 [128]int8 788 } /* _types.h:79:3 */ 789 790 type X__darwin_mbstate_t = X__mbstate_t /* _types.h:81:33 */ // mbstate_t 791 792 type X__darwin_ptrdiff_t = int64 /* _types.h:84:33 */ // ptr1 - ptr2 793 794 type X__darwin_size_t = uint64 /* _types.h:92:33 */ // sizeof() 795 796 type X__darwin_va_list = X__builtin_va_list /* _types.h:98:33 */ // va_list 797 798 type X__darwin_wchar_t = int32 /* _types.h:104:33 */ // wchar_t 799 800 type X__darwin_rune_t = X__darwin_wchar_t /* _types.h:109:33 */ // rune_t 801 802 type X__darwin_wint_t = int32 /* _types.h:112:33 */ // wint_t 803 804 type X__darwin_clock_t = uint64 /* _types.h:117:33 */ // clock() 805 type X__darwin_socklen_t = X__uint32_t /* _types.h:118:33 */ // socklen_t (duh) 806 type X__darwin_ssize_t = int64 /* _types.h:119:33 */ // byte count or error 807 type X__darwin_time_t = int64 /* _types.h:120:33 */ // time() 808 809 // Type definitions; takes common type definitions that must be used 810 // in multiple header files due to [XSI], removes them from the system 811 // space, and puts them in the implementation space. 812 813 type X__darwin_blkcnt_t = X__int64_t /* _types.h:55:25 */ // total blocks 814 type X__darwin_blksize_t = X__int32_t /* _types.h:56:25 */ // preferred block size 815 type X__darwin_dev_t = X__int32_t /* _types.h:57:25 */ // dev_t 816 type X__darwin_fsblkcnt_t = uint32 /* _types.h:58:25 */ // Used by statvfs and fstatvfs 817 type X__darwin_fsfilcnt_t = uint32 /* _types.h:59:25 */ // Used by statvfs and fstatvfs 818 type X__darwin_gid_t = X__uint32_t /* _types.h:60:25 */ // [???] process and group IDs 819 type X__darwin_id_t = X__uint32_t /* _types.h:61:25 */ // [XSI] pid_t, uid_t, or gid_t 820 type X__darwin_ino64_t = X__uint64_t /* _types.h:62:25 */ // [???] Used for 64 bit inodes 821 type X__darwin_ino_t = X__darwin_ino64_t /* _types.h:64:26 */ // [???] Used for inodes 822 type X__darwin_mach_port_name_t = X__darwin_natural_t /* _types.h:68:28 */ // Used by mach 823 type X__darwin_mach_port_t = X__darwin_mach_port_name_t /* _types.h:69:35 */ // Used by mach 824 type X__darwin_mode_t = X__uint16_t /* _types.h:70:25 */ // [???] Some file attributes 825 type X__darwin_off_t = X__int64_t /* _types.h:71:25 */ // [???] Used for file sizes 826 type X__darwin_pid_t = X__int32_t /* _types.h:72:25 */ // [???] process and group IDs 827 type X__darwin_sigset_t = X__uint32_t /* _types.h:73:25 */ // [???] signal set 828 type X__darwin_suseconds_t = X__int32_t /* _types.h:74:25 */ // [???] microseconds 829 type X__darwin_uid_t = X__uint32_t /* _types.h:75:25 */ // [???] user IDs 830 type X__darwin_useconds_t = X__uint32_t /* _types.h:76:25 */ // [???] microseconds 831 type X__darwin_uuid_t = [16]uint8 /* _types.h:77:25 */ 832 type X__darwin_uuid_string_t = [37]int8 /* _types.h:78:17 */ 833 834 // Copyright (c) 2003-2013 Apple Inc. All rights reserved. 835 // 836 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 837 // 838 // This file contains Original Code and/or Modifications of Original Code 839 // as defined in and that are subject to the Apple Public Source License 840 // Version 2.0 (the 'License'). You may not use this file except in 841 // compliance with the License. The rights granted to you under the License 842 // may not be used to create, or enable the creation or redistribution of, 843 // unlawful or unlicensed copies of an Apple operating system, or to 844 // circumvent, violate, or enable the circumvention or violation of, any 845 // terms of an Apple operating system software license agreement. 846 // 847 // Please obtain a copy of the License at 848 // http://www.opensource.apple.com/apsl/ and read it before using this file. 849 // 850 // The Original Code and all software distributed under the License are 851 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 852 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 853 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 854 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 855 // Please see the License for the specific language governing rights and 856 // limitations under the License. 857 // 858 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 859 860 // Copyright (c) 2000-2018 Apple Inc. All rights reserved. 861 // 862 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 863 // 864 // This file contains Original Code and/or Modifications of Original Code 865 // as defined in and that are subject to the Apple Public Source License 866 // Version 2.0 (the 'License'). You may not use this file except in 867 // compliance with the License. The rights granted to you under the License 868 // may not be used to create, or enable the creation or redistribution of, 869 // unlawful or unlicensed copies of an Apple operating system, or to 870 // circumvent, violate, or enable the circumvention or violation of, any 871 // terms of an Apple operating system software license agreement. 872 // 873 // Please obtain a copy of the License at 874 // http://www.opensource.apple.com/apsl/ and read it before using this file. 875 // 876 // The Original Code and all software distributed under the License are 877 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 878 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 879 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 880 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 881 // Please see the License for the specific language governing rights and 882 // limitations under the License. 883 // 884 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 885 // Copyright 1995 NeXT Computer, Inc. All rights reserved. 886 // Copyright (c) 1991, 1993 887 // The Regents of the University of California. All rights reserved. 888 // 889 // This code is derived from software contributed to Berkeley by 890 // Berkeley Software Design, Inc. 891 // 892 // Redistribution and use in source and binary forms, with or without 893 // modification, are permitted provided that the following conditions 894 // are met: 895 // 1. Redistributions of source code must retain the above copyright 896 // notice, this list of conditions and the following disclaimer. 897 // 2. Redistributions in binary form must reproduce the above copyright 898 // notice, this list of conditions and the following disclaimer in the 899 // documentation and/or other materials provided with the distribution. 900 // 3. All advertising materials mentioning features or use of this software 901 // must display the following acknowledgement: 902 // This product includes software developed by the University of 903 // California, Berkeley and its contributors. 904 // 4. Neither the name of the University nor the names of its contributors 905 // may be used to endorse or promote products derived from this software 906 // without specific prior written permission. 907 // 908 // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 909 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 910 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 911 // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 912 // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 913 // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 914 // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 915 // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 916 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 917 // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 918 // SUCH DAMAGE. 919 // 920 // @(#)cdefs.h 8.8 (Berkeley) 1/9/95 921 922 // pthread opaque structures 923 924 type X__darwin_pthread_handler_rec = struct { 925 F__routine uintptr 926 F__arg uintptr 927 F__next uintptr 928 } /* _pthread_types.h:57:1 */ 929 930 type X_opaque_pthread_attr_t = struct { 931 F__sig int64 932 F__opaque [56]int8 933 } /* _pthread_types.h:63:1 */ 934 935 type X_opaque_pthread_cond_t = struct { 936 F__sig int64 937 F__opaque [40]int8 938 } /* _pthread_types.h:68:1 */ 939 940 type X_opaque_pthread_condattr_t = struct { 941 F__sig int64 942 F__opaque [8]int8 943 } /* _pthread_types.h:73:1 */ 944 945 type X_opaque_pthread_mutex_t = struct { 946 F__sig int64 947 F__opaque [56]int8 948 } /* _pthread_types.h:78:1 */ 949 950 type X_opaque_pthread_mutexattr_t = struct { 951 F__sig int64 952 F__opaque [8]int8 953 } /* _pthread_types.h:83:1 */ 954 955 type X_opaque_pthread_once_t = struct { 956 F__sig int64 957 F__opaque [8]int8 958 } /* _pthread_types.h:88:1 */ 959 960 type X_opaque_pthread_rwlock_t = struct { 961 F__sig int64 962 F__opaque [192]int8 963 } /* _pthread_types.h:93:1 */ 964 965 type X_opaque_pthread_rwlockattr_t = struct { 966 F__sig int64 967 F__opaque [16]int8 968 } /* _pthread_types.h:98:1 */ 969 970 type X_opaque_pthread_t = struct { 971 F__sig int64 972 F__cleanup_stack uintptr 973 F__opaque [8176]int8 974 } /* _pthread_types.h:103:1 */ 975 976 type X__darwin_pthread_attr_t = X_opaque_pthread_attr_t /* _pthread_types.h:109:39 */ 977 type X__darwin_pthread_cond_t = X_opaque_pthread_cond_t /* _pthread_types.h:110:39 */ 978 type X__darwin_pthread_condattr_t = X_opaque_pthread_condattr_t /* _pthread_types.h:111:43 */ 979 type X__darwin_pthread_key_t = uint64 /* _pthread_types.h:112:23 */ 980 type X__darwin_pthread_mutex_t = X_opaque_pthread_mutex_t /* _pthread_types.h:113:40 */ 981 type X__darwin_pthread_mutexattr_t = X_opaque_pthread_mutexattr_t /* _pthread_types.h:114:44 */ 982 type X__darwin_pthread_once_t = X_opaque_pthread_once_t /* _pthread_types.h:115:39 */ 983 type X__darwin_pthread_rwlock_t = X_opaque_pthread_rwlock_t /* _pthread_types.h:116:41 */ 984 type X__darwin_pthread_rwlockattr_t = X_opaque_pthread_rwlockattr_t /* _pthread_types.h:117:45 */ 985 type X__darwin_pthread_t = uintptr /* _pthread_types.h:118:34 */ 986 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 987 // 988 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 989 // 990 // This file contains Original Code and/or Modifications of Original Code 991 // as defined in and that are subject to the Apple Public Source License 992 // Version 2.0 (the 'License'). You may not use this file except in 993 // compliance with the License. The rights granted to you under the License 994 // may not be used to create, or enable the creation or redistribution of, 995 // unlawful or unlicensed copies of an Apple operating system, or to 996 // circumvent, violate, or enable the circumvention or violation of, any 997 // terms of an Apple operating system software license agreement. 998 // 999 // Please obtain a copy of the License at 1000 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1001 // 1002 // The Original Code and all software distributed under the License are 1003 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1004 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1005 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1006 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1007 // Please see the License for the specific language governing rights and 1008 // limitations under the License. 1009 // 1010 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1011 // Copyright (c) 2003-2007 Apple Inc. All rights reserved. 1012 // 1013 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1014 // 1015 // This file contains Original Code and/or Modifications of Original Code 1016 // as defined in and that are subject to the Apple Public Source License 1017 // Version 2.0 (the 'License'). You may not use this file except in 1018 // compliance with the License. The rights granted to you under the License 1019 // may not be used to create, or enable the creation or redistribution of, 1020 // unlawful or unlicensed copies of an Apple operating system, or to 1021 // circumvent, violate, or enable the circumvention or violation of, any 1022 // terms of an Apple operating system software license agreement. 1023 // 1024 // Please obtain a copy of the License at 1025 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1026 // 1027 // The Original Code and all software distributed under the License are 1028 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1029 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1030 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1031 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1032 // Please see the License for the specific language governing rights and 1033 // limitations under the License. 1034 // 1035 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1036 1037 type Mode_t = X__darwin_mode_t /* _mode_t.h:31:33 */ 1038 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 1039 // 1040 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1041 // 1042 // This file contains Original Code and/or Modifications of Original Code 1043 // as defined in and that are subject to the Apple Public Source License 1044 // Version 2.0 (the 'License'). You may not use this file except in 1045 // compliance with the License. The rights granted to you under the License 1046 // may not be used to create, or enable the creation or redistribution of, 1047 // unlawful or unlicensed copies of an Apple operating system, or to 1048 // circumvent, violate, or enable the circumvention or violation of, any 1049 // terms of an Apple operating system software license agreement. 1050 // 1051 // Please obtain a copy of the License at 1052 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1053 // 1054 // The Original Code and all software distributed under the License are 1055 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1056 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1057 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1058 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1059 // Please see the License for the specific language governing rights and 1060 // limitations under the License. 1061 // 1062 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1063 // Copyright (c) 2003-2007 Apple Inc. All rights reserved. 1064 // 1065 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1066 // 1067 // This file contains Original Code and/or Modifications of Original Code 1068 // as defined in and that are subject to the Apple Public Source License 1069 // Version 2.0 (the 'License'). You may not use this file except in 1070 // compliance with the License. The rights granted to you under the License 1071 // may not be used to create, or enable the creation or redistribution of, 1072 // unlawful or unlicensed copies of an Apple operating system, or to 1073 // circumvent, violate, or enable the circumvention or violation of, any 1074 // terms of an Apple operating system software license agreement. 1075 // 1076 // Please obtain a copy of the License at 1077 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1078 // 1079 // The Original Code and all software distributed under the License are 1080 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1081 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1082 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1083 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1084 // Please see the License for the specific language governing rights and 1085 // limitations under the License. 1086 // 1087 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1088 1089 type Off_t = X__darwin_off_t /* _off_t.h:31:33 */ 1090 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 1091 // 1092 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1093 // 1094 // This file contains Original Code and/or Modifications of Original Code 1095 // as defined in and that are subject to the Apple Public Source License 1096 // Version 2.0 (the 'License'). You may not use this file except in 1097 // compliance with the License. The rights granted to you under the License 1098 // may not be used to create, or enable the creation or redistribution of, 1099 // unlawful or unlicensed copies of an Apple operating system, or to 1100 // circumvent, violate, or enable the circumvention or violation of, any 1101 // terms of an Apple operating system software license agreement. 1102 // 1103 // Please obtain a copy of the License at 1104 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1105 // 1106 // The Original Code and all software distributed under the License are 1107 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1108 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1109 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1110 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1111 // Please see the License for the specific language governing rights and 1112 // limitations under the License. 1113 // 1114 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1115 // Copyright (c) 2003-2007 Apple Inc. All rights reserved. 1116 // 1117 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1118 // 1119 // This file contains Original Code and/or Modifications of Original Code 1120 // as defined in and that are subject to the Apple Public Source License 1121 // Version 2.0 (the 'License'). You may not use this file except in 1122 // compliance with the License. The rights granted to you under the License 1123 // may not be used to create, or enable the creation or redistribution of, 1124 // unlawful or unlicensed copies of an Apple operating system, or to 1125 // circumvent, violate, or enable the circumvention or violation of, any 1126 // terms of an Apple operating system software license agreement. 1127 // 1128 // Please obtain a copy of the License at 1129 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1130 // 1131 // The Original Code and all software distributed under the License are 1132 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1133 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1134 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1135 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1136 // Please see the License for the specific language governing rights and 1137 // limitations under the License. 1138 // 1139 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1140 1141 type Pid_t = X__darwin_pid_t /* _pid_t.h:31:31 */ 1142 1143 // File status flags: these are used by open(2), fcntl(2). 1144 // They are also used (indirectly) in the kernel file structure f_flags, 1145 // which is a superset of the open/fcntl flags. Open flags and f_flags 1146 // are inter-convertible using OFLAGS(fflags) and FFLAGS(oflags). 1147 // Open/fcntl flags begin with O_; kernel-internal flags begin with F. 1148 // open-only flags 1149 1150 // Kernel encoding of open mode; separate read and write bits that are 1151 // independently testable: 1 greater than the above. 1152 // 1153 // XXX 1154 // FREAD and FWRITE are excluded from the #ifdef KERNEL so that TIOCFLUSH, 1155 // which was documented to use FREAD/FWRITE, continues to work. 1156 1157 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 1158 // 1159 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1160 // 1161 // This file contains Original Code and/or Modifications of Original Code 1162 // as defined in and that are subject to the Apple Public Source License 1163 // Version 2.0 (the 'License'). You may not use this file except in 1164 // compliance with the License. The rights granted to you under the License 1165 // may not be used to create, or enable the creation or redistribution of, 1166 // unlawful or unlicensed copies of an Apple operating system, or to 1167 // circumvent, violate, or enable the circumvention or violation of, any 1168 // terms of an Apple operating system software license agreement. 1169 // 1170 // Please obtain a copy of the License at 1171 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1172 // 1173 // The Original Code and all software distributed under the License are 1174 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1175 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1176 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1177 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1178 // Please see the License for the specific language governing rights and 1179 // limitations under the License. 1180 // 1181 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1182 1183 // Descriptor value for the current working directory 1184 1185 // Flags for the at functions 1186 1187 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 1188 // 1189 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1190 // 1191 // This file contains Original Code and/or Modifications of Original Code 1192 // as defined in and that are subject to the Apple Public Source License 1193 // Version 2.0 (the 'License'). You may not use this file except in 1194 // compliance with the License. The rights granted to you under the License 1195 // may not be used to create, or enable the creation or redistribution of, 1196 // unlawful or unlicensed copies of an Apple operating system, or to 1197 // circumvent, violate, or enable the circumvention or violation of, any 1198 // terms of an Apple operating system software license agreement. 1199 // 1200 // Please obtain a copy of the License at 1201 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1202 // 1203 // The Original Code and all software distributed under the License are 1204 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1205 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1206 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1207 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1208 // Please see the License for the specific language governing rights and 1209 // limitations under the License. 1210 // 1211 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1212 1213 // Data Protection Flags 1214 1215 // The O_* flags used to have only F* names, which were used in the kernel 1216 // and by fcntl. We retain the F* names for the kernel f_flags field 1217 // and for backward compatibility for fcntl. 1218 1219 // Flags used for copyfile(2) 1220 1221 // Constants used for fcntl(2) 1222 1223 // command values 1224 // 46,47 used to be F_READBOOTSTRAP and F_WRITEBOOTSTRAP 1225 1226 // should not be used (i.e. its ok to temporaily create cached pages) 1227 1228 // See F_DUPFD_CLOEXEC below for 67 1229 1230 // may be broken into smaller chunks with throttling in between 1231 1232 // FS-specific fcntl()'s numbers begin at 0x00010000 and go up 1233 1234 // file descriptor flags (F_GETFD, F_SETFD) 1235 1236 // record locking flags (F_GETLK, F_SETLK, F_SETLKW) 1237 1238 // [XSI] The values used for l_whence shall be defined as described 1239 // in <unistd.h> 1240 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 1241 // 1242 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1243 // 1244 // This file contains Original Code and/or Modifications of Original Code 1245 // as defined in and that are subject to the Apple Public Source License 1246 // Version 2.0 (the 'License'). You may not use this file except in 1247 // compliance with the License. The rights granted to you under the License 1248 // may not be used to create, or enable the creation or redistribution of, 1249 // unlawful or unlicensed copies of an Apple operating system, or to 1250 // circumvent, violate, or enable the circumvention or violation of, any 1251 // terms of an Apple operating system software license agreement. 1252 // 1253 // Please obtain a copy of the License at 1254 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1255 // 1256 // The Original Code and all software distributed under the License are 1257 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1258 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1259 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1260 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1261 // Please see the License for the specific language governing rights and 1262 // limitations under the License. 1263 // 1264 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1265 1266 // Copyright (c) 2000-2018 Apple Inc. All rights reserved. 1267 // 1268 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1269 // 1270 // This file contains Original Code and/or Modifications of Original Code 1271 // as defined in and that are subject to the Apple Public Source License 1272 // Version 2.0 (the 'License'). You may not use this file except in 1273 // compliance with the License. The rights granted to you under the License 1274 // may not be used to create, or enable the creation or redistribution of, 1275 // unlawful or unlicensed copies of an Apple operating system, or to 1276 // circumvent, violate, or enable the circumvention or violation of, any 1277 // terms of an Apple operating system software license agreement. 1278 // 1279 // Please obtain a copy of the License at 1280 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1281 // 1282 // The Original Code and all software distributed under the License are 1283 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1284 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1285 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1286 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1287 // Please see the License for the specific language governing rights and 1288 // limitations under the License. 1289 // 1290 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1291 // Copyright 1995 NeXT Computer, Inc. All rights reserved. 1292 // Copyright (c) 1991, 1993 1293 // The Regents of the University of California. All rights reserved. 1294 // 1295 // This code is derived from software contributed to Berkeley by 1296 // Berkeley Software Design, Inc. 1297 // 1298 // Redistribution and use in source and binary forms, with or without 1299 // modification, are permitted provided that the following conditions 1300 // are met: 1301 // 1. Redistributions of source code must retain the above copyright 1302 // notice, this list of conditions and the following disclaimer. 1303 // 2. Redistributions in binary form must reproduce the above copyright 1304 // notice, this list of conditions and the following disclaimer in the 1305 // documentation and/or other materials provided with the distribution. 1306 // 3. All advertising materials mentioning features or use of this software 1307 // must display the following acknowledgement: 1308 // This product includes software developed by the University of 1309 // California, Berkeley and its contributors. 1310 // 4. Neither the name of the University nor the names of its contributors 1311 // may be used to endorse or promote products derived from this software 1312 // without specific prior written permission. 1313 // 1314 // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 1315 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 1316 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 1317 // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 1318 // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 1319 // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 1320 // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 1321 // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 1322 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 1323 // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 1324 // SUCH DAMAGE. 1325 // 1326 // @(#)cdefs.h 8.8 (Berkeley) 1/9/95 1327 1328 // whence values for lseek(2) 1329 1330 // [XSI] The symbolic names for file modes for use as values of mode_t 1331 // shall be defined as described in <sys/stat.h> 1332 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 1333 // 1334 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1335 // 1336 // This file contains Original Code and/or Modifications of Original Code 1337 // as defined in and that are subject to the Apple Public Source License 1338 // Version 2.0 (the 'License'). You may not use this file except in 1339 // compliance with the License. The rights granted to you under the License 1340 // may not be used to create, or enable the creation or redistribution of, 1341 // unlawful or unlicensed copies of an Apple operating system, or to 1342 // circumvent, violate, or enable the circumvention or violation of, any 1343 // terms of an Apple operating system software license agreement. 1344 // 1345 // Please obtain a copy of the License at 1346 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1347 // 1348 // The Original Code and all software distributed under the License are 1349 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1350 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1351 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1352 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1353 // Please see the License for the specific language governing rights and 1354 // limitations under the License. 1355 // 1356 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1357 1358 // [XSI] The symbolic names for file modes for use as values of mode_t 1359 // shall be defined as described in <sys/stat.h> 1360 // File type 1361 1362 // File mode 1363 // Read, write, execute/search by owner 1364 // Read, write, execute/search by group 1365 // Read, write, execute/search by others 1366 1367 // allocate flags (F_PREALLOCATE) 1368 1369 // Position Modes (fst_posmode) for F_PREALLOCATE 1370 1371 // we can keep them in sync should we desire 1372 1373 // Advisory file segment locking data type - 1374 // information passed to system by user 1375 type Flock = struct { 1376 Fl_start Off_t 1377 Fl_len Off_t 1378 Fl_pid Pid_t 1379 Fl_type int16 1380 Fl_whence int16 1381 } /* fcntl.h:343:1 */ 1382 1383 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 1384 // 1385 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1386 // 1387 // This file contains Original Code and/or Modifications of Original Code 1388 // as defined in and that are subject to the Apple Public Source License 1389 // Version 2.0 (the 'License'). You may not use this file except in 1390 // compliance with the License. The rights granted to you under the License 1391 // may not be used to create, or enable the creation or redistribution of, 1392 // unlawful or unlicensed copies of an Apple operating system, or to 1393 // circumvent, violate, or enable the circumvention or violation of, any 1394 // terms of an Apple operating system software license agreement. 1395 // 1396 // Please obtain a copy of the License at 1397 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1398 // 1399 // The Original Code and all software distributed under the License are 1400 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1401 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1402 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1403 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1404 // Please see the License for the specific language governing rights and 1405 // limitations under the License. 1406 // 1407 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1408 1409 // Copyright (c) 2000-2007 Apple Inc. All rights reserved. 1410 // 1411 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1412 // 1413 // This file contains Original Code and/or Modifications of Original Code 1414 // as defined in and that are subject to the Apple Public Source License 1415 // Version 2.0 (the 'License'). You may not use this file except in 1416 // compliance with the License. The rights granted to you under the License 1417 // may not be used to create, or enable the creation or redistribution of, 1418 // unlawful or unlicensed copies of an Apple operating system, or to 1419 // circumvent, violate, or enable the circumvention or violation of, any 1420 // terms of an Apple operating system software license agreement. 1421 // 1422 // Please obtain a copy of the License at 1423 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1424 // 1425 // The Original Code and all software distributed under the License are 1426 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1427 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1428 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1429 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1430 // Please see the License for the specific language governing rights and 1431 // limitations under the License. 1432 // 1433 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1434 // Copyright 1995 NeXT Computer, Inc. All rights reserved. 1435 1436 // Copyright (c) 2000-2008 Apple Inc. All rights reserved. 1437 // 1438 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1439 // 1440 // This file contains Original Code and/or Modifications of Original Code 1441 // as defined in and that are subject to the Apple Public Source License 1442 // Version 2.0 (the 'License'). You may not use this file except in 1443 // compliance with the License. The rights granted to you under the License 1444 // may not be used to create, or enable the creation or redistribution of, 1445 // unlawful or unlicensed copies of an Apple operating system, or to 1446 // circumvent, violate, or enable the circumvention or violation of, any 1447 // terms of an Apple operating system software license agreement. 1448 // 1449 // Please obtain a copy of the License at 1450 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1451 // 1452 // The Original Code and all software distributed under the License are 1453 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1454 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1455 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1456 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1457 // Please see the License for the specific language governing rights and 1458 // limitations under the License. 1459 // 1460 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1461 // Copyright 1995 NeXT Computer, Inc. All rights reserved. 1462 // Copyright (c) 1990, 1993 1463 // The Regents of the University of California. All rights reserved. 1464 // 1465 // Redistribution and use in source and binary forms, with or without 1466 // modification, are permitted provided that the following conditions 1467 // are met: 1468 // 1. Redistributions of source code must retain the above copyright 1469 // notice, this list of conditions and the following disclaimer. 1470 // 2. Redistributions in binary form must reproduce the above copyright 1471 // notice, this list of conditions and the following disclaimer in the 1472 // documentation and/or other materials provided with the distribution. 1473 // 3. All advertising materials mentioning features or use of this software 1474 // must display the following acknowledgement: 1475 // This product includes software developed by the University of 1476 // California, Berkeley and its contributors. 1477 // 4. Neither the name of the University nor the names of its contributors 1478 // may be used to endorse or promote products derived from this software 1479 // without specific prior written permission. 1480 // 1481 // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 1482 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 1483 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 1484 // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 1485 // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 1486 // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 1487 // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 1488 // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 1489 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 1490 // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 1491 // SUCH DAMAGE. 1492 // 1493 // @(#)types.h 8.3 (Berkeley) 1/5/94 1494 1495 // Copyright (c) 2000-2003 Apple Computer, Inc. All rights reserved. 1496 // 1497 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1498 // 1499 // This file contains Original Code and/or Modifications of Original Code 1500 // as defined in and that are subject to the Apple Public Source License 1501 // Version 2.0 (the 'License'). You may not use this file except in 1502 // compliance with the License. The rights granted to you under the License 1503 // may not be used to create, or enable the creation or redistribution of, 1504 // unlawful or unlicensed copies of an Apple operating system, or to 1505 // circumvent, violate, or enable the circumvention or violation of, any 1506 // terms of an Apple operating system software license agreement. 1507 // 1508 // Please obtain a copy of the License at 1509 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1510 // 1511 // The Original Code and all software distributed under the License are 1512 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1513 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1514 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1515 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1516 // Please see the License for the specific language governing rights and 1517 // limitations under the License. 1518 // 1519 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1520 // Copyright (c) 2000-2018 Apple Inc. All rights reserved. 1521 // 1522 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1523 // 1524 // This file contains Original Code and/or Modifications of Original Code 1525 // as defined in and that are subject to the Apple Public Source License 1526 // Version 2.0 (the 'License'). You may not use this file except in 1527 // compliance with the License. The rights granted to you under the License 1528 // may not be used to create, or enable the creation or redistribution of, 1529 // unlawful or unlicensed copies of an Apple operating system, or to 1530 // circumvent, violate, or enable the circumvention or violation of, any 1531 // terms of an Apple operating system software license agreement. 1532 // 1533 // Please obtain a copy of the License at 1534 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1535 // 1536 // The Original Code and all software distributed under the License are 1537 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1538 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1539 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1540 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1541 // Please see the License for the specific language governing rights and 1542 // limitations under the License. 1543 // 1544 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1545 // Copyright 1995 NeXT Computer, Inc. All rights reserved. 1546 // Copyright (c) 1991, 1993 1547 // The Regents of the University of California. All rights reserved. 1548 // 1549 // This code is derived from software contributed to Berkeley by 1550 // Berkeley Software Design, Inc. 1551 // 1552 // Redistribution and use in source and binary forms, with or without 1553 // modification, are permitted provided that the following conditions 1554 // are met: 1555 // 1. Redistributions of source code must retain the above copyright 1556 // notice, this list of conditions and the following disclaimer. 1557 // 2. Redistributions in binary form must reproduce the above copyright 1558 // notice, this list of conditions and the following disclaimer in the 1559 // documentation and/or other materials provided with the distribution. 1560 // 3. All advertising materials mentioning features or use of this software 1561 // must display the following acknowledgement: 1562 // This product includes software developed by the University of 1563 // California, Berkeley and its contributors. 1564 // 4. Neither the name of the University nor the names of its contributors 1565 // may be used to endorse or promote products derived from this software 1566 // without specific prior written permission. 1567 // 1568 // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 1569 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 1570 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 1571 // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 1572 // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 1573 // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 1574 // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 1575 // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 1576 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 1577 // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 1578 // SUCH DAMAGE. 1579 // 1580 // @(#)cdefs.h 8.8 (Berkeley) 1/9/95 1581 1582 // Basic integral types. Omit the typedef if 1583 // not possible for a machine/compiler combination. 1584 // Copyright (c) 2012 Apple Inc. All rights reserved. 1585 // 1586 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1587 // 1588 // This file contains Original Code and/or Modifications of Original Code 1589 // as defined in and that are subject to the Apple Public Source License 1590 // Version 2.0 (the 'License'). You may not use this file except in 1591 // compliance with the License. The rights granted to you under the License 1592 // may not be used to create, or enable the creation or redistribution of, 1593 // unlawful or unlicensed copies of an Apple operating system, or to 1594 // circumvent, violate, or enable the circumvention or violation of, any 1595 // terms of an Apple operating system software license agreement. 1596 // 1597 // Please obtain a copy of the License at 1598 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1599 // 1600 // The Original Code and all software distributed under the License are 1601 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1602 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1603 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1604 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1605 // Please see the License for the specific language governing rights and 1606 // limitations under the License. 1607 // 1608 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1609 type Int8_t = int8 /* _int8_t.h:30:33 */ 1610 // Copyright (c) 2012 Apple Inc. All rights reserved. 1611 // 1612 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1613 // 1614 // This file contains Original Code and/or Modifications of Original Code 1615 // as defined in and that are subject to the Apple Public Source License 1616 // Version 2.0 (the 'License'). You may not use this file except in 1617 // compliance with the License. The rights granted to you under the License 1618 // may not be used to create, or enable the creation or redistribution of, 1619 // unlawful or unlicensed copies of an Apple operating system, or to 1620 // circumvent, violate, or enable the circumvention or violation of, any 1621 // terms of an Apple operating system software license agreement. 1622 // 1623 // Please obtain a copy of the License at 1624 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1625 // 1626 // The Original Code and all software distributed under the License are 1627 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1628 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1629 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1630 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1631 // Please see the License for the specific language governing rights and 1632 // limitations under the License. 1633 // 1634 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1635 type Int16_t = int16 /* _int16_t.h:30:33 */ 1636 // Copyright (c) 2012 Apple Inc. All rights reserved. 1637 // 1638 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1639 // 1640 // This file contains Original Code and/or Modifications of Original Code 1641 // as defined in and that are subject to the Apple Public Source License 1642 // Version 2.0 (the 'License'). You may not use this file except in 1643 // compliance with the License. The rights granted to you under the License 1644 // may not be used to create, or enable the creation or redistribution of, 1645 // unlawful or unlicensed copies of an Apple operating system, or to 1646 // circumvent, violate, or enable the circumvention or violation of, any 1647 // terms of an Apple operating system software license agreement. 1648 // 1649 // Please obtain a copy of the License at 1650 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1651 // 1652 // The Original Code and all software distributed under the License are 1653 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1654 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1655 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1656 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1657 // Please see the License for the specific language governing rights and 1658 // limitations under the License. 1659 // 1660 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1661 type Int32_t = int32 /* _int32_t.h:30:33 */ 1662 // Copyright (c) 2012 Apple Inc. All rights reserved. 1663 // 1664 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1665 // 1666 // This file contains Original Code and/or Modifications of Original Code 1667 // as defined in and that are subject to the Apple Public Source License 1668 // Version 2.0 (the 'License'). You may not use this file except in 1669 // compliance with the License. The rights granted to you under the License 1670 // may not be used to create, or enable the creation or redistribution of, 1671 // unlawful or unlicensed copies of an Apple operating system, or to 1672 // circumvent, violate, or enable the circumvention or violation of, any 1673 // terms of an Apple operating system software license agreement. 1674 // 1675 // Please obtain a copy of the License at 1676 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1677 // 1678 // The Original Code and all software distributed under the License are 1679 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1680 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1681 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1682 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1683 // Please see the License for the specific language governing rights and 1684 // limitations under the License. 1685 // 1686 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1687 type Int64_t = int64 /* _int64_t.h:30:33 */ 1688 1689 // Copyright (c) 2016 Apple Inc. All rights reserved. 1690 // 1691 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1692 // 1693 // This file contains Original Code and/or Modifications of Original Code 1694 // as defined in and that are subject to the Apple Public Source License 1695 // Version 2.0 (the 'License'). You may not use this file except in 1696 // compliance with the License. The rights granted to you under the License 1697 // may not be used to create, or enable the creation or redistribution of, 1698 // unlawful or unlicensed copies of an Apple operating system, or to 1699 // circumvent, violate, or enable the circumvention or violation of, any 1700 // terms of an Apple operating system software license agreement. 1701 // 1702 // Please obtain a copy of the License at 1703 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1704 // 1705 // The Original Code and all software distributed under the License are 1706 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1707 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1708 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1709 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1710 // Please see the License for the specific language governing rights and 1711 // limitations under the License. 1712 // 1713 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1714 type U_int8_t = uint8 /* _u_int8_t.h:30:33 */ 1715 // Copyright (c) 2012 Apple Inc. All rights reserved. 1716 // 1717 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1718 // 1719 // This file contains Original Code and/or Modifications of Original Code 1720 // as defined in and that are subject to the Apple Public Source License 1721 // Version 2.0 (the 'License'). You may not use this file except in 1722 // compliance with the License. The rights granted to you under the License 1723 // may not be used to create, or enable the creation or redistribution of, 1724 // unlawful or unlicensed copies of an Apple operating system, or to 1725 // circumvent, violate, or enable the circumvention or violation of, any 1726 // terms of an Apple operating system software license agreement. 1727 // 1728 // Please obtain a copy of the License at 1729 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1730 // 1731 // The Original Code and all software distributed under the License are 1732 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1733 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1734 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1735 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1736 // Please see the License for the specific language governing rights and 1737 // limitations under the License. 1738 // 1739 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1740 type U_int16_t = uint16 /* _u_int16_t.h:30:41 */ 1741 // Copyright (c) 2012 Apple Inc. All rights reserved. 1742 // 1743 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1744 // 1745 // This file contains Original Code and/or Modifications of Original Code 1746 // as defined in and that are subject to the Apple Public Source License 1747 // Version 2.0 (the 'License'). You may not use this file except in 1748 // compliance with the License. The rights granted to you under the License 1749 // may not be used to create, or enable the creation or redistribution of, 1750 // unlawful or unlicensed copies of an Apple operating system, or to 1751 // circumvent, violate, or enable the circumvention or violation of, any 1752 // terms of an Apple operating system software license agreement. 1753 // 1754 // Please obtain a copy of the License at 1755 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1756 // 1757 // The Original Code and all software distributed under the License are 1758 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1759 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1760 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1761 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1762 // Please see the License for the specific language governing rights and 1763 // limitations under the License. 1764 // 1765 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1766 type U_int32_t = uint32 /* _u_int32_t.h:30:33 */ 1767 // Copyright (c) 2012 Apple Inc. All rights reserved. 1768 // 1769 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1770 // 1771 // This file contains Original Code and/or Modifications of Original Code 1772 // as defined in and that are subject to the Apple Public Source License 1773 // Version 2.0 (the 'License'). You may not use this file except in 1774 // compliance with the License. The rights granted to you under the License 1775 // may not be used to create, or enable the creation or redistribution of, 1776 // unlawful or unlicensed copies of an Apple operating system, or to 1777 // circumvent, violate, or enable the circumvention or violation of, any 1778 // terms of an Apple operating system software license agreement. 1779 // 1780 // Please obtain a copy of the License at 1781 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1782 // 1783 // The Original Code and all software distributed under the License are 1784 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1785 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1786 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1787 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1788 // Please see the License for the specific language governing rights and 1789 // limitations under the License. 1790 // 1791 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1792 type U_int64_t = uint64 /* _u_int64_t.h:30:33 */ 1793 1794 type Register_t = Int64_t /* types.h:87:33 */ 1795 1796 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 1797 // 1798 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1799 // 1800 // This file contains Original Code and/or Modifications of Original Code 1801 // as defined in and that are subject to the Apple Public Source License 1802 // Version 2.0 (the 'License'). You may not use this file except in 1803 // compliance with the License. The rights granted to you under the License 1804 // may not be used to create, or enable the creation or redistribution of, 1805 // unlawful or unlicensed copies of an Apple operating system, or to 1806 // circumvent, violate, or enable the circumvention or violation of, any 1807 // terms of an Apple operating system software license agreement. 1808 // 1809 // Please obtain a copy of the License at 1810 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1811 // 1812 // The Original Code and all software distributed under the License are 1813 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1814 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1815 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1816 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1817 // Please see the License for the specific language governing rights and 1818 // limitations under the License. 1819 // 1820 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1821 // Copyright (c) 2000-2007 Apple Inc. All rights reserved. 1822 // 1823 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1824 // 1825 // This file contains Original Code and/or Modifications of Original Code 1826 // as defined in and that are subject to the Apple Public Source License 1827 // Version 2.0 (the 'License'). You may not use this file except in 1828 // compliance with the License. The rights granted to you under the License 1829 // may not be used to create, or enable the creation or redistribution of, 1830 // unlawful or unlicensed copies of an Apple operating system, or to 1831 // circumvent, violate, or enable the circumvention or violation of, any 1832 // terms of an Apple operating system software license agreement. 1833 // 1834 // Please obtain a copy of the License at 1835 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1836 // 1837 // The Original Code and all software distributed under the License are 1838 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1839 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1840 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1841 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1842 // Please see the License for the specific language governing rights and 1843 // limitations under the License. 1844 // 1845 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1846 // Copyright 1995 NeXT Computer, Inc. All rights reserved. 1847 1848 type Intptr_t = X__darwin_intptr_t /* _intptr_t.h:32:33 */ 1849 // Copyright (c) 2003-2012 Apple Inc. All rights reserved. 1850 // 1851 // @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 1852 // 1853 // This file contains Original Code and/or Modifications of Original Code 1854 // as defined in and that are subject to the Apple Public Source License 1855 // Version 2.0 (the 'License'). You may not use this file except in 1856 // compliance with the License. The rights granted to you under the License 1857 // may not be used to create, or enable the creation or redistribution of, 1858 // unlawful or unlicensed copies of an Apple operating system, or to 1859 // circumvent, violate, or enable the circumvention or violation of, any 1860 // terms of an Apple operating system software license agreement. 1861 // 1862 // Please obtain a copy of the License at 1863 // http://www.opensource.apple.com/apsl/ and read it before using this file. 1864 // 1865 // The Original Code and all software distributed under the License are 1866 // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 1867 // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 1868 // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 1869 // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 1870 // Please see the License for the specific language governing rights and 1871 // limitations under the License. 1872 // 1873 // @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 1874 type Uintptr_t = uint64 /* _uintptr_t.h:30:33 */ 1875 1876 // These types are used for reserving the largest possible size. 1877 type User_addr_t = U_int64_t /* types.h:97:33 */ 1878 type User_size_t = U_int64_t /* types.h:98:33 */ 1879 type User_ssize_t = Int64_t /* types.h:99:33 */ 1880 type User_long_t = Int64_t /* types.h:100:33 */ 1881 type User_ulong_t = U_int64_t /* types.h:101:33 */ 1882 type User_time_t = Int64_t /* types.h:102:33 */ 1883 type User_off_t = Int64_t /* types.h:103:33 */ 1884 1885 // This defines the size of syscall arguments after copying into the kernel: 1886 type Syscall_arg_t = U_int64_t /* types.h:111:33 */ 1887 1888 type Timespec = struct { 1889 Ftv_sec X__darwin_time_t 1890 Ftv_nsec int64 1891 } /* _timespec.h:33:1 */ 1892 1893 // Advisory file segment locking with time out - 1894 // Information passed to system by user for F_SETLKWTIMEOUT 1895 type Flocktimeout = struct { 1896 Ffl struct { 1897 Fl_start Off_t 1898 Fl_len Off_t 1899 Fl_pid Pid_t 1900 Fl_type int16 1901 Fl_whence int16 1902 } 1903 Ftimeout struct { 1904 Ftv_sec X__darwin_time_t 1905 Ftv_nsec int64 1906 } 1907 } /* fcntl.h:358:1 */ 1908 1909 // advisory file read data type - 1910 // information passed by user to system 1911 1912 type Radvisory = struct { 1913 Fra_offset Off_t 1914 Fra_count int32 1915 F__ccgo_pad1 [4]byte 1916 } /* fcntl.h:371:1 */ 1917 1918 // * Information the user passes in to get the codeblobs out of the kernel 1919 type Fcodeblobs = struct { 1920 Ff_cd_hash uintptr 1921 Ff_hash_size Size_t 1922 Ff_cd_buffer uintptr 1923 Ff_cd_size Size_t 1924 Ff_out_size uintptr 1925 Ff_arch int32 1926 F__padding int32 1927 } /* fcntl.h:378:9 */ 1928 1929 // * Information the user passes in to get the codeblobs out of the kernel 1930 type Fcodeblobs_t = Fcodeblobs /* fcntl.h:386:3 */ 1931 1932 // detached code signatures data type - 1933 // information passed by user to system used by F_ADDSIGS and F_ADDFILESIGS. 1934 // F_ADDFILESIGS is a shortcut for files that contain their own signature and 1935 // doesn't require mapping of the file in order to load the signature. 1936 type Fsignatures = struct { 1937 Ffs_file_start Off_t 1938 Ffs_blob_start uintptr 1939 Ffs_blob_size Size_t 1940 } /* fcntl.h:395:9 */ 1941 1942 // detached code signatures data type - 1943 // information passed by user to system used by F_ADDSIGS and F_ADDFILESIGS. 1944 // F_ADDFILESIGS is a shortcut for files that contain their own signature and 1945 // doesn't require mapping of the file in order to load the signature. 1946 type Fsignatures_t = Fsignatures /* fcntl.h:399:3 */ 1947 1948 // DYLD needs to check if the object is allowed to be combined 1949 // into the main binary. This is done between the code signature 1950 // is loaded and dyld is doing all the work to process the LOAD commands. 1951 // 1952 // While this could be done in F_ADDFILESIGS.* family the hook into 1953 // the MAC module doesn't say no when LV isn't enabled and then that 1954 // is cached on the vnode, and the MAC module never gets change once 1955 // a process that library validation enabled. 1956 type Fchecklv = struct { 1957 Flv_file_start Off_t 1958 Flv_error_message_size Size_t 1959 Flv_error_message uintptr 1960 } /* fcntl.h:411:9 */ 1961 1962 // DYLD needs to check if the object is allowed to be combined 1963 // into the main binary. This is done between the code signature 1964 // is loaded and dyld is doing all the work to process the LOAD commands. 1965 // 1966 // While this could be done in F_ADDFILESIGS.* family the hook into 1967 // the MAC module doesn't say no when LV isn't enabled and then that 1968 // is cached on the vnode, and the MAC module never gets change once 1969 // a process that library validation enabled. 1970 type Fchecklv_t = Fchecklv /* fcntl.h:415:3 */ 1971 1972 // lock operations for flock(2) 1973 1974 // fstore_t type used by F_PREALLOCATE command 1975 1976 type Fstore = struct { 1977 Ffst_flags uint32 1978 Ffst_posmode int32 1979 Ffst_offset Off_t 1980 Ffst_length Off_t 1981 Ffst_bytesalloc Off_t 1982 } /* fcntl.h:427:9 */ 1983 1984 // lock operations for flock(2) 1985 1986 // fstore_t type used by F_PREALLOCATE command 1987 1988 type Fstore_t = Fstore /* fcntl.h:433:3 */ 1989 1990 // fpunchhole_t used by F_PUNCHHOLE 1991 type Fpunchhole = struct { 1992 Ffp_flags uint32 1993 Freserved uint32 1994 Ffp_offset Off_t 1995 Ffp_length Off_t 1996 } /* fcntl.h:436:9 */ 1997 1998 // fpunchhole_t used by F_PUNCHHOLE 1999 type Fpunchhole_t = Fpunchhole /* fcntl.h:441:3 */ 2000 2001 // factive_file_trim_t used by F_TRIM_ACTIVE_FILE 2002 type Ftrimactivefile = struct { 2003 Ffta_offset Off_t 2004 Ffta_length Off_t 2005 } /* fcntl.h:444:9 */ 2006 2007 // factive_file_trim_t used by F_TRIM_ACTIVE_FILE 2008 type Ftrimactivefile_t = Ftrimactivefile /* fcntl.h:447:3 */ 2009 2010 // fspecread_t used by F_SPECULATIVE_READ 2011 type Fspecread = struct { 2012 Ffsr_flags uint32 2013 Freserved uint32 2014 Ffsr_offset Off_t 2015 Ffsr_length Off_t 2016 } /* fcntl.h:450:9 */ 2017 2018 // fspecread_t used by F_SPECULATIVE_READ 2019 type Fspecread_t = Fspecread /* fcntl.h:455:3 */ 2020 2021 // fbootstraptransfer_t used by F_READBOOTSTRAP and F_WRITEBOOTSTRAP commands 2022 2023 type Fbootstraptransfer = struct { 2024 Ffbt_offset Off_t 2025 Ffbt_length Size_t 2026 Ffbt_buffer uintptr 2027 } /* fcntl.h:459:9 */ 2028 2029 // fbootstraptransfer_t used by F_READBOOTSTRAP and F_WRITEBOOTSTRAP commands 2030 2031 type Fbootstraptransfer_t = Fbootstraptransfer /* fcntl.h:463:3 */ 2032 2033 // For F_LOG2PHYS this information is passed back to user 2034 // Currently only devoffset is returned - that is the VOP_BMAP 2035 // result - the disk device address corresponding to the 2036 // current file offset (likely set with an lseek). 2037 // 2038 // The flags could hold an indication of whether the # of 2039 // contiguous bytes reflects the true extent length on disk, 2040 // or is an advisory value that indicates there is at least that 2041 // many bytes contiguous. For some filesystems it might be too 2042 // inefficient to provide anything beyond the advisory value. 2043 // Flags and contiguous bytes return values are not yet implemented. 2044 // For them the fcntl will nedd to switch from using BMAP to CMAP 2045 // and a per filesystem type flag will be needed to interpret the 2046 // contiguous bytes count result from CMAP. 2047 // 2048 // F_LOG2PHYS_EXT is a variant of F_LOG2PHYS that uses a passed in 2049 // file offset and length instead of the current file offset. 2050 // F_LOG2PHYS_EXT operates on the same structure as F_LOG2PHYS, but 2051 // treats it as an in/out. 2052 2053 type Log2phys = struct { 2054 Fl2p_flags uint32 2055 F__ccgo_pad1 [4]byte 2056 Fl2p_contigbytes Off_t 2057 Fl2p_devoffset Off_t 2058 } /* fcntl.h:489:1 */ 2059 2060 type Filesec_t = uintptr /* _filesec_t.h:31:25 */ 2061 2062 type Filesec_property_t = uint32 /* fcntl.h:523:3 */ 2063 2064 var _ int8 /* gen.c:2:13: */