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
|
@@ -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;
|
|
@@ -14892,12 +14892,13 @@ function parseSwiftDistributionLock(value) {
|
|
|
14892
14892
|
if (runtime === void 0) return void 0;
|
|
14893
14893
|
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(
|
|
14894
14894
|
runtime.url
|
|
14895
|
-
) || runtime.dataPlan !== void 0 && (typeof runtime.dataPlan !== "string" || !/^[a-f0-9]{64}$/.test(runtime.dataPlan)))
|
|
14895
|
+
) || 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)))
|
|
14896
14896
|
throw new Error("invalid shared SDK runtime publication in Swift distribution lock");
|
|
14897
14897
|
return {
|
|
14898
14898
|
source: runtime.source,
|
|
14899
14899
|
url: runtime.url,
|
|
14900
|
-
...runtime.dataPlan && { dataPlan: runtime.dataPlan }
|
|
14900
|
+
...runtime.dataPlan && { dataPlan: runtime.dataPlan },
|
|
14901
|
+
...runtime.recipe && { recipe: runtime.recipe }
|
|
14901
14902
|
};
|
|
14902
14903
|
};
|
|
14903
14904
|
const sdkRuntime = publication(value.sdkRuntime);
|
|
@@ -30840,6 +30841,21 @@ var init_swift_root_lock = __esm({
|
|
|
30840
30841
|
}
|
|
30841
30842
|
});
|
|
30842
30843
|
|
|
30844
|
+
// src/swift-sdk-image-recipe.ts
|
|
30845
|
+
var import_node_crypto27, SWIFT_SDK_IMAGE_VERSION, swiftSdkImageScope, SWIFT_SDK_IMAGE_RECIPE;
|
|
30846
|
+
var init_swift_sdk_image_recipe = __esm({
|
|
30847
|
+
"src/swift-sdk-image-recipe.ts"() {
|
|
30848
|
+
"use strict";
|
|
30849
|
+
import_node_crypto27 = require("node:crypto");
|
|
30850
|
+
init_wasm_optimize();
|
|
30851
|
+
SWIFT_SDK_IMAGE_VERSION = 13;
|
|
30852
|
+
swiftSdkImageScope = (scopedLookups) => scopedLookups ? "guest image scopes 9\n" : "unscoped constructor order 1\n";
|
|
30853
|
+
SWIFT_SDK_IMAGE_RECIPE = (0, import_node_crypto27.createHash)("sha256").update(`swift-sdk-image
|
|
30854
|
+
${SWIFT_SDK_IMAGE_VERSION}
|
|
30855
|
+
`).update(WASM_LOWER_IDENTITY).update(swiftSdkImageScope(false)).update(swiftSdkImageScope(true)).digest("hex").slice(0, 16);
|
|
30856
|
+
}
|
|
30857
|
+
});
|
|
30858
|
+
|
|
30843
30859
|
// src/swift-sdk-image-producer.ts
|
|
30844
30860
|
var swift_sdk_image_producer_exports = {};
|
|
30845
30861
|
__export(swift_sdk_image_producer_exports, {
|
|
@@ -30880,7 +30896,7 @@ function applySwiftSdkProducerEnvironment(environment) {
|
|
|
30880
30896
|
}
|
|
30881
30897
|
}
|
|
30882
30898
|
function writeSwiftSdkProducerResult(file, launchId, error) {
|
|
30883
|
-
const temporary = `${file}.${(0,
|
|
30899
|
+
const temporary = `${file}.${(0, import_node_crypto28.randomUUID)()}`;
|
|
30884
30900
|
(0, import_node_fs44.writeFileSync)(temporary, JSON.stringify({ launchId, error: error ?? null }));
|
|
30885
30901
|
(0, import_node_fs44.renameSync)(temporary, file);
|
|
30886
30902
|
}
|
|
@@ -30992,7 +31008,7 @@ async function produceSwiftSdkImage(input) {
|
|
|
30992
31008
|
}
|
|
30993
31009
|
}
|
|
30994
31010
|
const repo = import_node_path42.default.resolve(input.moduleRoot, "../..");
|
|
30995
|
-
const launchId = (0,
|
|
31011
|
+
const launchId = (0, import_node_crypto28.randomUUID)();
|
|
30996
31012
|
const directory3 = import_node_path42.default.join(root, launchId);
|
|
30997
31013
|
const requestFile = import_node_path42.default.join(directory3, "request.json");
|
|
30998
31014
|
const sessionFile2 = import_node_path42.default.join(directory3, "session");
|
|
@@ -31090,12 +31106,12 @@ async function produceSwiftSdkImage(input) {
|
|
|
31090
31106
|
await (0, import_promises5.setTimeout)(2e3, void 0, { signal: input.signal });
|
|
31091
31107
|
}
|
|
31092
31108
|
}
|
|
31093
|
-
var import_node_child_process27,
|
|
31109
|
+
var import_node_child_process27, import_node_crypto28, import_node_fs44, import_node_path42, import_promises5, import_node_util7, run, environmentNames, launcher;
|
|
31094
31110
|
var init_swift_sdk_image_producer = __esm({
|
|
31095
31111
|
"src/swift-sdk-image-producer.ts"() {
|
|
31096
31112
|
"use strict";
|
|
31097
31113
|
import_node_child_process27 = require("node:child_process");
|
|
31098
|
-
|
|
31114
|
+
import_node_crypto28 = require("node:crypto");
|
|
31099
31115
|
import_node_fs44 = require("node:fs");
|
|
31100
31116
|
import_node_path42 = __toESM(require("node:path"), 1);
|
|
31101
31117
|
import_promises5 = require("node:timers/promises");
|
|
@@ -31135,7 +31151,6 @@ __export(swift_sdk_image_exports, {
|
|
|
31135
31151
|
SWIFT_SDK_APP_TABLE_BASE: () => SWIFT_SDK_APP_TABLE_BASE,
|
|
31136
31152
|
SWIFT_SDK_IMAGE_BUNDLE: () => SWIFT_SDK_IMAGE_BUNDLE,
|
|
31137
31153
|
SWIFT_SDK_IMAGE_FILES: () => SWIFT_SDK_IMAGE_FILES,
|
|
31138
|
-
SWIFT_SDK_IMAGE_VERSION: () => SWIFT_SDK_IMAGE_VERSION,
|
|
31139
31154
|
SWIFT_SDK_MEMORY_BASE: () => SWIFT_SDK_MEMORY_BASE,
|
|
31140
31155
|
SWIFT_SDK_PIECE_FIELDS: () => SWIFT_SDK_PIECE_FIELDS,
|
|
31141
31156
|
buildSwiftSdkImage: () => buildSwiftSdkImage,
|
|
@@ -31170,9 +31185,9 @@ function swiftSdkImageProducts(moduleRoot, frameworkImports2) {
|
|
|
31170
31185
|
function swiftSdkImageKey(moduleRoot, scopedLookups = false, products = []) {
|
|
31171
31186
|
const distribution = swiftDistributionAt(moduleRoot);
|
|
31172
31187
|
const inputs2 = distribution ? swiftSdkDistributionInputs(distribution) : swiftModuleDigest(moduleRoot);
|
|
31173
|
-
return (0,
|
|
31188
|
+
return (0, import_node_crypto29.createHash)("sha256").update(`swift-sdk-image
|
|
31174
31189
|
${SWIFT_SDK_IMAGE_VERSION}
|
|
31175
|
-
`).update(WASM_LOWER_IDENTITY).update(KEEP_WASM_NAMES ? "\nnames\n" : "\n").update(scopedLookups
|
|
31190
|
+
`).update(WASM_LOWER_IDENTITY).update(KEEP_WASM_NAMES ? "\nnames\n" : "\n").update(swiftSdkImageScope(scopedLookups)).update(inputs2).update(products.length === 0 ? "" : `
|
|
31176
31191
|
products ${products.join(" ")}`).digest("hex").slice(0, 32);
|
|
31177
31192
|
}
|
|
31178
31193
|
function swiftSdkImageEntry(key2, scopedLookups) {
|
|
@@ -31261,7 +31276,7 @@ async function buildSwiftSdkImage(moduleRoot, scopedLookups = false, frameworkIm
|
|
|
31261
31276
|
stage
|
|
31262
31277
|
]);
|
|
31263
31278
|
const image = cached(stage, key2);
|
|
31264
|
-
if (!image || (0,
|
|
31279
|
+
if (!image || (0, import_node_crypto29.createHash)("sha256").update((0, import_node_fs45.readFileSync)(image.image)).digest("hex") !== image.sha256)
|
|
31265
31280
|
throw new Error(`invalid published Swift SDK image ${key2}`);
|
|
31266
31281
|
(0, import_node_fs45.rmSync)(directory2, { recursive: true, force: true });
|
|
31267
31282
|
(0, import_node_fs45.renameSync)(stage, directory2);
|
|
@@ -31531,7 +31546,7 @@ async function linkSwiftSdkImage(moduleRoot, key2, directory2, work, scopedLooku
|
|
|
31531
31546
|
(0, import_node_fs45.writeFileSync)(import_node_path43.default.join(work, INTERFACE_FILE), JSON.stringify(sdkInterface));
|
|
31532
31547
|
(0, import_node_fs45.writeFileSync)(
|
|
31533
31548
|
import_node_path43.default.join(work, IMAGE_DIGEST),
|
|
31534
|
-
typeof Bun !== "undefined" ? new Bun.CryptoHasher("sha256").update(image).digest("hex") : (0,
|
|
31549
|
+
typeof Bun !== "undefined" ? new Bun.CryptoHasher("sha256").update(image).digest("hex") : (0, import_node_crypto29.createHash)("sha256").update(image).digest("hex")
|
|
31535
31550
|
);
|
|
31536
31551
|
if (swiftSdkImageKey(
|
|
31537
31552
|
moduleRoot,
|
|
@@ -31800,12 +31815,12 @@ function readSwiftSdkManifest(image) {
|
|
|
31800
31815
|
}));
|
|
31801
31816
|
return setBoundedCache(cachedSdkManifests, cacheKey, { manifest, block: block2, segments });
|
|
31802
31817
|
}
|
|
31803
|
-
var import_node_child_process28,
|
|
31818
|
+
var import_node_child_process28, import_node_crypto29, import_node_fs45, import_node_path43, import_node_util8, run2, 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;
|
|
31804
31819
|
var init_swift_sdk_image = __esm({
|
|
31805
31820
|
"src/swift-sdk-image.ts"() {
|
|
31806
31821
|
"use strict";
|
|
31807
31822
|
import_node_child_process28 = require("node:child_process");
|
|
31808
|
-
|
|
31823
|
+
import_node_crypto29 = require("node:crypto");
|
|
31809
31824
|
import_node_fs45 = require("node:fs");
|
|
31810
31825
|
import_node_path43 = __toESM(require("node:path"), 1);
|
|
31811
31826
|
import_node_util8 = require("node:util");
|
|
@@ -31817,13 +31832,13 @@ var init_swift_sdk_image = __esm({
|
|
|
31817
31832
|
init_swift_root_lock();
|
|
31818
31833
|
init_swift_sdk_guest_lookups();
|
|
31819
31834
|
init_swift_sdk_image_map();
|
|
31835
|
+
init_swift_sdk_image_recipe();
|
|
31820
31836
|
init_swift_sdk_image_wasm();
|
|
31821
31837
|
init_swift_toolchain();
|
|
31822
31838
|
init_swift_wasm_prune();
|
|
31823
31839
|
init_swiftTargetContract();
|
|
31824
31840
|
init_wasm_optimize();
|
|
31825
31841
|
run2 = (0, import_node_util8.promisify)(import_node_child_process28.execFile);
|
|
31826
|
-
SWIFT_SDK_IMAGE_VERSION = 13;
|
|
31827
31842
|
SWIFT_SDK_APP_MEMORY_BASE = 8372224;
|
|
31828
31843
|
SWIFT_SDK_MEMORY_BASE = 128 * 1024 * 1024;
|
|
31829
31844
|
SWIFT_SDK_APP_TABLE_BASE = 524288;
|
|
@@ -32349,7 +32364,7 @@ async function linkSwiftAppModule(options2) {
|
|
|
32349
32364
|
lazy,
|
|
32350
32365
|
KEEP_WASM_NAMES
|
|
32351
32366
|
])
|
|
32352
|
-
).update(bytes).digest("hex") : (0,
|
|
32367
|
+
).update(bytes).digest("hex") : (0, import_node_crypto30.createHash)("sha256").update(
|
|
32353
32368
|
JSON.stringify([
|
|
32354
32369
|
loweringCache.compilerDigest,
|
|
32355
32370
|
optimize,
|
|
@@ -32968,7 +32983,7 @@ function createSwiftSdkBinding(linkage, sdk2, usage, projection) {
|
|
|
32968
32983
|
bindSwiftAppModule(linkage, sdk2),
|
|
32969
32984
|
selectSwiftSdkData(sdk2, usage, linkage, projection)
|
|
32970
32985
|
]);
|
|
32971
|
-
const sha2565 = typeof Bun !== "undefined" ? new Bun.CryptoHasher("sha256").update(bytes).digest("hex") : (0,
|
|
32986
|
+
const sha2565 = typeof Bun !== "undefined" ? new Bun.CryptoHasher("sha256").update(bytes).digest("hex") : (0, import_node_crypto30.createHash)("sha256").update(bytes).digest("hex");
|
|
32972
32987
|
return { bytes, sha256: sha2565 };
|
|
32973
32988
|
}
|
|
32974
32989
|
function readSwiftSdkUsage(mapFile, linkedFile, sdkObjects) {
|
|
@@ -33515,12 +33530,12 @@ function partitionParent(section2) {
|
|
|
33515
33530
|
"__objc_class_refs"
|
|
33516
33531
|
].find((name3) => section2 === name3 || section2.startsWith(`${name3}.`));
|
|
33517
33532
|
}
|
|
33518
|
-
var import_node_child_process29,
|
|
33533
|
+
var import_node_child_process29, import_node_crypto30, import_node_fs46, import_node_path44, import_node_util9, import_node_zlib5, run3, RELOCATION_WIDTHS, GLOBAL_INDEX, TLS_SLEB64, SDK_TLS_HELPER, SDK_TLS_DELTA, OBJC_SECTION_BOUNDARY, uleb4, sleb2, encodedName2, SCANNED, RUN_GAP;
|
|
33519
33534
|
var init_swift_sdk_app_module = __esm({
|
|
33520
33535
|
"src/swift-sdk-app-module.ts"() {
|
|
33521
33536
|
"use strict";
|
|
33522
33537
|
import_node_child_process29 = require("node:child_process");
|
|
33523
|
-
|
|
33538
|
+
import_node_crypto30 = require("node:crypto");
|
|
33524
33539
|
import_node_fs46 = require("node:fs");
|
|
33525
33540
|
import_node_path44 = __toESM(require("node:path"), 1);
|
|
33526
33541
|
import_node_util9 = require("node:util");
|
|
@@ -34226,7 +34241,7 @@ function compilerCheckpoint(root, recipe2, args, header) {
|
|
|
34226
34241
|
}
|
|
34227
34242
|
if (!objects.length) return;
|
|
34228
34243
|
const outputs = [module2, header, map2[""].dependencies, ...objects];
|
|
34229
|
-
const digest3 = (0,
|
|
34244
|
+
const digest3 = (0, import_node_crypto31.createHash)("sha256").update(recipe2).update(JSON.stringify(args)).update(mapText);
|
|
34230
34245
|
for (const flag of args) {
|
|
34231
34246
|
if (!flag.startsWith("@")) continue;
|
|
34232
34247
|
const response = flag.slice(1);
|
|
@@ -34320,11 +34335,11 @@ async function withSwiftHeaderCompiler(root, toolchainBin, recipe2, producers, b
|
|
|
34320
34335
|
(0, import_node_fs48.rmSync)(directory2, { recursive: true, force: true });
|
|
34321
34336
|
}
|
|
34322
34337
|
}
|
|
34323
|
-
var
|
|
34338
|
+
var import_node_crypto31, import_node_fs48, import_node_http2, import_node_path46, SWIFT_HEADER_COMPILER_WRAPPER, argument, client;
|
|
34324
34339
|
var init_swift_header_compiler = __esm({
|
|
34325
34340
|
"src/swift-header-compiler.ts"() {
|
|
34326
34341
|
"use strict";
|
|
34327
|
-
|
|
34342
|
+
import_node_crypto31 = require("node:crypto");
|
|
34328
34343
|
import_node_fs48 = require("node:fs");
|
|
34329
34344
|
import_node_http2 = require("node:http");
|
|
34330
34345
|
import_node_path46 = __toESM(require("node:path"), 1);
|
|
@@ -34607,7 +34622,7 @@ function swiftIcuAsset(toolchainBin, sdk2) {
|
|
|
34607
34622
|
JSON.stringify([toolchainBin, sdk2, swiftSdkOptions()]),
|
|
34608
34623
|
async () => {
|
|
34609
34624
|
const zipped = await deflate(await swiftIcuData(toolchainBin, sdk2));
|
|
34610
|
-
return { sha256: (0,
|
|
34625
|
+
return { sha256: (0, import_node_crypto32.createHash)("sha256").update(zipped).digest("hex"), gzip: zipped };
|
|
34611
34626
|
}
|
|
34612
34627
|
);
|
|
34613
34628
|
}
|
|
@@ -34709,7 +34724,7 @@ function swiftIcuPacked(icu) {
|
|
|
34709
34724
|
)
|
|
34710
34725
|
);
|
|
34711
34726
|
await (0, import_promises6.mkdir)(import_node_path48.default.dirname(file), { recursive: true });
|
|
34712
|
-
const tmp = `${file}.${(0,
|
|
34727
|
+
const tmp = `${file}.${(0, import_node_crypto32.randomUUID)()}.tmp`;
|
|
34713
34728
|
await (0, import_promises6.writeFile)(tmp, packed);
|
|
34714
34729
|
await (0, import_promises6.rename)(tmp, file);
|
|
34715
34730
|
return packed;
|
|
@@ -34722,12 +34737,12 @@ async function swiftIcuBundleAsset(icu) {
|
|
|
34722
34737
|
contentType: "application/octet-stream"
|
|
34723
34738
|
};
|
|
34724
34739
|
}
|
|
34725
|
-
var import_node_child_process31,
|
|
34740
|
+
var import_node_child_process31, import_node_crypto32, import_node_fs49, import_promises6, import_node_os12, import_node_path48, import_node_util10, import_node_zlib6, run4, deflate, compressBrotli, inflateGzip, ARCHIVE, MEMBER, raw, assets, packedFiles;
|
|
34726
34741
|
var init_swift_icu = __esm({
|
|
34727
34742
|
"src/swift-icu.ts"() {
|
|
34728
34743
|
"use strict";
|
|
34729
34744
|
import_node_child_process31 = require("node:child_process");
|
|
34730
|
-
|
|
34745
|
+
import_node_crypto32 = require("node:crypto");
|
|
34731
34746
|
import_node_fs49 = require("node:fs");
|
|
34732
34747
|
import_promises6 = require("node:fs/promises");
|
|
34733
34748
|
import_node_os12 = __toESM(require("node:os"), 1);
|
|
@@ -34997,7 +35012,7 @@ function swiftObjCPrebuiltCompiler(clang, root, sysroot, distribution, targets,
|
|
|
34997
35012
|
);
|
|
34998
35013
|
if (!modules.length) return [];
|
|
34999
35014
|
const { executable, prefixArgs } = rnxSelfInvocation();
|
|
35000
|
-
const compiler = (0,
|
|
35015
|
+
const compiler = (0, import_node_crypto33.createHash)("sha256").update(import_node_fs51.default.readFileSync(clang)).digest("hex");
|
|
35001
35016
|
return [
|
|
35002
35017
|
'case "$module" in',
|
|
35003
35018
|
` ${modules.join("|")}) exec ${[
|
|
@@ -35015,12 +35030,12 @@ function swiftObjCPrebuiltCompiler(clang, root, sysroot, distribution, targets,
|
|
|
35015
35030
|
"esac"
|
|
35016
35031
|
];
|
|
35017
35032
|
}
|
|
35018
|
-
var import_node_child_process33,
|
|
35033
|
+
var import_node_child_process33, import_node_crypto33, import_node_fs51, import_node_path50, quote2;
|
|
35019
35034
|
var init_swift_objc_prebuilt = __esm({
|
|
35020
35035
|
"src/swift-objc-prebuilt.ts"() {
|
|
35021
35036
|
"use strict";
|
|
35022
35037
|
import_node_child_process33 = require("node:child_process");
|
|
35023
|
-
|
|
35038
|
+
import_node_crypto33 = require("node:crypto");
|
|
35024
35039
|
import_node_fs51 = __toESM(require("node:fs"), 1);
|
|
35025
35040
|
import_node_path50 = __toESM(require("node:path"), 1);
|
|
35026
35041
|
init_internal_child_contract();
|
|
@@ -35373,7 +35388,7 @@ function swiftPackagePrebuiltEntries(input, moduleRoot, toolchainBin) {
|
|
|
35373
35388
|
([file, source]) => !/\.(?:swift|c|h|inc|modulemap)$/.test(file) || file.endsWith(".swift") && swiftImportNames(source, available2).some((name4) => !available2.has(name4))
|
|
35374
35389
|
))
|
|
35375
35390
|
return [];
|
|
35376
|
-
const hash = (0,
|
|
35391
|
+
const hash = (0, import_node_crypto34.createHash)("sha256");
|
|
35377
35392
|
for (const entry of files2.sort(
|
|
35378
35393
|
([left], [right]) => left < right ? -1 : left > right ? 1 : 0
|
|
35379
35394
|
))
|
|
@@ -35440,11 +35455,11 @@ function useSwiftPackagePrebuilts(input, moduleRoot, toolchainBin) {
|
|
|
35440
35455
|
}
|
|
35441
35456
|
return resolved;
|
|
35442
35457
|
}
|
|
35443
|
-
var
|
|
35458
|
+
var import_node_crypto34, import_node_fs54, import_node_path54, PACKAGE_RECIPE;
|
|
35444
35459
|
var init_swift_package_prebuilt = __esm({
|
|
35445
35460
|
"src/swift-package-prebuilt.ts"() {
|
|
35446
35461
|
"use strict";
|
|
35447
|
-
|
|
35462
|
+
import_node_crypto34 = require("node:crypto");
|
|
35448
35463
|
import_node_fs54 = __toESM(require("node:fs"), 1);
|
|
35449
35464
|
import_node_path54 = __toESM(require("node:path"), 1);
|
|
35450
35465
|
init_native_prebuilt();
|
|
@@ -35604,7 +35619,7 @@ function swiftObjCSelectorOptions(moduleRoot) {
|
|
|
35604
35619
|
`;
|
|
35605
35620
|
if (!(0, import_node_fs55.existsSync)(map2) || (0, import_node_fs55.readFileSync)(map2, "utf8") !== content) {
|
|
35606
35621
|
(0, import_node_fs55.mkdirSync)(import_node_path55.default.dirname(map2), { recursive: true });
|
|
35607
|
-
const partial = `${map2}.${(0,
|
|
35622
|
+
const partial = `${map2}.${(0, import_node_crypto35.randomUUID)()}`;
|
|
35608
35623
|
(0, import_node_fs55.writeFileSync)(partial, content);
|
|
35609
35624
|
(0, import_node_fs55.renameSync)(partial, map2);
|
|
35610
35625
|
}
|
|
@@ -35632,7 +35647,7 @@ async function ensureMacroPlugins(moduleRoot, toolchainBin, release, signal, lea
|
|
|
35632
35647
|
return { libraries, executables };
|
|
35633
35648
|
}
|
|
35634
35649
|
function swiftProjectBuildKey(moduleRoot, release) {
|
|
35635
|
-
return (0,
|
|
35650
|
+
return (0, import_node_crypto35.createHash)("sha256").update(`swift-framework/v2\0${release}\0${swiftModuleSdk(moduleRoot).wasmSdkId}`).update(swiftModuleDigest(moduleRoot)).digest("hex").slice(0, 32);
|
|
35636
35651
|
}
|
|
35637
35652
|
function sameStringList(left, right) {
|
|
35638
35653
|
if (left === right) return true;
|
|
@@ -35880,7 +35895,7 @@ function distributionClangModuleOptions(root, modules) {
|
|
|
35880
35895
|
function providedModulesPath(root, modules, excluded) {
|
|
35881
35896
|
if (!excluded || excluded.size === 0) return modules;
|
|
35882
35897
|
const entries2 = (0, import_node_fs55.readdirSync)(modules).filter((entry) => !excluded.has(entry.replace(/\..*$/, ""))).sort();
|
|
35883
|
-
const key2 = (0,
|
|
35898
|
+
const key2 = (0, import_node_crypto35.createHash)("sha256").update(JSON.stringify([modules, entries2])).update([...excluded].sort().join("\0")).digest("hex").slice(0, 16);
|
|
35884
35899
|
const directory2 = import_node_path55.default.join(root, `.peach-modules-${key2}`);
|
|
35885
35900
|
const complete = import_node_path55.default.join(directory2, ".complete");
|
|
35886
35901
|
if (!(0, import_node_fs55.existsSync)(complete)) {
|
|
@@ -35962,10 +35977,10 @@ function swiftTargetDependencies(files2, targets, frameworks = OPTIONAL_FRAMEWOR
|
|
|
35962
35977
|
function sha256Digest(value) {
|
|
35963
35978
|
if (typeof Bun !== "undefined")
|
|
35964
35979
|
return new Bun.CryptoHasher("sha256").update(value).digest();
|
|
35965
|
-
return (0,
|
|
35980
|
+
return (0, import_node_crypto35.createHash)("sha256").update(value).digest();
|
|
35966
35981
|
}
|
|
35967
35982
|
function swiftCompileInputHash(input, release) {
|
|
35968
|
-
const hash = (0,
|
|
35983
|
+
const hash = (0, import_node_crypto35.createHash)("sha256");
|
|
35969
35984
|
hash.update(`swift-compile
|
|
35970
35985
|
${release}
|
|
35971
35986
|
`);
|
|
@@ -36172,7 +36187,7 @@ function emitSwiftPackageManifest(args) {
|
|
|
36172
36187
|
].join("\n") + "\n";
|
|
36173
36188
|
distributionLinkPath = distributionLink.path.replace(
|
|
36174
36189
|
/\.rsp$/,
|
|
36175
|
-
`-${(0,
|
|
36190
|
+
`-${(0, import_node_crypto35.createHash)("sha256").update(list2).digest("hex").slice(0, 12)}.rsp`
|
|
36176
36191
|
);
|
|
36177
36192
|
distributionLink.files.set(distributionLinkPath, list2);
|
|
36178
36193
|
}
|
|
@@ -36193,7 +36208,7 @@ function emitSwiftPackageManifest(args) {
|
|
|
36193
36208
|
const endRun = () => {
|
|
36194
36209
|
if (run16.length >= MODULE_MAP_RESPONSE_FILE_RUN) {
|
|
36195
36210
|
const lines = run16.map((flag) => JSON.stringify(flag)).join("\n") + "\n";
|
|
36196
|
-
const digest4 = (0,
|
|
36211
|
+
const digest4 = (0, import_node_crypto35.createHash)("sha256").update(lines).digest("hex");
|
|
36197
36212
|
const file2 = import_node_path55.default.join(args.root, ".peach-clang-arguments", `${digest4}.rsp`);
|
|
36198
36213
|
args.files.set(file2, lines);
|
|
36199
36214
|
flags.push(`@${file2}`);
|
|
@@ -36217,7 +36232,7 @@ function emitSwiftPackageManifest(args) {
|
|
|
36217
36232
|
}
|
|
36218
36233
|
endRun();
|
|
36219
36234
|
const content = JSON.stringify(flags);
|
|
36220
|
-
const digest3 = (0,
|
|
36235
|
+
const digest3 = (0, import_node_crypto35.createHash)("sha256").update(content).digest("hex");
|
|
36221
36236
|
const file = import_node_path55.default.join(args.root, ".peach-manifest-arguments", `${digest3}.json`);
|
|
36222
36237
|
args.files.set(file, content);
|
|
36223
36238
|
return `peachCompilerArguments(${JSON.stringify(file)})`;
|
|
@@ -36229,7 +36244,7 @@ function emitSwiftPackageManifest(args) {
|
|
|
36229
36244
|
const macros = compactSwiftClangDefines(swiftClangSearchArguments(flags));
|
|
36230
36245
|
const compact = args.coalescibleOverlays ? compactSwiftClangOverlays(macros, args.coalescibleOverlays) : macros;
|
|
36231
36246
|
const content = compact.map((flag) => JSON.stringify(flag)).join("\n") + "\n";
|
|
36232
|
-
const digest3 = (0,
|
|
36247
|
+
const digest3 = (0, import_node_crypto35.createHash)("sha256").update(content).digest("hex");
|
|
36233
36248
|
const file = import_node_path55.default.join(args.root, ".peach-swift-arguments", `${digest3}.rsp`);
|
|
36234
36249
|
args.files.set(file, content);
|
|
36235
36250
|
return JSON.stringify([`@${file}`]);
|
|
@@ -37818,7 +37833,7 @@ ${swiftProjectFilesProblems(input.projectFiles).join("\n")}`
|
|
|
37818
37833
|
)
|
|
37819
37834
|
];
|
|
37820
37835
|
const moduleFlag = perFile.some((flag) => flag.startsWith("-fmodule-name=")) ? [] : [`-fmodule-name=${swiftTargetModuleName(target.name)}`];
|
|
37821
|
-
const identity2 = (0,
|
|
37836
|
+
const identity2 = (0, import_node_crypto35.createHash)("sha256").update(
|
|
37822
37837
|
JSON.stringify([
|
|
37823
37838
|
cxx,
|
|
37824
37839
|
quoteDirs,
|
|
@@ -38181,7 +38196,7 @@ module ${moduleName2}.Swift {
|
|
|
38181
38196
|
])
|
|
38182
38197
|
(0, import_node_fs55.rmSync)(cache, { recursive: true, force: true });
|
|
38183
38198
|
files2.set(frameworkSearchRecord, frameworkSearch);
|
|
38184
|
-
const modulePlan = (0,
|
|
38199
|
+
const modulePlan = (0, import_node_crypto35.createHash)("sha256").update(
|
|
38185
38200
|
swiftModuleInputFiles(moduleRoot).join("\n")
|
|
38186
38201
|
);
|
|
38187
38202
|
if (!distribution) {
|
|
@@ -38190,7 +38205,7 @@ module ${moduleName2}.Swift {
|
|
|
38190
38205
|
modulePlan.update(
|
|
38191
38206
|
Object.keys(input.files).filter((file) => file.endsWith(".swift")).sort().join("\n")
|
|
38192
38207
|
);
|
|
38193
|
-
const resourcePlan = (0,
|
|
38208
|
+
const resourcePlan = (0, import_node_crypto35.createHash)("sha256").update(
|
|
38194
38209
|
JSON.stringify(
|
|
38195
38210
|
resourceTargets.filter((target) => target.resources).map((target) => [
|
|
38196
38211
|
target.name,
|
|
@@ -38498,7 +38513,7 @@ ${entry}`);
|
|
|
38498
38513
|
);
|
|
38499
38514
|
for (const [target, data] of Object.entries(input.libraries ?? {})) {
|
|
38500
38515
|
const bytes = Buffer.from(data, "base64");
|
|
38501
|
-
const digest3 = (0,
|
|
38516
|
+
const digest3 = (0, import_node_crypto35.createHash)("sha256").update(bytes).digest("hex");
|
|
38502
38517
|
if (input.binaryModules?.[target] && packageTargets.has(target)) {
|
|
38503
38518
|
const objects = import_node_path55.default.join(
|
|
38504
38519
|
layout2.root,
|
|
@@ -39150,7 +39165,7 @@ function readCompiledArtifact(directory2, hash) {
|
|
|
39150
39165
|
return null;
|
|
39151
39166
|
const bytes = (0, import_node_fs55.readFileSync)(import_node_path55.default.join(directory2, "app.wasm"));
|
|
39152
39167
|
const gzip2 = (0, import_node_fs55.readFileSync)(import_node_path55.default.join(directory2, "icu.gz"));
|
|
39153
|
-
if ((0,
|
|
39168
|
+
if ((0, import_node_crypto35.createHash)("sha256").update(bytes).digest("hex") !== receipt.wasm || (0, import_node_crypto35.createHash)("sha256").update(gzip2).digest("hex") !== receipt.icu || bytes.length <= 8 || bytes.readUInt32LE(0) !== 1836278016 || bytes.readUInt32LE(4) !== 1)
|
|
39154
39169
|
return null;
|
|
39155
39170
|
let sdk2;
|
|
39156
39171
|
if ("sdk" in receipt) {
|
|
@@ -39158,7 +39173,7 @@ function readCompiledArtifact(directory2, hash) {
|
|
|
39158
39173
|
if (!isRecord(image) || typeof image.key !== "string" || typeof image.sha256 !== "string" || typeof image.binding !== "string")
|
|
39159
39174
|
return null;
|
|
39160
39175
|
const binding = (0, import_node_fs55.readFileSync)(import_node_path55.default.join(directory2, "sdk-binding.bin"));
|
|
39161
|
-
if ((0,
|
|
39176
|
+
if ((0, import_node_crypto35.createHash)("sha256").update(binding).digest("hex") !== image.binding)
|
|
39162
39177
|
return null;
|
|
39163
39178
|
sdk2 = {
|
|
39164
39179
|
key: image.key,
|
|
@@ -39186,7 +39201,7 @@ function saveCompiledArtifact(root, artifact) {
|
|
|
39186
39201
|
import_node_path55.default.join(pending2, "artifact.json"),
|
|
39187
39202
|
JSON.stringify({
|
|
39188
39203
|
hash: artifact.hash,
|
|
39189
|
-
wasm: (0,
|
|
39204
|
+
wasm: (0, import_node_crypto35.createHash)("sha256").update(artifact.bytes).digest("hex"),
|
|
39190
39205
|
icu: artifact.icu.sha256,
|
|
39191
39206
|
sdk: artifact.sdk && {
|
|
39192
39207
|
key: artifact.sdk.key,
|
|
@@ -39535,7 +39550,7 @@ async function buildFrameworkProducts(scratch2, args) {
|
|
|
39535
39550
|
const unoptimized = args.input.unoptimized === true;
|
|
39536
39551
|
const sdkOptions = swiftCompileSdkOptions(args.moduleRoot, args.toolchainBin);
|
|
39537
39552
|
const selectorOptions = swiftObjCSelectorOptions(args.moduleRoot);
|
|
39538
|
-
const receiptKey = (0,
|
|
39553
|
+
const receiptKey = (0, import_node_crypto35.createHash)("sha256").update(
|
|
39539
39554
|
JSON.stringify([
|
|
39540
39555
|
"framework-products/v2",
|
|
39541
39556
|
args.frameworkKey,
|
|
@@ -39702,7 +39717,7 @@ async function buildFrameworkProducts(scratch2, args) {
|
|
|
39702
39717
|
const archiveBase = import_node_path55.default.join(scratch2, "products-lib");
|
|
39703
39718
|
(0, import_node_fs55.mkdirSync)(archiveBase, { recursive: true });
|
|
39704
39719
|
const archiveRoot = import_node_path55.default.join(archiveBase, receiptKey);
|
|
39705
|
-
const stagedArchiveRoot = `${archiveRoot}.tmp-${process.pid}-${(0,
|
|
39720
|
+
const stagedArchiveRoot = `${archiveRoot}.tmp-${process.pid}-${(0, import_node_crypto35.randomUUID)()}`;
|
|
39706
39721
|
const stagedArchive = import_node_path55.default.join(stagedArchiveRoot, "lib");
|
|
39707
39722
|
(0, import_node_fs55.mkdirSync)(stagedArchive, { recursive: true });
|
|
39708
39723
|
const archived = /* @__PURE__ */ new Map();
|
|
@@ -39745,7 +39760,7 @@ ${args.frameworkKey}`,
|
|
|
39745
39760
|
const receiptsDir = import_node_path55.default.join(scratch2, "products-ready");
|
|
39746
39761
|
(0, import_node_fs55.mkdirSync)(receiptsDir, { recursive: true });
|
|
39747
39762
|
const receiptFile2 = import_node_path55.default.join(receiptsDir, `${receiptKey}.json`);
|
|
39748
|
-
const partialReceipt = `${receiptFile2}.${process.pid}.${(0,
|
|
39763
|
+
const partialReceipt = `${receiptFile2}.${process.pid}.${(0, import_node_crypto35.randomUUID)()}`;
|
|
39749
39764
|
(0, import_node_fs55.writeFileSync)(
|
|
39750
39765
|
partialReceipt,
|
|
39751
39766
|
JSON.stringify({
|
|
@@ -39917,7 +39932,7 @@ function mirrorTree2(source, target, skip) {
|
|
|
39917
39932
|
if (existing?.isFile() && existing.size === stat.size && (existing.mtimeMs === stat.mtimeMs || (0, import_node_fs55.readFileSync)(from).equals((0, import_node_fs55.readFileSync)(to))))
|
|
39918
39933
|
continue;
|
|
39919
39934
|
if (existing) (0, import_node_fs55.rmSync)(to, { recursive: true, force: true });
|
|
39920
|
-
const partial = `${to}.${(0,
|
|
39935
|
+
const partial = `${to}.${(0, import_node_crypto35.randomUUID)()}`;
|
|
39921
39936
|
(0, import_node_fs55.copyFileSync)(from, partial);
|
|
39922
39937
|
if (stat.mtimeMs > Date.now()) (0, import_node_fs55.utimesSync)(partial, stat.atime, stat.mtime);
|
|
39923
39938
|
(0, import_node_fs55.renameSync)(partial, to);
|
|
@@ -39977,7 +39992,7 @@ function stageFrameworkSource(moduleRoot, slot, frameworkKey, release) {
|
|
|
39977
39992
|
return stagedModule;
|
|
39978
39993
|
}
|
|
39979
39994
|
function swiftLinkStamp(args) {
|
|
39980
|
-
const hash = (0,
|
|
39995
|
+
const hash = (0, import_node_crypto35.createHash)("sha256");
|
|
39981
39996
|
hash.update(`swift-link/v1
|
|
39982
39997
|
${args.frameworkKey}
|
|
39983
39998
|
`);
|
|
@@ -40105,7 +40120,7 @@ async function compileSwiftProjectOnce(sources, options2) {
|
|
|
40105
40120
|
const inputHash = swiftCompileInputHash(input, options2.release);
|
|
40106
40121
|
const moduleDigest = swiftModuleDigest(moduleRoot);
|
|
40107
40122
|
const sourceHash = inputHash.copy().update(moduleDigest).digest("hex");
|
|
40108
|
-
const hash = sdkImage ? (0,
|
|
40123
|
+
const hash = sdkImage ? (0, import_node_crypto35.createHash)("sha256").update(`${sourceHash}
|
|
40109
40124
|
sdk module ${sdkImage.key}`).digest("hex") : sourceHash;
|
|
40110
40125
|
const frameworkKey = swiftProjectBuildKey(moduleRoot, options2.release);
|
|
40111
40126
|
const sharedRoot = import_node_path55.default.join(swiftCacheDir(), "swift-projects", hash);
|
|
@@ -40202,7 +40217,7 @@ ${cap}` : "";
|
|
|
40202
40217
|
}
|
|
40203
40218
|
const baseRoot = root;
|
|
40204
40219
|
const canPoolBuildRoot = !options2.intermediates && !options2.project && !options2.linkOnly && import_node_path55.default.basename(import_node_path55.default.dirname(baseRoot)) === "swift-builds";
|
|
40205
|
-
const buildShape = canPoolBuildRoot ? (0,
|
|
40220
|
+
const buildShape = canPoolBuildRoot ? (0, import_node_crypto35.createHash)("sha256").update(
|
|
40206
40221
|
JSON.stringify([
|
|
40207
40222
|
frameworkKey,
|
|
40208
40223
|
Boolean(sdkImage),
|
|
@@ -40691,17 +40706,17 @@ ${cap}` : "";
|
|
|
40691
40706
|
}
|
|
40692
40707
|
const receipt = import_node_path55.default.join(
|
|
40693
40708
|
checkpoints,
|
|
40694
|
-
(0,
|
|
40709
|
+
(0, import_node_crypto35.createHash)("sha256").update(target).digest("hex")
|
|
40695
40710
|
);
|
|
40696
40711
|
const headers = producers.map(headerPaths);
|
|
40697
40712
|
for (const header of headers)
|
|
40698
40713
|
if ((0, import_node_fs55.existsSync)(header.original)) publishHeader(header);
|
|
40699
40714
|
const fingerprint = () => {
|
|
40700
|
-
const digest3 = (0,
|
|
40715
|
+
const digest3 = (0, import_node_crypto35.createHash)("sha256").update(recipe2);
|
|
40701
40716
|
for (const { original, emitted } of headers) {
|
|
40702
40717
|
if (!(0, import_node_fs55.existsSync)(original) || !(0, import_node_fs55.existsSync)(emitted)) return;
|
|
40703
40718
|
digest3.update(
|
|
40704
|
-
(0,
|
|
40719
|
+
(0, import_node_crypto35.createHash)("sha256").update((0, import_node_fs55.readFileSync)(emitted)).digest()
|
|
40705
40720
|
);
|
|
40706
40721
|
}
|
|
40707
40722
|
return digest3.digest("hex");
|
|
@@ -40914,12 +40929,12 @@ ${cap}` : "";
|
|
|
40914
40929
|
options2.signal
|
|
40915
40930
|
);
|
|
40916
40931
|
}
|
|
40917
|
-
var import_node_child_process35,
|
|
40932
|
+
var import_node_child_process35, import_node_crypto35, import_node_fs55, import_node_os14, import_node_path55, 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;
|
|
40918
40933
|
var init_swift_compile = __esm({
|
|
40919
40934
|
"src/swift-compile.ts"() {
|
|
40920
40935
|
"use strict";
|
|
40921
40936
|
import_node_child_process35 = require("node:child_process");
|
|
40922
|
-
|
|
40937
|
+
import_node_crypto35 = require("node:crypto");
|
|
40923
40938
|
import_node_fs55 = require("node:fs");
|
|
40924
40939
|
import_node_os14 = __toESM(require("node:os"), 1);
|
|
40925
40940
|
import_node_path55 = __toESM(require("node:path"), 1);
|
|
@@ -41147,7 +41162,7 @@ ${wasmThreadLinkFlags.map((flag) => ` "-Xlinker", ${JSON.stringify(flag
|
|
|
41147
41162
|
REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
|
|
41148
41163
|
MULTI_MANIFEST_VERSION = 76;
|
|
41149
41164
|
SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
|
|
41150
|
-
compilerSourceDigest = true ? "
|
|
41165
|
+
compilerSourceDigest = true ? "169122685e250113f128b79efc78f9868f581da36ab083c174056ab99b87b629" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
|
|
41151
41166
|
nativeCxxCompilerFlags = ["-fno-cxx-modules"];
|
|
41152
41167
|
MODULE_MAP_RESPONSE_FILE_RUN = 16;
|
|
41153
41168
|
cFlagArray = (flags) => JSON.stringify(withoutGlogModuleMap(flags));
|
|
@@ -41263,7 +41278,7 @@ async function podPrepareEnvironment(base2) {
|
|
|
41263
41278
|
if (process.platform !== "linux") return base2;
|
|
41264
41279
|
const { root, toolchainBin } = await resolveSwiftModule();
|
|
41265
41280
|
const { sysroot, resources } = swiftSdkPaths(root, toolchainBin);
|
|
41266
|
-
const key2 = (0,
|
|
41281
|
+
const key2 = (0, import_node_crypto36.createHash)("sha256").update(XCRUN).update(CLANG).digest("hex").slice(0, 16);
|
|
41267
41282
|
const directory2 = import_node_path56.default.join(cacheDir(), "pod-tools", key2);
|
|
41268
41283
|
if (!import_node_fs56.default.existsSync(directory2)) {
|
|
41269
41284
|
import_node_fs56.default.mkdirSync(import_node_path56.default.dirname(directory2), { recursive: true });
|
|
@@ -41304,11 +41319,11 @@ async function podPrepareEnvironment(base2) {
|
|
|
41304
41319
|
PEACH_POD_RESOURCES: resources
|
|
41305
41320
|
};
|
|
41306
41321
|
}
|
|
41307
|
-
var
|
|
41322
|
+
var import_node_crypto36, import_node_fs56, import_node_path56, XCRUN, CLANG;
|
|
41308
41323
|
var init_pod_prepare_toolchain = __esm({
|
|
41309
41324
|
"src/pod-prepare-toolchain.ts"() {
|
|
41310
41325
|
"use strict";
|
|
41311
|
-
|
|
41326
|
+
import_node_crypto36 = require("node:crypto");
|
|
41312
41327
|
import_node_fs56 = __toESM(require("node:fs"), 1);
|
|
41313
41328
|
import_node_path56 = __toESM(require("node:path"), 1);
|
|
41314
41329
|
init_home_paths();
|
|
@@ -41394,10 +41409,10 @@ async function podSourceRoot(spec, prepareEnv) {
|
|
|
41394
41409
|
`${name3}: unrecognized ${strategy} source options ${unrecognized.join(", ")}`
|
|
41395
41410
|
);
|
|
41396
41411
|
const base2 = import_node_path57.default.join(rnxHomeDir(), "pod-sources");
|
|
41397
|
-
const digest3 = (0,
|
|
41412
|
+
const digest3 = (0, import_node_crypto37.createHash)("sha256").update(canonicalJson(source)).digest("hex").slice(0, 16);
|
|
41398
41413
|
const root = import_node_path57.default.join(base2, name3, `${String(spec.version)}-${digest3}`);
|
|
41399
41414
|
if (import_node_fs57.default.existsSync(root)) return root;
|
|
41400
|
-
const stage = import_node_path57.default.join(base2, ".staging", (0,
|
|
41415
|
+
const stage = import_node_path57.default.join(base2, ".staging", (0, import_node_crypto37.randomUUID)());
|
|
41401
41416
|
import_node_fs57.default.mkdirSync(stage, { recursive: true });
|
|
41402
41417
|
try {
|
|
41403
41418
|
if (strategy === "git") await downloadGit(name3, url, options2, stage);
|
|
@@ -41572,7 +41587,7 @@ async function downloadFile(pod, url, headers, file, algorithm) {
|
|
|
41572
41587
|
}
|
|
41573
41588
|
if (!response?.ok || !response.body)
|
|
41574
41589
|
throw new Error(`${pod}: GET ${url} failed with HTTP ${response?.status ?? "error"}`);
|
|
41575
|
-
const hash = algorithm ? (0,
|
|
41590
|
+
const hash = algorithm ? (0, import_node_crypto37.createHash)(algorithm) : null;
|
|
41576
41591
|
const handle = await import_node_fs57.default.promises.open(file, "w");
|
|
41577
41592
|
try {
|
|
41578
41593
|
const reader = response.body.getReader();
|
|
@@ -41829,12 +41844,12 @@ function cleanInstalledPod(spec, root, used) {
|
|
|
41829
41844
|
(node) => used.filter((entry) => entry.specs.includes(node.name)).map((entry) => entry.platform)
|
|
41830
41845
|
);
|
|
41831
41846
|
}
|
|
41832
|
-
var import_node_child_process36,
|
|
41847
|
+
var import_node_child_process36, import_node_crypto37, import_node_fs57, import_node_os15, import_node_path57, COCOAPODS_VERSION, USER_AGENT, PLATFORMS, HEADER_EXTENSIONS, SOURCE_EXTENSIONS, SOURCE_FILES_PATTERN, STRATEGIES, OPTIONS, ARCHIVE_TYPES, object4, RETRY_STATUSES, chomp, stringList, bracketEnd, escapeRegex;
|
|
41833
41848
|
var init_pod_sources = __esm({
|
|
41834
41849
|
"src/pod-sources.ts"() {
|
|
41835
41850
|
"use strict";
|
|
41836
41851
|
import_node_child_process36 = require("node:child_process");
|
|
41837
|
-
|
|
41852
|
+
import_node_crypto37 = require("node:crypto");
|
|
41838
41853
|
import_node_fs57 = __toESM(require("node:fs"), 1);
|
|
41839
41854
|
import_node_os15 = __toESM(require("node:os"), 1);
|
|
41840
41855
|
import_node_path57 = __toESM(require("node:path"), 1);
|
|
@@ -49088,7 +49103,7 @@ function specRepo(url, refresh) {
|
|
|
49088
49103
|
const dir = import_node_path58.default.join(
|
|
49089
49104
|
cacheDir(),
|
|
49090
49105
|
"cocoapods-repos",
|
|
49091
|
-
(0,
|
|
49106
|
+
(0, import_node_crypto38.createHash)("sha256").update(url).digest("hex").slice(0, 16)
|
|
49092
49107
|
);
|
|
49093
49108
|
if (!import_node_fs58.default.existsSync(import_node_path58.default.join(dir, ".git"))) {
|
|
49094
49109
|
const staged = `${dir}.${process.pid}`;
|
|
@@ -49118,7 +49133,7 @@ function podDir(repo, name3) {
|
|
|
49118
49133
|
const specs = import_node_fs58.default.existsSync(import_node_path58.default.join(repo, "Specs")) ? import_node_path58.default.join(repo, "Specs") : repo;
|
|
49119
49134
|
const metadata = import_node_path58.default.join(repo, "CocoaPods-version.yml");
|
|
49120
49135
|
const lengths = import_node_fs58.default.existsSync(metadata) ? browser_default.parse(import_node_fs58.default.readFileSync(metadata, "utf8"))?.prefix_lengths : void 0;
|
|
49121
|
-
const hash = (0,
|
|
49136
|
+
const hash = (0, import_node_crypto38.createHash)("md5").update(name3).digest("hex");
|
|
49122
49137
|
let at = 0;
|
|
49123
49138
|
const shards2 = (Array.isArray(lengths) ? lengths : []).map((length) => {
|
|
49124
49139
|
if (typeof length !== "number")
|
|
@@ -49151,17 +49166,17 @@ async function sourceSpecificationFile(source, name3, version2) {
|
|
|
49151
49166
|
if (!file) throw new Error(`${source} lists ${name3} ${version2} without a podspec`);
|
|
49152
49167
|
return file;
|
|
49153
49168
|
}
|
|
49154
|
-
var import_node_child_process37,
|
|
49169
|
+
var import_node_child_process37, import_node_crypto38, import_node_fs58, import_node_path58, shard, shards, TRUNK_SOURCES, refreshed, specRepoKey;
|
|
49155
49170
|
var init_cocoapods_trunk = __esm({
|
|
49156
49171
|
"src/cocoapods-trunk.ts"() {
|
|
49157
49172
|
"use strict";
|
|
49158
49173
|
import_node_child_process37 = require("node:child_process");
|
|
49159
|
-
|
|
49174
|
+
import_node_crypto38 = require("node:crypto");
|
|
49160
49175
|
import_node_fs58 = __toESM(require("node:fs"), 1);
|
|
49161
49176
|
import_node_path58 = __toESM(require("node:path"), 1);
|
|
49162
49177
|
init_browser();
|
|
49163
49178
|
init_home_paths();
|
|
49164
|
-
shard = (name3) => (0,
|
|
49179
|
+
shard = (name3) => (0, import_node_crypto38.createHash)("md5").update(name3).digest("hex").slice(0, 3).split("");
|
|
49165
49180
|
shards = /* @__PURE__ */ new Map();
|
|
49166
49181
|
TRUNK_SOURCES = /* @__PURE__ */ new Set([
|
|
49167
49182
|
"trunk",
|
|
@@ -49280,7 +49295,7 @@ function prism() {
|
|
|
49280
49295
|
throw new Error(`prism exited ${code}`);
|
|
49281
49296
|
},
|
|
49282
49297
|
random_get: (pointer2, length) => {
|
|
49283
|
-
if (memory) (0,
|
|
49298
|
+
if (memory) (0, import_node_crypto39.randomFillSync)(new Uint8Array(memory.buffer, pointer2, length));
|
|
49284
49299
|
return 0;
|
|
49285
49300
|
}
|
|
49286
49301
|
}
|
|
@@ -49304,11 +49319,11 @@ function parseRuby(source, file) {
|
|
|
49304
49319
|
parsed.set(file, { source, program: result.value });
|
|
49305
49320
|
return result.value;
|
|
49306
49321
|
}
|
|
49307
|
-
var
|
|
49322
|
+
var import_node_crypto39, import_node_fs60, import_node_module3, import_parsePrism, RubySyntaxError, prismExports, parsed;
|
|
49308
49323
|
var init_podspec_prism = __esm({
|
|
49309
49324
|
"src/podspec-prism.ts"() {
|
|
49310
49325
|
"use strict";
|
|
49311
|
-
|
|
49326
|
+
import_node_crypto39 = require("node:crypto");
|
|
49312
49327
|
import_node_fs60 = __toESM(require("node:fs"), 1);
|
|
49313
49328
|
import_node_module3 = require("node:module");
|
|
49314
49329
|
import_parsePrism = require("peachsim/vendor/@ruby/prism/src/parsePrism.js");
|
|
@@ -49927,7 +49942,7 @@ function stringMethod(interp, self, call, env) {
|
|
|
49927
49942
|
case "ascii_only?":
|
|
49928
49943
|
return call.name === "valid_encoding?" ? true : [...s].every((c) => c.charCodeAt(0) < 128);
|
|
49929
49944
|
case "hash":
|
|
49930
|
-
return Number.parseInt((0,
|
|
49945
|
+
return Number.parseInt((0, import_node_crypto40.createHash)("sha1").update(s).digest("hex").slice(0, 12), 16);
|
|
49931
49946
|
case "strip_heredoc":
|
|
49932
49947
|
return str2(stripHeredoc2(s));
|
|
49933
49948
|
case "squish":
|
|
@@ -50446,7 +50461,7 @@ function arrayMethod(interp, self, call, env) {
|
|
|
50446
50461
|
return NOT_FOUND;
|
|
50447
50462
|
case "hash":
|
|
50448
50463
|
return Number.parseInt(
|
|
50449
|
-
(0,
|
|
50464
|
+
(0, import_node_crypto40.createHash)("sha1").update(hashKey(self)).digest("hex").slice(0, 12),
|
|
50450
50465
|
16
|
|
50451
50466
|
);
|
|
50452
50467
|
case "pack":
|
|
@@ -50720,7 +50735,7 @@ function hashMethod(interp, self, call, env) {
|
|
|
50720
50735
|
}
|
|
50721
50736
|
case "hash":
|
|
50722
50737
|
return Number.parseInt(
|
|
50723
|
-
(0,
|
|
50738
|
+
(0, import_node_crypto40.createHash)("sha1").update(hashKey(self)).digest("hex").slice(0, 12),
|
|
50724
50739
|
16
|
|
50725
50740
|
);
|
|
50726
50741
|
case "compare_by_identity":
|
|
@@ -52059,12 +52074,12 @@ function archiveStepInside(words2, cwd, writable) {
|
|
|
52059
52074
|
return /^-x[a-z]*f$/.test(args[0] ?? "") && args.includes("-C") && operands.length === 2 && operands.every(inside);
|
|
52060
52075
|
return false;
|
|
52061
52076
|
}
|
|
52062
|
-
var import_node_child_process38,
|
|
52077
|
+
var import_node_child_process38, import_node_crypto40, import_node_fs61, import_node_path59, N, UnsupportedRuby, RString, RSymbol, RFloat, RRange, RRegexp, RMatch, RHash, RProc, RObject, RModule, Scope, RubyError, BreakSignal, NextSignal, ReturnSignal, ThrowSignal, objectIds, nextObjectId, str2, sym, truthy, POD_VERSION_METADATA, RubyVersion, Interpreter, RetrySignal, breakTags, BoundMethod, UnboundMethod, NOT_FOUND, EnumeratorData, RubyKeys, OBJECT_METHODS, KERNEL_METHODS, STDLIB, SCRIPT_RUNNERS;
|
|
52063
52078
|
var init_podspec_ruby = __esm({
|
|
52064
52079
|
"src/podspec-ruby.ts"() {
|
|
52065
52080
|
"use strict";
|
|
52066
52081
|
import_node_child_process38 = require("node:child_process");
|
|
52067
|
-
|
|
52082
|
+
import_node_crypto40 = require("node:crypto");
|
|
52068
52083
|
import_node_fs61 = __toESM(require("node:fs"), 1);
|
|
52069
52084
|
import_node_path59 = __toESM(require("node:path"), 1);
|
|
52070
52085
|
N = __toESM(require("peachsim/vendor/@ruby/prism/src/nodes.js"), 1);
|
|
@@ -54309,7 +54324,7 @@ function defineVersionClass(interp, cls) {
|
|
|
54309
54324
|
cls,
|
|
54310
54325
|
"hash",
|
|
54311
54326
|
(c) => Number.parseInt(
|
|
54312
|
-
(0,
|
|
54327
|
+
(0, import_node_crypto41.createHash)("sha1").update(data(c).text).digest("hex").slice(0, 12),
|
|
54313
54328
|
16
|
|
54314
54329
|
)
|
|
54315
54330
|
);
|
|
@@ -55123,11 +55138,11 @@ function installStdlib(interp) {
|
|
|
55123
55138
|
def(
|
|
55124
55139
|
cls,
|
|
55125
55140
|
"hexdigest",
|
|
55126
|
-
(c) => str2((0,
|
|
55141
|
+
(c) => str2((0, import_node_crypto41.createHash)(algorithm).update(text4(interp, c.args[0])).digest("hex"))
|
|
55127
55142
|
);
|
|
55128
55143
|
def(cls, "file", (c) => {
|
|
55129
55144
|
const value = new RObject(cls);
|
|
55130
|
-
value.data = (0,
|
|
55145
|
+
value.data = (0, import_node_crypto41.createHash)(algorithm).update(import_node_fs62.default.readFileSync(resolve4(text4(interp, c.args[0])))).digest("hex");
|
|
55131
55146
|
return value;
|
|
55132
55147
|
});
|
|
55133
55148
|
interp.defineNative(
|
|
@@ -55281,12 +55296,12 @@ function fnmatch(pattern, subject, flags) {
|
|
|
55281
55296
|
return !leadingDot && new RegExp(`^${source}$`, casefold ? "is" : "s").test(subject);
|
|
55282
55297
|
});
|
|
55283
55298
|
}
|
|
55284
|
-
var import_node_child_process39,
|
|
55299
|
+
var import_node_child_process39, import_node_crypto41, import_node_fs62, import_node_os16, import_node_path60, segment, FileHandle, WriteHandle, DownloadHandle, GemRequirement, TimeValue, SetData;
|
|
55285
55300
|
var init_podspec_ruby_stdlib = __esm({
|
|
55286
55301
|
"src/podspec-ruby-stdlib.ts"() {
|
|
55287
55302
|
"use strict";
|
|
55288
55303
|
import_node_child_process39 = require("node:child_process");
|
|
55289
|
-
|
|
55304
|
+
import_node_crypto41 = require("node:crypto");
|
|
55290
55305
|
import_node_fs62 = __toESM(require("node:fs"), 1);
|
|
55291
55306
|
import_node_os16 = __toESM(require("node:os"), 1);
|
|
55292
55307
|
import_node_path60 = __toESM(require("node:path"), 1);
|
|
@@ -66463,7 +66478,7 @@ function packageRoot(file) {
|
|
|
66463
66478
|
return directory2;
|
|
66464
66479
|
}
|
|
66465
66480
|
function appIdentity(app) {
|
|
66466
|
-
return (0,
|
|
66481
|
+
return (0, import_node_crypto42.createHash)("sha256").update(import_node_fs72.default.readFileSync(import_node_path72.default.join(app, "package.json"))).digest("hex");
|
|
66467
66482
|
}
|
|
66468
66483
|
function receiptFile(key2, environment) {
|
|
66469
66484
|
return import_node_path72.default.join(cacheDir(), "podspecs", "receipts-v1", key2, `${environment}.json`);
|
|
@@ -66487,7 +66502,7 @@ function podspecReceiptIdentity(file, appRoot = null) {
|
|
|
66487
66502
|
if (import_node_fs72.default.existsSync(manifest2)) manifests.add(manifest2);
|
|
66488
66503
|
if (directory2 === workspace || import_node_path72.default.dirname(directory2) === directory2) break;
|
|
66489
66504
|
}
|
|
66490
|
-
const hash = (0,
|
|
66505
|
+
const hash = (0, import_node_crypto42.createHash)("sha256").update(import_node_path72.default.relative(dependencyRoot, file)).update("\0").update(import_node_fs72.default.readFileSync(file));
|
|
66491
66506
|
hash.update("\0").update(manifest);
|
|
66492
66507
|
if (reactNative) hash.update("\0react-native-source");
|
|
66493
66508
|
for (const manifest2 of manifests) hash.update("\0").update(import_node_fs72.default.readFileSync(manifest2));
|
|
@@ -66501,7 +66516,7 @@ function podspecReceiptIdentity(file, appRoot = null) {
|
|
|
66501
66516
|
packageContexts.set(app, contexts);
|
|
66502
66517
|
let context = contexts.get(dependencyRoot);
|
|
66503
66518
|
if (!context) {
|
|
66504
|
-
const hash = (0,
|
|
66519
|
+
const hash = (0, import_node_crypto42.createHash)("sha256");
|
|
66505
66520
|
const walk4 = (relative4) => {
|
|
66506
66521
|
for (const entry of import_node_fs72.default.readdirSync(import_node_path72.default.join(dependencyRoot, relative4), {
|
|
66507
66522
|
withFileTypes: true
|
|
@@ -66520,7 +66535,7 @@ function podspecReceiptIdentity(file, appRoot = null) {
|
|
|
66520
66535
|
context = hash.digest("hex");
|
|
66521
66536
|
contexts.set(dependencyRoot, context);
|
|
66522
66537
|
}
|
|
66523
|
-
const environmentHash = (0,
|
|
66538
|
+
const environmentHash = (0, import_node_crypto42.createHash)("sha256").update(context);
|
|
66524
66539
|
for (const name3 of Object.keys(env).filter((name4) => /^(RCT_|USE_|ONE_|HERMES_|EXPO_)/.test(name4)).sort())
|
|
66525
66540
|
environmentHash.update("\0").update(name3).update(env[name3] ?? "");
|
|
66526
66541
|
const installed = reactNative ? void 0 : installedPodspec(app, file, dependencyRoot);
|
|
@@ -66585,7 +66600,7 @@ function loadPodspecs(files2, appRoot = null) {
|
|
|
66585
66600
|
receipts.set(plan.key, plan.receipt);
|
|
66586
66601
|
const file = receiptFile(plan.key, plan.environment);
|
|
66587
66602
|
import_node_fs72.default.mkdirSync(import_node_path72.default.dirname(file), { recursive: true });
|
|
66588
|
-
const temporary = `${file}.${(0,
|
|
66603
|
+
const temporary = `${file}.${(0, import_node_crypto42.randomUUID)()}.tmp`;
|
|
66589
66604
|
import_node_fs72.default.writeFileSync(temporary, JSON.stringify(plan.receipt));
|
|
66590
66605
|
import_node_fs72.default.renameSync(temporary, file);
|
|
66591
66606
|
}
|
|
@@ -66735,11 +66750,11 @@ function podspecSourceFiles(directory2, spec) {
|
|
|
66735
66750
|
);
|
|
66736
66751
|
return matched;
|
|
66737
66752
|
}
|
|
66738
|
-
var
|
|
66753
|
+
var import_node_crypto42, import_node_fs72, import_node_path72, import_zod, UnsupportedPodspec, pathsSchema, attributesSchema, evaluatedSpecSchema, podspecReceiptSchema, receipts, restoredReceipts, appReceipts, inputKeys, packageContexts, installedSpecs, Spec, podspecName, podspecSwiftVersion, c99, podspecLinksBinaries, podspecSourcePatterns, trees, SOURCE_EXTENSIONS2;
|
|
66739
66754
|
var init_podspec_sources = __esm({
|
|
66740
66755
|
"src/podspec-sources.ts"() {
|
|
66741
66756
|
"use strict";
|
|
66742
|
-
|
|
66757
|
+
import_node_crypto42 = require("node:crypto");
|
|
66743
66758
|
import_node_fs72 = __toESM(require("node:fs"), 1);
|
|
66744
66759
|
import_node_path72 = __toESM(require("node:path"), 1);
|
|
66745
66760
|
import_zod = require("peachsim/vendor/zod");
|
|
@@ -66805,7 +66820,7 @@ var init_podspec_sources = __esm({
|
|
|
66805
66820
|
function sha256Hex5(bytes) {
|
|
66806
66821
|
if (typeof Bun !== "undefined")
|
|
66807
66822
|
return new Bun.CryptoHasher("sha256").update(bytes).digest("hex");
|
|
66808
|
-
return (0,
|
|
66823
|
+
return (0, import_node_crypto43.createHash)("sha256").update(bytes).digest("hex");
|
|
66809
66824
|
}
|
|
66810
66825
|
function isBazelPackage(input) {
|
|
66811
66826
|
return /^BUILD(?:\.bazel)?$/.test(import_node_path73.default.basename(input)) && import_node_fs73.default.statSync(input).isFile();
|
|
@@ -66836,7 +66851,7 @@ function bazelBinary(root) {
|
|
|
66836
66851
|
const expected = (0, import_node_child_process41.execFileSync)("curl", ["-fsSL", `${url}.sha256`], {
|
|
66837
66852
|
encoding: "utf8"
|
|
66838
66853
|
}).split(/\s/)[0];
|
|
66839
|
-
const actual = (0,
|
|
66854
|
+
const actual = (0, import_node_crypto43.createHash)("sha256").update(import_node_fs73.default.readFileSync(partial)).digest("hex");
|
|
66840
66855
|
if (actual !== expected) {
|
|
66841
66856
|
import_node_fs73.default.rmSync(partial, { force: true });
|
|
66842
66857
|
throw new Error(`${url} digest ${actual} differs from its release ${expected}`);
|
|
@@ -66866,7 +66881,7 @@ function parseRule(raw2) {
|
|
|
66866
66881
|
};
|
|
66867
66882
|
}
|
|
66868
66883
|
function graphInputsDigest(root) {
|
|
66869
|
-
const hash = (0,
|
|
66884
|
+
const hash = (0, import_node_crypto43.createHash)("sha256");
|
|
66870
66885
|
const visit3 = (dir) => {
|
|
66871
66886
|
for (const entry of import_node_fs73.default.readdirSync(dir, { withFileTypes: true }).sort((a, b) => a.name.localeCompare(b.name))) {
|
|
66872
66887
|
if (entry.name.startsWith(".") || entry.name.startsWith("bazel-")) continue;
|
|
@@ -66899,7 +66914,7 @@ function bazelGraph(root, label, configuration) {
|
|
|
66899
66914
|
const cached2 = graphs.get(key2);
|
|
66900
66915
|
if (cached2) return cached2;
|
|
66901
66916
|
const flags = configurationFlags(configuration);
|
|
66902
|
-
const digest3 = (0,
|
|
66917
|
+
const digest3 = (0, import_node_crypto43.createHash)("sha256").update(JSON.stringify([GRAPH_FORMAT, label, flags, QUERIED_RULES])).update(graphInputsDigest(root)).digest("hex").slice(0, 24);
|
|
66903
66918
|
const file = import_node_path73.default.join(root, ".build", "peach-bazel", `graph-${digest3}.json`);
|
|
66904
66919
|
const bazel = bazelBinary(root);
|
|
66905
66920
|
const run16 = (args) => (0, import_node_child_process41.execFileSync)(bazel, args, {
|
|
@@ -67723,12 +67738,12 @@ function shellTokens(options2) {
|
|
|
67723
67738
|
return words2;
|
|
67724
67739
|
});
|
|
67725
67740
|
}
|
|
67726
|
-
var import_node_child_process41,
|
|
67741
|
+
var import_node_child_process41, import_node_crypto43, import_node_fs73, import_node_os18, import_node_path73, LIBRARY_RULES, QUERIED_RULES, NATIVE_SOURCE, HEADER3, PRODUCTS, graphs, CLANG_CONFIGURATION_FLAGS, GRAPH_FORMAT, BazelFiles, CXX_STANDARD;
|
|
67727
67742
|
var init_bazel_project = __esm({
|
|
67728
67743
|
"src/bazel-project.ts"() {
|
|
67729
67744
|
"use strict";
|
|
67730
67745
|
import_node_child_process41 = require("node:child_process");
|
|
67731
|
-
|
|
67746
|
+
import_node_crypto43 = require("node:crypto");
|
|
67732
67747
|
import_node_fs73 = __toESM(require("node:fs"), 1);
|
|
67733
67748
|
import_node_os18 = __toESM(require("node:os"), 1);
|
|
67734
67749
|
import_node_path73 = __toESM(require("node:path"), 1);
|
|
@@ -68189,7 +68204,7 @@ async function swiftBinaryModules(binary2) {
|
|
|
68189
68204
|
if (!binary2.url) return localSwiftBinaryModules(binary2.dir);
|
|
68190
68205
|
const cached2 = import_node_path74.default.join(
|
|
68191
68206
|
cacheDir3,
|
|
68192
|
-
`${(0,
|
|
68207
|
+
`${(0, import_node_crypto44.createHash)("sha256").update(`${binary2.url}\0${binary2.checksum ?? ""}`).digest("hex").slice(0, 32)}.json`
|
|
68193
68208
|
);
|
|
68194
68209
|
if (import_node_fs74.default.existsSync(cached2)) {
|
|
68195
68210
|
const value = JSON.parse(import_node_fs74.default.readFileSync(cached2, "utf8"));
|
|
@@ -68201,11 +68216,11 @@ async function swiftBinaryModules(binary2) {
|
|
|
68201
68216
|
import_node_fs74.default.writeFileSync(cached2, JSON.stringify(modules));
|
|
68202
68217
|
return modules;
|
|
68203
68218
|
}
|
|
68204
|
-
var
|
|
68219
|
+
var import_node_crypto44, import_node_fs74, import_node_path74, cacheDir3;
|
|
68205
68220
|
var init_swift_binary_modules = __esm({
|
|
68206
68221
|
"src/swift-binary-modules.ts"() {
|
|
68207
68222
|
"use strict";
|
|
68208
|
-
|
|
68223
|
+
import_node_crypto44 = require("node:crypto");
|
|
68209
68224
|
import_node_fs74 = __toESM(require("node:fs"), 1);
|
|
68210
68225
|
import_node_path74 = __toESM(require("node:path"), 1);
|
|
68211
68226
|
init_home_paths();
|
|
@@ -68215,11 +68230,11 @@ var init_swift_binary_modules = __esm({
|
|
|
68215
68230
|
});
|
|
68216
68231
|
|
|
68217
68232
|
// src/swift-coverage/provenance.ts
|
|
68218
|
-
var
|
|
68233
|
+
var import_node_crypto45, import_node_fs75, import_node_path75, swiftCoverageProvenance;
|
|
68219
68234
|
var init_provenance = __esm({
|
|
68220
68235
|
"src/swift-coverage/provenance.ts"() {
|
|
68221
68236
|
"use strict";
|
|
68222
|
-
|
|
68237
|
+
import_node_crypto45 = require("node:crypto");
|
|
68223
68238
|
import_node_fs75 = require("node:fs");
|
|
68224
68239
|
import_node_path75 = require("node:path");
|
|
68225
68240
|
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_path75.join)(__sootsim_import_meta_dirname, ".."));
|
|
@@ -69316,16 +69331,16 @@ function assetSymbolText(plan, root) {
|
|
|
69316
69331
|
if (source.status === "unknown") throw new Error(source.reason);
|
|
69317
69332
|
return source.text;
|
|
69318
69333
|
}
|
|
69319
|
-
var
|
|
69334
|
+
var import_node_crypto46, import_node_fs77, import_node_path77, sha2562, unprovenAssetSettings, assetSymbolSettingKeys, provenOtherAssetFlags, symbolTexts;
|
|
69320
69335
|
var init_xcode_assets = __esm({
|
|
69321
69336
|
"src/swift-coverage/xcode-assets.ts"() {
|
|
69322
69337
|
"use strict";
|
|
69323
|
-
|
|
69338
|
+
import_node_crypto46 = require("node:crypto");
|
|
69324
69339
|
import_node_fs77 = require("node:fs");
|
|
69325
69340
|
import_node_path77 = require("node:path");
|
|
69326
69341
|
init_provenance();
|
|
69327
69342
|
init_xcode_asset_symbols();
|
|
69328
|
-
sha2562 = (bytes) => (0,
|
|
69343
|
+
sha2562 = (bytes) => (0, import_node_crypto46.createHash)("sha256").update(bytes).digest("hex");
|
|
69329
69344
|
unprovenAssetSettings = [
|
|
69330
69345
|
"ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOL_FRAMEWORKS",
|
|
69331
69346
|
"ASSETCATALOG_COMPILER_GENERATE_ASSET_SYMBOL_WARNINGS",
|
|
@@ -69921,7 +69936,7 @@ function normalizedEnums(input) {
|
|
|
69921
69936
|
}
|
|
69922
69937
|
function localizationIdentifier(field, key2) {
|
|
69923
69938
|
const alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
|
69924
|
-
const digest3 = (0,
|
|
69939
|
+
const digest3 = (0, import_node_crypto47.createHash)("sha256").update(JSON.stringify([...field, key2])).digest();
|
|
69925
69940
|
return Array.from(
|
|
69926
69941
|
digest3.subarray(0, 6),
|
|
69927
69942
|
(byte) => alphabet[byte % alphabet.length]
|
|
@@ -70246,12 +70261,12 @@ function writeIntentDefinition(input, prefix) {
|
|
|
70246
70261
|
lines.push("</plist>", "");
|
|
70247
70262
|
return lines.join("\n");
|
|
70248
70263
|
}
|
|
70249
|
-
var import_strict4,
|
|
70264
|
+
var import_strict4, import_node_crypto47, typeMetadata, initializeMetadata, widgetArraySizes, defaultReasonMessages;
|
|
70250
70265
|
var init_metadata = __esm({
|
|
70251
70266
|
"src/intent-definition/metadata.ts"() {
|
|
70252
70267
|
"use strict";
|
|
70253
70268
|
import_strict4 = __toESM(require("node:assert/strict"), 1);
|
|
70254
|
-
|
|
70269
|
+
import_node_crypto47 = require("node:crypto");
|
|
70255
70270
|
init_fields();
|
|
70256
70271
|
init_hash_input();
|
|
70257
70272
|
init_siphash();
|
|
@@ -70960,7 +70975,7 @@ function preparePortableIntent(definition2, derivedDirectory, prefix, language,
|
|
|
70960
70975
|
if (prefix) identifier(prefix);
|
|
70961
70976
|
if (module2) identifier(module2);
|
|
70962
70977
|
const source = import_node_fs78.default.readFileSync(definition2);
|
|
70963
|
-
const key2 = (0,
|
|
70978
|
+
const key2 = (0, import_node_crypto48.createHash)("sha256").update(
|
|
70964
70979
|
JSON.stringify([intentCompilerRevision, definition2, prefix, language, module2])
|
|
70965
70980
|
).update("\0").update(source).digest("hex");
|
|
70966
70981
|
const cache = import_node_path78.default.join(derivedDirectory, "IntentDefinitions");
|
|
@@ -71000,11 +71015,11 @@ function preparePortableIntent(definition2, derivedDirectory, prefix, language,
|
|
|
71000
71015
|
import_node_fs78.default.rmSync(stage, { recursive: true, force: true });
|
|
71001
71016
|
}
|
|
71002
71017
|
}
|
|
71003
|
-
var
|
|
71018
|
+
var import_node_crypto48, import_node_fs78, import_node_path78, intentCompilerRevision;
|
|
71004
71019
|
var init_xcode_intents = __esm({
|
|
71005
71020
|
"src/xcode-intents.ts"() {
|
|
71006
71021
|
"use strict";
|
|
71007
|
-
|
|
71022
|
+
import_node_crypto48 = require("node:crypto");
|
|
71008
71023
|
import_node_fs78 = __toESM(require("node:fs"), 1);
|
|
71009
71024
|
import_node_path78 = __toESM(require("node:path"), 1);
|
|
71010
71025
|
init_fields();
|
|
@@ -71706,7 +71721,7 @@ function loadProject(xcodeproj) {
|
|
|
71706
71721
|
if (!projectFile)
|
|
71707
71722
|
throw new Error(`${xcodeproj} has no project.pbxproj or project.xcproj`);
|
|
71708
71723
|
const source = import_node_fs79.default.readFileSync(projectFile, "utf8");
|
|
71709
|
-
const digest3 = (0,
|
|
71724
|
+
const digest3 = (0, import_node_crypto49.createHash)("sha256").update(source).digest("hex");
|
|
71710
71725
|
const cached2 = loaded3.get(projectFile);
|
|
71711
71726
|
if (cached2?.digest === digest3) return cached2.project;
|
|
71712
71727
|
const root = projectFile.endsWith(".xcproj") ? readXcodeJsonProject(xcodeproj, source) : parseOpenStepPlist(source);
|
|
@@ -71758,7 +71773,7 @@ function xcodeInstallationIdentity() {
|
|
|
71758
71773
|
if (!selected) return null;
|
|
71759
71774
|
const directory2 = import_node_path80.default.extname(selected) === ".app" ? import_node_path80.default.join(selected, "Contents", "Developer") : selected;
|
|
71760
71775
|
const versionFile = `${directory2}/../version.plist`;
|
|
71761
|
-
const version2 = import_node_fs79.default.existsSync(versionFile) ? (0,
|
|
71776
|
+
const version2 = import_node_fs79.default.existsSync(versionFile) ? (0, import_node_crypto49.createHash)("sha256").update(import_node_fs79.default.readFileSync(versionFile)).digest("hex") : null;
|
|
71762
71777
|
return { directory: directory2, version: version2 };
|
|
71763
71778
|
}
|
|
71764
71779
|
function defaultConfiguration(project2) {
|
|
@@ -72226,7 +72241,7 @@ function targetMembers(ref, settings, options2, settingKeys, projectInputs) {
|
|
|
72226
72241
|
);
|
|
72227
72242
|
});
|
|
72228
72243
|
}
|
|
72229
|
-
const signature2 = (0,
|
|
72244
|
+
const signature2 = (0, import_node_crypto49.createHash)("sha256").update(
|
|
72230
72245
|
JSON.stringify([phase, [...settingKeys].map((key3) => [key3, settings(key3)])])
|
|
72231
72246
|
);
|
|
72232
72247
|
for (const file of inputFiles) {
|
|
@@ -72381,7 +72396,7 @@ ${output}`
|
|
|
72381
72396
|
const inputs2 = JSON.stringify([
|
|
72382
72397
|
1,
|
|
72383
72398
|
args,
|
|
72384
|
-
(0,
|
|
72399
|
+
(0, import_node_crypto49.createHash)("sha256").update(import_node_fs79.default.readFileSync(file)).digest("hex")
|
|
72385
72400
|
]);
|
|
72386
72401
|
const developer = settings("DEVELOPER_DIR");
|
|
72387
72402
|
const cached2 = import_node_fs79.default.existsSync(output) && import_node_fs79.default.existsSync(stamp) ? import_node_fs79.default.readFileSync(stamp, "utf8").split("\n") : [];
|
|
@@ -73844,12 +73859,12 @@ function readXcodeAppTarget(input, targetName, configurationName, options2 = {})
|
|
|
73844
73859
|
cocoapods
|
|
73845
73860
|
};
|
|
73846
73861
|
}
|
|
73847
|
-
var import_node_child_process42,
|
|
73862
|
+
var import_node_child_process42, import_node_crypto49, import_node_fs79, import_node_module5, import_node_path80, 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;
|
|
73848
73863
|
var init_xcode_project = __esm({
|
|
73849
73864
|
"src/xcode-project.ts"() {
|
|
73850
73865
|
"use strict";
|
|
73851
73866
|
import_node_child_process42 = require("node:child_process");
|
|
73852
|
-
|
|
73867
|
+
import_node_crypto49 = require("node:crypto");
|
|
73853
73868
|
import_node_fs79 = __toESM(require("node:fs"), 1);
|
|
73854
73869
|
import_node_module5 = require("node:module");
|
|
73855
73870
|
import_node_path80 = __toESM(require("node:path"), 1);
|
|
@@ -74041,8 +74056,8 @@ async function walkWorkspaceInputs(app, everyByte, sourceOnly, podsEnvironment)
|
|
|
74041
74056
|
);
|
|
74042
74057
|
const appRelative = import_node_path81.default.relative(root, app);
|
|
74043
74058
|
const manifest = JSON.parse(import_node_fs80.default.readFileSync(import_node_path81.default.join(root, "package.json"), "utf8"));
|
|
74044
|
-
const hash = (0,
|
|
74045
|
-
const native = (0,
|
|
74059
|
+
const hash = (0, import_node_crypto50.createHash)("sha256");
|
|
74060
|
+
const native = (0, import_node_crypto50.createHash)("sha256");
|
|
74046
74061
|
const nativeDirectories = localPackageDirectories(root, app);
|
|
74047
74062
|
const versionFree = new Set(
|
|
74048
74063
|
nativeDirectories.filter((directory2) => directory2 !== appRelative && directory2 !== "").filter(
|
|
@@ -74126,7 +74141,7 @@ async function walkWorkspaceInputs(app, everyByte, sourceOnly, podsEnvironment)
|
|
|
74126
74141
|
unread.slice(start, start + 32).map(async ({ file, content }) => {
|
|
74127
74142
|
const bytes = await import_node_fs80.default.promises.readFile(file);
|
|
74128
74143
|
content.size = bytes.length;
|
|
74129
|
-
content.digest = (0,
|
|
74144
|
+
content.digest = (0, import_node_crypto50.createHash)("sha256").update(bytes).digest("hex");
|
|
74130
74145
|
fileDigests.set(file, content);
|
|
74131
74146
|
})
|
|
74132
74147
|
);
|
|
@@ -74676,7 +74691,7 @@ function stageCachedQuickCryptoOpenSsl(app) {
|
|
|
74676
74691
|
const sha2565 = /openssl_sha256\s*=\s*"([0-9a-f]{64})"/.exec(podspec)?.[1];
|
|
74677
74692
|
if (!sha2565) return;
|
|
74678
74693
|
const archive = import_node_path81.default.join(cacheDir(), "pod-archives", `${sha2565}.zip`);
|
|
74679
|
-
if (!import_node_fs80.default.existsSync(archive) || (0,
|
|
74694
|
+
if (!import_node_fs80.default.existsSync(archive) || (0, import_node_crypto50.createHash)("sha256").update(import_node_fs80.default.readFileSync(archive)).digest("hex") !== sha2565)
|
|
74680
74695
|
return;
|
|
74681
74696
|
import_node_fs80.default.rmSync(opensslDir, { recursive: true, force: true });
|
|
74682
74697
|
import_node_fs80.default.mkdirSync(opensslDir, { recursive: true });
|
|
@@ -74714,12 +74729,12 @@ ${failedOutputLine(command, cwd, bytes)}`
|
|
|
74714
74729
|
});
|
|
74715
74730
|
});
|
|
74716
74731
|
}
|
|
74717
|
-
var import_node_child_process43,
|
|
74732
|
+
var import_node_child_process43, import_node_crypto50, import_node_fs80, import_node_module6, import_node_os19, import_node_path81, import_node_util11, isolatedGitEnv, NATIVE_CONFIG_FILE, NATIVE_SOURCE_FILE, fileDigests, NATIVE_PACKAGE_ENTRY, hashing, KEPT_WORKSPACES, WORKSPACE_GRACE_MS, ABANDONED_WORKSPACE_MS, RETIRED_PREFIX2, preparing, watches, current, CLONE_ENTRIES;
|
|
74718
74733
|
var init_expo_native_workspace = __esm({
|
|
74719
74734
|
"src/expo-native-workspace.ts"() {
|
|
74720
74735
|
"use strict";
|
|
74721
74736
|
import_node_child_process43 = require("node:child_process");
|
|
74722
|
-
|
|
74737
|
+
import_node_crypto50 = require("node:crypto");
|
|
74723
74738
|
import_node_fs80 = __toESM(require("node:fs"), 1);
|
|
74724
74739
|
import_node_module6 = require("node:module");
|
|
74725
74740
|
import_node_os19 = __toESM(require("node:os"), 1);
|
|
@@ -75134,7 +75149,7 @@ function kotlinHome() {
|
|
|
75134
75149
|
}
|
|
75135
75150
|
async function fetchVerified(download2, target) {
|
|
75136
75151
|
if (import_node_fs82.default.existsSync(target)) {
|
|
75137
|
-
if ((0,
|
|
75152
|
+
if ((0, import_node_crypto51.createHash)("sha256").update(import_node_fs82.default.readFileSync(target)).digest("hex") !== download2.sha256)
|
|
75138
75153
|
throw new Error(
|
|
75139
75154
|
`cached Kotlin download differs from its pin: ${import_node_path83.default.basename(target)}`
|
|
75140
75155
|
);
|
|
@@ -75143,7 +75158,7 @@ async function fetchVerified(download2, target) {
|
|
|
75143
75158
|
const response = await fetch(download2.url);
|
|
75144
75159
|
if (!response.ok) throw new Error(`${download2.url} answered ${response.status}`);
|
|
75145
75160
|
const bytes = Buffer.from(await response.arrayBuffer());
|
|
75146
|
-
const digest3 = (0,
|
|
75161
|
+
const digest3 = (0, import_node_crypto51.createHash)("sha256").update(bytes).digest("hex");
|
|
75147
75162
|
if (digest3 !== download2.sha256)
|
|
75148
75163
|
throw new Error(`${download2.url} has sha256 ${digest3}, expected ${download2.sha256}`);
|
|
75149
75164
|
import_node_fs82.default.mkdirSync(import_node_path83.default.dirname(target), { recursive: true });
|
|
@@ -75156,7 +75171,7 @@ async function ensureCompose(toolchain) {
|
|
|
75156
75171
|
const root = import_node_path83.default.join(kotlinHome(), "compose", toolchain.composeArchive.sha256);
|
|
75157
75172
|
const verify = (dir) => {
|
|
75158
75173
|
for (const { name: name3, sha256: sha2565 } of downloads) {
|
|
75159
|
-
const actual = (0,
|
|
75174
|
+
const actual = (0, import_node_crypto51.createHash)("sha256").update(import_node_fs82.default.readFileSync(import_node_path83.default.join(dir, name3))).digest("hex");
|
|
75160
75175
|
if (actual !== sha2565)
|
|
75161
75176
|
throw new Error(`Compose input differs from its pin: ${name3}`);
|
|
75162
75177
|
}
|
|
@@ -75227,12 +75242,12 @@ function ensureToolchain(toolchain) {
|
|
|
75227
75242
|
toolchains.set(key2, ready);
|
|
75228
75243
|
return ready;
|
|
75229
75244
|
}
|
|
75230
|
-
var import_node_child_process44,
|
|
75245
|
+
var import_node_child_process44, import_node_crypto51, import_node_fs82, import_node_path83, import_node_util12, run6, toolchains;
|
|
75231
75246
|
var init_kotlin_toolchain = __esm({
|
|
75232
75247
|
"src/kotlin-toolchain.ts"() {
|
|
75233
75248
|
"use strict";
|
|
75234
75249
|
import_node_child_process44 = require("node:child_process");
|
|
75235
|
-
|
|
75250
|
+
import_node_crypto51 = require("node:crypto");
|
|
75236
75251
|
import_node_fs82 = __toESM(require("node:fs"), 1);
|
|
75237
75252
|
import_node_path83 = __toESM(require("node:path"), 1);
|
|
75238
75253
|
import_node_util12 = require("node:util");
|
|
@@ -75566,7 +75581,7 @@ async function prepareNitroDependencies(reactNativeVersion, reactNativeRoot) {
|
|
|
75566
75581
|
throw new Error(`${dependency.name} archive holds a symlink: ${name3}`);
|
|
75567
75582
|
if (entry.isDirectory()) walk4(name3);
|
|
75568
75583
|
else if (entry.isFile() && (dependency.files ?? HEADER4).test(entry.name))
|
|
75569
|
-
files2[name3] = (0,
|
|
75584
|
+
files2[name3] = (0, import_node_crypto52.createHash)("sha256").update(import_node_fs84.default.readFileSync(import_node_path85.default.join(tree2, name3))).digest("hex");
|
|
75570
75585
|
}
|
|
75571
75586
|
};
|
|
75572
75587
|
for (const sourceRoot of dependency.sourceDirectories ?? [dependency.headers.from])
|
|
@@ -75616,7 +75631,7 @@ function nitroDependencyReader(reactNativeVersion, reactNativeRoot) {
|
|
|
75616
75631
|
const tree2 = import_node_path85.default.join(directory(dependency), "tree");
|
|
75617
75632
|
const source = import_node_path85.default.join(tree2, relative4);
|
|
75618
75633
|
const bytes = readPackageFile(tree2, source, MAX_SWIFT_COMPILE_SOURCE_BYTES);
|
|
75619
|
-
const original = (0,
|
|
75634
|
+
const original = (0, import_node_crypto52.createHash)("sha256").update(bytes).digest("hex");
|
|
75620
75635
|
if (original !== digest3)
|
|
75621
75636
|
throw new Error(
|
|
75622
75637
|
`${dependency.name} header differs from its verified archive: ${relative4}`
|
|
@@ -75632,7 +75647,7 @@ function nitroDependencyReader(reactNativeVersion, reactNativeRoot) {
|
|
|
75632
75647
|
if (!text7.includes(backport.before))
|
|
75633
75648
|
throw new Error(`${dependency.name} backport anchor missing: ${relative4}`);
|
|
75634
75649
|
text7 = text7.replace(backport.before, backport.after);
|
|
75635
|
-
sha2565 = (0,
|
|
75650
|
+
sha2565 = (0, import_node_crypto52.createHash)("sha256").update(text7).digest("hex");
|
|
75636
75651
|
if (sha2565 !== backport.derivedSha256)
|
|
75637
75652
|
throw new Error(`${dependency.name} backport derived source differs: ${relative4}`);
|
|
75638
75653
|
}
|
|
@@ -75673,7 +75688,7 @@ function nitroDependencySources(reactNativeVersion, reactNativeRoot, select) {
|
|
|
75673
75688
|
if (!select(dependency.name, prepared)) continue;
|
|
75674
75689
|
const source = import_node_path85.default.join(tree2, relative4);
|
|
75675
75690
|
const bytes = readPackageFile(tree2, source, MAX_SWIFT_COMPILE_SOURCE_BYTES);
|
|
75676
|
-
if ((0,
|
|
75691
|
+
if ((0, import_node_crypto52.createHash)("sha256").update(bytes).digest("hex") !== digest3)
|
|
75677
75692
|
throw new Error(
|
|
75678
75693
|
`${dependency.name} source differs from its verified archive: ${relative4}`
|
|
75679
75694
|
);
|
|
@@ -75702,7 +75717,7 @@ function glogSources() {
|
|
|
75702
75717
|
if (!digest3) throw new Error(`glog ${GLOG.prefix} has no ${relative4}`);
|
|
75703
75718
|
const source = import_node_path85.default.join(tree2, relative4);
|
|
75704
75719
|
const bytes = readPackageFile(tree2, source, MAX_SWIFT_COMPILE_SOURCE_BYTES);
|
|
75705
|
-
if ((0,
|
|
75720
|
+
if ((0, import_node_crypto52.createHash)("sha256").update(bytes).digest("hex") !== digest3)
|
|
75706
75721
|
throw new Error(`glog source differs from its verified archive: ${relative4}`);
|
|
75707
75722
|
return { relative: relative4, source, text: bytes.toString("utf8"), sha256: digest3 };
|
|
75708
75723
|
};
|
|
@@ -75712,7 +75727,7 @@ function glogSources() {
|
|
|
75712
75727
|
relative: output,
|
|
75713
75728
|
source: original.source,
|
|
75714
75729
|
text: text7,
|
|
75715
|
-
sha256: (0,
|
|
75730
|
+
sha256: (0, import_node_crypto52.createHash)("sha256").update(text7).digest("hex"),
|
|
75716
75731
|
configured: { template, originalSha256: original.sha256 }
|
|
75717
75732
|
};
|
|
75718
75733
|
};
|
|
@@ -75740,12 +75755,12 @@ function glogSources() {
|
|
|
75740
75755
|
for (const unit2 of GLOG_UNITS) sources.push(read(unit2));
|
|
75741
75756
|
return sources;
|
|
75742
75757
|
}
|
|
75743
|
-
var import_node_child_process45,
|
|
75758
|
+
var import_node_child_process45, import_node_crypto52, import_node_fs84, import_node_path85, import_node_util13, run7, DOUBLE_CONVERSION_WASM64_BACKPORT2, RN_SHARED_DEPENDENCIES, RN_FMT_11_DEPENDENCIES, RN_FAST_FLOAT_6_DEPENDENCIES, RN_FMT_12_DEPENDENCIES, HEADER4, GLOG, GLOG_SUBSTITUTIONS, GLOG_CONFIGURE, GLOG_CONFIG_APPENDIX, GLOG_UNITS;
|
|
75744
75759
|
var init_nitro_dependencies = __esm({
|
|
75745
75760
|
"src/nitro-dependencies.ts"() {
|
|
75746
75761
|
"use strict";
|
|
75747
75762
|
import_node_child_process45 = require("node:child_process");
|
|
75748
|
-
|
|
75763
|
+
import_node_crypto52 = require("node:crypto");
|
|
75749
75764
|
import_node_fs84 = __toESM(require("node:fs"), 1);
|
|
75750
75765
|
import_node_path85 = __toESM(require("node:path"), 1);
|
|
75751
75766
|
import_node_util13 = require("node:util");
|
|
@@ -76698,7 +76713,7 @@ function collectNitroSources(options2, nativeSourceKeys, sourceRoot) {
|
|
|
76698
76713
|
result.sources.push({
|
|
76699
76714
|
file: original,
|
|
76700
76715
|
source,
|
|
76701
|
-
sha256: (0,
|
|
76716
|
+
sha256: (0, import_node_crypto53.createHash)("sha256").update(bytes).digest("hex")
|
|
76702
76717
|
});
|
|
76703
76718
|
}
|
|
76704
76719
|
const requested = `${targetPath(name3)}/upstream/${sourceRelative}`;
|
|
@@ -76888,7 +76903,7 @@ function collectNitroSources(options2, nativeSourceKeys, sourceRoot) {
|
|
|
76888
76903
|
result.sources.push({
|
|
76889
76904
|
file: mapKey,
|
|
76890
76905
|
source: import_node_fs86.default.realpathSync(modulemapPath),
|
|
76891
|
-
sha256: (0,
|
|
76906
|
+
sha256: (0, import_node_crypto53.createHash)("sha256").update(modulemapBytes).digest("hex")
|
|
76892
76907
|
});
|
|
76893
76908
|
registered.push(clangModule);
|
|
76894
76909
|
}
|
|
@@ -76950,7 +76965,7 @@ function collectNitroSources(options2, nativeSourceKeys, sourceRoot) {
|
|
|
76950
76965
|
result.sources.push({
|
|
76951
76966
|
file: key2,
|
|
76952
76967
|
source: real,
|
|
76953
|
-
sha256: (0,
|
|
76968
|
+
sha256: (0, import_node_crypto53.createHash)("sha256").update(bytes).digest("hex")
|
|
76954
76969
|
});
|
|
76955
76970
|
if (/\.(?:c|cc|cpp|cxx|m|mm|swift)$/.test(canonicalRel)) {
|
|
76956
76971
|
excludes.add(`upstream/${canonicalRel}`);
|
|
@@ -77303,11 +77318,11 @@ extern "C" void ${registration.symbol}();
|
|
|
77303
77318
|
}
|
|
77304
77319
|
return result;
|
|
77305
77320
|
}
|
|
77306
|
-
var
|
|
77321
|
+
var import_node_crypto53, import_node_fs86, import_node_module8, import_node_path87, import_zod2, nitroProviderTarget, NITRO_VIEWS_TARGET, PEER_PODSPEC_SKIP;
|
|
77307
77322
|
var init_nitro_source = __esm({
|
|
77308
77323
|
"src/nitro-source.ts"() {
|
|
77309
77324
|
"use strict";
|
|
77310
|
-
|
|
77325
|
+
import_node_crypto53 = require("node:crypto");
|
|
77311
77326
|
import_node_fs86 = __toESM(require("node:fs"), 1);
|
|
77312
77327
|
import_node_module8 = require("node:module");
|
|
77313
77328
|
import_node_path87 = __toESM(require("node:path"), 1);
|
|
@@ -77317,7 +77332,7 @@ var init_nitro_source = __esm({
|
|
|
77317
77332
|
init_react_native_autolinking();
|
|
77318
77333
|
init_swift_source_file();
|
|
77319
77334
|
init_swift_submit();
|
|
77320
|
-
nitroProviderTarget = (provider) => `NitroPackage_${(0,
|
|
77335
|
+
nitroProviderTarget = (provider) => `NitroPackage_${(0, import_node_crypto53.createHash)("sha256").update(provider.name).digest("hex").slice(0, 16)}`;
|
|
77321
77336
|
NITRO_VIEWS_TARGET = "PeachNitroViews";
|
|
77322
77337
|
PEER_PODSPEC_SKIP = /* @__PURE__ */ new Set([
|
|
77323
77338
|
"React-jsi",
|
|
@@ -79498,7 +79513,7 @@ async function loadStoreKitTestStore(configuration, appDir) {
|
|
|
79498
79513
|
const identityPath = import_node_path89.default.join(
|
|
79499
79514
|
cacheDir(),
|
|
79500
79515
|
"storekit-identities",
|
|
79501
|
-
`${(0,
|
|
79516
|
+
`${(0, import_node_crypto54.createHash)("sha256").update(import_node_path89.default.resolve(appDir)).digest("hex")}.json`
|
|
79502
79517
|
);
|
|
79503
79518
|
let signing;
|
|
79504
79519
|
try {
|
|
@@ -79514,7 +79529,7 @@ async function loadStoreKitTestStore(configuration, appDir) {
|
|
|
79514
79529
|
const certificate = await import_x509.X509CertificateGenerator.createSelfSigned(
|
|
79515
79530
|
{
|
|
79516
79531
|
name: "CN=StoreKit Testing in Xcode, O=StoreKit Testing in Xcode",
|
|
79517
|
-
serialNumber: (0,
|
|
79532
|
+
serialNumber: (0, import_node_crypto54.randomBytes)(16).toString("hex"),
|
|
79518
79533
|
notBefore: new Date(Date.now() - 6e4),
|
|
79519
79534
|
notAfter: new Date(Date.now() + 365 * 864e5),
|
|
79520
79535
|
signingAlgorithm: algorithm,
|
|
@@ -79531,11 +79546,11 @@ async function loadStoreKitTestStore(configuration, appDir) {
|
|
|
79531
79546
|
}
|
|
79532
79547
|
return { ...catalog, signing };
|
|
79533
79548
|
}
|
|
79534
|
-
var
|
|
79549
|
+
var import_node_crypto54, import_promises7, import_node_path89, import_x509;
|
|
79535
79550
|
var init_storekit_test_store = __esm({
|
|
79536
79551
|
"src/storekit-test-store.ts"() {
|
|
79537
79552
|
"use strict";
|
|
79538
|
-
|
|
79553
|
+
import_node_crypto54 = require("node:crypto");
|
|
79539
79554
|
import_promises7 = require("node:fs/promises");
|
|
79540
79555
|
import_node_path89 = __toESM(require("node:path"), 1);
|
|
79541
79556
|
init_storeKitContract();
|
|
@@ -79880,7 +79895,7 @@ function watchNativeInputs(root) {
|
|
|
79880
79895
|
(0, import_node_timers.clearTimeout)(expiry);
|
|
79881
79896
|
for (const watcher of watchers) watcher.close();
|
|
79882
79897
|
}
|
|
79883
|
-
const inputs2 = { expiry, revision: (0,
|
|
79898
|
+
const inputs2 = { expiry, revision: (0, import_node_crypto55.randomUUID)() };
|
|
79884
79899
|
const watch = (directory2, recursive, name3) => {
|
|
79885
79900
|
const watcher = import_node_fs90.default.watch(
|
|
79886
79901
|
directory2,
|
|
@@ -79921,11 +79936,11 @@ function watchNativeInputs(root) {
|
|
|
79921
79936
|
watchedInputs.set(workspace, inputs2);
|
|
79922
79937
|
return inputs2;
|
|
79923
79938
|
}
|
|
79924
|
-
var
|
|
79939
|
+
var import_node_crypto55, import_node_fs90, import_node_path92, import_node_timers, setTimeoutNode, RETENTION_MS, watchedInputs, NativePreparation;
|
|
79925
79940
|
var init_native_preparation = __esm({
|
|
79926
79941
|
"src/native-preparation.ts"() {
|
|
79927
79942
|
"use strict";
|
|
79928
|
-
|
|
79943
|
+
import_node_crypto55 = require("node:crypto");
|
|
79929
79944
|
import_node_fs90 = __toESM(require("node:fs"), 1);
|
|
79930
79945
|
import_node_path92 = __toESM(require("node:path"), 1);
|
|
79931
79946
|
import_node_timers = require("node:timers");
|
|
@@ -80136,7 +80151,7 @@ function nativeStaticLibraryEntry(recipe2, compiler, sdk2, distribution) {
|
|
|
80136
80151
|
return { name: recipe2.name, inputs: inputs2, key: nativeEntryKey(inputs2) };
|
|
80137
80152
|
}
|
|
80138
80153
|
function nativeStaticLibraryRecipe(bytes) {
|
|
80139
|
-
const digest3 = (0,
|
|
80154
|
+
const digest3 = (0, import_node_crypto56.createHash)("sha256").update(bytes).digest("hex");
|
|
80140
80155
|
return NATIVE_STATIC_LIBRARY_RECIPES.find((item) => item.nativeSha256 === digest3);
|
|
80141
80156
|
}
|
|
80142
80157
|
function nativeStaticLibrary(file, recipe2, moduleRoot) {
|
|
@@ -80179,7 +80194,7 @@ function isRustSymbol(name3, demangled) {
|
|
|
80179
80194
|
function rustStaticLibrary(file, moduleRoot) {
|
|
80180
80195
|
const toolchain = swiftModuleToolchain(moduleRoot);
|
|
80181
80196
|
const bytes = import_node_fs92.default.readFileSync(file);
|
|
80182
|
-
const key2 = (0,
|
|
80197
|
+
const key2 = (0, import_node_crypto56.createHash)("sha256").update("rust-c-abi-v4\0").update(toolchain.release).update("\0").update(bytes).digest("hex");
|
|
80183
80198
|
const directory2 = import_node_path94.default.join(cacheDir(), "native-archives", key2);
|
|
80184
80199
|
const archive = import_node_path94.default.join(directory2, "library.a");
|
|
80185
80200
|
if (import_node_fs92.default.existsSync(archive)) return archive;
|
|
@@ -80208,7 +80223,7 @@ function rustStaticLibrary(file, moduleRoot) {
|
|
|
80208
80223
|
const members2 = readArMembers(bytes, true);
|
|
80209
80224
|
const seen = /* @__PURE__ */ new Set();
|
|
80210
80225
|
const unique2 = members2.filter(({ name: name3, bytes: bytes2 }) => {
|
|
80211
|
-
const identity2 = name3 + "\0" + (0,
|
|
80226
|
+
const identity2 = name3 + "\0" + (0, import_node_crypto56.createHash)("sha256").update(bytes2).digest("hex");
|
|
80212
80227
|
if (seen.has(identity2)) return false;
|
|
80213
80228
|
seen.add(identity2);
|
|
80214
80229
|
return true;
|
|
@@ -80255,14 +80270,14 @@ function rustStaticLibrary(file, moduleRoot) {
|
|
|
80255
80270
|
function combineNativeStaticLibraries(files2, moduleRoot) {
|
|
80256
80271
|
if (files2.length === 1) return files2[0];
|
|
80257
80272
|
const toolchain = swiftModuleToolchain(moduleRoot);
|
|
80258
|
-
const hash = (0,
|
|
80273
|
+
const hash = (0, import_node_crypto56.createHash)("sha256").update(toolchain.release);
|
|
80259
80274
|
for (const file of files2)
|
|
80260
80275
|
hash.update("\0").update(import_node_path94.default.basename(file)).update("\0").update(import_node_fs92.default.readFileSync(file));
|
|
80261
80276
|
const directory2 = import_node_path94.default.join(cacheDir(), "native-archives", hash.digest("hex"));
|
|
80262
80277
|
const archive = import_node_path94.default.join(directory2, "combined.a");
|
|
80263
80278
|
if (import_node_fs92.default.existsSync(archive)) return archive;
|
|
80264
80279
|
import_node_fs92.default.mkdirSync(directory2, { recursive: true });
|
|
80265
|
-
const temporary = import_node_path94.default.join(directory2, `combined-${(0,
|
|
80280
|
+
const temporary = import_node_path94.default.join(directory2, `combined-${(0, import_node_crypto56.randomUUID)()}.a`);
|
|
80266
80281
|
try {
|
|
80267
80282
|
(0, import_node_child_process47.execFileSync)(import_node_path94.default.join(toolchain.toolchainBin, "llvm-ar"), [
|
|
80268
80283
|
"qcsDL",
|
|
@@ -80275,12 +80290,12 @@ function combineNativeStaticLibraries(files2, moduleRoot) {
|
|
|
80275
80290
|
}
|
|
80276
80291
|
return archive;
|
|
80277
80292
|
}
|
|
80278
|
-
var import_node_child_process47,
|
|
80293
|
+
var import_node_child_process47, import_node_crypto56, import_node_fs92, import_node_path94, WEBRTC_NATIVE_FRAMEWORK, SIGNAL_WEBRTC_NATIVE_FRAMEWORK, WEBRTC_NATIVE_FRAMEWORK_RECIPES, NATIVE_STATIC_LIBRARY_RECIPES;
|
|
80279
80294
|
var init_native_static_libraries = __esm({
|
|
80280
80295
|
"src/native-static-libraries.ts"() {
|
|
80281
80296
|
"use strict";
|
|
80282
80297
|
import_node_child_process47 = require("node:child_process");
|
|
80283
|
-
|
|
80298
|
+
import_node_crypto56 = require("node:crypto");
|
|
80284
80299
|
import_node_fs92 = __toESM(require("node:fs"), 1);
|
|
80285
80300
|
import_node_path94 = __toESM(require("node:path"), 1);
|
|
80286
80301
|
init_home_paths();
|
|
@@ -80994,11 +81009,11 @@ var init_nitro_adapter = __esm({
|
|
|
80994
81009
|
});
|
|
80995
81010
|
|
|
80996
81011
|
// src/react-native-core-digest.ts
|
|
80997
|
-
var
|
|
81012
|
+
var import_node_crypto57, import_node_fs95, import_node_path97;
|
|
80998
81013
|
var init_react_native_core_digest = __esm({
|
|
80999
81014
|
"src/react-native-core-digest.ts"() {
|
|
81000
81015
|
"use strict";
|
|
81001
|
-
|
|
81016
|
+
import_node_crypto57 = require("node:crypto");
|
|
81002
81017
|
import_node_fs95 = __toESM(require("node:fs"), 1);
|
|
81003
81018
|
import_node_path97 = __toESM(require("node:path"), 1);
|
|
81004
81019
|
}
|
|
@@ -84410,11 +84425,11 @@ function coreDataModelDirectories(files2) {
|
|
|
84410
84425
|
}
|
|
84411
84426
|
return [...models].sort();
|
|
84412
84427
|
}
|
|
84413
|
-
var
|
|
84428
|
+
var import_node_crypto58, import_node_fs97, import_node_path99, attributeTypes, deleteRules, EXTERNAL_BINARY, PRESERVE_AFTER_DELETION, yes, common, uid, NULL, classChains, KeyedArchive, sha2563;
|
|
84414
84429
|
var init_core_data_model = __esm({
|
|
84415
84430
|
"src/core-data-model.ts"() {
|
|
84416
84431
|
"use strict";
|
|
84417
|
-
|
|
84432
|
+
import_node_crypto58 = require("node:crypto");
|
|
84418
84433
|
import_node_fs97 = require("node:fs");
|
|
84419
84434
|
import_node_path99 = __toESM(require("node:path"), 1);
|
|
84420
84435
|
init_core_data_entity_classes();
|
|
@@ -84533,7 +84548,7 @@ var init_core_data_model = __esm({
|
|
|
84533
84548
|
});
|
|
84534
84549
|
}
|
|
84535
84550
|
};
|
|
84536
|
-
sha2563 = (...parts) => (0,
|
|
84551
|
+
sha2563 = (...parts) => (0, import_node_crypto58.createHash)("sha256").update(
|
|
84537
84552
|
Buffer.concat(
|
|
84538
84553
|
parts.map(
|
|
84539
84554
|
(part) => Array.isArray(part) ? Buffer.from(part) : Buffer.from(part)
|
|
@@ -86796,7 +86811,7 @@ function sourceClosureFiles(srcDir, entrypoints, excludedFiles = []) {
|
|
|
86796
86811
|
return files2.sort();
|
|
86797
86812
|
}
|
|
86798
86813
|
function sourceClosureDigest(srcDir, entrypoints, excludedFiles) {
|
|
86799
|
-
const hash = (0,
|
|
86814
|
+
const hash = (0, import_node_crypto59.createHash)("sha256");
|
|
86800
86815
|
for (const file of sourceClosureFiles(srcDir, entrypoints, excludedFiles)) {
|
|
86801
86816
|
const key2 = import_node_path100.default.relative(srcDir, file);
|
|
86802
86817
|
const bytes = (0, import_node_fs98.readFileSync)(file);
|
|
@@ -86804,11 +86819,11 @@ function sourceClosureDigest(srcDir, entrypoints, excludedFiles) {
|
|
|
86804
86819
|
}
|
|
86805
86820
|
return hash.digest("hex");
|
|
86806
86821
|
}
|
|
86807
|
-
var
|
|
86822
|
+
var import_node_crypto59, import_node_fs98, import_node_path100, STANDIN_DIGEST_ENTRYPOINTS, STANDIN_DIGEST_EXCLUDED_FILES, RUNTIME_IMPORT, standinSourceDigest, STANDIN_SOURCE_DIGEST;
|
|
86808
86823
|
var init_swift_standin_digest = __esm({
|
|
86809
86824
|
"src/swift-standin-digest.ts"() {
|
|
86810
86825
|
"use strict";
|
|
86811
|
-
|
|
86826
|
+
import_node_crypto59 = require("node:crypto");
|
|
86812
86827
|
import_node_fs98 = require("node:fs");
|
|
86813
86828
|
import_node_path100 = __toESM(require("node:path"), 1);
|
|
86814
86829
|
STANDIN_DIGEST_ENTRYPOINTS = ["swift-standins.ts", "swift-objc-compile.ts"];
|
|
@@ -86819,7 +86834,7 @@ var init_swift_standin_digest = __esm({
|
|
|
86819
86834
|
];
|
|
86820
86835
|
RUNTIME_IMPORT = /(?:^|[;\n])[ \t]*(?:import|export)\s+(?!type(?:\s|\{))([\s\S]*?)\s+from\s*['"]([^'"]+)['"]|(?:^|[;\n])[ \t]*import\s+['"]([^'"]+)['"]|import\s*\(\s*['"]([^'"]+)['"]\s*\)/g;
|
|
86821
86836
|
standinSourceDigest = (srcDir = __sootsim_import_meta_dirname) => sourceClosureDigest(srcDir, STANDIN_DIGEST_ENTRYPOINTS, STANDIN_DIGEST_EXCLUDED_FILES);
|
|
86822
|
-
STANDIN_SOURCE_DIGEST = true ? "
|
|
86837
|
+
STANDIN_SOURCE_DIGEST = true ? "c87e0b7f1ae69b2a4e76611266612d6218f81a3244e592800c02f78c4f8e48f6" : standinSourceDigest();
|
|
86823
86838
|
}
|
|
86824
86839
|
});
|
|
86825
86840
|
|
|
@@ -87131,13 +87146,13 @@ var init_swift_wasm64_wamr = __esm({
|
|
|
87131
87146
|
|
|
87132
87147
|
// src/swift-wasm64-native-source.ts
|
|
87133
87148
|
function deriveSource(file, bytes, backport) {
|
|
87134
|
-
if (!backport || (0,
|
|
87149
|
+
if (!backport || (0, import_node_crypto60.createHash)("sha256").update(bytes).digest("hex") !== backport.originalSha256)
|
|
87135
87150
|
return null;
|
|
87136
87151
|
const source = bytes.toString("utf8");
|
|
87137
87152
|
const derived = Buffer.from(
|
|
87138
87153
|
"rewrite" in backport ? backport.rewrite(source) : source.replace(backport.before, backport.after)
|
|
87139
87154
|
);
|
|
87140
|
-
if ((0,
|
|
87155
|
+
if ((0, import_node_crypto60.createHash)("sha256").update(derived).digest("hex") !== backport.derivedSha256)
|
|
87141
87156
|
throw new Error(`Native source derivation differs: ${file}`);
|
|
87142
87157
|
return {
|
|
87143
87158
|
bytes: derived,
|
|
@@ -87156,11 +87171,11 @@ function deriveWasm64NativeSource(file, bytes) {
|
|
|
87156
87171
|
sourceDerivations.get(name3) ?? headerDerivations.get(name3)
|
|
87157
87172
|
);
|
|
87158
87173
|
}
|
|
87159
|
-
var
|
|
87174
|
+
var import_node_crypto60, import_node_path102, webrtcUnknownArchitecture, boringsslWordSize2, wamrCommit, headerDerivations, sourceDerivations;
|
|
87160
87175
|
var init_swift_wasm64_native_source = __esm({
|
|
87161
87176
|
"src/swift-wasm64-native-source.ts"() {
|
|
87162
87177
|
"use strict";
|
|
87163
|
-
|
|
87178
|
+
import_node_crypto60 = require("node:crypto");
|
|
87164
87179
|
import_node_path102 = __toESM(require("node:path"), 1);
|
|
87165
87180
|
init_swift_wasm64_wamr();
|
|
87166
87181
|
init_swiftWasm64ConfigContract();
|
|
@@ -87620,7 +87635,7 @@ var init_genrule_library_builds = __esm({
|
|
|
87620
87635
|
function nativeFrameworkCompiler(moduleRoot, toolchainBin, directory2) {
|
|
87621
87636
|
const distribution = swiftDistributionAt(moduleRoot);
|
|
87622
87637
|
const sdk2 = swiftSdkPaths(moduleRoot, toolchainBin);
|
|
87623
|
-
const identity2 = (0,
|
|
87638
|
+
const identity2 = (0, import_node_crypto61.createHash)("sha256").update(
|
|
87624
87639
|
JSON.stringify([
|
|
87625
87640
|
distribution?.id,
|
|
87626
87641
|
distribution?.link,
|
|
@@ -87646,7 +87661,7 @@ function nativeFrameworkCompiler(moduleRoot, toolchainBin, directory2) {
|
|
|
87646
87661
|
for (const alias of product.frameworkAliases) {
|
|
87647
87662
|
if (alias.wasmSdkId !== distribution.wasmSdkId || alias.wasmSdkChecksum !== distribution.wasmSdkChecksum)
|
|
87648
87663
|
throw new Error(`framework SDK identity differs for ${alias.name}`);
|
|
87649
|
-
if ((0,
|
|
87664
|
+
if ((0, import_node_crypto61.createHash)("sha256").update(import_node_fs101.default.readFileSync(import_node_path104.default.join(moduleRoot, alias.moduleMap))).digest("hex") !== alias.moduleMapSha256)
|
|
87650
87665
|
throw new Error(`framework module map changed ${alias.moduleMap}`);
|
|
87651
87666
|
const selected = /* @__PURE__ */ new Set();
|
|
87652
87667
|
const reach = (name3) => {
|
|
@@ -87687,7 +87702,7 @@ function nativeFrameworkCompiler(moduleRoot, toolchainBin, directory2) {
|
|
|
87687
87702
|
for (const alias of owner.frameworkAliases) {
|
|
87688
87703
|
if (frameworkResponses[alias.name])
|
|
87689
87704
|
throw new Error(`ambiguous declared framework ${alias.name}`);
|
|
87690
|
-
if ((0,
|
|
87705
|
+
if ((0, import_node_crypto61.createHash)("sha256").update(import_node_fs101.default.readFileSync(import_node_path104.default.join(sdkRoot, alias.moduleMap))).digest("hex") !== alias.moduleMapSha256)
|
|
87691
87706
|
throw new Error(`framework module map changed ${alias.moduleMap}`);
|
|
87692
87707
|
const file = import_node_path104.default.join(root, `${alias.name}.rsp`);
|
|
87693
87708
|
import_node_fs101.default.writeFileSync(file, aliasArtifacts.map(quote3).join("\n") + "\n");
|
|
@@ -87781,11 +87796,11 @@ exec ${shellQuote(configuration.compiler)} "$@"
|
|
|
87781
87796
|
};
|
|
87782
87797
|
return { cc: compiler("clang"), cxx: compiler("clang++"), identity: identity2 };
|
|
87783
87798
|
}
|
|
87784
|
-
var
|
|
87799
|
+
var import_node_crypto61, import_node_fs101, import_node_path104, v7;
|
|
87785
87800
|
var init_native_framework_compiler = __esm({
|
|
87786
87801
|
"src/native-framework-compiler.ts"() {
|
|
87787
87802
|
"use strict";
|
|
87788
|
-
|
|
87803
|
+
import_node_crypto61 = require("node:crypto");
|
|
87789
87804
|
import_node_fs101 = __toESM(require("node:fs"), 1);
|
|
87790
87805
|
import_node_path104 = __toESM(require("node:path"), 1);
|
|
87791
87806
|
v7 = __toESM(require("peachsim/vendor/valibot"), 1);
|
|
@@ -87806,7 +87821,7 @@ function processAlive(pid) {
|
|
|
87806
87821
|
}
|
|
87807
87822
|
function tryAcquireNumberedLock(directory2, detail = "") {
|
|
87808
87823
|
(0, import_node_fs102.mkdirSync)(directory2, { recursive: true });
|
|
87809
|
-
const claim = (0, import_node_path105.join)(directory2, `claim-${process.pid}-${(0,
|
|
87824
|
+
const claim = (0, import_node_path105.join)(directory2, `claim-${process.pid}-${(0, import_node_crypto62.randomUUID)()}`);
|
|
87810
87825
|
for (; ; ) {
|
|
87811
87826
|
const numbers = (0, import_node_fs102.readdirSync)(directory2).filter((name3) => /^\d+$/.test(name3)).map(Number);
|
|
87812
87827
|
const top = Math.max(-1, ...numbers);
|
|
@@ -87845,11 +87860,11 @@ ${detail}` : ""}`);
|
|
|
87845
87860
|
};
|
|
87846
87861
|
}
|
|
87847
87862
|
}
|
|
87848
|
-
var
|
|
87863
|
+
var import_node_crypto62, import_node_fs102, import_node_path105, errorCode2;
|
|
87849
87864
|
var init_numbered_lock = __esm({
|
|
87850
87865
|
"src/numbered-lock.ts"() {
|
|
87851
87866
|
"use strict";
|
|
87852
|
-
|
|
87867
|
+
import_node_crypto62 = require("node:crypto");
|
|
87853
87868
|
import_node_fs102 = require("node:fs");
|
|
87854
87869
|
import_node_path105 = require("node:path");
|
|
87855
87870
|
errorCode2 = (error) => error instanceof Error && "code" in error ? error.code : void 0;
|
|
@@ -87876,7 +87891,7 @@ function llvmIdentity(toolchainBin, release) {
|
|
|
87876
87891
|
] : ["clang", "wasm-ld", "llvm-ar", "llvm-nm", "llvm-strip"].map(
|
|
87877
87892
|
(name3) => swiftFileChecksum(import_node_path106.default.join(toolchainBin, name3))
|
|
87878
87893
|
);
|
|
87879
|
-
const identity2 = (0,
|
|
87894
|
+
const identity2 = (0, import_node_crypto63.createHash)("sha256").update(JSON.stringify(components)).digest("hex");
|
|
87880
87895
|
toolIdentities.set(toolchainBin, identity2);
|
|
87881
87896
|
return identity2;
|
|
87882
87897
|
}
|
|
@@ -87884,7 +87899,7 @@ function cSdkIdentity(sysroot, resourceDir, frameworks) {
|
|
|
87884
87899
|
const key2 = JSON.stringify([sysroot, resourceDir, frameworks]);
|
|
87885
87900
|
const cached2 = sysrootIdentities.get(key2);
|
|
87886
87901
|
if (cached2) return cached2;
|
|
87887
|
-
const hash = (0,
|
|
87902
|
+
const hash = (0, import_node_crypto63.createHash)("sha256");
|
|
87888
87903
|
const add = (root, relative4) => {
|
|
87889
87904
|
const file = import_node_path106.default.join(root, relative4);
|
|
87890
87905
|
const stat = import_node_fs103.default.statSync(file, { throwIfNoEntry: false });
|
|
@@ -87919,7 +87934,7 @@ function frameworkProbeIdentity(moduleRoot, toolchainBin) {
|
|
|
87919
87934
|
import_node_fs103.default.readFileSync(import_node_path106.default.join(moduleRoot, SWIFT_FRAMEWORK_PRODUCT_FILE), "utf8")
|
|
87920
87935
|
)
|
|
87921
87936
|
);
|
|
87922
|
-
const hash = (0,
|
|
87937
|
+
const hash = (0, import_node_crypto63.createHash)("sha256").update(
|
|
87923
87938
|
JSON.stringify([
|
|
87924
87939
|
headers,
|
|
87925
87940
|
distribution.link,
|
|
@@ -87929,7 +87944,7 @@ function frameworkProbeIdentity(moduleRoot, toolchainBin) {
|
|
|
87929
87944
|
])
|
|
87930
87945
|
);
|
|
87931
87946
|
const objects = distribution.objects.map((file) => [file, distribution.files[file]]);
|
|
87932
|
-
const objectKey = (0,
|
|
87947
|
+
const objectKey = (0, import_node_crypto63.createHash)("sha256").update(JSON.stringify(objects)).digest("hex");
|
|
87933
87948
|
const cache = import_node_path106.default.join(cacheDir4, "framework-symbols-by-object", objectKey);
|
|
87934
87949
|
if (!import_node_fs103.default.existsSync(cache)) {
|
|
87935
87950
|
import_node_fs103.default.mkdirSync(import_node_path106.default.dirname(cache), { recursive: true });
|
|
@@ -87964,7 +87979,7 @@ function frameworkProbeIdentity(moduleRoot, toolchainBin) {
|
|
|
87964
87979
|
const digest3 = import_node_path106.default.join(temporary, "digest");
|
|
87965
87980
|
import_node_fs103.default.writeFileSync(
|
|
87966
87981
|
digest3,
|
|
87967
|
-
(0,
|
|
87982
|
+
(0, import_node_crypto63.createHash)("sha256").update(symbols.sort().join("\n")).digest("hex")
|
|
87968
87983
|
);
|
|
87969
87984
|
import_node_fs103.default.renameSync(digest3, cache);
|
|
87970
87985
|
} finally {
|
|
@@ -88019,7 +88034,7 @@ function buildable(declaration) {
|
|
|
88019
88034
|
return builderOf(declaration) !== null && declaration.dependencies.every(buildable);
|
|
88020
88035
|
}
|
|
88021
88036
|
function declarationInputs(declaration, builder, toolchain, dependencyKeys) {
|
|
88022
|
-
const hash = (0,
|
|
88037
|
+
const hash = (0, import_node_crypto63.createHash)("sha256");
|
|
88023
88038
|
const files2 = declaration.sources.filter(
|
|
88024
88039
|
(source) => !source.generator && !source.file.split(import_node_path106.default.sep).includes(".git")
|
|
88025
88040
|
).map((source) => import_node_path106.default.relative(declaration.packageDir, source.file));
|
|
@@ -88153,12 +88168,12 @@ function genruleArchive(declaration, library, moduleRoot) {
|
|
|
88153
88168
|
}
|
|
88154
88169
|
return combined;
|
|
88155
88170
|
}
|
|
88156
|
-
var import_node_child_process51,
|
|
88171
|
+
var import_node_child_process51, import_node_crypto63, import_node_fs103, import_node_os20, import_node_path106, v8, BUILDERS, cacheDir4, toolIdentities, sysrootIdentities, GENRULE_RECIPE, GENRULE_BUNDLE;
|
|
88157
88172
|
var init_genrule_archives = __esm({
|
|
88158
88173
|
"src/genrule-archives.ts"() {
|
|
88159
88174
|
"use strict";
|
|
88160
88175
|
import_node_child_process51 = require("node:child_process");
|
|
88161
|
-
|
|
88176
|
+
import_node_crypto63 = require("node:crypto");
|
|
88162
88177
|
import_node_fs103 = __toESM(require("node:fs"), 1);
|
|
88163
88178
|
import_node_os20 = __toESM(require("node:os"), 1);
|
|
88164
88179
|
import_node_path106 = __toESM(require("node:path"), 1);
|
|
@@ -88266,7 +88281,7 @@ function privateSentrySlice(entry, moduleRoot) {
|
|
|
88266
88281
|
function nativeSwiftSlice(standin, moduleRoot, generator, configured, artifact) {
|
|
88267
88282
|
if (standin.module !== SENTRY_SWIFT_SLICE.name) return standin;
|
|
88268
88283
|
const native = simulatorNativeLibrary(artifact());
|
|
88269
|
-
if (!native || (0,
|
|
88284
|
+
if (!native || (0, import_node_crypto64.createHash)("sha256").update(import_node_fs104.default.readFileSync(native.file)).digest("hex") !== SENTRY_SWIFT_SLICE.nativeSha256)
|
|
88270
88285
|
return standin;
|
|
88271
88286
|
if (configured)
|
|
88272
88287
|
throw new Error(
|
|
@@ -88324,12 +88339,12 @@ function nativeSwiftSlice(standin, moduleRoot, generator, configured, artifact)
|
|
|
88324
88339
|
}
|
|
88325
88340
|
};
|
|
88326
88341
|
}
|
|
88327
|
-
var import_node_child_process52,
|
|
88342
|
+
var import_node_child_process52, import_node_crypto64, import_node_fs104, import_node_os21, import_node_path107, SENTRY_SWIFT_SLICE;
|
|
88328
88343
|
var init_native_swift_slices = __esm({
|
|
88329
88344
|
"src/native-swift-slices.ts"() {
|
|
88330
88345
|
"use strict";
|
|
88331
88346
|
import_node_child_process52 = require("node:child_process");
|
|
88332
|
-
|
|
88347
|
+
import_node_crypto64 = require("node:crypto");
|
|
88333
88348
|
import_node_fs104 = __toESM(require("node:fs"), 1);
|
|
88334
88349
|
import_node_os21 = __toESM(require("node:os"), 1);
|
|
88335
88350
|
import_node_path107 = __toESM(require("node:path"), 1);
|
|
@@ -89089,7 +89104,7 @@ function treeDigest(root) {
|
|
|
89089
89104
|
}).join("\n");
|
|
89090
89105
|
const memo2 = digests.get(`tree\0${root}`);
|
|
89091
89106
|
if (memo2?.stamp === stamp) return memo2.digest;
|
|
89092
|
-
const hash = (0,
|
|
89107
|
+
const hash = (0, import_node_crypto65.createHash)("sha256");
|
|
89093
89108
|
for (const name3 of names) {
|
|
89094
89109
|
hash.update(`${name3}\0`);
|
|
89095
89110
|
hash.update(import_node_fs108.default.readFileSync(import_node_path110.default.join(root, name3)));
|
|
@@ -89136,7 +89151,7 @@ function swiftBinaryFramework(binary2) {
|
|
|
89136
89151
|
const found3 = locateXcframework(import_node_path110.default.join(dir, "tree"));
|
|
89137
89152
|
if (found3) return { dir: found3, digest: stored.sha };
|
|
89138
89153
|
}
|
|
89139
|
-
const sha2 = (0,
|
|
89154
|
+
const sha2 = (0, import_node_crypto65.createHash)("sha256").update(import_node_fs108.default.readFileSync(binary2.dir)).digest("hex");
|
|
89140
89155
|
if (sha2 !== stored?.sha || !locateXcframework(import_node_path110.default.join(dir, "tree"))) {
|
|
89141
89156
|
import_node_fs108.default.rmSync(dir, { recursive: true, force: true });
|
|
89142
89157
|
import_node_fs108.default.mkdirSync(import_node_path110.default.join(dir, "tree"), { recursive: true });
|
|
@@ -89148,7 +89163,7 @@ function swiftBinaryFramework(binary2) {
|
|
|
89148
89163
|
return { dir: found2, digest: sha2 };
|
|
89149
89164
|
}
|
|
89150
89165
|
if (stored && import_node_fs108.default.existsSync(archive)) {
|
|
89151
|
-
const sha2 = (0,
|
|
89166
|
+
const sha2 = (0, import_node_crypto65.createHash)("sha256").update(import_node_fs108.default.readFileSync(archive)).digest("hex");
|
|
89152
89167
|
if (sha2 !== expected)
|
|
89153
89168
|
throw new Error(`archive checksum ${sha2} is not the declared checksum ${expected}`);
|
|
89154
89169
|
const found2 = locateXcframework(import_node_path110.default.join(dir, "tree"));
|
|
@@ -89157,7 +89172,7 @@ function swiftBinaryFramework(binary2) {
|
|
|
89157
89172
|
import_node_fs108.default.rmSync(dir, { recursive: true, force: true });
|
|
89158
89173
|
import_node_fs108.default.mkdirSync(import_node_path110.default.join(dir, "tree"), { recursive: true });
|
|
89159
89174
|
exec("curl", ["-fsSL", "--retry", "2", "-o", archive, binary2.url]);
|
|
89160
|
-
const sha = (0,
|
|
89175
|
+
const sha = (0, import_node_crypto65.createHash)("sha256").update(import_node_fs108.default.readFileSync(archive)).digest("hex");
|
|
89161
89176
|
if (sha !== expected) {
|
|
89162
89177
|
import_node_fs108.default.rmSync(dir, { recursive: true, force: true });
|
|
89163
89178
|
throw new Error(`archive checksum ${sha} is not the declared checksum ${expected}`);
|
|
@@ -89282,7 +89297,7 @@ function binaryHeaderSearchPaths(binary2, root, workspaceRoot2, declaredFramewor
|
|
|
89282
89297
|
});
|
|
89283
89298
|
}
|
|
89284
89299
|
}
|
|
89285
|
-
const declaredDigest = (0,
|
|
89300
|
+
const declaredDigest = (0, import_node_crypto65.createHash)("sha256");
|
|
89286
89301
|
for (const framework of providedFrameworks)
|
|
89287
89302
|
declaredDigest.update(`provided/${import_node_path110.default.relative(artifact.dir, framework)}\0`);
|
|
89288
89303
|
for (const [framework, { declared: names, imports: imports2, sdkHeader }] of declared)
|
|
@@ -89352,7 +89367,7 @@ function binaryHeaderSearchPaths(binary2, root, workspaceRoot2, declaredFramewor
|
|
|
89352
89367
|
import_node_fs108.default.copyFileSync(surface.modulemap, modulemap);
|
|
89353
89368
|
}
|
|
89354
89369
|
}
|
|
89355
|
-
const contents2 = (0,
|
|
89370
|
+
const contents2 = (0, import_node_crypto65.createHash)("sha256");
|
|
89356
89371
|
for (const framework of providedFrameworks.filter((item) => !declared.has(item))) {
|
|
89357
89372
|
const modulemap = import_node_path110.default.join(
|
|
89358
89373
|
pending2,
|
|
@@ -90767,7 +90782,7 @@ function crateSourceRoots(manifest, searchRoot) {
|
|
|
90767
90782
|
return roots;
|
|
90768
90783
|
}
|
|
90769
90784
|
function crateSourceDigest(manifest, searchRoot) {
|
|
90770
|
-
const hash = (0,
|
|
90785
|
+
const hash = (0, import_node_crypto65.createHash)("sha256");
|
|
90771
90786
|
const walk4 = (dir, root) => {
|
|
90772
90787
|
for (const entry of import_node_fs108.default.readdirSync(dir, { withFileTypes: true }).sort((left, right) => left.name < right.name ? -1 : 1)) {
|
|
90773
90788
|
const full = import_node_path110.default.join(dir, entry.name);
|
|
@@ -91214,7 +91229,7 @@ function standinGenerationInputs(binaries, toolchain, configuredBehavior = {}, s
|
|
|
91214
91229
|
...swiftSources.flags,
|
|
91215
91230
|
...swiftSources.sources.flatMap((source) => [
|
|
91216
91231
|
source,
|
|
91217
|
-
(0,
|
|
91232
|
+
(0, import_node_crypto65.createHash)("sha256").update(import_node_fs108.default.readFileSync(import_node_path110.default.join(binary2.dir, source))).digest("hex")
|
|
91218
91233
|
])
|
|
91219
91234
|
);
|
|
91220
91235
|
continue;
|
|
@@ -91250,7 +91265,7 @@ function standinGenerationInputs(binaries, toolchain, configuredBehavior = {}, s
|
|
|
91250
91265
|
);
|
|
91251
91266
|
}
|
|
91252
91267
|
}
|
|
91253
|
-
return (0,
|
|
91268
|
+
return (0, import_node_crypto65.createHash)("sha256").update(parts.join("\0")).digest("hex");
|
|
91254
91269
|
}
|
|
91255
91270
|
function missingArtifactGap(binary2) {
|
|
91256
91271
|
if (swiftBinaryOnDisk(binary2)) return null;
|
|
@@ -91332,7 +91347,7 @@ ${roots.map((file) => ` header "${file}"`).join("\n")}
|
|
|
91332
91347
|
return NO_IMPORTABLE_SURFACE;
|
|
91333
91348
|
}
|
|
91334
91349
|
const configured = new Map(Object.entries(behavior));
|
|
91335
|
-
const hash = (0,
|
|
91350
|
+
const hash = (0, import_node_crypto65.createHash)("sha256").update(
|
|
91336
91351
|
standinGenerationInputs([binary2], toolchain, behavior)
|
|
91337
91352
|
);
|
|
91338
91353
|
hash.update(digest3);
|
|
@@ -91572,7 +91587,7 @@ async function buildStandins(binaries, toolchain, provided, behavior) {
|
|
|
91572
91587
|
);
|
|
91573
91588
|
if (binary2.moduleSources !== void 0)
|
|
91574
91589
|
frameworkInputs.push(
|
|
91575
|
-
`${binary2.target}\0${(0,
|
|
91590
|
+
`${binary2.target}\0${(0, import_node_crypto65.createHash)("sha256").update(
|
|
91576
91591
|
[iosSdkId(), ...swiftSources.flags, ...swiftSources.sources, ...texts].join(
|
|
91577
91592
|
"\0"
|
|
91578
91593
|
)
|
|
@@ -91613,7 +91628,7 @@ async function buildStandins(binaries, toolchain, provided, behavior) {
|
|
|
91613
91628
|
import_node_fs108.default.mkdirSync(sourceFrameworks);
|
|
91614
91629
|
const frameworks = {
|
|
91615
91630
|
dirs: [...frameworkDirs, sourceFrameworks].sort(),
|
|
91616
|
-
digest: (0,
|
|
91631
|
+
digest: (0, import_node_crypto65.createHash)("sha256").update(frameworkInputs.sort().join("\0")).digest("hex"),
|
|
91617
91632
|
surfaces: frameworkSurfaces
|
|
91618
91633
|
};
|
|
91619
91634
|
const siblings = new Map(
|
|
@@ -91732,12 +91747,12 @@ async function buildStandins(binaries, toolchain, provided, behavior) {
|
|
|
91732
91747
|
import_node_fs108.default.rmSync(modules, { recursive: true, force: true });
|
|
91733
91748
|
}
|
|
91734
91749
|
}
|
|
91735
|
-
var import_node_child_process54,
|
|
91750
|
+
var import_node_child_process54, import_node_crypto65, import_node_fs108, import_node_path110, 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;
|
|
91736
91751
|
var init_swift_standins = __esm({
|
|
91737
91752
|
"src/swift-standins.ts"() {
|
|
91738
91753
|
"use strict";
|
|
91739
91754
|
import_node_child_process54 = require("node:child_process");
|
|
91740
|
-
|
|
91755
|
+
import_node_crypto65 = require("node:crypto");
|
|
91741
91756
|
import_node_fs108 = __toESM(require("node:fs"), 1);
|
|
91742
91757
|
import_node_path110 = __toESM(require("node:path"), 1);
|
|
91743
91758
|
init_forked_script_contract();
|
|
@@ -91767,7 +91782,7 @@ var init_swift_standins = __esm({
|
|
|
91767
91782
|
init_swiftTargetContract();
|
|
91768
91783
|
TRIPLE = SWIFT_WASM_TRIPLE;
|
|
91769
91784
|
cacheDir5 = import_node_path110.default.join(cacheDir(), "swift-standins");
|
|
91770
|
-
key = (...parts) => (0,
|
|
91785
|
+
key = (...parts) => (0, import_node_crypto65.createHash)("sha256").update(parts.join("\0")).digest("hex").slice(0, 32);
|
|
91771
91786
|
digests = /* @__PURE__ */ new Map();
|
|
91772
91787
|
isBinaryLibraryFile = (file) => /\.(?:a|dylib|o|tbd)$/i.test(file);
|
|
91773
91788
|
OBJC_IMPORT = /#\s*(?:import|include)\s*[<"](?:[\w+-]+\/)?([\w+.-]+\.h)[>"]/g;
|
|
@@ -91930,7 +91945,7 @@ function compiledFrameworkImports(app, products) {
|
|
|
91930
91945
|
function sha256Hex6(bytes) {
|
|
91931
91946
|
if (typeof Bun !== "undefined")
|
|
91932
91947
|
return new Bun.CryptoHasher("sha256").update(bytes).digest("hex");
|
|
91933
|
-
return (0,
|
|
91948
|
+
return (0, import_node_crypto66.createHash)("sha256").update(bytes).digest("hex");
|
|
91934
91949
|
}
|
|
91935
91950
|
function regularFileStamp(file) {
|
|
91936
91951
|
const stat = import_node_fs109.default.lstatSync(file, { bigint: true, throwIfNoEntry: false });
|
|
@@ -91973,7 +91988,7 @@ function cachedBinaryFileDigest(file) {
|
|
|
91973
91988
|
const digest3 = sha256Hex6(import_node_fs109.default.readFileSync(real));
|
|
91974
91989
|
binaryFileDigests.set(real, { stamp, digest: digest3 });
|
|
91975
91990
|
import_node_fs109.default.mkdirSync(dir, { recursive: true });
|
|
91976
|
-
const partial = `${record5}.${process.pid}.${(0,
|
|
91991
|
+
const partial = `${record5}.${process.pid}.${(0, import_node_crypto66.randomUUID)()}`;
|
|
91977
91992
|
import_node_fs109.default.writeFileSync(partial, JSON.stringify({ stamp, digest: digest3 }));
|
|
91978
91993
|
import_node_fs109.default.renameSync(partial, record5);
|
|
91979
91994
|
return digest3;
|
|
@@ -93243,12 +93258,12 @@ ${reported.trimEnd() || `Clang exited with status ${result.status}`}`;
|
|
|
93243
93258
|
import_node_fs109.default.closeSync(descriptor);
|
|
93244
93259
|
}
|
|
93245
93260
|
}
|
|
93246
|
-
var import_node_child_process55,
|
|
93261
|
+
var import_node_child_process55, import_node_crypto66, import_node_fs109, import_node_path111, SwiftObjCCompilationError, isDirectory4, isSdkInclude, FRAMEWORK_IMPORT, OWN_IMPORT, binaryFileDigests, objcInputSnapshots;
|
|
93247
93262
|
var init_swift_objc_compile = __esm({
|
|
93248
93263
|
"src/swift-objc-compile.ts"() {
|
|
93249
93264
|
"use strict";
|
|
93250
93265
|
import_node_child_process55 = require("node:child_process");
|
|
93251
|
-
|
|
93266
|
+
import_node_crypto66 = require("node:crypto");
|
|
93252
93267
|
import_node_fs109 = __toESM(require("node:fs"), 1);
|
|
93253
93268
|
import_node_path111 = __toESM(require("node:path"), 1);
|
|
93254
93269
|
init_mapLimit();
|
|
@@ -93302,7 +93317,7 @@ async function buildRiveRuntimeDependencies(checkout, moduleRoot) {
|
|
|
93302
93317
|
];
|
|
93303
93318
|
const objc = [...swiftObjCRuntimeFlags, "-fobjc-exceptions"];
|
|
93304
93319
|
const xcode = (0, import_node_child_process56.execFileSync)("xcodebuild", ["-version"], { encoding: "utf8" });
|
|
93305
|
-
const key2 = (0,
|
|
93320
|
+
const key2 = (0, import_node_crypto67.createHash)("sha256").update(
|
|
93306
93321
|
JSON.stringify([
|
|
93307
93322
|
RECIPE,
|
|
93308
93323
|
(0, import_node_child_process56.execFileSync)("git", ["-C", runtime, "rev-parse", "HEAD"], {
|
|
@@ -93513,12 +93528,12 @@ exec ${quote3(import_node_path112.default.join(toolchainBin, "llvm-ar"))} rcs "$
|
|
|
93513
93528
|
);
|
|
93514
93529
|
return directory2;
|
|
93515
93530
|
}
|
|
93516
|
-
var import_node_child_process56,
|
|
93531
|
+
var import_node_child_process56, import_node_crypto67, import_node_fs110, import_node_os22, import_node_path112, import_promises9, RECIPE, CONFIG, RUNTIME_LIBRARIES;
|
|
93517
93532
|
var init_rive_runtime_dependencies = __esm({
|
|
93518
93533
|
"src/rive-runtime-dependencies.ts"() {
|
|
93519
93534
|
"use strict";
|
|
93520
93535
|
import_node_child_process56 = require("node:child_process");
|
|
93521
|
-
|
|
93536
|
+
import_node_crypto67 = require("node:crypto");
|
|
93522
93537
|
import_node_fs110 = __toESM(require("node:fs"), 1);
|
|
93523
93538
|
import_node_os22 = __toESM(require("node:os"), 1);
|
|
93524
93539
|
import_node_path112 = __toESM(require("node:path"), 1);
|
|
@@ -94375,7 +94390,7 @@ async function xcodeCxxReachable(app, binaries, moduleRoot, clang) {
|
|
|
94375
94390
|
(binary2) => binary2.publicHeaders === void 0 && binary2.placeholder === void 0 && swiftBinaryOnDisk(binary2) && binaryHeaderSearchPaths(binary2, staged, app.rootDir).headers.length === 1
|
|
94376
94391
|
))
|
|
94377
94392
|
return [...binaries];
|
|
94378
|
-
const hash = (0,
|
|
94393
|
+
const hash = (0, import_node_crypto68.createHash)("sha256");
|
|
94379
94394
|
hash.update(
|
|
94380
94395
|
JSON.stringify([
|
|
94381
94396
|
inputs2.targets,
|
|
@@ -94584,12 +94599,12 @@ async function xcodeCxxReachable(app, binaries, moduleRoot, clang) {
|
|
|
94584
94599
|
);
|
|
94585
94600
|
return result;
|
|
94586
94601
|
}
|
|
94587
|
-
var import_node_child_process58,
|
|
94602
|
+
var import_node_child_process58, import_node_crypto68, import_node_fs112, import_node_path114, cachedInputs;
|
|
94588
94603
|
var init_swift_cxx_reachable = __esm({
|
|
94589
94604
|
"src/swift-cxx-reachable.ts"() {
|
|
94590
94605
|
"use strict";
|
|
94591
94606
|
import_node_child_process58 = require("node:child_process");
|
|
94592
|
-
|
|
94607
|
+
import_node_crypto68 = require("node:crypto");
|
|
94593
94608
|
import_node_fs112 = __toESM(require("node:fs"), 1);
|
|
94594
94609
|
import_node_path114 = __toESM(require("node:path"), 1);
|
|
94595
94610
|
init_is_record();
|
|
@@ -94787,7 +94802,7 @@ function nativeSourceDescriptor(packagePath) {
|
|
|
94787
94802
|
function swiftArtifactContentDigest(bytes) {
|
|
94788
94803
|
let digest3 = swiftArtifactDigests.get(bytes);
|
|
94789
94804
|
if (!digest3) {
|
|
94790
|
-
digest3 = (0,
|
|
94805
|
+
digest3 = (0, import_node_crypto69.createHash)("sha256").update(bytes).digest("hex");
|
|
94791
94806
|
swiftArtifactDigests.set(bytes, digest3);
|
|
94792
94807
|
}
|
|
94793
94808
|
return digest3;
|
|
@@ -94915,7 +94930,7 @@ async function wasmPortableAssembly(binaries, toolchainBin, moduleRoot) {
|
|
|
94915
94930
|
const clang = import_node_path116.default.join(toolchainBin, "clang");
|
|
94916
94931
|
const empty = (binary2, file) => {
|
|
94917
94932
|
const source = import_node_path116.default.join(binary2.dir, file);
|
|
94918
|
-
const key2 = (0,
|
|
94933
|
+
const key2 = (0, import_node_crypto69.createHash)("sha256").update(
|
|
94919
94934
|
JSON.stringify([
|
|
94920
94935
|
clang,
|
|
94921
94936
|
sdk2.sysroot,
|
|
@@ -94960,7 +94975,7 @@ async function wasmPortableAssembly(binaries, toolchainBin, moduleRoot) {
|
|
|
94960
94975
|
return new Set(portable.flat());
|
|
94961
94976
|
}
|
|
94962
94977
|
async function swiftPackages(entry, app) {
|
|
94963
|
-
const stamp = (file) => import_node_fs114.default.existsSync(file) ? (0,
|
|
94978
|
+
const stamp = (file) => import_node_fs114.default.existsSync(file) ? (0, import_node_crypto69.createHash)("sha256").update(import_node_fs114.default.readFileSync(file)).digest("hex") : null;
|
|
94964
94979
|
const owners = [...app.frameworks, app].map((target) => ({
|
|
94965
94980
|
module: target.moduleName,
|
|
94966
94981
|
products: target.packageProducts ?? []
|
|
@@ -96124,7 +96139,7 @@ async function buildSwiftResourceTable(project2, baseUrl, inputs2) {
|
|
|
96124
96139
|
const source = new TextDecoder("utf-8", { fatal: true, ignoreBOM: true }).decode(
|
|
96125
96140
|
bytes
|
|
96126
96141
|
);
|
|
96127
|
-
const sha2565 = (0,
|
|
96142
|
+
const sha2565 = (0, import_node_crypto69.createHash)("sha256").update(bytes).digest("hex");
|
|
96128
96143
|
const bundle = swiftResourceBundleForFile(bundles, key2);
|
|
96129
96144
|
if (!bundle && inputs2["Package.swift"])
|
|
96130
96145
|
throw new Error(`metal source ${key2} has no resource target bundle`);
|
|
@@ -96147,7 +96162,7 @@ async function buildSwiftResourceTable(project2, baseUrl, inputs2) {
|
|
|
96147
96162
|
const bytes = readPackageFile2(project2.packagePath, disk, limits.imageBytes);
|
|
96148
96163
|
pdfs.set(file, {
|
|
96149
96164
|
file: disk,
|
|
96150
|
-
sha256: (0,
|
|
96165
|
+
sha256: (0, import_node_crypto69.createHash)("sha256").update(bytes).digest("hex")
|
|
96151
96166
|
});
|
|
96152
96167
|
}
|
|
96153
96168
|
const pdfRasters = rasterizePdfFiles([...pdfs.values()], limits);
|
|
@@ -96193,7 +96208,7 @@ async function buildSwiftResourceTable(project2, baseUrl, inputs2) {
|
|
|
96193
96208
|
throw new Error("swift image pack exceeds the compile service caps");
|
|
96194
96209
|
}
|
|
96195
96210
|
imageBytes += bytes.length;
|
|
96196
|
-
const hash = (0,
|
|
96211
|
+
const hash = (0, import_node_crypto69.createHash)("sha256").update(bytes).digest("hex").slice(0, 16);
|
|
96197
96212
|
const bundle = table[bundlePath] ?? /* @__PURE__ */ Object.create(null);
|
|
96198
96213
|
const pixelSize = ext === ".png" ? readPngDimensions(bytes) : null;
|
|
96199
96214
|
const variant2 = {
|
|
@@ -96500,7 +96515,7 @@ function updateSwiftConfigStamp(hash, packagePath) {
|
|
|
96500
96515
|
hash.update(JSON.stringify(gates.map((name3) => swiftWasm64PlatformGates[name3])));
|
|
96501
96516
|
}
|
|
96502
96517
|
function sourceStamp(packagePath, moduleRootOverride, hosted = false) {
|
|
96503
|
-
const hash = (0,
|
|
96518
|
+
const hash = (0, import_node_crypto69.createHash)("sha256");
|
|
96504
96519
|
hash.update(packagePath);
|
|
96505
96520
|
updateSwiftConfigStamp(hash, packagePath);
|
|
96506
96521
|
const libraries = projects().get(packagePath)?.libraries;
|
|
@@ -96529,7 +96544,7 @@ function sourceStamp(packagePath, moduleRootOverride, hosted = false) {
|
|
|
96529
96544
|
return hash.digest("hex").slice(0, 16);
|
|
96530
96545
|
}
|
|
96531
96546
|
function sourceContentStamp(packagePath, moduleRootOverride) {
|
|
96532
|
-
const hash = (0,
|
|
96547
|
+
const hash = (0, import_node_crypto69.createHash)("sha256");
|
|
96533
96548
|
hash.update(compilerSourceDigest);
|
|
96534
96549
|
updateSwiftConfigStamp(hash, packagePath);
|
|
96535
96550
|
const libraries = projects().get(packagePath)?.libraries;
|
|
@@ -96561,7 +96576,7 @@ function moduleStamp(packagePath, moduleRootOverride, hosted) {
|
|
|
96561
96576
|
(root) => import_node_fs114.default.existsSync(import_node_path116.default.join(root, "toolchain.json"))
|
|
96562
96577
|
);
|
|
96563
96578
|
if (!moduleRoot) return "";
|
|
96564
|
-
const hash = (0,
|
|
96579
|
+
const hash = (0, import_node_crypto69.createHash)("sha256");
|
|
96565
96580
|
hash.update(moduleRoot);
|
|
96566
96581
|
for (const relative4 of swiftModuleInputFiles(moduleRoot)) {
|
|
96567
96582
|
hash.update(relative4);
|
|
@@ -96571,7 +96586,7 @@ function moduleStamp(packagePath, moduleRootOverride, hosted) {
|
|
|
96571
96586
|
}
|
|
96572
96587
|
function otherInputs(input, standalone) {
|
|
96573
96588
|
const { files: _files, ...rest } = input;
|
|
96574
|
-
return (0,
|
|
96589
|
+
return (0, import_node_crypto69.createHash)("sha256").update(JSON.stringify({ ...rest, standalone })).digest("hex");
|
|
96575
96590
|
}
|
|
96576
96591
|
function icuUrl(origin, artifact) {
|
|
96577
96592
|
return "url" in artifact.icu ? artifact.icu.url : `${origin}${ICU_PATH}${swiftIcuAddress(artifact.icu)}`;
|
|
@@ -96586,7 +96601,7 @@ function standinLibraries(binaries, standins, rootDir, toolchain, rustWasm64) {
|
|
|
96586
96601
|
for (const standin of standins) {
|
|
96587
96602
|
if (!standin.prebuilt) continue;
|
|
96588
96603
|
const bytes = Buffer.from(standin.prebuilt.library, "base64");
|
|
96589
|
-
const digest3 = (0,
|
|
96604
|
+
const digest3 = (0, import_node_crypto69.createHash)("sha256").update(bytes).digest("hex");
|
|
96590
96605
|
const dir = import_node_path116.default.join(swiftCacheDir(), "native-archives", digest3);
|
|
96591
96606
|
import_node_fs114.default.mkdirSync(dir, { recursive: true });
|
|
96592
96607
|
const library = import_node_path116.default.join(dir, `lib${standin.module}.a`);
|
|
@@ -96935,7 +96950,7 @@ function swiftBuildRoot(packagePath, moduleRoot) {
|
|
|
96935
96950
|
return import_node_path116.default.join(
|
|
96936
96951
|
swiftCacheDir(),
|
|
96937
96952
|
"swift-builds",
|
|
96938
|
-
(0,
|
|
96953
|
+
(0, import_node_crypto69.createHash)("sha256").update(`${compilerKey}\0${buildKeyPath}`).digest("hex").slice(0, 16)
|
|
96939
96954
|
);
|
|
96940
96955
|
}
|
|
96941
96956
|
function installedWorkspaceInput(packagePath, entry, moduleRoot) {
|
|
@@ -97236,7 +97251,7 @@ async function fetchSwiftDyldTable(moduleUrl, module2, signal) {
|
|
|
97236
97251
|
const response = await fetch(url, { signal });
|
|
97237
97252
|
if (!response.ok) throw new Error(`swift compile: ${url} answered ${response.status}`);
|
|
97238
97253
|
const bytes = Buffer.from(await response.arrayBuffer());
|
|
97239
|
-
if (bytes.length !== byteLength || (0,
|
|
97254
|
+
if (bytes.length !== byteLength || (0, import_node_crypto69.createHash)("sha256").update(bytes).digest("hex") !== sha2565)
|
|
97240
97255
|
throw new Error(`swift compile: ${url} does not match its module's index`);
|
|
97241
97256
|
return { dyldTable: { sha256: sha2565, bytes } };
|
|
97242
97257
|
}
|
|
@@ -97315,13 +97330,13 @@ function swiftArtifactIsAvailable(origin, url, hash) {
|
|
|
97315
97330
|
(project2) => project2.artifacts.some((artifact) => artifact.hash === hash)
|
|
97316
97331
|
);
|
|
97317
97332
|
}
|
|
97318
|
-
var import_node_async_hooks2, import_node_child_process60,
|
|
97333
|
+
var import_node_async_hooks2, import_node_child_process60, import_node_crypto69, import_node_fs114, import_node_os24, import_node_path116, ARTIFACT_PATH, RESOURCE_PATH, ICU_PATH, SKIP_ROOT_DIRS, NATIVE_DESCRIPTOR, NATIVE_GLUE, SwiftMissingModulesError, 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;
|
|
97319
97334
|
var init_swift_host = __esm({
|
|
97320
97335
|
"src/swift-host.ts"() {
|
|
97321
97336
|
"use strict";
|
|
97322
97337
|
import_node_async_hooks2 = require("node:async_hooks");
|
|
97323
97338
|
import_node_child_process60 = require("node:child_process");
|
|
97324
|
-
|
|
97339
|
+
import_node_crypto69 = require("node:crypto");
|
|
97325
97340
|
import_node_fs114 = __toESM(require("node:fs"), 1);
|
|
97326
97341
|
import_node_os24 = __toESM(require("node:os"), 1);
|
|
97327
97342
|
import_node_path116 = __toESM(require("node:path"), 1);
|
|
@@ -97875,7 +97890,7 @@ function hashTree(root) {
|
|
|
97875
97890
|
for (const entry of import_node_fs117.default.readdirSync(root, { recursive: true, withFileTypes: true })) {
|
|
97876
97891
|
if (!entry.isFile()) continue;
|
|
97877
97892
|
const file = import_node_path119.default.join(entry.parentPath, entry.name);
|
|
97878
|
-
hashes[import_node_path119.default.relative(root, file).split(import_node_path119.default.sep).join("/")] = (0,
|
|
97893
|
+
hashes[import_node_path119.default.relative(root, file).split(import_node_path119.default.sep).join("/")] = (0, import_node_crypto70.createHash)("sha256").update(import_node_fs117.default.readFileSync(file)).digest("hex");
|
|
97879
97894
|
}
|
|
97880
97895
|
return Object.fromEntries(Object.entries(hashes).sort(([a], [b]) => a < b ? -1 : 1));
|
|
97881
97896
|
}
|
|
@@ -97925,12 +97940,12 @@ async function runInstalledTurboCodegen(appRoot, outDir, signal) {
|
|
|
97925
97940
|
files: hashTree(generatedRoot)
|
|
97926
97941
|
};
|
|
97927
97942
|
}
|
|
97928
|
-
var import_node_child_process61,
|
|
97943
|
+
var import_node_child_process61, import_node_crypto70, import_node_fs117, import_node_module13, import_node_path119, import_node_util15, run10, RENDERER_PODS, RENDERER_PODS_VERSIONED, COMPILED_SOURCE, LEGACY_BRIDGE_DEV_SUPPORT, LEGACY_BRIDGE_PODS, LEGACY_BRIDGE_PODS_VERSIONED;
|
|
97929
97944
|
var init_turbo_codegen_intake = __esm({
|
|
97930
97945
|
"src/turbo-codegen-intake.ts"() {
|
|
97931
97946
|
"use strict";
|
|
97932
97947
|
import_node_child_process61 = require("node:child_process");
|
|
97933
|
-
|
|
97948
|
+
import_node_crypto70 = require("node:crypto");
|
|
97934
97949
|
import_node_fs117 = __toESM(require("node:fs"), 1);
|
|
97935
97950
|
import_node_module13 = require("node:module");
|
|
97936
97951
|
import_node_path119 = __toESM(require("node:path"), 1);
|
|
@@ -101881,11 +101896,11 @@ extern "C" __attribute__((export_name("peach_fabric_component_names"))) const ch
|
|
|
101881
101896
|
}
|
|
101882
101897
|
`;
|
|
101883
101898
|
}
|
|
101884
|
-
var
|
|
101899
|
+
var import_node_crypto71, import_node_fs118, import_node_path120, 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;
|
|
101885
101900
|
var init_turbo_source = __esm({
|
|
101886
101901
|
"src/turbo-source.ts"() {
|
|
101887
101902
|
"use strict";
|
|
101888
|
-
|
|
101903
|
+
import_node_crypto71 = require("node:crypto");
|
|
101889
101904
|
import_node_fs118 = __toESM(require("node:fs"), 1);
|
|
101890
101905
|
import_node_path120 = __toESM(require("node:path"), 1);
|
|
101891
101906
|
init_cocoapods_trunk();
|
|
@@ -102013,7 +102028,7 @@ var init_turbo_source = __esm({
|
|
|
102013
102028
|
];
|
|
102014
102029
|
DECLARED_MODULE_NAME = /\bName\(\s*"(\w+)"\s*\)/g;
|
|
102015
102030
|
EXPORTED_MODULE = /\bRCT_(?:EXPORT_MODULE(?:_NO_LOAD)?|EXTERN_MODULE)\s*\(\s*(\w*)/g;
|
|
102016
|
-
sha2564 = (data) => (0,
|
|
102031
|
+
sha2564 = (data) => (0, import_node_crypto71.createHash)("sha256").update(data).digest("hex");
|
|
102017
102032
|
podspecList = podspecAttribute;
|
|
102018
102033
|
versionParts = (version2) => version2.split(/[.-]/).map((p) => Number(p) || 0);
|
|
102019
102034
|
iosOf = (member) => object7(member.ios) ? member.ios : null;
|
|
@@ -102813,7 +102828,7 @@ function retainInstalledReactNativeDeclarations(snapshot, options2, skipped) {
|
|
|
102813
102828
|
}
|
|
102814
102829
|
async function prepareTurboCompileInput(options2) {
|
|
102815
102830
|
await prepareTurboSourceDependencies(options2.reactNativeRoot);
|
|
102816
|
-
const key2 = (0,
|
|
102831
|
+
const key2 = (0, import_node_crypto72.createHash)("sha256").update(options2.providers.map(({ root }) => import_node_fs119.default.realpathSync(root)).join("\0")).update("\0").update(import_node_fs119.default.realpathSync(options2.moduleRoot)).digest("hex");
|
|
102817
102832
|
const scratch2 = import_node_path121.default.join(import_node_os25.default.tmpdir(), "peach-turbo-swift", key2);
|
|
102818
102833
|
import_node_fs119.default.mkdirSync(scratch2, { recursive: true });
|
|
102819
102834
|
const codegenDir = import_node_fs119.default.mkdtempSync(import_node_path121.default.join(scratch2, "codegen-"));
|
|
@@ -103014,11 +103029,11 @@ async function compileTurboModule(options2) {
|
|
|
103014
103029
|
collection
|
|
103015
103030
|
};
|
|
103016
103031
|
}
|
|
103017
|
-
var
|
|
103032
|
+
var import_node_crypto72, import_node_fs119, import_node_module14, import_node_os25, import_node_path121;
|
|
103018
103033
|
var init_turbo_compile = __esm({
|
|
103019
103034
|
"src/turbo-compile.ts"() {
|
|
103020
103035
|
"use strict";
|
|
103021
|
-
|
|
103036
|
+
import_node_crypto72 = require("node:crypto");
|
|
103022
103037
|
import_node_fs119 = __toESM(require("node:fs"), 1);
|
|
103023
103038
|
import_node_module14 = require("node:module");
|
|
103024
103039
|
import_node_os25 = __toESM(require("node:os"), 1);
|
|
@@ -103235,8 +103250,8 @@ function reactNativeCoreEntry(reactNativeRoot, moduleRoot, mode) {
|
|
|
103235
103250
|
);
|
|
103236
103251
|
if (!isRecord(manifest) || typeof manifest.version !== "string")
|
|
103237
103252
|
throw new Error(`${reactNativeRoot}: react-native has no version`);
|
|
103238
|
-
const headers = (0,
|
|
103239
|
-
const sources = (0,
|
|
103253
|
+
const headers = (0, import_node_crypto73.createHash)("sha256");
|
|
103254
|
+
const sources = (0, import_node_crypto73.createHash)("sha256");
|
|
103240
103255
|
const walk4 = (relative4) => {
|
|
103241
103256
|
for (const file of import_node_fs121.default.readdirSync(import_node_path123.default.join(reactNativeRoot, relative4), { withFileTypes: true }).sort((a, b) => a.name < b.name ? -1 : a.name > b.name ? 1 : 0)) {
|
|
103242
103257
|
if (file.name === "node_modules" || file.name.startsWith(".")) continue;
|
|
@@ -103343,7 +103358,7 @@ function linkReactNativeCore(collection, core, moduleRoot) {
|
|
|
103343
103358
|
const file = import_node_path123.default.join(
|
|
103344
103359
|
cacheDir(),
|
|
103345
103360
|
"native-archives",
|
|
103346
|
-
`${(0,
|
|
103361
|
+
`${(0, import_node_crypto73.createHash)("sha256").update(data).digest("hex")}.a`
|
|
103347
103362
|
);
|
|
103348
103363
|
import_node_fs121.default.mkdirSync(import_node_path123.default.dirname(file), { recursive: true });
|
|
103349
103364
|
if (!import_node_fs121.default.existsSync(file)) import_node_fs121.default.writeFileSync(file, Buffer.from(data, "base64"));
|
|
@@ -103353,11 +103368,11 @@ function linkReactNativeCore(collection, core, moduleRoot) {
|
|
|
103353
103368
|
}
|
|
103354
103369
|
}
|
|
103355
103370
|
}
|
|
103356
|
-
var
|
|
103371
|
+
var import_node_crypto73, import_node_fs121, import_node_module15, import_node_path123, import_node_util16, recipe, strings3, building;
|
|
103357
103372
|
var init_react_native_core = __esm({
|
|
103358
103373
|
"src/react-native-core.ts"() {
|
|
103359
103374
|
"use strict";
|
|
103360
|
-
|
|
103375
|
+
import_node_crypto73 = require("node:crypto");
|
|
103361
103376
|
import_node_fs121 = __toESM(require("node:fs"), 1);
|
|
103362
103377
|
import_node_module15 = require("node:module");
|
|
103363
103378
|
import_node_path123 = __toESM(require("node:path"), 1);
|
|
@@ -103387,11 +103402,11 @@ async function trunkSpecification(lockFile, root, version2, checksum) {
|
|
|
103387
103402
|
"specifications",
|
|
103388
103403
|
`${checksum}.json`
|
|
103389
103404
|
);
|
|
103390
|
-
const sha1 = (value) => (0,
|
|
103405
|
+
const sha1 = (value) => (0, import_node_crypto74.createHash)("sha1").update(value).digest("hex");
|
|
103391
103406
|
let text7;
|
|
103392
103407
|
if (import_node_fs122.default.existsSync(file)) text7 = import_node_fs122.default.readFileSync(file, "utf8");
|
|
103393
103408
|
else {
|
|
103394
|
-
const shard2 = (0,
|
|
103409
|
+
const shard2 = (0, import_node_crypto74.createHash)("md5").update(root).digest("hex").slice(0, 3).split("").join("/");
|
|
103395
103410
|
const specPath = `Specs/${shard2}/${root}/${version2}/${root}.podspec.json`;
|
|
103396
103411
|
const response = await fetch(`https://cdn.cocoapods.org/${specPath}`);
|
|
103397
103412
|
if (!response.ok)
|
|
@@ -103520,7 +103535,7 @@ async function collectSwiftSourcePods(lockFile, modules, moduleRoot, headerModul
|
|
|
103520
103535
|
"end",
|
|
103521
103536
|
""
|
|
103522
103537
|
].join("\n");
|
|
103523
|
-
const key2 = (0,
|
|
103538
|
+
const key2 = (0, import_node_crypto74.createHash)("sha256").update(project).update(podfile).update(JSON.stringify([...selected].sort(([a], [b]) => a.localeCompare(b)))).update(
|
|
103524
103539
|
JSON.stringify(
|
|
103525
103540
|
Object.entries(specificationChecksums).sort(([a], [b]) => a.localeCompare(b))
|
|
103526
103541
|
)
|
|
@@ -103589,11 +103604,11 @@ async function collectSwiftSourcePods(lockFile, modules, moduleRoot, headerModul
|
|
|
103589
103604
|
);
|
|
103590
103605
|
});
|
|
103591
103606
|
}
|
|
103592
|
-
var
|
|
103607
|
+
var import_node_crypto74, import_node_fs122, import_node_path124, APP, record4, project, podModuleName;
|
|
103593
103608
|
var init_swift_source_pods = __esm({
|
|
103594
103609
|
"src/swift-source-pods.ts"() {
|
|
103595
103610
|
"use strict";
|
|
103596
|
-
|
|
103611
|
+
import_node_crypto74 = require("node:crypto");
|
|
103597
103612
|
import_node_fs122 = __toESM(require("node:fs"), 1);
|
|
103598
103613
|
import_node_path124 = __toESM(require("node:path"), 1);
|
|
103599
103614
|
init_browser();
|
|
@@ -104270,7 +104285,7 @@ async function prepareNitroCompileInput(options2) {
|
|
|
104270
104285
|
input.libraries ??= {};
|
|
104271
104286
|
input.libraries[nitroProviderTarget({ name: name3 })] = library;
|
|
104272
104287
|
}
|
|
104273
|
-
const key2 = (0,
|
|
104288
|
+
const key2 = (0, import_node_crypto75.createHash)("sha256").update(
|
|
104274
104289
|
collection.providers.map(({ root, hybridObjects }) => `${root}\0${hybridObjects.join(",")}`).join("\0")
|
|
104275
104290
|
).update("\0").update(import_node_fs123.default.realpathSync(options2.moduleRoot)).update("\0").update(options2.configuration).digest("hex");
|
|
104276
104291
|
const packagePath = import_node_path125.default.join(import_node_os26.default.tmpdir(), "peach-nitro-swift", key2, `p${process.pid}`);
|
|
@@ -104327,11 +104342,11 @@ function nitrogenGeneratedSources(podDirectory) {
|
|
|
104327
104342
|
...sources(import_node_path125.default.join(generated, "ios"), /\.(h|hpp|c|cpp|mm|swift)$/)
|
|
104328
104343
|
];
|
|
104329
104344
|
}
|
|
104330
|
-
var
|
|
104345
|
+
var import_node_crypto75, import_node_fs123, import_node_os26, import_node_path125, BUNDLED_CXX_NAMESPACES, REACT_INCLUDE_PATTERN, REACT_LINKING_PATTERN, REACT_VERSION_PATTERN, RN_HEADER_DIR_MAP, RN_COMMON_ROOTS;
|
|
104331
104346
|
var init_nitro_compile = __esm({
|
|
104332
104347
|
"src/nitro-compile.ts"() {
|
|
104333
104348
|
"use strict";
|
|
104334
|
-
|
|
104349
|
+
import_node_crypto75 = require("node:crypto");
|
|
104335
104350
|
import_node_fs123 = __toESM(require("node:fs"), 1);
|
|
104336
104351
|
import_node_os26 = __toESM(require("node:os"), 1);
|
|
104337
104352
|
import_node_path125 = __toESM(require("node:path"), 1);
|
|
@@ -104408,11 +104423,11 @@ var init_nitro_compile = __esm({
|
|
|
104408
104423
|
});
|
|
104409
104424
|
|
|
104410
104425
|
// src/nitro-compiler-digest.ts
|
|
104411
|
-
var
|
|
104426
|
+
var import_node_crypto76, import_node_fs124, import_node_path126;
|
|
104412
104427
|
var init_nitro_compiler_digest = __esm({
|
|
104413
104428
|
"src/nitro-compiler-digest.ts"() {
|
|
104414
104429
|
"use strict";
|
|
104415
|
-
|
|
104430
|
+
import_node_crypto76 = require("node:crypto");
|
|
104416
104431
|
import_node_fs124 = require("node:fs");
|
|
104417
104432
|
import_node_path126 = __toESM(require("node:path"), 1);
|
|
104418
104433
|
init_swift_compiler_digest();
|
|
@@ -104433,7 +104448,7 @@ function hashPackageTree(root, options2) {
|
|
|
104433
104448
|
}
|
|
104434
104449
|
};
|
|
104435
104450
|
walk4(root, "");
|
|
104436
|
-
const hash = (0,
|
|
104451
|
+
const hash = (0, import_node_crypto77.createHash)("sha256");
|
|
104437
104452
|
return (async () => {
|
|
104438
104453
|
for (let start = 0; start < files2.length; start += READ_AHEAD) {
|
|
104439
104454
|
const batch = files2.slice(start, start + READ_AHEAD);
|
|
@@ -104448,11 +104463,11 @@ function packageTreeDigest(root) {
|
|
|
104448
104463
|
compareNames: (left, right) => left.localeCompare(right)
|
|
104449
104464
|
});
|
|
104450
104465
|
}
|
|
104451
|
-
var
|
|
104466
|
+
var import_node_crypto77, import_node_fs125, import_promises11, import_node_path127, READ_AHEAD;
|
|
104452
104467
|
var init_package_tree_digest = __esm({
|
|
104453
104468
|
"src/package-tree-digest.ts"() {
|
|
104454
104469
|
"use strict";
|
|
104455
|
-
|
|
104470
|
+
import_node_crypto77 = require("node:crypto");
|
|
104456
104471
|
import_node_fs125 = require("node:fs");
|
|
104457
104472
|
import_promises11 = require("node:fs/promises");
|
|
104458
104473
|
import_node_path127 = require("node:path");
|
|
@@ -104591,7 +104606,7 @@ var init_nitro_superset = __esm({
|
|
|
104591
104606
|
init_nitroContract();
|
|
104592
104607
|
init_swift_standin_digest();
|
|
104593
104608
|
NITRO_SUPERSET_ENTRY_NAME = "superset";
|
|
104594
|
-
NITRO_COMPILER_DIGEST = true ? "
|
|
104609
|
+
NITRO_COMPILER_DIGEST = true ? "bdc0f5dd61f31a5b6f5bba3db67fc29584077dfb64bd237228a11b91b9ab2730" : nitroCompilerSourceDigest(__sootsim_import_meta_dirname, STANDIN_SOURCE_DIGEST2);
|
|
104595
104610
|
nitroSupersetLock = parseLock(nitro_superset_lock_default);
|
|
104596
104611
|
nitroSupersetKey = (inputs2) => nativeEntryKey({ ...inputs2, compiler: NITRO_COMPILER_DIGEST });
|
|
104597
104612
|
published = /* @__PURE__ */ new Map();
|
|
@@ -105364,7 +105379,7 @@ async function compilePreparedOneSDKApp(appRoot, preparedRoot, origin, moduleRoo
|
|
|
105364
105379
|
const packagePath = import_node_path130.default.join(
|
|
105365
105380
|
swiftCacheDir(),
|
|
105366
105381
|
"peach-one-sdk-swift",
|
|
105367
|
-
(0,
|
|
105382
|
+
(0, import_node_crypto78.createHash)("sha256").update(import_node_fs128.default.realpathSync(appRoot)).digest("hex").slice(0, 16),
|
|
105368
105383
|
"sdk"
|
|
105369
105384
|
);
|
|
105370
105385
|
const bindingFlags = optimize ? '["-suppress-warnings"]' : '["-suppress-warnings", "-Onone", "-no-whole-module-optimization"]';
|
|
@@ -105411,11 +105426,11 @@ async function buildOneSDKBundle(appRoot) {
|
|
|
105411
105426
|
assets: await compiledModuleAssets(compiled.artifact)
|
|
105412
105427
|
};
|
|
105413
105428
|
}
|
|
105414
|
-
var
|
|
105429
|
+
var import_node_crypto78, import_node_fs128, import_node_path130, ONE_SDK_ROUTE, ONE_SDK_BINDING_SHARDS, ONE_SDK_BINDING_SHARD_MIN_BYTES, handleOneSDKRequest;
|
|
105415
105430
|
var init_one_sdk_bundle = __esm({
|
|
105416
105431
|
"src/one-sdk-bundle.ts"() {
|
|
105417
105432
|
"use strict";
|
|
105418
|
-
|
|
105433
|
+
import_node_crypto78 = require("node:crypto");
|
|
105419
105434
|
import_node_fs128 = __toESM(require("node:fs"), 1);
|
|
105420
105435
|
import_node_path130 = __toESM(require("node:path"), 1);
|
|
105421
105436
|
init_expo_native_workspace();
|
|
@@ -105459,13 +105474,13 @@ var init_expo_eager_seam_contract = __esm({
|
|
|
105459
105474
|
|
|
105460
105475
|
// src/expo-native-compiler-digest.ts
|
|
105461
105476
|
function expoNativeCompilerDigestValue() {
|
|
105462
|
-
return true ? "
|
|
105477
|
+
return true ? "a46618eade53d31c53a3c6377fc86635c03dbcfedd5e131d38b77d9fcc366623" : expoNativeCompilerDigest(__sootsim_import_meta_dirname);
|
|
105463
105478
|
}
|
|
105464
|
-
var
|
|
105479
|
+
var import_node_crypto79;
|
|
105465
105480
|
var init_expo_native_compiler_digest = __esm({
|
|
105466
105481
|
"src/expo-native-compiler-digest.ts"() {
|
|
105467
105482
|
"use strict";
|
|
105468
|
-
|
|
105483
|
+
import_node_crypto79 = require("node:crypto");
|
|
105469
105484
|
init_react_native_core_digest();
|
|
105470
105485
|
init_swift_compiler_digest();
|
|
105471
105486
|
init_swift_standin_digest();
|
|
@@ -105474,7 +105489,7 @@ var init_expo_native_compiler_digest = __esm({
|
|
|
105474
105489
|
|
|
105475
105490
|
// src/expo-discovery-cache.ts
|
|
105476
105491
|
function peachPin() {
|
|
105477
|
-
return (0,
|
|
105492
|
+
return (0, import_node_crypto80.createHash)("sha256").update(
|
|
105478
105493
|
`${FORMAT}\0${expoNativeCompilerDigestValue()}\0${swiftNativePin().distribution.id}\0`
|
|
105479
105494
|
).update(JSON.stringify([...EXPO_EAGER_NATIVE_VIEWS])).update(JSON.stringify([...peachAnsweredNativePackages()].sort())).digest("hex");
|
|
105480
105495
|
}
|
|
@@ -105488,7 +105503,7 @@ function stable(value) {
|
|
|
105488
105503
|
}
|
|
105489
105504
|
async function expoDiscoveryKey(options2) {
|
|
105490
105505
|
const { root, hash } = await hashExpoWorkspace(options2.appRoot, options2.signal);
|
|
105491
|
-
const key2 = (0,
|
|
105506
|
+
const key2 = (0, import_node_crypto80.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");
|
|
105492
105507
|
return { key: key2, root };
|
|
105493
105508
|
}
|
|
105494
105509
|
function expoDiscoveryCacheDir() {
|
|
@@ -105559,7 +105574,7 @@ function readExpoDiscovery(key2) {
|
|
|
105559
105574
|
if (typeof parsed2.archive !== "string" || !isDigest(parsed2.archive)) return void 0;
|
|
105560
105575
|
const archive = import_node_path131.default.join(expoDiscoveryCacheDir(), "blobs", `${parsed2.archive}.zst`);
|
|
105561
105576
|
const bytes = import_node_fs129.default.readFileSync(archive);
|
|
105562
|
-
if ((0,
|
|
105577
|
+
if ((0, import_node_crypto80.createHash)("sha256").update(bytes).digest("hex") !== parsed2.archive)
|
|
105563
105578
|
return void 0;
|
|
105564
105579
|
const bodies = (0, import_node_zlib8.zstdDecompressSync)(bytes);
|
|
105565
105580
|
const decoded = /* @__PURE__ */ new Map();
|
|
@@ -105633,7 +105648,7 @@ function stampedFileHash(file) {
|
|
|
105633
105648
|
const stamp = [stat.dev, stat.ino, stat.size, stat.mtimeNs, stat.ctimeNs].join(":");
|
|
105634
105649
|
const cached2 = fileHashes.get(file);
|
|
105635
105650
|
if (cached2?.stamp === stamp) return cached2.checksum;
|
|
105636
|
-
const checksum = (0,
|
|
105651
|
+
const checksum = (0, import_node_crypto80.createHash)("sha256").update(import_node_fs129.default.readFileSync(file)).digest("hex");
|
|
105637
105652
|
fileHashes.set(file, { stamp, checksum });
|
|
105638
105653
|
fileHashesChanged = true;
|
|
105639
105654
|
return checksum;
|
|
@@ -105642,7 +105657,7 @@ function saveFileHashes() {
|
|
|
105642
105657
|
if (!fileHashesChanged) return;
|
|
105643
105658
|
fileHashesChanged = false;
|
|
105644
105659
|
const target = fileHashesPath();
|
|
105645
|
-
const temporary = `${target}.${process.pid}.${(0,
|
|
105660
|
+
const temporary = `${target}.${process.pid}.${(0, import_node_crypto80.randomUUID)()}.tmp`;
|
|
105646
105661
|
try {
|
|
105647
105662
|
import_node_fs129.default.mkdirSync(import_node_path131.default.dirname(target), { recursive: true });
|
|
105648
105663
|
import_node_fs129.default.writeFileSync(
|
|
@@ -105697,7 +105712,7 @@ function frameworkDigest(directory2, signal) {
|
|
|
105697
105712
|
if (target !== root && !target.startsWith(`${root}${import_node_path131.default.sep}`))
|
|
105698
105713
|
throw new Error(`framework link escapes its tree: ${relative4}`);
|
|
105699
105714
|
}
|
|
105700
|
-
return (0,
|
|
105715
|
+
return (0, import_node_crypto80.createHash)("sha256").update(JSON.stringify([...entries2])).digest("hex");
|
|
105701
105716
|
}
|
|
105702
105717
|
function rewritePreparedPaths(options2) {
|
|
105703
105718
|
const { units, sourceRoot, preparedRoot, signal } = options2;
|
|
@@ -105718,7 +105733,7 @@ function rewritePreparedPaths(options2) {
|
|
|
105718
105733
|
return null;
|
|
105719
105734
|
}
|
|
105720
105735
|
if (!preparedBytes.equals(sourceBytes)) return null;
|
|
105721
|
-
dependencies[sourceFile] = (0,
|
|
105736
|
+
dependencies[sourceFile] = (0, import_node_crypto80.createHash)("sha256").update(sourceBytes).digest("hex");
|
|
105722
105737
|
verifiedFiles.set(preparedFile, sourceFile);
|
|
105723
105738
|
return sourceFile;
|
|
105724
105739
|
};
|
|
@@ -105795,7 +105810,7 @@ function rewritePreparedPaths(options2) {
|
|
|
105795
105810
|
portableDir = import_node_path131.default.join(parent, import_node_path131.default.basename(dir));
|
|
105796
105811
|
if (!import_node_fs129.default.existsSync(portableDir)) {
|
|
105797
105812
|
import_node_fs129.default.mkdirSync(parent, { recursive: true });
|
|
105798
|
-
const tmp = import_node_path131.default.join(parent, `.${process.pid}.${(0,
|
|
105813
|
+
const tmp = import_node_path131.default.join(parent, `.${process.pid}.${(0, import_node_crypto80.randomUUID)()}.tmp`);
|
|
105799
105814
|
try {
|
|
105800
105815
|
import_node_fs129.default.cpSync(dir, tmp, { recursive: true, verbatimSymlinks: true });
|
|
105801
105816
|
if (frameworkDigest(tmp, signal) !== preparedDigest)
|
|
@@ -105824,7 +105839,7 @@ function writeExpoDiscovery(options2) {
|
|
|
105824
105839
|
try {
|
|
105825
105840
|
const dir = expoDiscoveryCacheDir();
|
|
105826
105841
|
import_node_fs129.default.mkdirSync(dir, { recursive: true });
|
|
105827
|
-
const tmp = import_node_path131.default.join(dir, `.${options2.key}.${process.pid}.${(0,
|
|
105842
|
+
const tmp = import_node_path131.default.join(dir, `.${options2.key}.${process.pid}.${(0, import_node_crypto80.randomUUID)()}.tmp`);
|
|
105828
105843
|
if (options2.units === null) {
|
|
105829
105844
|
import_node_fs129.default.writeFileSync(
|
|
105830
105845
|
tmp,
|
|
@@ -105887,8 +105902,8 @@ function writeExpoDiscovery(options2) {
|
|
|
105887
105902
|
}
|
|
105888
105903
|
);
|
|
105889
105904
|
const contents2 = (0, import_node_zlib8.zstdCompressSync)(Buffer.concat(chunks, size2));
|
|
105890
|
-
const archive = (0,
|
|
105891
|
-
const temporary = import_node_path131.default.join(blobDir, "." + (0,
|
|
105905
|
+
const archive = (0, import_node_crypto80.createHash)("sha256").update(contents2).digest("hex");
|
|
105906
|
+
const temporary = import_node_path131.default.join(blobDir, "." + (0, import_node_crypto80.randomUUID)() + ".tmp");
|
|
105892
105907
|
try {
|
|
105893
105908
|
import_node_fs129.default.writeFileSync(temporary, contents2);
|
|
105894
105909
|
import_node_fs129.default.renameSync(temporary, import_node_path131.default.join(blobDir, `${archive}.zst`));
|
|
@@ -105915,11 +105930,11 @@ function writeExpoDiscovery(options2) {
|
|
|
105915
105930
|
return error instanceof Error ? error.message : String(error);
|
|
105916
105931
|
}
|
|
105917
105932
|
}
|
|
105918
|
-
var
|
|
105933
|
+
var import_node_crypto80, import_node_fs129, import_node_path131, import_node_zlib8, FORMAT, EXPIRY_MS, ORPHAN_TEMPORARY_MS, strings4, stringRecord, isDigest, digestRecord, isBodyOffset, isBodyOffsets, sourceLocationLine, fileHashes, fileHashesLoaded, fileHashesChanged, MISSING_TREE;
|
|
105919
105934
|
var init_expo_discovery_cache = __esm({
|
|
105920
105935
|
"src/expo-discovery-cache.ts"() {
|
|
105921
105936
|
"use strict";
|
|
105922
|
-
|
|
105937
|
+
import_node_crypto80 = require("node:crypto");
|
|
105923
105938
|
import_node_fs129 = __toESM(require("node:fs"), 1);
|
|
105924
105939
|
import_node_path131 = __toESM(require("node:path"), 1);
|
|
105925
105940
|
import_node_zlib8 = require("node:zlib");
|
|
@@ -106123,7 +106138,7 @@ async function expoNativeInputs(appRoot) {
|
|
|
106123
106138
|
"swift-pin": JSON.stringify(swiftNativePin()),
|
|
106124
106139
|
answered: JSON.stringify([...peachAnsweredNativePackages()].sort()),
|
|
106125
106140
|
"pods-environment": JSON.stringify(reactNativePodsEnvironment()),
|
|
106126
|
-
fingerprint: (0,
|
|
106141
|
+
fingerprint: (0, import_node_crypto81.createHash)("sha256").update(lines.sort().join("\n")).digest("hex")
|
|
106127
106142
|
},
|
|
106128
106143
|
packages
|
|
106129
106144
|
};
|
|
@@ -106229,7 +106244,7 @@ async function prebuiltAppTarget(appRoot, signal, dependencies = "lockfile") {
|
|
|
106229
106244
|
}
|
|
106230
106245
|
function servedExpoSwift(appRoot, entry, app) {
|
|
106231
106246
|
if (!entry.expoSwift) return null;
|
|
106232
|
-
const rootId = `${(0,
|
|
106247
|
+
const rootId = `${(0, import_node_crypto81.createHash)("sha256").update(import_node_fs131.default.realpathSync(appRoot)).digest("hex")}/Expo`;
|
|
106233
106248
|
if (app.infoPlist === null) throw new Error("the prebuilt app target has no Info.plist");
|
|
106234
106249
|
const installed = installedInfoPlist(app.infoPlist, entry.infoPlist);
|
|
106235
106250
|
const infoPlist2 = Buffer.from(installed).toString("base64");
|
|
@@ -106257,11 +106272,11 @@ async function prebuiltExpoSwiftResult(appRoot, entry, signal) {
|
|
|
106257
106272
|
await prebuiltAppTarget(appRoot, signal, "installed")
|
|
106258
106273
|
);
|
|
106259
106274
|
}
|
|
106260
|
-
var
|
|
106275
|
+
var import_node_crypto81, import_node_fs131, import_node_module18, import_node_path133, import_node_util17, EXPO_NATIVE_ENTRY_NAME, IDENTITY_SOURCE_SKIPS, expoNativeEntryUrl, isStringRecord, isPlistArray, published2, lookups, answers;
|
|
106261
106276
|
var init_expo_native_prebuilt = __esm({
|
|
106262
106277
|
"src/expo-native-prebuilt.ts"() {
|
|
106263
106278
|
"use strict";
|
|
106264
|
-
|
|
106279
|
+
import_node_crypto81 = require("node:crypto");
|
|
106265
106280
|
import_node_fs131 = __toESM(require("node:fs"), 1);
|
|
106266
106281
|
import_node_module18 = require("node:module");
|
|
106267
106282
|
import_node_path133 = __toESM(require("node:path"), 1);
|
|
@@ -106875,7 +106890,7 @@ function exportedNames(moduleRoot, name3) {
|
|
|
106875
106890
|
const modules = import_node_path135.default.join(moduleRoot, "modules");
|
|
106876
106891
|
const module2 = import_node_path135.default.join(modules, `${name3}.swiftmodule`);
|
|
106877
106892
|
if (!import_node_fs133.default.existsSync(module2)) return /* @__PURE__ */ new Set();
|
|
106878
|
-
const key2 = (0,
|
|
106893
|
+
const key2 = (0, import_node_crypto82.createHash)("sha256").update(import_node_fs133.default.readFileSync(module2)).digest("hex");
|
|
106879
106894
|
const directory2 = import_node_path135.default.join(swiftCacheDir(), "swift-public-names");
|
|
106880
106895
|
const receipt = import_node_path135.default.join(directory2, `${key2}.json`);
|
|
106881
106896
|
if (import_node_fs133.default.existsSync(receipt)) {
|
|
@@ -106958,12 +106973,12 @@ function clangTypeOwnership(moduleRoot, module2) {
|
|
|
106958
106973
|
}
|
|
106959
106974
|
);
|
|
106960
106975
|
}
|
|
106961
|
-
var import_node_child_process64,
|
|
106976
|
+
var import_node_child_process64, import_node_crypto82, import_node_fs133, import_node_path135, blockTypedef, enumTypedef, enumConstant, swiftPrivate;
|
|
106962
106977
|
var init_swift_clang_type_ownership = __esm({
|
|
106963
106978
|
"src/swift-clang-type-ownership.ts"() {
|
|
106964
106979
|
"use strict";
|
|
106965
106980
|
import_node_child_process64 = require("node:child_process");
|
|
106966
|
-
|
|
106981
|
+
import_node_crypto82 = require("node:crypto");
|
|
106967
106982
|
import_node_fs133 = __toESM(require("node:fs"), 1);
|
|
106968
106983
|
import_node_path135 = __toESM(require("node:path"), 1);
|
|
106969
106984
|
init_is_record();
|
|
@@ -108606,7 +108621,7 @@ function targetSettings2(units) {
|
|
|
108606
108621
|
}
|
|
108607
108622
|
function oneSDKStamp(oneSDK) {
|
|
108608
108623
|
if (!oneSDK) return "";
|
|
108609
|
-
const hash = (0,
|
|
108624
|
+
const hash = (0, import_node_crypto83.createHash)("sha256");
|
|
108610
108625
|
for (const files2 of [oneSDK.targets, oneSDK.entry])
|
|
108611
108626
|
for (const [name3, source] of [...files2].sort(([a], [b]) => a.localeCompare(b)))
|
|
108612
108627
|
hash.update(`${name3}\0${source}\0`);
|
|
@@ -108657,7 +108672,7 @@ ${bridgeModules.length ? "import React\n" : ""}${oneSDK ? "import One\nimport On
|
|
|
108657
108672
|
`;
|
|
108658
108673
|
}
|
|
108659
108674
|
function expoSwiftPreparedKey(base2, units, reactProviderStamp) {
|
|
108660
|
-
const hash = (0,
|
|
108675
|
+
const hash = (0, import_node_crypto83.createHash)("sha256");
|
|
108661
108676
|
hash.update(base2);
|
|
108662
108677
|
hash.update(reactProviderStamp);
|
|
108663
108678
|
for (const unit2 of units) {
|
|
@@ -109031,8 +109046,8 @@ async function compileExpoSwiftModulesTraced(root, base2, publishArtifact, optio
|
|
|
109031
109046
|
}
|
|
109032
109047
|
return provider;
|
|
109033
109048
|
})() : void 0;
|
|
109034
|
-
const reactProviderStamp = reactProvider ? (0,
|
|
109035
|
-
const key2 = (0,
|
|
109049
|
+
const reactProviderStamp = reactProvider ? (0, import_node_crypto83.createHash)("sha256").update(JSON.stringify(reactProvider)).digest("hex") : "";
|
|
109050
|
+
const key2 = (0, import_node_crypto83.createHash)("sha256").update(import_node_fs134.default.realpathSync(root)).digest("hex");
|
|
109036
109051
|
const unitContentStamp = (unit2) => sourceContentStamp(expoSwiftPackage(key2, unit2.moduleId), module2.root) + (unit2.reactNativeProvider ? `:${reactProviderStamp}` : "");
|
|
109037
109052
|
const failures = /* @__PURE__ */ new Map();
|
|
109038
109053
|
const failureRecords = /* @__PURE__ */ new Map();
|
|
@@ -109374,13 +109389,13 @@ async function compileExpoSwiftModulesTraced(root, base2, publishArtifact, optio
|
|
|
109374
109389
|
throw failure2;
|
|
109375
109390
|
}
|
|
109376
109391
|
}
|
|
109377
|
-
var import_node_async_hooks3, import_node_child_process65,
|
|
109392
|
+
var import_node_async_hooks3, import_node_child_process65, import_node_crypto83, import_node_fs134, import_node_module20, import_node_os28, import_node_path136, import_node_url4, import_node_util18, run11, scriptEnv, EXPO_SWIFT_ENTRY, WITNESS_BATCH, traceStore, discoveryCache, preparedCache, savedFs, ignoredRoots, ownTemporaryRoots, EXPO_MODULE_SCAN_TIMEOUT_MS, preparedExpoSwift, openPreparations, ExpoSwiftLinkRefusal;
|
|
109378
109393
|
var init_expo_swift_host = __esm({
|
|
109379
109394
|
"src/expo-swift-host.ts"() {
|
|
109380
109395
|
"use strict";
|
|
109381
109396
|
import_node_async_hooks3 = require("node:async_hooks");
|
|
109382
109397
|
import_node_child_process65 = require("node:child_process");
|
|
109383
|
-
|
|
109398
|
+
import_node_crypto83 = require("node:crypto");
|
|
109384
109399
|
import_node_fs134 = __toESM(require("node:fs"), 1);
|
|
109385
109400
|
import_node_module20 = require("node:module");
|
|
109386
109401
|
import_node_os28 = __toESM(require("node:os"), 1);
|
|
@@ -109708,7 +109723,7 @@ async function resolveAndroidGradleSources(request) {
|
|
|
109708
109723
|
const parent = import_node_path139.default.join(kotlinHome(), "gradle-sources");
|
|
109709
109724
|
import_node_fs136.default.mkdirSync(parent, { recursive: true });
|
|
109710
109725
|
const work = import_node_fs136.default.mkdtempSync(import_node_path139.default.join(parent, ".query-"));
|
|
109711
|
-
const task = `peachAndroidSources${(0,
|
|
109726
|
+
const task = `peachAndroidSources${(0, import_node_crypto84.randomBytes)(8).toString("hex")}`;
|
|
109712
109727
|
const script = import_node_path139.default.join(work, "sources.gradle");
|
|
109713
109728
|
const encoded = Buffer.from(
|
|
109714
109729
|
JSON.stringify({
|
|
@@ -109860,12 +109875,12 @@ function readDependencySources(value) {
|
|
|
109860
109875
|
};
|
|
109861
109876
|
});
|
|
109862
109877
|
}
|
|
109863
|
-
var import_node_child_process66,
|
|
109878
|
+
var import_node_child_process66, import_node_crypto84, import_node_fs136, import_node_path139, import_node_util19, run12, modelQuery;
|
|
109864
109879
|
var init_android_gradle_sources = __esm({
|
|
109865
109880
|
"src/android-gradle-sources.ts"() {
|
|
109866
109881
|
"use strict";
|
|
109867
109882
|
import_node_child_process66 = require("node:child_process");
|
|
109868
|
-
|
|
109883
|
+
import_node_crypto84 = require("node:crypto");
|
|
109869
109884
|
import_node_fs136 = __toESM(require("node:fs"), 1);
|
|
109870
109885
|
import_node_path139 = __toESM(require("node:path"), 1);
|
|
109871
109886
|
import_node_util19 = require("node:util");
|
|
@@ -110253,7 +110268,7 @@ var init_android_bridge_packages = __esm({
|
|
|
110253
110268
|
|
|
110254
110269
|
// src/java-module-abi.ts
|
|
110255
110270
|
async function readJavaModuleSpecs(files2, sdkRoot, toolchain) {
|
|
110256
|
-
const digest3 = (0,
|
|
110271
|
+
const digest3 = (0, import_node_crypto85.createHash)("sha256");
|
|
110257
110272
|
const parent = import_node_path141.default.join(kotlinHome(), "java-specs");
|
|
110258
110273
|
import_node_fs138.default.mkdirSync(parent, { recursive: true });
|
|
110259
110274
|
const work = import_node_fs138.default.mkdtempSync(import_node_path141.default.join(parent, ".read-"));
|
|
@@ -110350,12 +110365,12 @@ async function compileJavaModuleAbi(input) {
|
|
|
110350
110365
|
);
|
|
110351
110366
|
return library;
|
|
110352
110367
|
}
|
|
110353
|
-
var import_node_child_process67,
|
|
110368
|
+
var import_node_child_process67, import_node_crypto85, import_node_fs138, import_node_path141, import_node_util20, run13, JAVA_BINDINGS_INITIALIZER;
|
|
110354
110369
|
var init_java_module_abi = __esm({
|
|
110355
110370
|
"src/java-module-abi.ts"() {
|
|
110356
110371
|
"use strict";
|
|
110357
110372
|
import_node_child_process67 = require("node:child_process");
|
|
110358
|
-
|
|
110373
|
+
import_node_crypto85 = require("node:crypto");
|
|
110359
110374
|
import_node_fs138 = __toESM(require("node:fs"), 1);
|
|
110360
110375
|
import_node_path141 = __toESM(require("node:path"), 1);
|
|
110361
110376
|
import_node_util20 = require("node:util");
|
|
@@ -110463,13 +110478,13 @@ function verifyKotlinSdkDirectory(root, compiler) {
|
|
|
110463
110478
|
if (!stat.isFile() || stat.nlink !== 1)
|
|
110464
110479
|
throw new Error(`Kotlin SDK binary is not a regular file: ${name3}`);
|
|
110465
110480
|
const bytes = import_node_fs139.default.readFileSync(target);
|
|
110466
|
-
if (bytes.length !== expected.bytes || (0,
|
|
110481
|
+
if (bytes.length !== expected.bytes || (0, import_node_crypto86.createHash)("sha256").update(bytes).digest("hex") !== expected.sha256)
|
|
110467
110482
|
throw new Error(`Kotlin SDK binary differs from its manifest: ${name3}`);
|
|
110468
110483
|
}
|
|
110469
110484
|
return manifest;
|
|
110470
110485
|
}
|
|
110471
110486
|
async function installKotlinSdkArchive(archive, compiler) {
|
|
110472
|
-
const sha2565 = (0,
|
|
110487
|
+
const sha2565 = (0, import_node_crypto86.createHash)("sha256").update(archive).digest("hex");
|
|
110473
110488
|
const parent = import_node_path142.default.join(kotlinHome(), "sdk");
|
|
110474
110489
|
const root = import_node_path142.default.join(parent, sha2565);
|
|
110475
110490
|
if (import_node_fs139.default.existsSync(root))
|
|
@@ -110498,12 +110513,12 @@ async function installKotlinSdkArchive(archive, compiler) {
|
|
|
110498
110513
|
import_node_fs139.default.rmSync(work, { recursive: true, force: true });
|
|
110499
110514
|
}
|
|
110500
110515
|
}
|
|
110501
|
-
var import_node_child_process68,
|
|
110516
|
+
var import_node_child_process68, import_node_crypto86, import_node_fs139, import_node_path142, import_node_util21, run14;
|
|
110502
110517
|
var init_kotlin_sdk = __esm({
|
|
110503
110518
|
"src/kotlin-sdk.ts"() {
|
|
110504
110519
|
"use strict";
|
|
110505
110520
|
import_node_child_process68 = require("node:child_process");
|
|
110506
|
-
|
|
110521
|
+
import_node_crypto86 = require("node:crypto");
|
|
110507
110522
|
import_node_fs139 = __toESM(require("node:fs"), 1);
|
|
110508
110523
|
import_node_path142 = __toESM(require("node:path"), 1);
|
|
110509
110524
|
import_node_util21 = require("node:util");
|
|
@@ -110606,7 +110621,7 @@ function peachKotlinModuleRoot() {
|
|
|
110606
110621
|
if (!IS_STANDALONE) return import_node_path144.default.join(peachsimPackageRoot(), "kotlin");
|
|
110607
110622
|
if (installedRoot) return installedRoot;
|
|
110608
110623
|
const files2 = JSON.parse(__PEACH_BUNDLED_KOTLIN__);
|
|
110609
|
-
const digest3 = (0,
|
|
110624
|
+
const digest3 = (0, import_node_crypto87.createHash)("sha256").update(__PEACH_BUNDLED_KOTLIN__).digest("hex");
|
|
110610
110625
|
const parent = import_node_path144.default.join(rnxHomeDir(), "kotlin", "modules");
|
|
110611
110626
|
const root = import_node_path144.default.join(parent, digest3);
|
|
110612
110627
|
import_node_fs141.default.mkdirSync(parent, { recursive: true });
|
|
@@ -110635,11 +110650,11 @@ function peachKotlinModuleRoot() {
|
|
|
110635
110650
|
installedRoot = root;
|
|
110636
110651
|
return root;
|
|
110637
110652
|
}
|
|
110638
|
-
var
|
|
110653
|
+
var import_node_crypto87, import_node_fs141, import_node_path144, installedRoot;
|
|
110639
110654
|
var init_kotlin_module = __esm({
|
|
110640
110655
|
"src/kotlin-module.ts"() {
|
|
110641
110656
|
"use strict";
|
|
110642
|
-
|
|
110657
|
+
import_node_crypto87 = require("node:crypto");
|
|
110643
110658
|
import_node_fs141 = __toESM(require("node:fs"), 1);
|
|
110644
110659
|
import_node_path144 = __toESM(require("node:path"), 1);
|
|
110645
110660
|
init_standalone();
|
|
@@ -111002,7 +111017,7 @@ function zipSources(bytes, where) {
|
|
|
111002
111017
|
return entries2;
|
|
111003
111018
|
}
|
|
111004
111019
|
function extract(bytes, where) {
|
|
111005
|
-
const key2 = (0,
|
|
111020
|
+
const key2 = (0, import_node_crypto88.createHash)("sha256").update(bytes).digest("hex");
|
|
111006
111021
|
const cached2 = pending.get(key2);
|
|
111007
111022
|
if (cached2) return cached2;
|
|
111008
111023
|
const request = (async () => {
|
|
@@ -111051,11 +111066,11 @@ function readSourcesJar(archive, where) {
|
|
|
111051
111066
|
function readMavenSourcesArchive(archive) {
|
|
111052
111067
|
return extract(readSourcesJar(archive, archive), archive);
|
|
111053
111068
|
}
|
|
111054
|
-
var
|
|
111069
|
+
var import_node_crypto88, import_node_fs143, import_node_os29, import_node_path146, import_node_zlib9, pending, MAX_SOURCES_JAR_BYTES, MAX_SOURCE_ENTRY_BYTES, MAX_TOTAL_EXTRACTED_BYTES;
|
|
111055
111070
|
var init_kotlin_maven_sources = __esm({
|
|
111056
111071
|
"src/kotlin-maven-sources.ts"() {
|
|
111057
111072
|
"use strict";
|
|
111058
|
-
|
|
111073
|
+
import_node_crypto88 = require("node:crypto");
|
|
111059
111074
|
import_node_fs143 = __toESM(require("node:fs"), 1);
|
|
111060
111075
|
import_node_os29 = __toESM(require("node:os"), 1);
|
|
111061
111076
|
import_node_path146 = __toESM(require("node:path"), 1);
|
|
@@ -111096,7 +111111,7 @@ async function compileKotlinGradleLibraries(input) {
|
|
|
111096
111111
|
])
|
|
111097
111112
|
];
|
|
111098
111113
|
const name3 = library.coordinate.replace(/[^a-zA-Z0-9._-]/g, "-");
|
|
111099
|
-
const suffix = (0,
|
|
111114
|
+
const suffix = (0, import_node_crypto89.createHash)("sha256").update(library.coordinate).digest("hex").slice(0, 12);
|
|
111100
111115
|
const klib = import_node_path147.default.join(input.output, `${name3}-${suffix}.klib`);
|
|
111101
111116
|
const kotlinJvmAbi = java.length && kotlin.length && library.jars.length === 1 ? library.jars[0] : void 0;
|
|
111102
111117
|
const abiPairs = java.length ? dependencies.flatMap(
|
|
@@ -111138,11 +111153,11 @@ async function compileKotlinGradleLibraries(input) {
|
|
|
111138
111153
|
}
|
|
111139
111154
|
return [...compiled.values()].map(({ klib }) => klib);
|
|
111140
111155
|
}
|
|
111141
|
-
var
|
|
111156
|
+
var import_node_crypto89, import_node_fs144, import_node_path147;
|
|
111142
111157
|
var init_kotlin_gradle_library_plan = __esm({
|
|
111143
111158
|
"src/kotlin-gradle-library-plan.ts"() {
|
|
111144
111159
|
"use strict";
|
|
111145
|
-
|
|
111160
|
+
import_node_crypto89 = require("node:crypto");
|
|
111146
111161
|
import_node_fs144 = __toESM(require("node:fs"), 1);
|
|
111147
111162
|
import_node_path147 = __toESM(require("node:path"), 1);
|
|
111148
111163
|
init_kotlin_library_sources();
|
|
@@ -111599,7 +111614,7 @@ function readExpoTypes(output) {
|
|
|
111599
111614
|
});
|
|
111600
111615
|
}
|
|
111601
111616
|
async function scanSources(tool, parse16, toolchain, moduleRoot, files2) {
|
|
111602
|
-
const digest3 = (0,
|
|
111617
|
+
const digest3 = (0, import_node_crypto90.createHash)("sha256").update(JSON.stringify(toolchain.compiler));
|
|
111603
111618
|
const sdk2 = await loadKotlinSdk(moduleRoot, toolchain);
|
|
111604
111619
|
digest3.update(import_node_fs145.default.readFileSync(import_node_path148.default.join(moduleRoot, "sdk.tar.gz")));
|
|
111605
111620
|
digest3.update(tool);
|
|
@@ -112261,7 +112276,7 @@ async function compileKotlin(input, origin) {
|
|
|
112261
112276
|
bytes: import_node_fs145.default.readFileSync(file)
|
|
112262
112277
|
}));
|
|
112263
112278
|
const { composeArchive, ...compilerInputs } = toolchain;
|
|
112264
|
-
const digest3 = (0,
|
|
112279
|
+
const digest3 = (0, import_node_crypto90.createHash)("sha256");
|
|
112265
112280
|
digest3.update(
|
|
112266
112281
|
JSON.stringify({
|
|
112267
112282
|
format: BUILD_FORMAT,
|
|
@@ -112283,7 +112298,7 @@ async function compileKotlin(input, origin) {
|
|
|
112283
112298
|
...gradleLibraries.libraries.flatMap(({ archive, jars }) => [archive, ...jars])
|
|
112284
112299
|
]);
|
|
112285
112300
|
for (const file of files2) {
|
|
112286
|
-
digest3.update((0,
|
|
112301
|
+
digest3.update((0, import_node_crypto90.createHash)("sha256").update(import_node_fs145.default.readFileSync(file)).digest());
|
|
112287
112302
|
}
|
|
112288
112303
|
}
|
|
112289
112304
|
if (viewModels) digest3.update(viewModels.toolClass);
|
|
@@ -112575,12 +112590,12 @@ async function serveKotlinRequest(pathname, res, app) {
|
|
|
112575
112590
|
}
|
|
112576
112591
|
return true;
|
|
112577
112592
|
}
|
|
112578
|
-
var import_node_child_process70,
|
|
112593
|
+
var import_node_child_process70, import_node_crypto90, import_node_fs145, import_node_module23, import_node_path148, import_node_util22, run15, KOTLIN_ARTIFACT_PREFIX, SKIP_DIRS, configureDeviceSource, BUILD_FORMAT, builds, toolScans, BRIDGE_PARAMETERS, BRIDGE_CASTS, BRIDGE_RETURNS, bridgeType, JAVA_CLASSES, argb, escapes2, literal2, CONTENT_TYPES;
|
|
112579
112594
|
var init_kotlin_host = __esm({
|
|
112580
112595
|
"src/kotlin-host.ts"() {
|
|
112581
112596
|
"use strict";
|
|
112582
112597
|
import_node_child_process70 = require("node:child_process");
|
|
112583
|
-
|
|
112598
|
+
import_node_crypto90 = require("node:crypto");
|
|
112584
112599
|
import_node_fs145 = __toESM(require("node:fs"), 1);
|
|
112585
112600
|
import_node_module23 = require("node:module");
|
|
112586
112601
|
import_node_path148 = __toESM(require("node:path"), 1);
|
|
@@ -113410,7 +113425,7 @@ __export(bundle_channel_exports, {
|
|
|
113410
113425
|
snapshotOneProductionBundle: () => snapshotOneProductionBundle
|
|
113411
113426
|
});
|
|
113412
113427
|
module.exports = __toCommonJS(bundle_channel_exports);
|
|
113413
|
-
var
|
|
113428
|
+
var import_node_crypto92 = require("node:crypto");
|
|
113414
113429
|
var import_node_fs152 = require("node:fs");
|
|
113415
113430
|
var import_node_path156 = require("node:path");
|
|
113416
113431
|
var import_node_vm = require("node:vm");
|
|
@@ -113586,7 +113601,7 @@ init_expo_native_workspace();
|
|
|
113586
113601
|
|
|
113587
113602
|
// src/host/staged-host-files.ts
|
|
113588
113603
|
var import_node_async_hooks4 = require("node:async_hooks");
|
|
113589
|
-
var
|
|
113604
|
+
var import_node_crypto91 = require("node:crypto");
|
|
113590
113605
|
var import_node_fs147 = __toESM(require("node:fs"), 1);
|
|
113591
113606
|
var import_node_path150 = __toESM(require("node:path"), 1);
|
|
113592
113607
|
|
|
@@ -113681,10 +113696,10 @@ function stageHostBytes(bytes, origin, extension = "") {
|
|
|
113681
113696
|
}
|
|
113682
113697
|
async function stageHostDerivedBytes(input, producer, origin, extension, derive) {
|
|
113683
113698
|
const directory2 = prepareStagedDirectory();
|
|
113684
|
-
const inputDigest = (0,
|
|
113699
|
+
const inputDigest = (0, import_node_crypto91.createHash)("sha256").update(input).digest("hex");
|
|
113685
113700
|
const index = import_node_path150.default.join(
|
|
113686
113701
|
directory2,
|
|
113687
|
-
`derived-${(0,
|
|
113702
|
+
`derived-${(0, import_node_crypto91.createHash)("sha256").update(`${producer}\0${inputDigest}`).digest("hex")}`
|
|
113688
113703
|
);
|
|
113689
113704
|
const recorded = import_node_fs147.default.existsSync(index) ? import_node_fs147.default.readFileSync(index, "utf8") : "";
|
|
113690
113705
|
if (STAGED_NAME.test(recorded) && import_node_fs147.default.existsSync(import_node_path150.default.join(directory2, recorded))) {
|
|
@@ -113695,7 +113710,7 @@ async function stageHostDerivedBytes(input, producer, origin, extension, derive)
|
|
|
113695
113710
|
return new URL(STAGED_PREFIX + recorded, origin).toString();
|
|
113696
113711
|
}
|
|
113697
113712
|
const staged = writeStagedBytes(await derive(), origin, extension, directory2);
|
|
113698
|
-
const temporary = import_node_path150.default.join(directory2, (0,
|
|
113713
|
+
const temporary = import_node_path150.default.join(directory2, (0, import_node_crypto91.randomUUID)());
|
|
113699
113714
|
try {
|
|
113700
113715
|
import_node_fs147.default.writeFileSync(temporary, new URL(staged).pathname.slice(STAGED_PREFIX.length), {
|
|
113701
113716
|
flag: "wx"
|
|
@@ -113720,7 +113735,7 @@ function prepareStagedDirectory() {
|
|
|
113720
113735
|
return directory2;
|
|
113721
113736
|
}
|
|
113722
113737
|
function writeStagedBytes(bytes, origin, extension, directory2) {
|
|
113723
|
-
const digest3 = (0,
|
|
113738
|
+
const digest3 = (0, import_node_crypto91.createHash)("sha256").update(bytes).digest("hex");
|
|
113724
113739
|
extension = extension.toLowerCase();
|
|
113725
113740
|
const name3 = STAGED_NAME.test(digest3 + extension) ? digest3 + extension : digest3;
|
|
113726
113741
|
stagedCapture.getStore()?.add(name3);
|
|
@@ -113729,7 +113744,7 @@ function writeStagedBytes(bytes, origin, extension, directory2) {
|
|
|
113729
113744
|
if (import_node_fs147.default.existsSync(destination)) {
|
|
113730
113745
|
import_node_fs147.default.utimesSync(destination, new Date(now), new Date(now));
|
|
113731
113746
|
} else {
|
|
113732
|
-
const temporary = import_node_path150.default.join(directory2, (0,
|
|
113747
|
+
const temporary = import_node_path150.default.join(directory2, (0, import_node_crypto91.randomUUID)());
|
|
113733
113748
|
try {
|
|
113734
113749
|
import_node_fs147.default.writeFileSync(temporary, bytes, { flag: "wx" });
|
|
113735
113750
|
import_node_fs147.default.renameSync(temporary, destination);
|
|
@@ -114026,7 +114041,7 @@ async function discoverProjectOneNativeAppCatalog(projectRoot, assetOrigin) {
|
|
|
114026
114041
|
}
|
|
114027
114042
|
|
|
114028
114043
|
// src/bundle-channel.mjs
|
|
114029
|
-
var digest2 = (bytes) => (0,
|
|
114044
|
+
var digest2 = (bytes) => (0, import_node_crypto92.createHash)("sha256").update(bytes).digest("hex");
|
|
114030
114045
|
var segment2 = /^[a-zA-Z0-9._-]+$/;
|
|
114031
114046
|
function packagedAssetDirectory(location) {
|
|
114032
114047
|
const parsed2 = new URL(location, "https://packaged.invalid");
|
|
@@ -114132,7 +114147,7 @@ async function prepareChannel({
|
|
|
114132
114147
|
files2.set(asset.path, asset.bytes);
|
|
114133
114148
|
}
|
|
114134
114149
|
}
|
|
114135
|
-
const identity2 = (0,
|
|
114150
|
+
const identity2 = (0, import_node_crypto92.createHash)("sha256").update(bundle).update(icon);
|
|
114136
114151
|
for (const [path143, bytes] of [...files2].sort(
|
|
114137
114152
|
([a], [b]) => a < b ? -1 : a > b ? 1 : 0
|
|
114138
114153
|
)) {
|