termios_darwin_arm64.go 79 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570
  1. // Code generated by 'ccgo termios/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 termios/termios_darwin_arm64.go -pkgname termios', DO NOT EDIT.
  2. package termios
  3. import (
  4. "math"
  5. "reflect"
  6. "sync/atomic"
  7. "unsafe"
  8. )
  9. var _ = math.Pi
  10. var _ reflect.Kind
  11. var _ atomic.Value
  12. var _ unsafe.Pointer
  13. const (
  14. ALTWERASE = 0x00000200 // termios.h:249:1:
  15. B0 = 0 // termios.h:291:1:
  16. B110 = 110 // termios.h:294:1:
  17. B115200 = 115200 // termios.h:313:1:
  18. B1200 = 1200 // termios.h:300:1:
  19. B134 = 134 // termios.h:295:1:
  20. B14400 = 14400 // termios.h:309:1:
  21. B150 = 150 // termios.h:296:1:
  22. B1800 = 1800 // termios.h:301:1:
  23. B19200 = 19200 // termios.h:305:1:
  24. B200 = 200 // termios.h:297:1:
  25. B230400 = 230400 // termios.h:314:1:
  26. B2400 = 2400 // termios.h:302:1:
  27. B28800 = 28800 // termios.h:310:1:
  28. B300 = 300 // termios.h:298:1:
  29. B38400 = 38400 // termios.h:306:1:
  30. B4800 = 4800 // termios.h:303:1:
  31. B50 = 50 // termios.h:292:1:
  32. B57600 = 57600 // termios.h:311:1:
  33. B600 = 600 // termios.h:299:1:
  34. B7200 = 7200 // termios.h:308:1:
  35. B75 = 75 // termios.h:293:1:
  36. B76800 = 76800 // termios.h:312:1:
  37. B9600 = 9600 // termios.h:304:1:
  38. BRKINT = 0x00000002 // termios.h:120:1:
  39. BS0 = 0x00000000 // termios.h:190:1:
  40. BS1 = 0x00008000 // termios.h:191:1:
  41. BSDLY = 0x00008000 // termios.h:159:1:
  42. CBRK = 255 // ttydefaults.h:107:1:
  43. CCAR_OFLOW = 0x00100000 // termios.h:222:1:
  44. CCTS_OFLOW = 0x00010000 // termios.h:217:1:
  45. CDISCARD = 15 // ttydefaults.h:102:1:
  46. CDSR_OFLOW = 0x00080000 // termios.h:221:1:
  47. CDSUSP = 25 // ttydefaults.h:98:1:
  48. CDTR_IFLOW = 0x00040000 // termios.h:220:1:
  49. CEOF = 4 // ttydefaults.h:88:1:
  50. CEOL = 0xff // ttydefaults.h:89:1:
  51. CEOT = 4 // ttydefaults.h:105:1:
  52. CERASE = 0177 // ttydefaults.h:90:1:
  53. CFLUSH = 15 // ttydefaults.h:109:1:
  54. CIGNORE = 0x00000001 // termios.h:203:1:
  55. CINTR = 3 // ttydefaults.h:91:1:
  56. CKILL = 21 // ttydefaults.h:93:1:
  57. CLNEXT = 22 // ttydefaults.h:101:1:
  58. CLOCAL = 0x00008000 // termios.h:215:1:
  59. CMIN = 1 // ttydefaults.h:94:1:
  60. CQUIT = 034 // ttydefaults.h:95:1:
  61. CR0 = 0x00000000 // termios.h:184:1:
  62. CR1 = 0x00001000 // termios.h:185:1:
  63. CR2 = 0x00002000 // termios.h:186:1:
  64. CR3 = 0x00003000 // termios.h:187:1:
  65. CRDLY = 0x00003000 // termios.h:157:1:
  66. CREAD = 0x00000800 // termios.h:211:1:
  67. CREPRINT = 18 // ttydefaults.h:104:1:
  68. CRPRNT = 18 // ttydefaults.h:108:1:
  69. CRTSCTS = 196608 // termios.h:218:1:
  70. CRTS_IFLOW = 0x00020000 // termios.h:219:1:
  71. CS5 = 0x00000000 // termios.h:206:1:
  72. CS6 = 0x00000100 // termios.h:207:1:
  73. CS7 = 0x00000200 // termios.h:208:1:
  74. CS8 = 0x00000300 // termios.h:209:1:
  75. CSIZE = 0x00000300 // termios.h:205:1:
  76. CSTART = 17 // ttydefaults.h:99:1:
  77. CSTATUS = 20 // ttydefaults.h:92:1:
  78. CSTOP = 19 // ttydefaults.h:100:1:
  79. CSTOPB = 0x00000400 // termios.h:210:1:
  80. CSUSP = 26 // ttydefaults.h:96:1:
  81. CTIME = 0 // ttydefaults.h:97:1:
  82. CWERASE = 23 // ttydefaults.h:103:1:
  83. ECHO = 0x00000008 // termios.h:240:1:
  84. ECHOCTL = 0x00000040 // termios.h:244:1:
  85. ECHOE = 0x00000002 // termios.h:238:1:
  86. ECHOK = 0x00000004 // termios.h:239:1:
  87. ECHOKE = 0x00000001 // termios.h:236:1:
  88. ECHONL = 0x00000010 // termios.h:241:1:
  89. ECHOPRT = 0x00000020 // termios.h:243:1:
  90. EXTA = 19200 // termios.h:315:1:
  91. EXTB = 38400 // termios.h:316:1:
  92. EXTPROC = 0x00000800 // termios.h:253:1:
  93. FF0 = 0x00000000 // termios.h:188:1:
  94. FF1 = 0x00004000 // termios.h:189:1:
  95. FFDLY = 0x00004000 // termios.h:158:1:
  96. FLUSHO = 0x00800000 // termios.h:257:1:
  97. HUPCL = 0x00004000 // termios.h:214:1:
  98. ICANON = 0x00000100 // termios.h:247:1:
  99. ICRNL = 0x00000100 // termios.h:127:1:
  100. IEXTEN = 0x00000400 // termios.h:251:1:
  101. IGNBRK = 0x00000001 // termios.h:119:1:
  102. IGNCR = 0x00000080 // termios.h:126:1:
  103. IGNPAR = 0x00000004 // termios.h:121:1:
  104. IMAXBEL = 0x00002000 // termios.h:132:1:
  105. INLCR = 0x00000040 // termios.h:125:1:
  106. INPCK = 0x00000010 // termios.h:123:1:
  107. IOCPARM_MASK = 0x1fff // ioccom.h:74:1:
  108. IOCPARM_MAX = 8192 // ioccom.h:79:1:
  109. ISIG = 0x00000080 // termios.h:246:1:
  110. ISTRIP = 0x00000020 // termios.h:124:1:
  111. IUTF8 = 0x00004000 // termios.h:133:1:
  112. IXANY = 0x00000800 // termios.h:130:1:
  113. IXOFF = 0x00000400 // termios.h:129:1:
  114. IXON = 0x00000200 // termios.h:128:1:
  115. MDMBUF = 0x00100000 // termios.h:223:1:
  116. NCCS = 20 // termios.h:108:1:
  117. NL0 = 0x00000000 // termios.h:173:1:
  118. NL1 = 0x00000100 // termios.h:174:1:
  119. NL2 = 0x00000200 // termios.h:176:1:
  120. NL3 = 0x00000300 // termios.h:177:1:
  121. NLDLY = 0x00000300 // termios.h:155:1:
  122. NOFLSH = 0x80000000 // termios.h:261:1:
  123. NOKERNINFO = 0x02000000 // termios.h:258:1:
  124. OCRNL = 0x00000010 // termios.h:151:1:
  125. OFDEL = 0x00020000 // termios.h:161:1:
  126. OFILL = 0x00000080 // termios.h:154:1:
  127. ONLCR = 0x00000002 // termios.h:140:1:
  128. ONLRET = 0x00000040 // termios.h:153:1:
  129. ONOCR = 0x00000020 // termios.h:152:1:
  130. ONOEOT = 0x00000008 // termios.h:143:1:
  131. OPOST = 0x00000001 // termios.h:139:1:
  132. OXTABS = 0x00000004 // termios.h:142:1:
  133. PARENB = 0x00001000 // termios.h:212:1:
  134. PARMRK = 0x00000008 // termios.h:122:1:
  135. PARODD = 0x00002000 // termios.h:213:1:
  136. PENDIN = 0x20000000 // termios.h:259:1:
  137. PPPDISC = 5 // ttycom.h:171:1:
  138. SLIPDISC = 4 // ttycom.h:170:1:
  139. TAB0 = 0x00000000 // termios.h:179:1:
  140. TAB1 = 0x00000400 // termios.h:180:1:
  141. TAB2 = 0x00000800 // termios.h:181:1:
  142. TAB3 = 0x00000004 // termios.h:183:1:
  143. TABDLY = 0x00000c04 // termios.h:156:1:
  144. TABLDISC = 3 // ttycom.h:169:1:
  145. TCIFLUSH = 1 // termios.h:320:1:
  146. TCIOFF = 3 // termios.h:325:1:
  147. TCIOFLUSH = 3 // termios.h:322:1:
  148. TCION = 4 // termios.h:326:1:
  149. TCOFLUSH = 2 // termios.h:321:1:
  150. TCOOFF = 1 // termios.h:323:1:
  151. TCOON = 2 // termios.h:324:1:
  152. TCSADRAIN = 1 // termios.h:282:1:
  153. TCSAFLUSH = 2 // termios.h:283:1:
  154. TCSANOW = 0 // termios.h:281:1:
  155. TCSASOFT = 0x10 // termios.h:285:1:
  156. TIOCM_CAR = 0100 // ttycom.h:97:1:
  157. TIOCM_CD = 64 // ttycom.h:98:1:
  158. TIOCM_CTS = 0040 // ttycom.h:96:1:
  159. TIOCM_DSR = 0400 // ttycom.h:101:1:
  160. TIOCM_DTR = 0002 // ttycom.h:92:1:
  161. TIOCM_LE = 0001 // ttycom.h:91:1:
  162. TIOCM_RI = 128 // ttycom.h:100:1:
  163. TIOCM_RNG = 0200 // ttycom.h:99:1:
  164. TIOCM_RTS = 0004 // ttycom.h:93:1:
  165. TIOCM_SR = 0020 // ttycom.h:95:1:
  166. TIOCM_ST = 0010 // ttycom.h:94:1:
  167. TIOCPKT_DATA = 0x00 // ttycom.h:128:1:
  168. TIOCPKT_DOSTOP = 0x20 // ttycom.h:134:1:
  169. TIOCPKT_FLUSHREAD = 0x01 // ttycom.h:129:1:
  170. TIOCPKT_FLUSHWRITE = 0x02 // ttycom.h:130:1:
  171. TIOCPKT_IOCTL = 0x40 // ttycom.h:135:1:
  172. TIOCPKT_NOSTOP = 0x10 // ttycom.h:133:1:
  173. TIOCPKT_START = 0x08 // ttycom.h:132:1:
  174. TIOCPKT_STOP = 0x04 // ttycom.h:131:1:
  175. TOSTOP = 0x00400000 // termios.h:255:1:
  176. TTYDEF_CFLAG = 19200 // ttydefaults.h:81:1:
  177. TTYDEF_IFLAG = 11010 // ttydefaults.h:78:1:
  178. TTYDEF_LFLAG = 1483 // ttydefaults.h:80:1:
  179. TTYDEF_OFLAG = 3 // ttydefaults.h:79:1:
  180. TTYDEF_SPEED = 9600 // ttydefaults.h:82:1:
  181. TTYDISC = 0 // ttycom.h:168:1:
  182. VDISCARD = 15 // termios.h:100:1:
  183. VDSUSP = 11 // termios.h:94:1:
  184. VEOF = 0 // termios.h:76:1:
  185. VEOL = 1 // termios.h:77:1:
  186. VEOL2 = 2 // termios.h:79:1:
  187. VERASE = 3 // termios.h:81:1:
  188. VINTR = 8 // termios.h:90:1:
  189. VKILL = 5 // termios.h:85:1:
  190. VLNEXT = 14 // termios.h:99:1:
  191. VMIN = 16 // termios.h:102:1:
  192. VQUIT = 9 // termios.h:91:1:
  193. VREPRINT = 6 // termios.h:87:1:
  194. VSTART = 12 // termios.h:96:1:
  195. VSTATUS = 18 // termios.h:105:1:
  196. VSTOP = 13 // termios.h:97:1:
  197. VSUSP = 10 // termios.h:92:1:
  198. VT0 = 0x00000000 // termios.h:192:1:
  199. VT1 = 0x00010000 // termios.h:193:1:
  200. VTDLY = 0x00010000 // termios.h:160:1:
  201. VTIME = 17 // termios.h:103:1:
  202. VWERASE = 4 // termios.h:83:1:
  203. X_BSD_ARM__TYPES_H_ = 0 // _types.h:5:1:
  204. X_BSD_MACHINE__TYPES_H_ = 0 // _types.h:29:1:
  205. X_CDEFS_H_ = 0 // cdefs.h:68:1:
  206. X_DARWIN_FEATURE_64_BIT_INODE = 1 // cdefs.h:774:1:
  207. X_DARWIN_FEATURE_ONLY_64_BIT_INODE = 1 // cdefs.h:784:1:
  208. X_DARWIN_FEATURE_ONLY_UNIX_CONFORMANCE = 1 // cdefs.h:800:1:
  209. X_DARWIN_FEATURE_ONLY_VERS_1050 = 1 // cdefs.h:792:1:
  210. X_DARWIN_FEATURE_UNIX_CONFORMANCE = 3 // cdefs.h:808:1:
  211. X_FILE_OFFSET_BITS = 64 // <builtin>:25:1:
  212. X_FORTIFY_SOURCE = 2 // _types.h:65:1:
  213. X_LP64 = 1 // <predefined>:1:1:
  214. X_Nonnull = 0 // cdefs.h:268:1:
  215. X_Null_unspecified = 0 // cdefs.h:271:1:
  216. X_Nullable = 0 // cdefs.h:265:1:
  217. X_PID_T = 0 // _pid_t.h:29:1:
  218. X_SYS_IOCCOM_H_ = 0 // ioccom.h:65:1:
  219. X_SYS_TERMIOS_H_ = 0 // termios.h:65:1:
  220. X_SYS_TTYCOM_H_ = 0 // ttycom.h:70:1:
  221. X_SYS_TTYDEFAULTS_H_ = 0 // ttydefaults.h:73:1:
  222. X_SYS__PTHREAD_TYPES_H_ = 0 // _pthread_types.h:30:1:
  223. X_SYS__TYPES_H_ = 0 // _types.h:30:1:
  224. )
  225. type Ptrdiff_t = int64 /* <builtin>:3:26 */
  226. type Size_t = uint64 /* <builtin>:9:23 */
  227. type Wchar_t = int32 /* <builtin>:15:24 */
  228. type X__int128_t = struct {
  229. Flo int64
  230. Fhi int64
  231. } /* <builtin>:21:43 */ // must match modernc.org/mathutil.Int128
  232. type X__uint128_t = struct {
  233. Flo uint64
  234. Fhi uint64
  235. } /* <builtin>:22:44 */ // must match modernc.org/mathutil.Int128
  236. type X__builtin_va_list = uintptr /* <builtin>:46:14 */
  237. type X__float128 = float64 /* <builtin>:47:21 */
  238. var X__darwin_check_fd_set_overflow uintptr /* <builtin>:146:5: */
  239. // Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
  240. //
  241. // @APPLE_LICENSE_HEADER_START@
  242. //
  243. // This file contains Original Code and/or Modifications of Original Code
  244. // as defined in and that are subject to the Apple Public Source License
  245. // Version 2.0 (the 'License'). You may not use this file except in
  246. // compliance with the License. Please obtain a copy of the License at
  247. // http://www.opensource.apple.com/apsl/ and read it before using this
  248. // file.
  249. //
  250. // The Original Code and all software distributed under the License are
  251. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  252. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  253. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  254. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  255. // Please see the License for the specific language governing rights and
  256. // limitations under the License.
  257. //
  258. // @APPLE_LICENSE_HEADER_END@
  259. // Copyright (c) 2000-2018 Apple Inc. All rights reserved.
  260. //
  261. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  262. //
  263. // This file contains Original Code and/or Modifications of Original Code
  264. // as defined in and that are subject to the Apple Public Source License
  265. // Version 2.0 (the 'License'). You may not use this file except in
  266. // compliance with the License. The rights granted to you under the License
  267. // may not be used to create, or enable the creation or redistribution of,
  268. // unlawful or unlicensed copies of an Apple operating system, or to
  269. // circumvent, violate, or enable the circumvention or violation of, any
  270. // terms of an Apple operating system software license agreement.
  271. //
  272. // Please obtain a copy of the License at
  273. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  274. //
  275. // The Original Code and all software distributed under the License are
  276. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  277. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  278. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  279. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  280. // Please see the License for the specific language governing rights and
  281. // limitations under the License.
  282. //
  283. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  284. // Copyright 1995 NeXT Computer, Inc. All rights reserved.
  285. // Copyright (c) 1991, 1993
  286. // The Regents of the University of California. All rights reserved.
  287. //
  288. // This code is derived from software contributed to Berkeley by
  289. // Berkeley Software Design, Inc.
  290. //
  291. // Redistribution and use in source and binary forms, with or without
  292. // modification, are permitted provided that the following conditions
  293. // are met:
  294. // 1. Redistributions of source code must retain the above copyright
  295. // notice, this list of conditions and the following disclaimer.
  296. // 2. Redistributions in binary form must reproduce the above copyright
  297. // notice, this list of conditions and the following disclaimer in the
  298. // documentation and/or other materials provided with the distribution.
  299. // 3. All advertising materials mentioning features or use of this software
  300. // must display the following acknowledgement:
  301. // This product includes software developed by the University of
  302. // California, Berkeley and its contributors.
  303. // 4. Neither the name of the University nor the names of its contributors
  304. // may be used to endorse or promote products derived from this software
  305. // without specific prior written permission.
  306. //
  307. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  308. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  309. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  310. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  311. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  312. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  313. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  314. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  315. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  316. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  317. // SUCH DAMAGE.
  318. //
  319. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  320. // This SDK is designed to work with clang and specific versions of
  321. // gcc >= 4.0 with Apple's patch sets
  322. // Compatibility with compilers and environments that don't support compiler
  323. // feature checking function-like macros.
  324. // The __CONCAT macro is used to concatenate parts of symbol names, e.g.
  325. // with "#define OLD(foo) __CONCAT(old,foo)", OLD(foo) produces oldfoo.
  326. // The __CONCAT macro is a bit tricky -- make sure you don't put spaces
  327. // in between its arguments. __CONCAT can also concatenate double-quoted
  328. // strings produced by the __STRING macro, but this only works with ANSI C.
  329. // In non-ANSI C environments, new programs will want ANSI-only C keywords
  330. // deleted from the program and old programs will want them left alone.
  331. // When using a compiler other than gcc, programs using the ANSI C keywords
  332. // const, inline etc. as normal identifiers should define -DNO_ANSI_KEYWORDS.
  333. // When using "gcc -traditional", we assume that this is the intent; if
  334. // __GNUC__ is defined but __STDC__ is not, we leave the new keywords alone.
  335. // __pure2 can be used for functions that are only a function of their scalar
  336. // arguments (meaning they can't dereference pointers).
  337. //
  338. // __stateful_pure can be used for functions that have no side effects,
  339. // but depend on the state of the memory.
  340. // __unused denotes variables and functions that may not be used, preventing
  341. // the compiler from warning about it if not used.
  342. // __used forces variables and functions to be included even if it appears
  343. // to the compiler that they are not used (and would thust be discarded).
  344. // __cold marks code used for debugging or that is rarely taken
  345. // and tells the compiler to optimize for size and outline code.
  346. // __exported denotes symbols that should be exported even when symbols
  347. // are hidden by default.
  348. // __exported_push/_exported_pop are pragmas used to delimit a range of
  349. // symbols that should be exported even when symbols are hidden by default.
  350. // __deprecated causes the compiler to produce a warning when encountering
  351. // code using the deprecated functionality.
  352. // __deprecated_msg() does the same, and compilers that support it will print
  353. // a message along with the deprecation warning.
  354. // This may require turning on such warning with the -Wdeprecated flag.
  355. // __deprecated_enum_msg() should be used on enums, and compilers that support
  356. // it will print the deprecation warning.
  357. // __kpi_deprecated() specifically indicates deprecation of kernel programming
  358. // interfaces in Kernel.framework used by KEXTs.
  359. // __unavailable causes the compiler to error out when encountering
  360. // code using the tagged function
  361. // Delete pseudo-keywords wherever they are not available or needed.
  362. // We use `__restrict' as a way to define the `restrict' type qualifier
  363. // without disturbing older software that is unaware of C99 keywords.
  364. // Compatibility with compilers and environments that don't support the
  365. // nullability feature.
  366. // __disable_tail_calls causes the compiler to not perform tail call
  367. // optimization inside the marked function.
  368. // __not_tail_called causes the compiler to prevent tail call optimization
  369. // on statically bound calls to the function. It has no effect on indirect
  370. // calls. Virtual functions, objective-c methods, and functions marked as
  371. // "always_inline" cannot be marked as __not_tail_called.
  372. // __result_use_check warns callers of a function that not using the function
  373. // return value is a bug, i.e. dismissing malloc() return value results in a
  374. // memory leak.
  375. // __swift_unavailable causes the compiler to mark a symbol as specifically
  376. // unavailable in Swift, regardless of any other availability in C.
  377. // __abortlike is the attribute to put on functions like abort() that are
  378. // typically used to mark assertions. These optimize the codegen
  379. // for outlining while still maintaining debugability.
  380. // Declaring inline functions within headers is error-prone due to differences
  381. // across various versions of the C language and extensions. __header_inline
  382. // can be used to declare inline functions within system headers. In cases
  383. // where you want to force inlining instead of letting the compiler make
  384. // the decision, you can use __header_always_inline.
  385. //
  386. // Be aware that using inline for functions which compilers may also provide
  387. // builtins can behave differently under various compilers. If you intend to
  388. // provide an inline version of such a function, you may want to use a macro
  389. // instead.
  390. //
  391. // The check for !__GNUC__ || __clang__ is because gcc doesn't correctly
  392. // support c99 inline in some cases:
  393. // http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55965
  394. // Compiler-dependent macros that bracket portions of code where the
  395. // "-Wunreachable-code" warning should be ignored. Please use sparingly.
  396. // Compiler-dependent macros to declare that functions take printf-like
  397. // or scanf-like arguments. They are null except for versions of gcc
  398. // that are known to support the features properly. Functions declared
  399. // with these attributes will cause compilation warnings if there is a
  400. // mismatch between the format string and subsequent function parameter
  401. // types.
  402. // Source compatibility only, ID string not emitted in object file
  403. // __alloc_size can be used to label function arguments that represent the
  404. // size of memory that the function allocates and returns. The one-argument
  405. // form labels a single argument that gives the allocation size (where the
  406. // arguments are numbered from 1):
  407. //
  408. // void *malloc(size_t __size) __alloc_size(1);
  409. //
  410. // The two-argument form handles the case where the size is calculated as the
  411. // product of two arguments:
  412. //
  413. // void *calloc(size_t __count, size_t __size) __alloc_size(1,2);
  414. // COMPILATION ENVIRONMENTS -- see compat(5) for additional detail
  415. //
  416. // DEFAULT By default newly complied code will get POSIX APIs plus
  417. // Apple API extensions in scope.
  418. //
  419. // Most users will use this compilation environment to avoid
  420. // behavioral differences between 32 and 64 bit code.
  421. //
  422. // LEGACY Defining _NONSTD_SOURCE will get pre-POSIX APIs plus Apple
  423. // API extensions in scope.
  424. //
  425. // This is generally equivalent to the Tiger release compilation
  426. // environment, except that it cannot be applied to 64 bit code;
  427. // its use is discouraged.
  428. //
  429. // We expect this environment to be deprecated in the future.
  430. //
  431. // STRICT Defining _POSIX_C_SOURCE or _XOPEN_SOURCE restricts the
  432. // available APIs to exactly the set of APIs defined by the
  433. // corresponding standard, based on the value defined.
  434. //
  435. // A correct, portable definition for _POSIX_C_SOURCE is 200112L.
  436. // A correct, portable definition for _XOPEN_SOURCE is 600L.
  437. //
  438. // Apple API extensions are not visible in this environment,
  439. // which can cause Apple specific code to fail to compile,
  440. // or behave incorrectly if prototypes are not in scope or
  441. // warnings about missing prototypes are not enabled or ignored.
  442. //
  443. // In any compilation environment, for correct symbol resolution to occur,
  444. // function prototypes must be in scope. It is recommended that all Apple
  445. // tools users add either the "-Wall" or "-Wimplicit-function-declaration"
  446. // compiler flags to their projects to be warned when a function is being
  447. // used without a prototype in scope.
  448. // These settings are particular to each product.
  449. // Platform: MacOSX
  450. // The __DARWIN_ALIAS macros are used to do symbol renaming; they allow
  451. // legacy code to use the old symbol, thus maintaining binary compatibility
  452. // while new code can use a standards compliant version of the same function.
  453. //
  454. // __DARWIN_ALIAS is used by itself if the function signature has not
  455. // changed, it is used along with a #ifdef check for __DARWIN_UNIX03
  456. // if the signature has changed. Because the __LP64__ environment
  457. // only supports UNIX03 semantics it causes __DARWIN_UNIX03 to be
  458. // defined, but causes __DARWIN_ALIAS to do no symbol mangling.
  459. //
  460. // As a special case, when XCode is used to target a specific version of the
  461. // OS, the manifest constant __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__
  462. // will be defined by the compiler, with the digits representing major version
  463. // time 100 + minor version times 10 (e.g. 10.5 := 1050). If we are targeting
  464. // pre-10.5, and it is the default compilation environment, revert the
  465. // compilation environment to pre-__DARWIN_UNIX03.
  466. // symbol suffixes used for symbol versioning
  467. // symbol versioning macros
  468. // symbol release macros
  469. // Copyright (c) 2010 Apple Inc. All rights reserved.
  470. //
  471. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  472. //
  473. // This file contains Original Code and/or Modifications of Original Code
  474. // as defined in and that are subject to the Apple Public Source License
  475. // Version 2.0 (the 'License'). You may not use this file except in
  476. // compliance with the License. The rights granted to you under the License
  477. // may not be used to create, or enable the creation or redistribution of,
  478. // unlawful or unlicensed copies of an Apple operating system, or to
  479. // circumvent, violate, or enable the circumvention or violation of, any
  480. // terms of an Apple operating system software license agreement.
  481. //
  482. // Please obtain a copy of the License at
  483. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  484. //
  485. // The Original Code and all software distributed under the License are
  486. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  487. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  488. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  489. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  490. // Please see the License for the specific language governing rights and
  491. // limitations under the License.
  492. //
  493. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  494. // POSIX.1 requires that the macros we test be defined before any standard
  495. // header file is included. This permits us to convert values for feature
  496. // testing, as necessary, using only _POSIX_C_SOURCE.
  497. //
  498. // Here's a quick run-down of the versions:
  499. // defined(_POSIX_SOURCE) 1003.1-1988
  500. // _POSIX_C_SOURCE == 1L 1003.1-1990
  501. // _POSIX_C_SOURCE == 2L 1003.2-1992 C Language Binding Option
  502. // _POSIX_C_SOURCE == 199309L 1003.1b-1993
  503. // _POSIX_C_SOURCE == 199506L 1003.1c-1995, 1003.1i-1995,
  504. // and the omnibus ISO/IEC 9945-1: 1996
  505. // _POSIX_C_SOURCE == 200112L 1003.1-2001
  506. // _POSIX_C_SOURCE == 200809L 1003.1-2008
  507. //
  508. // In addition, the X/Open Portability Guide, which is now the Single UNIX
  509. // Specification, defines a feature-test macro which indicates the version of
  510. // that specification, and which subsumes _POSIX_C_SOURCE.
  511. // Deal with IEEE Std. 1003.1-1990, in which _POSIX_C_SOURCE == 1L.
  512. // Deal with IEEE Std. 1003.2-1992, in which _POSIX_C_SOURCE == 2L.
  513. // Deal with various X/Open Portability Guides and Single UNIX Spec.
  514. // Deal with all versions of POSIX. The ordering relative to the tests above is
  515. // important.
  516. // POSIX C deprecation macros
  517. // Copyright (c) 2010 Apple Inc. All rights reserved.
  518. //
  519. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  520. //
  521. // This file contains Original Code and/or Modifications of Original Code
  522. // as defined in and that are subject to the Apple Public Source License
  523. // Version 2.0 (the 'License'). You may not use this file except in
  524. // compliance with the License. The rights granted to you under the License
  525. // may not be used to create, or enable the creation or redistribution of,
  526. // unlawful or unlicensed copies of an Apple operating system, or to
  527. // circumvent, violate, or enable the circumvention or violation of, any
  528. // terms of an Apple operating system software license agreement.
  529. //
  530. // Please obtain a copy of the License at
  531. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  532. //
  533. // The Original Code and all software distributed under the License are
  534. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  535. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  536. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  537. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  538. // Please see the License for the specific language governing rights and
  539. // limitations under the License.
  540. //
  541. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  542. // Set a single macro which will always be defined and can be used to determine
  543. // the appropriate namespace. For POSIX, these values will correspond to
  544. // _POSIX_C_SOURCE value. Currently there are two additional levels corresponding
  545. // to ANSI (_ANSI_SOURCE) and Darwin extensions (_DARWIN_C_SOURCE)
  546. // If the developer has neither requested a strict language mode nor a version
  547. // of POSIX, turn on functionality provided by __STDC_WANT_LIB_EXT1__ as part
  548. // of __DARWIN_C_FULL.
  549. // long long is not supported in c89 (__STRICT_ANSI__), but g++ -ansi and
  550. // c99 still want long longs. While not perfect, we allow long longs for
  551. // g++.
  552. // ****************************************
  553. //
  554. // Public darwin-specific feature macros
  555. //
  556. // _DARWIN_FEATURE_64_BIT_INODE indicates that the ino_t type is 64-bit, and
  557. // structures modified for 64-bit inodes (like struct stat) will be used.
  558. // _DARWIN_FEATURE_64_ONLY_BIT_INODE indicates that the ino_t type may only
  559. // be 64-bit; there is no support for 32-bit ino_t when this macro is defined
  560. // (and non-zero). There is no struct stat64 either, as the regular
  561. // struct stat will already be the 64-bit version.
  562. // _DARWIN_FEATURE_ONLY_VERS_1050 indicates that only those APIs updated
  563. // in 10.5 exists; no pre-10.5 variants are available.
  564. // _DARWIN_FEATURE_ONLY_UNIX_CONFORMANCE indicates only UNIX conforming API
  565. // are available (the legacy BSD APIs are not available)
  566. // _DARWIN_FEATURE_UNIX_CONFORMANCE indicates whether UNIX conformance is on,
  567. // and specifies the conformance level (3 is SUSv3)
  568. // This macro casts away the qualifier from the variable
  569. //
  570. // Note: use at your own risk, removing qualifiers can result in
  571. // catastrophic run-time failures.
  572. // __XNU_PRIVATE_EXTERN is a linkage decoration indicating that a symbol can be
  573. // used from other compilation units, but not other libraries or executables.
  574. // We intentionally define to nothing pointer attributes which do not have an
  575. // impact on the ABI. __indexable and __bidi_indexable are not defined because
  576. // of the ABI incompatibility that makes the diagnostic preferable.
  577. // Similarly, we intentionally define to nothing the
  578. // __ptrcheck_abi_assume_single and __ptrcheck_abi_assume_unsafe_indexable
  579. // macros because they do not lead to an ABI incompatibility. However, we do not
  580. // define the indexable and unsafe_indexable ones because the diagnostic is
  581. // better than the silent ABI break.
  582. // __unsafe_forge intrinsics are defined as regular C casts.
  583. // decay operates normally; attribute is meaningless without pointer checks.
  584. // Architecture validation for current SDK
  585. // Similar to OS_ENUM/OS_CLOSED_ENUM/OS_OPTIONS/OS_CLOSED_OPTIONS
  586. //
  587. // This provides more advanced type checking on compilers supporting
  588. // the proper extensions, even in C.
  589. // Copyright (c) 2000-2006 Apple Computer, Inc. All rights reserved.
  590. //
  591. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  592. //
  593. // This file contains Original Code and/or Modifications of Original Code
  594. // as defined in and that are subject to the Apple Public Source License
  595. // Version 2.0 (the 'License'). You may not use this file except in
  596. // compliance with the License. The rights granted to you under the License
  597. // may not be used to create, or enable the creation or redistribution of,
  598. // unlawful or unlicensed copies of an Apple operating system, or to
  599. // circumvent, violate, or enable the circumvention or violation of, any
  600. // terms of an Apple operating system software license agreement.
  601. //
  602. // Please obtain a copy of the License at
  603. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  604. //
  605. // The Original Code and all software distributed under the License are
  606. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  607. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  608. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  609. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  610. // Please see the License for the specific language governing rights and
  611. // limitations under the License.
  612. //
  613. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  614. // Copyright (c) 1997 Apple Computer, Inc. All Rights Reserved
  615. // Copyright (c) 1988, 1989, 1993, 1994
  616. // The Regents of the University of California. All rights reserved.
  617. //
  618. // Redistribution and use in source and binary forms, with or without
  619. // modification, are permitted provided that the following conditions
  620. // are met:
  621. // 1. Redistributions of source code must retain the above copyright
  622. // notice, this list of conditions and the following disclaimer.
  623. // 2. Redistributions in binary form must reproduce the above copyright
  624. // notice, this list of conditions and the following disclaimer in the
  625. // documentation and/or other materials provided with the distribution.
  626. // 3. All advertising materials mentioning features or use of this software
  627. // must display the following acknowledgement:
  628. // This product includes software developed by the University of
  629. // California, Berkeley and its contributors.
  630. // 4. Neither the name of the University nor the names of its contributors
  631. // may be used to endorse or promote products derived from this software
  632. // without specific prior written permission.
  633. //
  634. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  635. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  636. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  637. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  638. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  639. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  640. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  641. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  642. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  643. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  644. // SUCH DAMAGE.
  645. //
  646. // @(#)termios.h 8.3 (Berkeley) 3/28/94
  647. // Copyright (c) 2000-2018 Apple Inc. All rights reserved.
  648. //
  649. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  650. //
  651. // This file contains Original Code and/or Modifications of Original Code
  652. // as defined in and that are subject to the Apple Public Source License
  653. // Version 2.0 (the 'License'). You may not use this file except in
  654. // compliance with the License. The rights granted to you under the License
  655. // may not be used to create, or enable the creation or redistribution of,
  656. // unlawful or unlicensed copies of an Apple operating system, or to
  657. // circumvent, violate, or enable the circumvention or violation of, any
  658. // terms of an Apple operating system software license agreement.
  659. //
  660. // Please obtain a copy of the License at
  661. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  662. //
  663. // The Original Code and all software distributed under the License are
  664. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  665. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  666. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  667. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  668. // Please see the License for the specific language governing rights and
  669. // limitations under the License.
  670. //
  671. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  672. // Copyright 1995 NeXT Computer, Inc. All rights reserved.
  673. // Copyright (c) 1991, 1993
  674. // The Regents of the University of California. All rights reserved.
  675. //
  676. // This code is derived from software contributed to Berkeley by
  677. // Berkeley Software Design, Inc.
  678. //
  679. // Redistribution and use in source and binary forms, with or without
  680. // modification, are permitted provided that the following conditions
  681. // are met:
  682. // 1. Redistributions of source code must retain the above copyright
  683. // notice, this list of conditions and the following disclaimer.
  684. // 2. Redistributions in binary form must reproduce the above copyright
  685. // notice, this list of conditions and the following disclaimer in the
  686. // documentation and/or other materials provided with the distribution.
  687. // 3. All advertising materials mentioning features or use of this software
  688. // must display the following acknowledgement:
  689. // This product includes software developed by the University of
  690. // California, Berkeley and its contributors.
  691. // 4. Neither the name of the University nor the names of its contributors
  692. // may be used to endorse or promote products derived from this software
  693. // without specific prior written permission.
  694. //
  695. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  696. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  697. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  698. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  699. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  700. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  701. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  702. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  703. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  704. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  705. // SUCH DAMAGE.
  706. //
  707. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  708. // Special Control Characters
  709. //
  710. // Index into c_cc[] character array.
  711. //
  712. // Name Subscript Enabled by
  713. // 7 spare 1
  714. // 19 spare 2
  715. // Copyright (c) 2003-2012 Apple Inc. All rights reserved.
  716. //
  717. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  718. //
  719. // This file contains Original Code and/or Modifications of Original Code
  720. // as defined in and that are subject to the Apple Public Source License
  721. // Version 2.0 (the 'License'). You may not use this file except in
  722. // compliance with the License. The rights granted to you under the License
  723. // may not be used to create, or enable the creation or redistribution of,
  724. // unlawful or unlicensed copies of an Apple operating system, or to
  725. // circumvent, violate, or enable the circumvention or violation of, any
  726. // terms of an Apple operating system software license agreement.
  727. //
  728. // Please obtain a copy of the License at
  729. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  730. //
  731. // The Original Code and all software distributed under the License are
  732. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  733. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  734. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  735. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  736. // Please see the License for the specific language governing rights and
  737. // limitations under the License.
  738. //
  739. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  740. // Input flags - software input processing
  741. // Output flags - software output processing
  742. // The following block of features is unimplemented. Use of these flags in
  743. // programs will currently result in unexpected behaviour.
  744. //
  745. // - Begin unimplemented features
  746. // These manifest constants have the same names as those in the header
  747. // <sys/ioctl_compat.h>, so you are not permitted to have both definitions
  748. // in scope simultaneously in the same compilation unit. Nevertheless,
  749. // they are required to be in scope when _POSIX_C_SOURCE is requested;
  750. // this means that including the <sys/ioctl_compat.h> header before this
  751. // one when _POSIX_C_SOURCE is in scope will result in redefintions. We
  752. // attempt to maintain these as the same values so as to avoid this being
  753. // an outright error in most compilers.
  754. // not in sys/ioctl_compat.h, use OXTABS value
  755. // + End unimplemented features
  756. // Control flags - hardware control of terminal
  757. // "Local" flags - dumping ground for other state
  758. //
  759. // Warning: some flags in this structure begin with
  760. // the letter "I" and look like they belong in the
  761. // input flag.
  762. type Tcflag_t = uint64 /* termios.h:263:25 */
  763. type Cc_t = uint8 /* termios.h:264:25 */
  764. type Speed_t = uint64 /* termios.h:265:25 */
  765. type Termios = struct {
  766. Fc_iflag Tcflag_t
  767. Fc_oflag Tcflag_t
  768. Fc_cflag Tcflag_t
  769. Fc_lflag Tcflag_t
  770. Fc_cc [20]Cc_t
  771. F__ccgo_pad1 [4]byte
  772. Fc_ispeed Speed_t
  773. Fc_ospeed Speed_t
  774. } /* termios.h:267:1 */
  775. // Include tty ioctl's that aren't just for backwards compatibility
  776. // with the old tty driver. These ioctl definitions were previously
  777. // in <sys/ioctl.h>.
  778. // Copyright (c) 2000-2002 Apple Computer, Inc. All rights reserved.
  779. //
  780. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  781. //
  782. // This file contains Original Code and/or Modifications of Original Code
  783. // as defined in and that are subject to the Apple Public Source License
  784. // Version 2.0 (the 'License'). You may not use this file except in
  785. // compliance with the License. The rights granted to you under the License
  786. // may not be used to create, or enable the creation or redistribution of,
  787. // unlawful or unlicensed copies of an Apple operating system, or to
  788. // circumvent, violate, or enable the circumvention or violation of, any
  789. // terms of an Apple operating system software license agreement.
  790. //
  791. // Please obtain a copy of the License at
  792. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  793. //
  794. // The Original Code and all software distributed under the License are
  795. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  796. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  797. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  798. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  799. // Please see the License for the specific language governing rights and
  800. // limitations under the License.
  801. //
  802. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  803. // Copyright (c) 1997 Apple Computer, Inc. All Rights Reserved
  804. // -
  805. // Copyright (c) 1982, 1986, 1990, 1993, 1994
  806. // The Regents of the University of California. All rights reserved.
  807. // (c) UNIX System Laboratories, Inc.
  808. // All or some portions of this file are derived from material licensed
  809. // to the University of California by American Telephone and Telegraph
  810. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  811. // the permission of UNIX System Laboratories, Inc.
  812. //
  813. // Redistribution and use in source and binary forms, with or without
  814. // modification, are permitted provided that the following conditions
  815. // are met:
  816. // 1. Redistributions of source code must retain the above copyright
  817. // notice, this list of conditions and the following disclaimer.
  818. // 2. Redistributions in binary form must reproduce the above copyright
  819. // notice, this list of conditions and the following disclaimer in the
  820. // documentation and/or other materials provided with the distribution.
  821. // 3. All advertising materials mentioning features or use of this software
  822. // must display the following acknowledgement:
  823. // This product includes software developed by the University of
  824. // California, Berkeley and its contributors.
  825. // 4. Neither the name of the University nor the names of its contributors
  826. // may be used to endorse or promote products derived from this software
  827. // without specific prior written permission.
  828. //
  829. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  830. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  831. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  832. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  833. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  834. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  835. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  836. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  837. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  838. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  839. // SUCH DAMAGE.
  840. //
  841. // @(#)ttycom.h 8.1 (Berkeley) 3/28/94
  842. // Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
  843. //
  844. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  845. //
  846. // This file contains Original Code and/or Modifications of Original Code
  847. // as defined in and that are subject to the Apple Public Source License
  848. // Version 2.0 (the 'License'). You may not use this file except in
  849. // compliance with the License. The rights granted to you under the License
  850. // may not be used to create, or enable the creation or redistribution of,
  851. // unlawful or unlicensed copies of an Apple operating system, or to
  852. // circumvent, violate, or enable the circumvention or violation of, any
  853. // terms of an Apple operating system software license agreement.
  854. //
  855. // Please obtain a copy of the License at
  856. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  857. //
  858. // The Original Code and all software distributed under the License are
  859. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  860. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  861. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  862. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  863. // Please see the License for the specific language governing rights and
  864. // limitations under the License.
  865. //
  866. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  867. // Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved
  868. // -
  869. // Copyright (c) 1982, 1986, 1990, 1993, 1994
  870. // The Regents of the University of California. All rights reserved.
  871. //
  872. // Redistribution and use in source and binary forms, with or without
  873. // modification, are permitted provided that the following conditions
  874. // are met:
  875. // 1. Redistributions of source code must retain the above copyright
  876. // notice, this list of conditions and the following disclaimer.
  877. // 2. Redistributions in binary form must reproduce the above copyright
  878. // notice, this list of conditions and the following disclaimer in the
  879. // documentation and/or other materials provided with the distribution.
  880. // 3. All advertising materials mentioning features or use of this software
  881. // must display the following acknowledgement:
  882. // This product includes software developed by the University of
  883. // California, Berkeley and its contributors.
  884. // 4. Neither the name of the University nor the names of its contributors
  885. // may be used to endorse or promote products derived from this software
  886. // without specific prior written permission.
  887. //
  888. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  889. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  890. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  891. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  892. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  893. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  894. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  895. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  896. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  897. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  898. // SUCH DAMAGE.
  899. //
  900. // @(#)ioccom.h 8.2 (Berkeley) 3/28/94
  901. // Copyright (c) 2003-2007 Apple Inc. All rights reserved.
  902. //
  903. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  904. //
  905. // This file contains Original Code and/or Modifications of Original Code
  906. // as defined in and that are subject to the Apple Public Source License
  907. // Version 2.0 (the 'License'). You may not use this file except in
  908. // compliance with the License. The rights granted to you under the License
  909. // may not be used to create, or enable the creation or redistribution of,
  910. // unlawful or unlicensed copies of an Apple operating system, or to
  911. // circumvent, violate, or enable the circumvention or violation of, any
  912. // terms of an Apple operating system software license agreement.
  913. //
  914. // Please obtain a copy of the License at
  915. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  916. //
  917. // The Original Code and all software distributed under the License are
  918. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  919. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  920. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  921. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  922. // Please see the License for the specific language governing rights and
  923. // limitations under the License.
  924. //
  925. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  926. // Copyright (c) 2000-2018 Apple Inc. All rights reserved.
  927. //
  928. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  929. //
  930. // This file contains Original Code and/or Modifications of Original Code
  931. // as defined in and that are subject to the Apple Public Source License
  932. // Version 2.0 (the 'License'). You may not use this file except in
  933. // compliance with the License. The rights granted to you under the License
  934. // may not be used to create, or enable the creation or redistribution of,
  935. // unlawful or unlicensed copies of an Apple operating system, or to
  936. // circumvent, violate, or enable the circumvention or violation of, any
  937. // terms of an Apple operating system software license agreement.
  938. //
  939. // Please obtain a copy of the License at
  940. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  941. //
  942. // The Original Code and all software distributed under the License are
  943. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  944. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  945. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  946. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  947. // Please see the License for the specific language governing rights and
  948. // limitations under the License.
  949. //
  950. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  951. // Copyright 1995 NeXT Computer, Inc. All rights reserved.
  952. // Copyright (c) 1991, 1993
  953. // The Regents of the University of California. All rights reserved.
  954. //
  955. // This code is derived from software contributed to Berkeley by
  956. // Berkeley Software Design, Inc.
  957. //
  958. // Redistribution and use in source and binary forms, with or without
  959. // modification, are permitted provided that the following conditions
  960. // are met:
  961. // 1. Redistributions of source code must retain the above copyright
  962. // notice, this list of conditions and the following disclaimer.
  963. // 2. Redistributions in binary form must reproduce the above copyright
  964. // notice, this list of conditions and the following disclaimer in the
  965. // documentation and/or other materials provided with the distribution.
  966. // 3. All advertising materials mentioning features or use of this software
  967. // must display the following acknowledgement:
  968. // This product includes software developed by the University of
  969. // California, Berkeley and its contributors.
  970. // 4. Neither the name of the University nor the names of its contributors
  971. // may be used to endorse or promote products derived from this software
  972. // without specific prior written permission.
  973. //
  974. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  975. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  976. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  977. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  978. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  979. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  980. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  981. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  982. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  983. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  984. // SUCH DAMAGE.
  985. //
  986. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  987. // Copyright (c) 2003-2007 Apple Inc. All rights reserved.
  988. //
  989. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  990. //
  991. // This file contains Original Code and/or Modifications of Original Code
  992. // as defined in and that are subject to the Apple Public Source License
  993. // Version 2.0 (the 'License'). You may not use this file except in
  994. // compliance with the License. The rights granted to you under the License
  995. // may not be used to create, or enable the creation or redistribution of,
  996. // unlawful or unlicensed copies of an Apple operating system, or to
  997. // circumvent, violate, or enable the circumvention or violation of, any
  998. // terms of an Apple operating system software license agreement.
  999. //
  1000. // Please obtain a copy of the License at
  1001. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  1002. //
  1003. // The Original Code and all software distributed under the License are
  1004. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  1005. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  1006. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  1007. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  1008. // Please see the License for the specific language governing rights and
  1009. // limitations under the License.
  1010. //
  1011. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  1012. // Copyright (c) 2000-2007 Apple Inc. All rights reserved.
  1013. // This header file contains integer types. It's intended to also contain
  1014. // flotaing point and other arithmetic types, as needed, later.
  1015. type X__int8_t = int8 /* _types.h:15:33 */
  1016. type X__uint8_t = uint8 /* _types.h:19:33 */
  1017. type X__int16_t = int16 /* _types.h:20:33 */
  1018. type X__uint16_t = uint16 /* _types.h:21:33 */
  1019. type X__int32_t = int32 /* _types.h:22:33 */
  1020. type X__uint32_t = uint32 /* _types.h:23:33 */
  1021. type X__int64_t = int64 /* _types.h:24:33 */
  1022. type X__uint64_t = uint64 /* _types.h:25:33 */
  1023. type X__darwin_intptr_t = int64 /* _types.h:27:33 */
  1024. type X__darwin_natural_t = uint32 /* _types.h:28:33 */
  1025. // The rune type below is declared to be an ``int'' instead of the more natural
  1026. // ``unsigned long'' or ``long''. Two things are happening here. It is not
  1027. // unsigned so that EOF (-1) can be naturally assigned to it and used. Also,
  1028. // it looks like 10646 will be a 31 bit standard. This means that if your
  1029. // ints cannot hold 32 bits, you will be in trouble. The reason an int was
  1030. // chosen over a long is that the is*() and to*() routines take ints (says
  1031. // ANSI C), but they use __darwin_ct_rune_t instead of int. By changing it
  1032. // here, you lose a bit of ANSI conformance, but your programs will still
  1033. // work.
  1034. //
  1035. // NOTE: rune_t is not covered by ANSI nor other standards, and should not
  1036. // be instantiated outside of lib/libc/locale. Use wchar_t. wchar_t and
  1037. // rune_t must be the same type. Also wint_t must be no narrower than
  1038. // wchar_t, and should also be able to hold all members of the largest
  1039. // character set plus one extra value (WEOF). wint_t must be at least 16 bits.
  1040. type X__darwin_ct_rune_t = int32 /* _types.h:48:33 */ // ct_rune_t
  1041. // mbstate_t is an opaque object to keep conversion state, during multibyte
  1042. // stream conversions. The content must not be referenced by user programs.
  1043. type X__mbstate_t = struct {
  1044. F__ccgo_pad1 [0]uint64
  1045. F__mbstate8 [128]int8
  1046. } /* _types.h:57:3 */
  1047. type X__darwin_mbstate_t = X__mbstate_t /* _types.h:59:33 */ // mbstate_t
  1048. type X__darwin_ptrdiff_t = int64 /* _types.h:62:33 */ // ptr1 - ptr2
  1049. type X__darwin_size_t = uint64 /* _types.h:70:33 */ // sizeof()
  1050. type X__darwin_va_list = X__builtin_va_list /* _types.h:76:33 */ // va_list
  1051. type X__darwin_wchar_t = int32 /* _types.h:82:33 */ // wchar_t
  1052. type X__darwin_rune_t = X__darwin_wchar_t /* _types.h:87:33 */ // rune_t
  1053. type X__darwin_wint_t = int32 /* _types.h:90:33 */ // wint_t
  1054. type X__darwin_clock_t = uint64 /* _types.h:95:33 */ // clock()
  1055. type X__darwin_socklen_t = X__uint32_t /* _types.h:96:33 */ // socklen_t (duh)
  1056. type X__darwin_ssize_t = int64 /* _types.h:97:33 */ // byte count or error
  1057. type X__darwin_time_t = int64 /* _types.h:98:33 */ // time()
  1058. // Type definitions; takes common type definitions that must be used
  1059. // in multiple header files due to [XSI], removes them from the system
  1060. // space, and puts them in the implementation space.
  1061. type X__darwin_blkcnt_t = X__int64_t /* _types.h:55:25 */ // total blocks
  1062. type X__darwin_blksize_t = X__int32_t /* _types.h:56:25 */ // preferred block size
  1063. type X__darwin_dev_t = X__int32_t /* _types.h:57:25 */ // dev_t
  1064. type X__darwin_fsblkcnt_t = uint32 /* _types.h:58:25 */ // Used by statvfs and fstatvfs
  1065. type X__darwin_fsfilcnt_t = uint32 /* _types.h:59:25 */ // Used by statvfs and fstatvfs
  1066. type X__darwin_gid_t = X__uint32_t /* _types.h:60:25 */ // [???] process and group IDs
  1067. type X__darwin_id_t = X__uint32_t /* _types.h:61:25 */ // [XSI] pid_t, uid_t, or gid_t
  1068. type X__darwin_ino64_t = X__uint64_t /* _types.h:62:25 */ // [???] Used for 64 bit inodes
  1069. type X__darwin_ino_t = X__darwin_ino64_t /* _types.h:64:26 */ // [???] Used for inodes
  1070. type X__darwin_mach_port_name_t = X__darwin_natural_t /* _types.h:68:28 */ // Used by mach
  1071. type X__darwin_mach_port_t = X__darwin_mach_port_name_t /* _types.h:69:35 */ // Used by mach
  1072. type X__darwin_mode_t = X__uint16_t /* _types.h:70:25 */ // [???] Some file attributes
  1073. type X__darwin_off_t = X__int64_t /* _types.h:71:25 */ // [???] Used for file sizes
  1074. type X__darwin_pid_t = X__int32_t /* _types.h:72:25 */ // [???] process and group IDs
  1075. type X__darwin_sigset_t = X__uint32_t /* _types.h:73:25 */ // [???] signal set
  1076. type X__darwin_suseconds_t = X__int32_t /* _types.h:74:25 */ // [???] microseconds
  1077. type X__darwin_uid_t = X__uint32_t /* _types.h:75:25 */ // [???] user IDs
  1078. type X__darwin_useconds_t = X__uint32_t /* _types.h:76:25 */ // [???] microseconds
  1079. type X__darwin_uuid_t = [16]uint8 /* _types.h:77:25 */
  1080. type X__darwin_uuid_string_t = [37]int8 /* _types.h:78:17 */
  1081. // Copyright (c) 2003-2013 Apple Inc. All rights reserved.
  1082. //
  1083. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  1084. //
  1085. // This file contains Original Code and/or Modifications of Original Code
  1086. // as defined in and that are subject to the Apple Public Source License
  1087. // Version 2.0 (the 'License'). You may not use this file except in
  1088. // compliance with the License. The rights granted to you under the License
  1089. // may not be used to create, or enable the creation or redistribution of,
  1090. // unlawful or unlicensed copies of an Apple operating system, or to
  1091. // circumvent, violate, or enable the circumvention or violation of, any
  1092. // terms of an Apple operating system software license agreement.
  1093. //
  1094. // Please obtain a copy of the License at
  1095. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  1096. //
  1097. // The Original Code and all software distributed under the License are
  1098. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  1099. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  1100. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  1101. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  1102. // Please see the License for the specific language governing rights and
  1103. // limitations under the License.
  1104. //
  1105. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  1106. // Copyright (c) 2000-2018 Apple Inc. All rights reserved.
  1107. //
  1108. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  1109. //
  1110. // This file contains Original Code and/or Modifications of Original Code
  1111. // as defined in and that are subject to the Apple Public Source License
  1112. // Version 2.0 (the 'License'). You may not use this file except in
  1113. // compliance with the License. The rights granted to you under the License
  1114. // may not be used to create, or enable the creation or redistribution of,
  1115. // unlawful or unlicensed copies of an Apple operating system, or to
  1116. // circumvent, violate, or enable the circumvention or violation of, any
  1117. // terms of an Apple operating system software license agreement.
  1118. //
  1119. // Please obtain a copy of the License at
  1120. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  1121. //
  1122. // The Original Code and all software distributed under the License are
  1123. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  1124. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  1125. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  1126. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  1127. // Please see the License for the specific language governing rights and
  1128. // limitations under the License.
  1129. //
  1130. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  1131. // Copyright 1995 NeXT Computer, Inc. All rights reserved.
  1132. // Copyright (c) 1991, 1993
  1133. // The Regents of the University of California. All rights reserved.
  1134. //
  1135. // This code is derived from software contributed to Berkeley by
  1136. // Berkeley Software Design, Inc.
  1137. //
  1138. // Redistribution and use in source and binary forms, with or without
  1139. // modification, are permitted provided that the following conditions
  1140. // are met:
  1141. // 1. Redistributions of source code must retain the above copyright
  1142. // notice, this list of conditions and the following disclaimer.
  1143. // 2. Redistributions in binary form must reproduce the above copyright
  1144. // notice, this list of conditions and the following disclaimer in the
  1145. // documentation and/or other materials provided with the distribution.
  1146. // 3. All advertising materials mentioning features or use of this software
  1147. // must display the following acknowledgement:
  1148. // This product includes software developed by the University of
  1149. // California, Berkeley and its contributors.
  1150. // 4. Neither the name of the University nor the names of its contributors
  1151. // may be used to endorse or promote products derived from this software
  1152. // without specific prior written permission.
  1153. //
  1154. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1155. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1156. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1157. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1158. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1159. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1160. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1161. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1162. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1163. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1164. // SUCH DAMAGE.
  1165. //
  1166. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  1167. // pthread opaque structures
  1168. type X__darwin_pthread_handler_rec = struct {
  1169. F__routine uintptr
  1170. F__arg uintptr
  1171. F__next uintptr
  1172. } /* _pthread_types.h:57:1 */
  1173. type X_opaque_pthread_attr_t = struct {
  1174. F__sig int64
  1175. F__opaque [56]int8
  1176. } /* _pthread_types.h:63:1 */
  1177. type X_opaque_pthread_cond_t = struct {
  1178. F__sig int64
  1179. F__opaque [40]int8
  1180. } /* _pthread_types.h:68:1 */
  1181. type X_opaque_pthread_condattr_t = struct {
  1182. F__sig int64
  1183. F__opaque [8]int8
  1184. } /* _pthread_types.h:73:1 */
  1185. type X_opaque_pthread_mutex_t = struct {
  1186. F__sig int64
  1187. F__opaque [56]int8
  1188. } /* _pthread_types.h:78:1 */
  1189. type X_opaque_pthread_mutexattr_t = struct {
  1190. F__sig int64
  1191. F__opaque [8]int8
  1192. } /* _pthread_types.h:83:1 */
  1193. type X_opaque_pthread_once_t = struct {
  1194. F__sig int64
  1195. F__opaque [8]int8
  1196. } /* _pthread_types.h:88:1 */
  1197. type X_opaque_pthread_rwlock_t = struct {
  1198. F__sig int64
  1199. F__opaque [192]int8
  1200. } /* _pthread_types.h:93:1 */
  1201. type X_opaque_pthread_rwlockattr_t = struct {
  1202. F__sig int64
  1203. F__opaque [16]int8
  1204. } /* _pthread_types.h:98:1 */
  1205. type X_opaque_pthread_t = struct {
  1206. F__sig int64
  1207. F__cleanup_stack uintptr
  1208. F__opaque [8176]int8
  1209. } /* _pthread_types.h:103:1 */
  1210. type X__darwin_pthread_attr_t = X_opaque_pthread_attr_t /* _pthread_types.h:109:39 */
  1211. type X__darwin_pthread_cond_t = X_opaque_pthread_cond_t /* _pthread_types.h:110:39 */
  1212. type X__darwin_pthread_condattr_t = X_opaque_pthread_condattr_t /* _pthread_types.h:111:43 */
  1213. type X__darwin_pthread_key_t = uint64 /* _pthread_types.h:112:23 */
  1214. type X__darwin_pthread_mutex_t = X_opaque_pthread_mutex_t /* _pthread_types.h:113:40 */
  1215. type X__darwin_pthread_mutexattr_t = X_opaque_pthread_mutexattr_t /* _pthread_types.h:114:44 */
  1216. type X__darwin_pthread_once_t = X_opaque_pthread_once_t /* _pthread_types.h:115:39 */
  1217. type X__darwin_pthread_rwlock_t = X_opaque_pthread_rwlock_t /* _pthread_types.h:116:41 */
  1218. type X__darwin_pthread_rwlockattr_t = X_opaque_pthread_rwlockattr_t /* _pthread_types.h:117:45 */
  1219. type X__darwin_pthread_t = uintptr /* _pthread_types.h:118:34 */
  1220. // Ioctl's have the command encoded in the lower word, and the size of
  1221. // any in or out parameters in the upper word. The high 3 bits of the
  1222. // upper word are used to encode the in/out status of the parameter.
  1223. // no parameters
  1224. // copy parameters out
  1225. // copy parameters in
  1226. // copy parameters in and out
  1227. // mask for IN/OUT/VOID
  1228. // this should be _IORW, but stdio got there first
  1229. // Tty ioctl's except for those supported only for backwards compatibility
  1230. // with the old tty driver.
  1231. // Window/terminal size structure. This information is stored by the kernel
  1232. // in order to provide a consistent interface, but is not used by the kernel.
  1233. type Winsize = struct {
  1234. Fws_row uint16
  1235. Fws_col uint16
  1236. Fws_xpixel uint16
  1237. Fws_ypixel uint16
  1238. } /* ttycom.h:82:1 */
  1239. // 8-10 compat
  1240. // 15 unused
  1241. // 17-18 compat
  1242. // 127-124 compat
  1243. // 117-116 compat
  1244. // 105 unused
  1245. // END OF PROTECTED INCLUDE.
  1246. // Copyright (c) 2000-2002 Apple Computer, Inc. All rights reserved.
  1247. //
  1248. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  1249. //
  1250. // This file contains Original Code and/or Modifications of Original Code
  1251. // as defined in and that are subject to the Apple Public Source License
  1252. // Version 2.0 (the 'License'). You may not use this file except in
  1253. // compliance with the License. The rights granted to you under the License
  1254. // may not be used to create, or enable the creation or redistribution of,
  1255. // unlawful or unlicensed copies of an Apple operating system, or to
  1256. // circumvent, violate, or enable the circumvention or violation of, any
  1257. // terms of an Apple operating system software license agreement.
  1258. //
  1259. // Please obtain a copy of the License at
  1260. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  1261. //
  1262. // The Original Code and all software distributed under the License are
  1263. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  1264. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  1265. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  1266. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  1267. // Please see the License for the specific language governing rights and
  1268. // limitations under the License.
  1269. //
  1270. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  1271. // Copyright (c) 1997 Apple Computer, Inc. All Rights Reserved
  1272. // -
  1273. // Copyright (c) 1982, 1986, 1993
  1274. // The Regents of the University of California. All rights reserved.
  1275. // (c) UNIX System Laboratories, Inc.
  1276. // All or some portions of this file are derived from material licensed
  1277. // to the University of California by American Telephone and Telegraph
  1278. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  1279. // the permission of UNIX System Laboratories, Inc.
  1280. //
  1281. // Redistribution and use in source and binary forms, with or without
  1282. // modification, are permitted provided that the following conditions
  1283. // are met:
  1284. // 1. Redistributions of source code must retain the above copyright
  1285. // notice, this list of conditions and the following disclaimer.
  1286. // 2. Redistributions in binary form must reproduce the above copyright
  1287. // notice, this list of conditions and the following disclaimer in the
  1288. // documentation and/or other materials provided with the distribution.
  1289. // 3. All advertising materials mentioning features or use of this software
  1290. // must display the following acknowledgement:
  1291. // This product includes software developed by the University of
  1292. // California, Berkeley and its contributors.
  1293. // 4. Neither the name of the University nor the names of its contributors
  1294. // may be used to endorse or promote products derived from this software
  1295. // without specific prior written permission.
  1296. //
  1297. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1298. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1299. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1300. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1301. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1302. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1303. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1304. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1305. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1306. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1307. // SUCH DAMAGE.
  1308. //
  1309. // @(#)ttydefaults.h 8.4 (Berkeley) 1/21/94
  1310. // System wide defaults for terminal state.
  1311. // Defaults on "first" open.
  1312. // Control Character Defaults
  1313. // compat
  1314. // PROTECTED INCLUSION ENDS HERE
  1315. // #define TTYDEFCHARS to include an array of default control characters.
  1316. // Copyright (c) 2004, 2008, 2009 Apple Inc. All rights reserved.
  1317. //
  1318. // @APPLE_LICENSE_HEADER_START@
  1319. //
  1320. // This file contains Original Code and/or Modifications of Original Code
  1321. // as defined in and that are subject to the Apple Public Source License
  1322. // Version 2.0 (the 'License'). You may not use this file except in
  1323. // compliance with the License. Please obtain a copy of the License at
  1324. // http://www.opensource.apple.com/apsl/ and read it before using this
  1325. // file.
  1326. //
  1327. // The Original Code and all software distributed under the License are
  1328. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  1329. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  1330. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  1331. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  1332. // Please see the License for the specific language governing rights and
  1333. // limitations under the License.
  1334. //
  1335. // @APPLE_LICENSE_HEADER_END@
  1336. // Copyright (c) 2003-2007 Apple Inc. All rights reserved.
  1337. //
  1338. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  1339. //
  1340. // This file contains Original Code and/or Modifications of Original Code
  1341. // as defined in and that are subject to the Apple Public Source License
  1342. // Version 2.0 (the 'License'). You may not use this file except in
  1343. // compliance with the License. The rights granted to you under the License
  1344. // may not be used to create, or enable the creation or redistribution of,
  1345. // unlawful or unlicensed copies of an Apple operating system, or to
  1346. // circumvent, violate, or enable the circumvention or violation of, any
  1347. // terms of an Apple operating system software license agreement.
  1348. //
  1349. // Please obtain a copy of the License at
  1350. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  1351. //
  1352. // The Original Code and all software distributed under the License are
  1353. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  1354. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  1355. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  1356. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  1357. // Please see the License for the specific language governing rights and
  1358. // limitations under the License.
  1359. //
  1360. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  1361. // Copyright (c) 2003-2007 Apple Inc. All rights reserved.
  1362. //
  1363. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  1364. //
  1365. // This file contains Original Code and/or Modifications of Original Code
  1366. // as defined in and that are subject to the Apple Public Source License
  1367. // Version 2.0 (the 'License'). You may not use this file except in
  1368. // compliance with the License. The rights granted to you under the License
  1369. // may not be used to create, or enable the creation or redistribution of,
  1370. // unlawful or unlicensed copies of an Apple operating system, or to
  1371. // circumvent, violate, or enable the circumvention or violation of, any
  1372. // terms of an Apple operating system software license agreement.
  1373. //
  1374. // Please obtain a copy of the License at
  1375. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  1376. //
  1377. // The Original Code and all software distributed under the License are
  1378. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  1379. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  1380. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  1381. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  1382. // Please see the License for the specific language governing rights and
  1383. // limitations under the License.
  1384. //
  1385. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  1386. type X__darwin_nl_item = int32 /* _types.h:40:14 */
  1387. type X__darwin_wctrans_t = int32 /* _types.h:41:14 */
  1388. type X__darwin_wctype_t = X__uint32_t /* _types.h:43:20 */
  1389. // Copyright (c) 2003-2012 Apple Inc. All rights reserved.
  1390. //
  1391. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  1392. //
  1393. // This file contains Original Code and/or Modifications of Original Code
  1394. // as defined in and that are subject to the Apple Public Source License
  1395. // Version 2.0 (the 'License'). You may not use this file except in
  1396. // compliance with the License. The rights granted to you under the License
  1397. // may not be used to create, or enable the creation or redistribution of,
  1398. // unlawful or unlicensed copies of an Apple operating system, or to
  1399. // circumvent, violate, or enable the circumvention or violation of, any
  1400. // terms of an Apple operating system software license agreement.
  1401. //
  1402. // Please obtain a copy of the License at
  1403. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  1404. //
  1405. // The Original Code and all software distributed under the License are
  1406. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  1407. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  1408. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  1409. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  1410. // Please see the License for the specific language governing rights and
  1411. // limitations under the License.
  1412. //
  1413. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  1414. // Copyright (c) 2003-2007 Apple Inc. All rights reserved.
  1415. //
  1416. // @APPLE_OSREFERENCE_LICENSE_HEADER_START@
  1417. //
  1418. // This file contains Original Code and/or Modifications of Original Code
  1419. // as defined in and that are subject to the Apple Public Source License
  1420. // Version 2.0 (the 'License'). You may not use this file except in
  1421. // compliance with the License. The rights granted to you under the License
  1422. // may not be used to create, or enable the creation or redistribution of,
  1423. // unlawful or unlicensed copies of an Apple operating system, or to
  1424. // circumvent, violate, or enable the circumvention or violation of, any
  1425. // terms of an Apple operating system software license agreement.
  1426. //
  1427. // Please obtain a copy of the License at
  1428. // http://www.opensource.apple.com/apsl/ and read it before using this file.
  1429. //
  1430. // The Original Code and all software distributed under the License are
  1431. // distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  1432. // EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  1433. // INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  1434. // FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
  1435. // Please see the License for the specific language governing rights and
  1436. // limitations under the License.
  1437. //
  1438. // @APPLE_OSREFERENCE_LICENSE_HEADER_END@
  1439. type Pid_t = X__darwin_pid_t /* _pid_t.h:31:31 */
  1440. var _ int8 /* gen.c:2:13: */