pthread_netbsd_amd64.go 130 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742
  1. // Code generated by 'ccgo pthread/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 pthread/pthread_netbsd_amd64.go -pkgname pthread', DO NOT EDIT.
  2. package pthread
  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. BIG_ENDIAN = 4321 // endian.h:101:1:
  15. BYTE_ORDER = 1234 // endian.h:103:1:
  16. CLOCKS_PER_SEC = 100 // time.h:73:1:
  17. CLOCK_MONOTONIC = 3 // time.h:297:1:
  18. CLOCK_PROCESS_CPUTIME_ID = 0x40000000 // time.h:299:1:
  19. CLOCK_PROF = 2 // time.h:296:1:
  20. CLOCK_REALTIME = 0 // time.h:294:1:
  21. CLOCK_THREAD_CPUTIME_ID = 0x20000000 // time.h:298:1:
  22. CLOCK_VIRTUAL = 1 // time.h:295:1:
  23. CLONE_CSIGNAL = 0x000000ff // sched.h:189:1:
  24. CLONE_FILES = 0x00000400 // sched.h:192:1:
  25. CLONE_FS = 0x00000200 // sched.h:191:1:
  26. CLONE_PID = 0x00001000 // sched.h:194:1:
  27. CLONE_PTRACE = 0x00002000 // sched.h:195:1:
  28. CLONE_SIGHAND = 0x00000800 // sched.h:193:1:
  29. CLONE_VFORK = 0x00004000 // sched.h:197:1:
  30. CLONE_VM = 0x00000100 // sched.h:190:1:
  31. CPUSTATES = 5 // sched.h:140:1:
  32. CP_IDLE = 4 // sched.h:139:1:
  33. CP_INTR = 3 // sched.h:138:1:
  34. CP_NICE = 1 // sched.h:136:1:
  35. CP_SYS = 2 // sched.h:137:1:
  36. CP_USER = 0 // sched.h:135:1:
  37. FD_SETSIZE = 256 // fd_set.h:59:1:
  38. INT16_MAX = 32767 // common_int_limits.h:53:1:
  39. INT16_MIN = -32768 // common_int_limits.h:47:1:
  40. INT32_MAX = 2147483647 // common_int_limits.h:54:1:
  41. INT32_MIN = -2147483648 // common_int_limits.h:48:1:
  42. INT64_MAX = 9223372036854775807 // common_int_limits.h:55:1:
  43. INT64_MIN = -9223372036854775808 // common_int_limits.h:49:1:
  44. INT8_MAX = 127 // common_int_limits.h:52:1:
  45. INT8_MIN = -128 // common_int_limits.h:46:1:
  46. INTMAX_MAX = 9223372036854775807 // common_int_limits.h:111:1:
  47. INTMAX_MIN = -9223372036854775808 // common_int_limits.h:110:1:
  48. INTPTR_MAX = 9223372036854775807 // common_int_limits.h:105:1:
  49. INTPTR_MIN = -9223372036854775808 // common_int_limits.h:104:1:
  50. INT_FAST16_MAX = 2147483647 // common_int_limits.h:93:1:
  51. INT_FAST16_MIN = -2147483648 // common_int_limits.h:87:1:
  52. INT_FAST32_MAX = 2147483647 // common_int_limits.h:94:1:
  53. INT_FAST32_MIN = -2147483648 // common_int_limits.h:88:1:
  54. INT_FAST64_MAX = 9223372036854775807 // common_int_limits.h:95:1:
  55. INT_FAST64_MIN = -9223372036854775808 // common_int_limits.h:89:1:
  56. INT_FAST8_MAX = 2147483647 // common_int_limits.h:92:1:
  57. INT_FAST8_MIN = -2147483648 // common_int_limits.h:86:1:
  58. INT_LEAST16_MAX = 32767 // common_int_limits.h:73:1:
  59. INT_LEAST16_MIN = -32768 // common_int_limits.h:67:1:
  60. INT_LEAST32_MAX = 2147483647 // common_int_limits.h:74:1:
  61. INT_LEAST32_MIN = -2147483648 // common_int_limits.h:68:1:
  62. INT_LEAST64_MAX = 9223372036854775807 // common_int_limits.h:75:1:
  63. INT_LEAST64_MIN = -9223372036854775808 // common_int_limits.h:69:1:
  64. INT_LEAST8_MAX = 127 // common_int_limits.h:72:1:
  65. INT_LEAST8_MIN = -128 // common_int_limits.h:66:1:
  66. ITIMER_MONOTONIC = 3 // time.h:278:1:
  67. ITIMER_PROF = 2 // time.h:277:1:
  68. ITIMER_REAL = 0 // time.h:275:1:
  69. ITIMER_VIRTUAL = 1 // time.h:276:1:
  70. LITTLE_ENDIAN = 1234 // endian.h:100:1:
  71. NBBY = 8 // types.h:316:1:
  72. NFDBITS = 32 // fd_set.h:93:1:
  73. NODEVMAJOR = -1 // types.h:258:1:
  74. PDP_ENDIAN = 3412 // endian.h:102:1:
  75. PTHREAD_BARRIER_SERIAL_THREAD = 1234567 // pthread.h:266:1:
  76. PTHREAD_CANCEL_ASYNCHRONOUS = 1 // pthread.h:261:1:
  77. PTHREAD_CANCEL_DEFERRED = 0 // pthread.h:260:1:
  78. PTHREAD_CANCEL_DISABLE = 1 // pthread.h:264:1:
  79. PTHREAD_CANCEL_ENABLE = 0 // pthread.h:263:1:
  80. PTHREAD_CREATE_DETACHED = 1 // pthread.h:249:1:
  81. PTHREAD_CREATE_JOINABLE = 0 // pthread.h:248:1:
  82. PTHREAD_EXPLICIT_SCHED = 1 // pthread.h:252:1:
  83. PTHREAD_INHERIT_SCHED = 0 // pthread.h:251:1:
  84. PTHREAD_MAX_NAMELEN_NP = 32 // pthread.h:279:1:
  85. PTHREAD_MUTEX_DEFAULT = 0 // pthread.h:287:1:
  86. PTHREAD_MUTEX_ERRORCHECK = 1 // pthread.h:285:1:
  87. PTHREAD_MUTEX_NORMAL = 0 // pthread.h:284:1:
  88. PTHREAD_MUTEX_RECURSIVE = 2 // pthread.h:286:1:
  89. PTHREAD_PRIO_INHERIT = 1 // pthread.h:290:1:
  90. PTHREAD_PRIO_NONE = 0 // pthread.h:289:1:
  91. PTHREAD_PRIO_PROTECT = 2 // pthread.h:291:1:
  92. PTHREAD_PROCESS_PRIVATE = 0 // pthread.h:257:1:
  93. PTHREAD_PROCESS_SHARED = 1 // pthread.h:258:1:
  94. PTHREAD_SCOPE_PROCESS = 0 // pthread.h:254:1:
  95. PTHREAD_SCOPE_SYSTEM = 1 // pthread.h:255:1:
  96. PTRDIFF_MAX = 9223372036854775807 // common_int_limits.h:121:1:
  97. PTRDIFF_MIN = -9223372036854775808 // common_int_limits.h:120:1:
  98. SCHED_FIFO = 1 // sched.h:89:1:
  99. SCHED_NONE = -1 // sched.h:87:1:
  100. SCHED_OTHER = 0 // sched.h:88:1:
  101. SCHED_RR = 2 // sched.h:90:1:
  102. SIG_ATOMIC_MAX = 2147483647 // common_int_limits.h:125:1:
  103. SIG_ATOMIC_MIN = -2147483648 // common_int_limits.h:124:1:
  104. SIZE_MAX = 18446744073709551615 // common_int_limits.h:128:1:
  105. TIMER_ABSTIME = 0x1 // time.h:304:1:
  106. TIMER_RELTIME = 0x0 // time.h:302:1:
  107. TIME_UTC = 1 // time.h:238:1:
  108. UINT16_MAX = 65535 // common_int_limits.h:59:1:
  109. UINT32_MAX = 4294967295 // common_int_limits.h:60:1:
  110. UINT64_MAX = 18446744073709551615 // common_int_limits.h:61:1:
  111. UINT8_MAX = 255 // common_int_limits.h:58:1:
  112. UINTMAX_MAX = 18446744073709551615 // common_int_limits.h:112:1:
  113. UINTPTR_MAX = 18446744073709551615 // common_int_limits.h:106:1:
  114. UINT_FAST16_MAX = 4294967295 // common_int_limits.h:99:1:
  115. UINT_FAST32_MAX = 4294967295 // common_int_limits.h:100:1:
  116. UINT_FAST64_MAX = 18446744073709551615 // common_int_limits.h:101:1:
  117. UINT_FAST8_MAX = 4294967295 // common_int_limits.h:98:1:
  118. UINT_LEAST16_MAX = 65535 // common_int_limits.h:79:1:
  119. UINT_LEAST32_MAX = 4294967295 // common_int_limits.h:80:1:
  120. UINT_LEAST64_MAX = 18446744073709551615 // common_int_limits.h:81:1:
  121. UINT_LEAST8_MAX = 255 // common_int_limits.h:78:1:
  122. WCHAR_MAX = 0x7fffffff // wchar_limits.h:41:1:
  123. WCHAR_MIN = -2147483648 // wchar_limits.h:40:1:
  124. WINT_MAX = 0x7fffffff // wchar_limits.h:45:1:
  125. WINT_MIN = -2147483648 // wchar_limits.h:44:1:
  126. X_AMD64_BYTE_SWAP_H_ = 0 // byte_swap.h:37:1:
  127. X_AMD64_INT_CONST_H_ = 0 // int_const.h:33:1:
  128. X_AMD64_INT_LIMITS_H_ = 0 // int_limits.h:33:1:
  129. X_AMD64_INT_MWGWTYPES_H_ = 0 // int_mwgwtypes.h:33:1:
  130. X_AMD64_INT_TYPES_H_ = 0 // int_types.h:35:1:
  131. X_AMD64_WCHAR_LIMITS_H_ = 0 // wchar_limits.h:33:1:
  132. X_BIG_ENDIAN = 4321 // endian.h:44:1:
  133. X_BSD_INT16_T_ = 0 // types.h:65:1:
  134. X_BSD_INT32_T_ = 0 // types.h:75:1:
  135. X_BSD_INT64_T_ = 0 // types.h:85:1:
  136. X_BSD_INT8_T_ = 0 // types.h:55:1:
  137. X_BSD_INTPTR_T_ = 0 // stdint.h:80:1:
  138. X_BSD_UINT16_T_ = 0 // types.h:70:1:
  139. X_BSD_UINT32_T_ = 0 // types.h:80:1:
  140. X_BSD_UINT64_T_ = 0 // types.h:90:1:
  141. X_BSD_UINT8_T_ = 0 // types.h:60:1:
  142. X_BSD_UINTPTR_T_ = 0 // stdint.h:85:1:
  143. X_BYTE_ORDER = 1234 // endian_machdep.h:3:1:
  144. X_FILE_OFFSET_BITS = 64 // <builtin>:25:1:
  145. X_LIB_PTHREAD_H = 0 // pthread.h:33:1:
  146. X_LIB_PTHREAD_TYPES_H = 0 // pthread_types.h:33:1:
  147. X_LITTLE_ENDIAN = 1234 // endian.h:43:1:
  148. X_LP64 = 1 // <predefined>:268:1:
  149. X_NETBSD_SOURCE = 1 // featuretest.h:70:1:
  150. X_PDP_ENDIAN = 3412 // endian.h:45:1:
  151. X_PT_BARRIERATTR_DEAD = 0xDEAD0808 // pthread_types.h:278:1:
  152. X_PT_BARRIERATTR_MAGIC = 0x88880808 // pthread_types.h:277:1:
  153. X_PT_BARRIER_DEAD = 0xDEAD0008 // pthread_types.h:270:1:
  154. X_PT_BARRIER_MAGIC = 0x88880008 // pthread_types.h:269:1:
  155. X_PT_CONDATTR_DEAD = 0xDEAD0006 // pthread_types.h:197:1:
  156. X_PT_CONDATTR_MAGIC = 0x66660006 // pthread_types.h:196:1:
  157. X_PT_COND_DEAD = 0xDEAD0005 // pthread_types.h:182:1:
  158. X_PT_COND_MAGIC = 0x55550005 // pthread_types.h:181:1:
  159. X_PT_MUTEXATTR_DEAD = 0xDEAD0004 // pthread_types.h:167:1:
  160. X_PT_MUTEXATTR_MAGIC = 0x44440004 // pthread_types.h:166:1:
  161. X_PT_MUTEX_DEAD = 0xDEAD0003 // pthread_types.h:139:1:
  162. X_PT_MUTEX_MAGIC = 0x33330003 // pthread_types.h:138:1:
  163. X_PT_RWLOCKATTR_DEAD = 0xDEAD0909 // pthread_types.h:253:1:
  164. X_PT_RWLOCKATTR_MAGIC = 0x99990909 // pthread_types.h:252:1:
  165. X_PT_RWLOCK_DEAD = 0xDEAD0009 // pthread_types.h:236:1:
  166. X_PT_RWLOCK_MAGIC = 0x99990009 // pthread_types.h:235:1:
  167. X_PT_SPINLOCK_DEAD = 0xDEAD0007 // pthread_types.h:213:1:
  168. X_PT_SPINLOCK_MAGIC = 0x77770007 // pthread_types.h:212:1:
  169. X_PT_SPINLOCK_PSHARED = 0x00000001 // pthread_types.h:214:1:
  170. X_QUAD_HIGHWORD = 1 // endian.h:84:1:
  171. X_QUAD_LOWWORD = 0 // endian.h:85:1:
  172. X_SCHED_H_ = 0 // sched.h:33:1:
  173. X_SYS_ANSI_H_ = 0 // ansi.h:33:1:
  174. X_SYS_BSWAP_H_ = 0 // bswap.h:6:1:
  175. X_SYS_CDEFS_ELF_H_ = 0 // cdefs_elf.h:31:1:
  176. X_SYS_CDEFS_H_ = 0 // cdefs.h:37:1:
  177. X_SYS_COMMON_ANSI_H_ = 0 // common_ansi.h:33:1:
  178. X_SYS_COMMON_INT_LIMITS_H_ = 0 // common_int_limits.h:33:1:
  179. X_SYS_COMMON_INT_MWGWTYPES_H_ = 0 // common_int_mwgwtypes.h:33:1:
  180. X_SYS_COMMON_INT_TYPES_H_ = 0 // common_int_types.h:33:1:
  181. X_SYS_ENDIAN_H_ = 0 // endian.h:35:1:
  182. X_SYS_FD_SET_H_ = 0 // fd_set.h:35:1:
  183. X_SYS_IDTYPE_H_ = 0 // idtype.h:32:1:
  184. X_SYS_NULL_H_ = 0 // null.h:9:1:
  185. X_SYS_SCHED_H_ = 0 // sched.h:70:1:
  186. X_SYS_SELECT_H_ = 0 // select.h:35:1:
  187. X_SYS_SIGTYPES_H_ = 0 // sigtypes.h:40:1:
  188. X_SYS_STDINT_H_ = 0 // stdint.h:33:1:
  189. X_SYS_TIMESPEC_H_ = 0 // timespec.h:38:1:
  190. X_SYS_TIME_H_ = 0 // time.h:35:1:
  191. X_SYS_TYPES_H_ = 0 // types.h:40:1:
  192. X_TIME_H_ = 0 // time.h:40:1:
  193. X_X86_64_BSWAP_H_ = 0 // bswap.h:6:1:
  194. X_X86_64_CDEFS_H_ = 0 // cdefs.h:4:1:
  195. X_X86_64_TYPES_H_ = 0 // types.h:35:1:
  196. )
  197. // $NetBSD: idtype.h,v 1.5 2016/04/09 17:02:51 riastradh Exp $
  198. // -
  199. // Copyright (c) 2016 The NetBSD Foundation, Inc.
  200. // All rights reserved.
  201. //
  202. // This code is derived from software contributed to The NetBSD Foundation
  203. // by Christos Zoulas.
  204. //
  205. // Redistribution and use in source and binary forms, with or without
  206. // modification, are permitted provided that the following conditions
  207. // are met:
  208. // 1. Redistributions of source code must retain the above copyright
  209. // notice, this list of conditions and the following disclaimer.
  210. // 2. Redistributions in binary form must reproduce the above copyright
  211. // notice, this list of conditions and the following disclaimer in the
  212. // documentation and/or other materials provided with the distribution.
  213. //
  214. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  215. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  216. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  217. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  218. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  219. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  220. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  221. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  222. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  223. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  224. // POSSIBILITY OF SUCH DAMAGE.
  225. // Using the solaris constants, some of them are not applicable to us
  226. // Do not re-order the list, or add elements in the middle as this will
  227. // break the ABI of the system calls using this. We set a high private
  228. // maximum so that new values can be added in the future without
  229. // changing the width of the type.
  230. const ( /* idtype.h:41:1: */
  231. P_MYID = -1 // Me/my process group
  232. P_ALL = 0 // All processes.
  233. P_PID = 1 // A process identifier.
  234. P_LWPID = 2 // An LWP identifier.
  235. P_PPID = 3 // A parent process identifier.
  236. P_PGID = 4 // A process group identifier.
  237. P_SID = 5 // A session identifier.
  238. P_CID = 6 // A scheduling class identifier.
  239. P_UID = 7 // A user identifier.
  240. P_GID = 8 // A group identifier.
  241. P_TASKID = 9 // A task identifier.
  242. P_PROJID = 10 // A project identifier.
  243. P_POOLID = 11 // A pool identifier.
  244. P_ZONEID = 12 // A zone identifier.
  245. P_CTID = 13 // A (process) contract identifier.
  246. P_CPUID = 14 // CPU identifier.
  247. P_PSETID = 15 // Processor set identifier.
  248. X_P_MAXIDTYPE = 2147483647
  249. )
  250. type Ptrdiff_t = int64 /* <builtin>:3:26 */
  251. type Size_t = uint64 /* <builtin>:9:23 */
  252. type Wchar_t = int32 /* <builtin>:15:24 */
  253. type X__int128_t = struct {
  254. Flo int64
  255. Fhi int64
  256. } /* <builtin>:21:43 */ // must match modernc.org/mathutil.Int128
  257. type X__uint128_t = struct {
  258. Flo uint64
  259. Fhi uint64
  260. } /* <builtin>:22:44 */ // must match modernc.org/mathutil.Int128
  261. type X__builtin_va_list = uintptr /* <builtin>:46:14 */
  262. type X__float128 = float64 /* <builtin>:47:21 */
  263. // return true if value 'a' fits in type 't'
  264. // $NetBSD: time.h,v 1.47 2016/10/04 09:41:41 kamil Exp $
  265. // Copyright (c) 1989, 1993
  266. // The Regents of the University of California. All rights reserved.
  267. // (c) UNIX System Laboratories, Inc.
  268. // All or some portions of this file are derived from material licensed
  269. // to the University of California by American Telephone and Telegraph
  270. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  271. // the permission of UNIX System Laboratories, Inc.
  272. //
  273. // Redistribution and use in source and binary forms, with or without
  274. // modification, are permitted provided that the following conditions
  275. // are met:
  276. // 1. Redistributions of source code must retain the above copyright
  277. // notice, this list of conditions and the following disclaimer.
  278. // 2. Redistributions in binary form must reproduce the above copyright
  279. // notice, this list of conditions and the following disclaimer in the
  280. // documentation and/or other materials provided with the distribution.
  281. // 3. Neither the name of the University nor the names of its contributors
  282. // may be used to endorse or promote products derived from this software
  283. // without specific prior written permission.
  284. //
  285. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  286. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  287. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  288. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  289. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  290. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  291. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  292. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  293. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  294. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  295. // SUCH DAMAGE.
  296. //
  297. // @(#)time.h 8.3 (Berkeley) 1/21/94
  298. // $NetBSD: cdefs.h,v 1.141 2019/02/21 21:34:05 christos Exp $
  299. // * Copyright (c) 1991, 1993
  300. // The Regents of the University of California. All rights reserved.
  301. //
  302. // This code is derived from software contributed to Berkeley by
  303. // Berkeley Software Design, Inc.
  304. //
  305. // Redistribution and use in source and binary forms, with or without
  306. // modification, are permitted provided that the following conditions
  307. // are met:
  308. // 1. Redistributions of source code must retain the above copyright
  309. // notice, this list of conditions and the following disclaimer.
  310. // 2. Redistributions in binary form must reproduce the above copyright
  311. // notice, this list of conditions and the following disclaimer in the
  312. // documentation and/or other materials provided with the distribution.
  313. // 3. Neither the name of the University nor the names of its contributors
  314. // may be used to endorse or promote products derived from this software
  315. // without specific prior written permission.
  316. //
  317. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  318. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  319. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  320. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  321. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  322. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  323. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  324. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  325. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  326. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  327. // SUCH DAMAGE.
  328. //
  329. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  330. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  331. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  332. // Public domain.
  333. //
  334. // NOTE: Do not protect this header against multiple inclusion. Doing
  335. // so can have subtle side-effects due to header file inclusion order
  336. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  337. // protect each CPP macro that we want to supply.
  338. // Feature-test macros are defined by several standards, and allow an
  339. // application to specify what symbols they want the system headers to
  340. // expose, and hence what standard they want them to conform to.
  341. // There are two classes of feature-test macros. The first class
  342. // specify complete standards, and if one of these is defined, header
  343. // files will try to conform to the relevant standard. They are:
  344. //
  345. // ANSI macros:
  346. // _ANSI_SOURCE ANSI C89
  347. //
  348. // POSIX macros:
  349. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  350. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  351. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  352. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  353. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  354. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  355. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  356. //
  357. // X/Open macros:
  358. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  359. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  360. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  361. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  362. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  363. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  364. //
  365. // NetBSD macros:
  366. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  367. //
  368. // If more than one of these "major" feature-test macros is defined,
  369. // then the set of facilities provided (and namespace used) is the
  370. // union of that specified by the relevant standards, and in case of
  371. // conflict, the earlier standard in the above list has precedence (so
  372. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  373. // of rename() that's used is the POSIX one). If none of the "major"
  374. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  375. //
  376. // There are also "minor" feature-test macros, which enable extra
  377. // functionality in addition to some base standard. They should be
  378. // defined along with one of the "major" macros. The "minor" macros
  379. // are:
  380. //
  381. // _REENTRANT
  382. // _ISOC99_SOURCE
  383. // _ISOC11_SOURCE
  384. // _LARGEFILE_SOURCE Large File Support
  385. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  386. // $NetBSD: ansi.h,v 1.11 2019/05/07 03:49:26 kamil Exp $
  387. // $NetBSD: common_ansi.h,v 1.1 2014/08/19 07:27:31 matt Exp $
  388. // -
  389. // Copyright (c) 2014 The NetBSD Foundation, Inc.
  390. // All rights reserved.
  391. //
  392. // This code is derived from software contributed to The NetBSD Foundation
  393. // by Matt Thomas of 3am Software Foundry.
  394. //
  395. // Redistribution and use in source and binary forms, with or without
  396. // modification, are permitted provided that the following conditions
  397. // are met:
  398. // 1. Redistributions of source code must retain the above copyright
  399. // notice, this list of conditions and the following disclaimer.
  400. // 2. Redistributions in binary form must reproduce the above copyright
  401. // notice, this list of conditions and the following disclaimer in the
  402. // documentation and/or other materials provided with the distribution.
  403. //
  404. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  405. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  406. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  407. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  408. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  409. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  410. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  411. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  412. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  413. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  414. // POSSIBILITY OF SUCH DAMAGE.
  415. // $NetBSD: cdefs.h,v 1.141 2019/02/21 21:34:05 christos Exp $
  416. // * Copyright (c) 1991, 1993
  417. // The Regents of the University of California. All rights reserved.
  418. //
  419. // This code is derived from software contributed to Berkeley by
  420. // Berkeley Software Design, Inc.
  421. //
  422. // Redistribution and use in source and binary forms, with or without
  423. // modification, are permitted provided that the following conditions
  424. // are met:
  425. // 1. Redistributions of source code must retain the above copyright
  426. // notice, this list of conditions and the following disclaimer.
  427. // 2. Redistributions in binary form must reproduce the above copyright
  428. // notice, this list of conditions and the following disclaimer in the
  429. // documentation and/or other materials provided with the distribution.
  430. // 3. Neither the name of the University nor the names of its contributors
  431. // may be used to endorse or promote products derived from this software
  432. // without specific prior written permission.
  433. //
  434. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  435. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  436. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  437. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  438. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  439. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  440. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  441. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  442. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  443. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  444. // SUCH DAMAGE.
  445. //
  446. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  447. // $NetBSD: int_types.h,v 1.7 2014/07/25 21:43:13 joerg Exp $
  448. // -
  449. // Copyright (c) 1990 The Regents of the University of California.
  450. // All rights reserved.
  451. //
  452. // Redistribution and use in source and binary forms, with or without
  453. // modification, are permitted provided that the following conditions
  454. // are met:
  455. // 1. Redistributions of source code must retain the above copyright
  456. // notice, this list of conditions and the following disclaimer.
  457. // 2. Redistributions in binary form must reproduce the above copyright
  458. // notice, this list of conditions and the following disclaimer in the
  459. // documentation and/or other materials provided with the distribution.
  460. // 3. Neither the name of the University nor the names of its contributors
  461. // may be used to endorse or promote products derived from this software
  462. // without specific prior written permission.
  463. //
  464. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  465. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  466. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  467. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  468. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  469. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  470. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  471. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  472. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  473. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  474. // SUCH DAMAGE.
  475. //
  476. // from: @(#)types.h 7.5 (Berkeley) 3/9/91
  477. // $NetBSD: common_int_types.h,v 1.1 2014/07/25 21:43:13 joerg Exp $
  478. // -
  479. // Copyright (c) 2014 The NetBSD Foundation, Inc.
  480. // All rights reserved.
  481. //
  482. // This code is derived from software contributed to The NetBSD Foundation
  483. // by Joerg Sonnenberger.
  484. //
  485. // Redistribution and use in source and binary forms, with or without
  486. // modification, are permitted provided that the following conditions
  487. // are met:
  488. // 1. Redistributions of source code must retain the above copyright
  489. // notice, this list of conditions and the following disclaimer.
  490. // 2. Redistributions in binary form must reproduce the above copyright
  491. // notice, this list of conditions and the following disclaimer in the
  492. // documentation and/or other materials provided with the distribution.
  493. //
  494. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  495. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  496. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  497. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  498. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  499. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  500. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  501. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  502. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  503. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  504. // POSSIBILITY OF SUCH DAMAGE.
  505. // 7.18.1 Integer types
  506. // 7.18.1.1 Exact-width integer types
  507. type X__int8_t = int8 /* common_int_types.h:45:27 */
  508. type X__uint8_t = uint8 /* common_int_types.h:46:27 */
  509. type X__int16_t = int16 /* common_int_types.h:47:27 */
  510. type X__uint16_t = uint16 /* common_int_types.h:48:27 */
  511. type X__int32_t = int32 /* common_int_types.h:49:27 */
  512. type X__uint32_t = uint32 /* common_int_types.h:50:27 */
  513. type X__int64_t = int64 /* common_int_types.h:51:27 */
  514. type X__uint64_t = uint64 /* common_int_types.h:52:27 */
  515. // 7.18.1.4 Integer types capable of holding object pointers
  516. type X__intptr_t = int64 /* common_int_types.h:58:27 */
  517. type X__uintptr_t = uint64 /* common_int_types.h:59:26 */
  518. // Types which are fundamental to the implementation and may appear in
  519. // more than one standard header are defined here. Standard headers
  520. // then use:
  521. // #ifdef _BSD_SIZE_T_
  522. // typedef _BSD_SIZE_T_ size_t;
  523. // #undef _BSD_SIZE_T_
  524. // #endif
  525. // $NetBSD: null.h,v 1.9 2010/07/06 11:56:20 kleink Exp $
  526. // Written by Klaus Klein <kleink@NetBSD.org>, December 22, 1999.
  527. // Public domain.
  528. type Clock_t = uint32 /* time.h:49:23 */
  529. type Time_t = X__int64_t /* time.h:54:22 */
  530. type Clockid_t = int32 /* time.h:64:25 */
  531. type Timer_t = int32 /* time.h:69:23 */
  532. type Tm = struct {
  533. Ftm_sec int32
  534. Ftm_min int32
  535. Ftm_hour int32
  536. Ftm_mday int32
  537. Ftm_mon int32
  538. Ftm_year int32
  539. Ftm_wday int32
  540. Ftm_yday int32
  541. Ftm_isdst int32
  542. F__ccgo_pad1 [4]byte
  543. Ftm_gmtoff int64
  544. Ftm_zone uintptr
  545. } /* time.h:75:1 */
  546. // ISO/IEC 9899:201x 7.27.1/3 Components of time
  547. // $NetBSD: timespec.h,v 1.1 2015/07/31 12:51:32 kamil Exp $
  548. // Copyright (c) 1982, 1986, 1993
  549. // The Regents of the University of California. All rights reserved.
  550. //
  551. // Redistribution and use in source and binary forms, with or without
  552. // modification, are permitted provided that the following conditions
  553. // are met:
  554. // 1. Redistributions of source code must retain the above copyright
  555. // notice, this list of conditions and the following disclaimer.
  556. // 2. Redistributions in binary form must reproduce the above copyright
  557. // notice, this list of conditions and the following disclaimer in the
  558. // documentation and/or other materials provided with the distribution.
  559. // 3. Neither the name of the University nor the names of its contributors
  560. // may be used to endorse or promote products derived from this software
  561. // without specific prior written permission.
  562. //
  563. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  564. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  565. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  566. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  567. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  568. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  569. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  570. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  571. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  572. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  573. // SUCH DAMAGE.
  574. //
  575. // @(#)time.h 8.5 (Berkeley) 5/4/95
  576. //
  577. // Extracted by Kamil Rytarowski from:
  578. // NetBSD: src/sys/sys/time.h,v 1.69 2015/05/19 23:35:11 riastradh Exp
  579. // $NetBSD: ansi.h,v 1.14 2011/07/17 20:54:54 joerg Exp $
  580. // -
  581. // Copyright (c) 2000, 2001, 2002 The NetBSD Foundation, Inc.
  582. // All rights reserved.
  583. //
  584. // This code is derived from software contributed to The NetBSD Foundation
  585. // by Jun-ichiro itojun Hagino and by Klaus Klein.
  586. //
  587. // Redistribution and use in source and binary forms, with or without
  588. // modification, are permitted provided that the following conditions
  589. // are met:
  590. // 1. Redistributions of source code must retain the above copyright
  591. // notice, this list of conditions and the following disclaimer.
  592. // 2. Redistributions in binary form must reproduce the above copyright
  593. // notice, this list of conditions and the following disclaimer in the
  594. // documentation and/or other materials provided with the distribution.
  595. //
  596. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  597. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  598. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  599. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  600. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  601. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  602. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  603. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  604. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  605. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  606. // POSSIBILITY OF SUCH DAMAGE.
  607. // $NetBSD: ansi.h,v 1.11 2019/05/07 03:49:26 kamil Exp $
  608. // $NetBSD: common_ansi.h,v 1.1 2014/08/19 07:27:31 matt Exp $
  609. // -
  610. // Copyright (c) 2014 The NetBSD Foundation, Inc.
  611. // All rights reserved.
  612. //
  613. // This code is derived from software contributed to The NetBSD Foundation
  614. // by Matt Thomas of 3am Software Foundry.
  615. //
  616. // Redistribution and use in source and binary forms, with or without
  617. // modification, are permitted provided that the following conditions
  618. // are met:
  619. // 1. Redistributions of source code must retain the above copyright
  620. // notice, this list of conditions and the following disclaimer.
  621. // 2. Redistributions in binary form must reproduce the above copyright
  622. // notice, this list of conditions and the following disclaimer in the
  623. // documentation and/or other materials provided with the distribution.
  624. //
  625. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  626. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  627. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  628. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  629. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  630. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  631. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  632. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  633. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  634. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  635. // POSSIBILITY OF SUCH DAMAGE.
  636. type X__caddr_t = uintptr /* ansi.h:37:14 */ // core address
  637. type X__gid_t = X__uint32_t /* ansi.h:38:20 */ // group id
  638. type X__in_addr_t = X__uint32_t /* ansi.h:39:20 */ // IP(v4) address
  639. type X__in_port_t = X__uint16_t /* ansi.h:40:20 */ // "Internet" port number
  640. type X__mode_t = X__uint32_t /* ansi.h:41:20 */ // file permissions
  641. type X__off_t = X__int64_t /* ansi.h:42:19 */ // file offset
  642. type X__pid_t = X__int32_t /* ansi.h:43:19 */ // process id
  643. type X__sa_family_t = X__uint8_t /* ansi.h:44:19 */ // socket address family
  644. type X__socklen_t = uint32 /* ansi.h:45:22 */ // socket-related datum length
  645. type X__uid_t = X__uint32_t /* ansi.h:46:20 */ // user id
  646. type X__fsblkcnt_t = X__uint64_t /* ansi.h:47:20 */ // fs block count (statvfs)
  647. type X__fsfilcnt_t = X__uint64_t /* ansi.h:48:20 */
  648. type X__wctrans_t = uintptr /* ansi.h:51:32 */
  649. type X__wctype_t = uintptr /* ansi.h:54:31 */
  650. // mbstate_t is an opaque object to keep conversion state, during multibyte
  651. // stream conversions. The content must not be referenced by user programs.
  652. type X__mbstate_t = struct {
  653. F__mbstateL X__int64_t
  654. F__ccgo_pad1 [120]byte
  655. } /* ansi.h:63:3 */
  656. type X__va_list = X__builtin_va_list /* ansi.h:72:27 */
  657. type Timespec = struct {
  658. Ftv_sec Time_t
  659. Ftv_nsec int64
  660. } /* timespec.h:47:1 */
  661. // $NetBSD: time.h,v 1.79 2017/01/17 15:28:34 maya Exp $
  662. // Copyright (c) 1982, 1986, 1993
  663. // The Regents of the University of California. All rights reserved.
  664. //
  665. // Redistribution and use in source and binary forms, with or without
  666. // modification, are permitted provided that the following conditions
  667. // are met:
  668. // 1. Redistributions of source code must retain the above copyright
  669. // notice, this list of conditions and the following disclaimer.
  670. // 2. Redistributions in binary form must reproduce the above copyright
  671. // notice, this list of conditions and the following disclaimer in the
  672. // documentation and/or other materials provided with the distribution.
  673. // 3. Neither the name of the University nor the names of its contributors
  674. // may be used to endorse or promote products derived from this software
  675. // without specific prior written permission.
  676. //
  677. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  678. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  679. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  680. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  681. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  682. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  683. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  684. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  685. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  686. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  687. // SUCH DAMAGE.
  688. //
  689. // @(#)time.h 8.5 (Berkeley) 5/4/95
  690. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  691. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  692. // Public domain.
  693. //
  694. // NOTE: Do not protect this header against multiple inclusion. Doing
  695. // so can have subtle side-effects due to header file inclusion order
  696. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  697. // protect each CPP macro that we want to supply.
  698. // Feature-test macros are defined by several standards, and allow an
  699. // application to specify what symbols they want the system headers to
  700. // expose, and hence what standard they want them to conform to.
  701. // There are two classes of feature-test macros. The first class
  702. // specify complete standards, and if one of these is defined, header
  703. // files will try to conform to the relevant standard. They are:
  704. //
  705. // ANSI macros:
  706. // _ANSI_SOURCE ANSI C89
  707. //
  708. // POSIX macros:
  709. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  710. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  711. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  712. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  713. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  714. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  715. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  716. //
  717. // X/Open macros:
  718. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  719. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  720. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  721. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  722. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  723. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  724. //
  725. // NetBSD macros:
  726. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  727. //
  728. // If more than one of these "major" feature-test macros is defined,
  729. // then the set of facilities provided (and namespace used) is the
  730. // union of that specified by the relevant standards, and in case of
  731. // conflict, the earlier standard in the above list has precedence (so
  732. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  733. // of rename() that's used is the POSIX one). If none of the "major"
  734. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  735. //
  736. // There are also "minor" feature-test macros, which enable extra
  737. // functionality in addition to some base standard. They should be
  738. // defined along with one of the "major" macros. The "minor" macros
  739. // are:
  740. //
  741. // _REENTRANT
  742. // _ISOC99_SOURCE
  743. // _ISOC11_SOURCE
  744. // _LARGEFILE_SOURCE Large File Support
  745. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  746. // $NetBSD: types.h,v 1.102 2018/11/06 16:26:44 maya Exp $
  747. // -
  748. // Copyright (c) 1982, 1986, 1991, 1993, 1994
  749. // The Regents of the University of California. All rights reserved.
  750. // (c) UNIX System Laboratories, Inc.
  751. // All or some portions of this file are derived from material licensed
  752. // to the University of California by American Telephone and Telegraph
  753. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  754. // the permission of UNIX System Laboratories, Inc.
  755. //
  756. // Redistribution and use in source and binary forms, with or without
  757. // modification, are permitted provided that the following conditions
  758. // are met:
  759. // 1. Redistributions of source code must retain the above copyright
  760. // notice, this list of conditions and the following disclaimer.
  761. // 2. Redistributions in binary form must reproduce the above copyright
  762. // notice, this list of conditions and the following disclaimer in the
  763. // documentation and/or other materials provided with the distribution.
  764. // 3. Neither the name of the University nor the names of its contributors
  765. // may be used to endorse or promote products derived from this software
  766. // without specific prior written permission.
  767. //
  768. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  769. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  770. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  771. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  772. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  773. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  774. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  775. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  776. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  777. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  778. // SUCH DAMAGE.
  779. //
  780. // @(#)types.h 8.4 (Berkeley) 1/21/94
  781. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  782. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  783. // Public domain.
  784. //
  785. // NOTE: Do not protect this header against multiple inclusion. Doing
  786. // so can have subtle side-effects due to header file inclusion order
  787. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  788. // protect each CPP macro that we want to supply.
  789. // Feature-test macros are defined by several standards, and allow an
  790. // application to specify what symbols they want the system headers to
  791. // expose, and hence what standard they want them to conform to.
  792. // There are two classes of feature-test macros. The first class
  793. // specify complete standards, and if one of these is defined, header
  794. // files will try to conform to the relevant standard. They are:
  795. //
  796. // ANSI macros:
  797. // _ANSI_SOURCE ANSI C89
  798. //
  799. // POSIX macros:
  800. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  801. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  802. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  803. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  804. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  805. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  806. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  807. //
  808. // X/Open macros:
  809. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  810. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  811. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  812. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  813. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  814. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  815. //
  816. // NetBSD macros:
  817. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  818. //
  819. // If more than one of these "major" feature-test macros is defined,
  820. // then the set of facilities provided (and namespace used) is the
  821. // union of that specified by the relevant standards, and in case of
  822. // conflict, the earlier standard in the above list has precedence (so
  823. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  824. // of rename() that's used is the POSIX one). If none of the "major"
  825. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  826. //
  827. // There are also "minor" feature-test macros, which enable extra
  828. // functionality in addition to some base standard. They should be
  829. // defined along with one of the "major" macros. The "minor" macros
  830. // are:
  831. //
  832. // _REENTRANT
  833. // _ISOC99_SOURCE
  834. // _ISOC11_SOURCE
  835. // _LARGEFILE_SOURCE Large File Support
  836. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  837. // Machine type dependent parameters.
  838. // $NetBSD: types.h,v 1.60 2019/04/06 03:06:24 thorpej Exp $
  839. // -
  840. // Copyright (c) 1990 The Regents of the University of California.
  841. // All rights reserved.
  842. //
  843. // Redistribution and use in source and binary forms, with or without
  844. // modification, are permitted provided that the following conditions
  845. // are met:
  846. // 1. Redistributions of source code must retain the above copyright
  847. // notice, this list of conditions and the following disclaimer.
  848. // 2. Redistributions in binary form must reproduce the above copyright
  849. // notice, this list of conditions and the following disclaimer in the
  850. // documentation and/or other materials provided with the distribution.
  851. // 3. Neither the name of the University nor the names of its contributors
  852. // may be used to endorse or promote products derived from this software
  853. // without specific prior written permission.
  854. //
  855. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  856. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  857. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  858. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  859. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  860. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  861. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  862. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  863. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  864. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  865. // SUCH DAMAGE.
  866. //
  867. // @(#)types.h 7.5 (Berkeley) 3/9/91
  868. // $NetBSD: cdefs.h,v 1.141 2019/02/21 21:34:05 christos Exp $
  869. // * Copyright (c) 1991, 1993
  870. // The Regents of the University of California. All rights reserved.
  871. //
  872. // This code is derived from software contributed to Berkeley by
  873. // Berkeley Software Design, Inc.
  874. //
  875. // Redistribution and use in source and binary forms, with or without
  876. // modification, are permitted provided that the following conditions
  877. // are met:
  878. // 1. Redistributions of source code must retain the above copyright
  879. // notice, this list of conditions and the following disclaimer.
  880. // 2. Redistributions in binary form must reproduce the above copyright
  881. // notice, this list of conditions and the following disclaimer in the
  882. // documentation and/or other materials provided with the distribution.
  883. // 3. Neither the name of the University nor the names of its contributors
  884. // may be used to endorse or promote products derived from this software
  885. // without specific prior written permission.
  886. //
  887. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  888. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  889. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  890. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  891. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  892. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  893. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  894. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  895. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  896. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  897. // SUCH DAMAGE.
  898. //
  899. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  900. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  901. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  902. // Public domain.
  903. //
  904. // NOTE: Do not protect this header against multiple inclusion. Doing
  905. // so can have subtle side-effects due to header file inclusion order
  906. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  907. // protect each CPP macro that we want to supply.
  908. // Feature-test macros are defined by several standards, and allow an
  909. // application to specify what symbols they want the system headers to
  910. // expose, and hence what standard they want them to conform to.
  911. // There are two classes of feature-test macros. The first class
  912. // specify complete standards, and if one of these is defined, header
  913. // files will try to conform to the relevant standard. They are:
  914. //
  915. // ANSI macros:
  916. // _ANSI_SOURCE ANSI C89
  917. //
  918. // POSIX macros:
  919. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  920. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  921. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  922. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  923. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  924. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  925. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  926. //
  927. // X/Open macros:
  928. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  929. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  930. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  931. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  932. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  933. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  934. //
  935. // NetBSD macros:
  936. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  937. //
  938. // If more than one of these "major" feature-test macros is defined,
  939. // then the set of facilities provided (and namespace used) is the
  940. // union of that specified by the relevant standards, and in case of
  941. // conflict, the earlier standard in the above list has precedence (so
  942. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  943. // of rename() that's used is the POSIX one). If none of the "major"
  944. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  945. //
  946. // There are also "minor" feature-test macros, which enable extra
  947. // functionality in addition to some base standard. They should be
  948. // defined along with one of the "major" macros. The "minor" macros
  949. // are:
  950. //
  951. // _REENTRANT
  952. // _ISOC99_SOURCE
  953. // _ISOC11_SOURCE
  954. // _LARGEFILE_SOURCE Large File Support
  955. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  956. // $NetBSD: int_types.h,v 1.7 2014/07/25 21:43:13 joerg Exp $
  957. // -
  958. // Copyright (c) 1990 The Regents of the University of California.
  959. // All rights reserved.
  960. //
  961. // Redistribution and use in source and binary forms, with or without
  962. // modification, are permitted provided that the following conditions
  963. // are met:
  964. // 1. Redistributions of source code must retain the above copyright
  965. // notice, this list of conditions and the following disclaimer.
  966. // 2. Redistributions in binary form must reproduce the above copyright
  967. // notice, this list of conditions and the following disclaimer in the
  968. // documentation and/or other materials provided with the distribution.
  969. // 3. Neither the name of the University nor the names of its contributors
  970. // may be used to endorse or promote products derived from this software
  971. // without specific prior written permission.
  972. //
  973. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  974. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  975. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  976. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  977. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  978. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  979. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  980. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  981. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  982. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  983. // SUCH DAMAGE.
  984. //
  985. // from: @(#)types.h 7.5 (Berkeley) 3/9/91
  986. type X__register_t = int64 /* types.h:68:19 */
  987. type X__cpu_simple_lock_nv_t = uint8 /* types.h:69:24 */
  988. // __cpu_simple_lock_t used to be a full word.
  989. // The amd64 does not have strict alignment requirements.
  990. // $NetBSD: ansi.h,v 1.11 2019/05/07 03:49:26 kamil Exp $
  991. // $NetBSD: common_ansi.h,v 1.1 2014/08/19 07:27:31 matt Exp $
  992. // -
  993. // Copyright (c) 2014 The NetBSD Foundation, Inc.
  994. // All rights reserved.
  995. //
  996. // This code is derived from software contributed to The NetBSD Foundation
  997. // by Matt Thomas of 3am Software Foundry.
  998. //
  999. // Redistribution and use in source and binary forms, with or without
  1000. // modification, are permitted provided that the following conditions
  1001. // are met:
  1002. // 1. Redistributions of source code must retain the above copyright
  1003. // notice, this list of conditions and the following disclaimer.
  1004. // 2. Redistributions in binary form must reproduce the above copyright
  1005. // notice, this list of conditions and the following disclaimer in the
  1006. // documentation and/or other materials provided with the distribution.
  1007. //
  1008. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  1009. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  1010. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  1011. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  1012. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  1013. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  1014. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  1015. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1016. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  1017. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  1018. // POSSIBILITY OF SUCH DAMAGE.
  1019. // $NetBSD: int_types.h,v 1.7 2014/07/25 21:43:13 joerg Exp $
  1020. // -
  1021. // Copyright (c) 1990 The Regents of the University of California.
  1022. // All rights reserved.
  1023. //
  1024. // Redistribution and use in source and binary forms, with or without
  1025. // modification, are permitted provided that the following conditions
  1026. // are met:
  1027. // 1. Redistributions of source code must retain the above copyright
  1028. // notice, this list of conditions and the following disclaimer.
  1029. // 2. Redistributions in binary form must reproduce the above copyright
  1030. // notice, this list of conditions and the following disclaimer in the
  1031. // documentation and/or other materials provided with the distribution.
  1032. // 3. Neither the name of the University nor the names of its contributors
  1033. // may be used to endorse or promote products derived from this software
  1034. // without specific prior written permission.
  1035. //
  1036. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1037. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1038. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1039. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1040. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1041. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1042. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1043. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1044. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1045. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1046. // SUCH DAMAGE.
  1047. //
  1048. // from: @(#)types.h 7.5 (Berkeley) 3/9/91
  1049. // $NetBSD: ansi.h,v 1.14 2011/07/17 20:54:54 joerg Exp $
  1050. // -
  1051. // Copyright (c) 2000, 2001, 2002 The NetBSD Foundation, Inc.
  1052. // All rights reserved.
  1053. //
  1054. // This code is derived from software contributed to The NetBSD Foundation
  1055. // by Jun-ichiro itojun Hagino and by Klaus Klein.
  1056. //
  1057. // Redistribution and use in source and binary forms, with or without
  1058. // modification, are permitted provided that the following conditions
  1059. // are met:
  1060. // 1. Redistributions of source code must retain the above copyright
  1061. // notice, this list of conditions and the following disclaimer.
  1062. // 2. Redistributions in binary form must reproduce the above copyright
  1063. // notice, this list of conditions and the following disclaimer in the
  1064. // documentation and/or other materials provided with the distribution.
  1065. //
  1066. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  1067. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  1068. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  1069. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  1070. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  1071. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  1072. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  1073. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1074. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  1075. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  1076. // POSSIBILITY OF SUCH DAMAGE.
  1077. type Int8_t = X__int8_t /* types.h:54:18 */
  1078. type Uint8_t = X__uint8_t /* types.h:59:19 */
  1079. type Int16_t = X__int16_t /* types.h:64:19 */
  1080. type Uint16_t = X__uint16_t /* types.h:69:20 */
  1081. type Int32_t = X__int32_t /* types.h:74:19 */
  1082. type Uint32_t = X__uint32_t /* types.h:79:20 */
  1083. type Int64_t = X__int64_t /* types.h:84:19 */
  1084. type Uint64_t = X__uint64_t /* types.h:89:20 */
  1085. type U_int8_t = Uint8_t /* types.h:93:18 */
  1086. type U_int16_t = Uint16_t /* types.h:94:18 */
  1087. type U_int32_t = Uint32_t /* types.h:95:18 */
  1088. type U_int64_t = Uint64_t /* types.h:96:18 */
  1089. // $NetBSD: endian.h,v 1.1 2003/04/26 18:39:40 fvdl Exp $
  1090. // $NetBSD: endian.h,v 1.30 2016/02/27 21:37:35 christos Exp $
  1091. // Copyright (c) 1987, 1991, 1993
  1092. // The Regents of the University of California. All rights reserved.
  1093. //
  1094. // Redistribution and use in source and binary forms, with or without
  1095. // modification, are permitted provided that the following conditions
  1096. // are met:
  1097. // 1. Redistributions of source code must retain the above copyright
  1098. // notice, this list of conditions and the following disclaimer.
  1099. // 2. Redistributions in binary form must reproduce the above copyright
  1100. // notice, this list of conditions and the following disclaimer in the
  1101. // documentation and/or other materials provided with the distribution.
  1102. // 3. Neither the name of the University nor the names of its contributors
  1103. // may be used to endorse or promote products derived from this software
  1104. // without specific prior written permission.
  1105. //
  1106. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1107. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1108. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1109. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1110. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1111. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1112. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1113. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1114. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1115. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1116. // SUCH DAMAGE.
  1117. //
  1118. // @(#)endian.h 8.1 (Berkeley) 6/11/93
  1119. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  1120. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  1121. // Public domain.
  1122. //
  1123. // NOTE: Do not protect this header against multiple inclusion. Doing
  1124. // so can have subtle side-effects due to header file inclusion order
  1125. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  1126. // protect each CPP macro that we want to supply.
  1127. // Feature-test macros are defined by several standards, and allow an
  1128. // application to specify what symbols they want the system headers to
  1129. // expose, and hence what standard they want them to conform to.
  1130. // There are two classes of feature-test macros. The first class
  1131. // specify complete standards, and if one of these is defined, header
  1132. // files will try to conform to the relevant standard. They are:
  1133. //
  1134. // ANSI macros:
  1135. // _ANSI_SOURCE ANSI C89
  1136. //
  1137. // POSIX macros:
  1138. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  1139. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  1140. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  1141. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  1142. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  1143. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  1144. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  1145. //
  1146. // X/Open macros:
  1147. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  1148. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  1149. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  1150. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  1151. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  1152. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  1153. //
  1154. // NetBSD macros:
  1155. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  1156. //
  1157. // If more than one of these "major" feature-test macros is defined,
  1158. // then the set of facilities provided (and namespace used) is the
  1159. // union of that specified by the relevant standards, and in case of
  1160. // conflict, the earlier standard in the above list has precedence (so
  1161. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  1162. // of rename() that's used is the POSIX one). If none of the "major"
  1163. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  1164. //
  1165. // There are also "minor" feature-test macros, which enable extra
  1166. // functionality in addition to some base standard. They should be
  1167. // defined along with one of the "major" macros. The "minor" macros
  1168. // are:
  1169. //
  1170. // _REENTRANT
  1171. // _ISOC99_SOURCE
  1172. // _ISOC11_SOURCE
  1173. // _LARGEFILE_SOURCE Large File Support
  1174. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  1175. // Definitions for byte order, according to byte significance from low
  1176. // address to high.
  1177. // C-family endian-ness definitions
  1178. // $NetBSD: ansi.h,v 1.14 2011/07/17 20:54:54 joerg Exp $
  1179. // -
  1180. // Copyright (c) 2000, 2001, 2002 The NetBSD Foundation, Inc.
  1181. // All rights reserved.
  1182. //
  1183. // This code is derived from software contributed to The NetBSD Foundation
  1184. // by Jun-ichiro itojun Hagino and by Klaus Klein.
  1185. //
  1186. // Redistribution and use in source and binary forms, with or without
  1187. // modification, are permitted provided that the following conditions
  1188. // are met:
  1189. // 1. Redistributions of source code must retain the above copyright
  1190. // notice, this list of conditions and the following disclaimer.
  1191. // 2. Redistributions in binary form must reproduce the above copyright
  1192. // notice, this list of conditions and the following disclaimer in the
  1193. // documentation and/or other materials provided with the distribution.
  1194. //
  1195. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  1196. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  1197. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  1198. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  1199. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  1200. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  1201. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  1202. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1203. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  1204. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  1205. // POSSIBILITY OF SUCH DAMAGE.
  1206. // $NetBSD: cdefs.h,v 1.141 2019/02/21 21:34:05 christos Exp $
  1207. // * Copyright (c) 1991, 1993
  1208. // The Regents of the University of California. All rights reserved.
  1209. //
  1210. // This code is derived from software contributed to Berkeley by
  1211. // Berkeley Software Design, Inc.
  1212. //
  1213. // Redistribution and use in source and binary forms, with or without
  1214. // modification, are permitted provided that the following conditions
  1215. // are met:
  1216. // 1. Redistributions of source code must retain the above copyright
  1217. // notice, this list of conditions and the following disclaimer.
  1218. // 2. Redistributions in binary form must reproduce the above copyright
  1219. // notice, this list of conditions and the following disclaimer in the
  1220. // documentation and/or other materials provided with the distribution.
  1221. // 3. Neither the name of the University nor the names of its contributors
  1222. // may be used to endorse or promote products derived from this software
  1223. // without specific prior written permission.
  1224. //
  1225. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1226. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1227. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1228. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1229. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1230. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1231. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1232. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1233. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1234. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1235. // SUCH DAMAGE.
  1236. //
  1237. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  1238. // $NetBSD: types.h,v 1.102 2018/11/06 16:26:44 maya Exp $
  1239. // -
  1240. // Copyright (c) 1982, 1986, 1991, 1993, 1994
  1241. // The Regents of the University of California. All rights reserved.
  1242. // (c) UNIX System Laboratories, Inc.
  1243. // All or some portions of this file are derived from material licensed
  1244. // to the University of California by American Telephone and Telegraph
  1245. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  1246. // the permission of UNIX System Laboratories, Inc.
  1247. //
  1248. // Redistribution and use in source and binary forms, with or without
  1249. // modification, are permitted provided that the following conditions
  1250. // are met:
  1251. // 1. Redistributions of source code must retain the above copyright
  1252. // notice, this list of conditions and the following disclaimer.
  1253. // 2. Redistributions in binary form must reproduce the above copyright
  1254. // notice, this list of conditions and the following disclaimer in the
  1255. // documentation and/or other materials provided with the distribution.
  1256. // 3. Neither the name of the University nor the names of its contributors
  1257. // may be used to endorse or promote products derived from this software
  1258. // without specific prior written permission.
  1259. //
  1260. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1261. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1262. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1263. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1264. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1265. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1266. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1267. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1268. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1269. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1270. // SUCH DAMAGE.
  1271. //
  1272. // @(#)types.h 8.4 (Berkeley) 1/21/94
  1273. type In_addr_t = X__in_addr_t /* endian.h:58:21 */
  1274. type In_port_t = X__in_port_t /* endian.h:63:21 */
  1275. // $NetBSD: bswap.h,v 1.19 2015/03/12 15:28:16 christos Exp $
  1276. // Written by Manuel Bouyer. Public domain
  1277. // $NetBSD: stdint.h,v 1.8 2018/11/06 16:26:44 maya Exp $
  1278. // -
  1279. // Copyright (c) 2001, 2004 The NetBSD Foundation, Inc.
  1280. // All rights reserved.
  1281. //
  1282. // This code is derived from software contributed to The NetBSD Foundation
  1283. // by Klaus Klein.
  1284. //
  1285. // Redistribution and use in source and binary forms, with or without
  1286. // modification, are permitted provided that the following conditions
  1287. // are met:
  1288. // 1. Redistributions of source code must retain the above copyright
  1289. // notice, this list of conditions and the following disclaimer.
  1290. // 2. Redistributions in binary form must reproduce the above copyright
  1291. // notice, this list of conditions and the following disclaimer in the
  1292. // documentation and/or other materials provided with the distribution.
  1293. //
  1294. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  1295. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  1296. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  1297. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  1298. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  1299. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  1300. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  1301. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1302. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  1303. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  1304. // POSSIBILITY OF SUCH DAMAGE.
  1305. // $NetBSD: cdefs.h,v 1.141 2019/02/21 21:34:05 christos Exp $
  1306. // * Copyright (c) 1991, 1993
  1307. // The Regents of the University of California. All rights reserved.
  1308. //
  1309. // This code is derived from software contributed to Berkeley by
  1310. // Berkeley Software Design, Inc.
  1311. //
  1312. // Redistribution and use in source and binary forms, with or without
  1313. // modification, are permitted provided that the following conditions
  1314. // are met:
  1315. // 1. Redistributions of source code must retain the above copyright
  1316. // notice, this list of conditions and the following disclaimer.
  1317. // 2. Redistributions in binary form must reproduce the above copyright
  1318. // notice, this list of conditions and the following disclaimer in the
  1319. // documentation and/or other materials provided with the distribution.
  1320. // 3. Neither the name of the University nor the names of its contributors
  1321. // may be used to endorse or promote products derived from this software
  1322. // without specific prior written permission.
  1323. //
  1324. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1325. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1326. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1327. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1328. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1329. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1330. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1331. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1332. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1333. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1334. // SUCH DAMAGE.
  1335. //
  1336. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  1337. // $NetBSD: int_types.h,v 1.7 2014/07/25 21:43:13 joerg Exp $
  1338. // -
  1339. // Copyright (c) 1990 The Regents of the University of California.
  1340. // All rights reserved.
  1341. //
  1342. // Redistribution and use in source and binary forms, with or without
  1343. // modification, are permitted provided that the following conditions
  1344. // are met:
  1345. // 1. Redistributions of source code must retain the above copyright
  1346. // notice, this list of conditions and the following disclaimer.
  1347. // 2. Redistributions in binary form must reproduce the above copyright
  1348. // notice, this list of conditions and the following disclaimer in the
  1349. // documentation and/or other materials provided with the distribution.
  1350. // 3. Neither the name of the University nor the names of its contributors
  1351. // may be used to endorse or promote products derived from this software
  1352. // without specific prior written permission.
  1353. //
  1354. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1355. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1356. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1357. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1358. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1359. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1360. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1361. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1362. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1363. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1364. // SUCH DAMAGE.
  1365. //
  1366. // from: @(#)types.h 7.5 (Berkeley) 3/9/91
  1367. type Intptr_t = X__intptr_t /* stdint.h:79:20 */
  1368. type Uintptr_t = X__uintptr_t /* stdint.h:84:21 */
  1369. // $NetBSD: int_mwgwtypes.h,v 1.8 2014/07/25 21:43:13 joerg Exp $
  1370. // -
  1371. // Copyright (c) 2001 The NetBSD Foundation, Inc.
  1372. // All rights reserved.
  1373. //
  1374. // This code is derived from software contributed to The NetBSD Foundation
  1375. // by Klaus Klein.
  1376. //
  1377. // Redistribution and use in source and binary forms, with or without
  1378. // modification, are permitted provided that the following conditions
  1379. // are met:
  1380. // 1. Redistributions of source code must retain the above copyright
  1381. // notice, this list of conditions and the following disclaimer.
  1382. // 2. Redistributions in binary form must reproduce the above copyright
  1383. // notice, this list of conditions and the following disclaimer in the
  1384. // documentation and/or other materials provided with the distribution.
  1385. //
  1386. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  1387. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  1388. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  1389. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  1390. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  1391. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  1392. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  1393. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1394. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  1395. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  1396. // POSSIBILITY OF SUCH DAMAGE.
  1397. // $NetBSD: common_int_mwgwtypes.h,v 1.1 2014/07/25 21:43:13 joerg Exp $
  1398. // -
  1399. // Copyright (c) 2014 The NetBSD Foundation, Inc.
  1400. // All rights reserved.
  1401. //
  1402. // This code is derived from software contributed to The NetBSD Foundation
  1403. // by Joerg Sonnenberger.
  1404. //
  1405. // Redistribution and use in source and binary forms, with or without
  1406. // modification, are permitted provided that the following conditions
  1407. // are met:
  1408. // 1. Redistributions of source code must retain the above copyright
  1409. // notice, this list of conditions and the following disclaimer.
  1410. // 2. Redistributions in binary form must reproduce the above copyright
  1411. // notice, this list of conditions and the following disclaimer in the
  1412. // documentation and/or other materials provided with the distribution.
  1413. //
  1414. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  1415. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  1416. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  1417. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  1418. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  1419. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  1420. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  1421. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1422. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  1423. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  1424. // POSSIBILITY OF SUCH DAMAGE.
  1425. // 7.18.1 Integer types
  1426. // 7.18.1.2 Minimum-width integer types
  1427. type Int_least8_t = int8 /* common_int_mwgwtypes.h:45:32 */
  1428. type Uint_least8_t = uint8 /* common_int_mwgwtypes.h:46:32 */
  1429. type Int_least16_t = int16 /* common_int_mwgwtypes.h:47:32 */
  1430. type Uint_least16_t = uint16 /* common_int_mwgwtypes.h:48:32 */
  1431. type Int_least32_t = int32 /* common_int_mwgwtypes.h:49:32 */
  1432. type Uint_least32_t = uint32 /* common_int_mwgwtypes.h:50:32 */
  1433. type Int_least64_t = int64 /* common_int_mwgwtypes.h:51:32 */
  1434. type Uint_least64_t = uint64 /* common_int_mwgwtypes.h:52:32 */
  1435. // 7.18.1.3 Fastest minimum-width integer types
  1436. type Int_fast8_t = int32 /* common_int_mwgwtypes.h:55:32 */
  1437. type Uint_fast8_t = uint32 /* common_int_mwgwtypes.h:56:32 */
  1438. type Int_fast16_t = int32 /* common_int_mwgwtypes.h:57:32 */
  1439. type Uint_fast16_t = uint32 /* common_int_mwgwtypes.h:58:32 */
  1440. type Int_fast32_t = int32 /* common_int_mwgwtypes.h:59:32 */
  1441. type Uint_fast32_t = uint32 /* common_int_mwgwtypes.h:60:32 */
  1442. type Int_fast64_t = int64 /* common_int_mwgwtypes.h:61:32 */
  1443. type Uint_fast64_t = uint64 /* common_int_mwgwtypes.h:62:32 */
  1444. // 7.18.1.5 Greatest-width integer types
  1445. type Intmax_t = int64 /* common_int_mwgwtypes.h:66:33 */
  1446. type Uintmax_t = uint64 /* common_int_mwgwtypes.h:67:32 */
  1447. type U_char = uint8 /* types.h:101:23 */
  1448. type U_short = uint16 /* types.h:102:24 */
  1449. type U_int = uint32 /* types.h:103:22 */
  1450. type U_long = uint64 /* types.h:104:23 */
  1451. type Unchar = uint8 /* types.h:106:23 */ // Sys V compatibility
  1452. type Ushort = uint16 /* types.h:107:24 */ // Sys V compatibility
  1453. type Uint = uint32 /* types.h:108:22 */ // Sys V compatibility
  1454. type Ulong = uint64 /* types.h:109:23 */ // Sys V compatibility
  1455. type U_quad_t = Uint64_t /* types.h:112:18 */ // quads
  1456. type Quad_t = Int64_t /* types.h:113:18 */
  1457. type Qaddr_t = uintptr /* types.h:114:16 */
  1458. // The types longlong_t and u_longlong_t exist for use with the
  1459. // Sun-derived XDR routines involving these types, and their usage
  1460. // in other contexts is discouraged. Further note that these types
  1461. // may not be equivalent to "long long" and "unsigned long long",
  1462. // they are only guaranteed to be signed and unsigned 64-bit types
  1463. // respectively. Portable programs that need 64-bit types should use
  1464. // the C99 types int64_t and uint64_t instead.
  1465. type Longlong_t = Int64_t /* types.h:126:18 */ // for XDR
  1466. type U_longlong_t = Uint64_t /* types.h:127:18 */ // for XDR
  1467. type Blkcnt_t = Int64_t /* types.h:129:18 */ // fs block count
  1468. type Blksize_t = Int32_t /* types.h:130:18 */ // fs optimal block size
  1469. type Fsblkcnt_t = X__fsblkcnt_t /* types.h:133:22 */ // fs block count (statvfs)
  1470. type Fsfilcnt_t = X__fsfilcnt_t /* types.h:138:22 */ // fs file count
  1471. // We don't and shouldn't use caddr_t in the kernel anymore
  1472. type Caddr_t = X__caddr_t /* types.h:145:19 */ // core address
  1473. type Daddr_t = Int64_t /* types.h:154:18 */ // disk address
  1474. type Dev_t = Uint64_t /* types.h:157:18 */ // device number
  1475. type Fixpt_t = Uint32_t /* types.h:158:18 */ // fixed point number
  1476. type Gid_t = X__gid_t /* types.h:161:18 */ // group id
  1477. type Id_t = Uint32_t /* types.h:165:18 */ // group id, process id or user id
  1478. type Ino_t = Uint64_t /* types.h:166:18 */ // inode number
  1479. type Key_t = int64 /* types.h:167:15 */ // IPC key (for Sys V IPC)
  1480. type Mode_t = X__mode_t /* types.h:170:18 */ // permissions
  1481. type Nlink_t = Uint32_t /* types.h:174:18 */ // link count
  1482. type Off_t = X__off_t /* types.h:177:18 */ // file offset
  1483. type Pid_t = X__pid_t /* types.h:182:18 */ // process id
  1484. type Lwpid_t = Int32_t /* types.h:185:18 */ // LWP id
  1485. type Rlim_t = Uint64_t /* types.h:186:18 */ // resource limit
  1486. type Segsz_t = Int32_t /* types.h:187:18 */ // segment size
  1487. type Swblk_t = Int32_t /* types.h:188:18 */ // swap offset
  1488. type Uid_t = X__uid_t /* types.h:191:18 */ // user id
  1489. type Mqd_t = int32 /* types.h:195:14 */
  1490. type Cpuid_t = uint64 /* types.h:197:23 */
  1491. type Psetid_t = int32 /* types.h:199:14 */
  1492. type X__cpu_simple_lock_t = X__cpu_simple_lock_nv_t /* types.h:201:41 */
  1493. // Major, minor numbers, dev_t's.
  1494. type X__devmajor_t = Int32_t /* types.h:255:17 */
  1495. type X__devminor_t = Int32_t /* types.h:255:31 */
  1496. type Ssize_t = int64 /* types.h:284:24 */
  1497. type Suseconds_t = int32 /* types.h:304:27 */
  1498. type Useconds_t = uint32 /* types.h:309:26 */
  1499. // $NetBSD: fd_set.h,v 1.7 2018/06/24 12:05:40 kamil Exp $
  1500. // -
  1501. // Copyright (c) 1992, 1993
  1502. // The Regents of the University of California. All rights reserved.
  1503. //
  1504. // Redistribution and use in source and binary forms, with or without
  1505. // modification, are permitted provided that the following conditions
  1506. // are met:
  1507. // 1. Redistributions of source code must retain the above copyright
  1508. // notice, this list of conditions and the following disclaimer.
  1509. // 2. Redistributions in binary form must reproduce the above copyright
  1510. // notice, this list of conditions and the following disclaimer in the
  1511. // documentation and/or other materials provided with the distribution.
  1512. // 3. Neither the name of the University nor the names of its contributors
  1513. // may be used to endorse or promote products derived from this software
  1514. // without specific prior written permission.
  1515. //
  1516. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1517. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1518. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1519. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1520. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1521. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1522. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1523. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1524. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1525. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1526. // SUCH DAMAGE.
  1527. //
  1528. // from: @(#)types.h 8.4 (Berkeley) 1/21/94
  1529. // $NetBSD: cdefs.h,v 1.141 2019/02/21 21:34:05 christos Exp $
  1530. // * Copyright (c) 1991, 1993
  1531. // The Regents of the University of California. All rights reserved.
  1532. //
  1533. // This code is derived from software contributed to Berkeley by
  1534. // Berkeley Software Design, Inc.
  1535. //
  1536. // Redistribution and use in source and binary forms, with or without
  1537. // modification, are permitted provided that the following conditions
  1538. // are met:
  1539. // 1. Redistributions of source code must retain the above copyright
  1540. // notice, this list of conditions and the following disclaimer.
  1541. // 2. Redistributions in binary form must reproduce the above copyright
  1542. // notice, this list of conditions and the following disclaimer in the
  1543. // documentation and/or other materials provided with the distribution.
  1544. // 3. Neither the name of the University nor the names of its contributors
  1545. // may be used to endorse or promote products derived from this software
  1546. // without specific prior written permission.
  1547. //
  1548. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1549. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1550. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1551. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1552. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1553. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1554. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1555. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1556. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1557. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1558. // SUCH DAMAGE.
  1559. //
  1560. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  1561. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  1562. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  1563. // Public domain.
  1564. //
  1565. // NOTE: Do not protect this header against multiple inclusion. Doing
  1566. // so can have subtle side-effects due to header file inclusion order
  1567. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  1568. // protect each CPP macro that we want to supply.
  1569. // Feature-test macros are defined by several standards, and allow an
  1570. // application to specify what symbols they want the system headers to
  1571. // expose, and hence what standard they want them to conform to.
  1572. // There are two classes of feature-test macros. The first class
  1573. // specify complete standards, and if one of these is defined, header
  1574. // files will try to conform to the relevant standard. They are:
  1575. //
  1576. // ANSI macros:
  1577. // _ANSI_SOURCE ANSI C89
  1578. //
  1579. // POSIX macros:
  1580. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  1581. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  1582. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  1583. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  1584. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  1585. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  1586. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  1587. //
  1588. // X/Open macros:
  1589. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  1590. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  1591. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  1592. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  1593. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  1594. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  1595. //
  1596. // NetBSD macros:
  1597. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  1598. //
  1599. // If more than one of these "major" feature-test macros is defined,
  1600. // then the set of facilities provided (and namespace used) is the
  1601. // union of that specified by the relevant standards, and in case of
  1602. // conflict, the earlier standard in the above list has precedence (so
  1603. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  1604. // of rename() that's used is the POSIX one). If none of the "major"
  1605. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  1606. //
  1607. // There are also "minor" feature-test macros, which enable extra
  1608. // functionality in addition to some base standard. They should be
  1609. // defined along with one of the "major" macros. The "minor" macros
  1610. // are:
  1611. //
  1612. // _REENTRANT
  1613. // _ISOC99_SOURCE
  1614. // _ISOC11_SOURCE
  1615. // _LARGEFILE_SOURCE Large File Support
  1616. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  1617. // $NetBSD: int_types.h,v 1.7 2014/07/25 21:43:13 joerg Exp $
  1618. // -
  1619. // Copyright (c) 1990 The Regents of the University of California.
  1620. // All rights reserved.
  1621. //
  1622. // Redistribution and use in source and binary forms, with or without
  1623. // modification, are permitted provided that the following conditions
  1624. // are met:
  1625. // 1. Redistributions of source code must retain the above copyright
  1626. // notice, this list of conditions and the following disclaimer.
  1627. // 2. Redistributions in binary form must reproduce the above copyright
  1628. // notice, this list of conditions and the following disclaimer in the
  1629. // documentation and/or other materials provided with the distribution.
  1630. // 3. Neither the name of the University nor the names of its contributors
  1631. // may be used to endorse or promote products derived from this software
  1632. // without specific prior written permission.
  1633. //
  1634. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1635. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1636. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1637. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1638. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1639. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1640. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1641. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1642. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1643. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1644. // SUCH DAMAGE.
  1645. //
  1646. // from: @(#)types.h 7.5 (Berkeley) 3/9/91
  1647. // Implementation dependent defines, hidden from user space.
  1648. // POSIX does not specify them.
  1649. type X__fd_mask = X__uint32_t /* fd_set.h:46:20 */
  1650. // 32 = 2 ^ 5
  1651. // Select uses bit fields of file descriptors. These macros manipulate
  1652. // such bit fields. Note: FD_SETSIZE may be defined by the user.
  1653. type Fd_set1 = struct{ Ffds_bits [8]X__fd_mask } /* fd_set.h:66:9 */
  1654. // 32 = 2 ^ 5
  1655. // Select uses bit fields of file descriptors. These macros manipulate
  1656. // such bit fields. Note: FD_SETSIZE may be defined by the user.
  1657. type Fd_set = Fd_set1 /* fd_set.h:68:3 */
  1658. // Expose our internals if we are not required to hide them.
  1659. type Kauth_cred_t = uintptr /* types.h:318:27 */
  1660. type Pri_t = int32 /* types.h:320:13 */
  1661. // $NetBSD: pthread_types.h,v 1.23 2017/09/09 23:21:45 kamil Exp $
  1662. // -
  1663. // Copyright (c) 2001, 2008 The NetBSD Foundation, Inc.
  1664. // All rights reserved.
  1665. //
  1666. // This code is derived from software contributed to The NetBSD Foundation
  1667. // by Nathan J. Williams.
  1668. //
  1669. // Redistribution and use in source and binary forms, with or without
  1670. // modification, are permitted provided that the following conditions
  1671. // are met:
  1672. // 1. Redistributions of source code must retain the above copyright
  1673. // notice, this list of conditions and the following disclaimer.
  1674. // 2. Redistributions in binary form must reproduce the above copyright
  1675. // notice, this list of conditions and the following disclaimer in the
  1676. // documentation and/or other materials provided with the distribution.
  1677. //
  1678. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  1679. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  1680. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  1681. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  1682. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  1683. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  1684. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  1685. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1686. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  1687. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  1688. // POSSIBILITY OF SUCH DAMAGE.
  1689. // We use the "pthread_spin_t" name internally; "pthread_spinlock_t" is the
  1690. // POSIX spinlock object.
  1691. //
  1692. // C++ expects to be using PTHREAD_FOO_INITIALIZER as a member initializer.
  1693. // This does not work for volatile types. Since C++ does not touch the guts
  1694. // of those types, we do not include volatile in the C++ definitions.
  1695. type Pthread_spin_t = X__cpu_simple_lock_t /* pthread_types.h:43:29 */
  1696. type X__pthread_spin_t = Pthread_spin_t /* pthread_types.h:48:24 */
  1697. // Copied from PTQ_HEAD in pthread_queue.h
  1698. type Pthread_queue_struct_t = struct {
  1699. Fptqh_first uintptr
  1700. Fptqh_last uintptr
  1701. } /* pthread_types.h:61:1 */
  1702. type Pthread_queue_t = Pthread_queue_struct_t /* pthread_types.h:62:39 */
  1703. type X__pthread_attr_st = struct {
  1704. Fpta_magic uint32
  1705. Fpta_flags int32
  1706. Fpta_private uintptr
  1707. } /* pthread_types.h:65:1 */
  1708. type X__pthread_mutex_st = struct {
  1709. Fptm_magic uint32
  1710. Fptm_errorcheck X__pthread_spin_t
  1711. Fptm_pad1 [3]Uint8_t
  1712. F__8 struct{ Fptm_ceiling uint8 }
  1713. Fptm_pad2 [3]Uint8_t
  1714. F__ccgo_pad1 [4]byte
  1715. Fptm_owner Pthread_t
  1716. Fptm_waiters uintptr
  1717. Fptm_recursed uint32
  1718. F__ccgo_pad2 [4]byte
  1719. Fptm_spare2 uintptr
  1720. } /* pthread_types.h:66:1 */
  1721. type X__pthread_mutexattr_st = struct {
  1722. Fptma_magic uint32
  1723. F__ccgo_pad1 [4]byte
  1724. Fptma_private uintptr
  1725. } /* pthread_types.h:67:1 */
  1726. type X__pthread_cond_st = struct {
  1727. Fptc_magic uint32
  1728. Fptc_lock X__pthread_spin_t
  1729. F__ccgo_pad1 [3]byte
  1730. Fptc_waiters Pthread_queue_t
  1731. Fptc_mutex uintptr
  1732. Fptc_private uintptr
  1733. } /* pthread_types.h:68:1 */
  1734. type X__pthread_condattr_st = struct {
  1735. Fptca_magic uint32
  1736. F__ccgo_pad1 [4]byte
  1737. Fptca_private uintptr
  1738. } /* pthread_types.h:69:1 */
  1739. type X__pthread_rwlock_st = struct {
  1740. Fptr_magic uint32
  1741. Fptr_interlock X__pthread_spin_t
  1742. F__ccgo_pad1 [3]byte
  1743. Fptr_rblocked Pthread_queue_t
  1744. Fptr_wblocked Pthread_queue_t
  1745. Fptr_nreaders uint32
  1746. F__ccgo_pad2 [4]byte
  1747. Fptr_owner Pthread_t
  1748. Fptr_private uintptr
  1749. } /* pthread_types.h:71:1 */
  1750. type X__pthread_rwlockattr_st = struct {
  1751. Fptra_magic uint32
  1752. F__ccgo_pad1 [4]byte
  1753. Fptra_private uintptr
  1754. } /* pthread_types.h:72:1 */
  1755. type X__pthread_barrier_st = struct {
  1756. Fptb_magic uint32
  1757. Fptb_lock Pthread_spin_t
  1758. F__ccgo_pad1 [3]byte
  1759. Fptb_waiters Pthread_queue_t
  1760. Fptb_initcount uint32
  1761. Fptb_curcount uint32
  1762. Fptb_generation uint32
  1763. F__ccgo_pad2 [4]byte
  1764. Fptb_private uintptr
  1765. } /* pthread_types.h:73:1 */
  1766. type X__pthread_barrierattr_st = struct {
  1767. Fptba_magic uint32
  1768. F__ccgo_pad1 [4]byte
  1769. Fptba_private uintptr
  1770. } /* pthread_types.h:74:1 */
  1771. type Pthread_t = uintptr /* pthread_types.h:76:29 */
  1772. type Pthread_attr_t = X__pthread_attr_st /* pthread_types.h:77:34 */
  1773. type Pthread_mutex_t = X__pthread_mutex_st /* pthread_types.h:78:35 */
  1774. type Pthread_mutexattr_t = X__pthread_mutexattr_st /* pthread_types.h:79:39 */
  1775. type Pthread_cond_t = X__pthread_cond_st /* pthread_types.h:80:34 */
  1776. type Pthread_condattr_t = X__pthread_condattr_st /* pthread_types.h:81:38 */
  1777. type X__pthread_once_st = struct {
  1778. Fpto_mutex Pthread_mutex_t
  1779. Fpto_done int32
  1780. F__ccgo_pad1 [4]byte
  1781. } /* pthread_types.h:82:9 */
  1782. type Pthread_once_t = X__pthread_once_st /* pthread_types.h:82:34 */
  1783. type X__pthread_spinlock_st = struct {
  1784. Fpts_magic uint32
  1785. Fpts_spin X__pthread_spin_t
  1786. F__ccgo_pad1 [3]byte
  1787. Fpts_flags int32
  1788. } /* pthread_types.h:83:9 */
  1789. type Pthread_spinlock_t = X__pthread_spinlock_st /* pthread_types.h:83:38 */
  1790. type Pthread_rwlock_t = X__pthread_rwlock_st /* pthread_types.h:84:36 */
  1791. type Pthread_rwlockattr_t = X__pthread_rwlockattr_st /* pthread_types.h:85:40 */
  1792. type Pthread_barrier_t = X__pthread_barrier_st /* pthread_types.h:86:37 */
  1793. type Pthread_barrierattr_t = X__pthread_barrierattr_st /* pthread_types.h:87:41 */
  1794. type Pthread_key_t = int32 /* pthread_types.h:88:13 */
  1795. // Structure returned by gettimeofday(2) system call,
  1796. // and used in other calls.
  1797. type Timeval = struct {
  1798. Ftv_sec Time_t
  1799. Ftv_usec Suseconds_t
  1800. F__ccgo_pad1 [4]byte
  1801. } /* time.h:44:1 */
  1802. // $NetBSD: timespec.h,v 1.1 2015/07/31 12:51:32 kamil Exp $
  1803. // Copyright (c) 1982, 1986, 1993
  1804. // The Regents of the University of California. All rights reserved.
  1805. //
  1806. // Redistribution and use in source and binary forms, with or without
  1807. // modification, are permitted provided that the following conditions
  1808. // are met:
  1809. // 1. Redistributions of source code must retain the above copyright
  1810. // notice, this list of conditions and the following disclaimer.
  1811. // 2. Redistributions in binary form must reproduce the above copyright
  1812. // notice, this list of conditions and the following disclaimer in the
  1813. // documentation and/or other materials provided with the distribution.
  1814. // 3. Neither the name of the University nor the names of its contributors
  1815. // may be used to endorse or promote products derived from this software
  1816. // without specific prior written permission.
  1817. //
  1818. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1819. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1820. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1821. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1822. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1823. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1824. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1825. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1826. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1827. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1828. // SUCH DAMAGE.
  1829. //
  1830. // @(#)time.h 8.5 (Berkeley) 5/4/95
  1831. //
  1832. // Extracted by Kamil Rytarowski from:
  1833. // NetBSD: src/sys/sys/time.h,v 1.69 2015/05/19 23:35:11 riastradh Exp
  1834. // Note: timezone is obsolete. All timezone handling is now in
  1835. // userland. Its just here for back compatibility.
  1836. type Timezone = struct {
  1837. Ftz_minuteswest int32
  1838. Ftz_dsttime int32
  1839. } /* time.h:65:1 */
  1840. // Operations on timevals.
  1841. // hide bintime for _STANDALONE because this header is used for hpcboot.exe,
  1842. // which is built with compilers which don't recognize LL suffix.
  1843. //
  1844. // http://mail-index.NetBSD.org/tech-userlevel/2008/02/27/msg000181.html
  1845. type Bintime = struct {
  1846. Fsec Time_t
  1847. Ffrac Uint64_t
  1848. } /* time.h:102:1 */
  1849. // Operations on timespecs.
  1850. // Names of the interval timers, and structure
  1851. // defining a timer setting.
  1852. // NB: Must match the CLOCK_ constants below.
  1853. type Itimerval = struct {
  1854. Fit_interval struct {
  1855. Ftv_sec Time_t
  1856. Ftv_usec Suseconds_t
  1857. F__ccgo_pad1 [4]byte
  1858. }
  1859. Fit_value struct {
  1860. Ftv_sec Time_t
  1861. Ftv_usec Suseconds_t
  1862. F__ccgo_pad1 [4]byte
  1863. }
  1864. } /* time.h:280:1 */
  1865. // Structure defined by POSIX.1b to be like a itimerval, but with
  1866. // timespecs. Used in the timer_*() system calls.
  1867. type Itimerspec = struct {
  1868. Fit_interval struct {
  1869. Ftv_sec Time_t
  1870. Ftv_nsec int64
  1871. }
  1872. Fit_value struct {
  1873. Ftv_sec Time_t
  1874. Ftv_nsec int64
  1875. }
  1876. } /* time.h:289:1 */
  1877. // $NetBSD: select.h,v 1.37 2014/04/25 15:52:45 pooka Exp $
  1878. // -
  1879. // Copyright (c) 1992, 1993
  1880. // The Regents of the University of California. All rights reserved.
  1881. //
  1882. // Redistribution and use in source and binary forms, with or without
  1883. // modification, are permitted provided that the following conditions
  1884. // are met:
  1885. // 1. Redistributions of source code must retain the above copyright
  1886. // notice, this list of conditions and the following disclaimer.
  1887. // 2. Redistributions in binary form must reproduce the above copyright
  1888. // notice, this list of conditions and the following disclaimer in the
  1889. // documentation and/or other materials provided with the distribution.
  1890. // 3. Neither the name of the University nor the names of its contributors
  1891. // may be used to endorse or promote products derived from this software
  1892. // without specific prior written permission.
  1893. //
  1894. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1895. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1896. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1897. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1898. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1899. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1900. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1901. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1902. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1903. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1904. // SUCH DAMAGE.
  1905. //
  1906. // @(#)select.h 8.2 (Berkeley) 1/4/94
  1907. // $NetBSD: cdefs.h,v 1.141 2019/02/21 21:34:05 christos Exp $
  1908. // * Copyright (c) 1991, 1993
  1909. // The Regents of the University of California. All rights reserved.
  1910. //
  1911. // This code is derived from software contributed to Berkeley by
  1912. // Berkeley Software Design, Inc.
  1913. //
  1914. // Redistribution and use in source and binary forms, with or without
  1915. // modification, are permitted provided that the following conditions
  1916. // are met:
  1917. // 1. Redistributions of source code must retain the above copyright
  1918. // notice, this list of conditions and the following disclaimer.
  1919. // 2. Redistributions in binary form must reproduce the above copyright
  1920. // notice, this list of conditions and the following disclaimer in the
  1921. // documentation and/or other materials provided with the distribution.
  1922. // 3. Neither the name of the University nor the names of its contributors
  1923. // may be used to endorse or promote products derived from this software
  1924. // without specific prior written permission.
  1925. //
  1926. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1927. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1928. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1929. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1930. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1931. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1932. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1933. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1934. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1935. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1936. // SUCH DAMAGE.
  1937. //
  1938. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  1939. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  1940. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  1941. // Public domain.
  1942. //
  1943. // NOTE: Do not protect this header against multiple inclusion. Doing
  1944. // so can have subtle side-effects due to header file inclusion order
  1945. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  1946. // protect each CPP macro that we want to supply.
  1947. // Feature-test macros are defined by several standards, and allow an
  1948. // application to specify what symbols they want the system headers to
  1949. // expose, and hence what standard they want them to conform to.
  1950. // There are two classes of feature-test macros. The first class
  1951. // specify complete standards, and if one of these is defined, header
  1952. // files will try to conform to the relevant standard. They are:
  1953. //
  1954. // ANSI macros:
  1955. // _ANSI_SOURCE ANSI C89
  1956. //
  1957. // POSIX macros:
  1958. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  1959. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  1960. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  1961. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  1962. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  1963. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  1964. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  1965. //
  1966. // X/Open macros:
  1967. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  1968. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  1969. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  1970. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  1971. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  1972. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  1973. //
  1974. // NetBSD macros:
  1975. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  1976. //
  1977. // If more than one of these "major" feature-test macros is defined,
  1978. // then the set of facilities provided (and namespace used) is the
  1979. // union of that specified by the relevant standards, and in case of
  1980. // conflict, the earlier standard in the above list has precedence (so
  1981. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  1982. // of rename() that's used is the POSIX one). If none of the "major"
  1983. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  1984. //
  1985. // There are also "minor" feature-test macros, which enable extra
  1986. // functionality in addition to some base standard. They should be
  1987. // defined along with one of the "major" macros. The "minor" macros
  1988. // are:
  1989. //
  1990. // _REENTRANT
  1991. // _ISOC99_SOURCE
  1992. // _ISOC11_SOURCE
  1993. // _LARGEFILE_SOURCE Large File Support
  1994. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  1995. // $NetBSD: fd_set.h,v 1.7 2018/06/24 12:05:40 kamil Exp $
  1996. // -
  1997. // Copyright (c) 1992, 1993
  1998. // The Regents of the University of California. All rights reserved.
  1999. //
  2000. // Redistribution and use in source and binary forms, with or without
  2001. // modification, are permitted provided that the following conditions
  2002. // are met:
  2003. // 1. Redistributions of source code must retain the above copyright
  2004. // notice, this list of conditions and the following disclaimer.
  2005. // 2. Redistributions in binary form must reproduce the above copyright
  2006. // notice, this list of conditions and the following disclaimer in the
  2007. // documentation and/or other materials provided with the distribution.
  2008. // 3. Neither the name of the University nor the names of its contributors
  2009. // may be used to endorse or promote products derived from this software
  2010. // without specific prior written permission.
  2011. //
  2012. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2013. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2014. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2015. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2016. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2017. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2018. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2019. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2020. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2021. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2022. // SUCH DAMAGE.
  2023. //
  2024. // from: @(#)types.h 8.4 (Berkeley) 1/21/94
  2025. // $NetBSD: sigtypes.h,v 1.11 2017/01/12 18:29:14 christos Exp $
  2026. // Copyright (c) 1982, 1986, 1989, 1991, 1993
  2027. // The Regents of the University of California. All rights reserved.
  2028. // (c) UNIX System Laboratories, Inc.
  2029. // All or some portions of this file are derived from material licensed
  2030. // to the University of California by American Telephone and Telegraph
  2031. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  2032. // the permission of UNIX System Laboratories, Inc.
  2033. //
  2034. // Redistribution and use in source and binary forms, with or without
  2035. // modification, are permitted provided that the following conditions
  2036. // are met:
  2037. // 1. Redistributions of source code must retain the above copyright
  2038. // notice, this list of conditions and the following disclaimer.
  2039. // 2. Redistributions in binary form must reproduce the above copyright
  2040. // notice, this list of conditions and the following disclaimer in the
  2041. // documentation and/or other materials provided with the distribution.
  2042. // 3. Neither the name of the University nor the names of its contributors
  2043. // may be used to endorse or promote products derived from this software
  2044. // without specific prior written permission.
  2045. //
  2046. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2047. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2048. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2049. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2050. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2051. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2052. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2053. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2054. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2055. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2056. // SUCH DAMAGE.
  2057. //
  2058. // @(#)signal.h 8.4 (Berkeley) 5/4/95
  2059. // This header file defines various signal-related types. We also keep
  2060. // the macros to manipulate sigset_t here, to encapsulate knowledge of
  2061. // its internals.
  2062. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  2063. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  2064. // Public domain.
  2065. //
  2066. // NOTE: Do not protect this header against multiple inclusion. Doing
  2067. // so can have subtle side-effects due to header file inclusion order
  2068. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  2069. // protect each CPP macro that we want to supply.
  2070. // Feature-test macros are defined by several standards, and allow an
  2071. // application to specify what symbols they want the system headers to
  2072. // expose, and hence what standard they want them to conform to.
  2073. // There are two classes of feature-test macros. The first class
  2074. // specify complete standards, and if one of these is defined, header
  2075. // files will try to conform to the relevant standard. They are:
  2076. //
  2077. // ANSI macros:
  2078. // _ANSI_SOURCE ANSI C89
  2079. //
  2080. // POSIX macros:
  2081. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  2082. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  2083. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  2084. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  2085. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  2086. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  2087. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  2088. //
  2089. // X/Open macros:
  2090. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  2091. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  2092. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  2093. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  2094. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  2095. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  2096. //
  2097. // NetBSD macros:
  2098. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  2099. //
  2100. // If more than one of these "major" feature-test macros is defined,
  2101. // then the set of facilities provided (and namespace used) is the
  2102. // union of that specified by the relevant standards, and in case of
  2103. // conflict, the earlier standard in the above list has precedence (so
  2104. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  2105. // of rename() that's used is the POSIX one). If none of the "major"
  2106. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  2107. //
  2108. // There are also "minor" feature-test macros, which enable extra
  2109. // functionality in addition to some base standard. They should be
  2110. // defined along with one of the "major" macros. The "minor" macros
  2111. // are:
  2112. //
  2113. // _REENTRANT
  2114. // _ISOC99_SOURCE
  2115. // _ISOC11_SOURCE
  2116. // _LARGEFILE_SOURCE Large File Support
  2117. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  2118. // $NetBSD: int_types.h,v 1.7 2014/07/25 21:43:13 joerg Exp $
  2119. // -
  2120. // Copyright (c) 1990 The Regents of the University of California.
  2121. // All rights reserved.
  2122. //
  2123. // Redistribution and use in source and binary forms, with or without
  2124. // modification, are permitted provided that the following conditions
  2125. // are met:
  2126. // 1. Redistributions of source code must retain the above copyright
  2127. // notice, this list of conditions and the following disclaimer.
  2128. // 2. Redistributions in binary form must reproduce the above copyright
  2129. // notice, this list of conditions and the following disclaimer in the
  2130. // documentation and/or other materials provided with the distribution.
  2131. // 3. Neither the name of the University nor the names of its contributors
  2132. // may be used to endorse or promote products derived from this software
  2133. // without specific prior written permission.
  2134. //
  2135. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2136. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2137. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2138. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2139. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2140. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2141. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2142. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2143. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2144. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2145. // SUCH DAMAGE.
  2146. //
  2147. // from: @(#)types.h 7.5 (Berkeley) 3/9/91
  2148. // $NetBSD: ansi.h,v 1.11 2019/05/07 03:49:26 kamil Exp $
  2149. // $NetBSD: common_ansi.h,v 1.1 2014/08/19 07:27:31 matt Exp $
  2150. // -
  2151. // Copyright (c) 2014 The NetBSD Foundation, Inc.
  2152. // All rights reserved.
  2153. //
  2154. // This code is derived from software contributed to The NetBSD Foundation
  2155. // by Matt Thomas of 3am Software Foundry.
  2156. //
  2157. // Redistribution and use in source and binary forms, with or without
  2158. // modification, are permitted provided that the following conditions
  2159. // are met:
  2160. // 1. Redistributions of source code must retain the above copyright
  2161. // notice, this list of conditions and the following disclaimer.
  2162. // 2. Redistributions in binary form must reproduce the above copyright
  2163. // notice, this list of conditions and the following disclaimer in the
  2164. // documentation and/or other materials provided with the distribution.
  2165. //
  2166. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  2167. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  2168. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  2169. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  2170. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  2171. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  2172. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  2173. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  2174. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  2175. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  2176. // POSSIBILITY OF SUCH DAMAGE.
  2177. type Sigset_t = struct{ F__bits [4]X__uint32_t } /* sigtypes.h:62:3 */
  2178. // Macro for manipulating signal masks.
  2179. type Sigaltstack = struct {
  2180. Fss_sp uintptr
  2181. Fss_size Size_t
  2182. Fss_flags int32
  2183. F__ccgo_pad1 [4]byte
  2184. } /* sigtypes.h:108:9 */
  2185. // Macro for manipulating signal masks.
  2186. type Stack_t = Sigaltstack /* sigtypes.h:116:3 */
  2187. // $NetBSD: idtype.h,v 1.5 2016/04/09 17:02:51 riastradh Exp $
  2188. // -
  2189. // Copyright (c) 2016 The NetBSD Foundation, Inc.
  2190. // All rights reserved.
  2191. //
  2192. // This code is derived from software contributed to The NetBSD Foundation
  2193. // by Christos Zoulas.
  2194. //
  2195. // Redistribution and use in source and binary forms, with or without
  2196. // modification, are permitted provided that the following conditions
  2197. // are met:
  2198. // 1. Redistributions of source code must retain the above copyright
  2199. // notice, this list of conditions and the following disclaimer.
  2200. // 2. Redistributions in binary form must reproduce the above copyright
  2201. // notice, this list of conditions and the following disclaimer in the
  2202. // documentation and/or other materials provided with the distribution.
  2203. //
  2204. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  2205. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  2206. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  2207. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  2208. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  2209. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  2210. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  2211. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  2212. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  2213. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  2214. // POSSIBILITY OF SUCH DAMAGE.
  2215. // Using the solaris constants, some of them are not applicable to us
  2216. // Do not re-order the list, or add elements in the middle as this will
  2217. // break the ABI of the system calls using this. We set a high private
  2218. // maximum so that new values can be added in the future without
  2219. // changing the width of the type.
  2220. type Idtype_t = int32 /* idtype.h:60:3 */
  2221. type Locale_t = uintptr /* time.h:188:25 */
  2222. type Timezone_t = uintptr /* time.h:198:24 */
  2223. // $NetBSD: sched.h,v 1.12.52.1 2022/08/03 10:42:02 martin Exp $
  2224. // -
  2225. // Copyright (c) 2001 The NetBSD Foundation, Inc.
  2226. // All rights reserved.
  2227. //
  2228. // This code is derived from software contributed to The NetBSD Foundation
  2229. // by Nathan J. Williams.
  2230. //
  2231. // Redistribution and use in source and binary forms, with or without
  2232. // modification, are permitted provided that the following conditions
  2233. // are met:
  2234. // 1. Redistributions of source code must retain the above copyright
  2235. // notice, this list of conditions and the following disclaimer.
  2236. // 2. Redistributions in binary form must reproduce the above copyright
  2237. // notice, this list of conditions and the following disclaimer in the
  2238. // documentation and/or other materials provided with the distribution.
  2239. //
  2240. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  2241. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  2242. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  2243. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  2244. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  2245. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  2246. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  2247. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  2248. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  2249. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  2250. // POSSIBILITY OF SUCH DAMAGE.
  2251. // $NetBSD: cdefs.h,v 1.141 2019/02/21 21:34:05 christos Exp $
  2252. // * Copyright (c) 1991, 1993
  2253. // The Regents of the University of California. All rights reserved.
  2254. //
  2255. // This code is derived from software contributed to Berkeley by
  2256. // Berkeley Software Design, Inc.
  2257. //
  2258. // Redistribution and use in source and binary forms, with or without
  2259. // modification, are permitted provided that the following conditions
  2260. // are met:
  2261. // 1. Redistributions of source code must retain the above copyright
  2262. // notice, this list of conditions and the following disclaimer.
  2263. // 2. Redistributions in binary form must reproduce the above copyright
  2264. // notice, this list of conditions and the following disclaimer in the
  2265. // documentation and/or other materials provided with the distribution.
  2266. // 3. Neither the name of the University nor the names of its contributors
  2267. // may be used to endorse or promote products derived from this software
  2268. // without specific prior written permission.
  2269. //
  2270. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2271. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2272. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2273. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2274. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2275. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2276. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2277. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2278. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2279. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2280. // SUCH DAMAGE.
  2281. //
  2282. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  2283. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  2284. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  2285. // Public domain.
  2286. //
  2287. // NOTE: Do not protect this header against multiple inclusion. Doing
  2288. // so can have subtle side-effects due to header file inclusion order
  2289. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  2290. // protect each CPP macro that we want to supply.
  2291. // Feature-test macros are defined by several standards, and allow an
  2292. // application to specify what symbols they want the system headers to
  2293. // expose, and hence what standard they want them to conform to.
  2294. // There are two classes of feature-test macros. The first class
  2295. // specify complete standards, and if one of these is defined, header
  2296. // files will try to conform to the relevant standard. They are:
  2297. //
  2298. // ANSI macros:
  2299. // _ANSI_SOURCE ANSI C89
  2300. //
  2301. // POSIX macros:
  2302. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  2303. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  2304. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  2305. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  2306. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  2307. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  2308. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  2309. //
  2310. // X/Open macros:
  2311. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  2312. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  2313. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  2314. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  2315. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  2316. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  2317. //
  2318. // NetBSD macros:
  2319. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  2320. //
  2321. // If more than one of these "major" feature-test macros is defined,
  2322. // then the set of facilities provided (and namespace used) is the
  2323. // union of that specified by the relevant standards, and in case of
  2324. // conflict, the earlier standard in the above list has precedence (so
  2325. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  2326. // of rename() that's used is the POSIX one). If none of the "major"
  2327. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  2328. //
  2329. // There are also "minor" feature-test macros, which enable extra
  2330. // functionality in addition to some base standard. They should be
  2331. // defined along with one of the "major" macros. The "minor" macros
  2332. // are:
  2333. //
  2334. // _REENTRANT
  2335. // _ISOC99_SOURCE
  2336. // _ISOC11_SOURCE
  2337. // _LARGEFILE_SOURCE Large File Support
  2338. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  2339. // $NetBSD: sched.h,v 1.76 2016/07/03 14:24:59 christos Exp $
  2340. // -
  2341. // Copyright (c) 1999, 2000, 2001, 2002, 2007, 2008 The NetBSD Foundation, Inc.
  2342. // All rights reserved.
  2343. //
  2344. // This code is derived from software contributed to The NetBSD Foundation
  2345. // by Ross Harvey, Jason R. Thorpe, Nathan J. Williams, Andrew Doran and
  2346. // Daniel Sieger.
  2347. //
  2348. // Redistribution and use in source and binary forms, with or without
  2349. // modification, are permitted provided that the following conditions
  2350. // are met:
  2351. // 1. Redistributions of source code must retain the above copyright
  2352. // notice, this list of conditions and the following disclaimer.
  2353. // 2. Redistributions in binary form must reproduce the above copyright
  2354. // notice, this list of conditions and the following disclaimer in the
  2355. // documentation and/or other materials provided with the distribution.
  2356. //
  2357. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  2358. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  2359. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  2360. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  2361. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  2362. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  2363. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  2364. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  2365. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  2366. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  2367. // POSSIBILITY OF SUCH DAMAGE.
  2368. // -
  2369. // Copyright (c) 1982, 1986, 1991, 1993
  2370. // The Regents of the University of California. All rights reserved.
  2371. // (c) UNIX System Laboratories, Inc.
  2372. // All or some portions of this file are derived from material licensed
  2373. // to the University of California by American Telephone and Telegraph
  2374. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  2375. // the permission of UNIX System Laboratories, Inc.
  2376. //
  2377. // Redistribution and use in source and binary forms, with or without
  2378. // modification, are permitted provided that the following conditions
  2379. // are met:
  2380. // 1. Redistributions of source code must retain the above copyright
  2381. // notice, this list of conditions and the following disclaimer.
  2382. // 2. Redistributions in binary form must reproduce the above copyright
  2383. // notice, this list of conditions and the following disclaimer in the
  2384. // documentation and/or other materials provided with the distribution.
  2385. // 3. Neither the name of the University nor the names of its contributors
  2386. // may be used to endorse or promote products derived from this software
  2387. // without specific prior written permission.
  2388. //
  2389. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2390. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2391. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2392. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2393. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2394. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2395. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2396. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2397. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2398. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2399. // SUCH DAMAGE.
  2400. //
  2401. // @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
  2402. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  2403. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  2404. // Public domain.
  2405. //
  2406. // NOTE: Do not protect this header against multiple inclusion. Doing
  2407. // so can have subtle side-effects due to header file inclusion order
  2408. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  2409. // protect each CPP macro that we want to supply.
  2410. // Feature-test macros are defined by several standards, and allow an
  2411. // application to specify what symbols they want the system headers to
  2412. // expose, and hence what standard they want them to conform to.
  2413. // There are two classes of feature-test macros. The first class
  2414. // specify complete standards, and if one of these is defined, header
  2415. // files will try to conform to the relevant standard. They are:
  2416. //
  2417. // ANSI macros:
  2418. // _ANSI_SOURCE ANSI C89
  2419. //
  2420. // POSIX macros:
  2421. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  2422. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  2423. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  2424. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  2425. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  2426. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  2427. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  2428. //
  2429. // X/Open macros:
  2430. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  2431. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  2432. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  2433. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  2434. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  2435. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  2436. //
  2437. // NetBSD macros:
  2438. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  2439. //
  2440. // If more than one of these "major" feature-test macros is defined,
  2441. // then the set of facilities provided (and namespace used) is the
  2442. // union of that specified by the relevant standards, and in case of
  2443. // conflict, the earlier standard in the above list has precedence (so
  2444. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  2445. // of rename() that's used is the POSIX one). If none of the "major"
  2446. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  2447. //
  2448. // There are also "minor" feature-test macros, which enable extra
  2449. // functionality in addition to some base standard. They should be
  2450. // defined along with one of the "major" macros. The "minor" macros
  2451. // are:
  2452. //
  2453. // _REENTRANT
  2454. // _ISOC99_SOURCE
  2455. // _ISOC11_SOURCE
  2456. // _LARGEFILE_SOURCE Large File Support
  2457. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  2458. // $NetBSD: types.h,v 1.102 2018/11/06 16:26:44 maya Exp $
  2459. // -
  2460. // Copyright (c) 1982, 1986, 1991, 1993, 1994
  2461. // The Regents of the University of California. All rights reserved.
  2462. // (c) UNIX System Laboratories, Inc.
  2463. // All or some portions of this file are derived from material licensed
  2464. // to the University of California by American Telephone and Telegraph
  2465. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  2466. // the permission of UNIX System Laboratories, Inc.
  2467. //
  2468. // Redistribution and use in source and binary forms, with or without
  2469. // modification, are permitted provided that the following conditions
  2470. // are met:
  2471. // 1. Redistributions of source code must retain the above copyright
  2472. // notice, this list of conditions and the following disclaimer.
  2473. // 2. Redistributions in binary form must reproduce the above copyright
  2474. // notice, this list of conditions and the following disclaimer in the
  2475. // documentation and/or other materials provided with the distribution.
  2476. // 3. Neither the name of the University nor the names of its contributors
  2477. // may be used to endorse or promote products derived from this software
  2478. // without specific prior written permission.
  2479. //
  2480. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2481. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2482. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2483. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2484. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2485. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2486. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2487. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2488. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2489. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2490. // SUCH DAMAGE.
  2491. //
  2492. // @(#)types.h 8.4 (Berkeley) 1/21/94
  2493. type Sched_param = struct{ Fsched_priority int32 } /* sched.h:80:1 */
  2494. type Pthread_cleanup_store = struct{ Fpad [4]uintptr } /* pthread.h:170:1 */
  2495. var _ int8 /* gen.c:2:13: */