peachsim 0.1.1886 → 0.1.1887
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.
- package/cli/native-input.ts +1 -1
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.cjs +1 -1
- package/dist-lib/attached-projects.cjs +1 -1
- package/dist-lib/auth/shared-session.cjs +1 -1
- package/dist-lib/backend-origin.cjs +1 -1
- package/dist-lib/beta.cjs +1 -1
- package/dist-lib/beta.mjs +1 -1
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +1 -1
- package/dist-lib/bridge-contract-input.mjs +1 -1
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +1 -1
- package/dist-lib/bundle-channel.cjs +206 -82
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +1 -1
- package/dist-lib/cloud-contract.cjs +1 -1
- package/dist-lib/cloud-contract.mjs +1 -1
- package/dist-lib/cloud-test-args.cjs +1 -1
- package/dist-lib/cloud-test-args.mjs +1 -1
- package/dist-lib/cloud.cjs +1 -1
- package/dist-lib/cloud.mjs +1 -1
- package/dist-lib/config.cjs +1 -1
- package/dist-lib/config.mjs +1 -1
- package/dist-lib/detox/index.cjs +1 -1
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/expo-swift-bundle.cjs +136 -42
- package/dist-lib/expo-swift-metadata.cjs +1 -1
- package/dist-lib/expo-swift-metadata.mjs +1 -1
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +146 -23
- package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
- package/dist-lib/host/replacement-module-handler.cjs +1 -1
- package/dist-lib/host/websocket-proxy.cjs +1 -1
- package/dist-lib/index.cjs +15 -2
- package/dist-lib/jump-to-source-babel.cjs +1 -1
- package/dist-lib/jump-to-source-native.cjs +1 -1
- package/dist-lib/kotlin-host.cjs +1 -1
- package/dist-lib/menu.cjs +1 -1
- package/dist-lib/menu.mjs +1 -1
- package/dist-lib/metro-fingerprint-registry.cjs +1 -1
- package/dist-lib/metro-fingerprint-registry.mjs +1 -1
- package/dist-lib/metro-production-bundle.cjs +1 -1
- package/dist-lib/metro-production-bundle.mjs +1 -1
- package/dist-lib/metro.cjs +15 -2
- package/dist-lib/native-app-identity-project.cjs +15 -2
- package/dist-lib/native-app-identity-project.mjs +22 -3
- package/dist-lib/native-app-identity.cjs +1 -1
- package/dist-lib/native-app-identity.mjs +1 -1
- package/dist-lib/native-firebase-metadata.cjs +1 -1
- package/dist-lib/native-firebase-metadata.mjs +1 -1
- package/dist-lib/pdfium-raster.cjs +1 -1
- package/dist-lib/pdfium-raster.mjs +1 -1
- package/dist-lib/plist.cjs +1 -1
- package/dist-lib/plist.mjs +1 -1
- package/dist-lib/profiles.cjs +1 -1
- package/dist-lib/public-brand.cjs +1 -1
- package/dist-lib/public-origins-lib-esm.json +27 -24
- package/dist-lib/public-origins-lib.json +70 -53
- package/dist-lib/react-native-host-modules.cjs +1 -1
- package/dist-lib/react-native-host-modules.mjs +1 -1
- package/dist-lib/reap-browser.cjs +1 -1
- package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
- package/dist-lib/sdk.cjs +1 -1
- package/dist-lib/sdk.mjs +1 -1
- package/dist-lib/skills.cjs +170 -31
- package/dist-lib/swift-compile.cjs +100 -12
- package/dist-lib/swift-compile.mjs +104 -11
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +1 -1
- package/dist-lib/swift-submit.cjs +2 -2
- package/dist-lib/swift-submit.mjs +2 -2
- package/dist-lib/swift-toolchain.cjs +1 -1
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vite-swift.cjs +116 -18
- package/dist-lib/vite.cjs +1 -1
- package/dist-lib/worklet-executable.cjs +1 -1
- package/dist-lib/worklet-executable.mjs +1 -1
- package/package.json +1 -1
- package/src/expo-swift-bundle.ts +2 -7
- package/src/nitro-bundle.ts +7 -10
- package/src/podspec-sources.ts +20 -0
- package/src/swift-compile.ts +10 -5
- package/src/swift-host.ts +32 -19
- package/src/swift-icu.ts +60 -18
- package/src/swift-submit.ts +3 -1
- package/src/turbo-bundle.ts +1 -1
- package/src/turbo-codegen-intake.ts +10 -3
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1887 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -1991,7 +1991,7 @@ var init_swift_submit = __esm({
|
|
|
1991
1991
|
MAX_SWIFT_COMPILE_IMAGES = 256;
|
|
1992
1992
|
MAX_SWIFT_COMPILE_IMAGE_BYTES = 4 * 1024 * 1024;
|
|
1993
1993
|
MAX_SWIFT_COMPILE_IMAGE_TOTAL_BYTES = 16 * 1024 * 1024;
|
|
1994
|
-
SWIFT_HOST_ABI =
|
|
1994
|
+
SWIFT_HOST_ABI = 69;
|
|
1995
1995
|
POLL_INTERVAL_MS = 1500;
|
|
1996
1996
|
}
|
|
1997
1997
|
});
|
|
@@ -27181,6 +27181,76 @@ var init_swift_guest_compile = __esm({
|
|
|
27181
27181
|
}
|
|
27182
27182
|
});
|
|
27183
27183
|
|
|
27184
|
+
// ../peach-compat/src/stubs/wasm-memory.ts
|
|
27185
|
+
var init_wasm_memory = __esm({
|
|
27186
|
+
"../peach-compat/src/stubs/wasm-memory.ts"() {
|
|
27187
|
+
"use strict";
|
|
27188
|
+
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
27189
|
+
}
|
|
27190
|
+
});
|
|
27191
|
+
|
|
27192
|
+
// ../sootsim-swift/src/icuData.ts
|
|
27193
|
+
function swiftIcuLayout(head, blobBytes) {
|
|
27194
|
+
const view = new DataView(head.buffer, head.byteOffset, head.byteLength);
|
|
27195
|
+
const toc = view.getUint16(0, true);
|
|
27196
|
+
if (head[2] !== 218 || head[3] !== 39)
|
|
27197
|
+
throw new Error("swift icu data has no icu header");
|
|
27198
|
+
const count = view.getUint32(toc, true);
|
|
27199
|
+
const names = [];
|
|
27200
|
+
const offsets = new Uint32Array(count + 1);
|
|
27201
|
+
const decoder = new TextDecoder("latin1");
|
|
27202
|
+
for (let index = 0; index < count; index++) {
|
|
27203
|
+
const name3 = toc + view.getUint32(toc + 4 + index * 8, true);
|
|
27204
|
+
offsets[index] = toc + view.getUint32(toc + 8 + index * 8, true);
|
|
27205
|
+
names.push(decoder.decode(head.subarray(name3, head.indexOf(0, name3))));
|
|
27206
|
+
}
|
|
27207
|
+
offsets[count] = blobBytes;
|
|
27208
|
+
const packOf = new Uint32Array(count);
|
|
27209
|
+
const packs = [];
|
|
27210
|
+
for (let index = 0; index < count; index++) {
|
|
27211
|
+
const last = packs[packs.length - 1];
|
|
27212
|
+
if (last && offsets[index + 1] - last[0] <= PACK_BYTES) last[1] = offsets[index + 1];
|
|
27213
|
+
else packs.push([offsets[index], offsets[index + 1]]);
|
|
27214
|
+
packOf[index] = packs.length - 1;
|
|
27215
|
+
}
|
|
27216
|
+
return { headBytes: offsets[0], names, packOf, packs };
|
|
27217
|
+
}
|
|
27218
|
+
function swiftIcuPack(blob, deflate2) {
|
|
27219
|
+
const layout2 = swiftIcuLayout(blob, blob.byteLength);
|
|
27220
|
+
const parts = [
|
|
27221
|
+
deflate2(blob.subarray(0, layout2.headBytes)),
|
|
27222
|
+
...layout2.packs.map(([start, end]) => deflate2(blob.subarray(start, end)))
|
|
27223
|
+
];
|
|
27224
|
+
const index = new DataView(new ArrayBuffer(16 + parts.length * 4));
|
|
27225
|
+
index.setUint32(0, MAGIC, true);
|
|
27226
|
+
index.setUint32(4, VERSION, true);
|
|
27227
|
+
index.setUint32(8, blob.byteLength, true);
|
|
27228
|
+
index.setUint32(12, layout2.packs.length, true);
|
|
27229
|
+
parts.forEach((part, at2) => index.setUint32(16 + at2 * 4, part.byteLength, true));
|
|
27230
|
+
const packed = new Uint8Array(
|
|
27231
|
+
index.byteLength + parts.reduce((total, part) => total + part.byteLength, 0)
|
|
27232
|
+
);
|
|
27233
|
+
packed.set(new Uint8Array(index.buffer));
|
|
27234
|
+
let at = index.byteLength;
|
|
27235
|
+
for (const part of parts) {
|
|
27236
|
+
packed.set(part, at);
|
|
27237
|
+
at += part.byteLength;
|
|
27238
|
+
}
|
|
27239
|
+
return packed;
|
|
27240
|
+
}
|
|
27241
|
+
var PACK_BYTES, MAGIC, VERSION, SWIFT_ICU_PACKED;
|
|
27242
|
+
var init_icuData = __esm({
|
|
27243
|
+
"../sootsim-swift/src/icuData.ts"() {
|
|
27244
|
+
"use strict";
|
|
27245
|
+
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
27246
|
+
init_wasm_memory();
|
|
27247
|
+
PACK_BYTES = 64 * 1024;
|
|
27248
|
+
MAGIC = 1430473040;
|
|
27249
|
+
VERSION = 1;
|
|
27250
|
+
SWIFT_ICU_PACKED = `picu${VERSION}`;
|
|
27251
|
+
}
|
|
27252
|
+
});
|
|
27253
|
+
|
|
27184
27254
|
// src/swift-icu.ts
|
|
27185
27255
|
async function memo(cache, key2, load2) {
|
|
27186
27256
|
const cached2 = cache.get(key2);
|
|
@@ -27284,7 +27354,40 @@ function icuSegment(object6) {
|
|
|
27284
27354
|
throw new Error(`swift-icu: expected one icu data segment, found ${found.length}`);
|
|
27285
27355
|
return found[0];
|
|
27286
27356
|
}
|
|
27287
|
-
|
|
27357
|
+
function swiftIcuAddress(icu) {
|
|
27358
|
+
return `${icu.sha256}.${SWIFT_ICU_PACKED}`;
|
|
27359
|
+
}
|
|
27360
|
+
function swiftIcuPacked(icu) {
|
|
27361
|
+
return memo(packedFiles, icu.sha256, async () => {
|
|
27362
|
+
const file = import_node_path37.default.join(
|
|
27363
|
+
import_node_os8.default.homedir(),
|
|
27364
|
+
".peach",
|
|
27365
|
+
"cache",
|
|
27366
|
+
"swift-brotli",
|
|
27367
|
+
swiftIcuAddress(icu)
|
|
27368
|
+
);
|
|
27369
|
+
if ((0, import_node_fs39.existsSync)(file)) return (0, import_promises4.readFile)(file);
|
|
27370
|
+
const packed = Buffer.from(
|
|
27371
|
+
swiftIcuPack(
|
|
27372
|
+
await inflateGzip(icu.gzip),
|
|
27373
|
+
(bytes) => (0, import_node_zlib3.deflateRawSync)(bytes, { level: 9 })
|
|
27374
|
+
)
|
|
27375
|
+
);
|
|
27376
|
+
await (0, import_promises4.mkdir)(import_node_path37.default.dirname(file), { recursive: true });
|
|
27377
|
+
const tmp = `${file}.${(0, import_node_crypto18.randomUUID)()}.tmp`;
|
|
27378
|
+
await (0, import_promises4.writeFile)(tmp, packed);
|
|
27379
|
+
await (0, import_promises4.rename)(tmp, file);
|
|
27380
|
+
return packed;
|
|
27381
|
+
});
|
|
27382
|
+
}
|
|
27383
|
+
async function swiftIcuBundleAsset(icu) {
|
|
27384
|
+
return {
|
|
27385
|
+
path: `__peach/swift-icu/${swiftIcuAddress(icu)}`,
|
|
27386
|
+
bytes: await swiftIcuPacked(icu),
|
|
27387
|
+
contentType: "application/octet-stream"
|
|
27388
|
+
};
|
|
27389
|
+
}
|
|
27390
|
+
var import_node_child_process22, import_node_crypto18, import_node_fs39, import_promises4, import_node_os8, import_node_path37, import_node_util7, import_node_zlib3, run5, deflate, compressBrotli, inflateGzip, ARCHIVE, MEMBER, raw, assets, packedFiles;
|
|
27288
27391
|
var init_swift_icu = __esm({
|
|
27289
27392
|
"src/swift-icu.ts"() {
|
|
27290
27393
|
"use strict";
|
|
@@ -27292,9 +27395,12 @@ var init_swift_icu = __esm({
|
|
|
27292
27395
|
import_node_child_process22 = require("node:child_process");
|
|
27293
27396
|
import_node_crypto18 = require("node:crypto");
|
|
27294
27397
|
import_node_fs39 = require("node:fs");
|
|
27398
|
+
import_promises4 = require("node:fs/promises");
|
|
27399
|
+
import_node_os8 = __toESM(require("node:os"), 1);
|
|
27295
27400
|
import_node_path37 = __toESM(require("node:path"), 1);
|
|
27296
27401
|
import_node_util7 = require("node:util");
|
|
27297
27402
|
import_node_zlib3 = require("node:zlib");
|
|
27403
|
+
init_icuData();
|
|
27298
27404
|
init_swift_toolchain();
|
|
27299
27405
|
run5 = (0, import_node_util7.promisify)(import_node_child_process22.execFile);
|
|
27300
27406
|
deflate = (0, import_node_util7.promisify)(import_node_zlib3.gzip);
|
|
@@ -27304,6 +27410,7 @@ var init_swift_icu = __esm({
|
|
|
27304
27410
|
MEMBER = "icu_packaged_data.cpp.obj";
|
|
27305
27411
|
raw = /* @__PURE__ */ new Map();
|
|
27306
27412
|
assets = /* @__PURE__ */ new Map();
|
|
27413
|
+
packedFiles = /* @__PURE__ */ new Map();
|
|
27307
27414
|
}
|
|
27308
27415
|
});
|
|
27309
27416
|
|
|
@@ -27529,7 +27636,7 @@ var init_swift_project_user = __esm({
|
|
|
27529
27636
|
|
|
27530
27637
|
// src/swift-reproducible.ts
|
|
27531
27638
|
function swiftReproducibleBuildFlags(roots) {
|
|
27532
|
-
return [[
|
|
27639
|
+
return [[import_node_os9.default.homedir(), "home"], ...roots].flatMap(
|
|
27533
27640
|
([root, name3]) => [.../* @__PURE__ */ new Set([root, (0, import_node_fs42.realpathSync)(root)])].map((from) => `${from}=/peach/${name3}`)
|
|
27534
27641
|
).flatMap((map2) => [
|
|
27535
27642
|
"-Xswiftc",
|
|
@@ -27542,13 +27649,13 @@ function swiftReproducibleBuildFlags(roots) {
|
|
|
27542
27649
|
`-ffile-prefix-map=${map2}`
|
|
27543
27650
|
]);
|
|
27544
27651
|
}
|
|
27545
|
-
var import_node_fs42,
|
|
27652
|
+
var import_node_fs42, import_node_os9;
|
|
27546
27653
|
var init_swift_reproducible = __esm({
|
|
27547
27654
|
"src/swift-reproducible.ts"() {
|
|
27548
27655
|
"use strict";
|
|
27549
27656
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
27550
27657
|
import_node_fs42 = require("node:fs");
|
|
27551
|
-
|
|
27658
|
+
import_node_os9 = __toESM(require("node:os"), 1);
|
|
27552
27659
|
}
|
|
27553
27660
|
});
|
|
27554
27661
|
|
|
@@ -27625,7 +27732,7 @@ function groupAlive(table, leader) {
|
|
|
27625
27732
|
}
|
|
27626
27733
|
function withCocoaPodsCacheLock(work) {
|
|
27627
27734
|
return withSwiftRootLock(
|
|
27628
|
-
process.env.CP_CACHE_DIR || import_node_path40.default.join((0,
|
|
27735
|
+
process.env.CP_CACHE_DIR || import_node_path40.default.join((0, import_node_os10.homedir)(), "Library/Caches/CocoaPods"),
|
|
27629
27736
|
work
|
|
27630
27737
|
);
|
|
27631
27738
|
}
|
|
@@ -27730,7 +27837,7 @@ async function withSwiftRootLock(root, work, signal, wait = true) {
|
|
|
27730
27837
|
(0, import_node_fs43.writeFileSync)(import_node_path40.default.join(directory2, name2(held, "released")), "");
|
|
27731
27838
|
}
|
|
27732
27839
|
}
|
|
27733
|
-
var import_node_child_process24, import_node_crypto19, import_node_fs43,
|
|
27840
|
+
var import_node_child_process24, import_node_crypto19, import_node_fs43, import_node_os10, import_node_path40, POLL_MS, START_TOLERANCE_MS, name2;
|
|
27734
27841
|
var init_swift_root_lock = __esm({
|
|
27735
27842
|
"src/swift-root-lock.ts"() {
|
|
27736
27843
|
"use strict";
|
|
@@ -27738,7 +27845,7 @@ var init_swift_root_lock = __esm({
|
|
|
27738
27845
|
import_node_child_process24 = require("node:child_process");
|
|
27739
27846
|
import_node_crypto19 = require("node:crypto");
|
|
27740
27847
|
import_node_fs43 = require("node:fs");
|
|
27741
|
-
|
|
27848
|
+
import_node_os10 = require("node:os");
|
|
27742
27849
|
import_node_path40 = __toESM(require("node:path"), 1);
|
|
27743
27850
|
init_home_paths();
|
|
27744
27851
|
init_process_group();
|
|
@@ -32241,7 +32348,7 @@ function compileSwiftProjectOnce(input, options) {
|
|
|
32241
32348
|
options.signal
|
|
32242
32349
|
);
|
|
32243
32350
|
}
|
|
32244
|
-
var import_node_child_process26, import_node_crypto20, import_node_fs46,
|
|
32351
|
+
var import_node_child_process26, import_node_crypto20, import_node_fs46, import_node_os11, import_node_path44, WASM_TRIPLE, SWIFTPM_PROGRESS, SWIFTPM_NOISE, admittedCores, SWIFT_BUILD_JOBS, BUILD_JOBS, SWIFT_BUILDER_TRANSPORT_MARGIN_MS, SWIFT_BUILDER_DEFAULT_COMPILE_MS, clangInterfaceHeader, swiftInterfaceDeclarations, linkedModuleDigests, SYSTEM_MODULE_LIBRARIES, SYSTEM_MODULE_IMPORT, OPTIONAL_FRAMEWORK_DEPENDENCIES, OPTIONAL_FRAMEWORKS, SWIFT_IMPORT, kleeneNot, kleeneAnd, kleeneOr, sdkPaths, availableModules, sdkOverlayFrameworks, ONE_PRODUCT, SPRITEKIT_PRODUCT, importsSpriteKit, FOUNDATION_IMPLICIT_MODULES, FOUNDATION_IMPLICIT_FLAGS, ONE_IMPLICIT_FLAGS, executableLinkFlags, darwinRecordsRegion, REACTOR_FLAG, MULTI_MANIFEST_VERSION, SWIFT_HEADER_PRODUCTS_TARGET, compilerSourceDigest, nativeCxxCompilerFlags, cFlagArray, cxxFlagArray, DIRECTIVE, OS_IOS, DELEGATE_CLASS, REUSABLE_INIT, REUSABLE_VIEW_BASES, CLASS_BASE, FRAME_INIT, FOUNDATION_NETWORKING_TYPES, FOUNDATION_OVERLAY_TYPES, FOUNDATION_OVERLAY_GLOBALS, CORE_FOUNDATION_OVERLAY_GLOBALS, CORE_FOUNDATION_GEOMETRY_TYPES, CORE_FOUNDATION_GRAPHICS_TYPES, CORE_FOUNDATION_HANDLE_IMPORTS, emptyMacroEnvironment, HIDDEN_UNITS, LIBXML_REFERENCE, LIBXML_SOURCE, ROOT_LOCKS, host, rootLocks, SHARED_ARTIFACT_BUDGET_BYTES, SHARED_ARTIFACT_GRACE_MS, RETIRED_PREFIX, retainedArtifacts, FRAMEWORK_LINK_TARGET, SWIFT_LINK_STAMP, SWIFT_FRAMEWORK_SLOTS, SWIFT_FRAMEWORK_SLOT_KEY;
|
|
32245
32352
|
var init_swift_compile = __esm({
|
|
32246
32353
|
"src/swift-compile.ts"() {
|
|
32247
32354
|
"use strict";
|
|
@@ -32249,7 +32356,7 @@ var init_swift_compile = __esm({
|
|
|
32249
32356
|
import_node_child_process26 = require("node:child_process");
|
|
32250
32357
|
import_node_crypto20 = require("node:crypto");
|
|
32251
32358
|
import_node_fs46 = require("node:fs");
|
|
32252
|
-
|
|
32359
|
+
import_node_os11 = __toESM(require("node:os"), 1);
|
|
32253
32360
|
import_node_path44 = __toESM(require("node:path"), 1);
|
|
32254
32361
|
init_admitted_mac_build();
|
|
32255
32362
|
init_process_group();
|
|
@@ -32283,7 +32390,7 @@ var init_swift_compile = __esm({
|
|
|
32283
32390
|
admittedCores = Number(process.env.TM_EXEC_CPU_CORES);
|
|
32284
32391
|
SWIFT_BUILD_JOBS = Math.min(
|
|
32285
32392
|
4,
|
|
32286
|
-
Math.max(1, Math.floor(
|
|
32393
|
+
Math.max(1, Math.floor(import_node_os11.default.availableParallelism() / 2)),
|
|
32287
32394
|
Number.isInteger(admittedCores) && admittedCores > 0 ? admittedCores : 4
|
|
32288
32395
|
);
|
|
32289
32396
|
BUILD_JOBS = String(SWIFT_BUILD_JOBS);
|
|
@@ -32403,12 +32510,14 @@ var init_swift_compile = __esm({
|
|
|
32403
32510
|
"-Xlinker", "-lsetjmp",
|
|
32404
32511
|
"-Xlinker", "--export-table",
|
|
32405
32512
|
"-Xlinker", "--growable-table",
|
|
32513
|
+
"-Xlinker", "--wrap=swift_udata_open",
|
|
32514
|
+
"-Xlinker", "--wrap=swift_udata_openChoice",
|
|
32406
32515
|
`;
|
|
32407
32516
|
darwinRecordsRegion = (quoted) => quoted.length ? ["-Wl,--start-lib", ...quoted, "-Wl,--end-lib"] : [];
|
|
32408
32517
|
REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
|
|
32409
32518
|
MULTI_MANIFEST_VERSION = 66;
|
|
32410
32519
|
SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
|
|
32411
|
-
compilerSourceDigest = true ? "
|
|
32520
|
+
compilerSourceDigest = true ? "d46232537a993bc7418818ab7d2dc159518328882280b8b4bfd459cffd910921" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
|
|
32412
32521
|
nativeCxxCompilerFlags = ["-fno-cxx-modules"];
|
|
32413
32522
|
cFlagArray = (flags) => JSON.stringify(withoutGlogModuleMap(flags));
|
|
32414
32523
|
cxxFlagArray = (flags) => JSON.stringify([...nativeCxxCompilerFlags, ...withoutGlogModuleMap(flags)]);
|
|
@@ -33530,7 +33639,7 @@ async function swiftDistributionRoot(signal) {
|
|
|
33530
33639
|
async function installSwiftToolchain(release, sdk, signal, compilerOnly = false) {
|
|
33531
33640
|
process.env.PEACH_SWIFT_SDKS_PATH ??= import_node_path46.default.join(rnxHomeDir(), "swift", "sdks");
|
|
33532
33641
|
const root = import_node_path46.default.resolve(swiftToolchainBin(release), "../..");
|
|
33533
|
-
const owned = process.platform === "darwin" ? import_node_path46.default.join(
|
|
33642
|
+
const owned = process.platform === "darwin" ? import_node_path46.default.join(import_node_os12.default.homedir(), "Library/Developer/Toolchains", `${release}.xctoolchain`) : import_node_path46.default.join(rnxHomeDir(), "swift", "toolchains", release);
|
|
33534
33643
|
const selectedCompiler = process.platform === "darwin" && import_node_fs48.default.existsSync(import_node_path46.default.join(root, "usr/bin/swift"));
|
|
33535
33644
|
if (release.includes("-custom-") && root === owned && !selectedCompiler && !swiftCompilerReady(release)) {
|
|
33536
33645
|
const archive = swiftHostCompilerArchive(release);
|
|
@@ -33633,13 +33742,13 @@ function swiftModuleToolchain(root) {
|
|
|
33633
33742
|
const { release } = swiftModuleCompiler(root);
|
|
33634
33743
|
return { release, toolchainBin: swiftToolchain(release, swiftModuleSdk(root)) };
|
|
33635
33744
|
}
|
|
33636
|
-
var import_node_fs48,
|
|
33745
|
+
var import_node_fs48, import_node_os12, import_node_path46, SWIFT_ENDPOINT_ENV, DEFAULT_SWIFT_ENDPOINT, installs, staleWarned;
|
|
33637
33746
|
var init_swift_distribution = __esm({
|
|
33638
33747
|
"src/swift-distribution.ts"() {
|
|
33639
33748
|
"use strict";
|
|
33640
33749
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
33641
33750
|
import_node_fs48 = __toESM(require("node:fs"), 1);
|
|
33642
|
-
|
|
33751
|
+
import_node_os12 = __toESM(require("node:os"), 1);
|
|
33643
33752
|
import_node_path46 = __toESM(require("node:path"), 1);
|
|
33644
33753
|
init_src();
|
|
33645
33754
|
init_linux_browser_libs();
|
|
@@ -34128,7 +34237,7 @@ let package = Package(
|
|
|
34128
34237
|
]
|
|
34129
34238
|
)
|
|
34130
34239
|
`;
|
|
34131
|
-
const dir = import_node_fs49.default.mkdtempSync(import_node_path47.default.join(
|
|
34240
|
+
const dir = import_node_fs49.default.mkdtempSync(import_node_path47.default.join(import_node_os13.default.tmpdir(), "peach-resolve-"));
|
|
34132
34241
|
import_node_fs49.default.writeFileSync(import_node_path47.default.join(dir, "Package.swift"), manifest);
|
|
34133
34242
|
const args = [
|
|
34134
34243
|
"package",
|
|
@@ -34209,7 +34318,7 @@ function swiftTargetFiles(manifest, target) {
|
|
|
34209
34318
|
}
|
|
34210
34319
|
return [...new Set(files2)].sort();
|
|
34211
34320
|
}
|
|
34212
|
-
var import_node_child_process27, import_node_crypto22, import_node_fs49,
|
|
34321
|
+
var import_node_child_process27, import_node_crypto22, import_node_fs49, import_node_os13, import_node_path47, import_node_util8, TARGET_TYPES, isTargetType, record, array3, string4, cacheDir3, evaluated, execFileAsync, cachedToolchain, SwiftManifestPreparationRequired, manifestPreparations, GUEST_PLATFORMS, within, requirementClause;
|
|
34213
34322
|
var init_swift_package_manifest = __esm({
|
|
34214
34323
|
"src/swift-package-manifest.ts"() {
|
|
34215
34324
|
"use strict";
|
|
@@ -34217,7 +34326,7 @@ var init_swift_package_manifest = __esm({
|
|
|
34217
34326
|
import_node_child_process27 = require("node:child_process");
|
|
34218
34327
|
import_node_crypto22 = require("node:crypto");
|
|
34219
34328
|
import_node_fs49 = __toESM(require("node:fs"), 1);
|
|
34220
|
-
|
|
34329
|
+
import_node_os13 = __toESM(require("node:os"), 1);
|
|
34221
34330
|
import_node_path47 = __toESM(require("node:path"), 1);
|
|
34222
34331
|
import_node_util8 = require("node:util");
|
|
34223
34332
|
init_home_paths();
|
|
@@ -36815,14 +36924,14 @@ async function readExpoConfigAsync(projectRoot) {
|
|
|
36815
36924
|
import_node_fs51.default.rmSync(directory2, { recursive: true, force: true });
|
|
36816
36925
|
}
|
|
36817
36926
|
}
|
|
36818
|
-
var import_node_child_process29, import_node_fs51,
|
|
36927
|
+
var import_node_child_process29, import_node_fs51, import_node_os14, import_node_path50, EXPO_CONFIG_SCRIPT, resultDirectory;
|
|
36819
36928
|
var init_native_firebase_config = __esm({
|
|
36820
36929
|
"src/native-firebase-config.ts"() {
|
|
36821
36930
|
"use strict";
|
|
36822
36931
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
36823
36932
|
import_node_child_process29 = require("node:child_process");
|
|
36824
36933
|
import_node_fs51 = __toESM(require("node:fs"), 1);
|
|
36825
|
-
|
|
36934
|
+
import_node_os14 = __toESM(require("node:os"), 1);
|
|
36826
36935
|
import_node_path50 = __toESM(require("node:path"), 1);
|
|
36827
36936
|
init_is_record();
|
|
36828
36937
|
init_plist();
|
|
@@ -36843,7 +36952,7 @@ if (expoEnv) {
|
|
|
36843
36952
|
const result = JSON.stringify(getConfig(root, { skipSDKVersionRequirement: true }).exp);
|
|
36844
36953
|
if (Buffer.byteLength(result) > 1024 * 1024) throw new Error('Expo native configuration exceeds 1 MiB.');
|
|
36845
36954
|
writeFileSync(process.argv[2], result, { mode: 0o600 });`;
|
|
36846
|
-
resultDirectory = () => import_node_fs51.default.mkdtempSync(import_node_path50.default.join(
|
|
36955
|
+
resultDirectory = () => import_node_fs51.default.mkdtempSync(import_node_path50.default.join(import_node_os14.default.tmpdir(), "peach-expo-config-"));
|
|
36847
36956
|
}
|
|
36848
36957
|
});
|
|
36849
36958
|
|
|
@@ -36920,7 +37029,7 @@ async function preparedNativeInventory(app, selected, signal) {
|
|
|
36920
37029
|
}
|
|
36921
37030
|
const result = [];
|
|
36922
37031
|
for (const [name3, root] of [...roots].sort(([a], [b]) => a.localeCompare(b))) {
|
|
36923
|
-
await (0,
|
|
37032
|
+
await (0, import_promises5.setImmediate)(void 0, { signal });
|
|
36924
37033
|
const hash = (0, import_node_crypto25.createHash)("sha256");
|
|
36925
37034
|
const canonicalRoot = import_node_fs53.default.realpathSync(root);
|
|
36926
37035
|
const walk3 = (directory2, relative4) => {
|
|
@@ -36952,7 +37061,7 @@ async function preparedNativeInventory(app, selected, signal) {
|
|
|
36952
37061
|
}
|
|
36953
37062
|
return result;
|
|
36954
37063
|
}
|
|
36955
|
-
var import_node_child_process30, import_node_crypto25, import_node_fs53, import_node_module3, import_node_path52,
|
|
37064
|
+
var import_node_child_process30, import_node_crypto25, import_node_fs53, import_node_module3, import_node_path52, import_promises5, import_node_util9;
|
|
36956
37065
|
var init_prepared_native_inventory = __esm({
|
|
36957
37066
|
"src/prepared-native-inventory.ts"() {
|
|
36958
37067
|
"use strict";
|
|
@@ -36962,7 +37071,7 @@ var init_prepared_native_inventory = __esm({
|
|
|
36962
37071
|
import_node_fs53 = __toESM(require("node:fs"), 1);
|
|
36963
37072
|
import_node_module3 = require("node:module");
|
|
36964
37073
|
import_node_path52 = __toESM(require("node:path"), 1);
|
|
36965
|
-
|
|
37074
|
+
import_promises5 = require("node:timers/promises");
|
|
36966
37075
|
import_node_util9 = require("node:util");
|
|
36967
37076
|
init_expo_autolinking();
|
|
36968
37077
|
init_is_record();
|
|
@@ -37709,7 +37818,7 @@ async function expoDiscoveryKey(options) {
|
|
|
37709
37818
|
return { key: key2, root };
|
|
37710
37819
|
}
|
|
37711
37820
|
function sharedDir() {
|
|
37712
|
-
return import_node_path56.default.join((0,
|
|
37821
|
+
return import_node_path56.default.join((0, import_node_os15.homedir)(), ".peach", "cache", "expo-discovery");
|
|
37713
37822
|
}
|
|
37714
37823
|
function isExpoSwiftSourceUnit(value) {
|
|
37715
37824
|
return isRecord(value) && typeof value.namespace === "string" && typeof value.moduleId === "string" && (value.nativeAppIdentity === void 0 || isNativeAppIdentity(value.nativeAppIdentity)) && strings2(value.classes) && strings2(value.bridgeModules) && strings2(value.appDelegateSubscribers) && strings2(value.reactDelegateHandlers) && stringRecord(value.files) && strings2(value.frameworks) && (value.nativeTargets === void 0 || Array.isArray(value.nativeTargets) && value.nativeTargets.every(isRecord)) && (value.nativeFiles === void 0 || stringRecord(value.nativeFiles)) && (value.resources === void 0 || stringRecord(value.resources)) && (value.resourceBundles === void 0 || isSwiftResourceBundles(value.resourceBundles)) && (value.swiftLanguageMode === void 0 || typeof value.swiftLanguageMode === "number");
|
|
@@ -38031,14 +38140,14 @@ function writeExpoDiscovery(options) {
|
|
|
38031
38140
|
return error instanceof Error ? error.message : String(error);
|
|
38032
38141
|
}
|
|
38033
38142
|
}
|
|
38034
|
-
var import_node_crypto28, import_node_fs57,
|
|
38143
|
+
var import_node_crypto28, import_node_fs57, import_node_os15, import_node_path56, import_node_url3, FORMAT, PIPELINE_FILES, strings2, stringRecord, isDigest, digestRecord, sourceLocationLine, MISSING_TREE;
|
|
38035
38144
|
var init_expo_discovery_cache = __esm({
|
|
38036
38145
|
"src/expo-discovery-cache.ts"() {
|
|
38037
38146
|
"use strict";
|
|
38038
38147
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
38039
38148
|
import_node_crypto28 = require("node:crypto");
|
|
38040
38149
|
import_node_fs57 = __toESM(require("node:fs"), 1);
|
|
38041
|
-
|
|
38150
|
+
import_node_os15 = require("node:os");
|
|
38042
38151
|
import_node_path56 = __toESM(require("node:path"), 1);
|
|
38043
38152
|
import_node_url3 = require("node:url");
|
|
38044
38153
|
init_expo_eager_seam_contract();
|
|
@@ -38134,7 +38243,7 @@ var init_swift_standin_digest = __esm({
|
|
|
38134
38243
|
STANDIN_DIGEST_ENTRYPOINTS = ["swift-standins.ts", "swift-objc-compile.ts"];
|
|
38135
38244
|
SPECIFIER = /from\s*['"]([^'"]+)['"]|import\s*\(\s*['"]([^'"]+)['"]\s*\)/g;
|
|
38136
38245
|
standinSourceDigest = (srcDir = __sootsim_import_meta_dirname) => sourceClosureDigest(srcDir, STANDIN_DIGEST_ENTRYPOINTS);
|
|
38137
|
-
STANDIN_SOURCE_DIGEST = true ? "
|
|
38246
|
+
STANDIN_SOURCE_DIGEST = true ? "2340b1684e4aa046dace7fdc861bb6a39fde0a6ee06003187e6af39416313d98" : standinSourceDigest();
|
|
38138
38247
|
}
|
|
38139
38248
|
});
|
|
38140
38249
|
|
|
@@ -38402,19 +38511,19 @@ async function packageTreeDigest(root) {
|
|
|
38402
38511
|
const hash = (0, import_node_crypto31.createHash)("sha256");
|
|
38403
38512
|
for (let start = 0; start < files2.length; start += READ_AHEAD) {
|
|
38404
38513
|
const batch = files2.slice(start, start + READ_AHEAD);
|
|
38405
|
-
const bytes = await Promise.all(batch.map((file) => (0,
|
|
38514
|
+
const bytes = await Promise.all(batch.map((file) => (0, import_promises6.readFile)((0, import_node_path60.join)(root, file))));
|
|
38406
38515
|
batch.forEach((file, index) => hash.update(`${file}\0`).update(bytes[index]));
|
|
38407
38516
|
}
|
|
38408
38517
|
return hash.digest("hex");
|
|
38409
38518
|
}
|
|
38410
|
-
var import_node_crypto31, import_node_fs61,
|
|
38519
|
+
var import_node_crypto31, import_node_fs61, import_promises6, import_node_path60, READ_AHEAD;
|
|
38411
38520
|
var init_package_tree_digest = __esm({
|
|
38412
38521
|
"src/package-tree-digest.ts"() {
|
|
38413
38522
|
"use strict";
|
|
38414
38523
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
38415
38524
|
import_node_crypto31 = require("node:crypto");
|
|
38416
38525
|
import_node_fs61 = require("node:fs");
|
|
38417
|
-
|
|
38526
|
+
import_promises6 = require("node:fs/promises");
|
|
38418
38527
|
import_node_path60 = require("node:path");
|
|
38419
38528
|
READ_AHEAD = 64;
|
|
38420
38529
|
}
|
|
@@ -38624,7 +38733,7 @@ var init_expo_native_prebuilt = __esm({
|
|
|
38624
38733
|
init_swift_native_pin();
|
|
38625
38734
|
init_xcode_project();
|
|
38626
38735
|
EXPO_NATIVE_ENTRY_NAME = "ios";
|
|
38627
|
-
EXPO_NATIVE_COMPILER_DIGEST = true ? "
|
|
38736
|
+
EXPO_NATIVE_COMPILER_DIGEST = true ? "4585315f71394b53ace3ffe5eaedd20a11f727ce4eaa50a1cbc934b5c7f189d1" : expoNativeCompilerDigest(__sootsim_import_meta_dirname);
|
|
38628
38737
|
IDENTITY_SOURCE_SKIPS = 1 | 4 | 8 | 16 | 32 | 64 | 128 | 4096;
|
|
38629
38738
|
expoNativeEntryUrl = (key2, file) => `${NATIVE_PREBUILT_ORIGIN}/${nativeEntryPrefix("expo", EXPO_NATIVE_ENTRY_NAME, key2)}/${file}`;
|
|
38630
38739
|
isStringRecord = (value) => isRecord(value) && Object.values(value).every((item) => typeof item === "string");
|
|
@@ -39170,7 +39279,7 @@ async function fetchCheckout(checkouts, identity2, pin2, signal) {
|
|
|
39170
39279
|
const lock = async () => {
|
|
39171
39280
|
let release = tryAcquireNumberedLock(`${dir}.lock`);
|
|
39172
39281
|
while (!release) {
|
|
39173
|
-
await (0,
|
|
39282
|
+
await (0, import_promises7.setTimeout)(25, void 0, { signal });
|
|
39174
39283
|
release = tryAcquireNumberedLock(`${dir}.lock`);
|
|
39175
39284
|
}
|
|
39176
39285
|
return release;
|
|
@@ -39742,7 +39851,7 @@ function resolveSwiftPackages(options) {
|
|
|
39742
39851
|
result.nativeProducts.push({ name: name3, packageDir: manifest.dir, source });
|
|
39743
39852
|
return result;
|
|
39744
39853
|
}
|
|
39745
|
-
var import_node_child_process34, import_node_crypto35, import_node_fs66, import_node_path65,
|
|
39854
|
+
var import_node_child_process34, import_node_crypto35, import_node_fs66, import_node_path65, import_promises7, import_node_util12, SWIFT_PLACEHOLDER_PACKAGES, placeholderPackage, UNSUPPORTED_NATIVE, BINARY, blockers, verified, execFileAsync2, checkoutKey;
|
|
39746
39855
|
var init_swift_packages = __esm({
|
|
39747
39856
|
"src/swift-packages.ts"() {
|
|
39748
39857
|
"use strict";
|
|
@@ -39751,7 +39860,7 @@ var init_swift_packages = __esm({
|
|
|
39751
39860
|
import_node_crypto35 = require("node:crypto");
|
|
39752
39861
|
import_node_fs66 = __toESM(require("node:fs"), 1);
|
|
39753
39862
|
import_node_path65 = __toESM(require("node:path"), 1);
|
|
39754
|
-
|
|
39863
|
+
import_promises7 = require("node:timers/promises");
|
|
39755
39864
|
import_node_util12 = require("node:util");
|
|
39756
39865
|
init_home_paths();
|
|
39757
39866
|
init_numbered_lock();
|
|
@@ -39845,7 +39954,7 @@ async function cxxDeclarations(astFile, headers) {
|
|
|
39845
39954
|
const result = [];
|
|
39846
39955
|
let lastFile = "";
|
|
39847
39956
|
let rootComplete = false;
|
|
39848
|
-
await (0,
|
|
39957
|
+
await (0, import_promises8.pipeline)(import_node_fs68.default.createReadStream(astFile), (0, import_stream_json.default)(), async (tokens2) => {
|
|
39849
39958
|
for await (const value of tokens2) {
|
|
39850
39959
|
if (!value || typeof value !== "object" || !("name" in value) || typeof value.name !== "string")
|
|
39851
39960
|
throw new Error("invalid clang AST token");
|
|
@@ -39939,14 +40048,14 @@ async function cxxDeclarations(astFile, headers) {
|
|
|
39939
40048
|
if (stack.length !== 0 || !rootComplete) throw new Error("truncated clang AST");
|
|
39940
40049
|
return result;
|
|
39941
40050
|
}
|
|
39942
|
-
var import_node_fs68, import_node_path66,
|
|
40051
|
+
var import_node_fs68, import_node_path66, import_promises8, import_stream_json, DECLARATIONS;
|
|
39943
40052
|
var init_swift_cxx_declarations = __esm({
|
|
39944
40053
|
"src/swift-cxx-declarations.ts"() {
|
|
39945
40054
|
"use strict";
|
|
39946
40055
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
39947
40056
|
import_node_fs68 = __toESM(require("node:fs"), 1);
|
|
39948
40057
|
import_node_path66 = __toESM(require("node:path"), 1);
|
|
39949
|
-
|
|
40058
|
+
import_promises8 = require("node:stream/promises");
|
|
39950
40059
|
import_stream_json = __toESM(require("stream-json"), 1);
|
|
39951
40060
|
DECLARATIONS = /* @__PURE__ */ new Set([
|
|
39952
40061
|
"FunctionDecl",
|
|
@@ -46276,7 +46385,7 @@ function rasterBinary() {
|
|
|
46276
46385
|
try {
|
|
46277
46386
|
import_node_fs75.default.mkdirSync(cacheDir(), { recursive: true });
|
|
46278
46387
|
const source = import_node_path73.default.join(
|
|
46279
|
-
import_node_fs75.default.mkdtempSync(import_node_path73.default.join(
|
|
46388
|
+
import_node_fs75.default.mkdtempSync(import_node_path73.default.join(import_node_os16.default.tmpdir(), "swift-pdf-raster-")),
|
|
46280
46389
|
"raster.swift"
|
|
46281
46390
|
);
|
|
46282
46391
|
import_node_fs75.default.writeFileSync(source, RASTER_SWIFT);
|
|
@@ -46301,7 +46410,7 @@ function rasterizePdfFile(diskPath, pdfSha256) {
|
|
|
46301
46410
|
} catch {
|
|
46302
46411
|
}
|
|
46303
46412
|
const out = import_node_path73.default.join(
|
|
46304
|
-
import_node_fs75.default.mkdtempSync(import_node_path73.default.join(
|
|
46413
|
+
import_node_fs75.default.mkdtempSync(import_node_path73.default.join(import_node_os16.default.tmpdir(), "swift-pdf-png-")),
|
|
46305
46414
|
"out.png"
|
|
46306
46415
|
);
|
|
46307
46416
|
try {
|
|
@@ -46337,7 +46446,7 @@ function rasterizePdfFile(diskPath, pdfSha256) {
|
|
|
46337
46446
|
import_node_fs75.default.rmSync(import_node_path73.default.dirname(out), { recursive: true, force: true });
|
|
46338
46447
|
}
|
|
46339
46448
|
}
|
|
46340
|
-
var import_node_child_process39, import_node_crypto39, import_node_fs75,
|
|
46449
|
+
var import_node_child_process39, import_node_crypto39, import_node_fs75, import_node_os16, import_node_path73, RASTER_SWIFT;
|
|
46341
46450
|
var init_swift_pdf_raster = __esm({
|
|
46342
46451
|
"src/swift-pdf-raster.ts"() {
|
|
46343
46452
|
"use strict";
|
|
@@ -46345,7 +46454,7 @@ var init_swift_pdf_raster = __esm({
|
|
|
46345
46454
|
import_node_child_process39 = require("node:child_process");
|
|
46346
46455
|
import_node_crypto39 = require("node:crypto");
|
|
46347
46456
|
import_node_fs75 = __toESM(require("node:fs"), 1);
|
|
46348
|
-
|
|
46457
|
+
import_node_os16 = __toESM(require("node:os"), 1);
|
|
46349
46458
|
import_node_path73 = __toESM(require("node:path"), 1);
|
|
46350
46459
|
init_internal_child_contract();
|
|
46351
46460
|
init_self_invocation();
|
|
@@ -47615,7 +47724,7 @@ function buildSwiftBundleFiles(packagePath, hosted, inputs, resourceBundles) {
|
|
|
47615
47724
|
}
|
|
47616
47725
|
}
|
|
47617
47726
|
if (xcode?.app.postBundleScripts.length) {
|
|
47618
|
-
const dir = import_node_fs76.default.mkdtempSync(import_node_path74.default.join(
|
|
47727
|
+
const dir = import_node_fs76.default.mkdtempSync(import_node_path74.default.join(import_node_os17.default.tmpdir(), "peach-xcode-bundle-"));
|
|
47619
47728
|
const wrapper = import_node_path74.default.basename(xcode.app.settings("UNLOCALIZED_RESOURCES_FOLDER_PATH")) || `${xcode.app.name}.app`;
|
|
47620
47729
|
const bundle = import_node_path74.default.join(dir, wrapper);
|
|
47621
47730
|
try {
|
|
@@ -47759,7 +47868,7 @@ function otherInputs(input) {
|
|
|
47759
47868
|
return (0, import_node_crypto40.createHash)("sha256").update(JSON.stringify(rest)).digest("hex");
|
|
47760
47869
|
}
|
|
47761
47870
|
function icuUrl(origin, artifact) {
|
|
47762
|
-
return "url" in artifact.icu ? artifact.icu.url : `${origin}${ICU_PATH}${artifact.icu
|
|
47871
|
+
return "url" in artifact.icu ? artifact.icu.url : `${origin}${ICU_PATH}${swiftIcuAddress(artifact.icu)}`;
|
|
47763
47872
|
}
|
|
47764
47873
|
function standinLibraries(binaries, standins, rootDir, toolchain) {
|
|
47765
47874
|
const linked = /* @__PURE__ */ new Map();
|
|
@@ -48307,7 +48416,7 @@ function scopedArtifact(project2, entry, moduleRoot, signal) {
|
|
|
48307
48416
|
project2.building = { stamp, promise: fresh, signal };
|
|
48308
48417
|
return fresh;
|
|
48309
48418
|
}
|
|
48310
|
-
var import_node_async_hooks, import_node_child_process40, import_node_crypto40, import_node_fs76,
|
|
48419
|
+
var import_node_async_hooks, import_node_child_process40, import_node_crypto40, import_node_fs76, import_node_os17, import_node_path74, RESOURCE_PATH, ICU_PATH, SKIP_ROOT_DIRS, NATIVE_DESCRIPTOR, NATIVE_GLUE, SwiftMissingModulesError, sharedProjects, projectScope, projects, sharedSourceEntries, sourceEntries, sharedXcodeProjects, xcodeProjects, preparedScriptInputs, XCODE_APP_DIR, XCODE_FRAMEWORKS_DIR, XCODE_PACKAGES_DIR, layoutScope, HOSTED_LIMITS, LOCAL_LIMITS, inputLimits, RESOURCE_CONTENT_TYPES, API_GAP_PATTERNS, IOS_SDK_FRAMEWORKS;
|
|
48311
48420
|
var init_swift_host = __esm({
|
|
48312
48421
|
"src/swift-host.ts"() {
|
|
48313
48422
|
"use strict";
|
|
@@ -48316,7 +48425,7 @@ var init_swift_host = __esm({
|
|
|
48316
48425
|
import_node_child_process40 = require("node:child_process");
|
|
48317
48426
|
import_node_crypto40 = require("node:crypto");
|
|
48318
48427
|
import_node_fs76 = __toESM(require("node:fs"), 1);
|
|
48319
|
-
|
|
48428
|
+
import_node_os17 = __toESM(require("node:os"), 1);
|
|
48320
48429
|
import_node_path74 = __toESM(require("node:path"), 1);
|
|
48321
48430
|
init_bundleAssets();
|
|
48322
48431
|
init_stringCatalog();
|
|
@@ -49694,6 +49803,24 @@ var init_podspec_sources = __esm({
|
|
|
49694
49803
|
helper,
|
|
49695
49804
|
node.args.map((arg) => this.ev(scope2, arg))
|
|
49696
49805
|
);
|
|
49806
|
+
if (node.name === "get_folly_config") {
|
|
49807
|
+
let root = import_node_path76.default.dirname(this.current);
|
|
49808
|
+
while (!import_node_fs78.default.existsSync(import_node_path76.default.join(root, "scripts/cocoapods/helpers.rb"))) {
|
|
49809
|
+
if (root === import_node_path76.default.dirname(root)) return this.fail("call to get_folly_config");
|
|
49810
|
+
root = import_node_path76.default.dirname(root);
|
|
49811
|
+
}
|
|
49812
|
+
const helpers = import_node_fs78.default.readFileSync(
|
|
49813
|
+
import_node_path76.default.join(root, "scripts/cocoapods/helpers.rb"),
|
|
49814
|
+
"utf8"
|
|
49815
|
+
);
|
|
49816
|
+
const version2 = /:version\s*=>\s*'([^']*)'/.exec(helpers)?.[1];
|
|
49817
|
+
const flags = /:compiler_flags\s*=>\s*'([^']*)'/.exec(helpers)?.[1];
|
|
49818
|
+
if (!version2 || !flags) return this.fail("get_folly_config");
|
|
49819
|
+
return /* @__PURE__ */ new Map([
|
|
49820
|
+
["version", version2],
|
|
49821
|
+
["compiler_flags", flags]
|
|
49822
|
+
]);
|
|
49823
|
+
}
|
|
49697
49824
|
return this.fail(`call to ${node.name}`);
|
|
49698
49825
|
}
|
|
49699
49826
|
case "bin": {
|
|
@@ -50323,7 +50450,13 @@ function installedFabricSources(reactNativeRoot, { legacyBridge = false, bridgeO
|
|
|
50323
50450
|
import_node_path77.default.basename(file, ".podspec")
|
|
50324
50451
|
)
|
|
50325
50452
|
);
|
|
50326
|
-
|
|
50453
|
+
const expected = [...bridgeOnly ? LEGACY_BRIDGE_PODS : RENDERER_PODS].filter(
|
|
50454
|
+
(name3) => !RENDERER_PODS_VERSIONED.has(name3)
|
|
50455
|
+
);
|
|
50456
|
+
const present = required.filter(
|
|
50457
|
+
(file) => !RENDERER_PODS_VERSIONED.has(import_node_path77.default.basename(file, ".podspec"))
|
|
50458
|
+
);
|
|
50459
|
+
if (present.length !== expected.length)
|
|
50327
50460
|
throw new Error(`${reactNativeRoot}: installed renderer podspecs are incomplete`);
|
|
50328
50461
|
return specs.map((file) => {
|
|
50329
50462
|
const directory2 = import_node_path77.default.dirname(file);
|
|
@@ -50424,7 +50557,6 @@ var init_turbo_codegen_intake = __esm({
|
|
|
50424
50557
|
"React-FabricComponents",
|
|
50425
50558
|
"React-FabricImage",
|
|
50426
50559
|
"React-RCTFabric",
|
|
50427
|
-
"React-RCTFBReactNativeSpec",
|
|
50428
50560
|
"React-graphics",
|
|
50429
50561
|
"React-rendererdebug",
|
|
50430
50562
|
"React-utils",
|
|
@@ -50437,13 +50569,15 @@ var init_turbo_codegen_intake = __esm({
|
|
|
50437
50569
|
"React-runtimescheduler",
|
|
50438
50570
|
"React-ImageManager",
|
|
50439
50571
|
"React-performancetimeline",
|
|
50440
|
-
"React-jsinspectortracing",
|
|
50441
50572
|
"React-jsinspector",
|
|
50442
50573
|
"React-cxxreact",
|
|
50443
50574
|
"React-jserrorhandler",
|
|
50444
50575
|
"Yoga"
|
|
50445
50576
|
]);
|
|
50446
50577
|
RENDERER_PODS_VERSIONED = /* @__PURE__ */ new Set([
|
|
50578
|
+
// added after react-native 0.75
|
|
50579
|
+
"React-RCTFBReactNativeSpec",
|
|
50580
|
+
"React-jsinspectortracing",
|
|
50447
50581
|
// missing in 0.78, present in 0.81
|
|
50448
50582
|
"React-renderercss",
|
|
50449
50583
|
"React-oscompat",
|
|
@@ -53932,7 +54066,7 @@ function expoUnitAppPaths(unit2) {
|
|
|
53932
54066
|
});
|
|
53933
54067
|
}
|
|
53934
54068
|
function expoSwiftPackage(appKey, name3) {
|
|
53935
|
-
return import_node_path79.default.join(
|
|
54069
|
+
return import_node_path79.default.join(import_node_os18.default.tmpdir(), "peach-expo-swift", appKey, `p${process.pid}`, name3);
|
|
53936
54070
|
}
|
|
53937
54071
|
function failureRecordPath(packagePath) {
|
|
53938
54072
|
const app = import_node_path79.default.dirname(import_node_path79.default.dirname(packagePath));
|
|
@@ -54463,7 +54597,7 @@ async function compileExpoSwiftModulesTraced(root, base, publishArtifact, option
|
|
|
54463
54597
|
throw failure2;
|
|
54464
54598
|
}
|
|
54465
54599
|
}
|
|
54466
|
-
var import_node_async_hooks2, import_node_child_process43, import_node_crypto43, import_node_fs81, import_node_module9,
|
|
54600
|
+
var import_node_async_hooks2, import_node_child_process43, import_node_crypto43, import_node_fs81, import_node_module9, import_node_os18, import_node_path79, import_node_url5, import_node_util15, run7, scriptEnv, EXPO_SWIFT_ENTRY, WITNESS_BATCH, traceStore, discoveryCache, preparedCache, savedFs, ignoredRoots, preparedExpoSwift, openPreparations, ExpoSwiftLinkRefusal;
|
|
54467
54601
|
var init_expo_swift_host = __esm({
|
|
54468
54602
|
"src/expo-swift-host.ts"() {
|
|
54469
54603
|
"use strict";
|
|
@@ -54473,7 +54607,7 @@ var init_expo_swift_host = __esm({
|
|
|
54473
54607
|
import_node_crypto43 = require("node:crypto");
|
|
54474
54608
|
import_node_fs81 = __toESM(require("node:fs"), 1);
|
|
54475
54609
|
import_node_module9 = require("node:module");
|
|
54476
|
-
|
|
54610
|
+
import_node_os18 = __toESM(require("node:os"), 1);
|
|
54477
54611
|
import_node_path79 = __toESM(require("node:path"), 1);
|
|
54478
54612
|
import_node_url5 = require("node:url");
|
|
54479
54613
|
import_node_util15 = require("node:util");
|
|
@@ -54538,13 +54672,7 @@ async function buildExpoSwiftBundle(appRoot) {
|
|
|
54538
54672
|
bytes: artifact.bytes,
|
|
54539
54673
|
contentType: "application/wasm"
|
|
54540
54674
|
});
|
|
54541
|
-
if ("gzip" in artifact.icu)
|
|
54542
|
-
assets2.push({
|
|
54543
|
-
path: `__peach/swift-icu/${artifact.icu.sha256}`,
|
|
54544
|
-
bytes: artifact.icu.gzip,
|
|
54545
|
-
contentType: "application/gzip"
|
|
54546
|
-
});
|
|
54547
|
-
}
|
|
54675
|
+
if ("gzip" in artifact.icu) assets2.push(await swiftIcuBundleAsset(artifact.icu));
|
|
54548
54676
|
}
|
|
54549
54677
|
);
|
|
54550
54678
|
if (!metadata) return null;
|
|
@@ -54555,6 +54683,7 @@ var init_expo_swift_bundle = __esm({
|
|
|
54555
54683
|
"use strict";
|
|
54556
54684
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
54557
54685
|
init_expo_swift_host();
|
|
54686
|
+
init_swift_icu();
|
|
54558
54687
|
}
|
|
54559
54688
|
});
|
|
54560
54689
|
|
|
@@ -55507,7 +55636,7 @@ async function compileNitroModule(options) {
|
|
|
55507
55636
|
const key2 = (0, import_node_crypto45.createHash)("sha256").update(
|
|
55508
55637
|
collection.providers.map(({ root, hybridObjects }) => `${root}\0${hybridObjects.join(",")}`).join("\0")
|
|
55509
55638
|
).update("\0").update(import_node_fs85.default.realpathSync(options.moduleRoot)).update("\0").update(options.configuration).digest("hex");
|
|
55510
|
-
const packagePath = import_node_path83.default.join(
|
|
55639
|
+
const packagePath = import_node_path83.default.join(import_node_os19.default.tmpdir(), "peach-nitro-swift", key2, `p${process.pid}`);
|
|
55511
55640
|
const sharedLibrary = [...nativeLibraries.values()].find(
|
|
55512
55641
|
(pod) => pod.sharedLibrary
|
|
55513
55642
|
)?.sharedLibrary;
|
|
@@ -55555,14 +55684,14 @@ function nitrogenGeneratedSources(podDirectory) {
|
|
|
55555
55684
|
...sources(import_node_path83.default.join(generated, "ios"), /\.(h|hpp|c|cpp|mm|swift)$/)
|
|
55556
55685
|
];
|
|
55557
55686
|
}
|
|
55558
|
-
var import_node_crypto45, import_node_fs85,
|
|
55687
|
+
var import_node_crypto45, import_node_fs85, import_node_os19, import_node_path83, BUNDLED_CXX_NAMESPACES;
|
|
55559
55688
|
var init_nitro_compile = __esm({
|
|
55560
55689
|
"src/nitro-compile.ts"() {
|
|
55561
55690
|
"use strict";
|
|
55562
55691
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
55563
55692
|
import_node_crypto45 = require("node:crypto");
|
|
55564
55693
|
import_node_fs85 = __toESM(require("node:fs"), 1);
|
|
55565
|
-
|
|
55694
|
+
import_node_os19 = __toESM(require("node:os"), 1);
|
|
55566
55695
|
import_node_path83 = __toESM(require("node:path"), 1);
|
|
55567
55696
|
init_installed_native_libraries();
|
|
55568
55697
|
init_native_app_identity_project();
|
|
@@ -55706,7 +55835,7 @@ var init_nitro_superset = __esm({
|
|
|
55706
55835
|
init_swift_standin_digest();
|
|
55707
55836
|
NITRO_SUPERSET_ENTRY_NAME = "superset";
|
|
55708
55837
|
packageVersion = (root) => JSON.parse((0, import_node_fs86.readFileSync)((0, import_node_path84.join)(root, "package.json"), "utf8")).version;
|
|
55709
|
-
NITRO_COMPILER_DIGEST = true ? "
|
|
55838
|
+
NITRO_COMPILER_DIGEST = true ? "c178e3c4c8465d4d358306448e5ae7cac0a7c25cfb0e1462fe3da02524653782" : nitroCompilerSourceDigest(__sootsim_import_meta_dirname, STANDIN_SOURCE_DIGEST2);
|
|
55710
55839
|
nitroSupersetLock = parseLock(nitro_superset_lock_default);
|
|
55711
55840
|
nitroSupersetKey = (inputs) => nativeEntryKey({ ...inputs, compiler: NITRO_COMPILER_DIGEST });
|
|
55712
55841
|
published2 = /* @__PURE__ */ new Map();
|
|
@@ -55806,28 +55935,22 @@ async function compileNitroApp(appRoot, origin, configuration, moduleRoot, share
|
|
|
55806
55935
|
}
|
|
55807
55936
|
};
|
|
55808
55937
|
}
|
|
55809
|
-
function compiledModuleAssets(artifact) {
|
|
55810
|
-
|
|
55938
|
+
async function compiledModuleAssets(artifact) {
|
|
55939
|
+
return [
|
|
55811
55940
|
{
|
|
55812
55941
|
path: `__peach/swift/${artifact.hash}.wasm`,
|
|
55813
55942
|
bytes: artifact.bytes,
|
|
55814
55943
|
contentType: "application/wasm"
|
|
55815
|
-
}
|
|
55944
|
+
},
|
|
55945
|
+
..."gzip" in artifact.icu ? [await swiftIcuBundleAsset(artifact.icu)] : []
|
|
55816
55946
|
];
|
|
55817
|
-
if ("gzip" in artifact.icu)
|
|
55818
|
-
assets2.push({
|
|
55819
|
-
path: `__peach/swift-icu/${artifact.icu.sha256}`,
|
|
55820
|
-
bytes: artifact.icu.gzip,
|
|
55821
|
-
contentType: "application/gzip"
|
|
55822
|
-
});
|
|
55823
|
-
return assets2;
|
|
55824
55947
|
}
|
|
55825
55948
|
async function buildNitroBundle(appRoot, configuration, moduleRoot, shared = true) {
|
|
55826
55949
|
const compiled = await compileNitroApp(appRoot, "", configuration, moduleRoot, shared);
|
|
55827
55950
|
if (!compiled) return null;
|
|
55828
55951
|
return {
|
|
55829
55952
|
metadata: compiled.metadata,
|
|
55830
|
-
assets: compiled.artifact ? compiledModuleAssets(compiled.artifact) : []
|
|
55953
|
+
assets: compiled.artifact ? await compiledModuleAssets(compiled.artifact) : []
|
|
55831
55954
|
};
|
|
55832
55955
|
}
|
|
55833
55956
|
function compiledModuleRequestHandler(label, compile2) {
|
|
@@ -55916,6 +56039,7 @@ var init_nitro_bundle = __esm({
|
|
|
55916
56039
|
init_nitro_superset();
|
|
55917
56040
|
init_swift_distribution();
|
|
55918
56041
|
init_swift_host();
|
|
56042
|
+
init_swift_icu();
|
|
55919
56043
|
NITRO_ROUTE = "/__peach/nitro";
|
|
55920
56044
|
handleNitroRequest = compiledModuleRequestHandler(
|
|
55921
56045
|
"Nitro",
|
|
@@ -56046,7 +56170,7 @@ function collectTurboCompileInput(collection, runtime, iosDeploymentTarget, depe
|
|
|
56046
56170
|
async function compileTurboModule(options) {
|
|
56047
56171
|
await prepareTurboSourceDependencies(options.reactNativeRoot);
|
|
56048
56172
|
const key2 = (0, import_node_crypto46.createHash)("sha256").update(options.providers.map(({ root }) => import_node_fs88.default.realpathSync(root)).join("\0")).update("\0").update(import_node_fs88.default.realpathSync(options.moduleRoot)).digest("hex");
|
|
56049
|
-
const scratch2 = import_node_path86.default.join(
|
|
56173
|
+
const scratch2 = import_node_path86.default.join(import_node_os20.default.tmpdir(), "peach-turbo-swift", key2);
|
|
56050
56174
|
import_node_fs88.default.rmSync(import_node_path86.default.join(scratch2, "codegen"), { recursive: true, force: true });
|
|
56051
56175
|
const collection = await collectTurboSources({
|
|
56052
56176
|
appRoot: options.appRoot,
|
|
@@ -56244,7 +56368,7 @@ async function compileTurboModule(options) {
|
|
|
56244
56368
|
collection
|
|
56245
56369
|
};
|
|
56246
56370
|
}
|
|
56247
|
-
var import_node_crypto46, import_node_fs88, import_node_module11,
|
|
56371
|
+
var import_node_crypto46, import_node_fs88, import_node_module11, import_node_os20, import_node_path86;
|
|
56248
56372
|
var init_turbo_compile = __esm({
|
|
56249
56373
|
"src/turbo-compile.ts"() {
|
|
56250
56374
|
"use strict";
|
|
@@ -56252,7 +56376,7 @@ var init_turbo_compile = __esm({
|
|
|
56252
56376
|
import_node_crypto46 = require("node:crypto");
|
|
56253
56377
|
import_node_fs88 = __toESM(require("node:fs"), 1);
|
|
56254
56378
|
import_node_module11 = require("node:module");
|
|
56255
|
-
|
|
56379
|
+
import_node_os20 = __toESM(require("node:os"), 1);
|
|
56256
56380
|
import_node_path86 = __toESM(require("node:path"), 1);
|
|
56257
56381
|
init_native_app_identity_project();
|
|
56258
56382
|
init_nitro_adapter();
|
|
@@ -56342,7 +56466,7 @@ async function buildTurboBundle(appRoot, moduleRoot) {
|
|
|
56342
56466
|
if (!compiled) return null;
|
|
56343
56467
|
return {
|
|
56344
56468
|
metadata: compiled.metadata,
|
|
56345
|
-
assets: compiled.artifact ? compiledModuleAssets(compiled.artifact) : []
|
|
56469
|
+
assets: compiled.artifact ? await compiledModuleAssets(compiled.artifact) : []
|
|
56346
56470
|
};
|
|
56347
56471
|
}
|
|
56348
56472
|
var import_node_module12, import_node_path87, TURBO_ROUTE, handleTurboRequest;
|
|
@@ -62882,7 +63006,7 @@ ${await response.text()}`
|
|
|
62882
63006
|
}
|
|
62883
63007
|
async function snapshotOneProductionBundle(projectRoot, entryFile, env = {}, { runtimeExecutable = process.execPath, platforms: platforms2 = ["ios", "android"] } = {}) {
|
|
62884
63008
|
const { execFile: execFile18 } = await import("node:child_process");
|
|
62885
|
-
const { mkdtemp, readFile:
|
|
63009
|
+
const { mkdtemp, readFile: readFile3, rm: rm2 } = await import("node:fs/promises");
|
|
62886
63010
|
const { tmpdir: tmpdir3 } = await import("node:os");
|
|
62887
63011
|
const { promisify: promisify18 } = await import("node:util");
|
|
62888
63012
|
const inputs = await readPackagingInputs(projectRoot);
|
|
@@ -62913,10 +63037,10 @@ async function snapshotOneProductionBundle(projectRoot, entryFile, env = {}, { r
|
|
|
62913
63037
|
{ cwd: projectRoot, env: { ...process.env, ...env, NODE_ENV: "production" } }
|
|
62914
63038
|
);
|
|
62915
63039
|
snapshots.push(
|
|
62916
|
-
await packagePlatformBundle(projectRoot, platform2, await
|
|
63040
|
+
await packagePlatformBundle(projectRoot, platform2, await readFile3((0, import_node_path96.join)(out, "bundle.js")), {
|
|
62917
63041
|
...inputs,
|
|
62918
63042
|
configuration: "Release",
|
|
62919
|
-
readAssetFile: (asset, file) =>
|
|
63043
|
+
readAssetFile: (asset, file) => readFile3((0, import_node_path96.join)(out, asset.httpServerLocation, file))
|
|
62920
63044
|
})
|
|
62921
63045
|
);
|
|
62922
63046
|
} finally {
|