Loading...
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 | module Darwin.Mach.machine [system] { header "mach/machine.h" export * #ifdef XNU_KERNEL_PRIVATE // mach/machine/asm.h is in the public SDK for all OSes, but it // includes mach/arm64/asm.h in __arm64__, and that's only public // in macOS. #endif // declares Value macro which can cause problems in other headers explicit module asm { #ifdef XNU_PLATFORM_MacOSX header "mach/machine/asm.h" #endif #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/asm.h" #endif header "mach/arm/asm.h" #ifdef XNU_PLATFORM_MacOSX header "mach/arm64/asm.h" #endif export * } module _structs { header "mach/machine/_structs.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/_structs.h" #endif header "mach/arm/_structs.h" export * } module boolean { header "mach/machine/boolean.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/boolean.h" #endif header "mach/arm/boolean.h" export * } module exception { header "mach/machine/exception.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/exception.h" #endif header "mach/arm/exception.h" export * } #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) module fp_reg { header "mach/i386/fp_reg.h" export * } #endif module kern_return { header "mach/machine/kern_return.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/kern_return.h" #endif header "mach/arm/kern_return.h" export * } // ndr_def.h defines a non-external global variable and can only // be included from a single implementation file. explicit module ndr_def { header "mach/machine/ndr_def.h" export * #ifdef XNU_KERNEL_PRIVATE // mach/{i386,arm}/ndr_def.h are conceptually a part of mach/machine/ndr_def.h, // and so belong to this module, but need to be excluded or else clang will // attempt to compile {i386,arm}/ndr_def.h independently. And that fails // because {i386,arm}/ndr_def.h can only be included once, which is from // mach/machine/ndr_def.h. #endif #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) exclude header "mach/i386/ndr_def.h" #endif exclude header "mach/arm/ndr_def.h" } module processor_info { header "mach/machine/processor_info.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/processor_info.h" #endif header "mach/arm/processor_info.h" export * } module rpc { header "mach/machine/rpc.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/rpc.h" #endif header "mach/arm/rpc.h" export * } #ifdef XNU_KERNEL_PRIVATE // The XNU_PLATFORM_MacOSX headers are in the public SDK for macOS, // but mastered out of the public SDK for the other OSes. #endif #ifdef XNU_PLATFORM_MacOSX module sdt { header "mach/machine/sdt.h" export * } #endif #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) module sdt_isa { #ifdef XNU_PLATFORM_MacOSX header "mach/machine/sdt_isa.h" #endif header "mach/i386/sdt_isa.h" #ifdef XNU_PLATFORM_MacOSX header "mach/arm/sdt_isa.h" #endif export * } #endif #ifdef XNU_KERNEL_PRIVATE // usr/include/mach/machine/syscall_sw.h and usr/include/mach/i386/syscall_sw.h // are mastered out of all SDKs. #endif module thread_state { header "mach/machine/thread_state.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/thread_state.h" #endif header "mach/arm/thread_state.h" export * } module thread_status { header "mach/machine/thread_status.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/thread_status.h" #endif header "mach/arm/thread_status.h" export * } module traps { header "mach/arm/traps.h" export * } module vm_param { header "mach/machine/vm_param.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/vm_param.h" #endif header "mach/arm/vm_param.h" export * } module vm_types { header "mach/machine/vm_types.h" #if defined(XNU_PLATFORM_MacOSX) || defined(XNU_PLATFORM_iPhoneSimulator) || defined(XNU_PLATFORM_AppleTVSimulator) || defined(XNU_PLATFORM_WatchSimulator) header "mach/i386/vm_types.h" #endif header "mach/arm/vm_types.h" export * } #ifdef XNU_KERNEL_PRIVATE // mach/machine/asm.h is in the public SDK for all OSes, but it // includes mach/arm64/asm.h in __arm64__, and that's only public // in macOS. #endif #ifndef XNU_PLATFORM_MacOSX exclude header "mach/machine/asm.h" #endif #ifdef XNU_KERNEL_PRIVATE // arm/syscall_sw.h is in the public SDK for macOS, but mastered // out of the public SDK for the other OSes. However, it doesn't // compile (missing include?). #endif #ifdef XNU_PLATFORM_MacOSX exclude header "mach/arm/syscall_sw.h" #endif } |