peachsim 0.1.2624 → 0.1.2625
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/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 +2 -2
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +1 -1
- package/dist-lib/bridge-contract-input.mjs +5 -5
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +3 -3
- package/dist-lib/bundle-channel.cjs +339 -324
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +3 -3
- package/dist-lib/cloud-contract.cjs +1 -1
- package/dist-lib/cloud-contract.mjs +3 -3
- package/dist-lib/cloud-test-args.cjs +1 -1
- package/dist-lib/cloud-test-args.mjs +2 -2
- package/dist-lib/cloud.cjs +1 -1
- package/dist-lib/cloud.mjs +7 -7
- package/dist-lib/config.cjs +1 -1
- package/dist-lib/config.mjs +5 -5
- package/dist-lib/detox/index.cjs +1 -1
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/esm-chunks/{acorn-DH6VFUJ3.mjs → acorn-SHZZDBSI.mjs} +3 -3
- package/dist-lib/esm-chunks/{chunk-CM2NU5MS.mjs → chunk-2LDG7OD4.mjs} +5 -5
- package/dist-lib/esm-chunks/{chunk-UJORQHAE.mjs → chunk-3XZGWT62.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-JHMD4G4V.mjs → chunk-6PZI7TYE.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-265THLTP.mjs → chunk-7Z7YJ4FU.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-IMI2NE4A.mjs → chunk-A4R4YGFJ.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-QNXV766K.mjs → chunk-A66VNSO6.mjs} +15 -15
- package/dist-lib/esm-chunks/{chunk-3XA5HYI5.mjs → chunk-DVMKYLDN.mjs} +9 -8
- package/dist-lib/esm-chunks/{chunk-LOQBWIPM.mjs → chunk-F4YHL4UM.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-LCO2EXKF.mjs → chunk-JRU2VXUU.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-YOD53JTM.mjs → chunk-JVEJLPJC.mjs} +2 -2
- package/dist-lib/esm-chunks/{chunk-AV7G5PTE.mjs → chunk-KA4AQDVF.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-HKPKCJI5.mjs → chunk-LJYNZ5HM.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-LMWSFXYN.mjs → chunk-M2FEKSK3.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-N4ZJZUCO.mjs → chunk-OCCZJOSA.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-LD7Z3NDO.mjs → chunk-P542MMIN.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-OLAYY7SG.mjs → chunk-Q5NI4L3Z.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-QZ5HTMWV.mjs → chunk-R4FFTWPL.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-A2WMBGJO.mjs → chunk-RJWEWNAJ.mjs} +3 -3
- package/dist-lib/esm-chunks/{chunk-T7C6Z5UH.mjs → chunk-RXXCTHJG.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-LT533AHJ.mjs → chunk-SRIRVPNX.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-XONCLAVA.mjs → chunk-ULHG6CND.mjs} +21 -13
- package/dist-lib/esm-chunks/{chunk-2YHIYKY2.mjs → chunk-W4HQINQ6.mjs} +4 -4
- package/dist-lib/esm-chunks/{chunk-EFQFJ7M6.mjs → chunk-XQBHCWS4.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-VH4BJS5V.mjs → chunk-Z6AH6AQC.mjs} +1 -1
- package/dist-lib/esm-chunks/{metro-layout-parser-MDVTDJ65.mjs → metro-layout-parser-GJHR7FCR.mjs} +3 -3
- package/dist-lib/esm-chunks/{swift-package-prebuilt-ZN7I4FYC.mjs → swift-package-prebuilt-UVRGKTD4.mjs} +12 -12
- package/dist-lib/esm-chunks/{swift-sdk-app-module-DUVE2OXH.mjs → swift-sdk-app-module-U3MUJ7QD.mjs} +16 -16
- package/dist-lib/esm-chunks/{swift-sdk-image-YSWQBCYV.mjs → swift-sdk-image-U4W7QMAT.mjs} +16 -18
- package/dist-lib/esm-chunks/{swift-sdk-image-producer-MZ235WSK.mjs → swift-sdk-image-producer-TFFZDNRK.mjs} +5 -5
- package/dist-lib/expo-swift-bundle.cjs +240 -225
- package/dist-lib/expo-swift-metadata.cjs +1 -1
- package/dist-lib/expo-swift-metadata.mjs +7 -7
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +343 -328
- package/dist-lib/host/fetch-proxy-handler.cjs +7 -6
- package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.mjs +2 -2
- package/dist-lib/host/replacement-module-handler.cjs +1 -1
- package/dist-lib/host/websocket-proxy.cjs +1 -1
- package/dist-lib/index.cjs +1 -1
- package/dist-lib/kotlin-host.cjs +1 -1
- package/dist-lib/menu.cjs +1 -1
- package/dist-lib/menu.mjs +3 -3
- package/dist-lib/metro-fingerprint-registry.cjs +1 -1
- package/dist-lib/metro-fingerprint-registry.mjs +3 -3
- package/dist-lib/metro-production-bundle.cjs +1 -1
- package/dist-lib/metro-production-bundle.mjs +4 -4
- package/dist-lib/native-app-identity-project.cjs +4 -3
- package/dist-lib/native-app-identity-project.mjs +15 -15
- package/dist-lib/native-app-identity.cjs +1 -1
- package/dist-lib/native-app-identity.mjs +6 -6
- package/dist-lib/native-firebase-metadata.cjs +1 -1
- package/dist-lib/native-firebase-metadata.mjs +3 -3
- package/dist-lib/pdfium-raster.cjs +1 -1
- package/dist-lib/pdfium-raster.mjs +2 -2
- package/dist-lib/plist.cjs +1 -1
- package/dist-lib/plist.mjs +3 -3
- package/dist-lib/profiles.cjs +1 -1
- package/dist-lib/public-brand.cjs +1 -1
- package/dist-lib/public-origins-lib-esm.json +87 -86
- package/dist-lib/public-origins-lib.json +69 -64
- package/dist-lib/react-native-host-modules.cjs +1 -1
- package/dist-lib/react-native-host-modules.mjs +2 -2
- 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 +8 -8
- package/dist-lib/skills.cjs +380 -365
- package/dist-lib/swift-compile.cjs +75 -61
- package/dist-lib/swift-compile.mjs +12 -12
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +3 -3
- package/dist-lib/swift-submit.cjs +1 -1
- package/dist-lib/swift-submit.mjs +6 -6
- package/dist-lib/swift-svg-raster.cjs +1 -1
- package/dist-lib/swift-svg-raster.mjs +2 -2
- package/dist-lib/swift-toolchain.cjs +1 -1
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vendor/@peculiar/x509.cjs +1 -1
- package/dist-lib/vendor/@ruby/prism/src/nodes.js.cjs +1 -1
- package/dist-lib/vendor/@ruby/prism/src/parsePrism.js.cjs +1 -1
- package/dist-lib/vendor/acorn.cjs +1 -1
- package/dist-lib/vendor/magic-string.cjs +1 -1
- package/dist-lib/vendor/stream-json.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/index.js.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/parser/index.js.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/parser/tokenizer/index.js.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/parser/tokenizer/types.js.cjs +1 -1
- package/dist-lib/vendor/sucrase.cjs +1 -1
- package/dist-lib/vendor/terser.cjs +1 -1
- package/dist-lib/vendor/valibot.cjs +1 -1
- package/dist-lib/vendor/ws.cjs +1 -1
- package/dist-lib/vendor/zod.cjs +1 -1
- package/dist-lib/worklet-executable.cjs +1 -1
- package/dist-lib/worklet-executable.mjs +3 -3
- package/package.json +1 -1
- package/src/swift-distribution-contract.ts +6 -1
- package/src/swift-distribution.lock.json +4 -2
- package/src/swift-sdk-image-recipe.ts +20 -0
- package/src/swift-sdk-image.ts +2 -4
package/dist-lib/skills.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2625 | (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;
|
|
@@ -35826,13 +35826,13 @@ var init_swift_standin_digest = __esm({
|
|
|
35826
35826
|
];
|
|
35827
35827
|
RUNTIME_IMPORT = /(?:^|[;\n])[ \t]*(?:import|export)\s+(?!type(?:\s|\{))([\s\S]*?)\s+from\s*['"]([^'"]+)['"]|(?:^|[;\n])[ \t]*import\s+['"]([^'"]+)['"]|import\s*\(\s*['"]([^'"]+)['"]\s*\)/g;
|
|
35828
35828
|
standinSourceDigest = (srcDir = __sootsim_import_meta_dirname) => sourceClosureDigest(srcDir, STANDIN_DIGEST_ENTRYPOINTS, STANDIN_DIGEST_EXCLUDED_FILES);
|
|
35829
|
-
STANDIN_SOURCE_DIGEST = true ? "
|
|
35829
|
+
STANDIN_SOURCE_DIGEST = true ? "c87e0b7f1ae69b2a4e76611266612d6218f81a3244e592800c02f78c4f8e48f6" : standinSourceDigest();
|
|
35830
35830
|
}
|
|
35831
35831
|
});
|
|
35832
35832
|
|
|
35833
35833
|
// src/expo-native-compiler-digest.ts
|
|
35834
35834
|
function expoNativeCompilerDigestValue() {
|
|
35835
|
-
return true ? "
|
|
35835
|
+
return true ? "a46618eade53d31c53a3c6377fc86635c03dbcfedd5e131d38b77d9fcc366623" : expoNativeCompilerDigest(__sootsim_import_meta_dirname);
|
|
35836
35836
|
}
|
|
35837
35837
|
var import_node_crypto12;
|
|
35838
35838
|
var init_expo_native_compiler_digest = __esm({
|
|
@@ -57448,12 +57448,13 @@ function parseSwiftDistributionLock(value) {
|
|
|
57448
57448
|
if (runtime === void 0) return void 0;
|
|
57449
57449
|
if (!isRecord(runtime) || typeof runtime.source !== "string" || !/^[a-f0-9]{64}$/.test(runtime.source) || typeof runtime.url !== "string" || !/^https:\/\/[a-z0-9.-]+(?::\d+)?\/compile\/asset\/[a-f0-9]{64}$/.test(
|
|
57450
57450
|
runtime.url
|
|
57451
|
-
) || runtime.dataPlan !== void 0 && (typeof runtime.dataPlan !== "string" || !/^[a-f0-9]{64}$/.test(runtime.dataPlan)))
|
|
57451
|
+
) || runtime.dataPlan !== void 0 && (typeof runtime.dataPlan !== "string" || !/^[a-f0-9]{64}$/.test(runtime.dataPlan)) || runtime.recipe !== void 0 && (typeof runtime.recipe !== "string" || !/^[a-f0-9]{16}$/.test(runtime.recipe)))
|
|
57452
57452
|
throw new Error("invalid shared SDK runtime publication in Swift distribution lock");
|
|
57453
57453
|
return {
|
|
57454
57454
|
source: runtime.source,
|
|
57455
57455
|
url: runtime.url,
|
|
57456
|
-
...runtime.dataPlan && { dataPlan: runtime.dataPlan }
|
|
57456
|
+
...runtime.dataPlan && { dataPlan: runtime.dataPlan },
|
|
57457
|
+
...runtime.recipe && { recipe: runtime.recipe }
|
|
57457
57458
|
};
|
|
57458
57459
|
};
|
|
57459
57460
|
const sdkRuntime = publication(value.sdkRuntime);
|
|
@@ -73693,6 +73694,21 @@ var init_swift_root_lock = __esm({
|
|
|
73693
73694
|
}
|
|
73694
73695
|
});
|
|
73695
73696
|
|
|
73697
|
+
// src/swift-sdk-image-recipe.ts
|
|
73698
|
+
var import_node_crypto43, SWIFT_SDK_IMAGE_VERSION, swiftSdkImageScope, SWIFT_SDK_IMAGE_RECIPE;
|
|
73699
|
+
var init_swift_sdk_image_recipe = __esm({
|
|
73700
|
+
"src/swift-sdk-image-recipe.ts"() {
|
|
73701
|
+
"use strict";
|
|
73702
|
+
import_node_crypto43 = require("node:crypto");
|
|
73703
|
+
init_wasm_optimize();
|
|
73704
|
+
SWIFT_SDK_IMAGE_VERSION = 13;
|
|
73705
|
+
swiftSdkImageScope = (scopedLookups) => scopedLookups ? "guest image scopes 9\n" : "unscoped constructor order 1\n";
|
|
73706
|
+
SWIFT_SDK_IMAGE_RECIPE = (0, import_node_crypto43.createHash)("sha256").update(`swift-sdk-image
|
|
73707
|
+
${SWIFT_SDK_IMAGE_VERSION}
|
|
73708
|
+
`).update(WASM_LOWER_IDENTITY).update(swiftSdkImageScope(false)).update(swiftSdkImageScope(true)).digest("hex").slice(0, 16);
|
|
73709
|
+
}
|
|
73710
|
+
});
|
|
73711
|
+
|
|
73696
73712
|
// src/swift-sdk-image-producer.ts
|
|
73697
73713
|
var swift_sdk_image_producer_exports = {};
|
|
73698
73714
|
__export(swift_sdk_image_producer_exports, {
|
|
@@ -73733,7 +73749,7 @@ function applySwiftSdkProducerEnvironment(environment) {
|
|
|
73733
73749
|
}
|
|
73734
73750
|
}
|
|
73735
73751
|
function writeSwiftSdkProducerResult(file, launchId, error) {
|
|
73736
|
-
const temporary = `${file}.${(0,
|
|
73752
|
+
const temporary = `${file}.${(0, import_node_crypto44.randomUUID)()}`;
|
|
73737
73753
|
(0, import_node_fs73.writeFileSync)(temporary, JSON.stringify({ launchId, error: error ?? null }));
|
|
73738
73754
|
(0, import_node_fs73.renameSync)(temporary, file);
|
|
73739
73755
|
}
|
|
@@ -73845,7 +73861,7 @@ async function produceSwiftSdkImage(input) {
|
|
|
73845
73861
|
}
|
|
73846
73862
|
}
|
|
73847
73863
|
const repo = import_node_path71.default.resolve(input.moduleRoot, "../..");
|
|
73848
|
-
const launchId = (0,
|
|
73864
|
+
const launchId = (0, import_node_crypto44.randomUUID)();
|
|
73849
73865
|
const directory3 = import_node_path71.default.join(root, launchId);
|
|
73850
73866
|
const requestFile = import_node_path71.default.join(directory3, "request.json");
|
|
73851
73867
|
const sessionFile2 = import_node_path71.default.join(directory3, "session");
|
|
@@ -73943,12 +73959,12 @@ async function produceSwiftSdkImage(input) {
|
|
|
73943
73959
|
await (0, import_promises10.setTimeout)(2e3, void 0, { signal: input.signal });
|
|
73944
73960
|
}
|
|
73945
73961
|
}
|
|
73946
|
-
var import_node_child_process38,
|
|
73962
|
+
var import_node_child_process38, import_node_crypto44, import_node_fs73, import_node_path71, import_promises10, import_node_util9, run4, environmentNames, launcher;
|
|
73947
73963
|
var init_swift_sdk_image_producer = __esm({
|
|
73948
73964
|
"src/swift-sdk-image-producer.ts"() {
|
|
73949
73965
|
"use strict";
|
|
73950
73966
|
import_node_child_process38 = require("node:child_process");
|
|
73951
|
-
|
|
73967
|
+
import_node_crypto44 = require("node:crypto");
|
|
73952
73968
|
import_node_fs73 = require("node:fs");
|
|
73953
73969
|
import_node_path71 = __toESM(require("node:path"), 1);
|
|
73954
73970
|
import_promises10 = require("node:timers/promises");
|
|
@@ -73988,7 +74004,6 @@ __export(swift_sdk_image_exports, {
|
|
|
73988
74004
|
SWIFT_SDK_APP_TABLE_BASE: () => SWIFT_SDK_APP_TABLE_BASE,
|
|
73989
74005
|
SWIFT_SDK_IMAGE_BUNDLE: () => SWIFT_SDK_IMAGE_BUNDLE,
|
|
73990
74006
|
SWIFT_SDK_IMAGE_FILES: () => SWIFT_SDK_IMAGE_FILES,
|
|
73991
|
-
SWIFT_SDK_IMAGE_VERSION: () => SWIFT_SDK_IMAGE_VERSION,
|
|
73992
74007
|
SWIFT_SDK_MEMORY_BASE: () => SWIFT_SDK_MEMORY_BASE,
|
|
73993
74008
|
SWIFT_SDK_PIECE_FIELDS: () => SWIFT_SDK_PIECE_FIELDS,
|
|
73994
74009
|
buildSwiftSdkImage: () => buildSwiftSdkImage,
|
|
@@ -74023,9 +74038,9 @@ function swiftSdkImageProducts(moduleRoot, frameworkImports2) {
|
|
|
74023
74038
|
function swiftSdkImageKey(moduleRoot, scopedLookups = false, products = []) {
|
|
74024
74039
|
const distribution = swiftDistributionAt(moduleRoot);
|
|
74025
74040
|
const inputs2 = distribution ? swiftSdkDistributionInputs(distribution) : swiftModuleDigest(moduleRoot);
|
|
74026
|
-
return (0,
|
|
74041
|
+
return (0, import_node_crypto45.createHash)("sha256").update(`swift-sdk-image
|
|
74027
74042
|
${SWIFT_SDK_IMAGE_VERSION}
|
|
74028
|
-
`).update(WASM_LOWER_IDENTITY).update(KEEP_WASM_NAMES ? "\nnames\n" : "\n").update(scopedLookups
|
|
74043
|
+
`).update(WASM_LOWER_IDENTITY).update(KEEP_WASM_NAMES ? "\nnames\n" : "\n").update(swiftSdkImageScope(scopedLookups)).update(inputs2).update(products.length === 0 ? "" : `
|
|
74029
74044
|
products ${products.join(" ")}`).digest("hex").slice(0, 32);
|
|
74030
74045
|
}
|
|
74031
74046
|
function swiftSdkImageEntry(key2, scopedLookups) {
|
|
@@ -74114,7 +74129,7 @@ async function buildSwiftSdkImage(moduleRoot, scopedLookups = false, frameworkIm
|
|
|
74114
74129
|
stage
|
|
74115
74130
|
]);
|
|
74116
74131
|
const image = cached3(stage, key2);
|
|
74117
|
-
if (!image || (0,
|
|
74132
|
+
if (!image || (0, import_node_crypto45.createHash)("sha256").update((0, import_node_fs74.readFileSync)(image.image)).digest("hex") !== image.sha256)
|
|
74118
74133
|
throw new Error(`invalid published Swift SDK image ${key2}`);
|
|
74119
74134
|
(0, import_node_fs74.rmSync)(directory2, { recursive: true, force: true });
|
|
74120
74135
|
(0, import_node_fs74.renameSync)(stage, directory2);
|
|
@@ -74384,7 +74399,7 @@ async function linkSwiftSdkImage(moduleRoot, key2, directory2, work, scopedLooku
|
|
|
74384
74399
|
(0, import_node_fs74.writeFileSync)(import_node_path72.default.join(work, INTERFACE_FILE), JSON.stringify(sdkInterface));
|
|
74385
74400
|
(0, import_node_fs74.writeFileSync)(
|
|
74386
74401
|
import_node_path72.default.join(work, IMAGE_DIGEST),
|
|
74387
|
-
typeof Bun !== "undefined" ? new Bun.CryptoHasher("sha256").update(image).digest("hex") : (0,
|
|
74402
|
+
typeof Bun !== "undefined" ? new Bun.CryptoHasher("sha256").update(image).digest("hex") : (0, import_node_crypto45.createHash)("sha256").update(image).digest("hex")
|
|
74388
74403
|
);
|
|
74389
74404
|
if (swiftSdkImageKey(
|
|
74390
74405
|
moduleRoot,
|
|
@@ -74653,12 +74668,12 @@ function readSwiftSdkManifest(image) {
|
|
|
74653
74668
|
}));
|
|
74654
74669
|
return setBoundedCache(cachedSdkManifests, cacheKey, { manifest, block: block2, segments });
|
|
74655
74670
|
}
|
|
74656
|
-
var import_node_child_process39,
|
|
74671
|
+
var import_node_child_process39, import_node_crypto45, import_node_fs74, import_node_path72, import_node_util10, run5, SWIFT_SDK_APP_MEMORY_BASE, SWIFT_SDK_MEMORY_BASE, SWIFT_SDK_APP_TABLE_BASE, EMPTY_APP, IMAGE_TABLES, IMAGE_ENTRY, imageApp, IMAGE_FILE, IMAGE_DIGEST, swiftSdkImageFile, INTERFACE_FILE, MANIFEST_FILE, MANIFEST_DATA_FILE, SWIFT_SDK_IMAGE_FILES, SWIFT_SDK_IMAGE_BUNDLE, MAX_CACHED_SDK_IMAGES, cachedSdkInterfaces, cachedSdkManifestIndices, cachedSdkManifests, SWIFT_SDK_PIECE_FIELDS, MANIFEST_BLOCKS, isManifestBlock;
|
|
74657
74672
|
var init_swift_sdk_image = __esm({
|
|
74658
74673
|
"src/swift-sdk-image.ts"() {
|
|
74659
74674
|
"use strict";
|
|
74660
74675
|
import_node_child_process39 = require("node:child_process");
|
|
74661
|
-
|
|
74676
|
+
import_node_crypto45 = require("node:crypto");
|
|
74662
74677
|
import_node_fs74 = require("node:fs");
|
|
74663
74678
|
import_node_path72 = __toESM(require("node:path"), 1);
|
|
74664
74679
|
import_node_util10 = require("node:util");
|
|
@@ -74670,13 +74685,13 @@ var init_swift_sdk_image = __esm({
|
|
|
74670
74685
|
init_swift_root_lock();
|
|
74671
74686
|
init_swift_sdk_guest_lookups();
|
|
74672
74687
|
init_swift_sdk_image_map();
|
|
74688
|
+
init_swift_sdk_image_recipe();
|
|
74673
74689
|
init_swift_sdk_image_wasm();
|
|
74674
74690
|
init_swift_toolchain();
|
|
74675
74691
|
init_swift_wasm_prune();
|
|
74676
74692
|
init_swiftTargetContract();
|
|
74677
74693
|
init_wasm_optimize();
|
|
74678
74694
|
run5 = (0, import_node_util10.promisify)(import_node_child_process39.execFile);
|
|
74679
|
-
SWIFT_SDK_IMAGE_VERSION = 13;
|
|
74680
74695
|
SWIFT_SDK_APP_MEMORY_BASE = 8372224;
|
|
74681
74696
|
SWIFT_SDK_MEMORY_BASE = 128 * 1024 * 1024;
|
|
74682
74697
|
SWIFT_SDK_APP_TABLE_BASE = 524288;
|
|
@@ -75320,7 +75335,7 @@ async function linkSwiftAppModule(options2) {
|
|
|
75320
75335
|
lazy,
|
|
75321
75336
|
KEEP_WASM_NAMES
|
|
75322
75337
|
])
|
|
75323
|
-
).update(bytes).digest("hex") : (0,
|
|
75338
|
+
).update(bytes).digest("hex") : (0, import_node_crypto46.createHash)("sha256").update(
|
|
75324
75339
|
JSON.stringify([
|
|
75325
75340
|
loweringCache.compilerDigest,
|
|
75326
75341
|
optimize,
|
|
@@ -75939,7 +75954,7 @@ function createSwiftSdkBinding(linkage, sdk2, usage, projection) {
|
|
|
75939
75954
|
bindSwiftAppModule(linkage, sdk2),
|
|
75940
75955
|
selectSwiftSdkData(sdk2, usage, linkage, projection)
|
|
75941
75956
|
]);
|
|
75942
|
-
const sha2565 = typeof Bun !== "undefined" ? new Bun.CryptoHasher("sha256").update(bytes).digest("hex") : (0,
|
|
75957
|
+
const sha2565 = typeof Bun !== "undefined" ? new Bun.CryptoHasher("sha256").update(bytes).digest("hex") : (0, import_node_crypto46.createHash)("sha256").update(bytes).digest("hex");
|
|
75943
75958
|
return { bytes, sha256: sha2565 };
|
|
75944
75959
|
}
|
|
75945
75960
|
function readSwiftSdkUsage(mapFile, linkedFile, sdkObjects) {
|
|
@@ -76486,12 +76501,12 @@ function partitionParent(section2) {
|
|
|
76486
76501
|
"__objc_class_refs"
|
|
76487
76502
|
].find((name3) => section2 === name3 || section2.startsWith(`${name3}.`));
|
|
76488
76503
|
}
|
|
76489
|
-
var import_node_child_process40,
|
|
76504
|
+
var import_node_child_process40, import_node_crypto46, import_node_fs75, import_node_path73, import_node_util11, import_node_zlib5, run6, RELOCATION_WIDTHS, GLOBAL_INDEX, TLS_SLEB64, SDK_TLS_HELPER, SDK_TLS_DELTA, OBJC_SECTION_BOUNDARY, uleb4, sleb2, encodedName2, SCANNED, RUN_GAP;
|
|
76490
76505
|
var init_swift_sdk_app_module = __esm({
|
|
76491
76506
|
"src/swift-sdk-app-module.ts"() {
|
|
76492
76507
|
"use strict";
|
|
76493
76508
|
import_node_child_process40 = require("node:child_process");
|
|
76494
|
-
|
|
76509
|
+
import_node_crypto46 = require("node:crypto");
|
|
76495
76510
|
import_node_fs75 = require("node:fs");
|
|
76496
76511
|
import_node_path73 = __toESM(require("node:path"), 1);
|
|
76497
76512
|
import_node_util11 = require("node:util");
|
|
@@ -77197,7 +77212,7 @@ function compilerCheckpoint(root, recipe2, args, header) {
|
|
|
77197
77212
|
}
|
|
77198
77213
|
if (!objects.length) return;
|
|
77199
77214
|
const outputs = [module2, header, map2[""].dependencies, ...objects];
|
|
77200
|
-
const digest3 = (0,
|
|
77215
|
+
const digest3 = (0, import_node_crypto47.createHash)("sha256").update(recipe2).update(JSON.stringify(args)).update(mapText);
|
|
77201
77216
|
for (const flag of args) {
|
|
77202
77217
|
if (!flag.startsWith("@")) continue;
|
|
77203
77218
|
const response = flag.slice(1);
|
|
@@ -77291,11 +77306,11 @@ async function withSwiftHeaderCompiler(root, toolchainBin, recipe2, producers, b
|
|
|
77291
77306
|
(0, import_node_fs77.rmSync)(directory2, { recursive: true, force: true });
|
|
77292
77307
|
}
|
|
77293
77308
|
}
|
|
77294
|
-
var
|
|
77309
|
+
var import_node_crypto47, import_node_fs77, import_node_http2, import_node_path75, SWIFT_HEADER_COMPILER_WRAPPER, argument, client;
|
|
77295
77310
|
var init_swift_header_compiler = __esm({
|
|
77296
77311
|
"src/swift-header-compiler.ts"() {
|
|
77297
77312
|
"use strict";
|
|
77298
|
-
|
|
77313
|
+
import_node_crypto47 = require("node:crypto");
|
|
77299
77314
|
import_node_fs77 = require("node:fs");
|
|
77300
77315
|
import_node_http2 = require("node:http");
|
|
77301
77316
|
import_node_path75 = __toESM(require("node:path"), 1);
|
|
@@ -77559,7 +77574,7 @@ var init_icuData = __esm({
|
|
|
77559
77574
|
|
|
77560
77575
|
// src/swift-icu.ts
|
|
77561
77576
|
async function cachedBrotli(bytes, quality, cacheKey) {
|
|
77562
|
-
const key2 = cacheKey && /^[a-f0-9]{64}$/.test(cacheKey) ? cacheKey : (0,
|
|
77577
|
+
const key2 = cacheKey && /^[a-f0-9]{64}$/.test(cacheKey) ? cacheKey : (0, import_node_crypto48.createHash)("sha256").update(bytes).digest("hex");
|
|
77563
77578
|
const cacheId = `${quality}:${key2}`;
|
|
77564
77579
|
const cached5 = brotliMemoryCache.get(cacheId);
|
|
77565
77580
|
if (cached5) return cached5;
|
|
@@ -77577,7 +77592,7 @@ async function cachedBrotli(bytes, quality, cacheKey) {
|
|
|
77577
77592
|
});
|
|
77578
77593
|
try {
|
|
77579
77594
|
await (0, import_promises11.mkdir)(dir, { recursive: true });
|
|
77580
|
-
const tmp = `${file}.${(0,
|
|
77595
|
+
const tmp = `${file}.${(0, import_node_crypto48.randomUUID)()}.tmp`;
|
|
77581
77596
|
await (0, import_promises11.writeFile)(tmp, compressed);
|
|
77582
77597
|
await (0, import_promises11.rename)(tmp, file);
|
|
77583
77598
|
} catch {
|
|
@@ -77615,7 +77630,7 @@ function swiftIcuAsset(toolchainBin, sdk2) {
|
|
|
77615
77630
|
JSON.stringify([toolchainBin, sdk2, swiftSdkOptions()]),
|
|
77616
77631
|
async () => {
|
|
77617
77632
|
const zipped = await deflate(await swiftIcuData(toolchainBin, sdk2));
|
|
77618
|
-
return { sha256: (0,
|
|
77633
|
+
return { sha256: (0, import_node_crypto48.createHash)("sha256").update(zipped).digest("hex"), gzip: zipped };
|
|
77619
77634
|
}
|
|
77620
77635
|
);
|
|
77621
77636
|
}
|
|
@@ -77717,7 +77732,7 @@ function swiftIcuPacked(icu) {
|
|
|
77717
77732
|
)
|
|
77718
77733
|
);
|
|
77719
77734
|
await (0, import_promises11.mkdir)(import_node_path77.default.dirname(file), { recursive: true });
|
|
77720
|
-
const tmp = `${file}.${(0,
|
|
77735
|
+
const tmp = `${file}.${(0, import_node_crypto48.randomUUID)()}.tmp`;
|
|
77721
77736
|
await (0, import_promises11.writeFile)(tmp, packed);
|
|
77722
77737
|
await (0, import_promises11.rename)(tmp, file);
|
|
77723
77738
|
return packed;
|
|
@@ -77730,12 +77745,12 @@ async function swiftIcuBundleAsset(icu) {
|
|
|
77730
77745
|
contentType: "application/octet-stream"
|
|
77731
77746
|
};
|
|
77732
77747
|
}
|
|
77733
|
-
var import_node_child_process42,
|
|
77748
|
+
var import_node_child_process42, import_node_crypto48, import_node_fs78, import_promises11, import_node_os16, import_node_path77, import_node_util12, import_node_zlib6, run7, deflate, compressBrotli, inflateGzip, ARCHIVE, MEMBER, raw, assets, brotliMemoryCache, packedFiles;
|
|
77734
77749
|
var init_swift_icu = __esm({
|
|
77735
77750
|
"src/swift-icu.ts"() {
|
|
77736
77751
|
"use strict";
|
|
77737
77752
|
import_node_child_process42 = require("node:child_process");
|
|
77738
|
-
|
|
77753
|
+
import_node_crypto48 = require("node:crypto");
|
|
77739
77754
|
import_node_fs78 = require("node:fs");
|
|
77740
77755
|
import_promises11 = require("node:fs/promises");
|
|
77741
77756
|
import_node_os16 = __toESM(require("node:os"), 1);
|
|
@@ -77938,7 +77953,7 @@ function swiftObjCPrebuiltCompiler(clang, root, sysroot, distribution, targets,
|
|
|
77938
77953
|
);
|
|
77939
77954
|
if (!modules.length) return [];
|
|
77940
77955
|
const { executable, prefixArgs } = rnxSelfInvocation();
|
|
77941
|
-
const compiler = (0,
|
|
77956
|
+
const compiler = (0, import_node_crypto49.createHash)("sha256").update(import_node_fs79.default.readFileSync(clang)).digest("hex");
|
|
77942
77957
|
return [
|
|
77943
77958
|
'case "$module" in',
|
|
77944
77959
|
` ${modules.join("|")}) exec ${[
|
|
@@ -77956,12 +77971,12 @@ function swiftObjCPrebuiltCompiler(clang, root, sysroot, distribution, targets,
|
|
|
77956
77971
|
"esac"
|
|
77957
77972
|
];
|
|
77958
77973
|
}
|
|
77959
|
-
var import_node_child_process43,
|
|
77974
|
+
var import_node_child_process43, import_node_crypto49, import_node_fs79, import_node_path78, quote2;
|
|
77960
77975
|
var init_swift_objc_prebuilt = __esm({
|
|
77961
77976
|
"src/swift-objc-prebuilt.ts"() {
|
|
77962
77977
|
"use strict";
|
|
77963
77978
|
import_node_child_process43 = require("node:child_process");
|
|
77964
|
-
|
|
77979
|
+
import_node_crypto49 = require("node:crypto");
|
|
77965
77980
|
import_node_fs79 = __toESM(require("node:fs"), 1);
|
|
77966
77981
|
import_node_path78 = __toESM(require("node:path"), 1);
|
|
77967
77982
|
init_internal_child_contract();
|
|
@@ -78314,7 +78329,7 @@ function swiftPackagePrebuiltEntries(input, moduleRoot, toolchainBin) {
|
|
|
78314
78329
|
([file, source]) => !/\.(?:swift|c|h|inc|modulemap)$/.test(file) || file.endsWith(".swift") && swiftImportNames(source, available2).some((name4) => !available2.has(name4))
|
|
78315
78330
|
))
|
|
78316
78331
|
return [];
|
|
78317
|
-
const hash = (0,
|
|
78332
|
+
const hash = (0, import_node_crypto50.createHash)("sha256");
|
|
78318
78333
|
for (const entry of files2.sort(
|
|
78319
78334
|
([left], [right]) => left < right ? -1 : left > right ? 1 : 0
|
|
78320
78335
|
))
|
|
@@ -78381,11 +78396,11 @@ function useSwiftPackagePrebuilts(input, moduleRoot, toolchainBin) {
|
|
|
78381
78396
|
}
|
|
78382
78397
|
return resolved;
|
|
78383
78398
|
}
|
|
78384
|
-
var
|
|
78399
|
+
var import_node_crypto50, import_node_fs82, import_node_path82, PACKAGE_RECIPE;
|
|
78385
78400
|
var init_swift_package_prebuilt = __esm({
|
|
78386
78401
|
"src/swift-package-prebuilt.ts"() {
|
|
78387
78402
|
"use strict";
|
|
78388
|
-
|
|
78403
|
+
import_node_crypto50 = require("node:crypto");
|
|
78389
78404
|
import_node_fs82 = __toESM(require("node:fs"), 1);
|
|
78390
78405
|
import_node_path82 = __toESM(require("node:path"), 1);
|
|
78391
78406
|
init_native_prebuilt();
|
|
@@ -78545,7 +78560,7 @@ function swiftObjCSelectorOptions(moduleRoot) {
|
|
|
78545
78560
|
`;
|
|
78546
78561
|
if (!(0, import_node_fs83.existsSync)(map2) || (0, import_node_fs83.readFileSync)(map2, "utf8") !== content) {
|
|
78547
78562
|
(0, import_node_fs83.mkdirSync)(import_node_path83.default.dirname(map2), { recursive: true });
|
|
78548
|
-
const partial = `${map2}.${(0,
|
|
78563
|
+
const partial = `${map2}.${(0, import_node_crypto51.randomUUID)()}`;
|
|
78549
78564
|
(0, import_node_fs83.writeFileSync)(partial, content);
|
|
78550
78565
|
(0, import_node_fs83.renameSync)(partial, map2);
|
|
78551
78566
|
}
|
|
@@ -78573,7 +78588,7 @@ async function ensureMacroPlugins(moduleRoot, toolchainBin, release, signal, lea
|
|
|
78573
78588
|
return { libraries, executables };
|
|
78574
78589
|
}
|
|
78575
78590
|
function swiftProjectBuildKey(moduleRoot, release) {
|
|
78576
|
-
return (0,
|
|
78591
|
+
return (0, import_node_crypto51.createHash)("sha256").update(`swift-framework/v2\0${release}\0${swiftModuleSdk(moduleRoot).wasmSdkId}`).update(swiftModuleDigest(moduleRoot)).digest("hex").slice(0, 32);
|
|
78577
78592
|
}
|
|
78578
78593
|
function sameStringList(left, right) {
|
|
78579
78594
|
if (left === right) return true;
|
|
@@ -78821,7 +78836,7 @@ function distributionClangModuleOptions(root, modules) {
|
|
|
78821
78836
|
function providedModulesPath(root, modules, excluded) {
|
|
78822
78837
|
if (!excluded || excluded.size === 0) return modules;
|
|
78823
78838
|
const entries2 = (0, import_node_fs83.readdirSync)(modules).filter((entry) => !excluded.has(entry.replace(/\..*$/, ""))).sort();
|
|
78824
|
-
const key2 = (0,
|
|
78839
|
+
const key2 = (0, import_node_crypto51.createHash)("sha256").update(JSON.stringify([modules, entries2])).update([...excluded].sort().join("\0")).digest("hex").slice(0, 16);
|
|
78825
78840
|
const directory2 = import_node_path83.default.join(root, `.peach-modules-${key2}`);
|
|
78826
78841
|
const complete = import_node_path83.default.join(directory2, ".complete");
|
|
78827
78842
|
if (!(0, import_node_fs83.existsSync)(complete)) {
|
|
@@ -78903,10 +78918,10 @@ function swiftTargetDependencies(files2, targets, frameworks = OPTIONAL_FRAMEWOR
|
|
|
78903
78918
|
function sha256Digest(value) {
|
|
78904
78919
|
if (typeof Bun !== "undefined")
|
|
78905
78920
|
return new Bun.CryptoHasher("sha256").update(value).digest();
|
|
78906
|
-
return (0,
|
|
78921
|
+
return (0, import_node_crypto51.createHash)("sha256").update(value).digest();
|
|
78907
78922
|
}
|
|
78908
78923
|
function swiftCompileInputHash(input, release) {
|
|
78909
|
-
const hash = (0,
|
|
78924
|
+
const hash = (0, import_node_crypto51.createHash)("sha256");
|
|
78910
78925
|
hash.update(`swift-compile
|
|
78911
78926
|
${release}
|
|
78912
78927
|
`);
|
|
@@ -79113,7 +79128,7 @@ function emitSwiftPackageManifest(args) {
|
|
|
79113
79128
|
].join("\n") + "\n";
|
|
79114
79129
|
distributionLinkPath = distributionLink.path.replace(
|
|
79115
79130
|
/\.rsp$/,
|
|
79116
|
-
`-${(0,
|
|
79131
|
+
`-${(0, import_node_crypto51.createHash)("sha256").update(list2).digest("hex").slice(0, 12)}.rsp`
|
|
79117
79132
|
);
|
|
79118
79133
|
distributionLink.files.set(distributionLinkPath, list2);
|
|
79119
79134
|
}
|
|
@@ -79134,7 +79149,7 @@ function emitSwiftPackageManifest(args) {
|
|
|
79134
79149
|
const endRun = () => {
|
|
79135
79150
|
if (run18.length >= MODULE_MAP_RESPONSE_FILE_RUN) {
|
|
79136
79151
|
const lines = run18.map((flag) => JSON.stringify(flag)).join("\n") + "\n";
|
|
79137
|
-
const digest4 = (0,
|
|
79152
|
+
const digest4 = (0, import_node_crypto51.createHash)("sha256").update(lines).digest("hex");
|
|
79138
79153
|
const file2 = import_node_path83.default.join(args.root, ".peach-clang-arguments", `${digest4}.rsp`);
|
|
79139
79154
|
args.files.set(file2, lines);
|
|
79140
79155
|
flags.push(`@${file2}`);
|
|
@@ -79158,7 +79173,7 @@ function emitSwiftPackageManifest(args) {
|
|
|
79158
79173
|
}
|
|
79159
79174
|
endRun();
|
|
79160
79175
|
const content = JSON.stringify(flags);
|
|
79161
|
-
const digest3 = (0,
|
|
79176
|
+
const digest3 = (0, import_node_crypto51.createHash)("sha256").update(content).digest("hex");
|
|
79162
79177
|
const file = import_node_path83.default.join(args.root, ".peach-manifest-arguments", `${digest3}.json`);
|
|
79163
79178
|
args.files.set(file, content);
|
|
79164
79179
|
return `peachCompilerArguments(${JSON.stringify(file)})`;
|
|
@@ -79170,7 +79185,7 @@ function emitSwiftPackageManifest(args) {
|
|
|
79170
79185
|
const macros = compactSwiftClangDefines(swiftClangSearchArguments(flags));
|
|
79171
79186
|
const compact = args.coalescibleOverlays ? compactSwiftClangOverlays(macros, args.coalescibleOverlays) : macros;
|
|
79172
79187
|
const content = compact.map((flag) => JSON.stringify(flag)).join("\n") + "\n";
|
|
79173
|
-
const digest3 = (0,
|
|
79188
|
+
const digest3 = (0, import_node_crypto51.createHash)("sha256").update(content).digest("hex");
|
|
79174
79189
|
const file = import_node_path83.default.join(args.root, ".peach-swift-arguments", `${digest3}.rsp`);
|
|
79175
79190
|
args.files.set(file, content);
|
|
79176
79191
|
return JSON.stringify([`@${file}`]);
|
|
@@ -80759,7 +80774,7 @@ ${swiftProjectFilesProblems(input.projectFiles).join("\n")}`
|
|
|
80759
80774
|
)
|
|
80760
80775
|
];
|
|
80761
80776
|
const moduleFlag = perFile.some((flag) => flag.startsWith("-fmodule-name=")) ? [] : [`-fmodule-name=${swiftTargetModuleName(target.name)}`];
|
|
80762
|
-
const identity2 = (0,
|
|
80777
|
+
const identity2 = (0, import_node_crypto51.createHash)("sha256").update(
|
|
80763
80778
|
JSON.stringify([
|
|
80764
80779
|
cxx,
|
|
80765
80780
|
quoteDirs,
|
|
@@ -81122,7 +81137,7 @@ module ${moduleName2}.Swift {
|
|
|
81122
81137
|
])
|
|
81123
81138
|
(0, import_node_fs83.rmSync)(cache, { recursive: true, force: true });
|
|
81124
81139
|
files2.set(frameworkSearchRecord, frameworkSearch);
|
|
81125
|
-
const modulePlan = (0,
|
|
81140
|
+
const modulePlan = (0, import_node_crypto51.createHash)("sha256").update(
|
|
81126
81141
|
swiftModuleInputFiles(moduleRoot).join("\n")
|
|
81127
81142
|
);
|
|
81128
81143
|
if (!distribution) {
|
|
@@ -81131,7 +81146,7 @@ module ${moduleName2}.Swift {
|
|
|
81131
81146
|
modulePlan.update(
|
|
81132
81147
|
Object.keys(input.files).filter((file) => file.endsWith(".swift")).sort().join("\n")
|
|
81133
81148
|
);
|
|
81134
|
-
const resourcePlan = (0,
|
|
81149
|
+
const resourcePlan = (0, import_node_crypto51.createHash)("sha256").update(
|
|
81135
81150
|
JSON.stringify(
|
|
81136
81151
|
resourceTargets.filter((target) => target.resources).map((target) => [
|
|
81137
81152
|
target.name,
|
|
@@ -81439,7 +81454,7 @@ ${entry}`);
|
|
|
81439
81454
|
);
|
|
81440
81455
|
for (const [target, data] of Object.entries(input.libraries ?? {})) {
|
|
81441
81456
|
const bytes = Buffer.from(data, "base64");
|
|
81442
|
-
const digest3 = (0,
|
|
81457
|
+
const digest3 = (0, import_node_crypto51.createHash)("sha256").update(bytes).digest("hex");
|
|
81443
81458
|
if (input.binaryModules?.[target] && packageTargets.has(target)) {
|
|
81444
81459
|
const objects = import_node_path83.default.join(
|
|
81445
81460
|
layout2.root,
|
|
@@ -82091,7 +82106,7 @@ function readCompiledArtifact(directory2, hash) {
|
|
|
82091
82106
|
return null;
|
|
82092
82107
|
const bytes = (0, import_node_fs83.readFileSync)(import_node_path83.default.join(directory2, "app.wasm"));
|
|
82093
82108
|
const gzip2 = (0, import_node_fs83.readFileSync)(import_node_path83.default.join(directory2, "icu.gz"));
|
|
82094
|
-
if ((0,
|
|
82109
|
+
if ((0, import_node_crypto51.createHash)("sha256").update(bytes).digest("hex") !== receipt.wasm || (0, import_node_crypto51.createHash)("sha256").update(gzip2).digest("hex") !== receipt.icu || bytes.length <= 8 || bytes.readUInt32LE(0) !== 1836278016 || bytes.readUInt32LE(4) !== 1)
|
|
82095
82110
|
return null;
|
|
82096
82111
|
let sdk2;
|
|
82097
82112
|
if ("sdk" in receipt) {
|
|
@@ -82099,7 +82114,7 @@ function readCompiledArtifact(directory2, hash) {
|
|
|
82099
82114
|
if (!isRecord(image) || typeof image.key !== "string" || typeof image.sha256 !== "string" || typeof image.binding !== "string")
|
|
82100
82115
|
return null;
|
|
82101
82116
|
const binding = (0, import_node_fs83.readFileSync)(import_node_path83.default.join(directory2, "sdk-binding.bin"));
|
|
82102
|
-
if ((0,
|
|
82117
|
+
if ((0, import_node_crypto51.createHash)("sha256").update(binding).digest("hex") !== image.binding)
|
|
82103
82118
|
return null;
|
|
82104
82119
|
sdk2 = {
|
|
82105
82120
|
key: image.key,
|
|
@@ -82127,7 +82142,7 @@ function saveCompiledArtifact(root, artifact) {
|
|
|
82127
82142
|
import_node_path83.default.join(pending2, "artifact.json"),
|
|
82128
82143
|
JSON.stringify({
|
|
82129
82144
|
hash: artifact.hash,
|
|
82130
|
-
wasm: (0,
|
|
82145
|
+
wasm: (0, import_node_crypto51.createHash)("sha256").update(artifact.bytes).digest("hex"),
|
|
82131
82146
|
icu: artifact.icu.sha256,
|
|
82132
82147
|
sdk: artifact.sdk && {
|
|
82133
82148
|
key: artifact.sdk.key,
|
|
@@ -82476,7 +82491,7 @@ async function buildFrameworkProducts(scratch2, args) {
|
|
|
82476
82491
|
const unoptimized = args.input.unoptimized === true;
|
|
82477
82492
|
const sdkOptions = swiftCompileSdkOptions(args.moduleRoot, args.toolchainBin);
|
|
82478
82493
|
const selectorOptions = swiftObjCSelectorOptions(args.moduleRoot);
|
|
82479
|
-
const receiptKey = (0,
|
|
82494
|
+
const receiptKey = (0, import_node_crypto51.createHash)("sha256").update(
|
|
82480
82495
|
JSON.stringify([
|
|
82481
82496
|
"framework-products/v2",
|
|
82482
82497
|
args.frameworkKey,
|
|
@@ -82643,7 +82658,7 @@ async function buildFrameworkProducts(scratch2, args) {
|
|
|
82643
82658
|
const archiveBase = import_node_path83.default.join(scratch2, "products-lib");
|
|
82644
82659
|
(0, import_node_fs83.mkdirSync)(archiveBase, { recursive: true });
|
|
82645
82660
|
const archiveRoot = import_node_path83.default.join(archiveBase, receiptKey);
|
|
82646
|
-
const stagedArchiveRoot = `${archiveRoot}.tmp-${process.pid}-${(0,
|
|
82661
|
+
const stagedArchiveRoot = `${archiveRoot}.tmp-${process.pid}-${(0, import_node_crypto51.randomUUID)()}`;
|
|
82647
82662
|
const stagedArchive = import_node_path83.default.join(stagedArchiveRoot, "lib");
|
|
82648
82663
|
(0, import_node_fs83.mkdirSync)(stagedArchive, { recursive: true });
|
|
82649
82664
|
const archived = /* @__PURE__ */ new Map();
|
|
@@ -82686,7 +82701,7 @@ ${args.frameworkKey}`,
|
|
|
82686
82701
|
const receiptsDir = import_node_path83.default.join(scratch2, "products-ready");
|
|
82687
82702
|
(0, import_node_fs83.mkdirSync)(receiptsDir, { recursive: true });
|
|
82688
82703
|
const receiptFile2 = import_node_path83.default.join(receiptsDir, `${receiptKey}.json`);
|
|
82689
|
-
const partialReceipt = `${receiptFile2}.${process.pid}.${(0,
|
|
82704
|
+
const partialReceipt = `${receiptFile2}.${process.pid}.${(0, import_node_crypto51.randomUUID)()}`;
|
|
82690
82705
|
(0, import_node_fs83.writeFileSync)(
|
|
82691
82706
|
partialReceipt,
|
|
82692
82707
|
JSON.stringify({
|
|
@@ -82858,7 +82873,7 @@ function mirrorTree2(source, target, skip) {
|
|
|
82858
82873
|
if (existing?.isFile() && existing.size === stat2.size && (existing.mtimeMs === stat2.mtimeMs || (0, import_node_fs83.readFileSync)(from).equals((0, import_node_fs83.readFileSync)(to))))
|
|
82859
82874
|
continue;
|
|
82860
82875
|
if (existing) (0, import_node_fs83.rmSync)(to, { recursive: true, force: true });
|
|
82861
|
-
const partial = `${to}.${(0,
|
|
82876
|
+
const partial = `${to}.${(0, import_node_crypto51.randomUUID)()}`;
|
|
82862
82877
|
(0, import_node_fs83.copyFileSync)(from, partial);
|
|
82863
82878
|
if (stat2.mtimeMs > Date.now()) (0, import_node_fs83.utimesSync)(partial, stat2.atime, stat2.mtime);
|
|
82864
82879
|
(0, import_node_fs83.renameSync)(partial, to);
|
|
@@ -82918,7 +82933,7 @@ function stageFrameworkSource(moduleRoot, slot, frameworkKey, release) {
|
|
|
82918
82933
|
return stagedModule;
|
|
82919
82934
|
}
|
|
82920
82935
|
function swiftLinkStamp(args) {
|
|
82921
|
-
const hash = (0,
|
|
82936
|
+
const hash = (0, import_node_crypto51.createHash)("sha256");
|
|
82922
82937
|
hash.update(`swift-link/v1
|
|
82923
82938
|
${args.frameworkKey}
|
|
82924
82939
|
`);
|
|
@@ -83046,7 +83061,7 @@ async function compileSwiftProjectOnce(sources, options2) {
|
|
|
83046
83061
|
const inputHash = swiftCompileInputHash(input, options2.release);
|
|
83047
83062
|
const moduleDigest = swiftModuleDigest(moduleRoot);
|
|
83048
83063
|
const sourceHash = inputHash.copy().update(moduleDigest).digest("hex");
|
|
83049
|
-
const hash = sdkImage ? (0,
|
|
83064
|
+
const hash = sdkImage ? (0, import_node_crypto51.createHash)("sha256").update(`${sourceHash}
|
|
83050
83065
|
sdk module ${sdkImage.key}`).digest("hex") : sourceHash;
|
|
83051
83066
|
const frameworkKey = swiftProjectBuildKey(moduleRoot, options2.release);
|
|
83052
83067
|
const sharedRoot = import_node_path83.default.join(swiftCacheDir(), "swift-projects", hash);
|
|
@@ -83143,7 +83158,7 @@ ${cap}` : "";
|
|
|
83143
83158
|
}
|
|
83144
83159
|
const baseRoot = root;
|
|
83145
83160
|
const canPoolBuildRoot = !options2.intermediates && !options2.project && !options2.linkOnly && import_node_path83.default.basename(import_node_path83.default.dirname(baseRoot)) === "swift-builds";
|
|
83146
|
-
const buildShape = canPoolBuildRoot ? (0,
|
|
83161
|
+
const buildShape = canPoolBuildRoot ? (0, import_node_crypto51.createHash)("sha256").update(
|
|
83147
83162
|
JSON.stringify([
|
|
83148
83163
|
frameworkKey,
|
|
83149
83164
|
Boolean(sdkImage),
|
|
@@ -83632,17 +83647,17 @@ ${cap}` : "";
|
|
|
83632
83647
|
}
|
|
83633
83648
|
const receipt = import_node_path83.default.join(
|
|
83634
83649
|
checkpoints,
|
|
83635
|
-
(0,
|
|
83650
|
+
(0, import_node_crypto51.createHash)("sha256").update(target).digest("hex")
|
|
83636
83651
|
);
|
|
83637
83652
|
const headers = producers.map(headerPaths);
|
|
83638
83653
|
for (const header of headers)
|
|
83639
83654
|
if ((0, import_node_fs83.existsSync)(header.original)) publishHeader(header);
|
|
83640
83655
|
const fingerprint = () => {
|
|
83641
|
-
const digest3 = (0,
|
|
83656
|
+
const digest3 = (0, import_node_crypto51.createHash)("sha256").update(recipe2);
|
|
83642
83657
|
for (const { original, emitted } of headers) {
|
|
83643
83658
|
if (!(0, import_node_fs83.existsSync)(original) || !(0, import_node_fs83.existsSync)(emitted)) return;
|
|
83644
83659
|
digest3.update(
|
|
83645
|
-
(0,
|
|
83660
|
+
(0, import_node_crypto51.createHash)("sha256").update((0, import_node_fs83.readFileSync)(emitted)).digest()
|
|
83646
83661
|
);
|
|
83647
83662
|
}
|
|
83648
83663
|
return digest3.digest("hex");
|
|
@@ -83855,12 +83870,12 @@ ${cap}` : "";
|
|
|
83855
83870
|
options2.signal
|
|
83856
83871
|
);
|
|
83857
83872
|
}
|
|
83858
|
-
var import_node_child_process45,
|
|
83873
|
+
var import_node_child_process45, import_node_crypto51, import_node_fs83, import_node_os18, import_node_path83, v6, WASM_TRIPLE, SWIFTPM_PROGRESS, SWIFTPM_NOISE, SWIFT_COMPILER_ENV_KEYS, SYSTEM_MODULE_LIBRARIES, SYSTEM_MODULE_IMPORT, lastPartition, OPTIONAL_FRAMEWORK_DEPENDENCIES, OPTIONAL_FRAMEWORKS, availableModules, sdkOverlayFrameworks, DISTRIBUTION_CLANG_MODULES, CLANG_DISTRIBUTION_MODULES, ONE_PRODUCT, GAME_FAMILY, gameProducts, gameProduct, GAME_REACH, ONE_IMPLICIT_FLAGS, executableLinkFlags, darwinRecordsRegion, REACTOR_FLAG, MULTI_MANIFEST_VERSION, SWIFT_HEADER_PRODUCTS_TARGET, compilerSourceDigest, nativeCxxCompilerFlags, MODULE_MAP_RESPONSE_FILE_RUN, cFlagArray, cxxFlagArray, SWIFTPM_DEFAULT_IOS_DEPLOYMENT_TARGET, OS_IOS, ARCH_ARM64, NOT_ON_IOS, DELEGATE_CLASS, ARM64_MACRO, WASM_MACRO, ARCH_WASM32, C_WORDS, archEnvironments, CORE_FOUNDATION_GEOMETRY_TYPES, CORE_FOUNDATION_GRAPHICS_TYPES, CORE_FOUNDATION_HANDLE_IMPORTS, cPredefineTable, cPredefineCache, HIDDEN_UNITS, FIRST_WINS_PAIRS, LAST_WINS_PAIRS, VALUE_FLAGS, LIBXML_REFERENCE, LIBXML_SOURCE, ROOT_LOCKS, host, rootLocks, SHARED_ARTIFACT_BUDGET_BYTES, SHARED_ARTIFACT_GRACE_MS, RETIRED_PREFIX, retainedArtifacts, FRAMEWORK_LINK_TARGET, frameworkProductsReceiptSchema, SWIFT_LINK_STAMP, SWIFT_HOST_COMPILER_WRAPPER, SWIFT_FRAMEWORK_SLOTS, SWIFT_FRAMEWORK_UNOPTIMIZED_SLOTS, SWIFT_FRAMEWORK_SLOT_KEY, SWIFT_FRAMEWORK_SLOT_ORIGIN, SWIFT_FRAMEWORK_SLOT_RELEASE, SWIFT_BUILD_ROOT_SLOTS, SWIFT_BUILD_ROOT_SHAPE;
|
|
83859
83874
|
var init_swift_compile = __esm({
|
|
83860
83875
|
"src/swift-compile.ts"() {
|
|
83861
83876
|
"use strict";
|
|
83862
83877
|
import_node_child_process45 = require("node:child_process");
|
|
83863
|
-
|
|
83878
|
+
import_node_crypto51 = require("node:crypto");
|
|
83864
83879
|
import_node_fs83 = require("node:fs");
|
|
83865
83880
|
import_node_os18 = __toESM(require("node:os"), 1);
|
|
83866
83881
|
import_node_path83 = __toESM(require("node:path"), 1);
|
|
@@ -84088,7 +84103,7 @@ ${wasmThreadLinkFlags.map((flag) => ` "-Xlinker", ${JSON.stringify(flag
|
|
|
84088
84103
|
REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
|
|
84089
84104
|
MULTI_MANIFEST_VERSION = 76;
|
|
84090
84105
|
SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
|
|
84091
|
-
compilerSourceDigest = true ? "
|
|
84106
|
+
compilerSourceDigest = true ? "169122685e250113f128b79efc78f9868f581da36ab083c174056ab99b87b629" : swiftCompilerSourceDigest2(__sootsim_import_meta_dirname);
|
|
84092
84107
|
nativeCxxCompilerFlags = ["-fno-cxx-modules"];
|
|
84093
84108
|
MODULE_MAP_RESPONSE_FILE_RUN = 16;
|
|
84094
84109
|
cFlagArray = (flags) => JSON.stringify(withoutGlogModuleMap(flags));
|
|
@@ -84204,7 +84219,7 @@ async function podPrepareEnvironment(base2) {
|
|
|
84204
84219
|
if (process.platform !== "linux") return base2;
|
|
84205
84220
|
const { root, toolchainBin } = await resolveSwiftModule();
|
|
84206
84221
|
const { sysroot, resources } = swiftSdkPaths(root, toolchainBin);
|
|
84207
|
-
const key2 = (0,
|
|
84222
|
+
const key2 = (0, import_node_crypto52.createHash)("sha256").update(XCRUN).update(CLANG).digest("hex").slice(0, 16);
|
|
84208
84223
|
const directory2 = import_node_path84.default.join(cacheDir(), "pod-tools", key2);
|
|
84209
84224
|
if (!import_node_fs84.default.existsSync(directory2)) {
|
|
84210
84225
|
import_node_fs84.default.mkdirSync(import_node_path84.default.dirname(directory2), { recursive: true });
|
|
@@ -84245,11 +84260,11 @@ async function podPrepareEnvironment(base2) {
|
|
|
84245
84260
|
PEACH_POD_RESOURCES: resources
|
|
84246
84261
|
};
|
|
84247
84262
|
}
|
|
84248
|
-
var
|
|
84263
|
+
var import_node_crypto52, import_node_fs84, import_node_path84, XCRUN, CLANG;
|
|
84249
84264
|
var init_pod_prepare_toolchain = __esm({
|
|
84250
84265
|
"src/pod-prepare-toolchain.ts"() {
|
|
84251
84266
|
"use strict";
|
|
84252
|
-
|
|
84267
|
+
import_node_crypto52 = require("node:crypto");
|
|
84253
84268
|
import_node_fs84 = __toESM(require("node:fs"), 1);
|
|
84254
84269
|
import_node_path84 = __toESM(require("node:path"), 1);
|
|
84255
84270
|
init_home_paths();
|
|
@@ -84335,10 +84350,10 @@ async function podSourceRoot(spec, prepareEnv) {
|
|
|
84335
84350
|
`${name3}: unrecognized ${strategy} source options ${unrecognized.join(", ")}`
|
|
84336
84351
|
);
|
|
84337
84352
|
const base2 = import_node_path85.default.join(rnxHomeDir(), "pod-sources");
|
|
84338
|
-
const digest3 = (0,
|
|
84353
|
+
const digest3 = (0, import_node_crypto53.createHash)("sha256").update(canonicalJson(source)).digest("hex").slice(0, 16);
|
|
84339
84354
|
const root = import_node_path85.default.join(base2, name3, `${String(spec.version)}-${digest3}`);
|
|
84340
84355
|
if (import_node_fs85.default.existsSync(root)) return root;
|
|
84341
|
-
const stage = import_node_path85.default.join(base2, ".staging", (0,
|
|
84356
|
+
const stage = import_node_path85.default.join(base2, ".staging", (0, import_node_crypto53.randomUUID)());
|
|
84342
84357
|
import_node_fs85.default.mkdirSync(stage, { recursive: true });
|
|
84343
84358
|
try {
|
|
84344
84359
|
if (strategy === "git") await downloadGit(name3, url, options2, stage);
|
|
@@ -84513,7 +84528,7 @@ async function downloadFile(pod, url, headers, file, algorithm) {
|
|
|
84513
84528
|
}
|
|
84514
84529
|
if (!response?.ok || !response.body)
|
|
84515
84530
|
throw new Error(`${pod}: GET ${url} failed with HTTP ${response?.status ?? "error"}`);
|
|
84516
|
-
const hash = algorithm ? (0,
|
|
84531
|
+
const hash = algorithm ? (0, import_node_crypto53.createHash)(algorithm) : null;
|
|
84517
84532
|
const handle = await import_node_fs85.default.promises.open(file, "w");
|
|
84518
84533
|
try {
|
|
84519
84534
|
const reader = response.body.getReader();
|
|
@@ -84770,12 +84785,12 @@ function cleanInstalledPod(spec, root, used) {
|
|
|
84770
84785
|
(node) => used.filter((entry) => entry.specs.includes(node.name)).map((entry) => entry.platform)
|
|
84771
84786
|
);
|
|
84772
84787
|
}
|
|
84773
|
-
var import_node_child_process46,
|
|
84788
|
+
var import_node_child_process46, import_node_crypto53, import_node_fs85, import_node_os19, import_node_path85, COCOAPODS_VERSION, USER_AGENT, PLATFORMS, HEADER_EXTENSIONS, SOURCE_EXTENSIONS2, SOURCE_FILES_PATTERN, STRATEGIES, OPTIONS, ARCHIVE_TYPES, object5, RETRY_STATUSES, chomp, stringList, bracketEnd, escapeRegex;
|
|
84774
84789
|
var init_pod_sources = __esm({
|
|
84775
84790
|
"src/pod-sources.ts"() {
|
|
84776
84791
|
"use strict";
|
|
84777
84792
|
import_node_child_process46 = require("node:child_process");
|
|
84778
|
-
|
|
84793
|
+
import_node_crypto53 = require("node:crypto");
|
|
84779
84794
|
import_node_fs85 = __toESM(require("node:fs"), 1);
|
|
84780
84795
|
import_node_os19 = __toESM(require("node:os"), 1);
|
|
84781
84796
|
import_node_path85 = __toESM(require("node:path"), 1);
|
|
@@ -84859,7 +84874,7 @@ function specRepo(url, refresh) {
|
|
|
84859
84874
|
const dir = import_node_path86.default.join(
|
|
84860
84875
|
cacheDir(),
|
|
84861
84876
|
"cocoapods-repos",
|
|
84862
|
-
(0,
|
|
84877
|
+
(0, import_node_crypto54.createHash)("sha256").update(url).digest("hex").slice(0, 16)
|
|
84863
84878
|
);
|
|
84864
84879
|
if (!import_node_fs86.default.existsSync(import_node_path86.default.join(dir, ".git"))) {
|
|
84865
84880
|
const staged = `${dir}.${process.pid}`;
|
|
@@ -84889,7 +84904,7 @@ function podDir(repo, name3) {
|
|
|
84889
84904
|
const specs = import_node_fs86.default.existsSync(import_node_path86.default.join(repo, "Specs")) ? import_node_path86.default.join(repo, "Specs") : repo;
|
|
84890
84905
|
const metadata = import_node_path86.default.join(repo, "CocoaPods-version.yml");
|
|
84891
84906
|
const lengths = import_node_fs86.default.existsSync(metadata) ? browser_default.parse(import_node_fs86.default.readFileSync(metadata, "utf8"))?.prefix_lengths : void 0;
|
|
84892
|
-
const hash = (0,
|
|
84907
|
+
const hash = (0, import_node_crypto54.createHash)("md5").update(name3).digest("hex");
|
|
84893
84908
|
let at = 0;
|
|
84894
84909
|
const shards2 = (Array.isArray(lengths) ? lengths : []).map((length) => {
|
|
84895
84910
|
if (typeof length !== "number")
|
|
@@ -84922,17 +84937,17 @@ async function sourceSpecificationFile(source, name3, version2) {
|
|
|
84922
84937
|
if (!file) throw new Error(`${source} lists ${name3} ${version2} without a podspec`);
|
|
84923
84938
|
return file;
|
|
84924
84939
|
}
|
|
84925
|
-
var import_node_child_process47,
|
|
84940
|
+
var import_node_child_process47, import_node_crypto54, import_node_fs86, import_node_path86, shard, shards, TRUNK_SOURCES, refreshed, specRepoKey;
|
|
84926
84941
|
var init_cocoapods_trunk = __esm({
|
|
84927
84942
|
"src/cocoapods-trunk.ts"() {
|
|
84928
84943
|
"use strict";
|
|
84929
84944
|
import_node_child_process47 = require("node:child_process");
|
|
84930
|
-
|
|
84945
|
+
import_node_crypto54 = require("node:crypto");
|
|
84931
84946
|
import_node_fs86 = __toESM(require("node:fs"), 1);
|
|
84932
84947
|
import_node_path86 = __toESM(require("node:path"), 1);
|
|
84933
84948
|
init_browser();
|
|
84934
84949
|
init_home_paths();
|
|
84935
|
-
shard = (name3) => (0,
|
|
84950
|
+
shard = (name3) => (0, import_node_crypto54.createHash)("md5").update(name3).digest("hex").slice(0, 3).split("");
|
|
84936
84951
|
shards = /* @__PURE__ */ new Map();
|
|
84937
84952
|
TRUNK_SOURCES = /* @__PURE__ */ new Set([
|
|
84938
84953
|
"trunk",
|
|
@@ -94601,7 +94616,7 @@ end
|
|
|
94601
94616
|
function sha256Hex5(bytes) {
|
|
94602
94617
|
if (typeof Bun !== "undefined")
|
|
94603
94618
|
return new Bun.CryptoHasher("sha256").update(bytes).digest("hex");
|
|
94604
|
-
return (0,
|
|
94619
|
+
return (0, import_node_crypto55.createHash)("sha256").update(bytes).digest("hex");
|
|
94605
94620
|
}
|
|
94606
94621
|
function isBazelPackage(input) {
|
|
94607
94622
|
return /^BUILD(?:\.bazel)?$/.test(import_node_path96.default.basename(input)) && import_node_fs95.default.statSync(input).isFile();
|
|
@@ -94632,7 +94647,7 @@ function bazelBinary(root) {
|
|
|
94632
94647
|
const expected = (0, import_node_child_process48.execFileSync)("curl", ["-fsSL", `${url}.sha256`], {
|
|
94633
94648
|
encoding: "utf8"
|
|
94634
94649
|
}).split(/\s/)[0];
|
|
94635
|
-
const actual = (0,
|
|
94650
|
+
const actual = (0, import_node_crypto55.createHash)("sha256").update(import_node_fs95.default.readFileSync(partial)).digest("hex");
|
|
94636
94651
|
if (actual !== expected) {
|
|
94637
94652
|
import_node_fs95.default.rmSync(partial, { force: true });
|
|
94638
94653
|
throw new Error(`${url} digest ${actual} differs from its release ${expected}`);
|
|
@@ -94662,7 +94677,7 @@ function parseRule(raw2) {
|
|
|
94662
94677
|
};
|
|
94663
94678
|
}
|
|
94664
94679
|
function graphInputsDigest(root) {
|
|
94665
|
-
const hash = (0,
|
|
94680
|
+
const hash = (0, import_node_crypto55.createHash)("sha256");
|
|
94666
94681
|
const visit3 = (dir) => {
|
|
94667
94682
|
for (const entry of import_node_fs95.default.readdirSync(dir, { withFileTypes: true }).sort((a, b) => a.name.localeCompare(b.name))) {
|
|
94668
94683
|
if (entry.name.startsWith(".") || entry.name.startsWith("bazel-")) continue;
|
|
@@ -94695,7 +94710,7 @@ function bazelGraph(root, label, configuration2) {
|
|
|
94695
94710
|
const cached5 = graphs.get(key2);
|
|
94696
94711
|
if (cached5) return cached5;
|
|
94697
94712
|
const flags = configurationFlags(configuration2);
|
|
94698
|
-
const digest3 = (0,
|
|
94713
|
+
const digest3 = (0, import_node_crypto55.createHash)("sha256").update(JSON.stringify([GRAPH_FORMAT, label, flags, QUERIED_RULES])).update(graphInputsDigest(root)).digest("hex").slice(0, 24);
|
|
94699
94714
|
const file = import_node_path96.default.join(root, ".build", "peach-bazel", `graph-${digest3}.json`);
|
|
94700
94715
|
const bazel = bazelBinary(root);
|
|
94701
94716
|
const run18 = (args) => (0, import_node_child_process48.execFileSync)(bazel, args, {
|
|
@@ -95519,12 +95534,12 @@ function shellTokens(options2) {
|
|
|
95519
95534
|
return words2;
|
|
95520
95535
|
});
|
|
95521
95536
|
}
|
|
95522
|
-
var import_node_child_process48,
|
|
95537
|
+
var import_node_child_process48, import_node_crypto55, import_node_fs95, import_node_os20, import_node_path96, LIBRARY_RULES, QUERIED_RULES, NATIVE_SOURCE, HEADER4, PRODUCTS, graphs, CLANG_CONFIGURATION_FLAGS, GRAPH_FORMAT, BazelFiles, CXX_STANDARD;
|
|
95523
95538
|
var init_bazel_project = __esm({
|
|
95524
95539
|
"src/bazel-project.ts"() {
|
|
95525
95540
|
"use strict";
|
|
95526
95541
|
import_node_child_process48 = require("node:child_process");
|
|
95527
|
-
|
|
95542
|
+
import_node_crypto55 = require("node:crypto");
|
|
95528
95543
|
import_node_fs95 = __toESM(require("node:fs"), 1);
|
|
95529
95544
|
import_node_os20 = __toESM(require("node:os"), 1);
|
|
95530
95545
|
import_node_path96 = __toESM(require("node:path"), 1);
|
|
@@ -97178,7 +97193,7 @@ async function swiftBinaryModules(binary2) {
|
|
|
97178
97193
|
if (!binary2.url) return localSwiftBinaryModules(binary2.dir);
|
|
97179
97194
|
const cached5 = import_node_path97.default.join(
|
|
97180
97195
|
cacheDir3,
|
|
97181
|
-
`${(0,
|
|
97196
|
+
`${(0, import_node_crypto56.createHash)("sha256").update(`${binary2.url}\0${binary2.checksum ?? ""}`).digest("hex").slice(0, 32)}.json`
|
|
97182
97197
|
);
|
|
97183
97198
|
if (import_node_fs96.default.existsSync(cached5)) {
|
|
97184
97199
|
const value = JSON.parse(import_node_fs96.default.readFileSync(cached5, "utf8"));
|
|
@@ -97190,11 +97205,11 @@ async function swiftBinaryModules(binary2) {
|
|
|
97190
97205
|
import_node_fs96.default.writeFileSync(cached5, JSON.stringify(modules));
|
|
97191
97206
|
return modules;
|
|
97192
97207
|
}
|
|
97193
|
-
var
|
|
97208
|
+
var import_node_crypto56, import_node_fs96, import_node_path97, cacheDir3;
|
|
97194
97209
|
var init_swift_binary_modules = __esm({
|
|
97195
97210
|
"src/swift-binary-modules.ts"() {
|
|
97196
97211
|
"use strict";
|
|
97197
|
-
|
|
97212
|
+
import_node_crypto56 = require("node:crypto");
|
|
97198
97213
|
import_node_fs96 = __toESM(require("node:fs"), 1);
|
|
97199
97214
|
import_node_path97 = __toESM(require("node:path"), 1);
|
|
97200
97215
|
init_home_paths();
|
|
@@ -97204,11 +97219,11 @@ var init_swift_binary_modules = __esm({
|
|
|
97204
97219
|
});
|
|
97205
97220
|
|
|
97206
97221
|
// src/swift-coverage/provenance.ts
|
|
97207
|
-
var
|
|
97222
|
+
var import_node_crypto57, import_node_fs97, import_node_path98, swiftCoverageProvenance;
|
|
97208
97223
|
var init_provenance = __esm({
|
|
97209
97224
|
"src/swift-coverage/provenance.ts"() {
|
|
97210
97225
|
"use strict";
|
|
97211
|
-
|
|
97226
|
+
import_node_crypto57 = require("node:crypto");
|
|
97212
97227
|
import_node_fs97 = require("node:fs");
|
|
97213
97228
|
import_node_path98 = require("node:path");
|
|
97214
97229
|
swiftCoverageProvenance = true ? JSON.parse('{"swift-coverage/indexdump.ts":"0d82d8eeb96bf377f409ea7e33274c341a710c0e071f6b6e17571a23d8d92412","swift-coverage/indexing.ts":"633ccf19eec1f382a8847d0ee1dca42a2792a3c60aafd43622ed5152b09b8272","swift-coverage/types.ts":"bd8fae54ea6c53e110cd8a5d7b57c1d532dd0166e09fdaea63c4f270c3780dd1","swift-coverage/source.ts":"c151758a9f67631bc61473c375df0dc017da6902a34533b2cf4fc4fd7d19b6ee","swift-coverage/package.ts":"1f0068be7461fa7c5a7a891faf318f305cbed2e94c19667ba76627f7e5be260b","swift-coverage/xcode.ts":"d6a3228567a46c6d5280895383093889d9b868958a117881061bdd74729a225f","swift-coverage/xcode-assets.ts":"d98d6294b359528f7733b26db6f80f554782354faa235605f9562be4ad98b8a3","swift-coverage/xcode-asset-symbols.ts":"1b2a67733bc9d139b351466270205452a6172140bc25080d72619e2952c44671","swift-coverage/xcode-bridging.ts":"33184be8c5daf6646aa5a1276a4e15531f1be27b7c26f56550e0fbb1fc678a11","swift-coverage/xcode-packages.ts":"5c83f56357d880243ab485b260d23abd0094583ffa2287dac6e9e7eb18c3673d","swift-coverage/xcode-strings.ts":"facdbeb9de6bb12da4ab4954553edfaadd0e486f1181443138be70c3d8396236","swift-coverage/reader.ts":"da559b67ecd1161dea70c980b5f98f2c55af3550f0714479100fa5e9e813625c","swift-coverage/provenance.ts":"f5039c16e63c6129e22b71203f58982c68cef6e282a4f236b93da28edd39c108","swift-package-manifest.ts":"523fdfffc0cff95c8df7beeca437622a07d4fd666f0bb22b0ff67d14c42a7b10","swift-package.ts":"05c6cf101fbc944f6684a70db0a9c5aede846b2f0482a6b4a5a0abed737d4658","swift-source-file.ts":"8becce5e73b76a61d9d202c1ecfb39b1238e9bbf0e77841f1c51c98fa9ac7bd3","swift-toolchain.ts":"32bf10d6f3396dd1a20ff6d415499a5990ec2550c63306fd9ef071bdf4a58f1e","home-paths.ts":"d1606390f0e8e50f0ff72544eadb3d49dfabf08e004c1218f2998c36fb8995dd","xcode-header-search.ts":"c72b724fc497e4cf603c355f86eb3c07c929ad299758cffbc6ff88ed241654c6","xcode-project.ts":"e30510099ee19d34de62d8ae859df53f77594a4ab105fdb5bcd7e005ec9689ca","xcode-target-members.ts":"96f6a9f5567a4fbd9806252229b35b9a451a112b20f70f8c20189ffd428815fd","xcode-json-project.ts":"df6d6db28e0c8cfdf1f480e1e32d35f12c9cf1936642d5dda923889fb18a8fd6","openstep-plist.ts":"da11f86885ef1e25979ad989f332195c113c4b7a43f108e8d36646973430b81b"}') : swiftCoverageSourceDigests((0, import_node_path98.join)(__sootsim_import_meta_dirname, ".."));
|
|
@@ -98305,16 +98320,16 @@ function assetSymbolText(plan, root) {
|
|
|
98305
98320
|
if (source.status === "unknown") throw new Error(source.reason);
|
|
98306
98321
|
return source.text;
|
|
98307
98322
|
}
|
|
98308
|
-
var
|
|
98323
|
+
var import_node_crypto58, import_node_fs99, import_node_path100, sha2562, unprovenAssetSettings, assetSymbolSettingKeys, provenOtherAssetFlags, symbolTexts;
|
|
98309
98324
|
var init_xcode_assets = __esm({
|
|
98310
98325
|
"src/swift-coverage/xcode-assets.ts"() {
|
|
98311
98326
|
"use strict";
|
|
98312
|
-
|
|
98327
|
+
import_node_crypto58 = require("node:crypto");
|
|
98313
98328
|
import_node_fs99 = require("node:fs");
|
|
98314
98329
|
import_node_path100 = require("node:path");
|
|
98315
98330
|
init_provenance();
|
|
98316
98331
|
init_xcode_asset_symbols();
|
|
98317
|
-
sha2562 = (bytes) => (0,
|
|
98332
|
+
sha2562 = (bytes) => (0, import_node_crypto58.createHash)("sha256").update(bytes).digest("hex");
|
|
98318
98333
|
unprovenAssetSettings = [
|
|
98319
98334
|
"ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOL_FRAMEWORKS",
|
|
98320
98335
|
"ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOL_WARNINGS",
|
|
@@ -98910,7 +98925,7 @@ function normalizedEnums(input) {
|
|
|
98910
98925
|
}
|
|
98911
98926
|
function localizationIdentifier(field2, key2) {
|
|
98912
98927
|
const alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
|
98913
|
-
const digest3 = (0,
|
|
98928
|
+
const digest3 = (0, import_node_crypto59.createHash)("sha256").update(JSON.stringify([...field2, key2])).digest();
|
|
98914
98929
|
return Array.from(
|
|
98915
98930
|
digest3.subarray(0, 6),
|
|
98916
98931
|
(byte) => alphabet[byte % alphabet.length]
|
|
@@ -99235,12 +99250,12 @@ function writeIntentDefinition(input, prefix) {
|
|
|
99235
99250
|
lines.push("</plist>", "");
|
|
99236
99251
|
return lines.join("\n");
|
|
99237
99252
|
}
|
|
99238
|
-
var import_strict4,
|
|
99253
|
+
var import_strict4, import_node_crypto59, typeMetadata, initializeMetadata, widgetArraySizes, defaultReasonMessages;
|
|
99239
99254
|
var init_metadata = __esm({
|
|
99240
99255
|
"src/intent-definition/metadata.ts"() {
|
|
99241
99256
|
"use strict";
|
|
99242
99257
|
import_strict4 = __toESM(require("node:assert/strict"), 1);
|
|
99243
|
-
|
|
99258
|
+
import_node_crypto59 = require("node:crypto");
|
|
99244
99259
|
init_fields();
|
|
99245
99260
|
init_hash_input();
|
|
99246
99261
|
init_siphash();
|
|
@@ -99949,7 +99964,7 @@ function preparePortableIntent(definition2, derivedDirectory, prefix, language,
|
|
|
99949
99964
|
if (prefix) identifier(prefix);
|
|
99950
99965
|
if (module2) identifier(module2);
|
|
99951
99966
|
const source = import_node_fs100.default.readFileSync(definition2);
|
|
99952
|
-
const key2 = (0,
|
|
99967
|
+
const key2 = (0, import_node_crypto60.createHash)("sha256").update(
|
|
99953
99968
|
JSON.stringify([intentCompilerRevision, definition2, prefix, language, module2])
|
|
99954
99969
|
).update("\0").update(source).digest("hex");
|
|
99955
99970
|
const cache = import_node_path101.default.join(derivedDirectory, "IntentDefinitions");
|
|
@@ -99989,11 +100004,11 @@ function preparePortableIntent(definition2, derivedDirectory, prefix, language,
|
|
|
99989
100004
|
import_node_fs100.default.rmSync(stage, { recursive: true, force: true });
|
|
99990
100005
|
}
|
|
99991
100006
|
}
|
|
99992
|
-
var
|
|
100007
|
+
var import_node_crypto60, import_node_fs100, import_node_path101, intentCompilerRevision;
|
|
99993
100008
|
var init_xcode_intents = __esm({
|
|
99994
100009
|
"src/xcode-intents.ts"() {
|
|
99995
100010
|
"use strict";
|
|
99996
|
-
|
|
100011
|
+
import_node_crypto60 = require("node:crypto");
|
|
99997
100012
|
import_node_fs100 = __toESM(require("node:fs"), 1);
|
|
99998
100013
|
import_node_path101 = __toESM(require("node:path"), 1);
|
|
99999
100014
|
init_fields();
|
|
@@ -100695,7 +100710,7 @@ function loadProject(xcodeproj) {
|
|
|
100695
100710
|
if (!projectFile)
|
|
100696
100711
|
throw new Error(`${xcodeproj} has no project.pbxproj or project.xcproj`);
|
|
100697
100712
|
const source = import_node_fs101.default.readFileSync(projectFile, "utf8");
|
|
100698
|
-
const digest3 = (0,
|
|
100713
|
+
const digest3 = (0, import_node_crypto61.createHash)("sha256").update(source).digest("hex");
|
|
100699
100714
|
const cached5 = loaded3.get(projectFile);
|
|
100700
100715
|
if (cached5?.digest === digest3) return cached5.project;
|
|
100701
100716
|
const root = projectFile.endsWith(".xcproj") ? readXcodeJsonProject(xcodeproj, source) : parseOpenStepPlist(source);
|
|
@@ -100747,7 +100762,7 @@ function xcodeInstallationIdentity() {
|
|
|
100747
100762
|
if (!selected) return null;
|
|
100748
100763
|
const directory2 = import_node_path103.default.extname(selected) === ".app" ? import_node_path103.default.join(selected, "Contents", "Developer") : selected;
|
|
100749
100764
|
const versionFile = `${directory2}/../version.plist`;
|
|
100750
|
-
const version2 = import_node_fs101.default.existsSync(versionFile) ? (0,
|
|
100765
|
+
const version2 = import_node_fs101.default.existsSync(versionFile) ? (0, import_node_crypto61.createHash)("sha256").update(import_node_fs101.default.readFileSync(versionFile)).digest("hex") : null;
|
|
100751
100766
|
return { directory: directory2, version: version2 };
|
|
100752
100767
|
}
|
|
100753
100768
|
function defaultConfiguration(project2) {
|
|
@@ -101215,7 +101230,7 @@ function targetMembers(ref, settings, options2, settingKeys, projectInputs) {
|
|
|
101215
101230
|
);
|
|
101216
101231
|
});
|
|
101217
101232
|
}
|
|
101218
|
-
const signature2 = (0,
|
|
101233
|
+
const signature2 = (0, import_node_crypto61.createHash)("sha256").update(
|
|
101219
101234
|
JSON.stringify([phase, [...settingKeys].map((key3) => [key3, settings(key3)])])
|
|
101220
101235
|
);
|
|
101221
101236
|
for (const file of inputFiles) {
|
|
@@ -101370,7 +101385,7 @@ ${output}`
|
|
|
101370
101385
|
const inputs2 = JSON.stringify([
|
|
101371
101386
|
1,
|
|
101372
101387
|
args,
|
|
101373
|
-
(0,
|
|
101388
|
+
(0, import_node_crypto61.createHash)("sha256").update(import_node_fs101.default.readFileSync(file)).digest("hex")
|
|
101374
101389
|
]);
|
|
101375
101390
|
const developer = settings("DEVELOPER_DIR");
|
|
101376
101391
|
const cached5 = import_node_fs101.default.existsSync(output) && import_node_fs101.default.existsSync(stamp) ? import_node_fs101.default.readFileSync(stamp, "utf8").split("\n") : [];
|
|
@@ -102873,12 +102888,12 @@ function readXcodeAppTarget(input, targetName, configurationName, options2 = {})
|
|
|
102873
102888
|
cocoapods
|
|
102874
102889
|
};
|
|
102875
102890
|
}
|
|
102876
|
-
var import_node_child_process49,
|
|
102891
|
+
var import_node_child_process49, import_node_crypto61, import_node_fs101, import_node_module9, import_node_path103, XCODE_DEFAULT_IOS_DEPLOYMENT_TARGET, runScriptTimeoutMs, CXX_STANDARD_ALIASES, PRE_CXX20_STANDARDS, APPLICATION, APP_EXTENSION, RESOURCE_BUNDLE, PRODUCT_MACH_O_TYPES, FRAMEWORK_PRODUCTS, HEADER_FILE, MODULE_PRODUCTS, CONDITIONS, isDirectory3, loaded3, developerDir, preparedSourcePhases, isPodsProject, targetRefs, NativeAppTargetSelectionError, workspaceResolvedFile, SwiftPackageResolutionRequired;
|
|
102877
102892
|
var init_xcode_project = __esm({
|
|
102878
102893
|
"src/xcode-project.ts"() {
|
|
102879
102894
|
"use strict";
|
|
102880
102895
|
import_node_child_process49 = require("node:child_process");
|
|
102881
|
-
|
|
102896
|
+
import_node_crypto61 = require("node:crypto");
|
|
102882
102897
|
import_node_fs101 = __toESM(require("node:fs"), 1);
|
|
102883
102898
|
import_node_module9 = require("node:module");
|
|
102884
102899
|
import_node_path103 = __toESM(require("node:path"), 1);
|
|
@@ -103070,8 +103085,8 @@ async function walkWorkspaceInputs(app, everyByte, sourceOnly, podsEnvironment)
|
|
|
103070
103085
|
);
|
|
103071
103086
|
const appRelative = import_node_path104.default.relative(root, app);
|
|
103072
103087
|
const manifest = JSON.parse(import_node_fs102.default.readFileSync(import_node_path104.default.join(root, "package.json"), "utf8"));
|
|
103073
|
-
const hash = (0,
|
|
103074
|
-
const native = (0,
|
|
103088
|
+
const hash = (0, import_node_crypto62.createHash)("sha256");
|
|
103089
|
+
const native = (0, import_node_crypto62.createHash)("sha256");
|
|
103075
103090
|
const nativeDirectories = localPackageDirectories(root, app);
|
|
103076
103091
|
const versionFree = new Set(
|
|
103077
103092
|
nativeDirectories.filter((directory2) => directory2 !== appRelative && directory2 !== "").filter(
|
|
@@ -103155,7 +103170,7 @@ async function walkWorkspaceInputs(app, everyByte, sourceOnly, podsEnvironment)
|
|
|
103155
103170
|
unread.slice(start, start + 32).map(async ({ file, content }) => {
|
|
103156
103171
|
const bytes = await import_node_fs102.default.promises.readFile(file);
|
|
103157
103172
|
content.size = bytes.length;
|
|
103158
|
-
content.digest = (0,
|
|
103173
|
+
content.digest = (0, import_node_crypto62.createHash)("sha256").update(bytes).digest("hex");
|
|
103159
103174
|
fileDigests.set(file, content);
|
|
103160
103175
|
})
|
|
103161
103176
|
);
|
|
@@ -103705,7 +103720,7 @@ function stageCachedQuickCryptoOpenSsl(app) {
|
|
|
103705
103720
|
const sha2565 = /openssl_sha256\s*=\s*"([0-9a-f]{64})"/.exec(podspec)?.[1];
|
|
103706
103721
|
if (!sha2565) return;
|
|
103707
103722
|
const archive = import_node_path104.default.join(cacheDir(), "pod-archives", `${sha2565}.zip`);
|
|
103708
|
-
if (!import_node_fs102.default.existsSync(archive) || (0,
|
|
103723
|
+
if (!import_node_fs102.default.existsSync(archive) || (0, import_node_crypto62.createHash)("sha256").update(import_node_fs102.default.readFileSync(archive)).digest("hex") !== sha2565)
|
|
103709
103724
|
return;
|
|
103710
103725
|
import_node_fs102.default.rmSync(opensslDir, { recursive: true, force: true });
|
|
103711
103726
|
import_node_fs102.default.mkdirSync(opensslDir, { recursive: true });
|
|
@@ -103743,12 +103758,12 @@ ${failedOutputLine(command, cwd, bytes)}`
|
|
|
103743
103758
|
});
|
|
103744
103759
|
});
|
|
103745
103760
|
}
|
|
103746
|
-
var import_node_child_process50,
|
|
103761
|
+
var import_node_child_process50, import_node_crypto62, import_node_fs102, import_node_module10, import_node_os21, import_node_path104, import_node_util13, isolatedGitEnv, NATIVE_CONFIG_FILE, NATIVE_SOURCE_FILE2, fileDigests, NATIVE_PACKAGE_ENTRY, hashing, KEPT_WORKSPACES, WORKSPACE_GRACE_MS, ABANDONED_WORKSPACE_MS, RETIRED_PREFIX2, preparing, watches, current, CLONE_ENTRIES;
|
|
103747
103762
|
var init_expo_native_workspace = __esm({
|
|
103748
103763
|
"src/expo-native-workspace.ts"() {
|
|
103749
103764
|
"use strict";
|
|
103750
103765
|
import_node_child_process50 = require("node:child_process");
|
|
103751
|
-
|
|
103766
|
+
import_node_crypto62 = require("node:crypto");
|
|
103752
103767
|
import_node_fs102 = __toESM(require("node:fs"), 1);
|
|
103753
103768
|
import_node_module10 = require("node:module");
|
|
103754
103769
|
import_node_os21 = __toESM(require("node:os"), 1);
|
|
@@ -103821,7 +103836,7 @@ function run() {
|
|
|
103821
103836
|
|
|
103822
103837
|
// src/expo-discovery-cache.ts
|
|
103823
103838
|
function peachPin() {
|
|
103824
|
-
return (0,
|
|
103839
|
+
return (0, import_node_crypto63.createHash)("sha256").update(
|
|
103825
103840
|
`${FORMAT}\0${expoNativeCompilerDigestValue()}\0${swiftNativePin().distribution.id}\0`
|
|
103826
103841
|
).update(JSON.stringify([...EXPO_EAGER_NATIVE_VIEWS])).update(JSON.stringify([...peachAnsweredNativePackages()].sort())).digest("hex");
|
|
103827
103842
|
}
|
|
@@ -103835,7 +103850,7 @@ function stable(value) {
|
|
|
103835
103850
|
}
|
|
103836
103851
|
async function expoDiscoveryKey(options2) {
|
|
103837
103852
|
const { root, hash } = await hashExpoWorkspace(options2.appRoot, options2.signal);
|
|
103838
|
-
const key2 = (0,
|
|
103853
|
+
const key2 = (0, import_node_crypto63.createHash)("sha256").update(`${peachPin()}\0${hash}\0`).update(`${stable(JSON.parse(options2.searchText))}\0`).update(`${stable(options2.configuration)}\0`).update(stable(JSON.parse(options2.resolveText))).digest("hex");
|
|
103839
103854
|
return { key: key2, root };
|
|
103840
103855
|
}
|
|
103841
103856
|
function expoDiscoveryCacheDir() {
|
|
@@ -103906,7 +103921,7 @@ function readExpoDiscovery(key2) {
|
|
|
103906
103921
|
if (typeof parsed2.archive !== "string" || !isDigest(parsed2.archive)) return void 0;
|
|
103907
103922
|
const archive = import_node_path105.default.join(expoDiscoveryCacheDir(), "blobs", `${parsed2.archive}.zst`);
|
|
103908
103923
|
const bytes = import_node_fs103.default.readFileSync(archive);
|
|
103909
|
-
if ((0,
|
|
103924
|
+
if ((0, import_node_crypto63.createHash)("sha256").update(bytes).digest("hex") !== parsed2.archive)
|
|
103910
103925
|
return void 0;
|
|
103911
103926
|
const bodies = (0, import_node_zlib7.zstdDecompressSync)(bytes);
|
|
103912
103927
|
const decoded = /* @__PURE__ */ new Map();
|
|
@@ -103980,7 +103995,7 @@ function stampedFileHash(file) {
|
|
|
103980
103995
|
const stamp = [stat2.dev, stat2.ino, stat2.size, stat2.mtimeNs, stat2.ctimeNs].join(":");
|
|
103981
103996
|
const cached5 = fileHashes.get(file);
|
|
103982
103997
|
if (cached5?.stamp === stamp) return cached5.checksum;
|
|
103983
|
-
const checksum = (0,
|
|
103998
|
+
const checksum = (0, import_node_crypto63.createHash)("sha256").update(import_node_fs103.default.readFileSync(file)).digest("hex");
|
|
103984
103999
|
fileHashes.set(file, { stamp, checksum });
|
|
103985
104000
|
fileHashesChanged = true;
|
|
103986
104001
|
return checksum;
|
|
@@ -103989,7 +104004,7 @@ function saveFileHashes() {
|
|
|
103989
104004
|
if (!fileHashesChanged) return;
|
|
103990
104005
|
fileHashesChanged = false;
|
|
103991
104006
|
const target = fileHashesPath();
|
|
103992
|
-
const temporary = `${target}.${process.pid}.${(0,
|
|
104007
|
+
const temporary = `${target}.${process.pid}.${(0, import_node_crypto63.randomUUID)()}.tmp`;
|
|
103993
104008
|
try {
|
|
103994
104009
|
import_node_fs103.default.mkdirSync(import_node_path105.default.dirname(target), { recursive: true });
|
|
103995
104010
|
import_node_fs103.default.writeFileSync(
|
|
@@ -104044,7 +104059,7 @@ function frameworkDigest(directory2, signal) {
|
|
|
104044
104059
|
if (target !== root && !target.startsWith(`${root}${import_node_path105.default.sep}`))
|
|
104045
104060
|
throw new Error(`framework link escapes its tree: ${relative7}`);
|
|
104046
104061
|
}
|
|
104047
|
-
return (0,
|
|
104062
|
+
return (0, import_node_crypto63.createHash)("sha256").update(JSON.stringify([...entries2])).digest("hex");
|
|
104048
104063
|
}
|
|
104049
104064
|
function rewritePreparedPaths(options2) {
|
|
104050
104065
|
const { units, sourceRoot, preparedRoot, signal } = options2;
|
|
@@ -104065,7 +104080,7 @@ function rewritePreparedPaths(options2) {
|
|
|
104065
104080
|
return null;
|
|
104066
104081
|
}
|
|
104067
104082
|
if (!preparedBytes.equals(sourceBytes)) return null;
|
|
104068
|
-
dependencies[sourceFile] = (0,
|
|
104083
|
+
dependencies[sourceFile] = (0, import_node_crypto63.createHash)("sha256").update(sourceBytes).digest("hex");
|
|
104069
104084
|
verifiedFiles.set(preparedFile, sourceFile);
|
|
104070
104085
|
return sourceFile;
|
|
104071
104086
|
};
|
|
@@ -104142,7 +104157,7 @@ function rewritePreparedPaths(options2) {
|
|
|
104142
104157
|
portableDir = import_node_path105.default.join(parent, import_node_path105.default.basename(dir));
|
|
104143
104158
|
if (!import_node_fs103.default.existsSync(portableDir)) {
|
|
104144
104159
|
import_node_fs103.default.mkdirSync(parent, { recursive: true });
|
|
104145
|
-
const tmp = import_node_path105.default.join(parent, `.${process.pid}.${(0,
|
|
104160
|
+
const tmp = import_node_path105.default.join(parent, `.${process.pid}.${(0, import_node_crypto63.randomUUID)()}.tmp`);
|
|
104146
104161
|
try {
|
|
104147
104162
|
import_node_fs103.default.cpSync(dir, tmp, { recursive: true, verbatimSymlinks: true });
|
|
104148
104163
|
if (frameworkDigest(tmp, signal) !== preparedDigest)
|
|
@@ -104171,7 +104186,7 @@ function writeExpoDiscovery(options2) {
|
|
|
104171
104186
|
try {
|
|
104172
104187
|
const dir = expoDiscoveryCacheDir();
|
|
104173
104188
|
import_node_fs103.default.mkdirSync(dir, { recursive: true });
|
|
104174
|
-
const tmp = import_node_path105.default.join(dir, `.${options2.key}.${process.pid}.${(0,
|
|
104189
|
+
const tmp = import_node_path105.default.join(dir, `.${options2.key}.${process.pid}.${(0, import_node_crypto63.randomUUID)()}.tmp`);
|
|
104175
104190
|
if (options2.units === null) {
|
|
104176
104191
|
import_node_fs103.default.writeFileSync(
|
|
104177
104192
|
tmp,
|
|
@@ -104234,8 +104249,8 @@ function writeExpoDiscovery(options2) {
|
|
|
104234
104249
|
}
|
|
104235
104250
|
);
|
|
104236
104251
|
const contents2 = (0, import_node_zlib7.zstdCompressSync)(Buffer.concat(chunks, size2));
|
|
104237
|
-
const archive = (0,
|
|
104238
|
-
const temporary = import_node_path105.default.join(blobDir, "." + (0,
|
|
104252
|
+
const archive = (0, import_node_crypto63.createHash)("sha256").update(contents2).digest("hex");
|
|
104253
|
+
const temporary = import_node_path105.default.join(blobDir, "." + (0, import_node_crypto63.randomUUID)() + ".tmp");
|
|
104239
104254
|
try {
|
|
104240
104255
|
import_node_fs103.default.writeFileSync(temporary, contents2);
|
|
104241
104256
|
import_node_fs103.default.renameSync(temporary, import_node_path105.default.join(blobDir, `${archive}.zst`));
|
|
@@ -104262,11 +104277,11 @@ function writeExpoDiscovery(options2) {
|
|
|
104262
104277
|
return error instanceof Error ? error.message : String(error);
|
|
104263
104278
|
}
|
|
104264
104279
|
}
|
|
104265
|
-
var
|
|
104280
|
+
var import_node_crypto63, import_node_fs103, import_node_path105, import_node_zlib7, FORMAT, EXPIRY_MS, ORPHAN_TEMPORARY_MS, strings2, stringRecord, isDigest, digestRecord, isBodyOffset, isBodyOffsets, sourceLocationLine, fileHashes, fileHashesLoaded, fileHashesChanged, MISSING_TREE;
|
|
104266
104281
|
var init_expo_discovery_cache = __esm({
|
|
104267
104282
|
"src/expo-discovery-cache.ts"() {
|
|
104268
104283
|
"use strict";
|
|
104269
|
-
|
|
104284
|
+
import_node_crypto63 = require("node:crypto");
|
|
104270
104285
|
import_node_fs103 = __toESM(require("node:fs"), 1);
|
|
104271
104286
|
import_node_path105 = __toESM(require("node:path"), 1);
|
|
104272
104287
|
import_node_zlib7 = require("node:zlib");
|
|
@@ -105342,7 +105357,7 @@ function hashPackageTree(root, options2) {
|
|
|
105342
105357
|
}
|
|
105343
105358
|
};
|
|
105344
105359
|
walk4(root, "");
|
|
105345
|
-
const hash = (0,
|
|
105360
|
+
const hash = (0, import_node_crypto64.createHash)("sha256");
|
|
105346
105361
|
return (async () => {
|
|
105347
105362
|
for (let start = 0; start < files2.length; start += READ_AHEAD) {
|
|
105348
105363
|
const batch = files2.slice(start, start + READ_AHEAD);
|
|
@@ -105363,11 +105378,11 @@ function nativePackageTreeDigest(root) {
|
|
|
105363
105378
|
skipFile: (name3) => name3.endsWith(".d.ts") || name3.endsWith(".d.ts.map") || name3.endsWith(".js.map")
|
|
105364
105379
|
});
|
|
105365
105380
|
}
|
|
105366
|
-
var
|
|
105381
|
+
var import_node_crypto64, import_node_fs106, import_promises12, import_node_path108, READ_AHEAD;
|
|
105367
105382
|
var init_package_tree_digest = __esm({
|
|
105368
105383
|
"src/package-tree-digest.ts"() {
|
|
105369
105384
|
"use strict";
|
|
105370
|
-
|
|
105385
|
+
import_node_crypto64 = require("node:crypto");
|
|
105371
105386
|
import_node_fs106 = require("node:fs");
|
|
105372
105387
|
import_promises12 = require("node:fs/promises");
|
|
105373
105388
|
import_node_path108 = require("node:path");
|
|
@@ -105447,7 +105462,7 @@ async function expoNativeInputs(appRoot) {
|
|
|
105447
105462
|
"swift-pin": JSON.stringify(swiftNativePin()),
|
|
105448
105463
|
answered: JSON.stringify([...peachAnsweredNativePackages()].sort()),
|
|
105449
105464
|
"pods-environment": JSON.stringify(reactNativePodsEnvironment()),
|
|
105450
|
-
fingerprint: (0,
|
|
105465
|
+
fingerprint: (0, import_node_crypto65.createHash)("sha256").update(lines.sort().join("\n")).digest("hex")
|
|
105451
105466
|
},
|
|
105452
105467
|
packages
|
|
105453
105468
|
};
|
|
@@ -105565,7 +105580,7 @@ async function managedExpoNativeAppIdentity(appRoot, iosTarget) {
|
|
|
105565
105580
|
}
|
|
105566
105581
|
function servedExpoSwift(appRoot, entry, app) {
|
|
105567
105582
|
if (!entry.expoSwift) return null;
|
|
105568
|
-
const rootId = `${(0,
|
|
105583
|
+
const rootId = `${(0, import_node_crypto65.createHash)("sha256").update(import_node_fs107.default.realpathSync(appRoot)).digest("hex")}/Expo`;
|
|
105569
105584
|
if (app.infoPlist === null) throw new Error("the prebuilt app target has no Info.plist");
|
|
105570
105585
|
const installed2 = installedInfoPlist(app.infoPlist, entry.infoPlist);
|
|
105571
105586
|
const infoPlist2 = Buffer.from(installed2).toString("base64");
|
|
@@ -105593,11 +105608,11 @@ async function prebuiltExpoSwiftResult(appRoot, entry, signal) {
|
|
|
105593
105608
|
await prebuiltAppTarget(appRoot, signal, "installed")
|
|
105594
105609
|
);
|
|
105595
105610
|
}
|
|
105596
|
-
var
|
|
105611
|
+
var import_node_crypto65, import_node_fs107, import_node_module13, import_node_path109, import_node_util14, EXPO_NATIVE_ENTRY_NAME, IDENTITY_SOURCE_SKIPS, expoNativeEntryUrl, isStringRecord, isPlistArray, published, lookups, answers;
|
|
105597
105612
|
var init_expo_native_prebuilt = __esm({
|
|
105598
105613
|
"src/expo-native-prebuilt.ts"() {
|
|
105599
105614
|
"use strict";
|
|
105600
|
-
|
|
105615
|
+
import_node_crypto65 = require("node:crypto");
|
|
105601
105616
|
import_node_fs107 = __toESM(require("node:fs"), 1);
|
|
105602
105617
|
import_node_module13 = require("node:module");
|
|
105603
105618
|
import_node_path109 = __toESM(require("node:path"), 1);
|
|
@@ -105649,7 +105664,7 @@ function watchNativeInputs(root) {
|
|
|
105649
105664
|
(0, import_node_timers2.clearTimeout)(expiry);
|
|
105650
105665
|
for (const watcher of watchers) watcher.close();
|
|
105651
105666
|
}
|
|
105652
|
-
const inputs2 = { expiry, revision: (0,
|
|
105667
|
+
const inputs2 = { expiry, revision: (0, import_node_crypto66.randomUUID)() };
|
|
105653
105668
|
const watch4 = (directory2, recursive, name3) => {
|
|
105654
105669
|
const watcher = import_node_fs108.default.watch(
|
|
105655
105670
|
directory2,
|
|
@@ -105694,11 +105709,11 @@ function nativeInputRevision(root) {
|
|
|
105694
105709
|
const inputs2 = watchNativeInputs(root);
|
|
105695
105710
|
if (inputs2) return JSON.stringify([inputs2.revision, resolveActiveRuntimeRoot()]);
|
|
105696
105711
|
}
|
|
105697
|
-
var
|
|
105712
|
+
var import_node_crypto66, import_node_fs108, import_node_path110, import_node_timers2, setTimeoutNode, RETENTION_MS, watchedInputs, NativePreparation;
|
|
105698
105713
|
var init_native_preparation = __esm({
|
|
105699
105714
|
"src/native-preparation.ts"() {
|
|
105700
105715
|
"use strict";
|
|
105701
|
-
|
|
105716
|
+
import_node_crypto66 = require("node:crypto");
|
|
105702
105717
|
import_node_fs108 = __toESM(require("node:fs"), 1);
|
|
105703
105718
|
import_node_path110 = __toESM(require("node:path"), 1);
|
|
105704
105719
|
import_node_timers2 = require("node:timers");
|
|
@@ -105878,7 +105893,7 @@ function nativeStaticLibraryEntry(recipe2, compiler, sdk2, distribution) {
|
|
|
105878
105893
|
return { name: recipe2.name, inputs: inputs2, key: nativeEntryKey(inputs2) };
|
|
105879
105894
|
}
|
|
105880
105895
|
function nativeStaticLibraryRecipe(bytes) {
|
|
105881
|
-
const digest3 = (0,
|
|
105896
|
+
const digest3 = (0, import_node_crypto67.createHash)("sha256").update(bytes).digest("hex");
|
|
105882
105897
|
return NATIVE_STATIC_LIBRARY_RECIPES.find((item) => item.nativeSha256 === digest3);
|
|
105883
105898
|
}
|
|
105884
105899
|
function nativeStaticLibrary(file, recipe2, moduleRoot) {
|
|
@@ -105921,7 +105936,7 @@ function isRustSymbol(name3, demangled) {
|
|
|
105921
105936
|
function rustStaticLibrary(file, moduleRoot) {
|
|
105922
105937
|
const toolchain = swiftModuleToolchain(moduleRoot);
|
|
105923
105938
|
const bytes = import_node_fs110.default.readFileSync(file);
|
|
105924
|
-
const key2 = (0,
|
|
105939
|
+
const key2 = (0, import_node_crypto67.createHash)("sha256").update("rust-c-abi-v4\0").update(toolchain.release).update("\0").update(bytes).digest("hex");
|
|
105925
105940
|
const directory2 = import_node_path112.default.join(cacheDir(), "native-archives", key2);
|
|
105926
105941
|
const archive = import_node_path112.default.join(directory2, "library.a");
|
|
105927
105942
|
if (import_node_fs110.default.existsSync(archive)) return archive;
|
|
@@ -105950,7 +105965,7 @@ function rustStaticLibrary(file, moduleRoot) {
|
|
|
105950
105965
|
const members2 = readArMembers(bytes, true);
|
|
105951
105966
|
const seen = /* @__PURE__ */ new Set();
|
|
105952
105967
|
const unique2 = members2.filter(({ name: name3, bytes: bytes2 }) => {
|
|
105953
|
-
const identity2 = name3 + "\0" + (0,
|
|
105968
|
+
const identity2 = name3 + "\0" + (0, import_node_crypto67.createHash)("sha256").update(bytes2).digest("hex");
|
|
105954
105969
|
if (seen.has(identity2)) return false;
|
|
105955
105970
|
seen.add(identity2);
|
|
105956
105971
|
return true;
|
|
@@ -105997,14 +106012,14 @@ function rustStaticLibrary(file, moduleRoot) {
|
|
|
105997
106012
|
function combineNativeStaticLibraries(files2, moduleRoot) {
|
|
105998
106013
|
if (files2.length === 1) return files2[0];
|
|
105999
106014
|
const toolchain = swiftModuleToolchain(moduleRoot);
|
|
106000
|
-
const hash = (0,
|
|
106015
|
+
const hash = (0, import_node_crypto67.createHash)("sha256").update(toolchain.release);
|
|
106001
106016
|
for (const file of files2)
|
|
106002
106017
|
hash.update("\0").update(import_node_path112.default.basename(file)).update("\0").update(import_node_fs110.default.readFileSync(file));
|
|
106003
106018
|
const directory2 = import_node_path112.default.join(cacheDir(), "native-archives", hash.digest("hex"));
|
|
106004
106019
|
const archive = import_node_path112.default.join(directory2, "combined.a");
|
|
106005
106020
|
if (import_node_fs110.default.existsSync(archive)) return archive;
|
|
106006
106021
|
import_node_fs110.default.mkdirSync(directory2, { recursive: true });
|
|
106007
|
-
const temporary = import_node_path112.default.join(directory2, `combined-${(0,
|
|
106022
|
+
const temporary = import_node_path112.default.join(directory2, `combined-${(0, import_node_crypto67.randomUUID)()}.a`);
|
|
106008
106023
|
try {
|
|
106009
106024
|
(0, import_node_child_process52.execFileSync)(import_node_path112.default.join(toolchain.toolchainBin, "llvm-ar"), [
|
|
106010
106025
|
"qcsDL",
|
|
@@ -106017,12 +106032,12 @@ function combineNativeStaticLibraries(files2, moduleRoot) {
|
|
|
106017
106032
|
}
|
|
106018
106033
|
return archive;
|
|
106019
106034
|
}
|
|
106020
|
-
var import_node_child_process52,
|
|
106035
|
+
var import_node_child_process52, import_node_crypto67, import_node_fs110, import_node_path112, WEBRTC_NATIVE_FRAMEWORK, SIGNAL_WEBRTC_NATIVE_FRAMEWORK, WEBRTC_NATIVE_FRAMEWORK_RECIPES, NATIVE_STATIC_LIBRARY_RECIPES;
|
|
106021
106036
|
var init_native_static_libraries = __esm({
|
|
106022
106037
|
"src/native-static-libraries.ts"() {
|
|
106023
106038
|
"use strict";
|
|
106024
106039
|
import_node_child_process52 = require("node:child_process");
|
|
106025
|
-
|
|
106040
|
+
import_node_crypto67 = require("node:crypto");
|
|
106026
106041
|
import_node_fs110 = __toESM(require("node:fs"), 1);
|
|
106027
106042
|
import_node_path112 = __toESM(require("node:path"), 1);
|
|
106028
106043
|
init_home_paths();
|
|
@@ -106627,13 +106642,13 @@ var init_swift_wasm64_wamr = __esm({
|
|
|
106627
106642
|
|
|
106628
106643
|
// src/swift-wasm64-native-source.ts
|
|
106629
106644
|
function deriveSource(file, bytes, backport) {
|
|
106630
|
-
if (!backport || (0,
|
|
106645
|
+
if (!backport || (0, import_node_crypto68.createHash)("sha256").update(bytes).digest("hex") !== backport.originalSha256)
|
|
106631
106646
|
return null;
|
|
106632
106647
|
const source = bytes.toString("utf8");
|
|
106633
106648
|
const derived = Buffer.from(
|
|
106634
106649
|
"rewrite" in backport ? backport.rewrite(source) : source.replace(backport.before, backport.after)
|
|
106635
106650
|
);
|
|
106636
|
-
if ((0,
|
|
106651
|
+
if ((0, import_node_crypto68.createHash)("sha256").update(derived).digest("hex") !== backport.derivedSha256)
|
|
106637
106652
|
throw new Error(`Native source derivation differs: ${file}`);
|
|
106638
106653
|
return {
|
|
106639
106654
|
bytes: derived,
|
|
@@ -106652,11 +106667,11 @@ function deriveWasm64NativeSource(file, bytes) {
|
|
|
106652
106667
|
sourceDerivations.get(name3) ?? headerDerivations.get(name3)
|
|
106653
106668
|
);
|
|
106654
106669
|
}
|
|
106655
|
-
var
|
|
106670
|
+
var import_node_crypto68, import_node_path114, webrtcUnknownArchitecture, boringsslWordSize2, wamrCommit, headerDerivations, sourceDerivations;
|
|
106656
106671
|
var init_swift_wasm64_native_source = __esm({
|
|
106657
106672
|
"src/swift-wasm64-native-source.ts"() {
|
|
106658
106673
|
"use strict";
|
|
106659
|
-
|
|
106674
|
+
import_node_crypto68 = require("node:crypto");
|
|
106660
106675
|
import_node_path114 = __toESM(require("node:path"), 1);
|
|
106661
106676
|
init_swift_wasm64_wamr();
|
|
106662
106677
|
init_swiftWasm64ConfigContract();
|
|
@@ -107116,7 +107131,7 @@ var init_genrule_library_builds = __esm({
|
|
|
107116
107131
|
function nativeFrameworkCompiler(moduleRoot, toolchainBin, directory2) {
|
|
107117
107132
|
const distribution = swiftDistributionAt(moduleRoot);
|
|
107118
107133
|
const sdk2 = swiftSdkPaths(moduleRoot, toolchainBin);
|
|
107119
|
-
const identity2 = (0,
|
|
107134
|
+
const identity2 = (0, import_node_crypto69.createHash)("sha256").update(
|
|
107120
107135
|
JSON.stringify([
|
|
107121
107136
|
distribution?.id,
|
|
107122
107137
|
distribution?.link,
|
|
@@ -107142,7 +107157,7 @@ function nativeFrameworkCompiler(moduleRoot, toolchainBin, directory2) {
|
|
|
107142
107157
|
for (const alias of product.frameworkAliases) {
|
|
107143
107158
|
if (alias.wasmSdkId !== distribution.wasmSdkId || alias.wasmSdkChecksum !== distribution.wasmSdkChecksum)
|
|
107144
107159
|
throw new Error(`framework SDK identity differs for ${alias.name}`);
|
|
107145
|
-
if ((0,
|
|
107160
|
+
if ((0, import_node_crypto69.createHash)("sha256").update(import_node_fs113.default.readFileSync(import_node_path116.default.join(moduleRoot, alias.moduleMap))).digest("hex") !== alias.moduleMapSha256)
|
|
107146
107161
|
throw new Error(`framework module map changed ${alias.moduleMap}`);
|
|
107147
107162
|
const selected = /* @__PURE__ */ new Set();
|
|
107148
107163
|
const reach = (name3) => {
|
|
@@ -107183,7 +107198,7 @@ function nativeFrameworkCompiler(moduleRoot, toolchainBin, directory2) {
|
|
|
107183
107198
|
for (const alias of owner.frameworkAliases) {
|
|
107184
107199
|
if (frameworkResponses[alias.name])
|
|
107185
107200
|
throw new Error(`ambiguous declared framework ${alias.name}`);
|
|
107186
|
-
if ((0,
|
|
107201
|
+
if ((0, import_node_crypto69.createHash)("sha256").update(import_node_fs113.default.readFileSync(import_node_path116.default.join(sdkRoot, alias.moduleMap))).digest("hex") !== alias.moduleMapSha256)
|
|
107187
107202
|
throw new Error(`framework module map changed ${alias.moduleMap}`);
|
|
107188
107203
|
const file = import_node_path116.default.join(root, `${alias.name}.rsp`);
|
|
107189
107204
|
import_node_fs113.default.writeFileSync(file, aliasArtifacts.map(quote3).join("\n") + "\n");
|
|
@@ -107277,11 +107292,11 @@ exec ${shellQuote(configuration2.compiler)} "$@"
|
|
|
107277
107292
|
};
|
|
107278
107293
|
return { cc: compiler("clang"), cxx: compiler("clang++"), identity: identity2 };
|
|
107279
107294
|
}
|
|
107280
|
-
var
|
|
107295
|
+
var import_node_crypto69, import_node_fs113, import_node_path116, v7;
|
|
107281
107296
|
var init_native_framework_compiler = __esm({
|
|
107282
107297
|
"src/native-framework-compiler.ts"() {
|
|
107283
107298
|
"use strict";
|
|
107284
|
-
|
|
107299
|
+
import_node_crypto69 = require("node:crypto");
|
|
107285
107300
|
import_node_fs113 = __toESM(require("node:fs"), 1);
|
|
107286
107301
|
import_node_path116 = __toESM(require("node:path"), 1);
|
|
107287
107302
|
v7 = __toESM(require("peachsim/vendor/valibot"), 1);
|
|
@@ -107302,7 +107317,7 @@ function processAlive(pid) {
|
|
|
107302
107317
|
}
|
|
107303
107318
|
function tryAcquireNumberedLock(directory2, detail = "") {
|
|
107304
107319
|
(0, import_node_fs114.mkdirSync)(directory2, { recursive: true });
|
|
107305
|
-
const claim = (0, import_node_path117.join)(directory2, `claim-${process.pid}-${(0,
|
|
107320
|
+
const claim = (0, import_node_path117.join)(directory2, `claim-${process.pid}-${(0, import_node_crypto70.randomUUID)()}`);
|
|
107306
107321
|
for (; ; ) {
|
|
107307
107322
|
const numbers = (0, import_node_fs114.readdirSync)(directory2).filter((name3) => /^\d+$/.test(name3)).map(Number);
|
|
107308
107323
|
const top = Math.max(-1, ...numbers);
|
|
@@ -107341,11 +107356,11 @@ ${detail}` : ""}`);
|
|
|
107341
107356
|
};
|
|
107342
107357
|
}
|
|
107343
107358
|
}
|
|
107344
|
-
var
|
|
107359
|
+
var import_node_crypto70, import_node_fs114, import_node_path117, errorCode2;
|
|
107345
107360
|
var init_numbered_lock = __esm({
|
|
107346
107361
|
"src/numbered-lock.ts"() {
|
|
107347
107362
|
"use strict";
|
|
107348
|
-
|
|
107363
|
+
import_node_crypto70 = require("node:crypto");
|
|
107349
107364
|
import_node_fs114 = require("node:fs");
|
|
107350
107365
|
import_node_path117 = require("node:path");
|
|
107351
107366
|
errorCode2 = (error) => error instanceof Error && "code" in error ? error.code : void 0;
|
|
@@ -107372,7 +107387,7 @@ function llvmIdentity(toolchainBin, release) {
|
|
|
107372
107387
|
] : ["clang", "wasm-ld", "llvm-ar", "llvm-nm", "llvm-strip"].map(
|
|
107373
107388
|
(name3) => swiftFileChecksum(import_node_path118.default.join(toolchainBin, name3))
|
|
107374
107389
|
);
|
|
107375
|
-
const identity2 = (0,
|
|
107390
|
+
const identity2 = (0, import_node_crypto71.createHash)("sha256").update(JSON.stringify(components)).digest("hex");
|
|
107376
107391
|
toolIdentities.set(toolchainBin, identity2);
|
|
107377
107392
|
return identity2;
|
|
107378
107393
|
}
|
|
@@ -107380,7 +107395,7 @@ function cSdkIdentity(sysroot, resourceDir, frameworks) {
|
|
|
107380
107395
|
const key2 = JSON.stringify([sysroot, resourceDir, frameworks]);
|
|
107381
107396
|
const cached5 = sysrootIdentities.get(key2);
|
|
107382
107397
|
if (cached5) return cached5;
|
|
107383
|
-
const hash = (0,
|
|
107398
|
+
const hash = (0, import_node_crypto71.createHash)("sha256");
|
|
107384
107399
|
const add2 = (root, relative7) => {
|
|
107385
107400
|
const file = import_node_path118.default.join(root, relative7);
|
|
107386
107401
|
const stat2 = import_node_fs115.default.statSync(file, { throwIfNoEntry: false });
|
|
@@ -107415,7 +107430,7 @@ function frameworkProbeIdentity(moduleRoot, toolchainBin) {
|
|
|
107415
107430
|
import_node_fs115.default.readFileSync(import_node_path118.default.join(moduleRoot, SWIFT_FRAMEWORK_PRODUCT_FILE), "utf8")
|
|
107416
107431
|
)
|
|
107417
107432
|
);
|
|
107418
|
-
const hash = (0,
|
|
107433
|
+
const hash = (0, import_node_crypto71.createHash)("sha256").update(
|
|
107419
107434
|
JSON.stringify([
|
|
107420
107435
|
headers,
|
|
107421
107436
|
distribution.link,
|
|
@@ -107425,7 +107440,7 @@ function frameworkProbeIdentity(moduleRoot, toolchainBin) {
|
|
|
107425
107440
|
])
|
|
107426
107441
|
);
|
|
107427
107442
|
const objects = distribution.objects.map((file) => [file, distribution.files[file]]);
|
|
107428
|
-
const objectKey = (0,
|
|
107443
|
+
const objectKey = (0, import_node_crypto71.createHash)("sha256").update(JSON.stringify(objects)).digest("hex");
|
|
107429
107444
|
const cache = import_node_path118.default.join(cacheDir4, "framework-symbols-by-object", objectKey);
|
|
107430
107445
|
if (!import_node_fs115.default.existsSync(cache)) {
|
|
107431
107446
|
import_node_fs115.default.mkdirSync(import_node_path118.default.dirname(cache), { recursive: true });
|
|
@@ -107460,7 +107475,7 @@ function frameworkProbeIdentity(moduleRoot, toolchainBin) {
|
|
|
107460
107475
|
const digest3 = import_node_path118.default.join(temporary, "digest");
|
|
107461
107476
|
import_node_fs115.default.writeFileSync(
|
|
107462
107477
|
digest3,
|
|
107463
|
-
(0,
|
|
107478
|
+
(0, import_node_crypto71.createHash)("sha256").update(symbols.sort().join("\n")).digest("hex")
|
|
107464
107479
|
);
|
|
107465
107480
|
import_node_fs115.default.renameSync(digest3, cache);
|
|
107466
107481
|
} finally {
|
|
@@ -107515,7 +107530,7 @@ function buildable(declaration) {
|
|
|
107515
107530
|
return builderOf(declaration) !== null && declaration.dependencies.every(buildable);
|
|
107516
107531
|
}
|
|
107517
107532
|
function declarationInputs(declaration, builder, toolchain, dependencyKeys) {
|
|
107518
|
-
const hash = (0,
|
|
107533
|
+
const hash = (0, import_node_crypto71.createHash)("sha256");
|
|
107519
107534
|
const files2 = declaration.sources.filter(
|
|
107520
107535
|
(source) => !source.generator && !source.file.split(import_node_path118.default.sep).includes(".git")
|
|
107521
107536
|
).map((source) => import_node_path118.default.relative(declaration.packageDir, source.file));
|
|
@@ -107649,12 +107664,12 @@ function genruleArchive(declaration, library, moduleRoot) {
|
|
|
107649
107664
|
}
|
|
107650
107665
|
return combined;
|
|
107651
107666
|
}
|
|
107652
|
-
var import_node_child_process55,
|
|
107667
|
+
var import_node_child_process55, import_node_crypto71, import_node_fs115, import_node_os23, import_node_path118, v8, BUILDERS, cacheDir4, toolIdentities, sysrootIdentities, GENRULE_RECIPE, GENRULE_BUNDLE;
|
|
107653
107668
|
var init_genrule_archives = __esm({
|
|
107654
107669
|
"src/genrule-archives.ts"() {
|
|
107655
107670
|
"use strict";
|
|
107656
107671
|
import_node_child_process55 = require("node:child_process");
|
|
107657
|
-
|
|
107672
|
+
import_node_crypto71 = require("node:crypto");
|
|
107658
107673
|
import_node_fs115 = __toESM(require("node:fs"), 1);
|
|
107659
107674
|
import_node_os23 = __toESM(require("node:os"), 1);
|
|
107660
107675
|
import_node_path118 = __toESM(require("node:path"), 1);
|
|
@@ -107762,7 +107777,7 @@ function privateSentrySlice(entry, moduleRoot) {
|
|
|
107762
107777
|
function nativeSwiftSlice(standin, moduleRoot, generator, configured, artifact) {
|
|
107763
107778
|
if (standin.module !== SENTRY_SWIFT_SLICE.name) return standin;
|
|
107764
107779
|
const native = simulatorNativeLibrary(artifact());
|
|
107765
|
-
if (!native || (0,
|
|
107780
|
+
if (!native || (0, import_node_crypto72.createHash)("sha256").update(import_node_fs116.default.readFileSync(native.file)).digest("hex") !== SENTRY_SWIFT_SLICE.nativeSha256)
|
|
107766
107781
|
return standin;
|
|
107767
107782
|
if (configured)
|
|
107768
107783
|
throw new Error(
|
|
@@ -107820,12 +107835,12 @@ function nativeSwiftSlice(standin, moduleRoot, generator, configured, artifact)
|
|
|
107820
107835
|
}
|
|
107821
107836
|
};
|
|
107822
107837
|
}
|
|
107823
|
-
var import_node_child_process56,
|
|
107838
|
+
var import_node_child_process56, import_node_crypto72, import_node_fs116, import_node_os24, import_node_path119, SENTRY_SWIFT_SLICE;
|
|
107824
107839
|
var init_native_swift_slices = __esm({
|
|
107825
107840
|
"src/native-swift-slices.ts"() {
|
|
107826
107841
|
"use strict";
|
|
107827
107842
|
import_node_child_process56 = require("node:child_process");
|
|
107828
|
-
|
|
107843
|
+
import_node_crypto72 = require("node:crypto");
|
|
107829
107844
|
import_node_fs116 = __toESM(require("node:fs"), 1);
|
|
107830
107845
|
import_node_os24 = __toESM(require("node:os"), 1);
|
|
107831
107846
|
import_node_path119 = __toESM(require("node:path"), 1);
|
|
@@ -108633,7 +108648,7 @@ function treeDigest2(root) {
|
|
|
108633
108648
|
}).join("\n");
|
|
108634
108649
|
const memo2 = digests.get(`tree\0${root}`);
|
|
108635
108650
|
if (memo2?.stamp === stamp) return memo2.digest;
|
|
108636
|
-
const hash = (0,
|
|
108651
|
+
const hash = (0, import_node_crypto73.createHash)("sha256");
|
|
108637
108652
|
for (const name3 of names) {
|
|
108638
108653
|
hash.update(`${name3}\0`);
|
|
108639
108654
|
hash.update(import_node_fs120.default.readFileSync(import_node_path122.default.join(root, name3)));
|
|
@@ -108680,7 +108695,7 @@ function swiftBinaryFramework(binary2) {
|
|
|
108680
108695
|
const found4 = locateXcframework(import_node_path122.default.join(dir, "tree"));
|
|
108681
108696
|
if (found4) return { dir: found4, digest: stored.sha };
|
|
108682
108697
|
}
|
|
108683
|
-
const sha2 = (0,
|
|
108698
|
+
const sha2 = (0, import_node_crypto73.createHash)("sha256").update(import_node_fs120.default.readFileSync(binary2.dir)).digest("hex");
|
|
108684
108699
|
if (sha2 !== stored?.sha || !locateXcframework(import_node_path122.default.join(dir, "tree"))) {
|
|
108685
108700
|
import_node_fs120.default.rmSync(dir, { recursive: true, force: true });
|
|
108686
108701
|
import_node_fs120.default.mkdirSync(import_node_path122.default.join(dir, "tree"), { recursive: true });
|
|
@@ -108692,7 +108707,7 @@ function swiftBinaryFramework(binary2) {
|
|
|
108692
108707
|
return { dir: found3, digest: sha2 };
|
|
108693
108708
|
}
|
|
108694
108709
|
if (stored && import_node_fs120.default.existsSync(archive)) {
|
|
108695
|
-
const sha2 = (0,
|
|
108710
|
+
const sha2 = (0, import_node_crypto73.createHash)("sha256").update(import_node_fs120.default.readFileSync(archive)).digest("hex");
|
|
108696
108711
|
if (sha2 !== expected)
|
|
108697
108712
|
throw new Error(`archive checksum ${sha2} is not the declared checksum ${expected}`);
|
|
108698
108713
|
const found3 = locateXcframework(import_node_path122.default.join(dir, "tree"));
|
|
@@ -108701,7 +108716,7 @@ function swiftBinaryFramework(binary2) {
|
|
|
108701
108716
|
import_node_fs120.default.rmSync(dir, { recursive: true, force: true });
|
|
108702
108717
|
import_node_fs120.default.mkdirSync(import_node_path122.default.join(dir, "tree"), { recursive: true });
|
|
108703
108718
|
exec("curl", ["-fsSL", "--retry", "2", "-o", archive, binary2.url]);
|
|
108704
|
-
const sha = (0,
|
|
108719
|
+
const sha = (0, import_node_crypto73.createHash)("sha256").update(import_node_fs120.default.readFileSync(archive)).digest("hex");
|
|
108705
108720
|
if (sha !== expected) {
|
|
108706
108721
|
import_node_fs120.default.rmSync(dir, { recursive: true, force: true });
|
|
108707
108722
|
throw new Error(`archive checksum ${sha} is not the declared checksum ${expected}`);
|
|
@@ -108826,7 +108841,7 @@ function binaryHeaderSearchPaths(binary2, root, workspaceRoot2, declaredFramewor
|
|
|
108826
108841
|
});
|
|
108827
108842
|
}
|
|
108828
108843
|
}
|
|
108829
|
-
const declaredDigest = (0,
|
|
108844
|
+
const declaredDigest = (0, import_node_crypto73.createHash)("sha256");
|
|
108830
108845
|
for (const framework of providedFrameworks)
|
|
108831
108846
|
declaredDigest.update(`provided/${import_node_path122.default.relative(artifact.dir, framework)}\0`);
|
|
108832
108847
|
for (const [framework, { declared: names, imports: imports2, sdkHeader }] of declared)
|
|
@@ -108896,7 +108911,7 @@ function binaryHeaderSearchPaths(binary2, root, workspaceRoot2, declaredFramewor
|
|
|
108896
108911
|
import_node_fs120.default.copyFileSync(surface.modulemap, modulemap);
|
|
108897
108912
|
}
|
|
108898
108913
|
}
|
|
108899
|
-
const contents2 = (0,
|
|
108914
|
+
const contents2 = (0, import_node_crypto73.createHash)("sha256");
|
|
108900
108915
|
for (const framework of providedFrameworks.filter((item) => !declared.has(item))) {
|
|
108901
108916
|
const modulemap = import_node_path122.default.join(
|
|
108902
108917
|
pending2,
|
|
@@ -110311,7 +110326,7 @@ function crateSourceRoots(manifest, searchRoot) {
|
|
|
110311
110326
|
return roots;
|
|
110312
110327
|
}
|
|
110313
110328
|
function crateSourceDigest(manifest, searchRoot) {
|
|
110314
|
-
const hash = (0,
|
|
110329
|
+
const hash = (0, import_node_crypto73.createHash)("sha256");
|
|
110315
110330
|
const walk4 = (dir, root) => {
|
|
110316
110331
|
for (const entry of import_node_fs120.default.readdirSync(dir, { withFileTypes: true }).sort((left, right) => left.name < right.name ? -1 : 1)) {
|
|
110317
110332
|
const full = import_node_path122.default.join(dir, entry.name);
|
|
@@ -110758,7 +110773,7 @@ function standinGenerationInputs(binaries, toolchain, configuredBehavior = {}, s
|
|
|
110758
110773
|
...swiftSources.flags,
|
|
110759
110774
|
...swiftSources.sources.flatMap((source) => [
|
|
110760
110775
|
source,
|
|
110761
|
-
(0,
|
|
110776
|
+
(0, import_node_crypto73.createHash)("sha256").update(import_node_fs120.default.readFileSync(import_node_path122.default.join(binary2.dir, source))).digest("hex")
|
|
110762
110777
|
])
|
|
110763
110778
|
);
|
|
110764
110779
|
continue;
|
|
@@ -110794,7 +110809,7 @@ function standinGenerationInputs(binaries, toolchain, configuredBehavior = {}, s
|
|
|
110794
110809
|
);
|
|
110795
110810
|
}
|
|
110796
110811
|
}
|
|
110797
|
-
return (0,
|
|
110812
|
+
return (0, import_node_crypto73.createHash)("sha256").update(parts2.join("\0")).digest("hex");
|
|
110798
110813
|
}
|
|
110799
110814
|
function missingArtifactGap(binary2) {
|
|
110800
110815
|
if (swiftBinaryOnDisk(binary2)) return null;
|
|
@@ -110876,7 +110891,7 @@ ${roots.map((file) => ` header "${file}"`).join("\n")}
|
|
|
110876
110891
|
return NO_IMPORTABLE_SURFACE;
|
|
110877
110892
|
}
|
|
110878
110893
|
const configured = new Map(Object.entries(behavior));
|
|
110879
|
-
const hash = (0,
|
|
110894
|
+
const hash = (0, import_node_crypto73.createHash)("sha256").update(
|
|
110880
110895
|
standinGenerationInputs([binary2], toolchain, behavior)
|
|
110881
110896
|
);
|
|
110882
110897
|
hash.update(digest3);
|
|
@@ -111116,7 +111131,7 @@ async function buildStandins(binaries, toolchain, provided, behavior) {
|
|
|
111116
111131
|
);
|
|
111117
111132
|
if (binary2.moduleSources !== void 0)
|
|
111118
111133
|
frameworkInputs.push(
|
|
111119
|
-
`${binary2.target}\0${(0,
|
|
111134
|
+
`${binary2.target}\0${(0, import_node_crypto73.createHash)("sha256").update(
|
|
111120
111135
|
[iosSdkId(), ...swiftSources.flags, ...swiftSources.sources, ...texts].join(
|
|
111121
111136
|
"\0"
|
|
111122
111137
|
)
|
|
@@ -111157,7 +111172,7 @@ async function buildStandins(binaries, toolchain, provided, behavior) {
|
|
|
111157
111172
|
import_node_fs120.default.mkdirSync(sourceFrameworks);
|
|
111158
111173
|
const frameworks = {
|
|
111159
111174
|
dirs: [...frameworkDirs, sourceFrameworks].sort(),
|
|
111160
|
-
digest: (0,
|
|
111175
|
+
digest: (0, import_node_crypto73.createHash)("sha256").update(frameworkInputs.sort().join("\0")).digest("hex"),
|
|
111161
111176
|
surfaces: frameworkSurfaces
|
|
111162
111177
|
};
|
|
111163
111178
|
const siblings = new Map(
|
|
@@ -111276,12 +111291,12 @@ async function buildStandins(binaries, toolchain, provided, behavior) {
|
|
|
111276
111291
|
import_node_fs120.default.rmSync(modules, { recursive: true, force: true });
|
|
111277
111292
|
}
|
|
111278
111293
|
}
|
|
111279
|
-
var import_node_child_process58,
|
|
111294
|
+
var import_node_child_process58, import_node_crypto73, import_node_fs120, import_node_path122, TRIPLE, cacheDir5, key, digests, isBinaryLibraryFile, OBJC_IMPORT, files, OBJC, NO_IMPORTABLE_SURFACE, OBJC_ATTRIBUTE, TYPE_DECLARATION, OPTIONAL_REQUIREMENT, WASM_EH_FLAGS, OBJC_UNREPRESENTABLE, INERT_VALUE, identChar, RUST_TARGET, UNSEARCHED, RUST_TOOLCHAIN, built;
|
|
111280
111295
|
var init_swift_standins = __esm({
|
|
111281
111296
|
"src/swift-standins.ts"() {
|
|
111282
111297
|
"use strict";
|
|
111283
111298
|
import_node_child_process58 = require("node:child_process");
|
|
111284
|
-
|
|
111299
|
+
import_node_crypto73 = require("node:crypto");
|
|
111285
111300
|
import_node_fs120 = __toESM(require("node:fs"), 1);
|
|
111286
111301
|
import_node_path122 = __toESM(require("node:path"), 1);
|
|
111287
111302
|
init_forked_script_contract();
|
|
@@ -111311,7 +111326,7 @@ var init_swift_standins = __esm({
|
|
|
111311
111326
|
init_swiftTargetContract();
|
|
111312
111327
|
TRIPLE = SWIFT_WASM_TRIPLE;
|
|
111313
111328
|
cacheDir5 = import_node_path122.default.join(cacheDir(), "swift-standins");
|
|
111314
|
-
key = (...parts2) => (0,
|
|
111329
|
+
key = (...parts2) => (0, import_node_crypto73.createHash)("sha256").update(parts2.join("\0")).digest("hex").slice(0, 32);
|
|
111315
111330
|
digests = /* @__PURE__ */ new Map();
|
|
111316
111331
|
isBinaryLibraryFile = (file) => /\.(?:a|dylib|o|tbd)$/i.test(file);
|
|
111317
111332
|
OBJC_IMPORT = /#\s*(?:import|include)\s*[<"](?:[\w+-]+\/)?([\w+.-]+\.h)[>"]/g;
|
|
@@ -111474,7 +111489,7 @@ function compiledFrameworkImports(app, products) {
|
|
|
111474
111489
|
function sha256Hex6(bytes) {
|
|
111475
111490
|
if (typeof Bun !== "undefined")
|
|
111476
111491
|
return new Bun.CryptoHasher("sha256").update(bytes).digest("hex");
|
|
111477
|
-
return (0,
|
|
111492
|
+
return (0, import_node_crypto74.createHash)("sha256").update(bytes).digest("hex");
|
|
111478
111493
|
}
|
|
111479
111494
|
function regularFileStamp(file) {
|
|
111480
111495
|
const stat2 = import_node_fs121.default.lstatSync(file, { bigint: true, throwIfNoEntry: false });
|
|
@@ -111517,7 +111532,7 @@ function cachedBinaryFileDigest(file) {
|
|
|
111517
111532
|
const digest3 = sha256Hex6(import_node_fs121.default.readFileSync(real));
|
|
111518
111533
|
binaryFileDigests.set(real, { stamp, digest: digest3 });
|
|
111519
111534
|
import_node_fs121.default.mkdirSync(dir, { recursive: true });
|
|
111520
|
-
const partial = `${record6}.${process.pid}.${(0,
|
|
111535
|
+
const partial = `${record6}.${process.pid}.${(0, import_node_crypto74.randomUUID)()}`;
|
|
111521
111536
|
import_node_fs121.default.writeFileSync(partial, JSON.stringify({ stamp, digest: digest3 }));
|
|
111522
111537
|
import_node_fs121.default.renameSync(partial, record6);
|
|
111523
111538
|
return digest3;
|
|
@@ -112787,12 +112802,12 @@ ${reported.trimEnd() || `Clang exited with status ${result.status}`}`;
|
|
|
112787
112802
|
import_node_fs121.default.closeSync(descriptor);
|
|
112788
112803
|
}
|
|
112789
112804
|
}
|
|
112790
|
-
var import_node_child_process59,
|
|
112805
|
+
var import_node_child_process59, import_node_crypto74, import_node_fs121, import_node_path123, SwiftObjCCompilationError, isDirectory4, isSdkInclude, FRAMEWORK_IMPORT, OWN_IMPORT, binaryFileDigests, objcInputSnapshots;
|
|
112791
112806
|
var init_swift_objc_compile = __esm({
|
|
112792
112807
|
"src/swift-objc-compile.ts"() {
|
|
112793
112808
|
"use strict";
|
|
112794
112809
|
import_node_child_process59 = require("node:child_process");
|
|
112795
|
-
|
|
112810
|
+
import_node_crypto74 = require("node:crypto");
|
|
112796
112811
|
import_node_fs121 = __toESM(require("node:fs"), 1);
|
|
112797
112812
|
import_node_path123 = __toESM(require("node:path"), 1);
|
|
112798
112813
|
init_mapLimit();
|
|
@@ -116957,11 +116972,11 @@ function coreDataModelDirectories(files2) {
|
|
|
116957
116972
|
}
|
|
116958
116973
|
return [...models].sort();
|
|
116959
116974
|
}
|
|
116960
|
-
var
|
|
116975
|
+
var import_node_crypto75, import_node_fs125, import_node_path127, attributeTypes, deleteRules, EXTERNAL_BINARY, PRESERVE_AFTER_DELETION, yes, common, uid, NULL, classChains, KeyedArchive, sha2563;
|
|
116961
116976
|
var init_core_data_model = __esm({
|
|
116962
116977
|
"src/core-data-model.ts"() {
|
|
116963
116978
|
"use strict";
|
|
116964
|
-
|
|
116979
|
+
import_node_crypto75 = require("node:crypto");
|
|
116965
116980
|
import_node_fs125 = require("node:fs");
|
|
116966
116981
|
import_node_path127 = __toESM(require("node:path"), 1);
|
|
116967
116982
|
init_core_data_entity_classes();
|
|
@@ -117080,7 +117095,7 @@ var init_core_data_model = __esm({
|
|
|
117080
117095
|
});
|
|
117081
117096
|
}
|
|
117082
117097
|
};
|
|
117083
|
-
sha2563 = (...parts2) => (0,
|
|
117098
|
+
sha2563 = (...parts2) => (0, import_node_crypto75.createHash)("sha256").update(
|
|
117084
117099
|
Buffer.concat(
|
|
117085
117100
|
parts2.map(
|
|
117086
117101
|
(part) => Array.isArray(part) ? Buffer.from(part) : Buffer.from(part)
|
|
@@ -119272,7 +119287,7 @@ async function buildRiveRuntimeDependencies(checkout, moduleRoot) {
|
|
|
119272
119287
|
];
|
|
119273
119288
|
const objc = [...swiftObjCRuntimeFlags, "-fobjc-exceptions"];
|
|
119274
119289
|
const xcode = (0, import_node_child_process61.execFileSync)("xcodebuild", ["-version"], { encoding: "utf8" });
|
|
119275
|
-
const key2 = (0,
|
|
119290
|
+
const key2 = (0, import_node_crypto76.createHash)("sha256").update(
|
|
119276
119291
|
JSON.stringify([
|
|
119277
119292
|
RECIPE,
|
|
119278
119293
|
(0, import_node_child_process61.execFileSync)("git", ["-C", runtime, "rev-parse", "HEAD"], {
|
|
@@ -119483,12 +119498,12 @@ exec ${quote3(import_node_path128.default.join(toolchainBin, "llvm-ar"))} rcs "$
|
|
|
119483
119498
|
);
|
|
119484
119499
|
return directory2;
|
|
119485
119500
|
}
|
|
119486
|
-
var import_node_child_process61,
|
|
119501
|
+
var import_node_child_process61, import_node_crypto76, import_node_fs126, import_node_os25, import_node_path128, import_promises14, RECIPE, CONFIG, RUNTIME_LIBRARIES;
|
|
119487
119502
|
var init_rive_runtime_dependencies = __esm({
|
|
119488
119503
|
"src/rive-runtime-dependencies.ts"() {
|
|
119489
119504
|
"use strict";
|
|
119490
119505
|
import_node_child_process61 = require("node:child_process");
|
|
119491
|
-
|
|
119506
|
+
import_node_crypto76 = require("node:crypto");
|
|
119492
119507
|
import_node_fs126 = __toESM(require("node:fs"), 1);
|
|
119493
119508
|
import_node_os25 = __toESM(require("node:os"), 1);
|
|
119494
119509
|
import_node_path128 = __toESM(require("node:path"), 1);
|
|
@@ -120345,7 +120360,7 @@ async function xcodeCxxReachable(app, binaries, moduleRoot, clang) {
|
|
|
120345
120360
|
(binary2) => binary2.publicHeaders === void 0 && binary2.placeholder === void 0 && swiftBinaryOnDisk(binary2) && binaryHeaderSearchPaths(binary2, staged, app.rootDir).headers.length === 1
|
|
120346
120361
|
))
|
|
120347
120362
|
return [...binaries];
|
|
120348
|
-
const hash = (0,
|
|
120363
|
+
const hash = (0, import_node_crypto77.createHash)("sha256");
|
|
120349
120364
|
hash.update(
|
|
120350
120365
|
JSON.stringify([
|
|
120351
120366
|
inputs2.targets,
|
|
@@ -120554,12 +120569,12 @@ async function xcodeCxxReachable(app, binaries, moduleRoot, clang) {
|
|
|
120554
120569
|
);
|
|
120555
120570
|
return result;
|
|
120556
120571
|
}
|
|
120557
|
-
var import_node_child_process63,
|
|
120572
|
+
var import_node_child_process63, import_node_crypto77, import_node_fs128, import_node_path130, cachedInputs;
|
|
120558
120573
|
var init_swift_cxx_reachable = __esm({
|
|
120559
120574
|
"src/swift-cxx-reachable.ts"() {
|
|
120560
120575
|
"use strict";
|
|
120561
120576
|
import_node_child_process63 = require("node:child_process");
|
|
120562
|
-
|
|
120577
|
+
import_node_crypto77 = require("node:crypto");
|
|
120563
120578
|
import_node_fs128 = __toESM(require("node:fs"), 1);
|
|
120564
120579
|
import_node_path130 = __toESM(require("node:path"), 1);
|
|
120565
120580
|
init_is_record();
|
|
@@ -121107,7 +121122,7 @@ function fetchSwiftSdkDataPlan({ url, dataPlan }) {
|
|
|
121107
121122
|
if (!response.ok)
|
|
121108
121123
|
throw new Error(`Swift SDK data plan ${address} answered ${response.status}`);
|
|
121109
121124
|
const bytes = Buffer.from(await response.arrayBuffer());
|
|
121110
|
-
if ((0,
|
|
121125
|
+
if ((0, import_node_crypto78.createHash)("sha256").update(bytes).digest("hex") !== dataPlan)
|
|
121111
121126
|
throw new Error(`Swift SDK data plan ${address} failed its digest check`);
|
|
121112
121127
|
return bytes;
|
|
121113
121128
|
});
|
|
@@ -121212,7 +121227,7 @@ function splitSwiftSdkLaterData(directory2, binding, plan) {
|
|
|
121212
121227
|
encode2(now),
|
|
121213
121228
|
encodeNativeSdkLater({
|
|
121214
121229
|
files: later.map((bytes) => ({
|
|
121215
|
-
sha256: (0,
|
|
121230
|
+
sha256: (0, import_node_crypto78.createHash)("sha256").update(bytes).digest("hex"),
|
|
121216
121231
|
byteLength: bytes.length
|
|
121217
121232
|
})),
|
|
121218
121233
|
...needs && {
|
|
@@ -121228,11 +121243,11 @@ function splitSwiftSdkLaterData(directory2, binding, plan) {
|
|
|
121228
121243
|
later
|
|
121229
121244
|
};
|
|
121230
121245
|
}
|
|
121231
|
-
var
|
|
121246
|
+
var import_node_crypto78, ADDRESS_REACH, sdkPieces, firstAtOrAfter, pieceAt, LATER_GROUP_BYTES, MAX_LATER_GROUPS, publishedPlans;
|
|
121232
121247
|
var init_swift_sdk_later_data = __esm({
|
|
121233
121248
|
"src/swift-sdk-later-data.ts"() {
|
|
121234
121249
|
"use strict";
|
|
121235
|
-
|
|
121250
|
+
import_node_crypto78 = require("node:crypto");
|
|
121236
121251
|
init_nativeSdkBindingContract();
|
|
121237
121252
|
init_nativeWasmContract();
|
|
121238
121253
|
init_swift_sdk_image();
|
|
@@ -122897,7 +122912,7 @@ async function splitNativeWasm(input, directory2, profile, binaryen, shared, kee
|
|
|
122897
122912
|
const part = await guard((0, import_node_path133.join)(directory2, `side-${id}.wasm`), lazy, env);
|
|
122898
122913
|
const bytes = (0, import_node_fs131.readFileSync)(part.file);
|
|
122899
122914
|
assertWasmCodeOnly(bytes);
|
|
122900
|
-
return { ...part, slots: slots2, sha256: (0,
|
|
122915
|
+
return { ...part, slots: slots2, sha256: (0, import_node_crypto79.createHash)("sha256").update(bytes).digest("hex") };
|
|
122901
122916
|
}
|
|
122902
122917
|
);
|
|
122903
122918
|
const dyldGroups = parts2.flatMap(
|
|
@@ -122965,12 +122980,12 @@ function describePart(file) {
|
|
|
122965
122980
|
);
|
|
122966
122981
|
return { file, functions, byteLength: bytes.byteLength };
|
|
122967
122982
|
}
|
|
122968
|
-
var import_node_child_process66,
|
|
122983
|
+
var import_node_child_process66, import_node_crypto79, import_node_fs131, import_node_os27, import_node_path133, import_node_util16, run11, MAX_MODULE_FUNCTIONS, MAX_START_FUNCTIONS, SIDE_FUNCTIONS, SIDE_CODE_BYTES, FEATURES2, featuresOf;
|
|
122969
122984
|
var init_wasm_lazy_split = __esm({
|
|
122970
122985
|
"src/wasm-lazy-split.ts"() {
|
|
122971
122986
|
"use strict";
|
|
122972
122987
|
import_node_child_process66 = require("node:child_process");
|
|
122973
|
-
|
|
122988
|
+
import_node_crypto79 = require("node:crypto");
|
|
122974
122989
|
import_node_fs131 = require("node:fs");
|
|
122975
122990
|
import_node_os27 = require("node:os");
|
|
122976
122991
|
import_node_path133 = require("node:path");
|
|
@@ -123407,11 +123422,11 @@ async function bootSwiftPreview(launch2, profile) {
|
|
|
123407
123422
|
server.close();
|
|
123408
123423
|
}
|
|
123409
123424
|
}
|
|
123410
|
-
var
|
|
123425
|
+
var import_node_crypto80, import_node_fs132, import_node_http3, import_node_https2, import_node_os28, import_node_path134, packageName, guestPath, appPath, profileWindowMs, profileQuietMs, digest2, partDigest, platform;
|
|
123411
123426
|
var init_swift_startup_split = __esm({
|
|
123412
123427
|
"src/swift-startup-split.ts"() {
|
|
123413
123428
|
"use strict";
|
|
123414
|
-
|
|
123429
|
+
import_node_crypto80 = require("node:crypto");
|
|
123415
123430
|
import_node_fs132 = require("node:fs");
|
|
123416
123431
|
import_node_http3 = require("node:http");
|
|
123417
123432
|
import_node_https2 = require("node:https");
|
|
@@ -123436,7 +123451,7 @@ var init_swift_startup_split = __esm({
|
|
|
123436
123451
|
appPath = "/__peach/swift/startup.wasm";
|
|
123437
123452
|
profileWindowMs = 3e4;
|
|
123438
123453
|
profileQuietMs = 2e3;
|
|
123439
|
-
digest2 = (bytes) => (0,
|
|
123454
|
+
digest2 = (bytes) => (0, import_node_crypto80.createHash)("sha256").update(bytes).digest("hex");
|
|
123440
123455
|
partDigest = /^[a-f0-9]{64}$/;
|
|
123441
123456
|
platform = `${process.platform}-${process.arch}`;
|
|
123442
123457
|
}
|
|
@@ -123480,7 +123495,7 @@ function* filesUnder(absolute) {
|
|
|
123480
123495
|
}
|
|
123481
123496
|
function hashFile(absolutePath) {
|
|
123482
123497
|
try {
|
|
123483
|
-
return (0,
|
|
123498
|
+
return (0, import_node_crypto81.createHash)("sha1").update((0, import_node_fs133.readFileSync)(absolutePath)).digest("hex");
|
|
123484
123499
|
} catch {
|
|
123485
123500
|
return null;
|
|
123486
123501
|
}
|
|
@@ -123614,11 +123629,11 @@ function findStaleRoutes(monorepoRoot, routes2) {
|
|
|
123614
123629
|
}
|
|
123615
123630
|
return stale;
|
|
123616
123631
|
}
|
|
123617
|
-
var
|
|
123632
|
+
var import_node_crypto81, import_node_fs133, import_node_path135, DEV_BUILD_REBUILD_COMMAND, RECORD_DIR, PEACHSIM_ENGINE_INPUTS, ENGINE_SOURCES, ROUTES, STANDALONE_ENGINE_ROUTES, EXCLUDED_DIR_NAMES;
|
|
123618
123633
|
var init_dev_build_freshness = __esm({
|
|
123619
123634
|
"cli/dev-build-freshness.ts"() {
|
|
123620
123635
|
"use strict";
|
|
123621
|
-
|
|
123636
|
+
import_node_crypto81 = require("node:crypto");
|
|
123622
123637
|
import_node_fs133 = require("node:fs");
|
|
123623
123638
|
import_node_path135 = require("node:path");
|
|
123624
123639
|
DEV_BUILD_REBUILD_COMMAND = "bun run build:peach";
|
|
@@ -123784,7 +123799,7 @@ function nativeSourceFiles(packagePath) {
|
|
|
123784
123799
|
function swiftArtifactContentDigest(bytes) {
|
|
123785
123800
|
let digest3 = swiftArtifactDigests.get(bytes);
|
|
123786
123801
|
if (!digest3) {
|
|
123787
|
-
digest3 = (0,
|
|
123802
|
+
digest3 = (0, import_node_crypto82.createHash)("sha256").update(bytes).digest("hex");
|
|
123788
123803
|
swiftArtifactDigests.set(bytes, digest3);
|
|
123789
123804
|
}
|
|
123790
123805
|
return digest3;
|
|
@@ -123935,7 +123950,7 @@ async function wasmPortableAssembly(binaries, toolchainBin, moduleRoot) {
|
|
|
123935
123950
|
const clang = import_node_path136.default.join(toolchainBin, "clang");
|
|
123936
123951
|
const empty = (binary2, file) => {
|
|
123937
123952
|
const source = import_node_path136.default.join(binary2.dir, file);
|
|
123938
|
-
const key2 = (0,
|
|
123953
|
+
const key2 = (0, import_node_crypto82.createHash)("sha256").update(
|
|
123939
123954
|
JSON.stringify([
|
|
123940
123955
|
clang,
|
|
123941
123956
|
sdk2.sysroot,
|
|
@@ -123980,7 +123995,7 @@ async function wasmPortableAssembly(binaries, toolchainBin, moduleRoot) {
|
|
|
123980
123995
|
return new Set(portable.flat());
|
|
123981
123996
|
}
|
|
123982
123997
|
async function swiftPackages(entry, app) {
|
|
123983
|
-
const stamp = (file) => import_node_fs134.default.existsSync(file) ? (0,
|
|
123998
|
+
const stamp = (file) => import_node_fs134.default.existsSync(file) ? (0, import_node_crypto82.createHash)("sha256").update(import_node_fs134.default.readFileSync(file)).digest("hex") : null;
|
|
123984
123999
|
const owners = [...app.frameworks, app].map((target) => ({
|
|
123985
124000
|
module: target.moduleName,
|
|
123986
124001
|
products: target.packageProducts ?? []
|
|
@@ -125144,7 +125159,7 @@ async function buildSwiftResourceTable(project2, baseUrl, inputs2) {
|
|
|
125144
125159
|
const source = new TextDecoder("utf-8", { fatal: true, ignoreBOM: true }).decode(
|
|
125145
125160
|
bytes
|
|
125146
125161
|
);
|
|
125147
|
-
const sha2565 = (0,
|
|
125162
|
+
const sha2565 = (0, import_node_crypto82.createHash)("sha256").update(bytes).digest("hex");
|
|
125148
125163
|
const bundle = swiftResourceBundleForFile(bundles, key2);
|
|
125149
125164
|
if (!bundle && inputs2["Package.swift"])
|
|
125150
125165
|
throw new Error(`metal source ${key2} has no resource target bundle`);
|
|
@@ -125167,7 +125182,7 @@ async function buildSwiftResourceTable(project2, baseUrl, inputs2) {
|
|
|
125167
125182
|
const bytes = readPackageFile2(project2.packagePath, disk, limits.imageBytes);
|
|
125168
125183
|
pdfs.set(file, {
|
|
125169
125184
|
file: disk,
|
|
125170
|
-
sha256: (0,
|
|
125185
|
+
sha256: (0, import_node_crypto82.createHash)("sha256").update(bytes).digest("hex")
|
|
125171
125186
|
});
|
|
125172
125187
|
}
|
|
125173
125188
|
const pdfRasters = rasterizePdfFiles([...pdfs.values()], limits);
|
|
@@ -125213,7 +125228,7 @@ async function buildSwiftResourceTable(project2, baseUrl, inputs2) {
|
|
|
125213
125228
|
throw new Error("swift image pack exceeds the compile service caps");
|
|
125214
125229
|
}
|
|
125215
125230
|
imageBytes += bytes.length;
|
|
125216
|
-
const hash = (0,
|
|
125231
|
+
const hash = (0, import_node_crypto82.createHash)("sha256").update(bytes).digest("hex").slice(0, 16);
|
|
125217
125232
|
const bundle = table[bundlePath] ?? /* @__PURE__ */ Object.create(null);
|
|
125218
125233
|
const pixelSize = ext === ".png" ? readPngDimensions(bytes) : null;
|
|
125219
125234
|
const variant2 = {
|
|
@@ -125523,7 +125538,7 @@ function updateSwiftConfigStamp(hash, packagePath) {
|
|
|
125523
125538
|
hash.update(JSON.stringify(gates.map((name3) => swiftWasm64PlatformGates[name3])));
|
|
125524
125539
|
}
|
|
125525
125540
|
function sourceStamp(packagePath, moduleRootOverride, hosted = false) {
|
|
125526
|
-
const hash = (0,
|
|
125541
|
+
const hash = (0, import_node_crypto82.createHash)("sha256");
|
|
125527
125542
|
hash.update(packagePath);
|
|
125528
125543
|
updateSwiftConfigStamp(hash, packagePath);
|
|
125529
125544
|
const libraries = projects().get(packagePath)?.libraries;
|
|
@@ -125552,7 +125567,7 @@ function sourceStamp(packagePath, moduleRootOverride, hosted = false) {
|
|
|
125552
125567
|
return hash.digest("hex").slice(0, 16);
|
|
125553
125568
|
}
|
|
125554
125569
|
function sourceContentStamp(packagePath, moduleRootOverride) {
|
|
125555
|
-
const hash = (0,
|
|
125570
|
+
const hash = (0, import_node_crypto82.createHash)("sha256");
|
|
125556
125571
|
hash.update(compilerSourceDigest);
|
|
125557
125572
|
updateSwiftConfigStamp(hash, packagePath);
|
|
125558
125573
|
const libraries = projects().get(packagePath)?.libraries;
|
|
@@ -125584,7 +125599,7 @@ function moduleStamp(packagePath, moduleRootOverride, hosted) {
|
|
|
125584
125599
|
(root) => import_node_fs134.default.existsSync(import_node_path136.default.join(root, "toolchain.json"))
|
|
125585
125600
|
);
|
|
125586
125601
|
if (!moduleRoot) return "";
|
|
125587
|
-
const hash = (0,
|
|
125602
|
+
const hash = (0, import_node_crypto82.createHash)("sha256");
|
|
125588
125603
|
hash.update(moduleRoot);
|
|
125589
125604
|
for (const relative7 of swiftModuleInputFiles(moduleRoot)) {
|
|
125590
125605
|
hash.update(relative7);
|
|
@@ -125594,7 +125609,7 @@ function moduleStamp(packagePath, moduleRootOverride, hosted) {
|
|
|
125594
125609
|
}
|
|
125595
125610
|
function otherInputs(input, standalone) {
|
|
125596
125611
|
const { files: _files, ...rest } = input;
|
|
125597
|
-
return (0,
|
|
125612
|
+
return (0, import_node_crypto82.createHash)("sha256").update(JSON.stringify({ ...rest, standalone })).digest("hex");
|
|
125598
125613
|
}
|
|
125599
125614
|
function entryRootId(packagePath, file) {
|
|
125600
125615
|
const relative7 = import_node_path136.default.relative(packagePath, file).split(import_node_path136.default.sep).join(import_node_path136.default.posix.sep);
|
|
@@ -125616,7 +125631,7 @@ function standinLibraries(binaries, standins, rootDir, toolchain, rustWasm64) {
|
|
|
125616
125631
|
for (const standin of standins) {
|
|
125617
125632
|
if (!standin.prebuilt) continue;
|
|
125618
125633
|
const bytes = Buffer.from(standin.prebuilt.library, "base64");
|
|
125619
|
-
const digest3 = (0,
|
|
125634
|
+
const digest3 = (0, import_node_crypto82.createHash)("sha256").update(bytes).digest("hex");
|
|
125620
125635
|
const dir = import_node_path136.default.join(swiftCacheDir(), "native-archives", digest3);
|
|
125621
125636
|
import_node_fs134.default.mkdirSync(dir, { recursive: true });
|
|
125622
125637
|
const library = import_node_path136.default.join(dir, `lib${standin.module}.a`);
|
|
@@ -125965,7 +125980,7 @@ function swiftBuildRoot(packagePath, moduleRoot) {
|
|
|
125965
125980
|
return import_node_path136.default.join(
|
|
125966
125981
|
swiftCacheDir(),
|
|
125967
125982
|
"swift-builds",
|
|
125968
|
-
(0,
|
|
125983
|
+
(0, import_node_crypto82.createHash)("sha256").update(`${compilerKey}\0${buildKeyPath}`).digest("hex").slice(0, 16)
|
|
125969
125984
|
);
|
|
125970
125985
|
}
|
|
125971
125986
|
function installedWorkspaceInput(packagePath, entry, moduleRoot) {
|
|
@@ -126266,7 +126281,7 @@ async function fetchSwiftDyldTable(moduleUrl, module2, signal) {
|
|
|
126266
126281
|
const response = await fetch(url, { signal });
|
|
126267
126282
|
if (!response.ok) throw new Error(`swift compile: ${url} answered ${response.status}`);
|
|
126268
126283
|
const bytes = Buffer.from(await response.arrayBuffer());
|
|
126269
|
-
if (bytes.length !== byteLength || (0,
|
|
126284
|
+
if (bytes.length !== byteLength || (0, import_node_crypto82.createHash)("sha256").update(bytes).digest("hex") !== sha2565)
|
|
126270
126285
|
throw new Error(`swift compile: ${url} does not match its module's index`);
|
|
126271
126286
|
return { dyldTable: { sha256: sha2565, bytes } };
|
|
126272
126287
|
}
|
|
@@ -126529,10 +126544,10 @@ async function splitSdkBinding(sdk2, splitKey, plan) {
|
|
|
126529
126544
|
sdk2.binding.bytes,
|
|
126530
126545
|
plan
|
|
126531
126546
|
);
|
|
126532
|
-
const digest3 = (0,
|
|
126547
|
+
const digest3 = (0, import_node_crypto82.createHash)("sha256").update(split.binding).digest("hex");
|
|
126533
126548
|
sdkBindingFiles.set(digest3, split.binding);
|
|
126534
126549
|
for (const later of split.later)
|
|
126535
|
-
sdkBindingFiles.set((0,
|
|
126550
|
+
sdkBindingFiles.set((0, import_node_crypto82.createHash)("sha256").update(later).digest("hex"), later);
|
|
126536
126551
|
sdkSplitBindings.set(key2, digest3);
|
|
126537
126552
|
}
|
|
126538
126553
|
function swiftCodePartAssets(origin, appParts, sdkDigest) {
|
|
@@ -126599,7 +126614,7 @@ function swiftSdkEntryAssets(origin, image, sdkDigest = image.sdk?.sha256) {
|
|
|
126599
126614
|
function swiftSdkStartup(sdk2, packagePath, artifactHash, metadata, launch2, runtimeRootOverride) {
|
|
126600
126615
|
const { key: key2 } = sdk2;
|
|
126601
126616
|
const normalizedPackage = normalizedSwiftPackagePath(packagePath);
|
|
126602
|
-
const app = (0,
|
|
126617
|
+
const app = (0, import_node_crypto82.createHash)("sha256").update(
|
|
126603
126618
|
JSON.stringify([
|
|
126604
126619
|
normalizedPackage,
|
|
126605
126620
|
launch2.environment,
|
|
@@ -126631,7 +126646,7 @@ function swiftSdkStartup(sdk2, packagePath, artifactHash, metadata, launch2, run
|
|
|
126631
126646
|
},
|
|
126632
126647
|
app
|
|
126633
126648
|
);
|
|
126634
|
-
const name3 = (0,
|
|
126649
|
+
const name3 = (0, import_node_crypto82.createHash)("sha256").update(split.primary).digest("hex");
|
|
126635
126650
|
sdkPieces2.set(name3, split.primary);
|
|
126636
126651
|
for (const [digest3, bytes] of split.parts) sdkPieces2.set(digest3, bytes);
|
|
126637
126652
|
sdkStartupParts.set(name3, split.parts);
|
|
@@ -126900,13 +126915,13 @@ function disposeSwiftProject(packagePath, signal) {
|
|
|
126900
126915
|
xcodeProjects().delete(packagePath);
|
|
126901
126916
|
sourceEntries().delete(packagePath);
|
|
126902
126917
|
}
|
|
126903
|
-
var import_node_async_hooks2, import_node_child_process67,
|
|
126918
|
+
var import_node_async_hooks2, import_node_child_process67, import_node_crypto82, import_node_fs134, import_node_os29, import_node_path136, ARTIFACT_PATH, RESOURCE_PATH, ICU_PATH, SDK_PATH, SDK_BINDING_PATH, SKIP_ROOT_DIRS, NATIVE_DESCRIPTOR, NATIVE_GLUE, SwiftMissingModulesError, startupImages, swiftArtifactDigests, sharedProjects, projectScope, projects, sharedSourceEntries, sourceEntries, sharedXcodeProjects, xcodeProjects, preparedScriptInputs, emptyWasmAssembly, XCODE_APP_DIR, XCODE_FRAMEWORKS_DIR, XCODE_PACKAGES_DIR, layoutScope, HOSTED_LIMITS, LOCAL_LIMITS, inputLimits, RESOURCE_CONTENT_TYPES, API_GAP_PATTERNS, IOS_SDK_FRAMEWORKS, sdkStartups, sdkStartupParts, sdkStartupPlans, sdkPieces2, sdkSplitBindings, sdkBindingFiles, servedSdkBinding;
|
|
126904
126919
|
var init_swift_host = __esm({
|
|
126905
126920
|
"src/swift-host.ts"() {
|
|
126906
126921
|
"use strict";
|
|
126907
126922
|
import_node_async_hooks2 = require("node:async_hooks");
|
|
126908
126923
|
import_node_child_process67 = require("node:child_process");
|
|
126909
|
-
|
|
126924
|
+
import_node_crypto82 = require("node:crypto");
|
|
126910
126925
|
import_node_fs134 = __toESM(require("node:fs"), 1);
|
|
126911
126926
|
import_node_os29 = __toESM(require("node:os"), 1);
|
|
126912
126927
|
import_node_path136 = __toESM(require("node:path"), 1);
|
|
@@ -127665,7 +127680,7 @@ function hashTree(root) {
|
|
|
127665
127680
|
for (const entry of import_node_fs137.default.readdirSync(root, { recursive: true, withFileTypes: true })) {
|
|
127666
127681
|
if (!entry.isFile()) continue;
|
|
127667
127682
|
const file = import_node_path139.default.join(entry.parentPath, entry.name);
|
|
127668
|
-
hashes[import_node_path139.default.relative(root, file).split(import_node_path139.default.sep).join("/")] = (0,
|
|
127683
|
+
hashes[import_node_path139.default.relative(root, file).split(import_node_path139.default.sep).join("/")] = (0, import_node_crypto83.createHash)("sha256").update(import_node_fs137.default.readFileSync(file)).digest("hex");
|
|
127669
127684
|
}
|
|
127670
127685
|
return Object.fromEntries(Object.entries(hashes).sort(([a], [b]) => a < b ? -1 : 1));
|
|
127671
127686
|
}
|
|
@@ -127715,12 +127730,12 @@ async function runInstalledTurboCodegen(appRoot, outDir, signal) {
|
|
|
127715
127730
|
files: hashTree(generatedRoot)
|
|
127716
127731
|
};
|
|
127717
127732
|
}
|
|
127718
|
-
var import_node_child_process68,
|
|
127733
|
+
var import_node_child_process68, import_node_crypto83, import_node_fs137, import_node_module17, import_node_path139, import_node_util17, run12, RENDERER_PODS, RENDERER_PODS_VERSIONED, COMPILED_SOURCE, LEGACY_BRIDGE_DEV_SUPPORT, LEGACY_BRIDGE_PODS, LEGACY_BRIDGE_PODS_VERSIONED;
|
|
127719
127734
|
var init_turbo_codegen_intake = __esm({
|
|
127720
127735
|
"src/turbo-codegen-intake.ts"() {
|
|
127721
127736
|
"use strict";
|
|
127722
127737
|
import_node_child_process68 = require("node:child_process");
|
|
127723
|
-
|
|
127738
|
+
import_node_crypto83 = require("node:crypto");
|
|
127724
127739
|
import_node_fs137 = __toESM(require("node:fs"), 1);
|
|
127725
127740
|
import_node_module17 = require("node:module");
|
|
127726
127741
|
import_node_path139 = __toESM(require("node:path"), 1);
|
|
@@ -131671,11 +131686,11 @@ extern "C" __attribute__((export_name("peach_fabric_component_names"))) const ch
|
|
|
131671
131686
|
}
|
|
131672
131687
|
`;
|
|
131673
131688
|
}
|
|
131674
|
-
var
|
|
131689
|
+
var import_node_crypto84, import_node_fs138, import_node_path140, TURBO_CORE_TARGET, TURBO_FMT_TARGET, TURBO_ENTRY_HEADER, TURBO_CORE_PUBLIC_HEADERS, REGISTRATION, CODEGEN_OBJC, UNIT, HEADER5, OBJC2, OBJC_TURBO, OBJC_BRIDGE, OBJC_REGISTERED, REACT_NATIVE_UNITS, REACT_NATIVE_INCLUDE_ROOTS, REACT_NATIVE_OBJC_UNITS, REACT_NATIVE_OBJC_VERSIONED_UNITS, REACT_NATIVE_HEADER_DIRS, REACT_NATIVE_BARE_HEADER_DIRS, DECLARED_MODULE_NAME, EXPORTED_MODULE, sha2564, podspecList, versionParts, iosOf, JS_CALL_INVOKER, FABRIC_HOST_INCLUDES, FABRIC_HOST_PAPER_INCLUDES, PAPER_UIKIT_BRIDGE_SWIFT;
|
|
131675
131690
|
var init_turbo_source = __esm({
|
|
131676
131691
|
"src/turbo-source.ts"() {
|
|
131677
131692
|
"use strict";
|
|
131678
|
-
|
|
131693
|
+
import_node_crypto84 = require("node:crypto");
|
|
131679
131694
|
import_node_fs138 = __toESM(require("node:fs"), 1);
|
|
131680
131695
|
import_node_path140 = __toESM(require("node:path"), 1);
|
|
131681
131696
|
init_cocoapods_trunk();
|
|
@@ -131803,7 +131818,7 @@ var init_turbo_source = __esm({
|
|
|
131803
131818
|
];
|
|
131804
131819
|
DECLARED_MODULE_NAME = /\bName\(\s*"(\w+)"\s*\)/g;
|
|
131805
131820
|
EXPORTED_MODULE = /\bRCT_(?:EXPORT_MODULE(?:_NO_LOAD)?|EXTERN_MODULE)\s*\(\s*(\w*)/g;
|
|
131806
|
-
sha2564 = (data) => (0,
|
|
131821
|
+
sha2564 = (data) => (0, import_node_crypto84.createHash)("sha256").update(data).digest("hex");
|
|
131807
131822
|
podspecList = podspecAttribute;
|
|
131808
131823
|
versionParts = (version2) => version2.split(/[.-]/).map((p) => Number(p) || 0);
|
|
131809
131824
|
iosOf = (member) => object7(member.ios) ? member.ios : null;
|
|
@@ -132603,7 +132618,7 @@ function retainInstalledReactNativeDeclarations(snapshot, options2, skipped) {
|
|
|
132603
132618
|
}
|
|
132604
132619
|
async function prepareTurboCompileInput(options2) {
|
|
132605
132620
|
await prepareTurboSourceDependencies(options2.reactNativeRoot);
|
|
132606
|
-
const key2 = (0,
|
|
132621
|
+
const key2 = (0, import_node_crypto85.createHash)("sha256").update(options2.providers.map(({ root }) => import_node_fs139.default.realpathSync(root)).join("\0")).update("\0").update(import_node_fs139.default.realpathSync(options2.moduleRoot)).digest("hex");
|
|
132607
132622
|
const scratch2 = import_node_path141.default.join(import_node_os30.default.tmpdir(), "peach-turbo-swift", key2);
|
|
132608
132623
|
import_node_fs139.default.mkdirSync(scratch2, { recursive: true });
|
|
132609
132624
|
const codegenDir = import_node_fs139.default.mkdtempSync(import_node_path141.default.join(scratch2, "codegen-"));
|
|
@@ -132804,11 +132819,11 @@ async function compileTurboModule(options2) {
|
|
|
132804
132819
|
collection
|
|
132805
132820
|
};
|
|
132806
132821
|
}
|
|
132807
|
-
var
|
|
132822
|
+
var import_node_crypto85, import_node_fs139, import_node_module18, import_node_os30, import_node_path141;
|
|
132808
132823
|
var init_turbo_compile = __esm({
|
|
132809
132824
|
"src/turbo-compile.ts"() {
|
|
132810
132825
|
"use strict";
|
|
132811
|
-
|
|
132826
|
+
import_node_crypto85 = require("node:crypto");
|
|
132812
132827
|
import_node_fs139 = __toESM(require("node:fs"), 1);
|
|
132813
132828
|
import_node_module18 = require("node:module");
|
|
132814
132829
|
import_node_os30 = __toESM(require("node:os"), 1);
|
|
@@ -133025,8 +133040,8 @@ function reactNativeCoreEntry(reactNativeRoot, moduleRoot, mode) {
|
|
|
133025
133040
|
);
|
|
133026
133041
|
if (!isRecord(manifest) || typeof manifest.version !== "string")
|
|
133027
133042
|
throw new Error(`${reactNativeRoot}: react-native has no version`);
|
|
133028
|
-
const headers = (0,
|
|
133029
|
-
const sources = (0,
|
|
133043
|
+
const headers = (0, import_node_crypto86.createHash)("sha256");
|
|
133044
|
+
const sources = (0, import_node_crypto86.createHash)("sha256");
|
|
133030
133045
|
const walk4 = (relative7) => {
|
|
133031
133046
|
for (const file of import_node_fs141.default.readdirSync(import_node_path143.default.join(reactNativeRoot, relative7), { withFileTypes: true }).sort((a, b) => a.name < b.name ? -1 : a.name > b.name ? 1 : 0)) {
|
|
133032
133047
|
if (file.name === "node_modules" || file.name.startsWith(".")) continue;
|
|
@@ -133133,7 +133148,7 @@ function linkReactNativeCore(collection, core, moduleRoot) {
|
|
|
133133
133148
|
const file = import_node_path143.default.join(
|
|
133134
133149
|
cacheDir(),
|
|
133135
133150
|
"native-archives",
|
|
133136
|
-
`${(0,
|
|
133151
|
+
`${(0, import_node_crypto86.createHash)("sha256").update(data).digest("hex")}.a`
|
|
133137
133152
|
);
|
|
133138
133153
|
import_node_fs141.default.mkdirSync(import_node_path143.default.dirname(file), { recursive: true });
|
|
133139
133154
|
if (!import_node_fs141.default.existsSync(file)) import_node_fs141.default.writeFileSync(file, Buffer.from(data, "base64"));
|
|
@@ -133143,11 +133158,11 @@ function linkReactNativeCore(collection, core, moduleRoot) {
|
|
|
133143
133158
|
}
|
|
133144
133159
|
}
|
|
133145
133160
|
}
|
|
133146
|
-
var
|
|
133161
|
+
var import_node_crypto86, import_node_fs141, import_node_module19, import_node_path143, import_node_util18, recipe, strings4, building;
|
|
133147
133162
|
var init_react_native_core = __esm({
|
|
133148
133163
|
"src/react-native-core.ts"() {
|
|
133149
133164
|
"use strict";
|
|
133150
|
-
|
|
133165
|
+
import_node_crypto86 = require("node:crypto");
|
|
133151
133166
|
import_node_fs141 = __toESM(require("node:fs"), 1);
|
|
133152
133167
|
import_node_module19 = require("node:module");
|
|
133153
133168
|
import_node_path143 = __toESM(require("node:path"), 1);
|
|
@@ -133172,7 +133187,7 @@ function exportedNames(moduleRoot, name3) {
|
|
|
133172
133187
|
const modules = import_node_path144.default.join(moduleRoot, "modules");
|
|
133173
133188
|
const module2 = import_node_path144.default.join(modules, `${name3}.swiftmodule`);
|
|
133174
133189
|
if (!import_node_fs142.default.existsSync(module2)) return /* @__PURE__ */ new Set();
|
|
133175
|
-
const key2 = (0,
|
|
133190
|
+
const key2 = (0, import_node_crypto87.createHash)("sha256").update(import_node_fs142.default.readFileSync(module2)).digest("hex");
|
|
133176
133191
|
const directory2 = import_node_path144.default.join(swiftCacheDir(), "swift-public-names");
|
|
133177
133192
|
const receipt = import_node_path144.default.join(directory2, `${key2}.json`);
|
|
133178
133193
|
if (import_node_fs142.default.existsSync(receipt)) {
|
|
@@ -133255,12 +133270,12 @@ function clangTypeOwnership(moduleRoot, module2) {
|
|
|
133255
133270
|
}
|
|
133256
133271
|
);
|
|
133257
133272
|
}
|
|
133258
|
-
var import_node_child_process70,
|
|
133273
|
+
var import_node_child_process70, import_node_crypto87, import_node_fs142, import_node_path144, blockTypedef, enumTypedef, enumConstant, swiftPrivate;
|
|
133259
133274
|
var init_swift_clang_type_ownership = __esm({
|
|
133260
133275
|
"src/swift-clang-type-ownership.ts"() {
|
|
133261
133276
|
"use strict";
|
|
133262
133277
|
import_node_child_process70 = require("node:child_process");
|
|
133263
|
-
|
|
133278
|
+
import_node_crypto87 = require("node:crypto");
|
|
133264
133279
|
import_node_fs142 = __toESM(require("node:fs"), 1);
|
|
133265
133280
|
import_node_path144 = __toESM(require("node:path"), 1);
|
|
133266
133281
|
init_is_record();
|
|
@@ -134915,7 +134930,7 @@ function targetSettings2(units) {
|
|
|
134915
134930
|
}
|
|
134916
134931
|
function oneSDKStamp(oneSDK) {
|
|
134917
134932
|
if (!oneSDK) return "";
|
|
134918
|
-
const hash = (0,
|
|
134933
|
+
const hash = (0, import_node_crypto88.createHash)("sha256");
|
|
134919
134934
|
for (const files2 of [oneSDK.targets, oneSDK.entry])
|
|
134920
134935
|
for (const [name3, source] of [...files2].sort(([a], [b]) => a.localeCompare(b)))
|
|
134921
134936
|
hash.update(`${name3}\0${source}\0`);
|
|
@@ -134966,7 +134981,7 @@ ${bridgeModules.length ? "import React\n" : ""}${oneSDK ? "import One\nimport On
|
|
|
134966
134981
|
`;
|
|
134967
134982
|
}
|
|
134968
134983
|
function expoSwiftPreparedKey(base2, units, reactProviderStamp) {
|
|
134969
|
-
const hash = (0,
|
|
134984
|
+
const hash = (0, import_node_crypto88.createHash)("sha256");
|
|
134970
134985
|
hash.update(base2);
|
|
134971
134986
|
hash.update(reactProviderStamp);
|
|
134972
134987
|
for (const unit2 of units) {
|
|
@@ -135340,8 +135355,8 @@ async function compileExpoSwiftModulesTraced(root, base2, publishArtifact, optio
|
|
|
135340
135355
|
}
|
|
135341
135356
|
return provider;
|
|
135342
135357
|
})() : void 0;
|
|
135343
|
-
const reactProviderStamp = reactProvider ? (0,
|
|
135344
|
-
const key2 = (0,
|
|
135358
|
+
const reactProviderStamp = reactProvider ? (0, import_node_crypto88.createHash)("sha256").update(JSON.stringify(reactProvider)).digest("hex") : "";
|
|
135359
|
+
const key2 = (0, import_node_crypto88.createHash)("sha256").update(import_node_fs143.default.realpathSync(root)).digest("hex");
|
|
135345
135360
|
const unitContentStamp = (unit2) => sourceContentStamp(expoSwiftPackage(key2, unit2.moduleId), module2.root) + (unit2.reactNativeProvider ? `:${reactProviderStamp}` : "");
|
|
135346
135361
|
const failures = /* @__PURE__ */ new Map();
|
|
135347
135362
|
const failureRecords = /* @__PURE__ */ new Map();
|
|
@@ -135783,13 +135798,13 @@ ${diagnostics}`}`
|
|
|
135783
135798
|
}
|
|
135784
135799
|
return true;
|
|
135785
135800
|
}
|
|
135786
|
-
var import_node_async_hooks3, import_node_child_process71,
|
|
135801
|
+
var import_node_async_hooks3, import_node_child_process71, import_node_crypto88, import_node_fs143, import_node_module20, import_node_os31, import_node_path145, import_node_url7, import_node_util19, run13, scriptEnv, EXPO_SWIFT_ROUTE, EXPO_SWIFT_ENTRY, WITNESS_BATCH, traceStore, discoveryCache, preparedCache, savedFs, ignoredRoots, ownTemporaryRoots, EXPO_MODULE_SCAN_TIMEOUT_MS, preparedExpoSwift, openPreparations, ExpoSwiftLinkRefusal;
|
|
135787
135802
|
var init_expo_swift_host = __esm({
|
|
135788
135803
|
"src/expo-swift-host.ts"() {
|
|
135789
135804
|
"use strict";
|
|
135790
135805
|
import_node_async_hooks3 = require("node:async_hooks");
|
|
135791
135806
|
import_node_child_process71 = require("node:child_process");
|
|
135792
|
-
|
|
135807
|
+
import_node_crypto88 = require("node:crypto");
|
|
135793
135808
|
import_node_fs143 = __toESM(require("node:fs"), 1);
|
|
135794
135809
|
import_node_module20 = require("node:module");
|
|
135795
135810
|
import_node_os31 = __toESM(require("node:os"), 1);
|
|
@@ -139062,7 +139077,7 @@ async function createIdentity() {
|
|
|
139062
139077
|
const keys = await crypto.subtle.generateKey(algorithm, true, ["sign", "verify"]);
|
|
139063
139078
|
const certificate = await import_x5092.X509CertificateGenerator.createSelfSigned(
|
|
139064
139079
|
{
|
|
139065
|
-
serialNumber: (0,
|
|
139080
|
+
serialNumber: (0, import_node_crypto89.randomBytes)(16).toString("hex"),
|
|
139066
139081
|
name: "CN=localhost",
|
|
139067
139082
|
notBefore: new Date(Date.now() - 6e4),
|
|
139068
139083
|
notAfter: new Date(Date.now() + 365 * 24 * 60 * 6e4),
|
|
@@ -139081,7 +139096,7 @@ async function createIdentity() {
|
|
|
139081
139096
|
${privateKey.toString("base64").match(/.{1,64}/g)?.join("\n")}
|
|
139082
139097
|
-----END PRIVATE KEY-----
|
|
139083
139098
|
`,
|
|
139084
|
-
spki: (0,
|
|
139099
|
+
spki: (0, import_node_crypto89.createHash)("sha256").update(Buffer.from(await crypto.subtle.exportKey("spki", keys.publicKey))).digest("base64")
|
|
139085
139100
|
};
|
|
139086
139101
|
}
|
|
139087
139102
|
async function startFetchProxyTransport(identityPath, hasLiveSims = () => false) {
|
|
@@ -139155,11 +139170,11 @@ async function startFetchProxyTransport(identityPath, hasLiveSims = () => false)
|
|
|
139155
139170
|
);
|
|
139156
139171
|
}
|
|
139157
139172
|
}
|
|
139158
|
-
var
|
|
139173
|
+
var import_node_crypto89, import_node_fs147, import_node_http23, import_node_path149, import_x5092;
|
|
139159
139174
|
var init_fetch_proxy_transport = __esm({
|
|
139160
139175
|
"src/host/fetch-proxy-transport.ts"() {
|
|
139161
139176
|
"use strict";
|
|
139162
|
-
|
|
139177
|
+
import_node_crypto89 = require("node:crypto");
|
|
139163
139178
|
import_node_fs147 = require("node:fs");
|
|
139164
139179
|
import_node_http23 = require("node:http2");
|
|
139165
139180
|
import_node_path149 = __toESM(require("node:path"), 1);
|
|
@@ -140391,10 +140406,10 @@ function stageHostBytes(bytes, origin, extension = "") {
|
|
|
140391
140406
|
}
|
|
140392
140407
|
async function stageHostDerivedBytes(input, producer, origin, extension, derive) {
|
|
140393
140408
|
const directory2 = prepareStagedDirectory();
|
|
140394
|
-
const inputDigest = (0,
|
|
140409
|
+
const inputDigest = (0, import_node_crypto90.createHash)("sha256").update(input).digest("hex");
|
|
140395
140410
|
const index = import_node_path153.default.join(
|
|
140396
140411
|
directory2,
|
|
140397
|
-
`derived-${(0,
|
|
140412
|
+
`derived-${(0, import_node_crypto90.createHash)("sha256").update(`${producer}\0${inputDigest}`).digest("hex")}`
|
|
140398
140413
|
);
|
|
140399
140414
|
const recorded = import_node_fs151.default.existsSync(index) ? import_node_fs151.default.readFileSync(index, "utf8") : "";
|
|
140400
140415
|
if (STAGED_NAME.test(recorded) && import_node_fs151.default.existsSync(import_node_path153.default.join(directory2, recorded))) {
|
|
@@ -140405,7 +140420,7 @@ async function stageHostDerivedBytes(input, producer, origin, extension, derive)
|
|
|
140405
140420
|
return new URL(STAGED_PREFIX + recorded, origin).toString();
|
|
140406
140421
|
}
|
|
140407
140422
|
const staged = writeStagedBytes(await derive(), origin, extension, directory2);
|
|
140408
|
-
const temporary = import_node_path153.default.join(directory2, (0,
|
|
140423
|
+
const temporary = import_node_path153.default.join(directory2, (0, import_node_crypto90.randomUUID)());
|
|
140409
140424
|
try {
|
|
140410
140425
|
import_node_fs151.default.writeFileSync(temporary, new URL(staged).pathname.slice(STAGED_PREFIX.length), {
|
|
140411
140426
|
flag: "wx"
|
|
@@ -140432,7 +140447,7 @@ function stageHostMetroAssets(assets2, origin) {
|
|
|
140432
140447
|
const name3 = staged.pathname.slice(STAGED_PREFIX.length);
|
|
140433
140448
|
const destination = import_node_path153.default.join(directory2, index);
|
|
140434
140449
|
stagedCapture.getStore()?.add(index);
|
|
140435
|
-
const temporary = import_node_path153.default.join(directory2, (0,
|
|
140450
|
+
const temporary = import_node_path153.default.join(directory2, (0, import_node_crypto90.randomUUID)());
|
|
140436
140451
|
try {
|
|
140437
140452
|
import_node_fs151.default.writeFileSync(temporary, name3, { flag: "wx" });
|
|
140438
140453
|
try {
|
|
@@ -140457,7 +140472,7 @@ function metroIndexName(url) {
|
|
|
140457
140472
|
url.searchParams.get("unstable_path"),
|
|
140458
140473
|
hashes[0]
|
|
140459
140474
|
]);
|
|
140460
|
-
return `metro-${(0,
|
|
140475
|
+
return `metro-${(0, import_node_crypto90.createHash)("sha256").update(key2).digest("hex")}`;
|
|
140461
140476
|
}
|
|
140462
140477
|
function metroRequestIndex(rawUrl) {
|
|
140463
140478
|
if (!rawUrl?.startsWith("/") || rawUrl.startsWith("//")) return null;
|
|
@@ -140485,7 +140500,7 @@ function prepareStagedDirectory() {
|
|
|
140485
140500
|
return directory2;
|
|
140486
140501
|
}
|
|
140487
140502
|
function writeStagedBytes(bytes, origin, extension, directory2) {
|
|
140488
|
-
const digest3 = (0,
|
|
140503
|
+
const digest3 = (0, import_node_crypto90.createHash)("sha256").update(bytes).digest("hex");
|
|
140489
140504
|
extension = extension.toLowerCase();
|
|
140490
140505
|
const name3 = STAGED_NAME.test(digest3 + extension) ? digest3 + extension : digest3;
|
|
140491
140506
|
stagedCapture.getStore()?.add(name3);
|
|
@@ -140494,7 +140509,7 @@ function writeStagedBytes(bytes, origin, extension, directory2) {
|
|
|
140494
140509
|
if (import_node_fs151.default.existsSync(destination)) {
|
|
140495
140510
|
import_node_fs151.default.utimesSync(destination, new Date(now), new Date(now));
|
|
140496
140511
|
} else {
|
|
140497
|
-
const temporary = import_node_path153.default.join(directory2, (0,
|
|
140512
|
+
const temporary = import_node_path153.default.join(directory2, (0, import_node_crypto90.randomUUID)());
|
|
140498
140513
|
try {
|
|
140499
140514
|
import_node_fs151.default.writeFileSync(temporary, bytes, { flag: "wx" });
|
|
140500
140515
|
import_node_fs151.default.renameSync(temporary, destination);
|
|
@@ -140566,12 +140581,12 @@ async function handleStagedHostFileRequest(req, res) {
|
|
|
140566
140581
|
throw error;
|
|
140567
140582
|
}
|
|
140568
140583
|
}
|
|
140569
|
-
var import_node_async_hooks4,
|
|
140584
|
+
var import_node_async_hooks4, import_node_crypto90, import_node_fs151, import_node_path153, stagedCapture, STAGED_PREFIX, STAGED_NAME, METRO_INDEX_NAME, STAGED_RETENTION_MS;
|
|
140570
140585
|
var init_staged_host_files = __esm({
|
|
140571
140586
|
"src/host/staged-host-files.ts"() {
|
|
140572
140587
|
"use strict";
|
|
140573
140588
|
import_node_async_hooks4 = require("node:async_hooks");
|
|
140574
|
-
|
|
140589
|
+
import_node_crypto90 = require("node:crypto");
|
|
140575
140590
|
import_node_fs151 = __toESM(require("node:fs"), 1);
|
|
140576
140591
|
import_node_path153 = __toESM(require("node:path"), 1);
|
|
140577
140592
|
init_uttype_mime();
|
|
@@ -141460,7 +141475,7 @@ async function oneNativeControlsPackage(appRoot, linkedGroups, sdk2) {
|
|
|
141460
141475
|
""
|
|
141461
141476
|
].join("\n");
|
|
141462
141477
|
}
|
|
141463
|
-
const digest3 = (0,
|
|
141478
|
+
const digest3 = (0, import_node_crypto91.createHash)("sha256").update(manifest);
|
|
141464
141479
|
for (const [name3, source] of files2)
|
|
141465
141480
|
digest3.update(name3).update("\0").update(source).update("\0");
|
|
141466
141481
|
const key2 = digest3.digest("hex").slice(0, 16);
|
|
@@ -141482,11 +141497,11 @@ async function oneNativeControlsPackage(appRoot, linkedGroups, sdk2) {
|
|
|
141482
141497
|
oneSDKModules: bindings && [...bindings.modules]
|
|
141483
141498
|
};
|
|
141484
141499
|
}
|
|
141485
|
-
var
|
|
141500
|
+
var import_node_crypto91, import_node_fs153, import_node_module21, import_node_path155, import_node_url8, ONE_SDK_DEFINES, BRIDGE_SWIFT, ONE_SDK_RUNTIME_SOURCES;
|
|
141486
141501
|
var init_one_native_controls_package = __esm({
|
|
141487
141502
|
"src/one-native-controls-package.ts"() {
|
|
141488
141503
|
"use strict";
|
|
141489
|
-
|
|
141504
|
+
import_node_crypto91 = require("node:crypto");
|
|
141490
141505
|
import_node_fs153 = __toESM(require("node:fs"), 1);
|
|
141491
141506
|
import_node_module21 = require("node:module");
|
|
141492
141507
|
import_node_path155 = __toESM(require("node:path"), 1);
|
|
@@ -142724,7 +142739,7 @@ async function readOneWidgetSources(appRoot) {
|
|
|
142724
142739
|
if (!Buffer.from(text7).equals(bytes))
|
|
142725
142740
|
throw new Error(`One widget prebuild source is not UTF-8: ${file}`);
|
|
142726
142741
|
files2.set(name3, text7);
|
|
142727
|
-
sources[import_node_path157.default.relative(root, file).split(import_node_path157.default.sep).join("/")] = (0,
|
|
142742
|
+
sources[import_node_path157.default.relative(root, file).split(import_node_path157.default.sep).join("/")] = (0, import_node_crypto92.createHash)("sha256").update(bytes).digest("hex");
|
|
142728
142743
|
}
|
|
142729
142744
|
const contract = files2.get("OneWidgetContract.swift") ?? "";
|
|
142730
142745
|
const source = files2.get("OneWidget.swift") ?? "";
|
|
@@ -142748,17 +142763,17 @@ async function configuredOneWidget(appRoot, bundleUrl, packageUrl) {
|
|
|
142748
142763
|
return {
|
|
142749
142764
|
metadata: source.widget,
|
|
142750
142765
|
projectRoot: source.root,
|
|
142751
|
-
appIdentity: (0,
|
|
142766
|
+
appIdentity: (0, import_node_crypto92.createHash)("sha256").update(JSON.stringify([source.root, source.widget.bundleId])).digest("hex"),
|
|
142752
142767
|
bundleUrl,
|
|
142753
142768
|
packageUrl,
|
|
142754
142769
|
urlSchemes: source.urlSchemes
|
|
142755
142770
|
};
|
|
142756
142771
|
}
|
|
142757
|
-
var
|
|
142772
|
+
var import_node_crypto92, import_node_fs155, import_node_path157, ONE_WIDGET_PACKAGE, nonEmpty;
|
|
142758
142773
|
var init_one_widget_metadata = __esm({
|
|
142759
142774
|
"src/one-widget-metadata.ts"() {
|
|
142760
142775
|
"use strict";
|
|
142761
|
-
|
|
142776
|
+
import_node_crypto92 = require("node:crypto");
|
|
142762
142777
|
import_node_fs155 = __toESM(require("node:fs"), 1);
|
|
142763
142778
|
import_node_path157 = __toESM(require("node:path"), 1);
|
|
142764
142779
|
init_is_record();
|
|
@@ -142792,7 +142807,7 @@ async function oneWidgetPackage(appRoot) {
|
|
|
142792
142807
|
const packagePath = import_node_path158.default.join(
|
|
142793
142808
|
import_node_os33.default.tmpdir(),
|
|
142794
142809
|
"peach-one-widgets",
|
|
142795
|
-
(0,
|
|
142810
|
+
(0, import_node_crypto93.createHash)("sha256").update(root).digest("hex"),
|
|
142796
142811
|
ONE_WIDGET_PACKAGE
|
|
142797
142812
|
);
|
|
142798
142813
|
import_node_fs156.default.mkdirSync(packagePath, { recursive: true });
|
|
@@ -142806,11 +142821,11 @@ async function oneWidgetPackage(appRoot) {
|
|
|
142806
142821
|
widget
|
|
142807
142822
|
};
|
|
142808
142823
|
}
|
|
142809
|
-
var
|
|
142824
|
+
var import_node_crypto93, import_node_fs156, import_node_os33, import_node_path158;
|
|
142810
142825
|
var init_one_widget_package = __esm({
|
|
142811
142826
|
"src/one-widget-package.ts"() {
|
|
142812
142827
|
"use strict";
|
|
142813
|
-
|
|
142828
|
+
import_node_crypto93 = require("node:crypto");
|
|
142814
142829
|
import_node_fs156 = __toESM(require("node:fs"), 1);
|
|
142815
142830
|
import_node_os33 = __toESM(require("node:os"), 1);
|
|
142816
142831
|
import_node_path158 = __toESM(require("node:path"), 1);
|
|
@@ -143026,7 +143041,7 @@ var init_android_view_classes = __esm({
|
|
|
143026
143041
|
|
|
143027
143042
|
// src/java-module-abi.ts
|
|
143028
143043
|
async function readJavaModuleSpecs(files2, sdkRoot, toolchain) {
|
|
143029
|
-
const digest3 = (0,
|
|
143044
|
+
const digest3 = (0, import_node_crypto94.createHash)("sha256");
|
|
143030
143045
|
const parent = import_node_path160.default.join(kotlinHome(), "java-specs");
|
|
143031
143046
|
import_node_fs158.default.mkdirSync(parent, { recursive: true });
|
|
143032
143047
|
const work = import_node_fs158.default.mkdtempSync(import_node_path160.default.join(parent, ".read-"));
|
|
@@ -143123,12 +143138,12 @@ async function compileJavaModuleAbi(input) {
|
|
|
143123
143138
|
);
|
|
143124
143139
|
return library;
|
|
143125
143140
|
}
|
|
143126
|
-
var import_node_child_process74,
|
|
143141
|
+
var import_node_child_process74, import_node_crypto94, import_node_fs158, import_node_path160, import_node_util20, run14, JAVA_BINDINGS_INITIALIZER;
|
|
143127
143142
|
var init_java_module_abi = __esm({
|
|
143128
143143
|
"src/java-module-abi.ts"() {
|
|
143129
143144
|
"use strict";
|
|
143130
143145
|
import_node_child_process74 = require("node:child_process");
|
|
143131
|
-
|
|
143146
|
+
import_node_crypto94 = require("node:crypto");
|
|
143132
143147
|
import_node_fs158 = __toESM(require("node:fs"), 1);
|
|
143133
143148
|
import_node_path160 = __toESM(require("node:path"), 1);
|
|
143134
143149
|
import_node_util20 = require("node:util");
|
|
@@ -143562,7 +143577,7 @@ function zipSources(bytes, where) {
|
|
|
143562
143577
|
return entries2;
|
|
143563
143578
|
}
|
|
143564
143579
|
function extract(bytes, where) {
|
|
143565
|
-
const key2 = (0,
|
|
143580
|
+
const key2 = (0, import_node_crypto95.createHash)("sha256").update(bytes).digest("hex");
|
|
143566
143581
|
const cached5 = pending.get(key2);
|
|
143567
143582
|
if (cached5) return cached5;
|
|
143568
143583
|
const request = (async () => {
|
|
@@ -143673,11 +143688,11 @@ async function kotlinSources(bytes, where) {
|
|
|
143673
143688
|
if (kotlin.length === 0) throw new Error(`${where}: sources jar has no Kotlin`);
|
|
143674
143689
|
return kotlin;
|
|
143675
143690
|
}
|
|
143676
|
-
var
|
|
143691
|
+
var import_node_crypto95, import_node_fs160, import_node_os34, import_node_path162, import_node_zlib9, pending, MAX_SOURCES_JAR_BYTES, MAX_SOURCE_ENTRY_BYTES, MAX_TOTAL_EXTRACTED_BYTES;
|
|
143677
143692
|
var init_kotlin_maven_sources = __esm({
|
|
143678
143693
|
"src/kotlin-maven-sources.ts"() {
|
|
143679
143694
|
"use strict";
|
|
143680
|
-
|
|
143695
|
+
import_node_crypto95 = require("node:crypto");
|
|
143681
143696
|
import_node_fs160 = __toESM(require("node:fs"), 1);
|
|
143682
143697
|
import_node_os34 = __toESM(require("node:os"), 1);
|
|
143683
143698
|
import_node_path162 = __toESM(require("node:path"), 1);
|
|
@@ -143767,7 +143782,7 @@ async function compileKotlinGradleLibraries(input) {
|
|
|
143767
143782
|
])
|
|
143768
143783
|
];
|
|
143769
143784
|
const name3 = library.coordinate.replace(/[^a-zA-Z0-9._-]/g, "-");
|
|
143770
|
-
const suffix = (0,
|
|
143785
|
+
const suffix = (0, import_node_crypto96.createHash)("sha256").update(library.coordinate).digest("hex").slice(0, 12);
|
|
143771
143786
|
const klib = import_node_path163.default.join(input.output, `${name3}-${suffix}.klib`);
|
|
143772
143787
|
const kotlinJvmAbi = java.length && kotlin.length && library.jars.length === 1 ? library.jars[0] : void 0;
|
|
143773
143788
|
const abiPairs = java.length ? dependencies.flatMap(
|
|
@@ -143809,11 +143824,11 @@ async function compileKotlinGradleLibraries(input) {
|
|
|
143809
143824
|
}
|
|
143810
143825
|
return [...compiled.values()].map(({ klib }) => klib);
|
|
143811
143826
|
}
|
|
143812
|
-
var
|
|
143827
|
+
var import_node_crypto96, import_node_fs161, import_node_path163;
|
|
143813
143828
|
var init_kotlin_gradle_library_plan = __esm({
|
|
143814
143829
|
"src/kotlin-gradle-library-plan.ts"() {
|
|
143815
143830
|
"use strict";
|
|
143816
|
-
|
|
143831
|
+
import_node_crypto96 = require("node:crypto");
|
|
143817
143832
|
import_node_fs161 = __toESM(require("node:fs"), 1);
|
|
143818
143833
|
import_node_path163 = __toESM(require("node:path"), 1);
|
|
143819
143834
|
init_kotlin_library_sources();
|
|
@@ -144049,13 +144064,13 @@ function verifyKotlinSdkDirectory(root, compiler) {
|
|
|
144049
144064
|
if (!stat2.isFile() || stat2.nlink !== 1)
|
|
144050
144065
|
throw new Error(`Kotlin SDK binary is not a regular file: ${name3}`);
|
|
144051
144066
|
const bytes = import_node_fs162.default.readFileSync(target);
|
|
144052
|
-
if (bytes.length !== expected.bytes || (0,
|
|
144067
|
+
if (bytes.length !== expected.bytes || (0, import_node_crypto97.createHash)("sha256").update(bytes).digest("hex") !== expected.sha256)
|
|
144053
144068
|
throw new Error(`Kotlin SDK binary differs from its manifest: ${name3}`);
|
|
144054
144069
|
}
|
|
144055
144070
|
return manifest;
|
|
144056
144071
|
}
|
|
144057
144072
|
async function installKotlinSdkArchive(archive, compiler) {
|
|
144058
|
-
const sha2565 = (0,
|
|
144073
|
+
const sha2565 = (0, import_node_crypto97.createHash)("sha256").update(archive).digest("hex");
|
|
144059
144074
|
const parent = import_node_path164.default.join(kotlinHome(), "sdk");
|
|
144060
144075
|
const root = import_node_path164.default.join(parent, sha2565);
|
|
144061
144076
|
if (import_node_fs162.default.existsSync(root))
|
|
@@ -144084,12 +144099,12 @@ async function installKotlinSdkArchive(archive, compiler) {
|
|
|
144084
144099
|
import_node_fs162.default.rmSync(work, { recursive: true, force: true });
|
|
144085
144100
|
}
|
|
144086
144101
|
}
|
|
144087
|
-
var import_node_child_process76,
|
|
144102
|
+
var import_node_child_process76, import_node_crypto97, import_node_fs162, import_node_path164, import_node_util21, run15;
|
|
144088
144103
|
var init_kotlin_sdk = __esm({
|
|
144089
144104
|
"src/kotlin-sdk.ts"() {
|
|
144090
144105
|
"use strict";
|
|
144091
144106
|
import_node_child_process76 = require("node:child_process");
|
|
144092
|
-
|
|
144107
|
+
import_node_crypto97 = require("node:crypto");
|
|
144093
144108
|
import_node_fs162 = __toESM(require("node:fs"), 1);
|
|
144094
144109
|
import_node_path164 = __toESM(require("node:path"), 1);
|
|
144095
144110
|
import_node_util21 = require("node:util");
|
|
@@ -144225,7 +144240,7 @@ function peachKotlinModuleRoot() {
|
|
|
144225
144240
|
if (!IS_STANDALONE) return import_node_path165.default.join(peachsimPackageRoot(), "kotlin");
|
|
144226
144241
|
if (installedRoot) return installedRoot;
|
|
144227
144242
|
const files2 = JSON.parse(__PEACH_BUNDLED_KOTLIN__);
|
|
144228
|
-
const digest3 = (0,
|
|
144243
|
+
const digest3 = (0, import_node_crypto98.createHash)("sha256").update(__PEACH_BUNDLED_KOTLIN__).digest("hex");
|
|
144229
144244
|
const parent = import_node_path165.default.join(rnxHomeDir(), "kotlin", "modules");
|
|
144230
144245
|
const root = import_node_path165.default.join(parent, digest3);
|
|
144231
144246
|
import_node_fs163.default.mkdirSync(parent, { recursive: true });
|
|
@@ -144254,11 +144269,11 @@ function peachKotlinModuleRoot() {
|
|
|
144254
144269
|
installedRoot = root;
|
|
144255
144270
|
return root;
|
|
144256
144271
|
}
|
|
144257
|
-
var
|
|
144272
|
+
var import_node_crypto98, import_node_fs163, import_node_path165, installedRoot;
|
|
144258
144273
|
var init_kotlin_module = __esm({
|
|
144259
144274
|
"src/kotlin-module.ts"() {
|
|
144260
144275
|
"use strict";
|
|
144261
|
-
|
|
144276
|
+
import_node_crypto98 = require("node:crypto");
|
|
144262
144277
|
import_node_fs163 = __toESM(require("node:fs"), 1);
|
|
144263
144278
|
import_node_path165 = __toESM(require("node:path"), 1);
|
|
144264
144279
|
init_standalone();
|
|
@@ -144292,7 +144307,7 @@ async function resolveAndroidGradleSources(request) {
|
|
|
144292
144307
|
const parent = import_node_path166.default.join(kotlinHome(), "gradle-sources");
|
|
144293
144308
|
import_node_fs164.default.mkdirSync(parent, { recursive: true });
|
|
144294
144309
|
const work = import_node_fs164.default.mkdtempSync(import_node_path166.default.join(parent, ".query-"));
|
|
144295
|
-
const task = `peachAndroidSources${(0,
|
|
144310
|
+
const task = `peachAndroidSources${(0, import_node_crypto99.randomBytes)(8).toString("hex")}`;
|
|
144296
144311
|
const script = import_node_path166.default.join(work, "sources.gradle");
|
|
144297
144312
|
const encoded = Buffer.from(
|
|
144298
144313
|
JSON.stringify({
|
|
@@ -144444,12 +144459,12 @@ function readDependencySources(value) {
|
|
|
144444
144459
|
};
|
|
144445
144460
|
});
|
|
144446
144461
|
}
|
|
144447
|
-
var import_node_child_process77,
|
|
144462
|
+
var import_node_child_process77, import_node_crypto99, import_node_fs164, import_node_path166, import_node_util22, run16, modelQuery;
|
|
144448
144463
|
var init_android_gradle_sources = __esm({
|
|
144449
144464
|
"src/android-gradle-sources.ts"() {
|
|
144450
144465
|
"use strict";
|
|
144451
144466
|
import_node_child_process77 = require("node:child_process");
|
|
144452
|
-
|
|
144467
|
+
import_node_crypto99 = require("node:crypto");
|
|
144453
144468
|
import_node_fs164 = __toESM(require("node:fs"), 1);
|
|
144454
144469
|
import_node_path166 = __toESM(require("node:path"), 1);
|
|
144455
144470
|
import_node_util22 = require("node:util");
|
|
@@ -144864,7 +144879,7 @@ function readExpoTypes(output) {
|
|
|
144864
144879
|
});
|
|
144865
144880
|
}
|
|
144866
144881
|
async function scanSources(tool, parse19, toolchain, moduleRoot, files2) {
|
|
144867
|
-
const digest3 = (0,
|
|
144882
|
+
const digest3 = (0, import_node_crypto100.createHash)("sha256").update(JSON.stringify(toolchain.compiler));
|
|
144868
144883
|
const sdk2 = await loadKotlinSdk(moduleRoot, toolchain);
|
|
144869
144884
|
digest3.update(import_node_fs165.default.readFileSync(import_node_path167.default.join(moduleRoot, "sdk.tar.gz")));
|
|
144870
144885
|
digest3.update(tool);
|
|
@@ -145526,7 +145541,7 @@ async function compileKotlin(input, origin) {
|
|
|
145526
145541
|
bytes: import_node_fs165.default.readFileSync(file)
|
|
145527
145542
|
}));
|
|
145528
145543
|
const { composeArchive, ...compilerInputs } = toolchain;
|
|
145529
|
-
const digest3 = (0,
|
|
145544
|
+
const digest3 = (0, import_node_crypto100.createHash)("sha256");
|
|
145530
145545
|
digest3.update(
|
|
145531
145546
|
JSON.stringify({
|
|
145532
145547
|
format: BUILD_FORMAT,
|
|
@@ -145548,7 +145563,7 @@ async function compileKotlin(input, origin) {
|
|
|
145548
145563
|
...gradleLibraries.libraries.flatMap(({ archive, jars }) => [archive, ...jars])
|
|
145549
145564
|
]);
|
|
145550
145565
|
for (const file of files2) {
|
|
145551
|
-
digest3.update((0,
|
|
145566
|
+
digest3.update((0, import_node_crypto100.createHash)("sha256").update(import_node_fs165.default.readFileSync(file)).digest());
|
|
145552
145567
|
}
|
|
145553
145568
|
}
|
|
145554
145569
|
if (viewModels) digest3.update(viewModels.toolClass);
|
|
@@ -145840,12 +145855,12 @@ async function serveKotlinRequest(pathname, res, app) {
|
|
|
145840
145855
|
}
|
|
145841
145856
|
return true;
|
|
145842
145857
|
}
|
|
145843
|
-
var import_node_child_process78,
|
|
145858
|
+
var import_node_child_process78, import_node_crypto100, import_node_fs165, import_node_module22, import_node_path167, import_node_util23, run17, KOTLIN_ARTIFACT_PREFIX, SKIP_DIRS, configureDeviceSource, BUILD_FORMAT, builds, toolScans, BRIDGE_PARAMETERS, BRIDGE_CASTS, BRIDGE_RETURNS, bridgeType, JAVA_CLASSES, argb, escapes2, literal5, CONTENT_TYPES;
|
|
145844
145859
|
var init_kotlin_host = __esm({
|
|
145845
145860
|
"src/kotlin-host.ts"() {
|
|
145846
145861
|
"use strict";
|
|
145847
145862
|
import_node_child_process78 = require("node:child_process");
|
|
145848
|
-
|
|
145863
|
+
import_node_crypto100 = require("node:crypto");
|
|
145849
145864
|
import_node_fs165 = __toESM(require("node:fs"), 1);
|
|
145850
145865
|
import_node_module22 = require("node:module");
|
|
145851
145866
|
import_node_path167 = __toESM(require("node:path"), 1);
|
|
@@ -146201,7 +146216,7 @@ async function readManagedExpoIdentity(root, platform3, iosTarget, bridgeOrigin)
|
|
|
146201
146216
|
url.searchParams.set("root", root);
|
|
146202
146217
|
const response = await nodeHttpFetch(url.href);
|
|
146203
146218
|
if (response.ok && response.headers.get("content-type") === revisionType) {
|
|
146204
|
-
const environment = (0,
|
|
146219
|
+
const environment = (0, import_node_crypto101.createHash)("sha256").update(JSON.stringify(Object.entries(process.env).sort())).digest("hex");
|
|
146205
146220
|
const inputs2 = Buffer.from(
|
|
146206
146221
|
JSON.stringify([
|
|
146207
146222
|
await response.text(),
|
|
@@ -146257,11 +146272,11 @@ function handleManagedExpoInputs(req, res, url) {
|
|
|
146257
146272
|
res.writeHead(200, { "Content-Type": revisionType });
|
|
146258
146273
|
res.end(revision);
|
|
146259
146274
|
}
|
|
146260
|
-
var
|
|
146275
|
+
var import_node_crypto101, import_node_fs167, import_node_path169, revisionType;
|
|
146261
146276
|
var init_managed_expo_identity = __esm({
|
|
146262
146277
|
"src/managed-expo-identity.ts"() {
|
|
146263
146278
|
"use strict";
|
|
146264
|
-
|
|
146279
|
+
import_node_crypto101 = require("node:crypto");
|
|
146265
146280
|
import_node_fs167 = __toESM(require("node:fs"), 1);
|
|
146266
146281
|
import_node_path169 = __toESM(require("node:path"), 1);
|
|
146267
146282
|
init_backend_origin();
|
|
@@ -146481,7 +146496,7 @@ async function stagePreparedExpoWidgetAssets(preparedApp, origin) {
|
|
|
146481
146496
|
const ext = import_node_path172.default.extname(file);
|
|
146482
146497
|
if (ext.toLowerCase() === ".svg") return stageCatalogSvg(file, scale, origin, bytes);
|
|
146483
146498
|
if (ext.toLowerCase() === ".pdf") {
|
|
146484
|
-
const sha2565 = (0,
|
|
146499
|
+
const sha2565 = (0, import_node_crypto102.createHash)("sha256").update(bytes).digest("hex");
|
|
146485
146500
|
const png = rasterizePdfFiles([{ file: members2.get(file), sha256: sha2565 }]).get(sha2565);
|
|
146486
146501
|
return stageHostBytes(png, origin, ".png");
|
|
146487
146502
|
}
|
|
@@ -146494,11 +146509,11 @@ async function stageExpoWidgetAssets(appRoot, origin) {
|
|
|
146494
146509
|
const prepared = await prepareExpoNativeProject(appRoot);
|
|
146495
146510
|
return stagePreparedExpoWidgetAssets(prepared.app, origin);
|
|
146496
146511
|
}
|
|
146497
|
-
var
|
|
146512
|
+
var import_node_crypto102, import_node_fs169, import_node_path172;
|
|
146498
146513
|
var init_expo_widget_assets = __esm({
|
|
146499
146514
|
"src/expo-widget-assets.ts"() {
|
|
146500
146515
|
"use strict";
|
|
146501
|
-
|
|
146516
|
+
import_node_crypto102 = require("node:crypto");
|
|
146502
146517
|
import_node_fs169 = __toESM(require("node:fs"), 1);
|
|
146503
146518
|
import_node_path172 = __toESM(require("node:path"), 1);
|
|
146504
146519
|
init_app_catalog();
|
|
@@ -146553,11 +146568,11 @@ async function trunkSpecification(lockFile, root, version2, checksum) {
|
|
|
146553
146568
|
"specifications",
|
|
146554
146569
|
`${checksum}.json`
|
|
146555
146570
|
);
|
|
146556
|
-
const sha1 = (value) => (0,
|
|
146571
|
+
const sha1 = (value) => (0, import_node_crypto103.createHash)("sha1").update(value).digest("hex");
|
|
146557
146572
|
let text7;
|
|
146558
146573
|
if (import_node_fs170.default.existsSync(file)) text7 = import_node_fs170.default.readFileSync(file, "utf8");
|
|
146559
146574
|
else {
|
|
146560
|
-
const shard2 = (0,
|
|
146575
|
+
const shard2 = (0, import_node_crypto103.createHash)("md5").update(root).digest("hex").slice(0, 3).split("").join("/");
|
|
146561
146576
|
const specPath = `Specs/${shard2}/${root}/${version2}/${root}.podspec.json`;
|
|
146562
146577
|
const response = await fetch(`https://cdn.cocoapods.org/${specPath}`);
|
|
146563
146578
|
if (!response.ok)
|
|
@@ -146686,7 +146701,7 @@ async function collectSwiftSourcePods(lockFile, modules, moduleRoot, headerModul
|
|
|
146686
146701
|
"end",
|
|
146687
146702
|
""
|
|
146688
146703
|
].join("\n");
|
|
146689
|
-
const key2 = (0,
|
|
146704
|
+
const key2 = (0, import_node_crypto103.createHash)("sha256").update(project).update(podfile).update(JSON.stringify([...selected].sort(([a], [b]) => a.localeCompare(b)))).update(
|
|
146690
146705
|
JSON.stringify(
|
|
146691
146706
|
Object.entries(specificationChecksums).sort(([a], [b]) => a.localeCompare(b))
|
|
146692
146707
|
)
|
|
@@ -146755,11 +146770,11 @@ async function collectSwiftSourcePods(lockFile, modules, moduleRoot, headerModul
|
|
|
146755
146770
|
);
|
|
146756
146771
|
});
|
|
146757
146772
|
}
|
|
146758
|
-
var
|
|
146773
|
+
var import_node_crypto103, import_node_fs170, import_node_path173, APP, record5, project, podModuleName;
|
|
146759
146774
|
var init_swift_source_pods = __esm({
|
|
146760
146775
|
"src/swift-source-pods.ts"() {
|
|
146761
146776
|
"use strict";
|
|
146762
|
-
|
|
146777
|
+
import_node_crypto103 = require("node:crypto");
|
|
146763
146778
|
import_node_fs170 = __toESM(require("node:fs"), 1);
|
|
146764
146779
|
import_node_path173 = __toESM(require("node:path"), 1);
|
|
146765
146780
|
init_browser();
|
|
@@ -147436,7 +147451,7 @@ async function prepareNitroCompileInput(options2) {
|
|
|
147436
147451
|
input.libraries ??= {};
|
|
147437
147452
|
input.libraries[nitroProviderTarget({ name: name3 })] = library;
|
|
147438
147453
|
}
|
|
147439
|
-
const key2 = (0,
|
|
147454
|
+
const key2 = (0, import_node_crypto104.createHash)("sha256").update(
|
|
147440
147455
|
collection.providers.map(({ root, hybridObjects }) => `${root}\0${hybridObjects.join(",")}`).join("\0")
|
|
147441
147456
|
).update("\0").update(import_node_fs171.default.realpathSync(options2.moduleRoot)).update("\0").update(options2.configuration).digest("hex");
|
|
147442
147457
|
const packagePath = import_node_path174.default.join(import_node_os35.default.tmpdir(), "peach-nitro-swift", key2, `p${process.pid}`);
|
|
@@ -147493,11 +147508,11 @@ function nitrogenGeneratedSources(podDirectory) {
|
|
|
147493
147508
|
...sources(import_node_path174.default.join(generated, "ios"), /\.(h|hpp|c|cpp|mm|swift)$/)
|
|
147494
147509
|
];
|
|
147495
147510
|
}
|
|
147496
|
-
var
|
|
147511
|
+
var import_node_crypto104, import_node_fs171, import_node_os35, import_node_path174, BUNDLED_CXX_NAMESPACES, REACT_INCLUDE_PATTERN, REACT_LINKING_PATTERN, REACT_VERSION_PATTERN, RN_HEADER_DIR_MAP, RN_COMMON_ROOTS;
|
|
147497
147512
|
var init_nitro_compile = __esm({
|
|
147498
147513
|
"src/nitro-compile.ts"() {
|
|
147499
147514
|
"use strict";
|
|
147500
|
-
|
|
147515
|
+
import_node_crypto104 = require("node:crypto");
|
|
147501
147516
|
import_node_fs171 = __toESM(require("node:fs"), 1);
|
|
147502
147517
|
import_node_os35 = __toESM(require("node:os"), 1);
|
|
147503
147518
|
import_node_path174 = __toESM(require("node:path"), 1);
|
|
@@ -147574,11 +147589,11 @@ var init_nitro_compile = __esm({
|
|
|
147574
147589
|
});
|
|
147575
147590
|
|
|
147576
147591
|
// src/nitro-compiler-digest.ts
|
|
147577
|
-
var
|
|
147592
|
+
var import_node_crypto105, import_node_fs172, import_node_path175;
|
|
147578
147593
|
var init_nitro_compiler_digest = __esm({
|
|
147579
147594
|
"src/nitro-compiler-digest.ts"() {
|
|
147580
147595
|
"use strict";
|
|
147581
|
-
|
|
147596
|
+
import_node_crypto105 = require("node:crypto");
|
|
147582
147597
|
import_node_fs172 = require("node:fs");
|
|
147583
147598
|
import_node_path175 = __toESM(require("node:path"), 1);
|
|
147584
147599
|
init_swift_compiler_digest();
|
|
@@ -147716,7 +147731,7 @@ var init_nitro_superset = __esm({
|
|
|
147716
147731
|
init_nitroContract();
|
|
147717
147732
|
init_swift_standin_digest();
|
|
147718
147733
|
NITRO_SUPERSET_ENTRY_NAME = "superset";
|
|
147719
|
-
NITRO_COMPILER_DIGEST = true ? "
|
|
147734
|
+
NITRO_COMPILER_DIGEST = true ? "bdc0f5dd61f31a5b6f5bba3db67fc29584077dfb64bd237228a11b91b9ab2730" : nitroCompilerSourceDigest(__sootsim_import_meta_dirname, STANDIN_SOURCE_DIGEST2);
|
|
147720
147735
|
nitroSupersetLock = parseLock(nitro_superset_lock_default);
|
|
147721
147736
|
nitroSupersetKey = (inputs2) => nativeEntryKey({ ...inputs2, compiler: NITRO_COMPILER_DIGEST });
|
|
147722
147737
|
published3 = /* @__PURE__ */ new Map();
|
|
@@ -148245,7 +148260,7 @@ async function compilePreparedOneSDKApp(appRoot, preparedRoot, origin, moduleRoo
|
|
|
148245
148260
|
const packagePath = import_node_path179.default.join(
|
|
148246
148261
|
swiftCacheDir(),
|
|
148247
148262
|
"peach-one-sdk-swift",
|
|
148248
|
-
(0,
|
|
148263
|
+
(0, import_node_crypto106.createHash)("sha256").update(import_node_fs175.default.realpathSync(appRoot)).digest("hex").slice(0, 16),
|
|
148249
148264
|
"sdk"
|
|
148250
148265
|
);
|
|
148251
148266
|
const bindingFlags = optimize ? '["-suppress-warnings"]' : '["-suppress-warnings", "-Onone", "-no-whole-module-optimization"]';
|
|
@@ -148292,11 +148307,11 @@ async function buildOneSDKBundle(appRoot) {
|
|
|
148292
148307
|
assets: await compiledModuleAssets(compiled.artifact)
|
|
148293
148308
|
};
|
|
148294
148309
|
}
|
|
148295
|
-
var
|
|
148310
|
+
var import_node_crypto106, import_node_fs175, import_node_path179, ONE_SDK_ROUTE, ONE_SDK_BINDING_SHARDS, ONE_SDK_BINDING_SHARD_MIN_BYTES, handleOneSDKRequest;
|
|
148296
148311
|
var init_one_sdk_bundle = __esm({
|
|
148297
148312
|
"src/one-sdk-bundle.ts"() {
|
|
148298
148313
|
"use strict";
|
|
148299
|
-
|
|
148314
|
+
import_node_crypto106 = require("node:crypto");
|
|
148300
148315
|
import_node_fs175 = __toESM(require("node:fs"), 1);
|
|
148301
148316
|
import_node_path179 = __toESM(require("node:path"), 1);
|
|
148302
148317
|
init_expo_native_workspace();
|
|
@@ -148986,7 +149001,7 @@ function writeSharedDesktopAuthSession(session) {
|
|
|
148986
149001
|
validatedAt: session.validatedAt ?? same?.validatedAt,
|
|
148987
149002
|
accountId: session.accountId?.trim() || same?.accountId
|
|
148988
149003
|
};
|
|
148989
|
-
const temporary = `${filepath}.${process.pid}.${(0,
|
|
149004
|
+
const temporary = `${filepath}.${process.pid}.${(0, import_node_crypto107.randomUUID)()}.tmp`;
|
|
148990
149005
|
try {
|
|
148991
149006
|
(0, import_node_fs179.writeFileSync)(temporary, JSON.stringify(normalized, null, 2) + "\n", {
|
|
148992
149007
|
mode: 384,
|
|
@@ -149038,11 +149053,11 @@ async function refreshSharedDesktopAuthSession(originOverride) {
|
|
|
149038
149053
|
return readSharedDesktopAuthSession();
|
|
149039
149054
|
}
|
|
149040
149055
|
}
|
|
149041
|
-
var
|
|
149056
|
+
var import_node_crypto107, import_node_fs179, import_node_path184, SESSION_VERSION, SESSION_FILE_ENV, DEFAULT_ORIGIN;
|
|
149042
149057
|
var init_shared_session = __esm({
|
|
149043
149058
|
"src/auth/shared-session.ts"() {
|
|
149044
149059
|
"use strict";
|
|
149045
|
-
|
|
149060
|
+
import_node_crypto107 = require("node:crypto");
|
|
149046
149061
|
import_node_fs179 = require("node:fs");
|
|
149047
149062
|
import_node_path184 = require("node:path");
|
|
149048
149063
|
init_home_paths();
|
|
@@ -149083,7 +149098,7 @@ var init_run_rnx = __esm({
|
|
|
149083
149098
|
// cli/secure-file.ts
|
|
149084
149099
|
function writeSecureJsonAtomic(filepath, value, { durable = true } = {}) {
|
|
149085
149100
|
(0, import_node_fs180.mkdirSync)((0, import_node_path185.dirname)(filepath), { recursive: true });
|
|
149086
|
-
const temporary = `${filepath}.tmp-${process.pid}-${(0,
|
|
149101
|
+
const temporary = `${filepath}.tmp-${process.pid}-${(0, import_node_crypto108.randomUUID)()}`;
|
|
149087
149102
|
let descriptor = null;
|
|
149088
149103
|
try {
|
|
149089
149104
|
descriptor = (0, import_node_fs180.openSync)(temporary, "wx", 384);
|
|
@@ -149100,11 +149115,11 @@ function writeSecureJsonAtomic(filepath, value, { durable = true } = {}) {
|
|
|
149100
149115
|
throw error;
|
|
149101
149116
|
}
|
|
149102
149117
|
}
|
|
149103
|
-
var
|
|
149118
|
+
var import_node_crypto108, import_node_fs180, import_node_path185;
|
|
149104
149119
|
var init_secure_file = __esm({
|
|
149105
149120
|
"cli/secure-file.ts"() {
|
|
149106
149121
|
"use strict";
|
|
149107
|
-
|
|
149122
|
+
import_node_crypto108 = require("node:crypto");
|
|
149108
149123
|
import_node_fs180 = require("node:fs");
|
|
149109
149124
|
import_node_path185 = require("node:path");
|
|
149110
149125
|
}
|
|
@@ -151613,7 +151628,7 @@ function projectSessionFile() {
|
|
|
151613
151628
|
}
|
|
151614
151629
|
dir = parent;
|
|
151615
151630
|
}
|
|
151616
|
-
const key2 = (0,
|
|
151631
|
+
const key2 = (0, import_node_crypto109.createHash)("sha256").update(dir).digest("hex").slice(0, 32);
|
|
151617
151632
|
return (0, import_node_path187.join)(rnxHomeDir(), "remote-sessions", `${key2}.json`);
|
|
151618
151633
|
}
|
|
151619
151634
|
function readCloudSession() {
|
|
@@ -151627,11 +151642,11 @@ function readCloudSession() {
|
|
|
151627
151642
|
}
|
|
151628
151643
|
return parseCloudSession(saved.session);
|
|
151629
151644
|
}
|
|
151630
|
-
var
|
|
151645
|
+
var import_node_crypto109, import_node_fs182, import_node_path187, CLOUD_SESSION_VERSION, MAX_ENCODED_SESSION_BYTES, PEACH_CLOUD_SESSION_ENV, RNX_SHELL_UPDATE_PREFIX, RNX_SHELL_UPDATE_SET_PREFIX, RNX_SHELL_UPDATE_UNSET, PROJECT_MARKERS;
|
|
151631
151646
|
var init_cloud_session = __esm({
|
|
151632
151647
|
"cli/cloud-session.ts"() {
|
|
151633
151648
|
"use strict";
|
|
151634
|
-
|
|
151649
|
+
import_node_crypto109 = require("node:crypto");
|
|
151635
151650
|
import_node_fs182 = require("node:fs");
|
|
151636
151651
|
import_node_path187 = require("node:path");
|
|
151637
151652
|
init_backend_origin();
|
|
@@ -152513,7 +152528,7 @@ function listMetroAssetDest(assetsPath) {
|
|
|
152513
152528
|
return { directory: directory2, files: files2, truncated };
|
|
152514
152529
|
}
|
|
152515
152530
|
function metroDescriptorHash(scaleBytes) {
|
|
152516
|
-
const hasher = (0,
|
|
152531
|
+
const hasher = (0, import_node_crypto110.createHash)("md5");
|
|
152517
152532
|
for (const bytes of scaleBytes) hasher.update(bytes);
|
|
152518
152533
|
return hasher.digest("hex");
|
|
152519
152534
|
}
|
|
@@ -152542,7 +152557,7 @@ function distinctByContent(directory2, options2) {
|
|
|
152542
152557
|
} catch {
|
|
152543
152558
|
continue;
|
|
152544
152559
|
}
|
|
152545
|
-
const digest3 = (0,
|
|
152560
|
+
const digest3 = (0, import_node_crypto110.createHash)("md5").update(bytes).digest("hex");
|
|
152546
152561
|
if (!byContent.has(digest3)) byContent.set(digest3, relative7);
|
|
152547
152562
|
}
|
|
152548
152563
|
return [...byContent.values()];
|
|
@@ -152590,7 +152605,7 @@ function placeMetroDescriptor(listing, descriptor) {
|
|
|
152590
152605
|
continue;
|
|
152591
152606
|
}
|
|
152592
152607
|
const identical = fileHashes2 ? bytes.every((file, index) => {
|
|
152593
|
-
const digest3 = (0,
|
|
152608
|
+
const digest3 = (0, import_node_crypto110.createHash)("md5").update(file).digest("hex");
|
|
152594
152609
|
return descriptor.scales.some(
|
|
152595
152610
|
(scale, declared) => scale === scales[index] && fileHashes2[declared] === digest3
|
|
152596
152611
|
);
|
|
@@ -152615,7 +152630,7 @@ function unverifiedContentKey(dest, fileDigests2) {
|
|
|
152615
152630
|
const file = (0, import_node_path189.join)(dest.directory, relative7);
|
|
152616
152631
|
let digest3 = fileDigests2.get(file);
|
|
152617
152632
|
if (digest3 === void 0) {
|
|
152618
|
-
digest3 = (0,
|
|
152633
|
+
digest3 = (0, import_node_crypto110.createHash)("sha256").update((0, import_node_fs184.readFileSync)(file)).digest("hex");
|
|
152619
152634
|
fileDigests2.set(file, digest3);
|
|
152620
152635
|
}
|
|
152621
152636
|
return [scale, digest3];
|
|
@@ -152770,14 +152785,14 @@ async function producePreviewArtifact(bundlePath) {
|
|
|
152770
152785
|
prepared.code
|
|
152771
152786
|
);
|
|
152772
152787
|
const bytes = Buffer.from(annotated, "utf8");
|
|
152773
|
-
const sha2565 = (0,
|
|
152788
|
+
const sha2565 = (0, import_node_crypto110.createHash)("sha256").update(bytes).digest("hex");
|
|
152774
152789
|
return {
|
|
152775
152790
|
bytes,
|
|
152776
152791
|
sha256: sha2565,
|
|
152777
152792
|
minified: false,
|
|
152778
152793
|
receipt: {
|
|
152779
152794
|
source: {
|
|
152780
|
-
sha256: (0,
|
|
152795
|
+
sha256: (0, import_node_crypto110.createHash)("sha256").update(prepared.source).digest("hex"),
|
|
152781
152796
|
bytes: Buffer.byteLength(prepared.source, "utf8")
|
|
152782
152797
|
},
|
|
152783
152798
|
artifact: { sha256: sha2565, bytes: bytes.byteLength }
|
|
@@ -152933,7 +152948,7 @@ async function produceArtifact(prepared, maxBytes, command) {
|
|
|
152933
152948
|
}
|
|
152934
152949
|
return {
|
|
152935
152950
|
bytes,
|
|
152936
|
-
sha256: (0,
|
|
152951
|
+
sha256: (0, import_node_crypto110.createHash)("sha256").update(bytes).digest("hex"),
|
|
152937
152952
|
receipt: artifact.receipt,
|
|
152938
152953
|
assetsDirectory: prepared.dest?.directory ?? null,
|
|
152939
152954
|
warnings
|
|
@@ -153449,11 +153464,11 @@ async function closeCloudSession(session) {
|
|
|
153449
153464
|
throw responseError(response.status, text7);
|
|
153450
153465
|
}
|
|
153451
153466
|
}
|
|
153452
|
-
var
|
|
153467
|
+
var import_node_crypto110, import_node_fs184, import_node_path189, import_node_vm, DEFAULT_RNX_CLOUD_ORIGIN, MAX_RNX_CLOUD_BUNDLE_BYTES, REMOTE_COMMAND, PREVIEW_COMMAND, NanoDevelopmentOnlyError, UnsupportedRemoteHostError, MAX_ASSET_DEST_FILES, ACCOUNT_CHOICE_REFUSALS, PROJECT_ONLY_DIRECTORIES, MAX_PLACEMENT_COMBINATIONS, REMOTE_HAS_NO_LOCAL_SIMS, CloudBridge, CloudBoxBridge, SceneBridge, BoxBootFailedError, BOX_BOOT_WAIT_MS;
|
|
153453
153468
|
var init_cloud_client = __esm({
|
|
153454
153469
|
"cli/cloud-client.ts"() {
|
|
153455
153470
|
"use strict";
|
|
153456
|
-
|
|
153471
|
+
import_node_crypto110 = require("node:crypto");
|
|
153457
153472
|
import_node_fs184 = require("node:fs");
|
|
153458
153473
|
import_node_path189 = require("node:path");
|
|
153459
153474
|
import_node_vm = require("node:vm");
|
|
@@ -153526,7 +153541,7 @@ var init_cloud_client = __esm({
|
|
|
153526
153541
|
const timeoutMs = options2?.timeoutMs ?? this.explicitTimeoutMs ?? options2?.defaultTimeoutMs;
|
|
153527
153542
|
const agent = commandAgent(command);
|
|
153528
153543
|
const body = {
|
|
153529
|
-
id: (0,
|
|
153544
|
+
id: (0, import_node_crypto110.randomUUID)(),
|
|
153530
153545
|
claimId: this.session.claimId,
|
|
153531
153546
|
command: cloudCommand(agent ? { ...command, agent } : command)
|
|
153532
153547
|
};
|
|
@@ -153596,7 +153611,7 @@ var init_cloud_client = __esm({
|
|
|
153596
153611
|
plane = "cloud";
|
|
153597
153612
|
async send(command, options2) {
|
|
153598
153613
|
const timeoutMs = options2?.timeoutMs ?? this.explicitTimeoutMs ?? options2?.defaultTimeoutMs;
|
|
153599
|
-
const id = (0,
|
|
153614
|
+
const id = (0, import_node_crypto110.randomUUID)();
|
|
153600
153615
|
const agent = commandAgent(command);
|
|
153601
153616
|
const payload = cloudCommand(agent ? { ...command, agent } : command);
|
|
153602
153617
|
let response;
|
|
@@ -157716,11 +157731,11 @@ function splashImageUrls(spec) {
|
|
|
157716
157731
|
if (spec.dark?.backgroundImageUrl) urls.add(spec.dark.backgroundImageUrl);
|
|
157717
157732
|
return [...urls];
|
|
157718
157733
|
}
|
|
157719
|
-
var
|
|
157734
|
+
var import_node_crypto111, import_node_module28, require2;
|
|
157720
157735
|
var init_app_splash = __esm({
|
|
157721
157736
|
"cli/app-splash.ts"() {
|
|
157722
157737
|
"use strict";
|
|
157723
|
-
|
|
157738
|
+
import_node_crypto111 = require("node:crypto");
|
|
157724
157739
|
import_node_module28 = require("node:module");
|
|
157725
157740
|
init_backend_origin();
|
|
157726
157741
|
init_cli_runtime();
|
|
@@ -157774,7 +157789,7 @@ function extractAppBinaryBundle(binary2) {
|
|
|
157774
157789
|
);
|
|
157775
157790
|
const sidecar = import_node_path194.default.posix.dirname(manifestEntry);
|
|
157776
157791
|
const appRoot = import_node_path194.default.posix.dirname(sidecar);
|
|
157777
|
-
const digest3 = (0,
|
|
157792
|
+
const digest3 = (0, import_node_crypto112.createHash)("sha256").update(import_node_fs189.default.readFileSync(file)).digest("hex");
|
|
157778
157793
|
const out = import_node_path194.default.join(cacheDir(), "app-binaries", digest3);
|
|
157779
157794
|
const bundlePath = import_node_path194.default.join(out, "main.js");
|
|
157780
157795
|
const extracted = import_node_path194.default.join(out, "extracted");
|
|
@@ -157792,7 +157807,7 @@ function extractAppBinaryBundle(binary2) {
|
|
|
157792
157807
|
const bundle = (0, import_node_zlib12.brotliDecompressSync)(
|
|
157793
157808
|
import_node_fs189.default.readFileSync(import_node_path194.default.join(extracted, sidecar, PEACH_SIDECAR_BUNDLE))
|
|
157794
157809
|
);
|
|
157795
|
-
if ((0,
|
|
157810
|
+
if ((0, import_node_crypto112.createHash)("sha256").update(bundle).digest("hex") !== manifest.bundleSha256)
|
|
157796
157811
|
throw new Error(`${binary2}: the peach sidecar bundle does not match its manifest`);
|
|
157797
157812
|
const assets2 = manifest.platform === "ios" ? import_node_path194.default.join(extracted, appRoot, "assets") : import_node_path194.default.join(extracted, sidecar, PEACH_SIDECAR_ASSETS);
|
|
157798
157813
|
if (import_node_fs189.default.existsSync(assets2)) import_node_fs189.default.renameSync(assets2, import_node_path194.default.join(out, "assets"));
|
|
@@ -157812,12 +157827,12 @@ function extractAppBinaryBundle(binary2) {
|
|
|
157812
157827
|
);
|
|
157813
157828
|
return { bundlePath, platform: platform3 };
|
|
157814
157829
|
}
|
|
157815
|
-
var import_node_child_process81,
|
|
157830
|
+
var import_node_child_process81, import_node_crypto112, import_node_fs189, import_node_path194, import_node_zlib12;
|
|
157816
157831
|
var init_binary_sidecar = __esm({
|
|
157817
157832
|
"cli/binary-sidecar.ts"() {
|
|
157818
157833
|
"use strict";
|
|
157819
157834
|
import_node_child_process81 = require("node:child_process");
|
|
157820
|
-
|
|
157835
|
+
import_node_crypto112 = require("node:crypto");
|
|
157821
157836
|
import_node_fs189 = __toESM(require("node:fs"), 1);
|
|
157822
157837
|
import_node_path194 = __toESM(require("node:path"), 1);
|
|
157823
157838
|
import_node_zlib12 = require("node:zlib");
|
|
@@ -158653,7 +158668,7 @@ var init_core = __esm({
|
|
|
158653
158668
|
// cli/output-redaction.ts
|
|
158654
158669
|
function mask(value) {
|
|
158655
158670
|
if (MASKED.test(value)) return value;
|
|
158656
|
-
return `<redacted:${(0,
|
|
158671
|
+
return `<redacted:${(0, import_node_crypto113.createHash)("sha256").update(value).digest("hex").slice(0, 4)}>`;
|
|
158657
158672
|
}
|
|
158658
158673
|
function maskQuoted(quoted2) {
|
|
158659
158674
|
return `${quoted2[0]}${mask(quoted2.slice(1, -1))}${quoted2[0]}`;
|
|
@@ -158775,11 +158790,11 @@ function redactText(text7, configurationOnly, decodedString = false) {
|
|
|
158775
158790
|
(line, prefix, name3, value) => SECRET_NAME.test(name3) ? `${prefix}${mask(value)}` : line
|
|
158776
158791
|
).replace(EMAIL, mask).replace(OPAQUE_ID, mask);
|
|
158777
158792
|
}
|
|
158778
|
-
var
|
|
158793
|
+
var import_node_crypto113, import_node_util26, SECRET_NAME, JWT, GOOGLE_API_KEY, BEARER, EMAIL, OPAQUE_ID, STRING, NUMBER, PAIR2, STRING_TOKEN, QUERY_PAIR, HEADER_LINE, MASKED, CONFIG_CONTAINER, utf8;
|
|
158779
158794
|
var init_output_redaction = __esm({
|
|
158780
158795
|
"cli/output-redaction.ts"() {
|
|
158781
158796
|
"use strict";
|
|
158782
|
-
|
|
158797
|
+
import_node_crypto113 = require("node:crypto");
|
|
158783
158798
|
import_node_util26 = require("node:util");
|
|
158784
158799
|
init_config();
|
|
158785
158800
|
SECRET_NAME = /^(?:[\w-]*(?:api[-_]?key|token|secret|password|passwd|authorization|cookie|signature|credential)s?|auth|sig|email|uid|[\w-]*(?:user|account|local|device|installation|client|app|project|sender|measurement|tenant)[-_]?id)$/i;
|
|
@@ -159282,7 +159297,7 @@ function macDesktopLaunchHome(bridgePort) {
|
|
|
159282
159297
|
const dev = readDevBridgeLockfiles().find(
|
|
159283
159298
|
(lock) => lock.bridgePort === bridgePort && isDevBridgeLockfileFresh(lock)
|
|
159284
159299
|
);
|
|
159285
|
-
const homeKey = (0,
|
|
159300
|
+
const homeKey = (0, import_node_crypto114.createHash)("sha256").update(home).digest("hex");
|
|
159286
159301
|
const dir = (0, import_path7.join)((0, import_os4.tmpdir)(), "peach-desktop-launch", homeKey, String(bridgePort));
|
|
159287
159302
|
(0, import_fs8.mkdirSync)(dir, { recursive: true });
|
|
159288
159303
|
if ((0, import_fs8.existsSync)(home)) {
|
|
@@ -159388,13 +159403,13 @@ function buildMacLaunchUrl(url, opts, nativeApp = false) {
|
|
|
159388
159403
|
}
|
|
159389
159404
|
return deepLink.toString();
|
|
159390
159405
|
}
|
|
159391
|
-
var import_child_process6, import_fs8,
|
|
159406
|
+
var import_child_process6, import_fs8, import_node_crypto114, import_os4, import_path7, import_url2, import_meta2, _sootsimRoot;
|
|
159392
159407
|
var init_desktop_companion = __esm({
|
|
159393
159408
|
"cli/desktop-companion.ts"() {
|
|
159394
159409
|
"use strict";
|
|
159395
159410
|
import_child_process6 = require("child_process");
|
|
159396
159411
|
import_fs8 = require("fs");
|
|
159397
|
-
|
|
159412
|
+
import_node_crypto114 = require("node:crypto");
|
|
159398
159413
|
import_os4 = require("os");
|
|
159399
159414
|
import_path7 = require("path");
|
|
159400
159415
|
import_url2 = require("url");
|
|
@@ -160129,11 +160144,11 @@ function trackCliDiagnostic(diagnostic) {
|
|
|
160129
160144
|
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
160130
160145
|
});
|
|
160131
160146
|
}
|
|
160132
|
-
var
|
|
160147
|
+
var import_node_crypto115, import_node_fs190, import_node_os37, observedRuntimeVersion, queue, CRASH_REPORT_EVERY_MS;
|
|
160133
160148
|
var init_telemetry = __esm({
|
|
160134
160149
|
"cli/telemetry.ts"() {
|
|
160135
160150
|
"use strict";
|
|
160136
|
-
|
|
160151
|
+
import_node_crypto115 = require("node:crypto");
|
|
160137
160152
|
import_node_fs190 = require("node:fs");
|
|
160138
160153
|
import_node_os37 = require("node:os");
|
|
160139
160154
|
init_event_identity();
|
|
@@ -165888,18 +165903,18 @@ function stageAppBundleResources(appDir, origin, iosTarget, environment) {
|
|
|
165888
165903
|
const content = bytes[index];
|
|
165889
165904
|
result[base2] = {
|
|
165890
165905
|
uri: urls[index],
|
|
165891
|
-
sha256: (0,
|
|
165906
|
+
sha256: (0, import_node_crypto116.createHash)("sha256").update(content).digest("hex"),
|
|
165892
165907
|
contentType: preferredMimeType(base2) ?? "application/octet-stream",
|
|
165893
165908
|
byteLength: content.byteLength
|
|
165894
165909
|
};
|
|
165895
165910
|
});
|
|
165896
165911
|
return result;
|
|
165897
165912
|
}
|
|
165898
|
-
var
|
|
165913
|
+
var import_node_crypto116, import_node_fs193, import_node_path196;
|
|
165899
165914
|
var init_app_bundle_resources = __esm({
|
|
165900
165915
|
"cli/app-bundle-resources.ts"() {
|
|
165901
165916
|
"use strict";
|
|
165902
|
-
|
|
165917
|
+
import_node_crypto116 = require("node:crypto");
|
|
165903
165918
|
import_node_fs193 = __toESM(require("node:fs"), 1);
|
|
165904
165919
|
import_node_path196 = __toESM(require("node:path"), 1);
|
|
165905
165920
|
init_uttype_mime();
|
|
@@ -166037,7 +166052,7 @@ function materialSymbolFontAssets(fontPaths) {
|
|
|
166037
166052
|
const directory2 = import_node_path197.default.dirname(selected[0]);
|
|
166038
166053
|
const codepointsFile = import_node_path197.default.join(directory2, "MaterialSymbols.codepoints");
|
|
166039
166054
|
const mirroredFile = import_node_path197.default.join(directory2, "MaterialSymbols.mirrored");
|
|
166040
|
-
const digest3 = (0,
|
|
166055
|
+
const digest3 = (0, import_node_crypto117.createHash)("md5");
|
|
166041
166056
|
for (const asset of [...selected, codepointsFile, mirroredFile].sort(
|
|
166042
166057
|
(a, b) => import_node_path197.default.basename(a) < import_node_path197.default.basename(b) ? -1 : import_node_path197.default.basename(a) > import_node_path197.default.basename(b) ? 1 : 0
|
|
166043
166058
|
)) {
|
|
@@ -166049,11 +166064,11 @@ function materialSymbolFontAssets(fontPaths) {
|
|
|
166049
166064
|
mirroredPath: mirroredFile
|
|
166050
166065
|
};
|
|
166051
166066
|
}
|
|
166052
|
-
var
|
|
166067
|
+
var import_node_crypto117, import_node_fs194, import_node_module29, import_node_path197;
|
|
166053
166068
|
var init_material_symbol_fonts2 = __esm({
|
|
166054
166069
|
"cli/material-symbol-fonts.ts"() {
|
|
166055
166070
|
"use strict";
|
|
166056
|
-
|
|
166071
|
+
import_node_crypto117 = require("node:crypto");
|
|
166057
166072
|
import_node_fs194 = __toESM(require("node:fs"), 1);
|
|
166058
166073
|
import_node_module29 = require("node:module");
|
|
166059
166074
|
import_node_path197 = __toESM(require("node:path"), 1);
|
|
@@ -166292,11 +166307,11 @@ function discoverNativeLinkedAppFontAssets(opts) {
|
|
|
166292
166307
|
materialSymbols: materialSymbolFontAssets(materialFonts)
|
|
166293
166308
|
};
|
|
166294
166309
|
}
|
|
166295
|
-
var
|
|
166310
|
+
var import_node_crypto118, import_node_fs195, import_node_module30, import_node_path198, require3;
|
|
166296
166311
|
var init_app_fonts = __esm({
|
|
166297
166312
|
"cli/app-fonts.ts"() {
|
|
166298
166313
|
"use strict";
|
|
166299
|
-
|
|
166314
|
+
import_node_crypto118 = require("node:crypto");
|
|
166300
166315
|
import_node_fs195 = __toESM(require("node:fs"), 1);
|
|
166301
166316
|
import_node_module30 = require("node:module");
|
|
166302
166317
|
import_node_path198 = __toESM(require("node:path"), 1);
|
|
@@ -167514,11 +167529,11 @@ async function stageMetroBundleAssets(bundleFile, source, origin) {
|
|
|
167514
167529
|
return import_node_fs197.default.readFileSync(import_node_path200.default.join(search.dest.directory, relative7));
|
|
167515
167530
|
});
|
|
167516
167531
|
const verified2 = perFile && hashes ? bytes.every((content, i) => {
|
|
167517
|
-
const hash = (0,
|
|
167532
|
+
const hash = (0, import_node_crypto119.createHash)("md5").update(content).digest("hex");
|
|
167518
167533
|
return descriptor.scales.some(
|
|
167519
167534
|
(scale, j) => scale === scales[i] && hashes[j] === hash
|
|
167520
167535
|
);
|
|
167521
|
-
}) : scales.length === descriptor.scales.length && (0,
|
|
167536
|
+
}) : scales.length === descriptor.scales.length && (0, import_node_crypto119.createHash)("md5").update(Buffer.concat(bytes)).digest("hex") === descriptor.hash;
|
|
167522
167537
|
if (!verified2)
|
|
167523
167538
|
throw new Error(`Metro asset changed while staging: ${descriptor.name}`);
|
|
167524
167539
|
scales.forEach((scale, i) => {
|
|
@@ -167545,11 +167560,11 @@ async function stageMetroBundleAssets(bundleFile, source, origin) {
|
|
|
167545
167560
|
});
|
|
167546
167561
|
stageHostMetroAssets(staged, origin);
|
|
167547
167562
|
}
|
|
167548
|
-
var
|
|
167563
|
+
var import_node_crypto119, import_node_fs197, import_node_path200;
|
|
167549
167564
|
var init_metro_bundle_assets = __esm({
|
|
167550
167565
|
"cli/metro-bundle-assets.ts"() {
|
|
167551
167566
|
"use strict";
|
|
167552
|
-
|
|
167567
|
+
import_node_crypto119 = require("node:crypto");
|
|
167553
167568
|
import_node_fs197 = __toESM(require("node:fs"), 1);
|
|
167554
167569
|
import_node_path200 = __toESM(require("node:path"), 1);
|
|
167555
167570
|
init_metroAssetArtifact();
|
|
@@ -167714,7 +167729,7 @@ async function signIn(origin, requestedAccount, chooseLater, announce) {
|
|
|
167714
167729
|
` dev-login not available (${devResult.error}); falling back to browser`
|
|
167715
167730
|
);
|
|
167716
167731
|
}
|
|
167717
|
-
const state = (0,
|
|
167732
|
+
const state = (0, import_node_crypto120.randomBytes)(16).toString("hex");
|
|
167718
167733
|
const LOGIN_TIMEOUT_MS = 5 * 60 * 1e3;
|
|
167719
167734
|
const result = await new Promise((resolve16) => {
|
|
167720
167735
|
let timer;
|
|
@@ -167823,11 +167838,11 @@ async function signIn(origin, requestedAccount, chooseLater, announce) {
|
|
|
167823
167838
|
dev: false
|
|
167824
167839
|
};
|
|
167825
167840
|
}
|
|
167826
|
-
var
|
|
167841
|
+
var import_node_crypto120, import_node_http4, import_promises20, REMOTE_DEFAULT_ORIGIN, DEV_LOGIN_WARMUP_MS;
|
|
167827
167842
|
var init_login = __esm({
|
|
167828
167843
|
"cli/commands/login.ts"() {
|
|
167829
167844
|
"use strict";
|
|
167830
|
-
|
|
167845
|
+
import_node_crypto120 = require("node:crypto");
|
|
167831
167846
|
import_node_http4 = __toESM(require("node:http"), 1);
|
|
167832
167847
|
import_promises20 = require("node:readline/promises");
|
|
167833
167848
|
init_shared_session();
|
|
@@ -168039,7 +168054,7 @@ async function requireAccount(commandLabel, options2 = {}, signedInAgain = false
|
|
|
168039
168054
|
if (auth.kind === "github") return;
|
|
168040
168055
|
const header = authHeaderValue(auth);
|
|
168041
168056
|
const origin = await billingOriginFor(auth);
|
|
168042
|
-
const credential = (0,
|
|
168057
|
+
const credential = (0, import_node_crypto121.createHash)("sha256").update(`${origin}
|
|
168043
168058
|
${header}`).digest("hex");
|
|
168044
168059
|
const check2 = readCheck();
|
|
168045
168060
|
const known = check2?.credential === credential ? check2 : null;
|
|
@@ -168087,11 +168102,11 @@ ${header}`).digest("hex");
|
|
|
168087
168102
|
`${name3} could not reach ${origin} to verify your account${status ? ` (${status})` : ""}; connect once and run it again`
|
|
168088
168103
|
);
|
|
168089
168104
|
}
|
|
168090
|
-
var
|
|
168105
|
+
var import_node_crypto121, import_node_fs198, import_node_path201, import_zod5, REFRESH_AFTER_MS, VALID_FOR_MS, VERIFY_TIMEOUT_MS, checkSchema, ACCOUNT_REQUIRED_HINT, waitlistedSchema;
|
|
168091
168106
|
var init_account_gate = __esm({
|
|
168092
168107
|
"cli/account-gate.ts"() {
|
|
168093
168108
|
"use strict";
|
|
168094
|
-
|
|
168109
|
+
import_node_crypto121 = require("node:crypto");
|
|
168095
168110
|
import_node_fs198 = require("node:fs");
|
|
168096
168111
|
import_node_path201 = __toESM(require("node:path"), 1);
|
|
168097
168112
|
import_zod5 = require("peachsim/vendor/zod");
|