peachsim 0.1.1700 → 0.1.1728

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (950) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +79 -5
  3. package/cli/app-bundle-resources.ts +5 -2
  4. package/cli/app-catalog.ts +10 -0
  5. package/cli/app-fonts.ts +5 -5
  6. package/cli/app-splash.ts +4 -4
  7. package/cli/app-stubs.ts +36 -9
  8. package/cli/bridge-diagnostics.ts +2 -1
  9. package/cli/cloud-client.ts +6 -3
  10. package/cli/command-registry.ts +1 -0
  11. package/cli/commands/control.ts +180 -837
  12. package/cli/commands/coverage-swift.ts +19 -1
  13. package/cli/commands/daemon.ts +8 -0
  14. package/cli/commands/detect.ts +84 -37
  15. package/cli/commands/detox.ts +3 -0
  16. package/cli/commands/doctor.ts +178 -22
  17. package/cli/commands/flow.ts +4 -1
  18. package/cli/commands/inspect/actions.ts +74 -14
  19. package/cli/commands/inspect/core.ts +181 -18
  20. package/cli/commands/inspect/settling.ts +22 -7
  21. package/cli/commands/inspect/wait-ready.ts +13 -5
  22. package/cli/commands/inspect.ts +56 -47
  23. package/cli/commands/kotlin.ts +12 -2
  24. package/cli/commands/package.ts +750 -0
  25. package/cli/commands/record.ts +263 -32
  26. package/cli/commands/screenshot.ts +2 -13
  27. package/cli/commands/serve.ts +6 -0
  28. package/cli/commands/shell-url.ts +834 -0
  29. package/cli/commands/swift.ts +42 -102
  30. package/cli/commands/test.ts +69 -101
  31. package/cli/commands/upload.ts +1 -1
  32. package/cli/current-sim.ts +4 -4
  33. package/cli/device-option.ts +1 -1
  34. package/cli/hints.ts +1 -6
  35. package/cli/main.ts +20 -1
  36. package/cli/metro-bundle-assets.ts +77 -0
  37. package/cli/native-input.ts +199 -0
  38. package/cli/outbound-endpoints.ts +32 -3
  39. package/cli/packaged-app-launcher.ts +95 -0
  40. package/cli/run-registry.ts +0 -8
  41. package/cli/scene-video.ts +18 -9
  42. package/cli/ws-bridge.ts +56 -14
  43. package/detox/index.ts +240 -18
  44. package/detox/launch-permissions.ts +183 -27
  45. package/dist-lib/agent-daemon-client.cjs +1 -1
  46. package/dist-lib/agent-events.cjs +1 -1
  47. package/dist-lib/attached-projects.cjs +1 -1
  48. package/dist-lib/auth/shared-session.cjs +1 -1
  49. package/dist-lib/backend-origin.cjs +10 -9
  50. package/dist-lib/beta.cjs +1 -1
  51. package/dist-lib/beta.mjs +1 -1
  52. package/dist-lib/bridge-constants.cjs +5 -1
  53. package/dist-lib/bridge-contract-input.cjs +1 -1
  54. package/dist-lib/bridge-contract-input.mjs +1 -1
  55. package/dist-lib/bridge-contract.cjs +1 -1
  56. package/dist-lib/bridge-contract.mjs +1 -1
  57. package/dist-lib/bundle-channel.cjs +38744 -32209
  58. package/dist-lib/capture-contract.cjs +1 -1
  59. package/dist-lib/capture-contract.mjs +1 -1
  60. package/dist-lib/cloud-contract.cjs +1 -1
  61. package/dist-lib/cloud-contract.mjs +1 -1
  62. package/dist-lib/cloud-test-args.cjs +1 -1
  63. package/dist-lib/cloud-test-args.mjs +1 -1
  64. package/dist-lib/cloud.cjs +2 -1
  65. package/dist-lib/cloud.mjs +2 -1
  66. package/dist-lib/config.cjs +1 -1
  67. package/dist-lib/config.mjs +1 -1
  68. package/dist-lib/detox/index.cjs +335 -70
  69. package/dist-lib/dev-bundle-resolution.cjs +15 -20
  70. package/dist-lib/expo-swift-bundle.cjs +22406 -23392
  71. package/dist-lib/expo-swift-metadata.cjs +4 -1
  72. package/dist-lib/expo-swift-metadata.mjs +3 -1
  73. package/dist-lib/home-paths.cjs +21 -2
  74. package/dist-lib/host/bridge-host.cjs +34611 -31375
  75. package/dist-lib/host/fetch-proxy-handler.cjs +475 -86
  76. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  77. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  78. package/dist-lib/host/replacement-module-handler.cjs +2 -1
  79. package/dist-lib/host/websocket-proxy.cjs +311 -45
  80. package/dist-lib/index.cjs +2509 -640
  81. package/dist-lib/jump-to-source-babel.cjs +1 -1
  82. package/dist-lib/jump-to-source-native.cjs +1 -1
  83. package/dist-lib/kotlin-host.cjs +127 -16
  84. package/dist-lib/menu.cjs +10 -1
  85. package/dist-lib/menu.mjs +9 -1
  86. package/dist-lib/metro-fingerprint-registry.cjs +1 -1
  87. package/dist-lib/metro-fingerprint-registry.mjs +1 -1
  88. package/dist-lib/metro-production-bundle.cjs +1 -1
  89. package/dist-lib/metro-production-bundle.mjs +1 -1
  90. package/dist-lib/metro.cjs +2340 -605
  91. package/dist-lib/native-app-identity-project.cjs +1277 -243
  92. package/dist-lib/native-app-identity-project.mjs +1287 -254
  93. package/dist-lib/native-app-identity.cjs +26 -2
  94. package/dist-lib/native-app-identity.mjs +24 -2
  95. package/dist-lib/native-firebase-metadata.cjs +1 -1
  96. package/dist-lib/native-firebase-metadata.mjs +1 -1
  97. package/dist-lib/plist.cjs +1 -1
  98. package/dist-lib/plist.mjs +1 -1
  99. package/dist-lib/profiles.cjs +1 -1
  100. package/dist-lib/public-brand.cjs +1 -1
  101. package/dist-lib/public-origins-lib-esm.json +36 -101
  102. package/dist-lib/public-origins-lib.json +478 -434
  103. package/dist-lib/react-native-host-modules.cjs +127 -3
  104. package/dist-lib/react-native-host-modules.mjs +126 -3
  105. package/dist-lib/reap-browser.cjs +12 -4
  106. package/dist-lib/scripts/dev-server-scanner.cjs +32 -50
  107. package/dist-lib/sdk.cjs +161 -24
  108. package/dist-lib/sdk.mjs +154 -24
  109. package/dist-lib/skills.cjs +44096 -28607
  110. package/dist-lib/swift-compile.cjs +6294 -16931
  111. package/dist-lib/swift-compile.mjs +6282 -16928
  112. package/dist-lib/swift-package.cjs +81 -3
  113. package/dist-lib/swift-package.mjs +77 -3
  114. package/dist-lib/swift-submit.cjs +14 -4
  115. package/dist-lib/swift-submit.mjs +14 -4
  116. package/dist-lib/swift-toolchain.cjs +108 -18
  117. package/dist-lib/swift.cjs +1 -1
  118. package/dist-lib/vite-swift.cjs +14434 -20336
  119. package/dist-lib/vite.cjs +558 -132
  120. package/dist-lib/worklet-executable.cjs +1 -1
  121. package/dist-lib/worklet-executable.mjs +1 -1
  122. package/dist-types/packages/peach-compat/src/stubs/native-seams/react-native-cookies.d.ts +17 -8
  123. package/dist-types/packages/peach-compat/src/stubs/native-seams/react-native-gesture-handler.d.ts +2 -0
  124. package/dist-types/packages/peach-compat/src/stubs/screen-transition-math.d.ts +1 -1
  125. package/dist-types/packages/peach-engine/src/capture/lockstep-clockContract.d.ts +1 -0
  126. package/dist-types/packages/peach-engine/src/engine/canvaskit-renderer.d.ts +1 -0
  127. package/dist-types/packages/peach-engine/src/engine/fiber-debug-metadata.d.ts +4 -0
  128. package/dist-types/packages/peach-engine/src/engine/font-config.d.ts +1 -1
  129. package/dist-types/packages/peach-engine/src/engine/fontDataContract.d.ts +1 -0
  130. package/dist-types/packages/peach-engine/src/engine/image-loader.d.ts +8 -4
  131. package/dist-types/packages/peach-engine/src/engine/lottie-types.d.ts +3 -0
  132. package/dist-types/packages/peach-engine/src/engine/memory-counts.d.ts +3 -1
  133. package/dist-types/packages/peach-engine/src/engine/node.d.ts +6 -14
  134. package/dist-types/packages/peach-engine/src/engine/riveContract.d.ts +5 -0
  135. package/dist-types/packages/peach-engine/src/engine/types.d.ts +3 -0
  136. package/dist-types/packages/peach-engine/src/guest-module-overrides.d.ts +3 -0
  137. package/dist-types/packages/peach-engine/src/ios/chrome-metrics.d.ts +2 -1
  138. package/dist-types/packages/peach-engine/src/permissions/system-permission-types.d.ts +2 -1
  139. package/dist-types/packages/peach-engine/src/react-native/host-services.d.ts +1 -0
  140. package/dist-types/packages/peach-engine/src/react-native/platform-colors.d.ts +1 -0
  141. package/dist-types/packages/peach-engine/src/remote-stream/cloud-display.d.ts +6 -2
  142. package/dist-types/packages/peach-engine/src/remote-stream/scene-recording.d.ts +4 -0
  143. package/dist-types/packages/peach-engine/src/render-worker/compositor-protocol.d.ts +25 -0
  144. package/dist-types/packages/peach-engine/src/render-worker/host-service-protocol.d.ts +18 -2
  145. package/dist-types/packages/peach-engine/src/render-worker/live-frame-mirror.d.ts +11 -0
  146. package/dist-types/packages/peach-engine/src/render-worker/native-ui-commandContract.d.ts +1 -1
  147. package/dist-types/packages/peach-engine/src/render-worker/native-ui-protocol.d.ts +10 -1
  148. package/dist-types/packages/peach-engine/src/render-worker/protocol.d.ts +10 -0
  149. package/dist-types/packages/peach-engine/src/render-worker/shell-protocol.d.ts +9 -0
  150. package/dist-types/packages/peach-engine/src/render-worker/shell-tree-wire.d.ts +5 -0
  151. package/dist-types/packages/peach-engine/src/render-worker/tree-sync-port.d.ts +6 -1
  152. package/dist-types/packages/peach-engine/src/render-worker/worklet-runtime-kind.d.ts +5 -1
  153. package/dist-types/packages/peach-engine/src/render-worker/worklet-runtime.d.ts +29 -5
  154. package/dist-types/packages/peach-engine/src/render-worker/workletThreadIdentityContract.d.ts +4 -0
  155. package/dist-types/packages/peach-engine/src/shell-events.d.ts +1 -0
  156. package/dist-types/packages/peach-globals/src/audioBridgeContract.d.ts +5 -0
  157. package/dist-types/packages/peach-globals/src/guestExecutionContract.d.ts +30 -0
  158. package/dist-types/packages/peach-globals/src/index.d.ts +7 -5
  159. package/dist-types/packages/peach-globals/src/keyboardBridgeContract.d.ts +11 -0
  160. package/dist-types/packages/peach-globals/src/nativeBuildOptionsContract.d.ts +1 -0
  161. package/dist-types/packages/peach-globals/src/permissionsBridgeContract.d.ts +11 -0
  162. package/dist-types/packages/peach-globals/src/recordingBridgeContract.d.ts +22 -1
  163. package/dist-types/packages/peach-globals/src/sceneStreamBridgeContract.d.ts +10 -0
  164. package/dist-types/packages/peach-globals/src/shellBridgeContract.d.ts +1 -0
  165. package/dist-types/packages/peach-globals/src/shellHostBridgeContract.d.ts +8 -2
  166. package/dist-types/packages/peach-globals/src/testBridgeContract.d.ts +12 -2
  167. package/dist-types/packages/peach-kit/src/capabilities.d.ts +1 -0
  168. package/package.json +3 -1
  169. package/runtime-companion.json +1 -1
  170. package/scripts/dev-server-scanner.ts +55 -81
  171. package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Headers/ASFoundation.h +52 -0
  172. package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Headers/ASWebAuthenticationSession.h +128 -0
  173. package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Headers/ASWebAuthenticationSessionCallback.h +35 -0
  174. package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Headers/AuthenticationServices.h +3 -0
  175. package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Modules/module.modulemap +5 -0
  176. package/sdk/ios/System/Library/Frameworks/CFNetwork.framework/Headers/CFHTTPMessage.h +724 -0
  177. package/sdk/ios/System/Library/Frameworks/CFNetwork.framework/Headers/CFNetwork.h +4 -0
  178. package/sdk/ios/System/Library/Frameworks/CFNetwork.framework/Headers/CFNetworkDefs.h +27 -0
  179. package/sdk/ios/System/Library/Frameworks/CFNetwork.framework/Modules/module.modulemap +5 -0
  180. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBATTRequest.h +69 -0
  181. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBAdvertisementData.h +94 -0
  182. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBAttribute.h +34 -0
  183. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBCentral.h +41 -0
  184. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBCentralManager.h +394 -0
  185. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBCentralManagerConstants.h +224 -0
  186. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBCharacteristic.h +187 -0
  187. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBDefines.h +16 -0
  188. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBDescriptor.h +78 -0
  189. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBError.h +75 -0
  190. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBL2CAPChannel.h +50 -0
  191. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBManager.h +88 -0
  192. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBPeer.h +28 -0
  193. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBPeripheral.h +530 -0
  194. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBPeripheralManager.h +489 -0
  195. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBPeripheralManagerConstants.h +63 -0
  196. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBService.h +100 -0
  197. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CBUUID.h +144 -0
  198. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CoreBluetooth.apinotes +7 -0
  199. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Headers/CoreBluetooth.h +32 -0
  200. package/sdk/ios/System/Library/Frameworks/CoreBluetooth.framework/Modules/module.modulemap +5 -0
  201. package/sdk/ios/System/Library/Frameworks/CoreFoundation.framework/Headers/CFCGTypes.h +131 -0
  202. package/sdk/ios/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h +1301 -0
  203. package/sdk/ios/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h +8 -0
  204. package/sdk/ios/System/Library/Frameworks/CoreGraphics.framework/Headers/CGBase.h +359 -2
  205. package/sdk/ios/System/Library/Frameworks/CoreGraphics.framework/Headers/CGGeometry.h +328 -0
  206. package/sdk/ios/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.h +3 -60
  207. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationManager.h +21 -50
  208. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLRegion.h +6 -6
  209. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/CoreNFC.apinotes +258 -0
  210. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/CoreNFC.h +31 -0
  211. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCError.h +103 -0
  212. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCFeliCaTag.h +267 -0
  213. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCISO15693ReaderSession.h +59 -0
  214. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCISO15693Tag.h +739 -0
  215. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCISO7816Tag.h +159 -0
  216. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCMiFareTag.h +94 -0
  217. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCNDEFMessage.h +60 -0
  218. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCNDEFPayload.h +121 -0
  219. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCNDEFReaderSession.h +169 -0
  220. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCNDEFTag.h +93 -0
  221. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCPaymentTagReaderSession.h +58 -0
  222. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCReaderSession.h +156 -0
  223. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCTag.h +127 -0
  224. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCTagReaderSession.h +201 -0
  225. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NFCVASReaderSession.h +237 -0
  226. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Headers/NSUserActivity+CoreNFC.h +35 -0
  227. package/sdk/ios/System/Library/Frameworks/CoreNFC.framework/Modules/module.modulemap +21 -0
  228. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTCall.h +53 -0
  229. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTCallCenter.h +45 -0
  230. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTCarrier.h +87 -0
  231. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTCellularData.h +39 -0
  232. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTCellularPlanProperties.h +46 -0
  233. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTCellularPlanProvisioning.h +33 -0
  234. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTCellularPlanProvisioningRequest.h +36 -0
  235. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTCellularPlanStatus.h +57 -0
  236. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTQuickSwitch.h +53 -0
  237. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTSubscriber.h +107 -0
  238. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTSubscriberInfo.h +34 -0
  239. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CTTelephonyNetworkInfo.h +161 -0
  240. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Headers/CoreTelephonyDefines.h +39 -0
  241. package/sdk/ios/System/Library/Frameworks/CoreTelephony.framework/Modules/module.modulemap +5 -0
  242. package/sdk/ios/System/Library/Frameworks/CoreText.framework/Headers/CTDefines.h +92 -0
  243. package/sdk/ios/System/Library/Frameworks/CoreText.framework/Headers/CTFontDescriptor.h +634 -0
  244. package/sdk/ios/System/Library/Frameworks/CoreText.framework/Headers/CTFontTraits.h +118 -0
  245. package/sdk/ios/System/Library/Frameworks/CoreText.framework/Headers/CoreText.h +1 -0
  246. package/sdk/ios/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes +2497 -0
  247. package/sdk/ios/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h +2962 -367
  248. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKAccessPoint.h +110 -0
  249. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKAchievement.h +64 -0
  250. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKAchievementDescription.h +88 -0
  251. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKAchievementViewController.h +30 -0
  252. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKBasePlayer.h +15 -0
  253. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKChallenge.h +199 -0
  254. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKChallengeDefinition.h +71 -0
  255. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKChallengeEventHandler.h +43 -0
  256. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKChallengesViewController.h +33 -0
  257. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKCloudPlayer.h +19 -0
  258. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKDefines.h +17 -0
  259. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKDialogController.h +35 -0
  260. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKError.h +52 -0
  261. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKEventListener.h +36 -0
  262. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKFriendRequestComposeViewController.h +60 -0
  263. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameActivity.h +201 -0
  264. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameActivityDefinition.h +98 -0
  265. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameActivityListener.h +28 -0
  266. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameActivityPlayStyle.h +17 -0
  267. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameActivityState.h +22 -0
  268. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameCenterViewController.h +102 -0
  269. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameSession.h +87 -0
  270. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameSessionError.h +26 -0
  271. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameSessionEventListener.h +25 -0
  272. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKGameSessionSharingViewController.h +33 -0
  273. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKLeaderboard.h +205 -0
  274. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKLeaderboardEntry.h +23 -0
  275. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKLeaderboardScore.h +25 -0
  276. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKLeaderboardSet.h +64 -0
  277. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKLeaderboardViewController.h +34 -0
  278. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKLocalPlayer.h +321 -0
  279. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKMatch.h +94 -0
  280. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKMatchmaker.h +229 -0
  281. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKMatchmakerViewController.h +100 -0
  282. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKNotificationBanner.h +20 -0
  283. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKPeerPickerController.h +93 -0
  284. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKPlayer.h +82 -0
  285. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKPublicConstants.h +57 -0
  286. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKPublicProtocols.h +71 -0
  287. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKReleaseState.h +16 -0
  288. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKSavedGame.h +41 -0
  289. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKSavedGameListener.h +22 -0
  290. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKScore.h +73 -0
  291. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKSession.h +87 -0
  292. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKSessionError.h +30 -0
  293. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKTurnBasedMatch.h +314 -0
  294. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKTurnBasedMatchmakerViewController.h +69 -0
  295. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKVoiceChat.h +48 -0
  296. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GKVoiceChatService.h +145 -0
  297. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GameKit.apinotes +307 -0
  298. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Headers/GameKit.h +79 -0
  299. package/sdk/ios/System/Library/Frameworks/GameKit.framework/Modules/module.modulemap +6 -0
  300. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKActivitySummary.h +122 -0
  301. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKActivitySummaryQuery.h +48 -0
  302. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKAnchoredObjectQuery.h +93 -0
  303. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKAppleSleepingBreathingDisturbancesClassification.h +39 -0
  304. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKAppleWalkingSteadinessClassification.h +49 -0
  305. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKAttachment.h +74 -0
  306. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKAttachmentStore.h +95 -0
  307. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKAudiogramSample.h +66 -0
  308. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKAudiogramSensitivityPoint.h +82 -0
  309. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKAudiogramSensitivityPointClampingRange.h +54 -0
  310. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKAudiogramSensitivityTest.h +101 -0
  311. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKCDADocumentSample.h +131 -0
  312. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKCategorySample.h +92 -0
  313. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKCategoryValues.h +279 -0
  314. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKCharacteristicObjects.h +79 -0
  315. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKCharacteristicValues.h +87 -0
  316. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKClinicalCoding.h +55 -0
  317. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKClinicalRecord.h +53 -0
  318. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKClinicalType.h +68 -0
  319. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKContactsLensSpecification.h +59 -0
  320. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKContactsPrescription.h +74 -0
  321. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKCorrelation.h +85 -0
  322. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKCorrelationQuery.h +57 -0
  323. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKCumulativeQuantitySample.h +36 -0
  324. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKCumulativeQuantitySeriesSample.h +23 -0
  325. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKDefines.h +114 -0
  326. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKDeletedObject.h +40 -0
  327. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKDevice.h +164 -0
  328. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKDiscreteQuantitySample.h +67 -0
  329. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKDocumentQuery.h +83 -0
  330. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKDocumentSample.h +29 -0
  331. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKElectrocardiogram.h +109 -0
  332. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKElectrocardiogramQuery.h +68 -0
  333. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKFHIRRelease.h +35 -0
  334. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKFHIRResource.h +81 -0
  335. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKFHIRVersion.h +50 -0
  336. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKGAD7Assessment.h +73 -0
  337. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKGlassesLensSpecification.h +81 -0
  338. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKGlassesPrescription.h +66 -0
  339. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKHealthConceptIdentifier.h +46 -0
  340. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKHealthStore.h +470 -0
  341. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKHeartbeatSeriesBuilder.h +104 -0
  342. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKHeartbeatSeriesQuery.h +47 -0
  343. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKHeartbeatSeriesSample.h +26 -0
  344. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKLensSpecification.h +53 -0
  345. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKLiveWorkoutBuilder.h +131 -0
  346. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKLiveWorkoutDataSource.h +67 -0
  347. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKLiveWorkoutZoneUpdate.h +25 -0
  348. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKMedicationConcept.h +95 -0
  349. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKMedicationDoseEvent.h +113 -0
  350. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKMetadata.h +583 -0
  351. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKMetadataEnums.h +250 -0
  352. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKObject.h +64 -0
  353. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKObjectType.h +294 -0
  354. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKObserverQuery.h +48 -0
  355. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKPHQ9Assessment.h +77 -0
  356. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKQuantity.h +55 -0
  357. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKQuantityAggregationStyle.h +30 -0
  358. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKQuantitySample.h +83 -0
  359. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKQuantitySeriesSampleBuilder.h +184 -0
  360. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKQuantitySeriesSampleQuery.h +90 -0
  361. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKQuery.h +722 -0
  362. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKQueryAnchor.h +33 -0
  363. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKQueryDescriptor.h +46 -0
  364. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKSample.h +48 -0
  365. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKSampleQuery.h +95 -0
  366. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKScoredAssessment.h +31 -0
  367. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKSeriesBuilder.h +40 -0
  368. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKSeriesSample.h +32 -0
  369. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKSource.h +45 -0
  370. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKSourceQuery.h +42 -0
  371. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKSourceRevision.h +78 -0
  372. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKStateOfMind.h +157 -0
  373. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKStatistics.h +166 -0
  374. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKStatisticsCollectionQuery.h +80 -0
  375. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKStatisticsQuery.h +37 -0
  376. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKTypeIdentifiers.h +359 -0
  377. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKUnit.h +287 -0
  378. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKUserAnnotatedMedication.h +60 -0
  379. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKUserAnnotatedMedicationQuery.h +38 -0
  380. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKVerifiableClinicalRecord.h +131 -0
  381. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKVerifiableClinicalRecordQuery.h +76 -0
  382. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKVerifiableClinicalRecordSubject.h +39 -0
  383. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKVisionPrescription.h +76 -0
  384. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKVisionPrism.h +123 -0
  385. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkout.h +341 -0
  386. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkoutActivity.h +127 -0
  387. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkoutActivityType.h +147 -0
  388. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkoutBuilder.h +264 -0
  389. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkoutConfiguration.h +62 -0
  390. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkoutEffortRelationshipQuery.h +80 -0
  391. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkoutRoute.h +20 -0
  392. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkoutRouteBuilder.h +102 -0
  393. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkoutRouteQuery.h +67 -0
  394. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HKWorkoutSession.h +364 -0
  395. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HealthKit.apinotes +5 -0
  396. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Headers/HealthKit.h +101 -0
  397. package/sdk/ios/System/Library/Frameworks/HealthKit.framework/Modules/module.modulemap +5 -0
  398. package/sdk/ios/System/Library/Frameworks/MediaAccessibility.framework/Headers/MAAudibleMedia.h +41 -0
  399. package/sdk/ios/System/Library/Frameworks/MediaAccessibility.framework/Headers/MACaptionAppearance.h +406 -0
  400. package/sdk/ios/System/Library/Frameworks/MediaAccessibility.framework/Headers/MADefinitions.h +38 -0
  401. package/sdk/ios/System/Library/Frameworks/MediaAccessibility.framework/Headers/MAFlashingLightsProcessing.h +53 -0
  402. package/sdk/ios/System/Library/Frameworks/MediaAccessibility.framework/Headers/MAImageCaptioning.h +55 -0
  403. package/sdk/ios/System/Library/Frameworks/MediaAccessibility.framework/Headers/MAMusicHaptics.h +69 -0
  404. package/sdk/ios/System/Library/Frameworks/MediaAccessibility.framework/Headers/MAVideoAccommodations.h +34 -0
  405. package/sdk/ios/System/Library/Frameworks/MediaAccessibility.framework/Headers/MediaAccessibility.h +14 -0
  406. package/sdk/ios/System/Library/Frameworks/MediaAccessibility.framework/Modules/module.modulemap +11 -0
  407. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEAppProxyFlow.h +142 -0
  408. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEAppProxyProvider.h +93 -0
  409. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEAppProxyProviderManager.h +40 -0
  410. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEAppProxyTCPFlow.h +63 -0
  411. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEAppProxyUDPFlow.h +86 -0
  412. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEAppPushManager.h +208 -0
  413. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEAppPushProvider.h +87 -0
  414. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEAppRule.h +80 -0
  415. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEDNSProxyManager.h +109 -0
  416. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEDNSProxyProvider.h +98 -0
  417. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEDNSProxyProviderProtocol.h +45 -0
  418. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEDNSSettings.h +124 -0
  419. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEDNSSettingsManager.h +116 -0
  420. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEEthernetTunnelNetworkSettings.h +45 -0
  421. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEEthernetTunnelProvider.h +31 -0
  422. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFilterControlProvider.h +80 -0
  423. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFilterDataProvider.h +235 -0
  424. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFilterFlow.h +177 -0
  425. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFilterManager.h +138 -0
  426. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFilterPacketProvider.h +99 -0
  427. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFilterProvider.h +335 -0
  428. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFilterProviderConfiguration.h +94 -0
  429. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFilterRule.h +46 -0
  430. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFilterSettings.h +56 -0
  431. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEFlowMetaData.h +45 -0
  432. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEHotspotConfigurationManager.h +493 -0
  433. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEHotspotHelper.h +529 -0
  434. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEHotspotNetwork.h +87 -0
  435. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEIPv4Settings.h +122 -0
  436. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEIPv6Settings.h +121 -0
  437. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NENetworkRule.h +218 -0
  438. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEOnDemandRule.h +210 -0
  439. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEPacket.h +67 -0
  440. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEPacketTunnelFlow.h +62 -0
  441. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEPacketTunnelNetworkSettings.h +135 -0
  442. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEPacketTunnelProvider.h +97 -0
  443. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEProvider.h +160 -0
  444. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEProxySettings.h +140 -0
  445. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelay.h +83 -0
  446. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelayManager.h +195 -0
  447. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NETransparentProxyManager.h +39 -0
  448. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NETransparentProxyNetworkSettings.h +62 -0
  449. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NETransparentProxyProvider.h +33 -0
  450. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NETunnelNetworkSettings.h +57 -0
  451. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NETunnelProvider.h +113 -0
  452. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NETunnelProviderManager.h +108 -0
  453. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NETunnelProviderProtocol.h +44 -0
  454. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NETunnelProviderSession.h +55 -0
  455. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEURLFilter.h +51 -0
  456. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEVPNConnection.h +162 -0
  457. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEVPNManager.h +153 -0
  458. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEVPNProtocol.h +135 -0
  459. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEVPNProtocolIKEv2.h +357 -0
  460. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NEVPNProtocolIPSec.h +71 -0
  461. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NWBonjourServiceEndpoint.h +82 -0
  462. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NWEndpoint.h +40 -0
  463. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NWHostEndpoint.h +68 -0
  464. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NWPath.h +93 -0
  465. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NWTCPConnection.h +335 -0
  466. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NWTLSParameters.h +70 -0
  467. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NWUDPSession.h +207 -0
  468. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NetworkExtension.apinotes +351 -0
  469. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Headers/NetworkExtension.h +74 -0
  470. package/sdk/ios/System/Library/Frameworks/NetworkExtension.framework/Modules/module.modulemap +5 -0
  471. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/ModelIO.h +84 -0
  472. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNAction.h +197 -0
  473. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNAnimation.h +428 -0
  474. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNAudioSource.h +170 -0
  475. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNBoundingVolume.h +50 -0
  476. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNCAAnimationExtensions.h +58 -0
  477. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNCamera.h +356 -0
  478. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNCameraController.h +124 -0
  479. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNConstraint.h +431 -0
  480. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNGeometry.h +591 -0
  481. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNHitTest.h +101 -0
  482. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNJavascript.h +58 -0
  483. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNLevelOfDetail.h +56 -0
  484. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNLight.h +350 -0
  485. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNMaterial.h +349 -0
  486. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNMaterialProperty.h +149 -0
  487. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNMorpher.h +79 -0
  488. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNNode.h +695 -0
  489. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNParametricGeometry.h +727 -0
  490. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNParticleSystem.h +462 -0
  491. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNPhysicsBehavior.h +219 -0
  492. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNPhysicsBody.h +148 -0
  493. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNPhysicsContact.h +34 -0
  494. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNPhysicsField.h +124 -0
  495. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNPhysicsShape.h +58 -0
  496. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNPhysicsWorld.h +90 -0
  497. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNReferenceNode.h +80 -0
  498. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNRenderer.h +102 -0
  499. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNScene.h +250 -0
  500. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNSceneRenderer.h +389 -0
  501. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNSceneSource.h +348 -0
  502. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNShadable.h +573 -0
  503. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNSkinner.h +84 -0
  504. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNTechnique.h +320 -0
  505. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNTransaction.h +64 -0
  506. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SCNView.h +170 -0
  507. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SceneKit.apinotes +423 -0
  508. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SceneKit.h +58 -0
  509. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SceneKitAvailability.h +10 -0
  510. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SceneKitDeprecated.h +88 -0
  511. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/SceneKitTypes.h +264 -0
  512. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Headers/scn_metal +75 -0
  513. package/sdk/ios/System/Library/Frameworks/SceneKit.framework/Modules/module.modulemap +12 -0
  514. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/CipherSuite.h +281 -0
  515. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/SecAccessControl.h +133 -0
  516. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/SecIdentity.h +232 -0
  517. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/SecKey.h +1616 -0
  518. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/SecProtocolMetadata.h +429 -0
  519. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/SecProtocolObject.h +71 -0
  520. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/SecProtocolOptions.h +775 -0
  521. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/SecProtocolTypes.h +327 -0
  522. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/SecRandom.h +84 -0
  523. package/sdk/ios/System/Library/Frameworks/Security.framework/Headers/Security.h +9 -0
  524. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h +12 -0
  525. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIInterface.h +23 -0
  526. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h +26 -9
  527. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIOrientation.h +14 -0
  528. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIStringDrawing.h +12 -0
  529. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIView.h +14 -0
  530. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIViewAnimating.h +12 -0
  531. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIViewController.h +16 -0
  532. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIWindow.h +2 -0
  533. package/sdk/ios/usr/include/AvailabilityInternal.h +23 -0
  534. package/sdk/ios/usr/include/Block.h +56 -0
  535. package/sdk/ios/usr/include/CommonCrypto/CommonCrypto.h +34 -0
  536. package/sdk/ios/usr/include/CommonCrypto/CommonCryptoError.h +78 -0
  537. package/sdk/ios/usr/include/CommonCrypto/CommonCryptor.h +763 -0
  538. package/sdk/ios/usr/include/CommonCrypto/CommonDigest.h +254 -47
  539. package/sdk/ios/usr/include/CommonCrypto/CommonHMAC.h +162 -0
  540. package/sdk/ios/usr/include/CommonCrypto/CommonKeyDerivation.h +136 -0
  541. package/sdk/ios/usr/include/CommonCrypto/CommonRandom.h +63 -0
  542. package/sdk/ios/usr/include/CommonCrypto/CommonSymmetricKeywrap.h +162 -0
  543. package/sdk/ios/usr/include/CommonCrypto/module.modulemap +15 -0
  544. package/sdk/ios/usr/include/ConditionalMacros.h +619 -0
  545. package/sdk/ios/usr/include/ObjectiveC.apinotes +437 -0
  546. package/sdk/ios/usr/include/TargetConditionals.h +525 -14
  547. package/sdk/ios/usr/include/___wctype.h +193 -0
  548. package/sdk/ios/usr/include/__wctype.h +43 -0
  549. package/sdk/ios/usr/include/_abort.h +36 -0
  550. package/sdk/ios/usr/include/_assert.h +80 -0
  551. package/sdk/ios/usr/include/_static_assert.h +33 -0
  552. package/sdk/ios/usr/include/_stdlib.h +403 -0
  553. package/sdk/ios/usr/include/_string.h +231 -0
  554. package/sdk/ios/usr/include/_strings.h +101 -0
  555. package/sdk/ios/usr/include/_types/_wctrans_t.h +33 -0
  556. package/sdk/ios/usr/include/_types/_wctype_t.h +33 -0
  557. package/sdk/ios/usr/include/_wchar.h +263 -0
  558. package/sdk/ios/usr/include/_wctype.h +129 -0
  559. package/sdk/ios/usr/include/_xlocale.h +47 -0
  560. package/sdk/ios/usr/include/alloca.h +46 -0
  561. package/sdk/ios/usr/include/architecture/byte_order.h +381 -0
  562. package/sdk/ios/usr/include/arm/_limits.h +13 -0
  563. package/sdk/ios/usr/include/arm/arch.h +71 -0
  564. package/sdk/ios/usr/include/arm/limits.h +136 -0
  565. package/sdk/ios/usr/include/arpa/inet.h +100 -0
  566. package/sdk/ios/usr/include/assert.h +77 -10
  567. package/sdk/ios/usr/include/bsm/audit.h +434 -0
  568. package/sdk/ios/usr/include/crt_externs.h +50 -0
  569. package/sdk/ios/usr/include/dispatch/base.h +369 -0
  570. package/sdk/ios/usr/include/dispatch/block.h +509 -0
  571. package/sdk/ios/usr/include/dispatch/data.h +290 -0
  572. package/sdk/ios/usr/include/dispatch/dispatch.h +68 -172
  573. package/sdk/ios/usr/include/dispatch/dispatch_swift_shims.h +61 -0
  574. package/sdk/ios/usr/include/dispatch/group.h +289 -0
  575. package/sdk/ios/usr/include/dispatch/introspection.h +190 -0
  576. package/sdk/ios/usr/include/dispatch/io.h +617 -0
  577. package/sdk/ios/usr/include/dispatch/object.h +680 -0
  578. package/sdk/ios/usr/include/dispatch/once.h +128 -0
  579. package/sdk/ios/usr/include/dispatch/queue.h +1824 -0
  580. package/sdk/ios/usr/include/dispatch/semaphore.h +124 -0
  581. package/sdk/ios/usr/include/dispatch/source.h +803 -0
  582. package/sdk/ios/usr/include/dispatch/time.h +144 -0
  583. package/sdk/ios/usr/include/dispatch/workloop.h +178 -0
  584. package/sdk/ios/usr/include/dlfcn.h +320 -7
  585. package/sdk/ios/usr/include/execinfo.h +100 -10
  586. package/sdk/ios/usr/include/ftw.h +63 -0
  587. package/sdk/ios/usr/include/gethostuuid.h +45 -0
  588. package/sdk/ios/usr/include/libkern/arm/OSByteOrder.h +195 -0
  589. package/sdk/ios/usr/include/limits.h +167 -4
  590. package/sdk/ios/usr/include/mach/arm/boolean.h +74 -0
  591. package/sdk/ios/usr/include/mach/arm/exception.h +86 -0
  592. package/sdk/ios/usr/include/mach/arm/kern_return.h +78 -0
  593. package/sdk/ios/usr/include/mach/arm/processor_info.h +76 -0
  594. package/sdk/ios/usr/include/mach/arm/rpc.h +39 -0
  595. package/sdk/ios/usr/include/mach/arm/thread_state.h +42 -0
  596. package/sdk/ios/usr/include/mach/arm/thread_status.h +302 -0
  597. package/sdk/ios/usr/include/mach/arm/vm_param.h +118 -0
  598. package/sdk/ios/usr/include/mach/arm/vm_types.h +162 -0
  599. package/sdk/ios/usr/include/mach/boolean.h +88 -4
  600. package/sdk/ios/usr/include/mach/clock.h +249 -0
  601. package/sdk/ios/usr/include/mach/clock_priv.h +203 -0
  602. package/sdk/ios/usr/include/mach/clock_types.h +127 -0
  603. package/sdk/ios/usr/include/mach/dyld_kernel.h +66 -0
  604. package/sdk/ios/usr/include/mach/error.h +117 -0
  605. package/sdk/ios/usr/include/mach/exc.h +285 -0
  606. package/sdk/ios/usr/include/mach/exception_types.h +204 -25
  607. package/sdk/ios/usr/include/mach/host_info.h +136 -51
  608. package/sdk/ios/usr/include/mach/host_notify.h +39 -0
  609. package/sdk/ios/usr/include/mach/host_priv.h +1167 -0
  610. package/sdk/ios/usr/include/mach/host_security.h +225 -0
  611. package/sdk/ios/usr/include/mach/host_special_ports.h +315 -0
  612. package/sdk/ios/usr/include/mach/kern_return.h +291 -2
  613. package/sdk/ios/usr/include/mach/kmod.h +180 -0
  614. package/sdk/ios/usr/include/mach/mach.h +237 -12
  615. package/sdk/ios/usr/include/mach/mach_error.h +93 -10
  616. package/sdk/ios/usr/include/mach/mach_host.h +1329 -5
  617. package/sdk/ios/usr/include/mach/mach_init.h +112 -13
  618. package/sdk/ios/usr/include/mach/mach_interface.h +52 -0
  619. package/sdk/ios/usr/include/mach/mach_port.h +1935 -4
  620. package/sdk/ios/usr/include/mach/mach_time.h +77 -14
  621. package/sdk/ios/usr/include/mach/mach_traps.h +311 -0
  622. package/sdk/ios/usr/include/mach/mach_types.h +297 -20
  623. package/sdk/ios/usr/include/mach/mach_voucher_types.h +259 -0
  624. package/sdk/ios/usr/include/mach/machine/boolean.h +40 -0
  625. package/sdk/ios/usr/include/mach/machine/exception.h +40 -0
  626. package/sdk/ios/usr/include/mach/machine/kern_return.h +40 -0
  627. package/sdk/ios/usr/include/mach/machine/processor_info.h +40 -0
  628. package/sdk/ios/usr/include/mach/machine/rpc.h +40 -0
  629. package/sdk/ios/usr/include/mach/machine/thread_state.h +44 -0
  630. package/sdk/ios/usr/include/mach/machine/thread_status.h +40 -0
  631. package/sdk/ios/usr/include/mach/machine/vm_param.h +40 -0
  632. package/sdk/ios/usr/include/mach/machine/vm_types.h +40 -0
  633. package/sdk/ios/usr/include/mach/machine.h +456 -142
  634. package/sdk/ios/usr/include/mach/memory_object_types.h +312 -0
  635. package/sdk/ios/usr/include/mach/message.h +972 -0
  636. package/sdk/ios/usr/include/mach/mig.h +180 -0
  637. package/sdk/ios/usr/include/mach/mig_errors.h +125 -0
  638. package/sdk/ios/usr/include/mach/mig_strncpy_zerofill_support.h +35 -0
  639. package/sdk/ios/usr/include/mach/ndr.h +207 -0
  640. package/sdk/ios/usr/include/mach/notify.h +141 -0
  641. package/sdk/ios/usr/include/mach/policy.h +235 -0
  642. package/sdk/ios/usr/include/mach/port.h +648 -0
  643. package/sdk/ios/usr/include/mach/processor.h +364 -0
  644. package/sdk/ios/usr/include/mach/processor_info.h +171 -0
  645. package/sdk/ios/usr/include/mach/processor_set.h +589 -0
  646. package/sdk/ios/usr/include/mach/rpc.h +135 -0
  647. package/sdk/ios/usr/include/mach/semaphore.h +78 -0
  648. package/sdk/ios/usr/include/mach/std_types.h +75 -0
  649. package/sdk/ios/usr/include/mach/sync_policy.h +47 -0
  650. package/sdk/ios/usr/include/mach/task.h +2887 -7
  651. package/sdk/ios/usr/include/mach/task_info.h +584 -19
  652. package/sdk/ios/usr/include/mach/task_inspect.h +57 -0
  653. package/sdk/ios/usr/include/mach/task_policy.h +182 -26
  654. package/sdk/ios/usr/include/mach/task_special_ports.h +135 -0
  655. package/sdk/ios/usr/include/mach/thread_act.h +1550 -5
  656. package/sdk/ios/usr/include/mach/thread_info.h +206 -28
  657. package/sdk/ios/usr/include/mach/thread_policy.h +268 -0
  658. package/sdk/ios/usr/include/mach/thread_special_ports.h +87 -0
  659. package/sdk/ios/usr/include/mach/thread_status.h +100 -0
  660. package/sdk/ios/usr/include/mach/thread_switch.h +77 -0
  661. package/sdk/ios/usr/include/mach/time_value.h +96 -4
  662. package/sdk/ios/usr/include/mach/vm_attributes.h +99 -0
  663. package/sdk/ios/usr/include/mach/vm_behavior.h +86 -0
  664. package/sdk/ios/usr/include/mach/vm_inherit.h +93 -0
  665. package/sdk/ios/usr/include/mach/vm_map.h +1558 -0
  666. package/sdk/ios/usr/include/mach/vm_page_size.h +68 -0
  667. package/sdk/ios/usr/include/mach/vm_prot.h +183 -7
  668. package/sdk/ios/usr/include/mach/vm_purgable.h +166 -0
  669. package/sdk/ios/usr/include/mach/vm_region.h +400 -36
  670. package/sdk/ios/usr/include/mach/vm_statistics.h +387 -96
  671. package/sdk/ios/usr/include/mach/vm_sync.h +84 -0
  672. package/sdk/ios/usr/include/mach/vm_types.h +194 -7
  673. package/sdk/ios/usr/include/mach-o/arch.h +154 -16
  674. package/sdk/ios/usr/include/mach-o/fat.h +89 -0
  675. package/sdk/ios/usr/include/mach-o/getsect.h +146 -12
  676. package/sdk/ios/usr/include/mach-o/loader.h +1679 -139
  677. package/sdk/ios/usr/include/mach_debug/hash_info.h +75 -0
  678. package/sdk/ios/usr/include/mach_debug/ipc_info.h +199 -0
  679. package/sdk/ios/usr/include/mach_debug/lockgroup_info.h +74 -0
  680. package/sdk/ios/usr/include/mach_debug/mach_debug_types.h +200 -0
  681. package/sdk/ios/usr/include/mach_debug/page_info.h +64 -0
  682. package/sdk/ios/usr/include/mach_debug/vm_info.h +149 -0
  683. package/sdk/ios/usr/include/mach_debug/zone_info.h +209 -0
  684. package/sdk/ios/usr/include/machine/limits.h +14 -0
  685. package/sdk/ios/usr/include/module.modulemap +5 -0
  686. package/sdk/ios/usr/include/net/if_types.h +152 -0
  687. package/sdk/ios/usr/include/objc/NSObjCRuntime.h +10 -0
  688. package/sdk/ios/usr/include/objc/NSObject.h +23 -25
  689. package/sdk/ios/usr/include/objc/objc-api.h +310 -0
  690. package/sdk/ios/usr/include/objc/objc-sync.h +59 -0
  691. package/sdk/ios/usr/include/objc/objc.h +243 -0
  692. package/sdk/ios/usr/include/objc/runtime.h +1933 -0
  693. package/sdk/ios/usr/include/os.modulemap +11 -0
  694. package/sdk/ios/usr/include/pthread/pthread_impl.h +66 -0
  695. package/sdk/ios/usr/include/pthread/sched.h +46 -0
  696. package/sdk/ios/usr/include/pthread.h +754 -4
  697. package/sdk/ios/usr/include/pwd.h +119 -0
  698. package/sdk/ios/usr/include/sched.h +46 -0
  699. package/sdk/ios/usr/include/secure/_string.h +295 -0
  700. package/sdk/ios/usr/include/secure/_strings.h +96 -0
  701. package/sdk/ios/usr/include/spawn.h +193 -0
  702. package/sdk/ios/usr/include/stddef.h +90 -0
  703. package/sdk/ios/usr/include/stdlib.h +62 -17
  704. package/sdk/ios/usr/include/string.h +62 -8
  705. package/sdk/ios/usr/include/sys/_pthread/_pthread_cond_t.h +32 -0
  706. package/sdk/ios/usr/include/sys/_pthread/_pthread_condattr_t.h +32 -0
  707. package/sdk/ios/usr/include/sys/_pthread/_pthread_key_t.h +32 -0
  708. package/sdk/ios/usr/include/sys/_pthread/_pthread_mutex_t.h +32 -0
  709. package/sdk/ios/usr/include/sys/_pthread/_pthread_mutexattr_t.h +32 -0
  710. package/sdk/ios/usr/include/sys/_pthread/_pthread_once_t.h +32 -0
  711. package/sdk/ios/usr/include/sys/_pthread/_pthread_rwlock_t.h +32 -0
  712. package/sdk/ios/usr/include/sys/_pthread/_pthread_rwlockattr_t.h +32 -0
  713. package/sdk/ios/usr/include/sys/_select.h +57 -0
  714. package/sdk/ios/usr/include/sys/_types/_blkcnt_t.h +32 -0
  715. package/sdk/ios/usr/include/sys/_types/_blksize_t.h +32 -0
  716. package/sdk/ios/usr/include/sys/_types/_caddr_t.h +32 -0
  717. package/sdk/ios/usr/include/sys/_types/_dev_t.h +32 -0
  718. package/sdk/ios/usr/include/sys/_types/_fsblkcnt_t.h +32 -0
  719. package/sdk/ios/usr/include/sys/_types/_fsfilcnt_t.h +32 -0
  720. package/sdk/ios/usr/include/sys/_types/_fsid_t.h +32 -0
  721. package/sdk/ios/usr/include/sys/_types/_fsobj_id_t.h +38 -0
  722. package/sdk/ios/usr/include/sys/_types/_graftdmg_un.h +64 -0
  723. package/sdk/ios/usr/include/sys/_types/_guid_t.h +37 -0
  724. package/sdk/ios/usr/include/sys/_types/_id_t.h +32 -0
  725. package/sdk/ios/usr/include/sys/_types/_ino64_t.h +32 -0
  726. package/sdk/ios/usr/include/sys/_types/_key_t.h +32 -0
  727. package/sdk/ios/usr/include/sys/_types/_mach_port_t.h +51 -0
  728. package/sdk/ios/usr/include/sys/_types/_mbstate_t.h +33 -0
  729. package/sdk/ios/usr/include/sys/_types/_mount_t.h +34 -0
  730. package/sdk/ios/usr/include/sys/_types/_nlink_t.h +32 -0
  731. package/sdk/ios/usr/include/sys/_types/_os_inline.h +34 -0
  732. package/sdk/ios/usr/include/sys/_types/_posix_vdisable.h +30 -0
  733. package/sdk/ios/usr/include/sys/_types/_rsize_t.h +55 -0
  734. package/sdk/ios/usr/include/sys/_types/_suseconds_t.h +32 -0
  735. package/sdk/ios/usr/include/sys/_types/_timeval.h +39 -0
  736. package/sdk/ios/usr/include/sys/_types/_u_char.h +31 -0
  737. package/sdk/ios/usr/include/sys/_types/_u_int.h +31 -0
  738. package/sdk/ios/usr/include/sys/_types/_u_short.h +31 -0
  739. package/sdk/ios/usr/include/sys/_types/_useconds_t.h +32 -0
  740. package/sdk/ios/usr/include/sys/_types/_uuid_t.h +32 -0
  741. package/sdk/ios/usr/include/sys/_types/_vnode_t.h +34 -0
  742. package/sdk/ios/usr/include/sys/acl.h +215 -0
  743. package/sdk/ios/usr/include/sys/attr.h +635 -0
  744. package/sdk/ios/usr/include/sys/cdefs.h +20 -0
  745. package/sdk/ios/usr/include/sys/event.h +388 -0
  746. package/sdk/ios/usr/include/sys/ioccom.h +99 -0
  747. package/sdk/ios/usr/include/sys/kauth.h +409 -0
  748. package/sdk/ios/usr/include/sys/mount.h +470 -0
  749. package/sdk/ios/usr/include/sys/queue.h +909 -0
  750. package/sdk/ios/usr/include/sys/resource.h +600 -0
  751. package/sdk/ios/usr/include/sys/select.h +134 -0
  752. package/sdk/ios/usr/include/sys/spawn.h +84 -0
  753. package/sdk/ios/usr/include/sys/sysctl.h +803 -57
  754. package/sdk/ios/usr/include/sys/syslimits.h +131 -11
  755. package/sdk/ios/usr/include/sys/syslog.h +236 -0
  756. package/sdk/ios/usr/include/sys/types.h +236 -19
  757. package/sdk/ios/usr/include/sys/ucred.h +116 -0
  758. package/sdk/ios/usr/include/sys/un.h +105 -0
  759. package/sdk/ios/usr/include/sys/unistd.h +225 -0
  760. package/sdk/ios/usr/include/sys/vm.h +89 -0
  761. package/sdk/ios/usr/include/sys/wait.h +256 -0
  762. package/sdk/ios/usr/include/sysdir.h +79 -0
  763. package/sdk/ios/usr/include/syslog.h +24 -0
  764. package/sdk/ios/usr/include/unistd.h +799 -3
  765. package/sdk/ios/usr/include/uuid/uuid.h +69 -10
  766. package/sdk/ios/usr/include/wchar.h +71 -0
  767. package/sdk/ios/usr/include/wctype.h +35 -0
  768. package/sdk/ios/usr/include/xlocale/___wctype.h +146 -0
  769. package/sdk/ios/usr/include/xlocale/_ctype.h +240 -0
  770. package/sdk/ios/usr/include/xlocale/_stdlib.h +77 -0
  771. package/sdk/ios/usr/include/xlocale/_string.h +43 -0
  772. package/sdk/ios/usr/include/xlocale/_wchar.h +160 -0
  773. package/sdk/ios/usr/include/xlocale/_wctype.h +100 -0
  774. package/sdk/ios/usr/include/xlocale.h +61 -0
  775. package/sdk/ios/usr/include/xpc/availability.h +141 -0
  776. package/sdk/ios/usr/include/xpc/base.h +243 -0
  777. package/sdk/ios/wasm/include/AvailabilityInternal.h +24 -0
  778. package/sdk/ios/wasm/include/TargetConditionals.h +529 -0
  779. package/sdk/ios/wasm/include/_locale.h +3 -0
  780. package/sdk/ios/wasm/include/_locale_posix2008.h +3 -0
  781. package/sdk/ios/wasm/include/_types/_locale_t.h +3 -0
  782. package/sdk/ios/wasm/include/arpa/inet.h +15 -0
  783. package/sdk/ios/wasm/include/dirent.h +52 -0
  784. package/sdk/ios/wasm/include/dlfcn.h +13 -1
  785. package/sdk/ios/wasm/include/errno.h +22 -0
  786. package/sdk/ios/wasm/include/fcntl.h +31 -0
  787. package/sdk/ios/wasm/include/ftw.h +15 -0
  788. package/sdk/ios/wasm/include/libkern/_OSByteOrder.h +6 -0
  789. package/sdk/ios/wasm/include/limits.h +9 -0
  790. package/sdk/ios/wasm/include/mach/machine/boolean.h +1 -1
  791. package/sdk/ios/wasm/include/mach/machine/exception.h +1 -4
  792. package/sdk/ios/wasm/include/mach/machine/kern_return.h +1 -1
  793. package/sdk/ios/wasm/include/mach/machine/processor_info.h +1 -1
  794. package/sdk/ios/wasm/include/mach/machine/rpc.h +1 -1
  795. package/sdk/ios/wasm/include/mach/machine/thread_state.h +1 -2
  796. package/sdk/ios/wasm/include/mach/machine/thread_status.h +1 -2
  797. package/sdk/ios/wasm/include/mach/machine/vm_param.h +1 -2
  798. package/sdk/ios/wasm/include/mach/machine/vm_types.h +1 -17
  799. package/sdk/ios/wasm/include/machine/_endian.h +2 -0
  800. package/sdk/ios/wasm/include/machine/_param.h +2 -0
  801. package/sdk/ios/wasm/include/machine/endian.h +1 -1
  802. package/sdk/ios/wasm/include/machine/limits.h +106 -2
  803. package/sdk/ios/wasm/include/machine/param.h +152 -0
  804. package/sdk/ios/wasm/include/netinet/in.h +11 -0
  805. package/sdk/ios/wasm/include/os/object.h +10 -0
  806. package/sdk/ios/wasm/include/pthread.h +14 -0
  807. package/sdk/ios/wasm/include/stdio.h +36 -0
  808. package/sdk/ios/wasm/include/stdlib.h +39 -1
  809. package/sdk/ios/wasm/include/strings.h +9 -0
  810. package/sdk/ios/wasm/include/sys/_types/_iovec_t.h +6 -0
  811. package/sdk/ios/wasm/include/sys/_types/_mode_t.h +10 -0
  812. package/sdk/ios/wasm/include/sys/file.h +7 -0
  813. package/sdk/ios/wasm/include/sys/ioctl.h +6 -0
  814. package/sdk/ios/wasm/include/sys/mman.h +2 -2
  815. package/sdk/ios/wasm/include/sys/param.h +4 -0
  816. package/sdk/ios/wasm/include/sys/resource.h +43 -0
  817. package/sdk/ios/wasm/include/sys/socket.h +75 -9
  818. package/sdk/ios/wasm/include/sys/stat.h +63 -0
  819. package/sdk/ios/wasm/include/sys/syscall.h +9 -0
  820. package/sdk/ios/wasm/include/sys/time.h +10 -0
  821. package/sdk/ios/wasm/include/sys/types.h +13 -0
  822. package/sdk/ios/wasm/include/sys/un.h +7 -0
  823. package/sdk/ios/wasm/include/time.h +3 -1
  824. package/sdk/ios/wasm/include/unistd.h +25 -3
  825. package/sdk/ios/wasm/include/xlocale/_stdlib.h +37 -0
  826. package/sdk/ios/wasm/storage-include/TargetConditionals.h +529 -0
  827. package/sdk/ios/wasm/storage-include/mach/machine/boolean.h +2 -0
  828. package/sdk/ios/wasm/storage-include/mach/machine/exception.h +5 -0
  829. package/sdk/ios/wasm/storage-include/mach/machine/kern_return.h +2 -0
  830. package/sdk/ios/wasm/storage-include/mach/machine/processor_info.h +2 -0
  831. package/sdk/ios/wasm/storage-include/mach/machine/rpc.h +2 -0
  832. package/sdk/ios/wasm/storage-include/mach/machine/thread_state.h +3 -0
  833. package/sdk/ios/wasm/storage-include/mach/machine/thread_status.h +3 -0
  834. package/sdk/ios/wasm/storage-include/mach/machine/vm_param.h +3 -0
  835. package/sdk/ios/wasm/storage-include/mach/machine/vm_types.h +18 -0
  836. package/sdk/ios/wasm/storage-include/machine/_endian.h +9 -0
  837. package/sdk/ios/wasm/storage-include/machine/_param.h +8 -0
  838. package/sdk/ios/wasm/storage-include/machine/_types.h +31 -0
  839. package/sdk/ios/wasm/storage-include/machine/endian.h +2 -0
  840. package/sdk/ios/wasm/storage-include/machine/limits.h +2 -0
  841. package/sdk/ios/wasm/storage-include/machine/types.h +15 -0
  842. package/sdk/native-hashes.json +81 -0
  843. package/skills/contrast/SKILL.md +3 -2
  844. package/skills/peach-test/SKILL.md +7 -3
  845. package/src/admitted-mac-build.ts +3 -0
  846. package/src/android-app-identity.ts +18 -0
  847. package/src/android-root-module.ts +145 -0
  848. package/src/androidRootModuleContract.ts +39 -0
  849. package/src/appPackageContract.ts +81 -0
  850. package/src/assetCatalogContract.ts +10 -1
  851. package/src/backend-origin.ts +11 -8
  852. package/src/bridge-constants.ts +7 -0
  853. package/src/bridge-contract.ts +53 -1
  854. package/src/bundle-channel.mjs +21 -4
  855. package/src/capture-contract.ts +3 -1
  856. package/src/cli-runtime.ts +6 -1
  857. package/src/dev-bundle-resolution.ts +7 -27
  858. package/src/device-catalog.ts +10 -4
  859. package/src/dom-source-reference.ts +15 -0
  860. package/src/expo-discovery-cache.ts +376 -0
  861. package/src/expo-manifest-body.ts +33 -0
  862. package/src/expo-native-workspace.ts +80 -24
  863. package/src/expo-swift-host.ts +905 -47
  864. package/src/expo-swift-ready.ts +43 -11
  865. package/src/expoSwiftContract.ts +3 -0
  866. package/src/generated/swift-c-predefines.json +1 -1
  867. package/src/home-paths.ts +35 -1
  868. package/src/host/app-package-handler.ts +47 -0
  869. package/src/host/bridge-host.ts +31 -0
  870. package/src/host/fetch-proxy-handler.ts +19 -1
  871. package/src/host/network-policy-proxy.ts +421 -0
  872. package/src/host/network-policy.ts +121 -0
  873. package/src/host/staged-host-files.ts +98 -3
  874. package/src/host/websocket-frame-guard.ts +163 -0
  875. package/src/host/websocket-proxy-headers.ts +29 -0
  876. package/src/host/websocket-proxy.ts +100 -58
  877. package/src/index.ts +3 -0
  878. package/src/installed-native-build-options.ts +154 -0
  879. package/src/installed-package-versions.ts +56 -49
  880. package/src/kotlin-host.ts +21 -18
  881. package/src/kotlin-instance-source.ts +126 -0
  882. package/src/material-symbol-fonts.ts +6 -4
  883. package/src/menu.ts +13 -0
  884. package/src/metro-plugin.ts +8 -0
  885. package/src/native-app-identity-project.ts +11 -2
  886. package/src/native-app-identity.ts +27 -0
  887. package/src/native-dev-bundle-url.ts +0 -18
  888. package/src/native-firebase-config.ts +71 -5
  889. package/src/native-preparation.ts +30 -0
  890. package/src/nativePreparationContract.ts +3 -0
  891. package/src/nitro-adapter.lock.json +382 -230
  892. package/src/nitro-bundle.ts +33 -1
  893. package/src/nitro-compile.ts +46 -7
  894. package/src/nitro-dependencies.ts +228 -0
  895. package/src/nitro-source.ts +191 -37
  896. package/src/nitroContract.ts +7 -0
  897. package/src/packageVersionsContract.ts +33 -0
  898. package/src/react-native-bridge-modules.ts +81 -32
  899. package/src/react-native-host-modules.ts +141 -4
  900. package/src/reactNativeConfigurationContract.ts +14 -0
  901. package/src/reap-browser.ts +15 -3
  902. package/src/runtime-assets.ts +10 -0
  903. package/src/sdk.ts +5 -0
  904. package/src/settingsContract.ts +27 -1
  905. package/src/sim-client.ts +5 -2
  906. package/src/storageSnapshotContract.ts +25 -10
  907. package/src/stub-pattern-matcher.ts +17 -4
  908. package/src/swift-compile.ts +1385 -4156
  909. package/src/swift-compiler-digest.ts +1 -2
  910. package/src/swift-coverage/package.ts +103 -58
  911. package/src/swift-coverage/provenance.ts +1 -0
  912. package/src/swift-coverage/xcode-asset-symbols.ts +922 -0
  913. package/src/swift-coverage/xcode-assets.ts +101 -123
  914. package/src/swift-coverage/xcode-bridging.ts +1 -12
  915. package/src/swift-coverage/xcode-packages.ts +167 -52
  916. package/src/swift-coverage/xcode.ts +3 -7
  917. package/src/swift-cxx-declarations.ts +205 -0
  918. package/src/swift-cxx-deps.ts +48 -0
  919. package/src/swift-cxx-reachable.ts +298 -0
  920. package/src/swift-cxx-standin.ts +248 -0
  921. package/src/swift-distribution.lock.json +26 -16
  922. package/src/swift-host.ts +308 -41
  923. package/src/swift-icu.ts +1 -1
  924. package/src/swift-link-roots.ts +118 -0
  925. package/src/swift-objc-compile.ts +752 -238
  926. package/src/swift-objc-import.ts +25 -964
  927. package/src/swift-objc-runtime.ts +7 -0
  928. package/src/swift-objc-standin.ts +264 -56
  929. package/src/swift-package-manifest.ts +190 -41
  930. package/src/swift-package.ts +123 -3
  931. package/src/swift-packages.ts +262 -39
  932. package/src/swift-pdf-raster.ts +115 -0
  933. package/src/swift-root-lock.ts +17 -1
  934. package/src/swift-shared-sdk.ts +45 -0
  935. package/src/swift-source-file.ts +10 -6
  936. package/src/swift-source-pods.ts +2 -10
  937. package/src/swift-standin-digest.ts +12 -15
  938. package/src/swift-standin-emit.ts +600 -57
  939. package/src/swift-standins.ts +679 -105
  940. package/src/swift-submit.ts +26 -6
  941. package/src/swift-toolchain.ts +143 -18
  942. package/src/swiftContract.ts +50 -29
  943. package/src/turbo-codegen-intake.ts +91 -0
  944. package/src/vite-plugin-one.ts +13 -9
  945. package/src/vite-plugin.ts +28 -28
  946. package/src/workspace-root.ts +15 -0
  947. package/src/xcode-json-project.ts +52 -1
  948. package/src/xcode-project.ts +509 -38
  949. package/src/swift-objc-export.ts +0 -532
  950. package/src/swift-objc-metadata.ts +0 -534
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.1700 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1728 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
  var __create = Object.create;
3
3
  var __defProp = Object.defineProperty;
4
4
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
@@ -29,8 +29,10 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
29
29
  ));
30
30
 
31
31
  // <define:__SWIFT_COVERAGE_SOURCE_DIGESTS__>
32
+ var define_SWIFT_COVERAGE_SOURCE_DIGESTS_default;
32
33
  var init_define_SWIFT_COVERAGE_SOURCE_DIGESTS = __esm({
33
34
  "<define:__SWIFT_COVERAGE_SOURCE_DIGESTS__>"() {
35
+ define_SWIFT_COVERAGE_SOURCE_DIGESTS_default = { "swift-coverage/indexdump.ts": "1ecc9c90d7e293f9bdc57db5bf90f6670d2aed8f8f9bd647cd55b2c70347aa38", "swift-coverage/indexing.ts": "02b9e91dcee1f48b74bcc8e35fe5dda5442fa235221faf82f0cbaa416a7d5409", "swift-coverage/types.ts": "cfc696535808957bd491dc5f5eefc991f65395eb6fc7ea377c31a12b5c4c3b57", "swift-coverage/source.ts": "8b398ceb60faf4a5729842cab60f49c2e601d6fc6bbbc1faec9023ecb8141990", "swift-coverage/package.ts": "1f0068be7461fa7c5a7a891faf318f305cbed2e94c19667ba76627f7e5be260b", "swift-coverage/xcode.ts": "9b9efa33fcd6d78e3ab4218b0340a6bf96832faa98ea04f3966167f691043462", "swift-coverage/xcode-assets.ts": "f674c68408df22bff2ac80c89467b6cf4018c7e4ada6f2408d7b5f98ee83289d", "swift-coverage/xcode-asset-symbols.ts": "b94c5836f6f11c400c93b931ed0a980b8067d84a5f7a1ee75f24d6bdbf46013d", "swift-coverage/xcode-bridging.ts": "33184be8c5daf6646aa5a1276a4e15531f1be27b7c26f56550e0fbb1fc678a11", "swift-coverage/xcode-packages.ts": "b112ed694771c1df8d9f4dd86691ee83fc9302f05690fae9a5151d0623191b0b", "swift-coverage/xcode-strings.ts": "f2dd4c7cd8ef77035184b0132909c2fa09fd20ed06b7757c2f1f960bfdde031c", "swift-coverage/reader.ts": "da559b67ecd1161dea70c980b5f98f2c55af3550f0714479100fa5e9e813625c", "swift-coverage/provenance.ts": "eb3b41ae8b58b48f6758f084800f188dfb1edb227e483abdd6b80cde66e849b9", "swift-package-manifest.ts": "d9170f454c21b88b10902e601998b42179b94a8a2018f51f92f9ddafdfcfd8f6", "swift-package.ts": "36c0beef4686796e700a479135c58b1680dc30f73e2b6107891898aa46db33b0", "swift-source-file.ts": "7653751b3edfd63479f733427b6767847de0cd2267715c14dc18d6e5233c3a91", "swift-toolchain.ts": "3142399c278b7759ddd50c33a5569bb1a4eab38d19b3f0923064907c90e08e27", "home-paths.ts": "20c49992c57b1e7d279454ff4587208ae3d888bb2e318674a6d405750cdbdc24", "xcode-header-search.ts": "1cfadaf2b1b29fbd72899716fc2469b6b6ca39d6c2b61fee9927fb28668967c5", "xcode-project.ts": "64d7996165ac049f4baa8b04242d4550639c9c5de7d12f61ad0d05f58857d39d", "xcode-target-members.ts": "94e7daaf57b351aa716b2c49e39c5dec8db5377d938a4f16f2d88d9099813c35", "xcode-json-project.ts": "41990ebbe4b488eef34e74c4608b4b48e5a5b299ba98ca7fbcfdfa0e77be63b6", "openstep-plist.ts": "74e6ce1dac80c9c318e0e9f5e3e8cd19a898a8820c36fc160609695bcb59dcd3" };
34
36
  }
35
37
  });
36
38
 
@@ -1153,9 +1155,9 @@ var require_lib = __commonJS({
1153
1155
 
1154
1156
  // src/native-app-identity-project.ts
1155
1157
  init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
1156
- import fs2 from "node:fs";
1158
+ import fs5 from "node:fs";
1157
1159
  import { createRequire } from "node:module";
1158
- import path3 from "node:path";
1160
+ import path6 from "node:path";
1159
1161
 
1160
1162
  // src/android-app-identity.ts
1161
1163
  init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
@@ -1292,6 +1294,13 @@ function nativeAppIdentityFromAndroidManifest(source, file, files = {}) {
1292
1294
  ...max === void 0 ? {} : { maxSdkVersion: Number(max) }
1293
1295
  });
1294
1296
  }
1297
+ let androidPhotoLibraryAddOnly;
1298
+ for (const element of application.children) {
1299
+ if (element.name !== "meta-data" || element.attributes[`${attribute}name`] !== "one.photoLibrary.addOnly")
1300
+ continue;
1301
+ if (/^(?:true|True|TRUE)$/.test(element.attributes[`${attribute}value`]?.trim() ?? ""))
1302
+ androidPhotoLibraryAddOnly = true;
1303
+ }
1295
1304
  let label = application.attributes[`${attribute}label`];
1296
1305
  let applicationName = null;
1297
1306
  if (label && !/\$\{|^[@?]/.test(label)) applicationName = label;
@@ -1330,7 +1339,8 @@ function nativeAppIdentityFromAndroidManifest(source, file, files = {}) {
1330
1339
  buildVersion,
1331
1340
  bundleIdentifier,
1332
1341
  platform: "android",
1333
- androidManifestPermissions
1342
+ androidManifestPermissions,
1343
+ ...androidPhotoLibraryAddOnly === void 0 ? {} : { androidPhotoLibraryAddOnly }
1334
1344
  };
1335
1345
  }
1336
1346
  function androidMergedResourceValuesDirectory(manifestFile) {
@@ -1534,7 +1544,7 @@ function parseOpenStepPlist(text2) {
1534
1544
  init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
1535
1545
  var NEVER_MEMBER = /(?:^|\/)(?:Info\.plist|[^/]+\.entitlements|[^/]+\.xcconfig|\.DS_Store)$/;
1536
1546
  var BUNDLE_DIR = /\.(xcassets|bundle|lproj|xcdatamodeld|scnassets|spriteatlas|rcproject|storyboardc|icon)$/;
1537
- function xcodePathResolver(objects, projectDir, join2) {
1547
+ function xcodePathResolver(objects, projectDir, join4) {
1538
1548
  const parents = /* @__PURE__ */ new Map();
1539
1549
  for (const [id, entry] of Object.entries(objects)) {
1540
1550
  if (!isDict(entry)) continue;
@@ -1552,11 +1562,11 @@ function xcodePathResolver(objects, projectDir, join2) {
1552
1562
  const own = str(entry.path) ?? "";
1553
1563
  const tree = str(entry.sourceTree) ?? "<group>";
1554
1564
  if (tree === "<absolute>") result = own;
1555
- else if (tree === "SOURCE_ROOT") result = join2(projectDir, own);
1565
+ else if (tree === "SOURCE_ROOT") result = join4(projectDir, own);
1556
1566
  else if (tree === "<group>") {
1557
1567
  const parent = parents.get(id);
1558
1568
  const base = parent ? resolve(parent) : projectDir;
1559
- if (base !== null) result = join2(base, own);
1569
+ if (base !== null) result = join4(base, own);
1560
1570
  }
1561
1571
  }
1562
1572
  paths.set(id, result);
@@ -1564,7 +1574,7 @@ function xcodePathResolver(objects, projectDir, join2) {
1564
1574
  };
1565
1575
  return resolve;
1566
1576
  }
1567
- function visitXcodeTargetMembers(objects, targetId, resolvePath, filesUnder, join2, visit) {
1577
+ function visitXcodeTargetMembers(objects, targetId, resolvePath, filesUnder, join4, visit) {
1568
1578
  const target = objects[targetId];
1569
1579
  if (!isDict(target)) return;
1570
1580
  for (const phaseId of list(target.buildPhases)) {
@@ -1600,7 +1610,7 @@ function visitXcodeTargetMembers(objects, targetId, resolvePath, filesUnder, joi
1600
1610
  for (const relative2 of list(exception.membershipExceptions))
1601
1611
  exceptions.add(relative2);
1602
1612
  }
1603
- const members = owned.has(groupId) ? filesUnder(folder) : [...exceptions].flatMap((relative2) => filesUnder(join2(folder, relative2)));
1613
+ const members = owned.has(groupId) ? filesUnder(folder) : [...exceptions].flatMap((relative2) => filesUnder(join4(folder, relative2)));
1604
1614
  for (const file of members) {
1605
1615
  const relative2 = file.slice(prefix.length);
1606
1616
  const excepted = [...exceptions].some(
@@ -1733,10 +1743,10 @@ function appTargetReleaseSettings(pbxproj, targetName, infoPlistRelativePath) {
1733
1743
  var APP_DELEGATE_PATH_RE = /(?:^|\/)ios\/([^/]+)\/AppDelegate\.(?:swift|mm|m)$/;
1734
1744
  function nativeAppIdentityFromIos(files, parseInfoPlist, iosTarget, resourceUri) {
1735
1745
  const pbxprojPath = Object.keys(files).find(
1736
- (path4) => /(?:^|\/)ios\/[^/]+\.xcodeproj\/project\.pbxproj$/.test(path4)
1746
+ (path7) => /(?:^|\/)ios\/[^/]+\.xcodeproj\/project\.pbxproj$/.test(path7)
1737
1747
  ) ?? Object.keys(files).find(
1738
- (path4) => /(?:^|\/)[^/]+\.xcodeproj\/project\.pbxproj$/.test(path4)
1739
- ) ?? Object.keys(files).find((path4) => /(?:^|\/)project\.pbxproj$/.test(path4));
1748
+ (path7) => /(?:^|\/)[^/]+\.xcodeproj\/project\.pbxproj$/.test(path7)
1749
+ ) ?? Object.keys(files).find((path7) => /(?:^|\/)project\.pbxproj$/.test(path7));
1740
1750
  if (!pbxprojPath) return null;
1741
1751
  const pbxproj = files[pbxprojPath];
1742
1752
  let objects = {};
@@ -1778,7 +1788,7 @@ function nativeAppIdentityFromIos(files, parseInfoPlist, iosTarget, resourceUri)
1778
1788
  } else if (applicationTargetNames.size === 1) {
1779
1789
  targetName = [...applicationTargetNames][0];
1780
1790
  } else if (applicationTargetNames.size > 1) {
1781
- const delegateTargets = Object.keys(files).filter((path4) => !path4.includes("/Pods/")).map((path4) => path4.match(APP_DELEGATE_PATH_RE)?.[1]).filter(
1791
+ const delegateTargets = Object.keys(files).filter((path7) => !path7.includes("/Pods/")).map((path7) => path7.match(APP_DELEGATE_PATH_RE)?.[1]).filter(
1782
1792
  (name) => typeof name === "string" && applicationTargetNames.has(name)
1783
1793
  );
1784
1794
  if (delegateTargets.length === 1) {
@@ -1976,7 +1986,7 @@ function nativeAppIdentityFromIos(files, parseInfoPlist, iosTarget, resourceUri)
1976
1986
  if (resourceUri) {
1977
1987
  if (!selectedTarget)
1978
1988
  throw new Error("native app icon target membership is unresolved");
1979
- const join2 = (base, own) => {
1989
+ const join4 = (base, own) => {
1980
1990
  const segments = [];
1981
1991
  for (const segment of `${base}/${own}`.split("/")) {
1982
1992
  if (segment === "" || segment === ".") continue;
@@ -1989,7 +1999,7 @@ function nativeAppIdentityFromIos(files, parseInfoPlist, iosTarget, resourceUri)
1989
1999
  const project = Object.values(objects).find(
1990
2000
  (object) => isRecord(object) && object.isa === "PBXProject"
1991
2001
  );
1992
- const projectDir = join2(
2002
+ const projectDir = join4(
1993
2003
  pbxprojPath.replace(/(?:^|\/)[^/]+\.xcodeproj\/project\.pbxproj$/, ""),
1994
2004
  isRecord(project) && typeof project.projectDirPath === "string" ? project.projectDirPath : ""
1995
2005
  );
@@ -1997,15 +2007,15 @@ function nativeAppIdentityFromIos(files, parseInfoPlist, iosTarget, resourceUri)
1997
2007
  visitXcodeTargetMembers(
1998
2008
  objects,
1999
2009
  selectedTarget.id,
2000
- xcodePathResolver(objects, projectDir, join2),
2010
+ xcodePathResolver(objects, projectDir, join4),
2001
2011
  (file) => {
2002
2012
  if (Object.hasOwn(files, file)) return [file];
2003
2013
  const prefix = file === "" ? "" : `${file.replace(/\/$/, "")}/`;
2004
2014
  return paths.filter(
2005
- (path4) => path4.startsWith(prefix) && !/(?:^|\/)\./.test(path4.slice(prefix.length))
2015
+ (path7) => path7.startsWith(prefix) && !/(?:^|\/)\./.test(path7.slice(prefix.length))
2006
2016
  );
2007
2017
  },
2008
- join2,
2018
+ join4,
2009
2019
  (file, kind) => {
2010
2020
  if (kind === "resource") resources.add(file);
2011
2021
  }
@@ -2013,7 +2023,7 @@ function nativeAppIdentityFromIos(files, parseInfoPlist, iosTarget, resourceUri)
2013
2023
  }
2014
2024
  const rootModuleName = readRootModuleName(
2015
2025
  Object.entries(files).filter(
2016
- ([path4]) => !path4.includes("/Pods/") && (/(?:^|\/)ios\/AppDelegate\.(?:swift|mm|m)$/.test(path4) || path4.match(APP_DELEGATE_PATH_RE)?.[1] === targetName)
2026
+ ([path7]) => !path7.includes("/Pods/") && (/(?:^|\/)ios\/AppDelegate\.(?:swift|mm|m)$/.test(path7) || path7.match(APP_DELEGATE_PATH_RE)?.[1] === targetName)
2017
2027
  ).map(([, source]) => source)
2018
2028
  );
2019
2029
  return {
@@ -2106,31 +2116,219 @@ function parsePlistSource(source) {
2106
2116
 
2107
2117
  // src/xcode-project.ts
2108
2118
  init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
2109
- import { execFileSync as execFileSync2 } from "node:child_process";
2110
- import { createHash as createHash2 } from "node:crypto";
2111
- import fs from "node:fs";
2112
- import path2 from "node:path";
2119
+ import { execFileSync as execFileSync3 } from "node:child_process";
2120
+ import { createHash as createHash5 } from "node:crypto";
2121
+ import fs4 from "node:fs";
2122
+ import path5 from "node:path";
2113
2123
  import plist2 from "plist";
2114
2124
 
2115
2125
  // src/swift-coverage/xcode-assets.ts
2116
2126
  init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
2117
- import { execFileSync } from "node:child_process";
2127
+ import { createHash as createHash2 } from "node:crypto";
2128
+ import { readFileSync as readFileSync3, readdirSync as readdirSync2, statSync, writeFileSync } from "node:fs";
2129
+ import { join as join3, relative, sep } from "node:path";
2130
+
2131
+ // src/swift-coverage/provenance.ts
2132
+ init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
2118
2133
  import { createHash } from "node:crypto";
2119
- import {
2120
- mkdirSync,
2121
- mkdtempSync,
2122
- readFileSync,
2123
- readdirSync,
2124
- rmSync,
2125
- statSync
2126
- } from "node:fs";
2127
- import { tmpdir } from "node:os";
2128
- import { join, relative, sep } from "node:path";
2129
- var assetSymbolSettingKeys = [
2130
- "ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOLS",
2131
- "ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS",
2132
- "PRODUCT_BUNDLE_IDENTIFIER",
2133
- "TARGETED_DEVICE_FAMILY",
2134
+ import { readFileSync } from "node:fs";
2135
+ import { join } from "node:path";
2136
+ var SWIFT_COVERAGE_DIGEST_SOURCES = [
2137
+ "swift-coverage/indexdump.ts",
2138
+ "swift-coverage/indexing.ts",
2139
+ "swift-coverage/types.ts",
2140
+ "swift-coverage/source.ts",
2141
+ "swift-coverage/package.ts",
2142
+ "swift-coverage/xcode.ts",
2143
+ "swift-coverage/xcode-assets.ts",
2144
+ "swift-coverage/xcode-asset-symbols.ts",
2145
+ "swift-coverage/xcode-bridging.ts",
2146
+ "swift-coverage/xcode-packages.ts",
2147
+ "swift-coverage/xcode-strings.ts",
2148
+ "swift-coverage/reader.ts",
2149
+ "swift-coverage/provenance.ts",
2150
+ "swift-package-manifest.ts",
2151
+ "swift-package.ts",
2152
+ "swift-source-file.ts",
2153
+ "swift-toolchain.ts",
2154
+ "home-paths.ts",
2155
+ "xcode-header-search.ts",
2156
+ "xcode-project.ts",
2157
+ "xcode-target-members.ts",
2158
+ "xcode-json-project.ts",
2159
+ "openstep-plist.ts"
2160
+ ];
2161
+ function swiftCoverageSourceDigests(srcDir) {
2162
+ return Object.fromEntries(
2163
+ SWIFT_COVERAGE_DIGEST_SOURCES.map((file) => [
2164
+ file,
2165
+ createHash("sha256").update(readFileSync(join(srcDir, file))).digest("hex")
2166
+ ])
2167
+ );
2168
+ }
2169
+ var swiftCoverageProvenance = typeof define_SWIFT_COVERAGE_SOURCE_DIGESTS_default === "object" ? define_SWIFT_COVERAGE_SOURCE_DIGESTS_default : swiftCoverageSourceDigests(join(import.meta.dirname, ".."));
2170
+
2171
+ // src/swift-coverage/xcode-asset-symbols.ts
2172
+ init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
2173
+ import { existsSync, readdirSync, readFileSync as readFileSync2 } from "node:fs";
2174
+ import { extname, join as join2 } from "node:path";
2175
+ var silentTypes = /* @__PURE__ */ new Set([
2176
+ "appiconset",
2177
+ "brandassets",
2178
+ "dataset",
2179
+ "iconset",
2180
+ "iconstack",
2181
+ "iconstackgroup",
2182
+ "launchimage",
2183
+ "stickerpack",
2184
+ "stickersiconset",
2185
+ "textureset"
2186
+ ]);
2187
+ var stackTypes = /* @__PURE__ */ new Set(["imagestack", "solidimagestack"]);
2188
+ var unprovenTypes = /* @__PURE__ */ new Set([
2189
+ "arobject",
2190
+ "arreferenceimage",
2191
+ "arresourcegroup",
2192
+ "complicationset",
2193
+ "cubetextureset",
2194
+ "gcdashboardimage",
2195
+ "gcleaderboard",
2196
+ "gcleaderboardset",
2197
+ "glyphset",
2198
+ "iconbadgeset",
2199
+ "iconstacklayer",
2200
+ "imagestacklayer",
2201
+ "mipmapset",
2202
+ "modelset",
2203
+ "sidebariconset",
2204
+ "solidimagestacklayer",
2205
+ "sticker",
2206
+ "stickerframeset",
2207
+ "stickersequence"
2208
+ ]);
2209
+ var knownTypes = /* @__PURE__ */ new Set([
2210
+ "colorset",
2211
+ "imageset",
2212
+ "symbolset",
2213
+ "spriteatlas",
2214
+ ...silentTypes,
2215
+ ...stackTypes,
2216
+ ...unprovenTypes
2217
+ ]);
2218
+ var compressionTypes = [
2219
+ "automatic",
2220
+ "lossless",
2221
+ "lossy",
2222
+ "gpu-optimized-best",
2223
+ "gpu-optimized-smallest"
2224
+ ];
2225
+ var renditionRules = {
2226
+ appearances: "objects",
2227
+ locale: "string",
2228
+ platform: "string",
2229
+ resizing: "object",
2230
+ "alignment-insets": "object",
2231
+ "compression-type": compressionTypes,
2232
+ "display-gamut": ["sRGB", "display-P3"],
2233
+ "minimum-system-version": "string",
2234
+ "matching-style": "string",
2235
+ "template-rendering-intent": "string",
2236
+ size: "string",
2237
+ role: "string",
2238
+ orientation: "string",
2239
+ extent: "string"
2240
+ };
2241
+ var setRules = {
2242
+ localizable: "any",
2243
+ "auto-scaling": "string",
2244
+ "symbol-rendering-intent": "string",
2245
+ "provides-namespace": "any",
2246
+ "on-demand-resource-tags": "any",
2247
+ "template-rendering-intent": "string",
2248
+ "preserves-vector-representation": "any"
2249
+ };
2250
+ var inclusionRules = {
2251
+ idiom: "any",
2252
+ subtype: "any",
2253
+ unassigned: "any"
2254
+ };
2255
+ var rules = {
2256
+ // colors check none of the image traits
2257
+ colorset: {
2258
+ entry: {
2259
+ ...renditionRules,
2260
+ ...inclusionRules,
2261
+ color: "any",
2262
+ scale: "string",
2263
+ "language-direction": "string",
2264
+ "width-class": "string",
2265
+ "height-class": "string",
2266
+ memory: "string",
2267
+ "graphics-feature-set": "string",
2268
+ "screen-width": "string"
2269
+ },
2270
+ set: setRules
2271
+ },
2272
+ imageset: {
2273
+ entry: {
2274
+ ...renditionRules,
2275
+ ...inclusionRules,
2276
+ filename: "any",
2277
+ scale: ["1x", "2x", "3x"],
2278
+ "language-direction": ["left-to-right", "right-to-left"],
2279
+ "width-class": ["compact", "regular", "unspecified"],
2280
+ "height-class": ["compact", "regular"],
2281
+ memory: ["1GB", "2GB", "3GB", "4GB", "6GB", "8GB", "12GB", "16GB"],
2282
+ "graphics-feature-set": [
2283
+ ...Array.from({ length: 10 }, (_, i) => `apple${i + 1}`),
2284
+ "metal1v2",
2285
+ "metal2v2",
2286
+ "metal3v1",
2287
+ "metal3v2",
2288
+ "metal4v1"
2289
+ ],
2290
+ "screen-width": "string"
2291
+ },
2292
+ // an image whose vector flag is not a boolean is dropped
2293
+ set: {
2294
+ ...setRules,
2295
+ "preserves-vector-representation": "boolean",
2296
+ "compression-type": compressionTypes
2297
+ }
2298
+ },
2299
+ symbolset: {
2300
+ entry: { idiom: "any", filename: "any" },
2301
+ set: { "symbol-rendering-intent": "any" }
2302
+ }
2303
+ };
2304
+ var swiftKeywords = new Set(
2305
+ "precedencegroup associatedtype fileprivate fallthrough extension typealias subscript continue internal Protocol protocol operator rethrows private default public static switch return throws repeat struct deinit import guard while where false catch break defer super class inout throw func Type case else true Self self enum init nil var for let Any try if in do as is _".split(
2306
+ " "
2307
+ )
2308
+ );
2309
+ var nsColorConflicts = new Set(
2310
+ "unemphasizedSelectedContentBackgroundColor unemphasizedSelectedTextBackgroundColor controlAlternatingRowBackgroundColors alternatingContentBackgroundColors systemColorsDidChangeNotification alternateSelectedControlTextColor selectedContentBackgroundColor alternateSelectedControlColor secondarySelectedControlColor unemphasizedSelectedTextColor selectedTextBackgroundColor keyboardFocusIndicatorColor scrubberTexturedBackground controlLightHighlightColor selectedMenuItemTextColor underPageBackgroundColor disabledControlTextColor selectedControlTextColor controlBackgroundColor controlDarkShadowColor windowBackgroundColor selectedMenuItemColor controlHighlightColor quaternaryLabelColor selectedControlColor windowFrameTextColor placeholderTextColor textBackgroundColor secondaryLabelColor tertiaryLabelColor findHighlightColor controlAccentColor controlShadowColor currentControlTint selectedKnobColor selectedTextColor windowFrameColor controlTextColor headerTextColor scrollBarColor separatorColor highlightColor ignoresAlpha systemOrange systemPurple systemIndigo controlColor systemYellow systemGreen systemBrown headerColor shadowColor systemBlue systemPink systemTeal systemCyan labelColor systemMint systemGray systemRed knobColor gridColor linkColor textColor lightGray darkGray magenta orange purple yellow white black green brown clear blue cyan gray red".split(
2311
+ " "
2312
+ )
2313
+ );
2314
+ var uiColorConflicts = new Set(
2315
+ "secondarySystemGroupedBackground tertiarySystemGroupedBackground secondarySystemBackground tertiarySystemBackground groupTableViewBackground systemGroupedBackground quaternarySystemFill smallSystemFontSize secondarySystemFill tertiarySystemFill systemBackground quaternaryLabel opaqueSeparator placeholderText systemFontSize buttonFontSize secondaryLabel labelFontSize tertiaryLabel systemOrange systemPurple systemIndigo systemYellow systemGray2 systemGray3 systemGray4 systemGray5 systemGray6 systemGreen systemBrown systemBlue systemPink systemTeal systemFill systemCyan systemMint systemGray systemRed tintColor separator lightText lightGray darkText darkGray magenta orange purple yellow white black label green brown clear blue link cyan gray red".split(
2316
+ " "
2317
+ )
2318
+ );
2319
+ var colorConflicts = new Set(
2320
+ "transferRepresentation accentColor secondary primary orange purple indigo yellow white black green brown clear blue pink teal cyan mint gray red".split(
2321
+ " "
2322
+ )
2323
+ );
2324
+ var nsImageConflicts = new Set(
2325
+ "touchBarAudioOutputVolumeMediumTemplateName touchBarAudioOutputVolumeHighTemplateName touchBarAudioOutputVolumeOffTemplateName touchBarAudioOutputVolumeLowTemplateName touchBarTextJustifiedAlignTemplateName touchBarCommunicationVideoTemplateName touchBarCommunicationAudioTemplateName touchBarSkipAhead30SecondsTemplateName touchBarSkipAhead15SecondsTemplateName touchBarTextStrikethroughTemplateName touchBarSkipBack30SecondsTemplateName touchBarSkipBack15SecondsTemplateName stopProgressFreestandingTemplateName touchBarAudioOutputMuteTemplateName invalidDataFreestandingTemplateName touchBarEnterFullScreenTemplateName touchBarTextCenterAlignTemplateName touchBarAudioInputMuteTemplateName followLinkFreestandingTemplateName touchBarExitFullScreenTemplateName touchBarTextRightAlignTemplateName touchBarTextUnderlineTemplateName touchBarTextLeftAlignTemplateName touchBarOpenInBrowserTemplateName touchBarFolderMoveToTemplateName touchBarFolderCopyToTemplateName touchBarFastForwardTemplateName rightFacingTriangleTemplateName refreshFreestandingTemplateName touchBarRotateRightTemplateName touchBarRecordStartTemplateName touchBarSkipToStartTemplateName touchBarTextItalicTemplateName touchBarNewMessageTemplateName leftFacingTriangleTemplateName revealFreestandingTemplateName touchBarVolumeDownTemplateName touchBarRecordStopTemplateName touchBarRotateLeftTemplateName touchBarAudioInputTemplateName touchBarColorPickerStrokeName touchBarSkipAheadTemplateName touchBarSkipToEndTemplateName touchBarGoForwardTemplateName touchBarPlayPauseTemplateName touchBarQuickLookTemplateName touchBarAddDetailTemplateName touchBarUserGroupTemplateName touchBarNewFolderTemplateName touchBarBookmarksTemplateName touchBarSlideshowTemplateName statusPartiallyAvailableName touchBarPlayheadTemplateName touchBarDownloadTemplateName touchBarTextBoldTemplateName touchBarSkipBackTemplateName touchBarVolumeUpTemplateName touchBarTextListTemplateName touchBarIconViewTemplateName touchBarListViewTemplateName touchBarUserAddTemplateName touchBarComposeTemplateName touchBarRefreshTemplateName enterFullScreenTemplateName touchBarTagIconTemplateName touchBarGetInfoTemplateName touchBarSidebarTemplateName touchBarTextBoxTemplateName touchBarHistoryTemplateName touchBarColorPickerFillName touchBarColorPickerFontName touchBarRewindTemplateName menuMixedStateTemplateName touchBarDeleteTemplateName touchBarRemoveTemplateName touchBarSearchTemplateName touchBarGoBackTemplateName exitFullScreenTemplateName touchBarGoDownTemplateName touchBarFolderTemplateName touchBarShareTemplateName touchBarPauseTemplateName touchBarAlarmTemplateName lockUnlockedTemplateName touchBarMailTemplateName touchBarGoUpTemplateName touchBarUserTemplateName iChatTheaterTemplateName stopProgressTemplateName touchBarPlayTemplateName touchBarAddTemplateName menuOnStateTemplateName lockLockedTemplateName smartBadgeTemplateName columnViewTemplateName preferencesGeneralName statusUnavailableName goForwardTemplateName bluetoothTemplateName quickLookTemplateName bookmarksTemplateName slideshowTemplateName multipleDocumentsName iconViewTemplateName listViewTemplateName flowViewTemplateName imageUnfilteredTypes statusAvailableName refreshTemplateName goRightTemplateName applicationIconName folderBurnableName removeTemplateName goBackTemplateName actionTemplateName goLeftTemplateName shareTemplateName homeTemplateName pathTemplateName userAccountsName addTemplateName folderSmartName statusNoneName colorPanelName trashEmptyName fontPanelName trashFullName userGroupName userGuestName advancedName mobileMeName everyoneName computerName networkName cautionName bonjourName folderName imageTypes infoName userName".split(
2326
+ " "
2327
+ )
2328
+ );
2329
+
2330
+ // src/swift-coverage/xcode-assets.ts
2331
+ var unprovenAssetSettings = [
2134
2332
  "ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOL_FRAMEWORKS",
2135
2333
  "ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOL_WARNINGS",
2136
2334
  "ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOL_ERRORS",
@@ -2139,10 +2337,16 @@ var assetSymbolSettingKeys = [
2139
2337
  "ASSETCATALOG_COMPILER_GENERATE_OBJC_ASSET_SYMBOLS_PATH",
2140
2338
  "ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOL_INDEX_PATH",
2141
2339
  "ASSETCATALOG_COMPILER_BUNDLE_IDENTIFIER",
2142
- "ASSETCATALOG_COMPILER_LIGHTWEIGHT_ASSET_RUNTIME_MODE",
2340
+ "ASSETCATALOG_COMPILER_LIGHTWEIGHT_ASSET_RUNTIME_MODE"
2341
+ ];
2342
+ var assetSymbolSettingKeys = [
2343
+ "ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOLS",
2344
+ "ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS",
2345
+ "PRODUCT_BUNDLE_IDENTIFIER",
2346
+ "TARGETED_DEVICE_FAMILY",
2347
+ ...unprovenAssetSettings,
2143
2348
  "ASSETCATALOG_OTHER_FLAGS"
2144
2349
  ];
2145
- var unprovenAssetSettings = assetSymbolSettingKeys.slice(4);
2146
2350
 
2147
2351
  // src/swift-package.ts
2148
2352
  init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
@@ -2161,6 +2365,8 @@ function isSwiftNativeTranslationUnit(file) {
2161
2365
  }
2162
2366
  var SWIFT_NATIVE_SOURCE_EXTENSIONS = [
2163
2367
  ...SWIFT_NATIVE_TRANSLATION_UNIT_EXTENSIONS,
2368
+ ".s",
2369
+ ".S",
2164
2370
  ".h",
2165
2371
  ".hh",
2166
2372
  ".hpp",
@@ -2170,17 +2376,497 @@ var SWIFT_NATIVE_SOURCE_EXTENSIONS = [
2170
2376
  ".inl",
2171
2377
  ".modulemap"
2172
2378
  ];
2379
+ function moduleMapTokens(text2) {
2380
+ return (text2.match(/\/\*[\s\S]*?\*\/|\/\/[^\n]*|"[^"]*"|[\w.*]+|[{}\[\]]/g) ?? []).filter((token) => !token.startsWith("/"));
2381
+ }
2173
2382
  function moduleMapName(text2) {
2174
- return /(?:^|\s)module\s+(\w+)/.exec(text2)?.[1];
2383
+ const tokens = moduleMapTokens(text2);
2384
+ const index = tokens.findIndex(
2385
+ (token, i) => token === "module" && tokens[i - 1] !== "extern"
2386
+ );
2387
+ return index < 0 ? void 0 : tokens[index + 1];
2388
+ }
2389
+ function swiftPackageIdentity(url) {
2390
+ const path7 = url.endsWith("/") ? url.slice(0, -1) : url;
2391
+ return (path7.split("/").pop() ?? path7).replace(/\.git$/, "").toLowerCase();
2392
+ }
2393
+
2394
+ // src/swift-package-manifest.ts
2395
+ init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
2396
+ import { execFileSync as execFileSync2 } from "node:child_process";
2397
+ import { createHash as createHash4 } from "node:crypto";
2398
+ import fs3 from "node:fs";
2399
+ import os2 from "node:os";
2400
+ import path3 from "node:path";
2401
+
2402
+ // src/home-paths.ts
2403
+ init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
2404
+ import { randomUUID } from "node:crypto";
2405
+ import fs from "node:fs";
2406
+ import { homedir } from "node:os";
2407
+ import path from "node:path";
2408
+ var PEACH_HOME_ENV = "PEACH_HOME";
2409
+ function rnxHomeDir() {
2410
+ const override = process.env[PEACH_HOME_ENV];
2411
+ if (override && override.length > 0) return path.resolve(override);
2412
+ return path.join(homedir(), ".peach");
2413
+ }
2414
+ function cacheDir() {
2415
+ return path.join(rnxHomeDir(), "cache");
2416
+ }
2417
+ var BUILDERS_ROOT_ENV = "CONTRAST_BUILDERS_ROOT";
2418
+ function buildersRootEnv() {
2419
+ const root = process.env[BUILDERS_ROOT_ENV]?.trim();
2420
+ return root ? root : null;
2421
+ }
2422
+ function swiftCacheDir() {
2423
+ const root = buildersRootEnv();
2424
+ return root ? path.join(root, "peach-cache") : cacheDir();
2425
+ }
2426
+ function swiftPackageCacheOptions() {
2427
+ const root = path.join(swiftCacheDir(), "swiftpm");
2428
+ return ["cache", "config", "security"].flatMap((name) => [
2429
+ `--${name}-path`,
2430
+ path.join(root, name)
2431
+ ]);
2432
+ }
2433
+ var DAEMON_LOCKFILE_MAX_BYTES = 16 * 1024;
2434
+
2435
+ // src/swift-distribution.lock.json
2436
+ var swift_distribution_lock_default = {
2437
+ id: "95a0e12e7c0af807",
2438
+ release: "swift-6.4.0-RELEASE-custom-0b2d0a9011c88e66",
2439
+ wasmSdkId: "swift-6.4.0-RELEASE_wasm-peach-cbf01f4b",
2440
+ wasmSdkUrl: "https://r2.sootsim.com/swift-wasm-sdk/swift-6.4.0-RELEASE_wasm-peach-cbf01f4b.artifactbundle.tar.gz",
2441
+ wasmSdkChecksum: "2243db65b12743d577fecc6aa27761363ccef470202f1fef2582e58750c0da4f",
2442
+ source: "56ee2df2c863050b8261f4f20f6a51c008682ce9",
2443
+ targets: [
2444
+ "ImagePlayground",
2445
+ "QuickLookThumbnailing",
2446
+ "libxml2",
2447
+ "CarPlay",
2448
+ "System",
2449
+ "_LocationEssentials",
2450
+ "GeoToolbox",
2451
+ "DataDetection",
2452
+ "Accessibility",
2453
+ "Contacts",
2454
+ "CoreML",
2455
+ "EventKit",
2456
+ "CloudKit",
2457
+ "IOSurface",
2458
+ "OpenGLES",
2459
+ "ContactsUI",
2460
+ "CoreLocationUI",
2461
+ "MediaPlayer",
2462
+ "MediaAccessibility",
2463
+ "MusicKit",
2464
+ "RealityKit",
2465
+ "SecureElementCredential",
2466
+ "Social",
2467
+ "SceneKit",
2468
+ "CoreBluetooth",
2469
+ "HealthKit",
2470
+ "CoreNFC",
2471
+ "Speech",
2472
+ "Vision",
2473
+ "VisionKit",
2474
+ "WorkoutKit",
2475
+ "_PassKit_SwiftUI",
2476
+ "ExpoModulesCore",
2477
+ "_MapKit_SwiftUI",
2478
+ "PeachJSON",
2479
+ "PeachFoundation",
2480
+ "FoundationNetworking",
2481
+ "DeveloperToolsSupport",
2482
+ "CoreImageEnums",
2483
+ "SwiftUI",
2484
+ "DarwinRecords",
2485
+ "Darwin",
2486
+ "MachO",
2487
+ "PeachObjCRuntime",
2488
+ "PeachObjC",
2489
+ "UIUtilities",
2490
+ "UIKitEnums",
2491
+ "UIKitCore",
2492
+ "PeachICU",
2493
+ "PeachCMark",
2494
+ "CoreImage",
2495
+ "QuartzCore",
2496
+ "CoreGraphics",
2497
+ "AppTrackingTransparency",
2498
+ "StoreKit",
2499
+ "_StoreKit_SwiftUI",
2500
+ "WeatherKit",
2501
+ "DeviceCheck",
2502
+ "PassKit",
2503
+ "Translation",
2504
+ "TipKit",
2505
+ "CoreSpotlight",
2506
+ "CoreVideo",
2507
+ "CoreMedia",
2508
+ "VideoToolbox",
2509
+ "AdSupport",
2510
+ "BackgroundTasks",
2511
+ "LocalAuthentication",
2512
+ "CoreMotion",
2513
+ "MessageUI",
2514
+ "GameController",
2515
+ "GameKit",
2516
+ "MetricKit",
2517
+ "Metal",
2518
+ "AuthenticationServices",
2519
+ "os",
2520
+ "Charts",
2521
+ "Symbols",
2522
+ "UniformTypeIdentifiers",
2523
+ "WidgetKit",
2524
+ "ActivityKit",
2525
+ "SwiftData",
2526
+ "UIKit",
2527
+ "React",
2528
+ "Combine",
2529
+ "PeachFoundationCombine",
2530
+ "AppIntents",
2531
+ "PhotosUI",
2532
+ "AVFoundation",
2533
+ "AVFAudio",
2534
+ "UserNotifications",
2535
+ "Network",
2536
+ "NetworkExtension",
2537
+ "OSLog",
2538
+ "PeachSecurityRuntime",
2539
+ "Accelerate",
2540
+ "CoreText",
2541
+ "CFNetwork",
2542
+ "CommonCrypto",
2543
+ "PeachCodec",
2544
+ "Compression",
2545
+ "zlib",
2546
+ "CryptoKit",
2547
+ "TikTokBusinessSDK",
2548
+ "nSure",
2549
+ "Statsig",
2550
+ "TOCropViewController",
2551
+ "RiveRuntime",
2552
+ "AVRouting",
2553
+ "CoreData",
2554
+ "PDFKit",
2555
+ "ModelIOEnums",
2556
+ "ModelIO",
2557
+ "MetalKit",
2558
+ "DatadogCore",
2559
+ "DatadogLogs",
2560
+ "DatadogRUM",
2561
+ "DatadogTrace",
2562
+ "AppLovinSDK",
2563
+ "GoogleMobileAds",
2564
+ "AppsFlyerLib",
2565
+ "FBSDKCoreKit",
2566
+ "FBAEMKit",
2567
+ "FBSDKCoreKit_Basics",
2568
+ "FirebaseCore",
2569
+ "FirebaseSharedSwift",
2570
+ "FirebaseRemoteConfig",
2571
+ "FirebaseFirestoreInternal",
2572
+ "FirebaseAnalytics",
2573
+ "FirebaseAppCheck",
2574
+ "FirebaseAuth",
2575
+ "FirebaseCrashlytics",
2576
+ "FirebaseFirestore",
2577
+ "FirebaseStorage",
2578
+ "Firebase",
2579
+ "Intercom",
2580
+ "FBAudienceNetwork",
2581
+ "NaturalLanguage",
2582
+ "AVKit",
2583
+ "SafariServices",
2584
+ "QuickLook",
2585
+ "CoreHaptics",
2586
+ "WebKit",
2587
+ "Photos",
2588
+ "LinkPresentation",
2589
+ "FoundationModels",
2590
+ "CoreTransferable",
2591
+ "AudioToolbox",
2592
+ "CoreAudioTypes",
2593
+ "AudioUnit",
2594
+ "Intents",
2595
+ "IntentsUI",
2596
+ "WatchConnectivity",
2597
+ "CoreServices",
2598
+ "MobileCoreServices",
2599
+ "CoreTelephony",
2600
+ "SystemConfiguration",
2601
+ "ImageIO",
2602
+ "CoreLocationEnums",
2603
+ "CoreLocation",
2604
+ "MapKit",
2605
+ "One",
2606
+ "simd",
2607
+ "GLKit",
2608
+ "GameplayKit",
2609
+ "SpriteKit",
2610
+ "PeachBox2D"
2611
+ ],
2612
+ systemEnvironment: {
2613
+ scenePhase: ["string:active", "string:inactive", "string:background"],
2614
+ deviceModel: ["string"],
2615
+ systemName: ["string"],
2616
+ systemVersion: ["string"],
2617
+ colorScheme: ["string:light", "string:dark"],
2618
+ semanticColors: ["object"],
2619
+ imageAssets: ["object"],
2620
+ locale: ["string"],
2621
+ dynamicTypeSize: [
2622
+ "string:xSmall",
2623
+ "string:small",
2624
+ "string:medium",
2625
+ "string:large",
2626
+ "string:xLarge",
2627
+ "string:xxLarge",
2628
+ "string:xxxLarge",
2629
+ "string:accessibility1",
2630
+ "string:accessibility2",
2631
+ "string:accessibility3",
2632
+ "string:accessibility4",
2633
+ "string:accessibility5"
2634
+ ],
2635
+ horizontalSizeClass: ["string:compact", "string:regular"],
2636
+ verticalSizeClass: ["string:compact", "string:regular"],
2637
+ accessibilityReduceMotion: ["bool"]
2638
+ },
2639
+ hosts: {
2640
+ "darwin-arm64": {
2641
+ sha256: "2ab6cf8ee1a10b76ef46c90c8ee384f44594aa5be63ac267f55ab6cd30722595",
2642
+ size: 88639020
2643
+ },
2644
+ "linux-x64": {
2645
+ sha256: "e159994e38c6043515c97d818c63f1e1b0170fb73b2cb721a6913b21691b1ec7",
2646
+ size: 91386228
2647
+ },
2648
+ "linux-arm64": {
2649
+ sha256: "80ef20a79414516631bc1394c1fcd045d0381a3c8be8b65967d6a089ad768d23",
2650
+ size: 90878300
2651
+ }
2652
+ }
2653
+ };
2654
+
2655
+ // src/swift-toolchain.ts
2656
+ init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
2657
+ import { execFileSync } from "node:child_process";
2658
+ import { createHash as createHash3 } from "node:crypto";
2659
+ import fs2 from "node:fs";
2660
+ import os from "node:os";
2661
+ import path2 from "node:path";
2662
+ import { fileURLToPath } from "node:url";
2663
+ var SWIFT_HOST_COMPILER_RELEASE = "swift-6.4.0-RELEASE-custom-0b2d0a9011c88e66";
2664
+ var SWIFT_HOST_COMPILER_ID = "0b2d0a9011c88e66";
2665
+ var compilerArchives = {
2666
+ "swift-6.4.0-RELEASE-custom-ecd2ad9d3fe59329": {
2667
+ identity: "ecd2ad9d3fe59329",
2668
+ hosts: {
2669
+ "darwin-arm64": {
2670
+ checksum: "ab42a13b34e410ca09737420d1ee1d6af417eec039ab44f9a60502bdb5c76506",
2671
+ manifest: "8a93b6b1e6ff577f6dacd81a511d415ca3b396698f9b0c4abc35a4ca807e9d1a"
2672
+ },
2673
+ "linux-x64": {
2674
+ checksum: "b174baa2c578fb32f09c79590d65d03951b04cdec52101b23a46c0b274249fc3",
2675
+ manifest: "330e6cbae5890111c22a58e645049a971eff30334c3f240c650fcfedfeab4ef6"
2676
+ },
2677
+ "linux-arm64": {
2678
+ checksum: "25f722334dd9d79391cb2e47301165e9ef98dd9a8036927652f3c5db3c56b2ae",
2679
+ manifest: "94e5667febf26f8a4ee8c5456f83f62d17453e503d261a4c46d2b80f872470ab"
2680
+ }
2681
+ }
2682
+ },
2683
+ [SWIFT_HOST_COMPILER_RELEASE]: {
2684
+ identity: SWIFT_HOST_COMPILER_ID,
2685
+ hosts: {
2686
+ "darwin-arm64": {
2687
+ checksum: "dc6a494227297ea657e8e5f7c5b4a861cb5e142bdbcfcb028ace2aeb19db90cc",
2688
+ manifest: "d8e9eee0fb9b847f1e9350525d6c68606df46101745f553332309ed026b3c26a"
2689
+ },
2690
+ "linux-x64": {
2691
+ checksum: "85c04b4496aea1657c21a47f448e01d6ccc1c7920d130a566db37fb8350a7be2",
2692
+ manifest: "8451659e74235ad53b700c1afbe293512197900eb98cb1f79e36df2f5c85d511"
2693
+ },
2694
+ "linux-arm64": {
2695
+ checksum: "196606ed62c5c926d18e6ef0769cb1ab21c9943f9084070ddf14a7bc696768b8",
2696
+ manifest: "85fb8d5b6527bd75003a6dbd25b68b22540665cf9df9b13f41f82e5d8acdbf1d"
2697
+ }
2698
+ }
2699
+ }
2700
+ };
2701
+ function swiftToolchainBin(release) {
2702
+ if (process.platform === "darwin") {
2703
+ const dirs = [os.homedir(), "/"].map(
2704
+ (base) => path2.join(base, `Library/Developer/Toolchains/${release}.xctoolchain/usr/bin`)
2705
+ );
2706
+ return dirs.find((dir) => fs2.existsSync(path2.join(dir, "swift"))) ?? dirs[0];
2707
+ }
2708
+ if (process.env.CONTRAST_SWIFT_TOOLCHAINS) {
2709
+ return path2.join(process.env.CONTRAST_SWIFT_TOOLCHAINS, release, "usr/bin");
2710
+ }
2711
+ const image = path2.join("/opt/swift", release, "usr/bin");
2712
+ if (fs2.existsSync(path2.join(image, "swift"))) return image;
2713
+ if (release.includes("-custom-"))
2714
+ return path2.join(peachHome(), "swift", "toolchains", release, "usr/bin");
2715
+ return (process.env.PATH ?? "").split(path2.delimiter).find((dir) => dir && fs2.existsSync(path2.join(dir, "swift"))) ?? image;
2716
+ }
2717
+ function peachHome() {
2718
+ const override = process.env.PEACH_HOME;
2719
+ return override ? path2.resolve(override) : path2.join(os.homedir(), ".peach");
2720
+ }
2721
+ var scratch;
2722
+ function swiftEnvironment(base = process.env) {
2723
+ if (!scratch) return base;
2724
+ return {
2725
+ ...base,
2726
+ TMPDIR: scratch.directory,
2727
+ XDG_CONFIG_HOME: path2.join(scratch.home, ".config"),
2728
+ XDG_CACHE_HOME: path2.join(scratch.home, ".cache"),
2729
+ XDG_DATA_HOME: path2.join(scratch.home, ".local", "share"),
2730
+ ...process.platform === "linux" ? { HOME: scratch.home } : {}
2731
+ };
2732
+ }
2733
+
2734
+ // src/swift-package-manifest.ts
2735
+ function swiftCommand() {
2736
+ return path3.join(swiftToolchainBin(swift_distribution_lock_default.release), "swift");
2737
+ }
2738
+ function swiftPackageFailure(error) {
2739
+ if (!(error instanceof Error)) return String(error);
2740
+ const stderr = "stderr" in error && (typeof error.stderr === "string" || Buffer.isBuffer(error.stderr)) ? error.stderr.toString().trim() : "";
2741
+ return stderr || error.message;
2742
+ }
2743
+ var cacheDir2 = path3.join(cacheDir(), "swift-manifests");
2744
+ var requirementClause = (item) => {
2745
+ const url = JSON.stringify(item.url);
2746
+ const requirement = item.requirement;
2747
+ if (requirement.kind === "upToNextMajorVersion")
2748
+ return `.package(url: ${url}, from: ${JSON.stringify(requirement.minimumVersion)})`;
2749
+ if (requirement.kind === "upToNextMinorVersion")
2750
+ return `.package(url: ${url}, .upToNextMinor(from: ${JSON.stringify(requirement.minimumVersion)}))`;
2751
+ if (requirement.kind === "versionRange")
2752
+ return `.package(url: ${url}, ${JSON.stringify(requirement.minimumVersion)}..<${JSON.stringify(requirement.maximumVersion)})`;
2753
+ if (requirement.kind === "exactVersion")
2754
+ return `.package(url: ${url}, exact: ${JSON.stringify(requirement.version)})`;
2755
+ if (requirement.kind === "branch")
2756
+ return `.package(url: ${url}, branch: ${JSON.stringify(requirement.branch)})`;
2757
+ return `.package(url: ${url}, revision: ${JSON.stringify(requirement.revision)})`;
2758
+ };
2759
+ function resolveSwiftPackageRequirements(requirements, destination) {
2760
+ const repository = (url) => url.replace(/(?:\.git)?\/?$/, "");
2761
+ const chosen = /* @__PURE__ */ new Map();
2762
+ for (const item of requirements) {
2763
+ const identity = swiftPackageIdentity(item.url);
2764
+ const previous = chosen.get(identity);
2765
+ if (previous && (repository(previous.url) !== repository(item.url) || JSON.stringify(previous.requirement) !== JSON.stringify(item.requirement)))
2766
+ throw new Error(
2767
+ `conflicting requirements for ${identity}: ${previous.url} ${JSON.stringify(previous.requirement)}; ${item.url} ${JSON.stringify(item.requirement)}`
2768
+ );
2769
+ if (!previous) chosen.set(identity, item);
2770
+ }
2771
+ const clauses = [...chosen.values()].sort(
2772
+ (a, b) => swiftPackageIdentity(a.url).localeCompare(swiftPackageIdentity(b.url))
2773
+ ).map(requirementClause);
2774
+ const manifest = `// swift-tools-version:5.9
2775
+ import PackageDescription
2776
+ let package = Package(
2777
+ name: "Resolve",
2778
+ dependencies: [
2779
+ ${clauses.join(",\n ")},
2780
+ ]
2781
+ )
2782
+ `;
2783
+ const dir = fs3.mkdtempSync(path3.join(os2.tmpdir(), "peach-resolve-"));
2784
+ try {
2785
+ fs3.writeFileSync(path3.join(dir, "Package.swift"), manifest);
2786
+ try {
2787
+ execFileSync2(
2788
+ swiftCommand(),
2789
+ [
2790
+ "package",
2791
+ ...swiftPackageCacheOptions(),
2792
+ "--package-path",
2793
+ dir,
2794
+ "--scratch-path",
2795
+ path3.join(dir, ".build"),
2796
+ "resolve"
2797
+ ],
2798
+ {
2799
+ encoding: "utf8",
2800
+ env: { ...swiftEnvironment(), GIT_TERMINAL_PROMPT: "0" },
2801
+ stdio: ["ignore", "pipe", "pipe"],
2802
+ maxBuffer: 32 * 1024 * 1024
2803
+ }
2804
+ );
2805
+ } catch (error) {
2806
+ throw new Error(
2807
+ `swiftpm could not resolve ${clauses.length} package requirements (${clauses.join(", ")}): ${swiftPackageFailure(error)}`,
2808
+ { cause: error }
2809
+ );
2810
+ }
2811
+ const resolved = path3.join(dir, "Package.resolved");
2812
+ if (!fs3.existsSync(resolved))
2813
+ throw new Error("swift package resolve wrote no Package.resolved");
2814
+ fs3.mkdirSync(path3.dirname(destination), { recursive: true });
2815
+ fs3.copyFileSync(resolved, destination);
2816
+ } finally {
2817
+ fs3.rmSync(dir, { recursive: true, force: true });
2818
+ }
2175
2819
  }
2176
2820
 
2177
2821
  // src/xcode-json-project.ts
2178
2822
  init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
2179
2823
  var import_json5 = __toESM(require_lib(), 1);
2180
- import path from "node:path";
2824
+ import path4 from "node:path";
2181
2825
  var isObject = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
2182
2826
  var text = (value) => typeof value === "string" ? value : void 0;
2183
2827
  var items = (value) => Array.isArray(value) ? value : [];
2828
+ function remoteVersionRequirement(entry) {
2829
+ const revision = text(entry.revision);
2830
+ if (revision !== void 0) return { requirement: { kind: "revision", revision } };
2831
+ const branch = text(entry.branch);
2832
+ if (branch !== void 0) return { requirement: { kind: "branch", branch } };
2833
+ const version = text(entry.version);
2834
+ if (version !== void 0) return { requirement: { kind: "exactVersion", version } };
2835
+ const minor = text(entry["up-to-next-minor-version"]);
2836
+ if (minor !== void 0)
2837
+ return { requirement: { kind: "upToNextMinorVersion", minimumVersion: minor } };
2838
+ const major = text(entry["up-to-next-major-version"]);
2839
+ if (major !== void 0)
2840
+ return { requirement: { kind: "upToNextMajorVersion", minimumVersion: major } };
2841
+ const range = text(entry["version-range"]);
2842
+ if (range !== void 0) {
2843
+ const bounds = range.split("..<");
2844
+ const minimum2 = bounds[0];
2845
+ const maximum2 = bounds[1];
2846
+ if (bounds.length !== 2 || !minimum2 || !maximum2 || bounds[2] !== void 0)
2847
+ throw new Error(
2848
+ `${text(entry.repository) ?? "package"} has a version-range that is not min..<max`
2849
+ );
2850
+ return {
2851
+ requirement: {
2852
+ kind: "versionRange",
2853
+ minimumVersion: minimum2,
2854
+ maximumVersion: maximum2
2855
+ }
2856
+ };
2857
+ }
2858
+ const minimum = text(entry["version-range-min"]);
2859
+ const maximum = text(entry["version-range-max"]);
2860
+ if (minimum !== void 0 && maximum !== void 0)
2861
+ return {
2862
+ requirement: {
2863
+ kind: "versionRange",
2864
+ minimumVersion: minimum,
2865
+ maximumVersion: maximum
2866
+ }
2867
+ };
2868
+ return void 0;
2869
+ }
2184
2870
  var PHASE_ISA = {
2185
2871
  "compile-sources": "PBXSourcesBuildPhase",
2186
2872
  resources: "PBXResourcesBuildPhase",
@@ -2192,7 +2878,7 @@ var PHASE_ISA = {
2192
2878
  function readXcodeJsonProject(xcodeproj, source) {
2193
2879
  const json = import_json5.default.parse(source);
2194
2880
  if (!isJsonObject(json)) throw new Error(`${xcodeproj}/project.xcproj is not an object`);
2195
- const projectDir = path.dirname(xcodeproj);
2881
+ const projectDir = path4.dirname(xcodeproj);
2196
2882
  const objects = {};
2197
2883
  let next = 0;
2198
2884
  const add = (entry, id) => {
@@ -2205,7 +2891,7 @@ function readXcodeJsonProject(xcodeproj, source) {
2205
2891
  const base = /^<([A-Z]+)>\/(.*)$/.exec(raw);
2206
2892
  if (base) {
2207
2893
  if (base[1] === "PROJECT")
2208
- return { sourceTree: "<absolute>", path: path.join(projectDir, base[2]) };
2894
+ return { sourceTree: "<absolute>", path: path4.join(projectDir, base[2]) };
2209
2895
  if (base[1] === "PRODUCTS")
2210
2896
  return { sourceTree: "BUILT_PRODUCTS_DIR", path: base[2] };
2211
2897
  return null;
@@ -2213,7 +2899,7 @@ function readXcodeJsonProject(xcodeproj, source) {
2213
2899
  const unescaped = raw.replaceAll("\\<", "<");
2214
2900
  if (unescaped.startsWith("/")) return { sourceTree: "<absolute>", path: unescaped };
2215
2901
  if (unescaped.startsWith("~")) return null;
2216
- return groupDir === null ? null : { sourceTree: "<absolute>", path: path.join(groupDir, unescaped) };
2902
+ return groupDir === null ? null : { sourceTree: "<absolute>", path: path4.join(groupDir, unescaped) };
2217
2903
  };
2218
2904
  const memberships = [];
2219
2905
  const folders = [];
@@ -2224,7 +2910,7 @@ function readXcodeJsonProject(xcodeproj, source) {
2224
2910
  const kind = text(entry.kind) ?? "file-reference";
2225
2911
  const raw = text(entry.path) ?? "";
2226
2912
  const located = raw === "" ? null : locate(raw, parent.dir);
2227
- const name = text(entry.name) ?? path.basename(raw);
2913
+ const name = text(entry.name) ?? path4.basename(raw);
2228
2914
  const node = { id: "", name, dir: null, parent, children: [] };
2229
2915
  if (kind === "group" || kind === "variant-group" || kind === "version-group") {
2230
2916
  node.dir = raw === "" ? parent.dir : located?.sourceTree === "<absolute>" ? located.path : null;
@@ -2345,8 +3031,12 @@ function readXcodeJsonProject(xcodeproj, source) {
2345
3031
  if (!isObject(entry)) continue;
2346
3032
  const repository = text(entry.repository);
2347
3033
  const local = text(entry.path);
2348
- const name = local !== void 0 ? path.basename(path.resolve(path.dirname(xcodeproj), local)) : path.basename(repository ?? "").replace(/\.git$/, "");
2349
- const id = text(entry.kind) === "local" && local !== void 0 ? add({ isa: "XCLocalSwiftPackageReference", relativePath: local }) : add({ isa: "XCRemoteSwiftPackageReference", repositoryURL: repository ?? "" });
3034
+ const name = local !== void 0 ? path4.basename(path4.resolve(path4.dirname(xcodeproj), local)) : path4.basename(repository ?? "").replace(/\.git$/, "");
3035
+ const id = text(entry.kind) === "local" && local !== void 0 ? add({ isa: "XCLocalSwiftPackageReference", relativePath: local }) : add({
3036
+ isa: "XCRemoteSwiftPackageReference",
3037
+ repositoryURL: repository ?? "",
3038
+ ...remoteVersionRequirement(entry)
3039
+ });
2350
3040
  packageIds.set(name.toLowerCase(), id);
2351
3041
  }
2352
3042
  const productDependency = (entry) => add({
@@ -2516,7 +3206,23 @@ function isJsonObject(value) {
2516
3206
 
2517
3207
  // src/xcode-project.ts
2518
3208
  var XCODE_DEFAULT_IOS_DEPLOYMENT_TARGET = "27.0";
3209
+ var CXX_STANDARD_ALIASES = {
3210
+ "c++0x": "c++11",
3211
+ "gnu++0x": "gnu++11"
3212
+ };
3213
+ var PRE_CXX20_STANDARDS = /* @__PURE__ */ new Set([
3214
+ "c++98",
3215
+ "gnu++98",
3216
+ "c++0x",
3217
+ "gnu++0x",
3218
+ "c++14",
3219
+ "gnu++14",
3220
+ "c++17",
3221
+ "gnu++17",
3222
+ "compiler-default"
3223
+ ]);
2519
3224
  var APPLICATION = "com.apple.product-type.application";
3225
+ var RESOURCE_BUNDLE = "com.apple.product-type.bundle";
2520
3226
  var FRAMEWORK_PRODUCTS = /* @__PURE__ */ new Set([
2521
3227
  "com.apple.product-type.framework",
2522
3228
  "com.apple.product-type.framework.static"
@@ -2534,28 +3240,28 @@ var CONDITIONS = {
2534
3240
  variant: "normal"
2535
3241
  };
2536
3242
  function walkFiles(dir) {
2537
- if (!fs.existsSync(dir)) return [];
3243
+ if (!fs4.existsSync(dir)) return [];
2538
3244
  const out = [];
2539
- for (const entry of fs.readdirSync(dir, { withFileTypes: true }).sort((left, right) => left.name.localeCompare(right.name))) {
3245
+ for (const entry of fs4.readdirSync(dir, { withFileTypes: true }).sort((left, right) => left.name.localeCompare(right.name))) {
2540
3246
  if (entry.name.startsWith(".")) continue;
2541
- const full = path2.join(dir, entry.name);
3247
+ const full = path5.join(dir, entry.name);
2542
3248
  if (entry.isDirectory()) out.push(...walkFiles(full));
2543
3249
  else if (entry.isFile()) out.push(full);
2544
3250
  }
2545
3251
  return out;
2546
3252
  }
2547
- var isDirectory = (dir) => fs.existsSync(dir) && fs.statSync(dir).isDirectory();
3253
+ var isDirectory = (dir) => fs4.existsSync(dir) && fs4.statSync(dir).isDirectory();
2548
3254
  function readXcconfig(file, read) {
2549
- if (read.includes(file) || !fs.existsSync(file)) return {};
3255
+ if (read.includes(file) || !fs4.existsSync(file)) return {};
2550
3256
  read.push(file);
2551
3257
  const settings = {};
2552
- for (const raw of fs.readFileSync(file, "utf8").split("\n")) {
3258
+ for (const raw of fs4.readFileSync(file, "utf8").split("\n")) {
2553
3259
  const line = raw.replace(/\/\/.*$/, "").trim();
2554
3260
  const include = /^#include\??\s+"([^"]+)"/.exec(line);
2555
3261
  if (include) {
2556
3262
  Object.assign(
2557
3263
  settings,
2558
- readXcconfig(path2.resolve(path2.dirname(file), include[1]), read)
3264
+ readXcconfig(path5.resolve(path5.dirname(file), include[1]), read)
2559
3265
  );
2560
3266
  continue;
2561
3267
  }
@@ -2605,22 +3311,22 @@ function decodeXml(text2) {
2605
3311
  return text2.replaceAll("&quot;", '"').replaceAll("&apos;", "'").replaceAll("&lt;", "<").replaceAll("&gt;", ">").replaceAll("&amp;", "&");
2606
3312
  }
2607
3313
  function workspaceReferences(workspace) {
2608
- const data = path2.join(workspace, "contents.xcworkspacedata");
2609
- if (!fs.existsSync(data))
3314
+ const data = path5.join(workspace, "contents.xcworkspacedata");
3315
+ if (!fs4.existsSync(data))
2610
3316
  throw new Error(`${workspace} has no contents.xcworkspacedata`);
2611
- const container = path2.dirname(workspace);
3317
+ const container = path5.dirname(workspace);
2612
3318
  const locate = (location, base) => {
2613
3319
  const colon = location.indexOf(":");
2614
3320
  const kind = location.slice(0, colon);
2615
3321
  const rest = location.slice(colon + 1);
2616
- if (kind === "group") return path2.resolve(base, rest);
2617
- if (kind === "container" || kind === "self") return path2.resolve(container, rest);
2618
- if (kind === "absolute") return path2.resolve(rest);
2619
- throw new Error(`${path2.basename(workspace)} has an unsupported location ${location}`);
3322
+ if (kind === "group") return path5.resolve(base, rest);
3323
+ if (kind === "container" || kind === "self") return path5.resolve(container, rest);
3324
+ if (kind === "absolute") return path5.resolve(rest);
3325
+ throw new Error(`${path5.basename(workspace)} has an unsupported location ${location}`);
2620
3326
  };
2621
3327
  const groups = [container];
2622
3328
  const references = [];
2623
- for (const [, closing, tag, attributes, selfClosing] of fs.readFileSync(data, "utf8").matchAll(/<(\/?)(Group|FileRef)\b([^>]*?)(\/?)>/g)) {
3329
+ for (const [, closing, tag, attributes, selfClosing] of fs4.readFileSync(data, "utf8").matchAll(/<(\/?)(Group|FileRef)\b([^>]*?)(\/?)>/g)) {
2624
3330
  if (closing) {
2625
3331
  if (tag === "Group") groups.pop();
2626
3332
  continue;
@@ -2633,11 +3339,46 @@ function workspaceReferences(workspace) {
2633
3339
  }
2634
3340
  return references;
2635
3341
  }
3342
+ function versionRequirement(url, requirement) {
3343
+ const kind = str(requirement.kind);
3344
+ const minimum = str(requirement.minimumVersion);
3345
+ const maximum = str(requirement.maximumVersion);
3346
+ const version = str(requirement.version);
3347
+ const branch = str(requirement.branch);
3348
+ const revision = str(requirement.revision);
3349
+ if (kind === "upToNextMajorVersion" && minimum)
3350
+ return { kind: "upToNextMajorVersion", minimumVersion: minimum };
3351
+ if (kind === "upToNextMinorVersion" && minimum)
3352
+ return { kind: "upToNextMinorVersion", minimumVersion: minimum };
3353
+ if (kind === "versionRange" && minimum && maximum)
3354
+ return { kind: "versionRange", minimumVersion: minimum, maximumVersion: maximum };
3355
+ if (kind === "exactVersion" && version) return { kind: "exactVersion", version };
3356
+ if (kind === "branch" && branch) return { kind: "branch", branch };
3357
+ if (kind === "revision" && revision) return { kind: "revision", revision };
3358
+ throw new Error(
3359
+ `${url} has an unsupported package requirement${kind ? ` (${kind})` : ""}`
3360
+ );
3361
+ }
3362
+ function remotePackageRequirements(projects) {
3363
+ const out = [];
3364
+ for (const project of projects) {
3365
+ for (const id of list(project.project.packageReferences)) {
3366
+ const reference = project.object(id);
3367
+ if (reference?.isa !== "XCRemoteSwiftPackageReference") continue;
3368
+ const url = str(reference.repositoryURL);
3369
+ if (!url) continue;
3370
+ const requirement = reference.requirement;
3371
+ if (!isDict(requirement)) throw new Error(`${url} has no version requirement`);
3372
+ out.push({ url, requirement: versionRequirement(url, requirement) });
3373
+ }
3374
+ }
3375
+ return out;
3376
+ }
2636
3377
  var loaded = /* @__PURE__ */ new Map();
2637
3378
  function xcodeProjectFile(xcodeproj) {
2638
3379
  for (const name of ["project.pbxproj", "project.xcproj"]) {
2639
- const file = path2.join(xcodeproj, name);
2640
- if (fs.existsSync(file)) return file;
3380
+ const file = path5.join(xcodeproj, name);
3381
+ if (fs4.existsSync(file)) return file;
2641
3382
  }
2642
3383
  return null;
2643
3384
  }
@@ -2645,8 +3386,8 @@ function loadProject(xcodeproj) {
2645
3386
  const projectFile = xcodeProjectFile(xcodeproj);
2646
3387
  if (!projectFile)
2647
3388
  throw new Error(`${xcodeproj} has no project.pbxproj or project.xcproj`);
2648
- const source = fs.readFileSync(projectFile, "utf8");
2649
- const digest = createHash2("sha256").update(source).digest("hex");
3389
+ const source = fs4.readFileSync(projectFile, "utf8");
3390
+ const digest = createHash5("sha256").update(source).digest("hex");
2650
3391
  const cached = loaded.get(projectFile);
2651
3392
  if (cached?.digest === digest) return cached.project;
2652
3393
  const root = projectFile.endsWith(".xcproj") ? readXcodeJsonProject(xcodeproj, source) : parseOpenStepPlist(source);
@@ -2662,10 +3403,10 @@ function loadProject(xcodeproj) {
2662
3403
  if (!project || project.isa !== "PBXProject") {
2663
3404
  throw new Error(`${projectFile} has no PBXProject root`);
2664
3405
  }
2665
- const projectDir = fs.realpathSync(
2666
- path2.resolve(path2.dirname(xcodeproj), str(project.projectDirPath) ?? "")
3406
+ const projectDir = fs4.realpathSync(
3407
+ path5.resolve(path5.dirname(xcodeproj), str(project.projectDirPath) ?? "")
2667
3408
  );
2668
- const resolvePath = xcodePathResolver(objects, projectDir, path2.join);
3409
+ const resolvePath = xcodePathResolver(objects, projectDir, path5.join);
2669
3410
  const result = {
2670
3411
  xcodeproj,
2671
3412
  projectFile,
@@ -2699,8 +3440,8 @@ function targetSettings(ref, configuration, builtins, options = {}, overrides =
2699
3440
  const relative2 = str(config.baseConfigurationReferenceRelativePath);
2700
3441
  const own = isDict(config.buildSettings) ? config.buildSettings : {};
2701
3442
  const directory = anchor ? project.resolvePath(anchor) : null;
2702
- const baseFile = base ? project.resolvePath(base) : directory && relative2 ? path2.resolve(directory, relative2) : null;
2703
- if (options.requireSources !== false && (base || anchor || relative2) && (!baseFile || !fs.existsSync(baseFile)))
3443
+ const baseFile = base ? project.resolvePath(base) : directory && relative2 ? path5.resolve(directory, relative2) : null;
3444
+ if (options.requireSources !== false && (base || anchor || relative2) && (!baseFile || !fs4.existsSync(baseFile)))
2704
3445
  throw new Error(
2705
3446
  `Unable to open base configuration reference file '${baseFile ?? base ?? relative2 ?? anchor}'`
2706
3447
  );
@@ -2756,7 +3497,7 @@ function targetSettings(ref, configuration, builtins, options = {}, overrides =
2756
3497
  const derived = (key) => {
2757
3498
  if (key === "AppIdentifierPrefix" || key === "TeamIdentifierPrefix")
2758
3499
  return teamPrefix();
2759
- return Object.hasOwn(derivedSettings, key) ? derivedSettings[key]() : process.env[key] ?? "";
3500
+ return Object.hasOwn(derivedSettings, key) ? derivedSettings[key]() : options.environment?.[key] ?? process.env[key] ?? "";
2760
3501
  };
2761
3502
  return {
2762
3503
  get,
@@ -2778,27 +3519,27 @@ function settingList(value) {
2778
3519
  );
2779
3520
  return items2;
2780
3521
  }
2781
- function expandSearchPath(directory, rules) {
2782
- if (path2.basename(directory) !== "**") return [directory];
3522
+ function expandSearchPath(directory, rules2) {
3523
+ if (path5.basename(directory) !== "**") return [directory];
2783
3524
  const expanded = [];
2784
3525
  const seen = /* @__PURE__ */ new Set();
2785
- const queue = [path2.dirname(directory)];
3526
+ const queue = [path5.dirname(directory)];
2786
3527
  for (let at = 0; at < queue.length; at++) {
2787
3528
  const current = queue[at];
2788
3529
  let real;
2789
3530
  try {
2790
- real = fs.realpathSync(current);
3531
+ real = fs4.realpathSync(current);
2791
3532
  } catch {
2792
3533
  continue;
2793
3534
  }
2794
- if (!fs.statSync(real).isDirectory() || seen.has(real)) continue;
3535
+ if (!fs4.statSync(real).isDirectory() || seen.has(real)) continue;
2795
3536
  seen.add(real);
2796
3537
  expanded.push(current);
2797
- for (const entry of fs.readdirSync(real, { withFileTypes: true }).sort((a, b) => a.name < b.name ? -1 : a.name > b.name ? 1 : 0)) {
2798
- if (entry.isSymbolicLink() ? !rules.followLinks : !entry.isDirectory()) continue;
2799
- if (rules.excluded.some((pattern) => pattern.test(entry.name)) && !rules.included.some((pattern) => pattern.test(entry.name)))
3538
+ for (const entry of fs4.readdirSync(real, { withFileTypes: true }).sort((a, b) => a.name < b.name ? -1 : a.name > b.name ? 1 : 0)) {
3539
+ if (entry.isSymbolicLink() ? !rules2.followLinks : !entry.isDirectory()) continue;
3540
+ if (rules2.excluded.some((pattern) => pattern.test(entry.name)) && !rules2.included.some((pattern) => pattern.test(entry.name)))
2800
3541
  continue;
2801
- queue.push(path2.join(current, entry.name));
3542
+ queue.push(path5.join(current, entry.name));
2802
3543
  }
2803
3544
  }
2804
3545
  return expanded;
@@ -2840,8 +3581,54 @@ function expand(value, lookup) {
2840
3581
  );
2841
3582
  }
2842
3583
  var preparedSourcePhases = /* @__PURE__ */ new Map();
3584
+ function shellCopies(script, settings, projectDir) {
3585
+ const assigned = /* @__PURE__ */ new Map();
3586
+ const copies = [];
3587
+ let resolved = true;
3588
+ const lookup = (name) => {
3589
+ const value = assigned.get(name) ?? settings(name);
3590
+ if (value === "") resolved = false;
3591
+ return value;
3592
+ };
3593
+ const word = (token2) => {
3594
+ if (/\$\{[A-Za-z_][A-Za-z0-9_]*(?::?[-+=?]|[#%/^,])/.test(token2)) return null;
3595
+ resolved = true;
3596
+ const quote = token2[0];
3597
+ const value = quote === "'" ? token2.slice(1, -1) : expand(quote === '"' ? token2.slice(1, -1) : token2, lookup);
3598
+ return resolved && !value.includes("$") ? value : null;
3599
+ };
3600
+ const token = /^(?:"[^"\\`]*"|'[^']*'|[^\s"'`;&|<>()\\]+)$/;
3601
+ for (const raw of script.split(/\r?\n/)) {
3602
+ const line = raw.trim().replace(/^export\s+/, "");
3603
+ if (line === "" || line.startsWith("#") || /^set\s+-[A-Za-z]+(\s+\w+)?$/.test(line))
3604
+ continue;
3605
+ const tokens = line.match(/"[^"]*"|'[^']*'|\S+/g) ?? [];
3606
+ if (!tokens.every(
3607
+ (value, index) => token.test(index === 0 ? value.replace(/^[A-Za-z_][A-Za-z0-9_]*=/, "") : value)
3608
+ ))
3609
+ return [];
3610
+ const assignment = /^([A-Za-z_][A-Za-z0-9_]*)=(.*)$/.exec(line);
3611
+ if (assignment) {
3612
+ const value = tokens.length === 1 ? word(assignment[2]) : null;
3613
+ if (value === null) return [];
3614
+ assigned.set(assignment[1], value);
3615
+ continue;
3616
+ }
3617
+ if (tokens[0] !== "cp" && tokens[0] !== "echo") return [];
3618
+ const operands = tokens.slice(1).map(word);
3619
+ if (operands.includes(null)) return [];
3620
+ if (tokens[0] === "echo") continue;
3621
+ if (operands.length !== 2 || operands.some((operand) => operand.startsWith("-")))
3622
+ return [];
3623
+ copies.push({
3624
+ from: path5.resolve(projectDir, operands[0]),
3625
+ to: path5.resolve(projectDir, operands[1])
3626
+ });
3627
+ }
3628
+ return copies;
3629
+ }
2843
3630
  function fileListEntries(file, absolute) {
2844
- return fs.readFileSync(file, "utf8").split(/\r?\n/).map((line) => line.trim()).filter((line) => line !== "" && !line.startsWith("#")).map(absolute);
3631
+ return fs4.readFileSync(file, "utf8").split(/\r?\n/).map((line) => line.trim()).filter((line) => line !== "" && !line.startsWith("#")).map(absolute);
2845
3632
  }
2846
3633
  function targetMembers(ref, settings, options, settingKeys, projectInputs) {
2847
3634
  const { project, target, id: targetId } = ref;
@@ -2851,14 +3638,19 @@ function targetMembers(ref, settings, options, settingKeys, projectInputs) {
2851
3638
  const headers = /* @__PURE__ */ new Set();
2852
3639
  const resources = /* @__PURE__ */ new Set();
2853
3640
  const scriptForOutput = /* @__PURE__ */ new Map();
3641
+ const copiedFiles = [];
3642
+ let generatedInfoPlist = false;
2854
3643
  const declaredInfoPlist = settings("INFOPLIST_FILE");
2855
- const infoPlistOutput = declaredInfoPlist ? path2.resolve(project.projectDir, declaredInfoPlist) : null;
3644
+ const infoPlistOutput = declaredInfoPlist ? path5.resolve(project.projectDir, declaredInfoPlist) : null;
2856
3645
  const isPreparedOutput = (file) => file === infoPlistOutput || options.requireSources !== false && file.endsWith(".swift");
2857
3646
  for (const phaseId of list(target.buildPhases)) {
2858
3647
  const phase = project.object(phaseId);
2859
3648
  if (phase?.isa !== "PBXShellScriptBuildPhase") continue;
2860
3649
  const script = str(phase.name) ?? phaseId;
2861
- const absolute = (raw) => path2.resolve(project.projectDir, expand(raw, settings));
3650
+ copiedFiles.push(
3651
+ ...shellCopies(str(phase.shellScript) ?? "", settings, project.projectDir)
3652
+ );
3653
+ const absolute = (raw) => path5.resolve(project.projectDir, expand(raw, settings));
2862
3654
  const inputs = list(phase.inputPaths).map(absolute);
2863
3655
  const outputs = list(phase.outputPaths).map(absolute);
2864
3656
  const fileLists = /* @__PURE__ */ new Map();
@@ -2867,7 +3659,7 @@ function targetMembers(ref, settings, options, settingKeys, projectInputs) {
2867
3659
  kind === "INPUT" ? phase.inputFileListPaths : phase.outputFileListPaths
2868
3660
  ).map((raw) => {
2869
3661
  const file = absolute(raw);
2870
- if (!fs.existsSync(file)) {
3662
+ if (!fs4.existsSync(file)) {
2871
3663
  return { file, entries: [] };
2872
3664
  }
2873
3665
  return { file, entries: fileListEntries(file, absolute) };
@@ -2878,6 +3670,7 @@ function targetMembers(ref, settings, options, settingKeys, projectInputs) {
2878
3670
  ...outputs,
2879
3671
  ...fileLists.get("OUTPUT").flatMap((item) => item.entries)
2880
3672
  ];
3673
+ if (allOutputs.includes(infoPlistOutput)) generatedInfoPlist = true;
2881
3674
  for (const output of allOutputs)
2882
3675
  if (output.endsWith(".swift") && !scriptForOutput.has(output))
2883
3676
  scriptForOutput.set(output, script);
@@ -2887,13 +3680,13 @@ function targetMembers(ref, settings, options, settingKeys, projectInputs) {
2887
3680
  ...fileLists.get("OUTPUT").map((item) => item.file)
2888
3681
  ];
2889
3682
  if (allOutputs.some((file) => file.endsWith(".swift") || file === infoPlistOutput)) {
2890
- for (const file of inputFiles) if (fs.existsSync(file)) projectInputs.add(file);
3683
+ for (const file of inputFiles) if (fs4.existsSync(file)) projectInputs.add(file);
2891
3684
  }
2892
- if (options.prepareGeneratedSources && allOutputs.some(isPreparedOutput)) {
2893
- const phaseDir = path2.join(settings("TARGET_TEMP_DIR"), `Script-${phaseId}`);
3685
+ if (options.prepareGeneratedSources === true && allOutputs.some(isPreparedOutput)) {
3686
+ const phaseDir = path5.join(settings("TARGET_TEMP_DIR"), `Script-${phaseId}`);
2894
3687
  for (const lists of fileLists.values())
2895
3688
  for (const { file } of lists)
2896
- if (!fs.existsSync(file))
3689
+ if (!fs4.existsSync(file))
2897
3690
  throw new Error(
2898
3691
  `${targetName}: Run Script "${script}" missing file list ${file}`
2899
3692
  );
@@ -2912,48 +3705,48 @@ function targetMembers(ref, settings, options, settingKeys, projectInputs) {
2912
3705
  const lists = fileLists.get(kind);
2913
3706
  env[`SCRIPT_${kind}_FILE_LIST_COUNT`] = String(lists.length);
2914
3707
  lists.forEach((_item, index) => {
2915
- env[`SCRIPT_${kind}_FILE_LIST_${index}`] = path2.join(
3708
+ env[`SCRIPT_${kind}_FILE_LIST_${index}`] = path5.join(
2916
3709
  phaseDir,
2917
3710
  `${kind}-${index}.xcfilelist`
2918
3711
  );
2919
3712
  });
2920
3713
  }
2921
- const signature = createHash2("sha256").update(
3714
+ const signature = createHash5("sha256").update(
2922
3715
  JSON.stringify([phase, [...settingKeys].map((key2) => [key2, settings(key2)])])
2923
3716
  );
2924
3717
  for (const file of inputFiles) {
2925
3718
  signature.update(file);
2926
- if (fs.existsSync(file)) {
2927
- const stat = fs.statSync(file);
3719
+ if (fs4.existsSync(file)) {
3720
+ const stat = fs4.statSync(file);
2928
3721
  signature.update(`${stat.mtimeMs}:${stat.ctimeMs}:${stat.size}`);
2929
3722
  } else signature.update("missing");
2930
3723
  }
2931
3724
  const stamp = signature.digest("hex");
2932
3725
  const key = `${project.projectFile}:${targetId}:${phaseId}:${settings("CONFIGURATION")}`;
2933
- if (preparedSourcePhases.get(key) === stamp && allOutputs.every((file) => fs.existsSync(file)))
3726
+ if (preparedSourcePhases.get(key) === stamp && allOutputs.every((file) => fs4.existsSync(file)))
2934
3727
  continue;
2935
- fs.mkdirSync(phaseDir, { recursive: true });
2936
- fs.mkdirSync(settings("BUILT_PRODUCTS_DIR"), { recursive: true });
2937
- fs.mkdirSync(settings("DERIVED_FILE_DIR"), { recursive: true });
3728
+ fs4.mkdirSync(phaseDir, { recursive: true });
3729
+ fs4.mkdirSync(settings("BUILT_PRODUCTS_DIR"), { recursive: true });
3730
+ fs4.mkdirSync(settings("DERIVED_FILE_DIR"), { recursive: true });
2938
3731
  for (const output of allOutputs)
2939
- fs.mkdirSync(path2.dirname(output), { recursive: true });
3732
+ fs4.mkdirSync(path5.dirname(output), { recursive: true });
2940
3733
  for (const [kind, lists] of fileLists)
2941
3734
  lists.forEach((item, index) => {
2942
- fs.writeFileSync(
3735
+ fs4.writeFileSync(
2943
3736
  env[`SCRIPT_${kind}_FILE_LIST_${index}`],
2944
3737
  `${item.entries.join("\n")}
2945
3738
  `
2946
3739
  );
2947
3740
  });
2948
3741
  try {
2949
- execFileSync2(
3742
+ execFileSync3(
2950
3743
  str(phase.shellPath) ?? "/bin/sh",
2951
3744
  ["-c", str(phase.shellScript) ?? ""],
2952
3745
  {
2953
3746
  cwd: project.projectDir,
2954
3747
  env,
2955
3748
  stdio: ["ignore", "pipe", "pipe"],
2956
- timeout: 12e4
3749
+ maxBuffer: Infinity
2957
3750
  }
2958
3751
  );
2959
3752
  } catch (error) {
@@ -2965,7 +3758,7 @@ ${output}`
2965
3758
  );
2966
3759
  }
2967
3760
  const missing = allOutputs.filter(
2968
- (file) => isPreparedOutput(file) && !fs.existsSync(file)
3761
+ (file) => file === infoPlistOutput && !fs4.existsSync(file)
2969
3762
  );
2970
3763
  if (missing.length > 0)
2971
3764
  throw new Error(
@@ -2978,8 +3771,8 @@ ${output}`
2978
3771
  project.objects,
2979
3772
  targetId,
2980
3773
  project.resolvePath,
2981
- (file) => isDirectory(file) ? walkFiles(file) : fs.existsSync(file) ? [file] : [],
2982
- path2.join,
3774
+ (file) => isDirectory(file) ? walkFiles(file) : fs4.existsSync(file) ? [file] : [],
3775
+ path5.join,
2983
3776
  (file, kind) => {
2984
3777
  if (kind === "header") {
2985
3778
  headers.add(file);
@@ -2989,9 +3782,9 @@ ${output}`
2989
3782
  resources.add(file);
2990
3783
  return;
2991
3784
  }
2992
- if (!fs.existsSync(file)) {
3785
+ if (!fs4.existsSync(file)) {
2993
3786
  if (options.requireSources === false) return;
2994
- const script = scriptForOutput.get(path2.normalize(file));
3787
+ const script = scriptForOutput.get(path5.normalize(file));
2995
3788
  throw new Error(
2996
3789
  script ? `${targetName}: missing generated source ${file} (Run Script "${script}" declares it in outputPaths; run the script or check in its output)` : `${targetName}: missing source ${file}`
2997
3790
  );
@@ -3000,20 +3793,19 @@ ${output}`
3000
3793
  if (file.endsWith(".swift")) sources.add(file);
3001
3794
  }
3002
3795
  );
3003
- for (const [file, script] of scriptForOutput) {
3796
+ for (const [file] of scriptForOutput) {
3004
3797
  if (sources.has(file) || allSources.has(file)) continue;
3005
- if (!fs.existsSync(file)) {
3006
- if (options.requireSources === false) continue;
3007
- throw new Error(
3008
- `${targetName}: missing generated source ${file} (Run Script "${script}" declares it in outputPaths; run the script or check in its output)`
3009
- );
3010
- }
3011
- allSources.add(file);
3012
- sources.add(file);
3798
+ if (!fs4.existsSync(file)) continue;
3799
+ const canonical = fs4.realpathSync(file);
3800
+ if (sources.has(canonical) || allSources.has(canonical)) continue;
3801
+ allSources.add(canonical);
3802
+ sources.add(canonical);
3013
3803
  }
3014
3804
  return {
3015
3805
  sources: [...sources].sort(),
3016
3806
  resources: [...resources].sort(),
3807
+ copiedFiles,
3808
+ generatedInfoPlist,
3017
3809
  allSources: [...allSources].sort(),
3018
3810
  headers: [...headers].sort()
3019
3811
  };
@@ -3021,37 +3813,37 @@ ${output}`
3021
3813
  function commonAncestor(dirs) {
3022
3814
  let common = dirs[0];
3023
3815
  for (const dir of dirs) {
3024
- while (common !== path2.dirname(common) && path2.relative(common, dir).startsWith(".."))
3025
- common = path2.dirname(common);
3816
+ while (common !== path5.dirname(common) && path5.relative(common, dir).startsWith(".."))
3817
+ common = path5.dirname(common);
3026
3818
  }
3027
3819
  return common;
3028
3820
  }
3029
- var isPodsProject = (xcodeproj) => path2.basename(xcodeproj) === "Pods.xcodeproj" && path2.basename(path2.dirname(xcodeproj)) === "Pods";
3821
+ var isPodsProject = (xcodeproj) => path5.basename(xcodeproj) === "Pods.xcodeproj" && path5.basename(path5.dirname(xcodeproj)) === "Pods";
3030
3822
  function installedPodsSandbox(pods) {
3031
- const podfileLock = path2.join(path2.dirname(pods), "Podfile.lock");
3032
- const manifestLock = path2.join(pods, "Manifest.lock");
3033
- if (!fs.existsSync(podfileLock))
3823
+ const podfileLock = path5.join(path5.dirname(pods), "Podfile.lock");
3824
+ const manifestLock = path5.join(pods, "Manifest.lock");
3825
+ if (!fs4.existsSync(podfileLock))
3034
3826
  throw new Error(
3035
- `${pods} has no ${podfileLock}: run \`pod install\` in ${path2.dirname(pods)}`
3827
+ `${pods} has no ${podfileLock}: run \`pod install\` in ${path5.dirname(pods)}`
3036
3828
  );
3037
- if (!fs.existsSync(manifestLock) || !fs.readFileSync(manifestLock).equals(fs.readFileSync(podfileLock)))
3829
+ if (!fs4.existsSync(manifestLock) || !fs4.readFileSync(manifestLock).equals(fs4.readFileSync(podfileLock)))
3038
3830
  throw new Error(
3039
- `The sandbox is not in sync with the Podfile.lock: ${manifestLock} differs from ${podfileLock}. Run \`pod install\` in ${path2.dirname(pods)}`
3831
+ `The sandbox is not in sync with the Podfile.lock: ${manifestLock} differs from ${podfileLock}. Run \`pod install\` in ${path5.dirname(pods)}`
3040
3832
  );
3041
3833
  const specChecksums = {};
3042
- const lines = fs.readFileSync(manifestLock, "utf8").split("\n");
3834
+ const lines = fs4.readFileSync(manifestLock, "utf8").split("\n");
3043
3835
  const start = lines.indexOf("SPEC CHECKSUMS:");
3044
3836
  for (const line of start === -1 ? [] : lines.slice(start + 1)) {
3045
3837
  const entry = /^ {2}"?([^":]+)"?: ([0-9a-f]+)$/.exec(line);
3046
3838
  if (!entry) break;
3047
3839
  specChecksums[entry[1]] = entry[2];
3048
3840
  }
3049
- const specs = path2.join(pods, "Local Podspecs");
3841
+ const specs = path5.join(pods, "Local Podspecs");
3050
3842
  return {
3051
3843
  podfileLock,
3052
3844
  manifestLock,
3053
3845
  specChecksums,
3054
- localPodspecs: isDirectory(specs) ? fs.readdirSync(specs).filter((name) => name.endsWith(".podspec.json")).sort().map((name) => path2.join(specs, name)) : []
3846
+ localPodspecs: isDirectory(specs) ? fs4.readdirSync(specs).filter((name) => name.endsWith(".podspec.json")).sort().map((name) => path5.join(specs, name)) : []
3055
3847
  };
3056
3848
  }
3057
3849
  function workspaceProjects(xcodeprojOrWorkspace, installedPods = false) {
@@ -3063,14 +3855,14 @@ function workspaceProjects(xcodeprojOrWorkspace, installedPods = false) {
3063
3855
  if (!xcodeProjectFile(xcodeproj)) {
3064
3856
  if (installedPods && isPodsProject(xcodeproj))
3065
3857
  throw new Error(
3066
- `${path2.basename(xcodeprojOrWorkspace)} builds ${xcodeproj}, which is not installed: run \`pod install\` in ${path2.dirname(path2.dirname(xcodeproj))}`
3858
+ `${path5.basename(xcodeprojOrWorkspace)} builds ${xcodeproj}, which is not installed: run \`pod install\` in ${path5.dirname(path5.dirname(xcodeproj))}`
3067
3859
  );
3068
3860
  return;
3069
3861
  }
3070
- const key = fs.realpathSync(xcodeproj);
3071
- if (projectAt.has(key) || !installedPods && key.split(path2.sep).includes("Pods"))
3862
+ const key = fs4.realpathSync(xcodeproj);
3863
+ if (projectAt.has(key) || !installedPods && key.split(path5.sep).includes("Pods"))
3072
3864
  return;
3073
- if (isPodsProject(key)) cocoapods = installedPodsSandbox(path2.dirname(key));
3865
+ if (isPodsProject(key)) cocoapods = installedPodsSandbox(path5.dirname(key));
3074
3866
  const project = loadProject(key);
3075
3867
  projectAt.set(key, project);
3076
3868
  projects.push(project);
@@ -3086,12 +3878,12 @@ function workspaceProjects(xcodeprojOrWorkspace, installedPods = false) {
3086
3878
  for (const reference of listed)
3087
3879
  if (reference.endsWith(".xcodeproj")) addProject(reference);
3088
3880
  if (projects.length === 0) {
3089
- throw new Error(`${path2.basename(xcodeprojOrWorkspace)} lists no Xcode project`);
3881
+ throw new Error(`${path5.basename(xcodeprojOrWorkspace)} lists no Xcode project`);
3090
3882
  }
3091
- const podfile = path2.join(path2.dirname(xcodeprojOrWorkspace), "Podfile");
3092
- if (installedPods && !cocoapods && fs.existsSync(podfile))
3883
+ const podfile = path5.join(path5.dirname(xcodeprojOrWorkspace), "Podfile");
3884
+ if (installedPods && !cocoapods && fs4.existsSync(podfile))
3093
3885
  throw new Error(
3094
- `${podfile} is not installed into ${path2.basename(xcodeprojOrWorkspace)}: run \`pod install\` in ${path2.dirname(podfile)} and open the workspace it writes`
3886
+ `${podfile} is not installed into ${path5.basename(xcodeprojOrWorkspace)}: run \`pod install\` in ${path5.dirname(podfile)} and open the workspace it writes`
3095
3887
  );
3096
3888
  return { listed, projects, projectAt, cocoapods };
3097
3889
  }
@@ -3127,7 +3919,7 @@ function listXcodeAppTargets(xcodeprojOrWorkspace, options = {}) {
3127
3919
  return workspaceProjects(xcodeprojOrWorkspace).projects.flatMap(projectTargets).filter((ref) => isIosAppTarget(ref, options)).map((ref) => str(ref.target.name) ?? ref.id);
3128
3920
  }
3129
3921
  function readXcodeAppTarget(input, targetName, configurationName, options = {}) {
3130
- const xcodeprojOrWorkspace = fs.realpathSync(input);
3922
+ const xcodeprojOrWorkspace = fs4.realpathSync(input);
3131
3923
  const workspace = xcodeprojOrWorkspace.endsWith(".xcworkspace") ? xcodeprojOrWorkspace : null;
3132
3924
  const { listed, projects, projectAt, cocoapods } = workspaceProjects(
3133
3925
  xcodeprojOrWorkspace,
@@ -3136,7 +3928,7 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3136
3928
  const allTargets = projects.flatMap(projectTargets);
3137
3929
  const appTargets = allTargets.filter((ref) => isIosAppTarget(ref, options));
3138
3930
  const appTargetNames = appTargets.map((ref) => str(ref.target.name) ?? ref.id);
3139
- const container = path2.basename(xcodeprojOrWorkspace);
3931
+ const container = path5.basename(xcodeprojOrWorkspace);
3140
3932
  const named = targetName ? appTargets.filter((ref) => ref.target.name === targetName) : appTargets;
3141
3933
  if (named.length !== 1) {
3142
3934
  throw new Error(
@@ -3149,15 +3941,15 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3149
3941
  for (const ref of allTargets) {
3150
3942
  const product = ref.project.object(str(ref.target.productReference));
3151
3943
  const file = str(product?.path);
3152
- if (file && !byProduct.has(path2.basename(file)))
3153
- byProduct.set(path2.basename(file), ref);
3944
+ if (file && !byProduct.has(path5.basename(file)))
3945
+ byProduct.set(path5.basename(file), ref);
3154
3946
  }
3155
3947
  const proxied = (project, proxyId) => {
3156
3948
  const proxy = project.object(proxyId);
3157
3949
  if (proxy?.isa !== "PBXContainerItemProxy") return void 0;
3158
3950
  const portal = str(proxy.containerPortal);
3159
3951
  const portalPath = project.resolvePath(portal ?? "");
3160
- const owner = project.object(portal)?.isa === "PBXProject" ? project : portalPath && fs.existsSync(portalPath) ? projectAt.get(fs.realpathSync(portalPath)) : void 0;
3952
+ const owner = project.object(portal)?.isa === "PBXProject" ? project : portalPath && fs4.existsSync(portalPath) ? projectAt.get(fs4.realpathSync(portalPath)) : void 0;
3161
3953
  const remote = str(proxy.remoteGlobalIDString);
3162
3954
  if (!owner || !remote) return void 0;
3163
3955
  return projectTargets(owner).find(
@@ -3178,12 +3970,12 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3178
3970
  if (phase?.isa !== "PBXFrameworksBuildPhase") continue;
3179
3971
  for (const buildFileId of list(phase.files)) {
3180
3972
  const file = project.object(str(project.object(buildFileId)?.fileRef));
3181
- const resolved = file?.isa === "PBXReferenceProxy" ? proxied(project, str(file.remoteRef)) : file && str(file.sourceTree) === "BUILT_PRODUCTS_DIR" ? byProduct.get(path2.basename(str(file.path) ?? "")) : void 0;
3973
+ const resolved = file?.isa === "PBXReferenceProxy" ? proxied(project, str(file.remoteRef)) : file && str(file.sourceTree) === "BUILT_PRODUCTS_DIR" ? byProduct.get(path5.basename(str(file.path) ?? "")) : void 0;
3182
3974
  if (resolved) found.push(resolved);
3183
3975
  }
3184
3976
  }
3185
3977
  return found.filter(
3186
- (candidate) => candidate.target.isa === "PBXAggregateTarget" || MODULE_PRODUCTS.has(str(candidate.target.productType) ?? "")
3978
+ (candidate) => candidate.target.isa === "PBXAggregateTarget" || candidate.target.productType === RESOURCE_BUNDLE || MODULE_PRODUCTS.has(str(candidate.target.productType) ?? "")
3187
3979
  );
3188
3980
  };
3189
3981
  const order = [];
@@ -3217,6 +4009,25 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3217
4009
  { TARGET_NAME: str(ref.target.name) ?? ref.id },
3218
4010
  options
3219
4011
  ).get("PRODUCT_NAME");
4012
+ const syncHeaderCache = /* @__PURE__ */ new Map();
4013
+ const synchronizedHeaders = (ref) => {
4014
+ const key = `${ref.project.xcodeproj}\0${ref.id}`;
4015
+ const cached = syncHeaderCache.get(key);
4016
+ if (cached) return cached;
4017
+ const found = [];
4018
+ visitXcodeTargetMembers(
4019
+ ref.project.objects,
4020
+ ref.id,
4021
+ ref.project.resolvePath,
4022
+ (file) => isDirectory(file) ? walkFiles(file) : fs4.existsSync(file) ? [file] : [],
4023
+ path5.join,
4024
+ (file, kind) => {
4025
+ if (kind === "header") found.push(file);
4026
+ }
4027
+ );
4028
+ syncHeaderCache.set(key, found);
4029
+ return found;
4030
+ };
3220
4031
  const projectHeaderMaps = /* @__PURE__ */ new Map();
3221
4032
  const projectHeaderMap = (project) => {
3222
4033
  const cached = projectHeaderMaps.get(project);
@@ -3225,26 +4036,41 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3225
4036
  for (const ref of projectTargets(project)) {
3226
4037
  const product = productName(ref);
3227
4038
  for (const { file, visibility } of headerPhase(ref)) {
3228
- const name = path2.basename(file);
4039
+ const name = path5.basename(file);
3229
4040
  if (!entries.has(name))
3230
4041
  entries.set(name, visibility !== "Project" ? `${product}/${name}` : file);
3231
4042
  }
4043
+ for (const file of synchronizedHeaders(ref)) {
4044
+ const name = path5.basename(file);
4045
+ if (!entries.has(name)) entries.set(name, file);
4046
+ }
4047
+ }
4048
+ for (const ref of projectTargets(project)) {
4049
+ for (const groupId of list(ref.target.fileSystemSynchronizedGroups)) {
4050
+ const folder = project.resolvePath(groupId);
4051
+ if (folder === null) continue;
4052
+ for (const file of walkFiles(folder)) {
4053
+ if (!HEADER_FILE.test(file)) continue;
4054
+ const name = path5.basename(file);
4055
+ if (!entries.has(name)) entries.set(name, file);
4056
+ }
4057
+ }
3232
4058
  }
3233
4059
  for (const id of Object.keys(project.objects)) {
3234
4060
  if (project.object(id)?.isa !== "PBXFileReference") continue;
3235
4061
  const file = project.resolvePath(id);
3236
- if (file && HEADER_FILE.test(file) && !entries.has(path2.basename(file)))
3237
- entries.set(path2.basename(file), file);
4062
+ if (file && HEADER_FILE.test(file) && !entries.has(path5.basename(file)))
4063
+ entries.set(path5.basename(file), file);
3238
4064
  }
3239
4065
  const map = [...entries];
3240
4066
  projectHeaderMaps.set(project, map);
3241
4067
  return map;
3242
4068
  };
3243
4069
  const xcconfigs = /* @__PURE__ */ new Set();
3244
- const buildDir = (project) => path2.join(project.projectDir, ".build/peach-xcode/Build");
4070
+ const buildDir = (project) => path5.join(project.projectDir, ".build/peach-xcode/Build");
3245
4071
  const podsBuild = {
3246
- SYMROOT: path2.join(buildDir(app.project), "Products"),
3247
- OBJROOT: path2.join(buildDir(app.project), "Intermediates.noindex")
4072
+ SYMROOT: path5.join(buildDir(app.project), "Products"),
4073
+ OBJROOT: path5.join(buildDir(app.project), "Intermediates.noindex")
3248
4074
  };
3249
4075
  const moduleTarget = (ref) => {
3250
4076
  const name = str(ref.target.name) ?? ref.id;
@@ -3259,18 +4085,19 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3259
4085
  TARGET_NAME: name,
3260
4086
  TARGETNAME: "$(TARGET_NAME)",
3261
4087
  PROJECT: "$(PROJECT_NAME)",
3262
- PROJECT_NAME: path2.basename(ref.project.xcodeproj, ".xcodeproj"),
4088
+ PROJECT_NAME: path5.basename(ref.project.xcodeproj, ".xcodeproj"),
3263
4089
  PROJECT_FILE_PATH: ref.project.xcodeproj,
3264
4090
  SRCROOT: ref.project.projectDir,
3265
4091
  SOURCE_ROOT: ref.project.projectDir,
3266
4092
  PROJECT_DIR: ref.project.projectDir,
3267
- SYMROOT: path2.join(buildDir(ref.project), "Products"),
4093
+ SYMROOT: path5.join(buildDir(ref.project), "Products"),
3268
4094
  BUILD_DIR: "$(SYMROOT)",
3269
4095
  BUILD_ROOT: "$(SYMROOT)",
3270
- OBJROOT: path2.join(buildDir(ref.project), "Intermediates.noindex"),
4096
+ OBJROOT: path5.join(buildDir(ref.project), "Intermediates.noindex"),
3271
4097
  CONFIGURATION_BUILD_DIR: "$(BUILD_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)",
3272
4098
  BUILT_PRODUCTS_DIR: "$(CONFIGURATION_BUILD_DIR)",
3273
4099
  TARGET_BUILD_DIR: "$(CONFIGURATION_BUILD_DIR)",
4100
+ UNLOCALIZED_RESOURCES_FOLDER_PATH: str(ref.project.object(str(ref.target.productReference))?.path) ?? "",
3274
4101
  PROJECT_TEMP_DIR: "$(OBJROOT)/$(PROJECT_NAME).build",
3275
4102
  CONFIGURATION_TEMP_DIR: "$(PROJECT_TEMP_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)",
3276
4103
  TARGET_TEMP_DIR: "$(CONFIGURATION_TEMP_DIR)/$(TARGET_NAME).build",
@@ -3278,8 +4105,14 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3278
4105
  TEMP_FILES_DIR: "$(TEMP_DIR)",
3279
4106
  TEMP_FILE_DIR: "$(TEMP_DIR)",
3280
4107
  TEMP_ROOT: "$(OBJROOT)",
4108
+ OBJECT_FILE_DIR: "$(TARGET_TEMP_DIR)/Objects",
4109
+ // the per-variant object directory carries no arch: xcode defines
4110
+ // OBJECT_FILE_DIR_normal as OBJECT_FILE_DIR-normal, and the target
4111
+ // appends $(CURRENT_ARCH) itself for the per-arch directory.
4112
+ OBJECT_FILE_DIR_normal: "$(OBJECT_FILE_DIR)-normal",
3281
4113
  DERIVED_FILE_DIR: "$(TARGET_TEMP_DIR)/DerivedSources",
3282
4114
  DERIVED_FILES_DIR: "$(DERIVED_FILE_DIR)",
4115
+ DERIVED_SOURCES_DIR: "$(DERIVED_FILE_DIR)",
3283
4116
  PLATFORM_NAME: "iphonesimulator",
3284
4117
  EFFECTIVE_PLATFORM_NAME: "-iphonesimulator",
3285
4118
  CURRENT_ARCH: "arm64",
@@ -3300,11 +4133,38 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3300
4133
  xcconfigs
3301
4134
  );
3302
4135
  const searchRules = recursiveSearchRules(settings2);
3303
- const absolute = (file) => path2.resolve(ref.project.projectDir, file);
4136
+ const absolute = (file) => path5.resolve(ref.project.projectDir, file);
3304
4137
  const framework = FRAMEWORK_PRODUCTS.has(str(ref.target.productType) ?? "");
3305
4138
  const product = settings2("PRODUCT_NAME");
4139
+ const moduleName = applyOperator(settings2("PRODUCT_MODULE_NAME"), "c99extidentifier");
4140
+ const compatibilityPhases = list(ref.target.buildPhases).flatMap((id) => {
4141
+ const phase = ref.project.object(id);
4142
+ if (phase?.isa !== "PBXShellScriptBuildPhase" || str(phase.name) !== "Copy generated compatibility header")
4143
+ return [];
4144
+ const inputs = list(phase.inputPaths).map(
4145
+ (file) => absolute(expand(file, settings2))
4146
+ );
4147
+ const outputs = list(phase.outputPaths).map(
4148
+ (file) => absolute(expand(file, settings2))
4149
+ );
4150
+ const moduleMap2 = inputs.find((file) => file.endsWith(".modulemap"));
4151
+ const umbrella = inputs.find((file) => file.endsWith("-umbrella.h"));
4152
+ const outputModuleMap = outputs.find((file) => file.endsWith(".modulemap"));
4153
+ const outputUmbrella = outputs.find((file) => file.endsWith("-umbrella.h"));
4154
+ const outputHeader = outputs.find((file) => file.endsWith(`/${moduleName}-Swift.h`));
4155
+ if (!moduleMap2 || !umbrella || !outputModuleMap || !outputUmbrella || !outputHeader)
4156
+ throw new Error(`${name}: incomplete CocoaPods Swift compatibility header phase`);
4157
+ return [{ id, moduleMap: moduleMap2, umbrella, outputModuleMap, outputUmbrella, outputHeader }];
4158
+ });
4159
+ if (compatibilityPhases.length > 1)
4160
+ throw new Error(`${name}: multiple CocoaPods Swift compatibility header phases`);
4161
+ const compatibility = compatibilityPhases[0];
4162
+ if (compatibility && members.sources.length === 0)
4163
+ throw new Error(
4164
+ `${name}: Swift compatibility header phase has no Swift producer sources`
4165
+ );
3306
4166
  const building = options.prepareGeneratedSources && options.requireSources !== false;
3307
- const versioning = building && allSources.length > 0 && settings2("VERSIONING_SYSTEM") === "apple-generic" ? path2.join(settings2("DERIVED_FILE_DIR"), `${product}_vers.c`) : null;
4167
+ const versioning = building && allSources.length > 0 && settings2("VERSIONING_SYSTEM") === "apple-generic" ? path5.join(settings2("DERIVED_FILE_DIR"), `${product}_vers.c`) : null;
3308
4168
  if (versioning) {
3309
4169
  const version = settings2("CURRENT_PROJECT_VERSION");
3310
4170
  const custom = [
@@ -3317,7 +4177,7 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3317
4177
  ].filter((key) => settings2(key));
3318
4178
  if (custom.length)
3319
4179
  throw new Error(
3320
- `${name}: Xcode generates ${path2.basename(versioning)} with ${custom.join(", ")}; peach does not model VERSION_INFO_* overrides`
4180
+ `${name}: Xcode generates ${path5.basename(versioning)} with ${custom.join(", ")}; peach does not model VERSION_INFO_* overrides`
3321
4181
  );
3322
4182
  const symbol = product.replace(/^[^A-Za-z_]/, "_").replace(/[^A-Za-z0-9_]/g, "_");
3323
4183
  const [major, minor] = version.split(".");
@@ -3330,9 +4190,9 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3330
4190
  ` const double ${symbol}VersionNumber __attribute__ ((used)) = (double)${number};`,
3331
4191
  ""
3332
4192
  ].join("\n");
3333
- if (!fs.existsSync(versioning) || fs.readFileSync(versioning, "utf8") !== unit) {
3334
- fs.mkdirSync(path2.dirname(versioning), { recursive: true });
3335
- fs.writeFileSync(versioning, unit);
4193
+ if (!fs4.existsSync(versioning) || fs4.readFileSync(versioning, "utf8") !== unit) {
4194
+ fs4.mkdirSync(path5.dirname(versioning), { recursive: true });
4195
+ fs4.writeFileSync(versioning, unit);
3336
4196
  }
3337
4197
  allSources.push(versioning);
3338
4198
  }
@@ -3351,29 +4211,61 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3351
4211
  const headerFiles = headerPhase(ref);
3352
4212
  const ownHeaders = /* @__PURE__ */ new Map();
3353
4213
  for (const { file, visibility } of headerFiles) {
3354
- const name2 = path2.basename(file);
4214
+ const name2 = path5.basename(file);
3355
4215
  const published = visibility !== "Project";
3356
4216
  if (!ownHeaders.has(name2))
3357
4217
  ownHeaders.set(name2, published ? `${product}/${name2}` : file);
3358
4218
  if (!published && !ownHeaders.has(`${product}/${name2}`))
3359
4219
  ownHeaders.set(`${product}/${name2}`, file);
3360
4220
  }
4221
+ for (const file of synchronizedHeaders(ref)) {
4222
+ const name2 = path5.basename(file);
4223
+ if (ownHeaders.has(name2)) continue;
4224
+ ownHeaders.set(name2, file);
4225
+ const qualified = `${product}/${name2}`;
4226
+ if (!ownHeaders.has(qualified)) ownHeaders.set(qualified, file);
4227
+ }
3361
4228
  const nonFrameworkHeaders = /* @__PURE__ */ new Map();
3362
4229
  for (const other of projectTargets(ref.project)) {
3363
4230
  if (FRAMEWORK_PRODUCTS.has(str(other.target.productType) ?? "")) continue;
3364
4231
  const otherProduct = productName(other);
3365
4232
  for (const { file, visibility } of headerPhase(other)) {
3366
4233
  if (visibility === "Project") continue;
3367
- const key = `${otherProduct}/${path2.basename(file)}`;
4234
+ const key = `${otherProduct}/${path5.basename(file)}`;
3368
4235
  if (!nonFrameworkHeaders.has(key)) nonFrameworkHeaders.set(key, file);
3369
4236
  }
3370
4237
  }
3371
- const wrapper = path2.join(settings2("BUILT_PRODUCTS_DIR"), `${product}.framework`);
4238
+ const wrapper = path5.join(settings2("BUILT_PRODUCTS_DIR"), `${product}.framework`);
3372
4239
  const moduleMap = (settings2("DEFINES_MODULE") === "YES" || !framework) && settings2("MODULEMAP_FILE") ? absolute(settings2("MODULEMAP_FILE")) : null;
3373
- const podHeaders = !framework && isPodsProject(ref.project.xcodeproj) && moduleMap && path2.relative(path2.join(ref.project.projectDir, "Headers", "Public"), moduleMap).split(path2.sep)[0] !== ".." && fs.existsSync(moduleMap) ? fs.readdirSync(path2.dirname(moduleMap)).flatMap((entry) => {
4240
+ const frameworkUmbrella = !compatibility && framework && members.sources.length > 0 && moduleMap ? path5.join(path5.dirname(moduleMap), `${moduleName}-umbrella.h`) : null;
4241
+ const frameworkCompatibility = frameworkUmbrella && moduleMap && fs4.existsSync(moduleMap) && fs4.existsSync(frameworkUmbrella) ? {
4242
+ framework: true,
4243
+ moduleMap,
4244
+ umbrella: frameworkUmbrella,
4245
+ outputModuleMap: path5.join(wrapper, "Modules", "module.modulemap"),
4246
+ outputUmbrella: path5.join(
4247
+ wrapper,
4248
+ "Headers",
4249
+ path5.basename(frameworkUmbrella)
4250
+ ),
4251
+ outputHeader: path5.join(
4252
+ wrapper,
4253
+ "Headers",
4254
+ settings2("SWIFT_OBJC_INTERFACE_HEADER_NAME") || `${moduleName}-Swift.h`
4255
+ )
4256
+ } : null;
4257
+ const swiftCompatibility = compatibility ? {
4258
+ framework: false,
4259
+ moduleMap: compatibility.moduleMap,
4260
+ umbrella: compatibility.umbrella,
4261
+ outputModuleMap: compatibility.outputModuleMap,
4262
+ outputUmbrella: compatibility.outputUmbrella,
4263
+ outputHeader: compatibility.outputHeader
4264
+ } : frameworkCompatibility;
4265
+ const podHeaders = !framework && isPodsProject(ref.project.xcodeproj) && moduleMap && path5.relative(path5.join(ref.project.projectDir, "Headers", "Public"), moduleMap).split(path5.sep)[0] !== ".." && fs4.existsSync(moduleMap) ? fs4.readdirSync(path5.dirname(moduleMap)).flatMap((entry) => {
3374
4266
  if (!/\.(h|hh|hpp|hxx|modulemap)$/.test(entry)) return [];
3375
- const file = path2.join(path2.dirname(moduleMap), entry);
3376
- return fs.existsSync(file) ? [file] : [];
4267
+ const file = path5.join(path5.dirname(moduleMap), entry);
4268
+ return fs4.existsSync(file) ? [file] : [];
3377
4269
  }) : [];
3378
4270
  const fileFlags = {};
3379
4271
  for (const phaseId of list(ref.target.buildPhases)) {
@@ -3391,12 +4283,14 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3391
4283
  );
3392
4284
  }
3393
4285
  }
4286
+ const cStandard = settings2("GCC_C_LANGUAGE_STANDARD");
4287
+ const cxxStandard = settings2("CLANG_CXX_LANGUAGE_STANDARD");
3394
4288
  return {
3395
4289
  settings: settings2,
3396
4290
  keys,
3397
4291
  module: {
3398
4292
  name,
3399
- moduleName: applyOperator(settings2("PRODUCT_MODULE_NAME"), "c99extidentifier"),
4293
+ moduleName,
3400
4294
  ...members,
3401
4295
  allSources,
3402
4296
  languageMode: swiftVersion >= 6 ? 6 : 5,
@@ -3411,6 +4305,14 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3411
4305
  )
3412
4306
  )
3413
4307
  },
4308
+ packageProducts: Array(),
4309
+ ...members.sources.length > 0 ? {
4310
+ swift: {
4311
+ flags: settingList(settings2("OTHER_SWIFT_FLAGS")),
4312
+ includePaths: settingList(settings2("SWIFT_INCLUDE_PATHS")).map(absolute),
4313
+ compatibility: swiftCompatibility
4314
+ }
4315
+ } : {},
3414
4316
  ...native ? {
3415
4317
  objc: {
3416
4318
  publicHeaders: [
@@ -3424,7 +4326,7 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3424
4326
  ...headers,
3425
4327
  ...Object.keys(ref.project.objects).flatMap((id) => {
3426
4328
  const file = ref.project.resolvePath(id);
3427
- return file && HEADER_FILE.test(file) && fs.existsSync(file) ? [file] : [];
4329
+ return file && HEADER_FILE.test(file) && fs4.existsSync(file) ? [file] : [];
3428
4330
  })
3429
4331
  ])
3430
4332
  ],
@@ -3433,15 +4335,15 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3433
4335
  // xcode searches its products' include directory before
3434
4336
  // HEADER_SEARCH_PATHS and the target's derived sources after.
3435
4337
  headerSearchPaths: [
3436
- path2.join(settings2("BUILT_PRODUCTS_DIR"), "include"),
4338
+ path5.join(settings2("BUILT_PRODUCTS_DIR"), "include"),
3437
4339
  ...settingList(settings2("HEADER_SEARCH_PATHS")).flatMap(
3438
4340
  (raw) => expandSearchPath(absolute(raw), searchRules)
3439
4341
  ),
3440
- path2.join(
4342
+ path5.join(
3441
4343
  `${settings2("DERIVED_FILE_DIR")}-normal`,
3442
4344
  settings2("CURRENT_ARCH")
3443
4345
  ),
3444
- path2.join(settings2("DERIVED_FILE_DIR"), settings2("CURRENT_ARCH")),
4346
+ path5.join(settings2("DERIVED_FILE_DIR"), settings2("CURRENT_ARCH")),
3445
4347
  settings2("DERIVED_FILE_DIR")
3446
4348
  ],
3447
4349
  userHeaderSearchPaths: settingList(
@@ -3458,14 +4360,18 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3458
4360
  settings2("CLANG_ENABLE_OBJC_ARC") === "YES" ? "-fobjc-arc" : "-fno-objc-arc",
3459
4361
  ...settings2("CLANG_ENABLE_OBJC_WEAK") === "YES" ? ["-fobjc-weak"] : [],
3460
4362
  ...settings2("CLANG_ENABLE_MODULES") === "YES" ? ["-fmodules"] : [],
3461
- ...settings2("GCC_C_LANGUAGE_STANDARD") ? [`-std=${settings2("GCC_C_LANGUAGE_STANDARD")}`] : [],
4363
+ ...cStandard && cStandard !== "compiler-default" ? [`-std=${cStandard}`] : [],
3462
4364
  ...settingList(settings2("GCC_PREPROCESSOR_DEFINITIONS")).map(
3463
4365
  (value) => `-D${value}`
3464
4366
  ),
3465
4367
  ...settingList(settings2("OTHER_CFLAGS"))
3466
4368
  ],
3467
4369
  cxxFlags: [
3468
- ...settings2("CLANG_CXX_LANGUAGE_STANDARD") ? [`-std=${settings2("CLANG_CXX_LANGUAGE_STANDARD")}`] : [],
4370
+ ...cxxStandard && cxxStandard !== "compiler-default" ? [`-std=${CXX_STANDARD_ALIASES[cxxStandard] ?? cxxStandard}`] : [],
4371
+ // clang.xcspec's hidden CLANG_DISABLE_CXX_MODULES (default
4372
+ // YES) keeps c++ and objective-c++ units out of modules when
4373
+ // modules are on or the standard is c++20 or later.
4374
+ ...settings2("CLANG_DISABLE_CXX_MODULES") !== "NO" && (settings2("CLANG_ENABLE_MODULES") === "YES" || !PRE_CXX20_STANDARDS.has(cxxStandard || "compiler-default")) ? ["-fno-cxx-modules"] : [],
3469
4375
  ...settingList(settings2("OTHER_CPLUSPLUSFLAGS"))
3470
4376
  ],
3471
4377
  fileFlags,
@@ -3481,16 +4387,42 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3481
4387
  ...headerFiles.flatMap(
3482
4388
  ({ file, visibility }) => visibility === "Project" ? [] : [
3483
4389
  [
3484
- path2.join(
4390
+ path5.join(
3485
4391
  wrapper,
3486
4392
  visibility === "Public" ? "Headers" : "PrivateHeaders",
3487
- path2.basename(file)
4393
+ path5.basename(file)
3488
4394
  ),
3489
4395
  file
3490
4396
  ]
3491
4397
  ]
3492
4398
  ),
3493
- ...moduleMap ? [[path2.join(wrapper, "Modules", "module.modulemap"), moduleMap]] : []
4399
+ // a copy files phase into the products directory, as
4400
+ // cocoapods writes for each header_mappings_dir folder.
4401
+ ...list(ref.target.buildPhases).flatMap((phaseId) => {
4402
+ const phase = ref.project.object(phaseId);
4403
+ if (phase?.isa !== "PBXCopyFilesBuildPhase" || str(phase.dstSubfolderSpec) !== "16")
4404
+ return [];
4405
+ const destination = expand(
4406
+ str(phase.dstPath) ?? "",
4407
+ (name2) => name2 === "PUBLIC_HEADERS_FOLDER_PATH" ? path5.join(wrapper, "Headers") : name2 === "PRIVATE_HEADERS_FOLDER_PATH" ? path5.join(wrapper, "PrivateHeaders") : settings2(name2)
4408
+ );
4409
+ return list(phase.files).flatMap((id) => {
4410
+ const file = ref.project.resolvePath(
4411
+ str(ref.project.object(id)?.fileRef) ?? ""
4412
+ );
4413
+ return file && HEADER_FILE.test(file) ? [
4414
+ [
4415
+ path5.resolve(
4416
+ settings2("BUILT_PRODUCTS_DIR"),
4417
+ destination,
4418
+ path5.basename(file)
4419
+ ),
4420
+ file
4421
+ ]
4422
+ ] : [];
4423
+ });
4424
+ }),
4425
+ ...moduleMap ? [[path5.join(wrapper, "Modules", "module.modulemap"), moduleMap]] : []
3494
4426
  ]) : Object.fromEntries(podHeaders.map((file) => [file, file]))
3495
4427
  }
3496
4428
  } : {}
@@ -3499,28 +4431,94 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3499
4431
  };
3500
4432
  const builtTargets = order.map((ref) => ({ ref, ...moduleTarget(ref) }));
3501
4433
  const { settings, keys: settingKeys, module } = builtTargets.at(-1);
3502
- const frameworkTargets = builtTargets.slice(0, -1).filter(({ ref }) => ref.target.isa === "PBXNativeTarget").map(({ ref, module: module2 }) => ({ ref, framework: module2 }));
4434
+ const frameworkTargets = builtTargets.slice(0, -1).filter(({ ref }) => MODULE_PRODUCTS.has(str(ref.target.productType) ?? "")).map(({ ref, module: module2 }) => ({ ref, framework: module2 }));
3503
4435
  const frameworks = frameworkTargets.map(({ framework }) => framework);
3504
4436
  const podSourceDirs = frameworkTargets.flatMap(
3505
- ({ ref, framework }) => isPodsProject(ref.project.xcodeproj) ? [...framework.allSources, ...framework.objc?.headers ?? []].map((file) => path2.dirname(file)).filter((dir) => fs.existsSync(dir)) : []
4437
+ ({ ref, framework }) => isPodsProject(ref.project.xcodeproj) ? [...framework.allSources, ...framework.objc?.headers ?? []].map((file) => path5.dirname(file)).filter((dir) => fs4.existsSync(dir)) : []
3506
4438
  );
3507
- const expandValue = (value) => {
3508
- if (typeof value === "string") return expand(value, settings);
3509
- if (Array.isArray(value)) return value.map(expandValue);
4439
+ const expandValue = (value, settings2) => {
4440
+ if (typeof value === "string") return expand(value, settings2);
4441
+ if (Array.isArray(value)) return value.map((item) => expandValue(item, settings2));
3510
4442
  if (typeof value === "object" && !(value instanceof Date) && !Buffer.isBuffer(value)) {
3511
4443
  return Object.fromEntries(
3512
- Object.entries(value).map(([key, value2]) => [key, expandValue(value2)])
4444
+ Object.entries(value).map(([key, value2]) => [key, expandValue(value2, settings2)])
3513
4445
  );
3514
4446
  }
3515
4447
  return value;
3516
4448
  };
3517
- const infoPlistFile = settings("INFOPLIST_FILE") ? path2.resolve(app.project.projectDir, settings("INFOPLIST_FILE")) : null;
3518
- const sourceInfo = infoPlistFile ? plist2.parse(fs.readFileSync(infoPlistFile, "utf8")) : {};
4449
+ const resourceProducts = [];
4450
+ const bundleTargets = builtTargets.filter(
4451
+ ({ ref }) => ref.target.productType === RESOURCE_BUNDLE
4452
+ );
4453
+ for (const owner of options.installedPods ? builtTargets : []) {
4454
+ for (const phaseId of list(owner.ref.target.buildPhases)) {
4455
+ const phase = owner.ref.project.object(phaseId);
4456
+ if (phase?.isa !== "PBXShellScriptBuildPhase" || str(phase.name) !== "[CP] Copy Pods Resources")
4457
+ continue;
4458
+ const absolute = (raw) => path5.resolve(owner.ref.project.projectDir, expand(raw, owner.settings));
4459
+ const entries = (paths) => paths.flatMap((raw) => {
4460
+ const file = absolute(raw);
4461
+ xcconfigs.add(file);
4462
+ return fileListEntries(file, absolute);
4463
+ });
4464
+ const inputs = entries(list(phase.inputFileListPaths)).filter(
4465
+ (file) => file.endsWith(".bundle")
4466
+ );
4467
+ const outputs = entries(list(phase.outputFileListPaths)).filter(
4468
+ (file) => file.endsWith(".bundle")
4469
+ );
4470
+ if (inputs.length !== outputs.length)
4471
+ throw new Error(`${owner.module.name}: resource bundle copy lists differ`);
4472
+ const destinationRoot = path5.join(
4473
+ owner.settings("TARGET_BUILD_DIR"),
4474
+ owner.settings("UNLOCALIZED_RESOURCES_FOLDER_PATH")
4475
+ );
4476
+ for (const [index, input2] of inputs.entries()) {
4477
+ const product = bundleTargets.find((target) => {
4478
+ const file = str(
4479
+ target.ref.project.object(str(target.ref.target.productReference))?.path
4480
+ );
4481
+ return file && path5.join(target.settings("TARGET_BUILD_DIR"), file) === input2;
4482
+ });
4483
+ if (!product)
4484
+ throw new Error(
4485
+ `${owner.module.name}: resource bundle input has no selected producer: ${input2}`
4486
+ );
4487
+ const destination = path5.relative(destinationRoot, outputs[index]);
4488
+ if (destination === ".." || destination.startsWith(`..${path5.sep}`) || path5.isAbsolute(destination) || path5.basename(input2) !== path5.basename(destination))
4489
+ throw new Error(
4490
+ `${owner.module.name}: invalid resource bundle copy destination`
4491
+ );
4492
+ const infoFile = path5.resolve(
4493
+ product.ref.project.projectDir,
4494
+ product.settings("INFOPLIST_FILE")
4495
+ );
4496
+ xcconfigs.add(infoFile);
4497
+ const parsed = plist2.parse(fs4.readFileSync(infoFile, "utf8"));
4498
+ const infoPlist = plist2.build(expandValue(parsed, product.settings));
4499
+ const prefix = owner.ref === app ? "" : `Frameworks/${owner.module.moduleName}.framework/`;
4500
+ const bundlePath = prefix + destination.split(path5.sep).join("/");
4501
+ if (resourceProducts.some((resource) => resource.path === bundlePath))
4502
+ throw new Error(
4503
+ `${owner.module.name}: duplicate resource bundle destination ${bundlePath}`
4504
+ );
4505
+ resourceProducts.push({
4506
+ path: bundlePath,
4507
+ resources: product.module.resources,
4508
+ infoPlist
4509
+ });
4510
+ }
4511
+ }
4512
+ }
4513
+ const infoPlistFile = settings("INFOPLIST_FILE") ? path5.resolve(app.project.projectDir, settings("INFOPLIST_FILE")) : null;
4514
+ const infoPlistPending = module.generatedInfoPlist && !options.prepareGeneratedSources;
4515
+ const sourceInfo = infoPlistFile && !infoPlistPending ? plist2.parse(fs4.readFileSync(infoPlistFile, "utf8")) : {};
3519
4516
  if (!sourceInfo || typeof sourceInfo !== "object" || Array.isArray(sourceInfo) || sourceInfo instanceof Date || Buffer.isBuffer(sourceInfo)) {
3520
4517
  throw new Error(`${module.name} Info.plist must contain a dictionary`);
3521
4518
  }
3522
4519
  const info = {};
3523
- for (const [key, value] of Object.entries(sourceInfo)) info[key] = expandValue(value);
4520
+ for (const [key, value] of Object.entries(sourceInfo))
4521
+ info[key] = expandValue(value, settings);
3524
4522
  for (const key of settingKeys) {
3525
4523
  if (!key.startsWith("INFOPLIST_KEY_") || key.endsWith("_Generation")) continue;
3526
4524
  const value = settings(key);
@@ -3543,7 +4541,7 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3543
4541
  };
3544
4542
  }
3545
4543
  const localPackageDirs = [
3546
- ...listed.filter((reference) => fs.existsSync(path2.join(reference, "Package.swift"))),
4544
+ ...listed.filter((reference) => fs4.existsSync(path5.join(reference, "Package.swift"))),
3547
4545
  ...projects.flatMap(
3548
4546
  (project) => Object.entries(project.objects).flatMap(([id, entry]) => {
3549
4547
  if (!isDict(entry)) return [];
@@ -3553,19 +4551,19 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3553
4551
  const packages = [];
3554
4552
  while (pending.length > 0) {
3555
4553
  const dir = pending.pop();
3556
- if (fs.existsSync(path2.join(dir, "Package.swift"))) {
4554
+ if (fs4.existsSync(path5.join(dir, "Package.swift"))) {
3557
4555
  packages.push(dir);
3558
4556
  continue;
3559
4557
  }
3560
4558
  if (!isDirectory(dir)) continue;
3561
- for (const child of fs.readdirSync(dir, { withFileTypes: true }))
4559
+ for (const child of fs4.readdirSync(dir, { withFileTypes: true }))
3562
4560
  if (child.isDirectory() && !child.name.startsWith("."))
3563
- pending.push(path2.join(dir, child.name));
4561
+ pending.push(path5.join(dir, child.name));
3564
4562
  }
3565
4563
  return packages;
3566
4564
  }
3567
- const candidate = entry.isa === "XCLocalSwiftPackageReference" ? path2.resolve(project.projectDir, str(entry.relativePath) ?? "") : entry.isa === "PBXFileReference" ? project.resolvePath(id) : null;
3568
- return candidate && fs.existsSync(path2.join(candidate, "Package.swift")) ? [candidate] : [];
4565
+ const candidate = entry.isa === "XCLocalSwiftPackageReference" ? path5.resolve(project.projectDir, str(entry.relativePath) ?? "") : entry.isa === "PBXFileReference" ? project.resolvePath(id) : null;
4566
+ return candidate && fs4.existsSync(path5.join(candidate, "Package.swift")) ? [candidate] : [];
3569
4567
  })
3570
4568
  )
3571
4569
  ];
@@ -3586,12 +4584,12 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3586
4584
  const linkedProductKeys = /* @__PURE__ */ new Set();
3587
4585
  const binaryFrameworks = /* @__PURE__ */ new Map();
3588
4586
  for (const { ref, settings: settings2 } of builtTargets) {
3589
- const absolute = (raw) => path2.resolve(ref.project.projectDir, expand(raw, settings2));
4587
+ const absolute = (raw) => path5.resolve(ref.project.projectDir, expand(raw, settings2));
3590
4588
  for (const raw of settingList(settings2("SWIFT_INCLUDE_PATHS"))) {
3591
4589
  const dir = absolute(raw);
3592
- const modulemap = path2.join(dir, "module.modulemap");
3593
- if (!fs.existsSync(modulemap)) continue;
3594
- const name = moduleMapName(fs.readFileSync(modulemap, "utf8"));
4590
+ const modulemap = path5.join(dir, "module.modulemap");
4591
+ if (!fs4.existsSync(modulemap)) continue;
4592
+ const name = moduleMapName(fs4.readFileSync(modulemap, "utf8"));
3595
4593
  if (name && !binaryFrameworks.has(name)) binaryFrameworks.set(name, dir);
3596
4594
  }
3597
4595
  for (const phaseId of list(ref.target.buildPhases)) {
@@ -3600,7 +4598,7 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3600
4598
  const inputs = list(phase.inputPaths).map(absolute);
3601
4599
  for (const raw of list(phase.inputFileListPaths)) {
3602
4600
  const file = absolute(raw);
3603
- if (!fs.existsSync(file)) continue;
4601
+ if (!fs4.existsSync(file)) continue;
3604
4602
  xcconfigs.add(file);
3605
4603
  inputs.push(...fileListEntries(file, absolute));
3606
4604
  }
@@ -3610,10 +4608,12 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3610
4608
  }
3611
4609
  }
3612
4610
  }
3613
- for (const { project, target } of order) {
4611
+ const productsByTarget = /* @__PURE__ */ new Map();
4612
+ for (const ref of order) {
4613
+ const { project, target } = ref;
3614
4614
  const productRef = (id) => {
3615
- const ref = str(project.object(id)?.productRef);
3616
- return ref ? [ref] : [];
4615
+ const ref2 = str(project.object(id)?.productRef);
4616
+ return ref2 ? [ref2] : [];
3617
4617
  };
3618
4618
  const productDependencies = [
3619
4619
  ...list(target.packageProductDependencies),
@@ -3623,6 +4623,8 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3623
4623
  return phase?.isa === "PBXFrameworksBuildPhase" ? list(phase.files).flatMap(productRef) : [];
3624
4624
  })
3625
4625
  ];
4626
+ const ownProducts = [];
4627
+ const ownKeys = /* @__PURE__ */ new Set();
3626
4628
  for (const dependencyId of new Set(productDependencies)) {
3627
4629
  const dependency = project.object(dependencyId);
3628
4630
  const product = str(dependency?.productName)?.replace(/^plugin:/, "");
@@ -3635,7 +4637,7 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3635
4637
  product,
3636
4638
  source: reference?.isa === "XCRemoteSwiftPackageReference" ? { kind: "remote", url: str(reference.repositoryURL) ?? "" } : reference?.isa === "XCLocalSwiftPackageReference" ? {
3637
4639
  kind: "local",
3638
- dir: path2.resolve(
4640
+ dir: path5.resolve(
3639
4641
  project.projectDir,
3640
4642
  str(reference.relativePath) ?? ""
3641
4643
  )
@@ -3644,7 +4646,13 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3644
4646
  productReferences.push({ project: project.projectFile, linked });
3645
4647
  if (linked.source.kind !== "unnamed")
3646
4648
  qualifiedProductKeys.add(`${project.projectFile}\0${product}`);
4649
+ const key = JSON.stringify(linked);
4650
+ if (!ownKeys.has(key)) {
4651
+ ownKeys.add(key);
4652
+ ownProducts.push(linked);
4653
+ }
3647
4654
  }
4655
+ productsByTarget.set(ref, ownProducts);
3648
4656
  for (const phaseId of list(target.buildPhases)) {
3649
4657
  const phase = project.object(phaseId);
3650
4658
  if (phase?.isa !== "PBXFrameworksBuildPhase") continue;
@@ -3652,11 +4660,20 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3652
4660
  const fileId = str(project.object(buildFileId)?.fileRef);
3653
4661
  const file = project.object(fileId);
3654
4662
  const tree = str(file?.sourceTree);
3655
- const name = /([^/]+)\.(xc)?framework$/.exec(str(file?.path) ?? "")?.[1];
4663
+ const rawPath = str(file?.path) ?? "";
4664
+ const name = /([^/]+)\.(xc)?framework$/.exec(rawPath)?.[1];
3656
4665
  if (file?.isa !== "PBXFileReference" || !name) continue;
3657
- if (tree === "BUILT_PRODUCTS_DIR" || tree === "SDKROOT" || tree === "DEVELOPER_DIR")
4666
+ if (tree === "BUILT_PRODUCTS_DIR" || tree === "SDKROOT" || tree === "DEVELOPER_DIR" || // a path into the sdk's own frameworks folder is the sdk's own
4667
+ // however it is rooted: xcode links -framework <name> from the sdk
4668
+ // and a stale group-relative path to it contributes nothing.
4669
+ /\/System\/Library\/Frameworks\/[^/]+$/.test(`/${rawPath}`) || // a target in the workspace builds it, so it exists only after that build
4670
+ byProduct.has(path5.basename(rawPath)))
3658
4671
  continue;
3659
4672
  const resolved = fileId ? project.resolvePath(fileId) : null;
4673
+ if (fileId && resolved !== null && !fs4.existsSync(resolved))
4674
+ throw new Error(
4675
+ `${str(target.name) ?? "target"}: linked framework ${name} (${fileId}) points at missing ${resolved} in ${project.projectFile}`
4676
+ );
3660
4677
  if (!binaryFrameworks.get(name)) binaryFrameworks.set(name, resolved);
3661
4678
  }
3662
4679
  }
@@ -3669,26 +4686,35 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3669
4686
  linkedProductKeys.add(key);
3670
4687
  linkedProducts.push(linked);
3671
4688
  }
3672
- const resolvedFile = path2.join(
3673
- workspace ?? path2.join(xcodeprojOrWorkspace, "project.xcworkspace"),
4689
+ for (const built of builtTargets)
4690
+ built.module.packageProducts = productsByTarget.get(built.ref) ?? [];
4691
+ const resolvedFile = path5.join(
4692
+ workspace ?? path5.join(xcodeprojOrWorkspace, "project.xcworkspace"),
3674
4693
  "xcshareddata",
3675
4694
  "swiftpm",
3676
4695
  "Package.resolved"
3677
4696
  );
3678
- const packageResolved = fs.existsSync(resolvedFile) ? [fs.realpathSync(resolvedFile)] : [...new Set(localPackageDirs.map((dir) => path2.join(dir, "Package.resolved")))].filter((file) => fs.existsSync(file)).map((file) => fs.realpathSync(file)).sort();
4697
+ let packageResolved = fs4.existsSync(resolvedFile) ? [fs4.realpathSync(resolvedFile)] : [...new Set(localPackageDirs.map((dir) => path5.join(dir, "Package.resolved")))].filter((file) => fs4.existsSync(file)).map((file) => fs4.realpathSync(file)).sort();
4698
+ if (packageResolved.length === 0) {
4699
+ const requirements = remotePackageRequirements(projects);
4700
+ if (requirements.length > 0) {
4701
+ resolveSwiftPackageRequirements(requirements, resolvedFile);
4702
+ packageResolved = [fs4.realpathSync(resolvedFile)];
4703
+ }
4704
+ }
3679
4705
  const used = order.map((ref) => ref.project);
3680
4706
  return {
3681
4707
  ...module,
3682
4708
  rootDir: commonAncestor(
3683
4709
  [
3684
- workspace ? path2.dirname(workspace) : app.project.projectDir,
4710
+ workspace ? path5.dirname(workspace) : app.project.projectDir,
3685
4711
  ...used.map((project) => project.projectDir),
3686
4712
  ...localPackageDirs,
3687
4713
  ...linkedProducts.flatMap(
3688
- ({ source }) => source.kind === "local" && fs.existsSync(source.dir) ? [source.dir] : []
4714
+ ({ source }) => source.kind === "local" && fs4.existsSync(source.dir) ? [source.dir] : []
3689
4715
  ),
3690
4716
  ...new Set(podSourceDirs)
3691
- ].map((dir) => fs.realpathSync(dir))
4717
+ ].map((dir) => fs4.realpathSync(dir))
3692
4718
  ),
3693
4719
  projectFiles: [
3694
4720
  .../* @__PURE__ */ new Set([
@@ -3699,12 +4725,14 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
3699
4725
  ].sort(),
3700
4726
  projectDirs: [...new Set(used.map((project) => project.projectDir))].sort(),
3701
4727
  appIconName: settings("ASSETCATALOG_COMPILER_APPICON_NAME"),
3702
- infoPlist: plist2.build(info),
4728
+ infoPlist: infoPlistPending ? null : plist2.build(info),
3703
4729
  infoPlistFile,
4730
+ developmentRegion: str(app.project.project.developmentRegion) ?? "en",
3704
4731
  frameworks,
4732
+ resourceProducts,
3705
4733
  linkedProducts,
3706
4734
  localPackageDirs: [
3707
- ...new Set(localPackageDirs.map((dir) => fs.realpathSync(dir)))
4735
+ ...new Set(localPackageDirs.map((dir) => fs4.realpathSync(dir)))
3708
4736
  ].sort(),
3709
4737
  binaryFrameworks: [...binaryFrameworks].map(([name, file]) => ({ name, path: file })).sort((left, right) => left.name.localeCompare(right.name)),
3710
4738
  packageResolved,
@@ -3720,6 +4748,10 @@ function nonEmptyString2(value) {
3720
4748
  return typeof value === "string" && value.length > 0 ? value : void 0;
3721
4749
  }
3722
4750
  function readNativeAppIdentityFromXcodeTarget(app, parseInfoPlist = parsePlistSource) {
4751
+ if (app.infoPlist === null)
4752
+ throw new Error(
4753
+ "native app Info.plist is generated by a build phase and was not prepared"
4754
+ );
3723
4755
  const dictionary = parseInfoPlist(app.infoPlist);
3724
4756
  if (!isRecord(dictionary)) throw new Error("native app Info.plist is not a dictionary");
3725
4757
  const settings = app.settings;
@@ -3779,7 +4811,7 @@ function readNativeAppIdentityFromXcodeTarget(app, parseInfoPlist = parsePlistSo
3779
4811
  const rtcAppGroupIdentifier = nonEmptyString2(dictionary.RTCAppGroupIdentifier);
3780
4812
  const screenShareExtensionBundleId = typeof dictionary.ScreenShareExtensionBundleId === "string" ? dictionary.ScreenShareExtensionBundleId : void 0;
3781
4813
  const rootModuleName = readRootModuleName(
3782
- app.allSources.filter((file) => /\.(?:swift|mm|m)$/.test(file) && fs2.existsSync(file)).map((file) => fs2.readFileSync(file, "utf8"))
4814
+ app.allSources.filter((file) => /\.(?:swift|mm|m)$/.test(file) && fs5.existsSync(file)).map((file) => fs5.readFileSync(file, "utf8"))
3783
4815
  );
3784
4816
  return {
3785
4817
  applicationName,
@@ -3800,7 +4832,7 @@ function readNativeAppIdentityFromXcodeTarget(app, parseInfoPlist = parsePlistSo
3800
4832
  googleSignIn: readGoogleSignInConfiguration(
3801
4833
  dictionary,
3802
4834
  Object.fromEntries(
3803
- app.resources.filter((file) => file.endsWith(".plist")).map((file) => [file, parseInfoPlist(fs2.readFileSync(file, "utf8"))])
4835
+ app.resources.filter((file) => file.endsWith(".plist")).map((file) => [file, parseInfoPlist(fs5.readFileSync(file, "utf8"))])
3804
4836
  )
3805
4837
  ),
3806
4838
  supportedInterfaceOrientations,
@@ -3809,11 +4841,11 @@ function readNativeAppIdentityFromXcodeTarget(app, parseInfoPlist = parsePlistSo
3809
4841
  alternateIconNames: [...alternateIconNames],
3810
4842
  appIconArtwork: resolveNativeAppIconArtwork(
3811
4843
  app.resources,
3812
- (file) => fs2.readFileSync(file, "utf8"),
4844
+ (file) => fs5.readFileSync(file, "utf8"),
3813
4845
  (file) => {
3814
- const extension = path3.extname(file).toLowerCase();
4846
+ const extension = path6.extname(file).toLowerCase();
3815
4847
  const contentType = extension === ".jpg" || extension === ".jpeg" ? "image/jpeg" : extension === ".webp" ? "image/webp" : "image/png";
3816
- return `data:${contentType};base64,${fs2.readFileSync(file).toString("base64")}`;
4848
+ return `data:${contentType};base64,${fs5.readFileSync(file).toString("base64")}`;
3817
4849
  },
3818
4850
  icons,
3819
4851
  app.appIconName,
@@ -3833,10 +4865,10 @@ function readNativeAppIdentityFromXcodeTarget(app, parseInfoPlist = parsePlistSo
3833
4865
  }
3834
4866
  var NativeAppTargetSelectionError = class extends Error {
3835
4867
  };
3836
- function readNativeAppIdentityFromProject(projectRoot, platform, parseInfoPlist = parsePlistSource, iosTarget, androidMergedManifest) {
4868
+ function readNativeAppIdentityFromProject(projectRoot, platform, parseInfoPlist = parsePlistSource, iosTarget, androidMergedManifest, environment) {
3837
4869
  const read = selectNativeAppIdentityReader(platform, {
3838
4870
  android: () => readAndroidNativeAppIdentity(projectRoot, androidMergedManifest),
3839
- ios: () => readIosNativeAppIdentity(projectRoot, parseInfoPlist, iosTarget)
4871
+ ios: () => readIosNativeAppIdentity(projectRoot, parseInfoPlist, iosTarget, environment)
3840
4872
  });
3841
4873
  return read ? read() : null;
3842
4874
  }
@@ -3844,22 +4876,22 @@ function readNativeAppIdentityFromSources(projectRoot, platform, parseInfoPlist,
3844
4876
  const read = selectNativeAppIdentityReader(platform, {
3845
4877
  android: () => null,
3846
4878
  ios: () => {
3847
- const iosRoot = path3.join(projectRoot, "ios");
3848
- if (!fs2.existsSync(iosRoot)) return null;
4879
+ const iosRoot = path6.join(projectRoot, "ios");
4880
+ if (!fs5.existsSync(iosRoot)) return null;
3849
4881
  const files = {};
3850
- for (const entry of fs2.readdirSync(iosRoot, { withFileTypes: true })) {
4882
+ for (const entry of fs5.readdirSync(iosRoot, { withFileTypes: true })) {
3851
4883
  if (entry.name === "Pods") continue;
3852
4884
  if (entry.isDirectory()) {
3853
4885
  const names = entry.name.endsWith(".xcodeproj") ? ["project.pbxproj"] : ["Info.plist", "AppDelegate.swift", "AppDelegate.mm", "AppDelegate.m"];
3854
4886
  for (const name of names) {
3855
4887
  const relative2 = `ios/${entry.name}/${name}`;
3856
- const file = path3.join(projectRoot, relative2);
3857
- if (fs2.existsSync(file)) files[relative2] = fs2.readFileSync(file, "utf8");
4888
+ const file = path6.join(projectRoot, relative2);
4889
+ if (fs5.existsSync(file)) files[relative2] = fs5.readFileSync(file, "utf8");
3858
4890
  }
3859
4891
  } else if (/AppDelegate\.(?:swift|mm|m)$/.test(entry.name)) {
3860
4892
  const relative2 = `ios/${entry.name}`;
3861
- const file = path3.join(projectRoot, relative2);
3862
- if (fs2.existsSync(file)) files[relative2] = fs2.readFileSync(file, "utf8");
4893
+ const file = path6.join(projectRoot, relative2);
4894
+ if (fs5.existsSync(file)) files[relative2] = fs5.readFileSync(file, "utf8");
3863
4895
  }
3864
4896
  }
3865
4897
  return extractNativeAppIdentityFromFiles(files, "ios", parseInfoPlist, iosTarget);
@@ -3870,41 +4902,41 @@ function readNativeAppIdentityFromSources(projectRoot, platform, parseInfoPlist,
3870
4902
  function readAndroidNativeAppIdentity(projectRoot, androidMergedManifest) {
3871
4903
  const files = {};
3872
4904
  if (androidMergedManifest) {
3873
- const file = path3.resolve(projectRoot, androidMergedManifest);
3874
- if (!fs2.existsSync(file)) return null;
3875
- files[androidMergedManifest] = fs2.readFileSync(file, "utf8");
4905
+ const file = path6.resolve(projectRoot, androidMergedManifest);
4906
+ if (!fs5.existsSync(file)) return null;
4907
+ files[androidMergedManifest] = fs5.readFileSync(file, "utf8");
3876
4908
  } else {
3877
- const androidRoot = path3.join(projectRoot, "android");
3878
- if (!fs2.existsSync(androidRoot)) return null;
4909
+ const androidRoot = path6.join(projectRoot, "android");
4910
+ if (!fs5.existsSync(androidRoot)) return null;
3879
4911
  const collect = (directory) => {
3880
- for (const entry of fs2.readdirSync(directory, { withFileTypes: true })) {
3881
- const file = path3.join(directory, entry.name);
4912
+ for (const entry of fs5.readdirSync(directory, { withFileTypes: true })) {
4913
+ const file = path6.join(directory, entry.name);
3882
4914
  if (entry.isDirectory()) collect(file);
3883
4915
  else if (entry.isFile() && entry.name === "AndroidManifest.xml")
3884
- files[path3.relative(projectRoot, file).split(path3.sep).join("/")] = fs2.readFileSync(file, "utf8");
4916
+ files[path6.relative(projectRoot, file).split(path6.sep).join("/")] = fs5.readFileSync(file, "utf8");
3885
4917
  }
3886
4918
  };
3887
- for (const module of fs2.readdirSync(androidRoot, { withFileTypes: true })) {
4919
+ for (const module of fs5.readdirSync(androidRoot, { withFileTypes: true })) {
3888
4920
  if (!module.isDirectory()) continue;
3889
- const outputs = path3.join(
4921
+ const outputs = path6.join(
3890
4922
  androidRoot,
3891
4923
  module.name,
3892
4924
  "build/intermediates/merged_manifests"
3893
4925
  );
3894
- if (fs2.existsSync(outputs)) collect(outputs);
4926
+ if (fs5.existsSync(outputs)) collect(outputs);
3895
4927
  }
3896
4928
  }
3897
4929
  for (const manifest of Object.keys(files)) {
3898
4930
  const resourceDirectory = androidMergedResourceValuesDirectory(manifest);
3899
4931
  if (!resourceDirectory) continue;
3900
- const absolute = path3.resolve(projectRoot, resourceDirectory);
3901
- if (!fs2.existsSync(absolute)) continue;
3902
- for (const entry of fs2.readdirSync(absolute, { withFileTypes: true })) {
4932
+ const absolute = path6.resolve(projectRoot, resourceDirectory);
4933
+ if (!fs5.existsSync(absolute)) continue;
4934
+ for (const entry of fs5.readdirSync(absolute, { withFileTypes: true })) {
3903
4935
  if (!entry.isDirectory() || !/^values(?:-|$)/.test(entry.name)) continue;
3904
- for (const resource of fs2.readdirSync(path3.join(absolute, entry.name))) {
4936
+ for (const resource of fs5.readdirSync(path6.join(absolute, entry.name))) {
3905
4937
  if (!resource.endsWith(".xml")) continue;
3906
4938
  const file = `${resourceDirectory}/${entry.name}/${resource}`;
3907
- files[file] = fs2.readFileSync(path3.resolve(projectRoot, file), "utf8");
4939
+ files[file] = fs5.readFileSync(path6.resolve(projectRoot, file), "utf8");
3908
4940
  }
3909
4941
  }
3910
4942
  }
@@ -3917,11 +4949,11 @@ function readAndroidNativeAppIdentity(projectRoot, androidMergedManifest) {
3917
4949
  androidMergedManifest
3918
4950
  );
3919
4951
  }
3920
- function readIosNativeAppIdentity(projectRoot, parseInfoPlist, iosTarget) {
3921
- const app = readIosAppTarget(projectRoot, iosTarget);
4952
+ function readIosNativeAppIdentity(projectRoot, parseInfoPlist, iosTarget, environment) {
4953
+ const app = readIosAppTarget(projectRoot, iosTarget, environment);
3922
4954
  if (!app) return null;
3923
4955
  const identity = readNativeAppIdentityFromXcodeTarget(app, parseInfoPlist);
3924
- const projectManifestPath = path3.join(projectRoot, "package.json");
4956
+ const projectManifestPath = path6.join(projectRoot, "package.json");
3925
4957
  const projectRequire = createRequire(projectManifestPath);
3926
4958
  let reanimatedManifestPath;
3927
4959
  try {
@@ -3935,22 +4967,22 @@ function readIosNativeAppIdentity(projectRoot, parseInfoPlist, iosTarget) {
3935
4967
  throw error;
3936
4968
  }
3937
4969
  const installedManifest = JSON.parse(
3938
- fs2.readFileSync(reanimatedManifestPath, "utf8")
4970
+ fs5.readFileSync(reanimatedManifestPath, "utf8")
3939
4971
  );
3940
4972
  const installedVersion = isRecord(installedManifest) ? nonEmptyString2(installedManifest.version) : void 0;
3941
4973
  if (!installedVersion) throw new Error("Reanimated package version is malformed");
3942
4974
  if (Number.parseInt(installedVersion, 10) < 4) return identity;
3943
4975
  const defaults = JSON.parse(
3944
- fs2.readFileSync(
3945
- path3.join(
3946
- path3.dirname(reanimatedManifestPath),
4976
+ fs5.readFileSync(
4977
+ path6.join(
4978
+ path6.dirname(reanimatedManifestPath),
3947
4979
  "src/featureFlags/staticFlags.json"
3948
4980
  ),
3949
4981
  "utf8"
3950
4982
  )
3951
4983
  );
3952
4984
  if (!isRecord(defaults)) throw new Error("Reanimated static flags are malformed");
3953
- const manifest = JSON.parse(fs2.readFileSync(projectManifestPath, "utf8"));
4985
+ const manifest = JSON.parse(fs5.readFileSync(projectManifestPath, "utf8"));
3954
4986
  const reanimated = isRecord(manifest) ? manifest.reanimated : void 0;
3955
4987
  const overrides = isRecord(reanimated) ? reanimated.staticFeatureFlags : void 0;
3956
4988
  if (overrides !== void 0 && !isRecord(overrides)) {
@@ -3972,10 +5004,10 @@ function readIosNativeAppIdentity(projectRoot, parseInfoPlist, iosTarget) {
3972
5004
  }
3973
5005
  return { ...identity, reanimatedStaticFeatureFlags: flags };
3974
5006
  }
3975
- function readIosAppTarget(projectRoot, iosTarget) {
3976
- const iosRoot = path3.join(projectRoot, "ios");
3977
- if (!fs2.existsSync(iosRoot)) return null;
3978
- const projects = fs2.readdirSync(iosRoot, { withFileTypes: true }).filter((entry) => entry.isDirectory() && entry.name.endsWith(".xcodeproj"));
5007
+ function readIosAppTarget(projectRoot, iosTarget, environment) {
5008
+ const iosRoot = path6.join(projectRoot, "ios");
5009
+ if (!fs5.existsSync(iosRoot)) return null;
5010
+ const projects = fs5.readdirSync(iosRoot, { withFileTypes: true }).filter((entry) => entry.isDirectory() && entry.name.endsWith(".xcodeproj"));
3979
5011
  if (projects.length === 0) return null;
3980
5012
  if (projects.length > 1 && !iosTarget) {
3981
5013
  throw new NativeAppTargetSelectionError(
@@ -3985,7 +5017,7 @@ function readIosAppTarget(projectRoot, iosTarget) {
3985
5017
  let project = projects[0];
3986
5018
  if (iosTarget && projects.length > 1) {
3987
5019
  const matches = projects.filter(
3988
- (entry) => listXcodeAppTargets(path3.join(iosRoot, entry.name), {
5020
+ (entry) => listXcodeAppTargets(path6.join(iosRoot, entry.name), {
3989
5021
  requireSources: false
3990
5022
  }).includes(iosTarget)
3991
5023
  );
@@ -3999,7 +5031,7 @@ function readIosAppTarget(projectRoot, iosTarget) {
3999
5031
  }
4000
5032
  project = matches[0];
4001
5033
  }
4002
- const xcodeproj = path3.join(iosRoot, project.name);
5034
+ const xcodeproj = path6.join(iosRoot, project.name);
4003
5035
  const appTargets = listXcodeAppTargets(xcodeproj, { requireSources: false });
4004
5036
  if (!iosTarget && appTargets.length > 1) {
4005
5037
  throw new NativeAppTargetSelectionError(
@@ -4008,7 +5040,8 @@ function readIosAppTarget(projectRoot, iosTarget) {
4008
5040
  }
4009
5041
  return readXcodeAppTarget(xcodeproj, iosTarget ?? appTargets[0], "Release", {
4010
5042
  requireSources: false,
4011
- prepareGeneratedSources: true
5043
+ prepareGeneratedSources: true,
5044
+ environment
4012
5045
  });
4013
5046
  }
4014
5047
  export {