peachsim 0.1.2248 → 0.1.2250
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cli/bridge-flow-runner.ts +30 -3
- package/cli/commands/flow.ts +4 -1
- package/cli/commands/inspect/settling.ts +35 -4
- package/cli/drivers/playwright.ts +2 -0
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.cjs +1 -1
- package/dist-lib/attached-projects.cjs +1 -1
- package/dist-lib/auth/shared-session.cjs +1 -1
- package/dist-lib/backend-origin.cjs +1 -1
- package/dist-lib/beta.cjs +1 -1
- package/dist-lib/beta.mjs +1 -1
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +1 -1
- package/dist-lib/bridge-contract-input.mjs +1 -1
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +1 -1
- package/dist-lib/bundle-channel.cjs +203 -53
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +1 -1
- package/dist-lib/cloud-contract.cjs +1 -1
- package/dist-lib/cloud-contract.mjs +1 -1
- package/dist-lib/cloud-test-args.cjs +1 -1
- package/dist-lib/cloud-test-args.mjs +1 -1
- package/dist-lib/cloud.cjs +1 -1
- package/dist-lib/cloud.mjs +1 -1
- package/dist-lib/config.cjs +1 -1
- package/dist-lib/config.mjs +1 -1
- package/dist-lib/detox/index.cjs +33 -9
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/expo-swift-bundle.cjs +177 -49
- package/dist-lib/expo-swift-metadata.cjs +1 -1
- package/dist-lib/expo-swift-metadata.mjs +1 -1
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +210 -54
- package/dist-lib/host/fetch-proxy-handler.cjs +4 -4
- package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
- package/dist-lib/host/replacement-module-handler.cjs +1 -1
- package/dist-lib/host/websocket-proxy.cjs +1 -1
- package/dist-lib/index.cjs +45 -14
- package/dist-lib/jump-to-source-babel.cjs +1 -1
- package/dist-lib/jump-to-source-native.cjs +1 -1
- package/dist-lib/kotlin-host.cjs +1 -1
- package/dist-lib/menu.cjs +1 -1
- package/dist-lib/menu.mjs +1 -1
- package/dist-lib/metro-fingerprint-registry.cjs +1 -1
- package/dist-lib/metro-fingerprint-registry.mjs +1 -1
- package/dist-lib/metro-production-bundle.cjs +1 -1
- package/dist-lib/metro-production-bundle.mjs +1 -1
- package/dist-lib/metro.cjs +15 -8
- package/dist-lib/native-app-identity-project.cjs +2 -2
- package/dist-lib/native-app-identity-project.mjs +2 -2
- package/dist-lib/native-app-identity.cjs +1 -1
- package/dist-lib/native-app-identity.mjs +1 -1
- package/dist-lib/native-firebase-metadata.cjs +1 -1
- package/dist-lib/native-firebase-metadata.mjs +1 -1
- package/dist-lib/pdfium-raster.cjs +1 -1
- package/dist-lib/pdfium-raster.mjs +1 -1
- package/dist-lib/plist.cjs +1 -1
- package/dist-lib/plist.mjs +1 -1
- package/dist-lib/profiles.cjs +1 -1
- package/dist-lib/public-brand.cjs +1 -1
- package/dist-lib/public-origins-lib-esm.json +24 -24
- package/dist-lib/public-origins-lib.json +53 -53
- package/dist-lib/react-native-host-modules.cjs +1 -1
- package/dist-lib/react-native-host-modules.mjs +1 -1
- package/dist-lib/reap-browser.cjs +2 -2
- package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
- package/dist-lib/sdk.cjs +31 -7
- package/dist-lib/sdk.mjs +31 -7
- package/dist-lib/skills.cjs +289 -64
- package/dist-lib/swift-compile.cjs +165 -38
- package/dist-lib/swift-compile.mjs +165 -38
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +1 -1
- package/dist-lib/swift-submit.cjs +1 -1
- package/dist-lib/swift-submit.mjs +1 -1
- package/dist-lib/swift-toolchain.cjs +1 -1
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vite-swift.cjs +174 -46
- package/dist-lib/vite.cjs +15 -8
- package/dist-lib/worklet-executable.cjs +1 -1
- package/dist-lib/worklet-executable.mjs +1 -1
- package/dist-types/packages/peach-engine/src/render-worker/compositor-protocol.d.ts +4 -0
- package/dist-types/packages/peach-engine/src/render-worker/image-pixel-contract.d.ts +0 -4
- package/dist-types/packages/peach-engine/src/render-worker/native-ui-protocol.d.ts +1 -0
- package/dist-types/packages/peach-engine/src/render-worker/shell-tree-wire.d.ts +8 -0
- package/dist-types/packages/peach-engine/src/render-worker/webview-capture-protocol.d.ts +1 -0
- package/dist-types/packages/peach-globals/src/globalsContract.d.ts +5 -0
- package/kotlin/sdk.tar.gz +0 -0
- package/package.json +1 -1
- package/runtime-companion.json +1 -1
- package/sdk/ios/wasm/include/math.h +1 -1
- package/sdk/ios/wasm/include/pthread.h +1 -1
- package/src/assetCatalogContract.ts +6 -0
- package/src/nitro-compile.ts +23 -1
- package/src/process-group.ts +5 -2
- package/src/runtime-packs.ts +8 -0
- package/src/sfSymbolMetricsContract.ts +73 -37
- package/src/swift-compile.ts +119 -13
- package/src/swift-guest-image-ledger.ts +10 -5
- package/src/swift-guest-link.ts +20 -14
- package/src/swift-guest-source-inputs.ts +5 -1
- package/src/swift-installed-targets.ts +4 -1
- package/src/swift-standins.ts +11 -8
- package/src/swift-wasm-prune.ts +33 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2250 | (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;
|
|
@@ -514,7 +514,7 @@ var init_process_table = __esm({
|
|
|
514
514
|
});
|
|
515
515
|
|
|
516
516
|
// src/process-group.ts
|
|
517
|
-
function listProcessChildren(parents, timeoutMs =
|
|
517
|
+
function listProcessChildren(parents, timeoutMs = 1e4) {
|
|
518
518
|
if (parents.some((pid) => !Number.isInteger(pid) || pid <= 1))
|
|
519
519
|
throw new Error("process inspection requires valid parent pids");
|
|
520
520
|
if (parents.length === 0) return [];
|
|
@@ -724,7 +724,7 @@ async function terminateProcessGroup(child, signal = "SIGTERM", gracefulTimeoutM
|
|
|
724
724
|
try {
|
|
725
725
|
signalProcessGroup(child, "SIGSTOP");
|
|
726
726
|
let parents = [child.pid];
|
|
727
|
-
const inspectionDeadline = Date.now() +
|
|
727
|
+
const inspectionDeadline = Date.now() + INSPECTION_TIMEOUT_MS;
|
|
728
728
|
while (parents.length > 0) {
|
|
729
729
|
const remaining = inspectionDeadline - Date.now();
|
|
730
730
|
if (remaining <= 0) {
|
|
@@ -820,7 +820,7 @@ async function terminateProcessGroup(child, signal = "SIGTERM", gracefulTimeoutM
|
|
|
820
820
|
}
|
|
821
821
|
if (inspectionError) throw inspectionError;
|
|
822
822
|
}
|
|
823
|
-
var import_node_child_process2, import_node_fs5, import_node_os3, import_node_path3, import_node_stream, import_promises, GRACEFUL_TIMEOUT_MS, FORCED_EXIT_TIMEOUT_MS, FREEZE_GUARD_NAME;
|
|
823
|
+
var import_node_child_process2, import_node_fs5, import_node_os3, import_node_path3, import_node_stream, import_promises, GRACEFUL_TIMEOUT_MS, FORCED_EXIT_TIMEOUT_MS, INSPECTION_TIMEOUT_MS, FREEZE_GUARD_NAME;
|
|
824
824
|
var init_process_group = __esm({
|
|
825
825
|
"src/process-group.ts"() {
|
|
826
826
|
"use strict";
|
|
@@ -833,6 +833,7 @@ var init_process_group = __esm({
|
|
|
833
833
|
init_process_table();
|
|
834
834
|
GRACEFUL_TIMEOUT_MS = 3e3;
|
|
835
835
|
FORCED_EXIT_TIMEOUT_MS = 1e3;
|
|
836
|
+
INSPECTION_TIMEOUT_MS = 1e4;
|
|
836
837
|
FREEZE_GUARD_NAME = "process-freeze-guard";
|
|
837
838
|
}
|
|
838
839
|
});
|
|
@@ -22440,7 +22441,11 @@ function parseWasmObjectBytes(file, buf, isDist, symbolFlagOffsets) {
|
|
|
22440
22441
|
objcClassSymToTypePrefix,
|
|
22441
22442
|
typePrefixesInObj,
|
|
22442
22443
|
rootFuncs,
|
|
22443
|
-
rootSegs
|
|
22444
|
+
rootSegs,
|
|
22445
|
+
segPayloadRanges: sEnds.map((end, i) => [
|
|
22446
|
+
dataStart + sPayloadStarts[i],
|
|
22447
|
+
dataStart + end
|
|
22448
|
+
])
|
|
22444
22449
|
};
|
|
22445
22450
|
}
|
|
22446
22451
|
function parseWasmObjectCached(file, isDist, useCache) {
|
|
@@ -22688,6 +22693,7 @@ function pruneSwiftWasmLink(directory2, toolchainBin, moduleRoot, staticClangTar
|
|
|
22688
22693
|
const eagerFiles = [];
|
|
22689
22694
|
const lazyBuildObjects = /* @__PURE__ */ new Map();
|
|
22690
22695
|
const extraArchiveObjs = [];
|
|
22696
|
+
const objectBytes = /* @__PURE__ */ new Map();
|
|
22691
22697
|
let inStartLib = false;
|
|
22692
22698
|
let swiftrtOrigPath = "";
|
|
22693
22699
|
for (const t of tokens2) {
|
|
@@ -22734,7 +22740,9 @@ function pruneSwiftWasmLink(directory2, toolchainBin, moduleRoot, staticClangTar
|
|
|
22734
22740
|
} else if (!inStartLib && t.endsWith(".a") && !t.endsWith("libclang_rt.builtins-wasm64.a") && import_node_fs37.default.existsSync(t)) {
|
|
22735
22741
|
const members2 = readArMembers(new Uint8Array(import_node_fs37.default.readFileSync(t)));
|
|
22736
22742
|
for (const m of members2) {
|
|
22737
|
-
|
|
22743
|
+
const object6 = parseWasmObjectBytes(`${t}(${m.name})`, m.bytes, false);
|
|
22744
|
+
extraArchiveObjs.push(object6);
|
|
22745
|
+
objectBytes.set(object6, Buffer.from(m.bytes));
|
|
22738
22746
|
}
|
|
22739
22747
|
}
|
|
22740
22748
|
}
|
|
@@ -23105,9 +23113,28 @@ function pruneSwiftWasmLink(directory2, toolchainBin, moduleRoot, staticClangTar
|
|
|
23105
23113
|
"$s10Foundation16NSSortDescriptorC7keyPath9ascendingACs03KeyE0Cyxq_G_SbtcSLR_r0_lufC",
|
|
23106
23114
|
"$s10Foundation16NSSortDescriptorC7keyPath9ascendingACs03KeyE0Cyxq_G_SbtcSLR_r0_lufc"
|
|
23107
23115
|
]);
|
|
23116
|
+
const keepObjCClassesNamedInSegment = (obj, segIdx) => {
|
|
23117
|
+
const range2 = obj.segPayloadRanges[segIdx];
|
|
23118
|
+
if (!range2) return;
|
|
23119
|
+
let bytes = objectBytes.get(obj);
|
|
23120
|
+
if (!bytes) objectBytes.set(obj, bytes = import_node_fs37.default.readFileSync(obj.file));
|
|
23121
|
+
const text6 = bytes.toString("latin1", range2[0], range2[1]);
|
|
23122
|
+
for (const match of text6.matchAll(/So(\d+)/g)) {
|
|
23123
|
+
const start = match.index + 2 + match[1].length;
|
|
23124
|
+
const length = Number(match[1]);
|
|
23125
|
+
if (text6[start + length] !== "C") continue;
|
|
23126
|
+
const symbol2 = `._OBJC_CLASS_${text6.slice(start, start + length)}`;
|
|
23127
|
+
for (const provider of lazyProviders.get(symbol2) ?? []) {
|
|
23128
|
+
eagerDynamicObjects.add(provider);
|
|
23129
|
+
extractObject(provider);
|
|
23130
|
+
activateSymbolInObj(provider, provider.symNames.indexOf(symbol2));
|
|
23131
|
+
}
|
|
23132
|
+
}
|
|
23133
|
+
};
|
|
23108
23134
|
while (workQueue.length > 0) {
|
|
23109
23135
|
const item = workQueue.pop();
|
|
23110
23136
|
const obj = item.obj;
|
|
23137
|
+
if (item.kind === "seg") keepObjCClassesNamedInSegment(obj, item.idx);
|
|
23111
23138
|
let relocs;
|
|
23112
23139
|
if (item.kind === "func") {
|
|
23113
23140
|
relocs = obj.funcRelocs[item.idx];
|
|
@@ -24053,8 +24080,12 @@ function createGuestImageLedger(input) {
|
|
|
24053
24080
|
}
|
|
24054
24081
|
}
|
|
24055
24082
|
}
|
|
24083
|
+
const nameBytes = /* @__PURE__ */ new Map();
|
|
24084
|
+
for (const definition2 of definitions)
|
|
24085
|
+
if (!nameBytes.has(definition2.name))
|
|
24086
|
+
nameBytes.set(definition2.name, Buffer.from(definition2.name));
|
|
24056
24087
|
definitions.sort(
|
|
24057
|
-
(a, b) => Buffer.compare(
|
|
24088
|
+
(a, b) => Buffer.compare(nameBytes.get(a.name), nameBytes.get(b.name)) || a.image - b.image
|
|
24058
24089
|
);
|
|
24059
24090
|
const preserveCanonical = /* @__PURE__ */ new Set();
|
|
24060
24091
|
const definitionsByName = Map.groupBy(definitions, (definition2) => definition2.name);
|
|
@@ -24084,12 +24115,12 @@ function createGuestImageLedger(input) {
|
|
|
24084
24115
|
preserveCanonical.add(name3);
|
|
24085
24116
|
for (const name3 of input.commandLineSymbols ?? []) preserveCanonical.add(name3);
|
|
24086
24117
|
const bindingsByImage = /* @__PURE__ */ new Map();
|
|
24118
|
+
const definitionsByImage = Map.groupBy(definitions, (definition2) => definition2.image);
|
|
24087
24119
|
for (const caller of input.callers) {
|
|
24088
24120
|
const bindings = /* @__PURE__ */ new Map();
|
|
24089
24121
|
const seen = /* @__PURE__ */ new Map();
|
|
24090
24122
|
for (const image of [caller.image, ...caller.next])
|
|
24091
|
-
for (const definition2 of
|
|
24092
|
-
if (definition2.image !== image) continue;
|
|
24123
|
+
for (const definition2 of definitionsByImage.get(image) ?? []) {
|
|
24093
24124
|
const previous = seen.get(definition2.name);
|
|
24094
24125
|
if (previous?.image === definition2.image) {
|
|
24095
24126
|
if (previous.weak && !definition2.weak) {
|
|
@@ -24129,8 +24160,9 @@ function createGuestImageLedger(input) {
|
|
|
24129
24160
|
definitionsByAlias.set(definition2.alias, definition2);
|
|
24130
24161
|
}
|
|
24131
24162
|
const objects = units.map(({ image, object: object6, aliases, functionImports }) => {
|
|
24132
|
-
const
|
|
24133
|
-
|
|
24163
|
+
const shared = bindingsByImage.get(image);
|
|
24164
|
+
const own = startup.get(object6.path);
|
|
24165
|
+
const bindings = own ? new Map([...shared, ...own]) : shared;
|
|
24134
24166
|
for (const [name3, type] of functionImports) {
|
|
24135
24167
|
const alias = bindings.get(name3);
|
|
24136
24168
|
const provider = alias === void 0 ? void 0 : definitionsByAlias.get(alias);
|
|
@@ -26049,6 +26081,7 @@ function linkGuestImages(options) {
|
|
|
26049
26081
|
);
|
|
26050
26082
|
}
|
|
26051
26083
|
const archives = /* @__PURE__ */ new Map();
|
|
26084
|
+
const memberBytes = /* @__PURE__ */ new Map();
|
|
26052
26085
|
const prepare2 = (provider2) => {
|
|
26053
26086
|
const trace = runLink("discovery", [
|
|
26054
26087
|
...withOutput(args, discovery, true),
|
|
@@ -26092,20 +26125,23 @@ function linkGuestImages(options) {
|
|
|
26092
26125
|
}
|
|
26093
26126
|
const objectsByImage = /* @__PURE__ */ new Map();
|
|
26094
26127
|
for (const image of plan.images) objectsByImage.set(image.id, []);
|
|
26128
|
+
const artifacts = new Map(plan.artifacts.map((artifact) => [artifact.path, artifact]));
|
|
26095
26129
|
for (const item of selected2) {
|
|
26096
|
-
const artifact =
|
|
26097
|
-
(candidate) => candidate.path === item.artifact
|
|
26098
|
-
);
|
|
26130
|
+
const artifact = artifacts.get(item.artifact);
|
|
26099
26131
|
const image = selectedGuestInputImage(artifact, item.member);
|
|
26100
26132
|
let bytes;
|
|
26101
26133
|
if (item.member === null) bytes = import_node_fs41.default.readFileSync(item.artifact);
|
|
26102
26134
|
else {
|
|
26103
|
-
let
|
|
26104
|
-
if (!
|
|
26105
|
-
members2 = readArMembers(import_node_fs41.default.readFileSync(item.artifact));
|
|
26135
|
+
let byName = memberBytes.get(item.artifact);
|
|
26136
|
+
if (!byName) {
|
|
26137
|
+
const members2 = readArMembers(import_node_fs41.default.readFileSync(item.artifact));
|
|
26106
26138
|
archives.set(item.artifact, members2);
|
|
26139
|
+
byName = /* @__PURE__ */ new Map();
|
|
26140
|
+
for (const member of members2)
|
|
26141
|
+
if (!byName.has(member.name)) byName.set(member.name, member.bytes);
|
|
26142
|
+
memberBytes.set(item.artifact, byName);
|
|
26107
26143
|
}
|
|
26108
|
-
bytes =
|
|
26144
|
+
bytes = byName.get(item.member);
|
|
26109
26145
|
}
|
|
26110
26146
|
const objects = objectsByImage.get(image);
|
|
26111
26147
|
if (!objects) throw new Error(`unknown image ${image}`);
|
|
@@ -26138,10 +26174,11 @@ function linkGuestImages(options) {
|
|
|
26138
26174
|
const { selected, ledger } = prepared;
|
|
26139
26175
|
const replacements = /* @__PURE__ */ new Map();
|
|
26140
26176
|
const linkedOwners = /* @__PURE__ */ new Map();
|
|
26177
|
+
const ledgerObjects = new Map(ledger.objects.map((item) => [item.path, item]));
|
|
26141
26178
|
for (const [index, artifact] of plan.artifacts.entries()) {
|
|
26142
26179
|
const prefix = `${artifact.path}(`;
|
|
26143
26180
|
if (artifact.kind === "object") {
|
|
26144
|
-
const object6 =
|
|
26181
|
+
const object6 = ledgerObjects.get(artifact.path);
|
|
26145
26182
|
if (!object6) continue;
|
|
26146
26183
|
const output3 = import_node_path39.default.join(directory2, `object-${index}.o`);
|
|
26147
26184
|
import_node_fs41.default.writeFileSync(output3, object6.bytes);
|
|
@@ -26161,9 +26198,7 @@ function linkGuestImages(options) {
|
|
|
26161
26198
|
const output2 = import_node_path39.default.join(directory2, `archive-${index}.a`);
|
|
26162
26199
|
const inputs = members2.map((member) => {
|
|
26163
26200
|
const memberOutput = import_node_path39.default.join(memberDir, member.name);
|
|
26164
|
-
const rewritten =
|
|
26165
|
-
(item) => item.path === `${prefix}${member.name})`
|
|
26166
|
-
);
|
|
26201
|
+
const rewritten = ledgerObjects.get(`${prefix}${member.name})`);
|
|
26167
26202
|
import_node_fs41.default.writeFileSync(memberOutput, rewritten?.bytes ?? member.bytes);
|
|
26168
26203
|
if (rewritten) {
|
|
26169
26204
|
linkedOwners.set(
|
|
@@ -26502,10 +26537,13 @@ function selectedGuestSymbolInputs(plan, selected) {
|
|
|
26502
26537
|
else {
|
|
26503
26538
|
let members2 = archives.get(item.artifact);
|
|
26504
26539
|
if (!members2) {
|
|
26505
|
-
members2 =
|
|
26540
|
+
members2 = Map.groupBy(
|
|
26541
|
+
readArMembers(import_node_fs41.default.readFileSync(item.artifact)),
|
|
26542
|
+
(member) => member.name
|
|
26543
|
+
);
|
|
26506
26544
|
archives.set(item.artifact, members2);
|
|
26507
26545
|
}
|
|
26508
|
-
const matching2 = members2.
|
|
26546
|
+
const matching2 = members2.get(item.member) ?? [];
|
|
26509
26547
|
if (matching2.length !== 1)
|
|
26510
26548
|
throw new Error(
|
|
26511
26549
|
`ambiguous selected symbol input ${item.artifact}(${item.member})`
|
|
@@ -26917,9 +26955,10 @@ function sourceGuestClangLinkOptions(options) {
|
|
|
26917
26955
|
if (command.tool !== "clang" || compiler !== (0, import_node_fs42.realpathSync)(import_node_path40.default.join(options.toolchainBin, "clang")) && compiler !== (0, import_node_fs42.realpathSync)(import_node_path40.default.join(options.buildDirectory, CLANG_TARGET_MODULE_WRAPPER)))
|
|
26918
26956
|
throw new Error(`unsupported source object producer ${file}`);
|
|
26919
26957
|
const args = command.args.slice(1).filter((arg) => arg !== "-c");
|
|
26958
|
+
const targetBuild = import_node_path40.default.relative(options.buildDirectory, file).split(import_node_path40.default.sep).findLast((part) => part !== ".build" && part.endsWith(".build"));
|
|
26920
26959
|
const outputDirectory = import_node_path40.default.join(
|
|
26921
26960
|
options.directory,
|
|
26922
|
-
import_node_path40.default.basename(import_node_path40.default.dirname(file))
|
|
26961
|
+
targetBuild ?? import_node_path40.default.basename(import_node_path40.default.dirname(file))
|
|
26923
26962
|
);
|
|
26924
26963
|
(0, import_node_fs42.mkdirSync)(outputDirectory, { recursive: true });
|
|
26925
26964
|
const output2 = import_node_path40.default.join(outputDirectory, `clang-link-${index}.ll`);
|
|
@@ -28931,6 +28970,46 @@ function swiftModuleInterface(moduleRoot, name3, interfaceRoot) {
|
|
|
28931
28970
|
if (declared.size === 0) return null;
|
|
28932
28971
|
return { declared, header: clangInterfaceHeader((0, import_node_fs52.readFileSync)(built2, "utf8")) };
|
|
28933
28972
|
}
|
|
28973
|
+
function nativelyDeclaredFunctions(generated, headers) {
|
|
28974
|
+
const candidates = [
|
|
28975
|
+
...new Set(
|
|
28976
|
+
[...generated.matchAll(/^\s*SWIFT_EXTERN\b[^(\n]*?\b(\w+)\s*\(/gm)].map(
|
|
28977
|
+
(match) => match[1]
|
|
28978
|
+
)
|
|
28979
|
+
)
|
|
28980
|
+
];
|
|
28981
|
+
if (candidates.length === 0) return [];
|
|
28982
|
+
const declaration = new RegExp(`^[^\\n#/*]*?\\b(${candidates.join("|")})\\s*\\(`, "gm");
|
|
28983
|
+
const found = /* @__PURE__ */ new Set();
|
|
28984
|
+
for (const header of headers)
|
|
28985
|
+
for (const match of header.matchAll(declaration)) found.add(match[1]);
|
|
28986
|
+
return [...found];
|
|
28987
|
+
}
|
|
28988
|
+
function sdkObjCDeclarationOwners(frameworks) {
|
|
28989
|
+
const known = sdkDeclarationOwners.get(frameworks);
|
|
28990
|
+
if (known) return known;
|
|
28991
|
+
const owners = /* @__PURE__ */ new Map();
|
|
28992
|
+
for (const framework of (0, import_node_fs52.readdirSync)(frameworks))
|
|
28993
|
+
if (framework.endsWith(".framework")) {
|
|
28994
|
+
const headers = import_node_path50.default.join(frameworks, framework, "Headers");
|
|
28995
|
+
if ((0, import_node_fs52.existsSync)(headers)) {
|
|
28996
|
+
for (const file of (0, import_node_fs52.readdirSync)(headers, { recursive: true, encoding: "utf8" }))
|
|
28997
|
+
if (file.endsWith(".h")) {
|
|
28998
|
+
const header = (0, import_node_fs52.readFileSync)(import_node_path50.default.join(headers, file), "utf8");
|
|
28999
|
+
for (const name3 of [
|
|
29000
|
+
...swiftInterfaceDeclarations(header),
|
|
29001
|
+
...objcEnumerations(header),
|
|
29002
|
+
...[
|
|
29003
|
+
...header.matchAll(/^[A-Z_]*_(?:EXTERN|EXPORT)\b[^;(\n]*?\b(\w+)\s*\(/gm)
|
|
29004
|
+
].map((match) => match[1])
|
|
29005
|
+
])
|
|
29006
|
+
owners.set(name3, framework.slice(0, -".framework".length));
|
|
29007
|
+
}
|
|
29008
|
+
}
|
|
29009
|
+
}
|
|
29010
|
+
sdkDeclarationOwners.set(frameworks, owners);
|
|
29011
|
+
return owners;
|
|
29012
|
+
}
|
|
28934
29013
|
function swiftHeaderWithSuperclassImports(header, interfaceFor) {
|
|
28935
29014
|
const superclasses = new Set(
|
|
28936
29015
|
[...header.matchAll(/@interface\s+\w+\s*:\s*(\w+)/g)].map((match) => match[1])
|
|
@@ -28963,6 +29042,10 @@ function withoutSwiftDeclarations(text6, declared, interfaceImport) {
|
|
|
28963
29042
|
const name3 = /^\s*(?:[A-Z_]\w*(?:\([^()\n]*\))?\s+)*@(?:protocol|interface)\s+(\w+)\s*(?=[:<{]|$)/.exec(
|
|
28964
29043
|
line
|
|
28965
29044
|
)?.[1];
|
|
29045
|
+
const external = /^\s*SWIFT_EXTERN\b[^(\n]*?\b(\w+)\s*\(.*\)[^;\n]*;\s*$/.exec(
|
|
29046
|
+
line
|
|
29047
|
+
)?.[1];
|
|
29048
|
+
if (external && declared.has(external)) continue;
|
|
28966
29049
|
const enumeration = /^\s*typedef\s+(?:NS_ENUM|NS_OPTIONS|SWIFT_ENUM(?:_NAMED)?)\s*\(\s*\w+\s*,\s*(\w+)\b/.exec(
|
|
28967
29050
|
line
|
|
28968
29051
|
)?.[1];
|
|
@@ -32192,15 +32275,29 @@ module ${moduleName2}.Swift {
|
|
|
32192
32275
|
[
|
|
32193
32276
|
"#!/bin/sh",
|
|
32194
32277
|
"name=",
|
|
32278
|
+
"explicit=",
|
|
32195
32279
|
"prev=",
|
|
32196
32280
|
'for arg in "$@"; do',
|
|
32197
|
-
|
|
32281
|
+
" case $arg in -fmodule-name=*) explicit=1 ;; esac",
|
|
32282
|
+
' if [ "$prev" = -o ]; then',
|
|
32283
|
+
" case $arg in */*) dir=${arg%/*} ;; *) dir= ;; esac",
|
|
32284
|
+
' while [ -n "$dir" ] && [ "$dir" != / ] && [ "$dir" != . ]; do',
|
|
32285
|
+
" base=${dir##*/}",
|
|
32286
|
+
" case $base in",
|
|
32287
|
+
" .build) break ;;",
|
|
32288
|
+
" *.build) name=${base%.build}; break ;;",
|
|
32289
|
+
" esac",
|
|
32290
|
+
" next=${dir%/*}",
|
|
32291
|
+
' [ "$next" = "$dir" ] && break',
|
|
32292
|
+
" dir=$next",
|
|
32293
|
+
" done",
|
|
32294
|
+
" fi",
|
|
32198
32295
|
" prev=$arg",
|
|
32199
32296
|
"done",
|
|
32200
|
-
"
|
|
32201
|
-
`
|
|
32202
|
-
|
|
32203
|
-
"
|
|
32297
|
+
'if [ -n "$name" ] && [ -z "$explicit" ]; then',
|
|
32298
|
+
` exec '${import_node_path50.default.join(nativeToolchain(), "clang")}' "-fmodule-name=$name" "$@"`,
|
|
32299
|
+
"fi",
|
|
32300
|
+
`exec '${import_node_path50.default.join(nativeToolchain(), "clang")}' "$@"`,
|
|
32204
32301
|
""
|
|
32205
32302
|
].join("\n")
|
|
32206
32303
|
);
|
|
@@ -32659,7 +32756,7 @@ function frameworkLinkClosure(scratch2, roots) {
|
|
|
32659
32756
|
const deps = /* @__PURE__ */ new Set();
|
|
32660
32757
|
for (const file of paths) {
|
|
32661
32758
|
const module2 = /\/Modules\/([^/]+)\.swiftmodule$/.exec(file);
|
|
32662
|
-
const object6 = /\/([^/]+)\.build
|
|
32759
|
+
const object6 = /\/release\/([^/]+)\.build\/.+\.o$/.exec(file);
|
|
32663
32760
|
if (module2) deps.add(module2[1]);
|
|
32664
32761
|
else if (object6 && object6[1] !== pending.name) deps.add(object6[1]);
|
|
32665
32762
|
}
|
|
@@ -33335,11 +33432,28 @@ function compileSwiftProjectOnce(input, options) {
|
|
|
33335
33432
|
))
|
|
33336
33433
|
declared.add(name4);
|
|
33337
33434
|
}
|
|
33338
|
-
const
|
|
33435
|
+
const own = withoutSwiftDeclarations(
|
|
33339
33436
|
clangInterfaceHeader((0, import_node_fs52.readFileSync)(source, "utf8")),
|
|
33340
33437
|
declared,
|
|
33341
33438
|
`#import <${name3}/${name3}.h>`
|
|
33342
33439
|
);
|
|
33440
|
+
const owners = sdkObjCDeclarationOwners(import_node_path50.default.dirname(import_node_path50.default.dirname(headers)));
|
|
33441
|
+
const foreign = /* @__PURE__ */ new Map();
|
|
33442
|
+
for (const declaration of [
|
|
33443
|
+
...swiftInterfaceDeclarations(own),
|
|
33444
|
+
...objcEnumerations(own),
|
|
33445
|
+
...[...own.matchAll(/^\s*SWIFT_EXTERN\b[^(\n]*?\b(\w+)\s*\(/gm)].map(
|
|
33446
|
+
(match) => match[1]
|
|
33447
|
+
)
|
|
33448
|
+
]) {
|
|
33449
|
+
const owner = owners.get(declaration);
|
|
33450
|
+
if (owner && owner !== name3) foreign.set(declaration, owner);
|
|
33451
|
+
}
|
|
33452
|
+
const header = foreign.size ? withoutSwiftDeclarations(
|
|
33453
|
+
own,
|
|
33454
|
+
new Set(foreign.keys()),
|
|
33455
|
+
[...new Set(foreign.values())].map((owner) => `#import <${owner}/${owner}.h>`).join("\n")
|
|
33456
|
+
) : own;
|
|
33343
33457
|
const value = {
|
|
33344
33458
|
file: import_node_path50.default.join(root, ".build/peach-framework-objc", `${name3}-Swift.h`),
|
|
33345
33459
|
header,
|
|
@@ -33376,18 +33490,25 @@ function compileSwiftProjectOnce(input, options) {
|
|
|
33376
33490
|
`${producer}-Swift.h`
|
|
33377
33491
|
);
|
|
33378
33492
|
const original = preparation.nativeHeaderDeclarations[producer] ? emitted.replace(/-Swift\.h$/, "-Swift.original.h") : emitted;
|
|
33379
|
-
if ((0, import_node_fs52.existsSync)(original))
|
|
33493
|
+
if ((0, import_node_fs52.existsSync)(original)) {
|
|
33494
|
+
const generated = clangInterfaceHeader((0, import_node_fs52.readFileSync)(original, "utf8"));
|
|
33380
33495
|
writeBuildFile(
|
|
33381
33496
|
emitted,
|
|
33382
33497
|
withoutSwiftDeclarations(
|
|
33383
|
-
swiftHeaderWithSuperclassImports(
|
|
33384
|
-
|
|
33385
|
-
|
|
33386
|
-
|
|
33387
|
-
|
|
33498
|
+
swiftHeaderWithSuperclassImports(generated, frameworkInterface),
|
|
33499
|
+
/* @__PURE__ */ new Set([
|
|
33500
|
+
...preparation.nativeHeaderDeclarations[producer] ?? [],
|
|
33501
|
+
...nativelyDeclaredFunctions(
|
|
33502
|
+
generated,
|
|
33503
|
+
Object.entries(input.files).filter(
|
|
33504
|
+
([name3]) => name3.endsWith(".h") && !name3.endsWith("-Swift.h")
|
|
33505
|
+
).map(([, source]) => source)
|
|
33506
|
+
)
|
|
33507
|
+
]),
|
|
33388
33508
|
`#import <${producer}/${producer}.h>`
|
|
33389
33509
|
)
|
|
33390
33510
|
);
|
|
33511
|
+
}
|
|
33391
33512
|
}
|
|
33392
33513
|
}
|
|
33393
33514
|
const checkpoints = import_node_path50.default.join(
|
|
@@ -33525,7 +33646,7 @@ function compileSwiftProjectOnce(input, options) {
|
|
|
33525
33646
|
options.signal
|
|
33526
33647
|
);
|
|
33527
33648
|
}
|
|
33528
|
-
var import_node_child_process29, import_node_crypto22, import_node_fs52, import_node_os10, import_node_path50, v5, WASM_TRIPLE, SWIFTPM_PROGRESS, SWIFTPM_NOISE, SWIFT_BUILDER_TRANSPORT_MARGIN_MS, SWIFT_BUILDER_DEFAULT_COMPILE_MS, clangInterfaceHeader, swiftInterfaceDeclarations, linkedModuleDigests, SYSTEM_MODULE_LIBRARIES, SYSTEM_MODULE_IMPORT, OPTIONAL_FRAMEWORK_DEPENDENCIES, OPTIONAL_FRAMEWORKS, SWIFT_IMPORT, kleeneNot, kleeneAnd, kleeneOr, sdkPaths, availableModules, sdkOverlayFrameworks, DISTRIBUTION_CLANG_MODULES, ONE_PRODUCT, GAME_FAMILY, gameProducts, gameProduct, GAME_REACH, FOUNDATION_IMPLICIT_MODULES, PRECONCURRENCY_FOUNDATION_IMPORT, FOUNDATION_IMPLICIT_FLAGS, ONE_IMPLICIT_FLAGS, executableLinkFlags, darwinRecordsRegion, REACTOR_FLAG, MULTI_MANIFEST_VERSION, SWIFT_HEADER_PRODUCTS_TARGET, compilerSourceDigest, nativeCxxCompilerFlags, cFlagArray, cxxFlagArray, SWIFTPM_DEFAULT_IOS_DEPLOYMENT_TARGET, DIRECTIVE, OS_IOS, NOT_ON_IOS, DELEGATE_CLASS, FOUNDATION_NETWORKING_TYPES, FOUNDATION_OVERLAY_TYPES, FOUNDATION_OVERLAY_GLOBALS, CORE_FOUNDATION_OVERLAY_GLOBALS, CORE_FOUNDATION_GEOMETRY_TYPES, CORE_FOUNDATION_GRAPHICS_TYPES, CORE_FOUNDATION_HANDLE_IMPORTS, emptyMacroEnvironment, wasmMacroEnvironment, HIDDEN_UNITS, LIBXML_REFERENCE, LIBXML_SOURCE, ROOT_LOCKS, host, rootLocks, SHARED_ARTIFACT_BUDGET_BYTES, SHARED_ARTIFACT_GRACE_MS, RETIRED_PREFIX, retainedArtifacts, FRAMEWORK_LINK_TARGET, SWIFT_LINK_STAMP, SWIFT_FRAMEWORK_SLOTS, SWIFT_FRAMEWORK_SLOT_KEY, SWIFT_FRAMEWORK_SLOT_ORIGIN;
|
|
33649
|
+
var import_node_child_process29, import_node_crypto22, import_node_fs52, import_node_os10, import_node_path50, v5, WASM_TRIPLE, SWIFTPM_PROGRESS, SWIFTPM_NOISE, SWIFT_BUILDER_TRANSPORT_MARGIN_MS, SWIFT_BUILDER_DEFAULT_COMPILE_MS, clangInterfaceHeader, objcEnumerations, sdkDeclarationOwners, swiftInterfaceDeclarations, linkedModuleDigests, SYSTEM_MODULE_LIBRARIES, SYSTEM_MODULE_IMPORT, OPTIONAL_FRAMEWORK_DEPENDENCIES, OPTIONAL_FRAMEWORKS, SWIFT_IMPORT, kleeneNot, kleeneAnd, kleeneOr, sdkPaths, availableModules, sdkOverlayFrameworks, DISTRIBUTION_CLANG_MODULES, ONE_PRODUCT, GAME_FAMILY, gameProducts, gameProduct, GAME_REACH, FOUNDATION_IMPLICIT_MODULES, PRECONCURRENCY_FOUNDATION_IMPORT, FOUNDATION_IMPLICIT_FLAGS, ONE_IMPLICIT_FLAGS, executableLinkFlags, darwinRecordsRegion, REACTOR_FLAG, MULTI_MANIFEST_VERSION, SWIFT_HEADER_PRODUCTS_TARGET, compilerSourceDigest, nativeCxxCompilerFlags, cFlagArray, cxxFlagArray, SWIFTPM_DEFAULT_IOS_DEPLOYMENT_TARGET, DIRECTIVE, OS_IOS, NOT_ON_IOS, DELEGATE_CLASS, FOUNDATION_NETWORKING_TYPES, FOUNDATION_OVERLAY_TYPES, FOUNDATION_OVERLAY_GLOBALS, CORE_FOUNDATION_OVERLAY_GLOBALS, CORE_FOUNDATION_GEOMETRY_TYPES, CORE_FOUNDATION_GRAPHICS_TYPES, CORE_FOUNDATION_HANDLE_IMPORTS, emptyMacroEnvironment, wasmMacroEnvironment, HIDDEN_UNITS, LIBXML_REFERENCE, LIBXML_SOURCE, ROOT_LOCKS, host, rootLocks, SHARED_ARTIFACT_BUDGET_BYTES, SHARED_ARTIFACT_GRACE_MS, RETIRED_PREFIX, retainedArtifacts, FRAMEWORK_LINK_TARGET, SWIFT_LINK_STAMP, SWIFT_FRAMEWORK_SLOTS, SWIFT_FRAMEWORK_SLOT_KEY, SWIFT_FRAMEWORK_SLOT_ORIGIN;
|
|
33529
33650
|
var init_swift_compile = __esm({
|
|
33530
33651
|
"src/swift-compile.ts"() {
|
|
33531
33652
|
"use strict";
|
|
@@ -33572,6 +33693,12 @@ var init_swift_compile = __esm({
|
|
|
33572
33693
|
/^@import (?:CoreFoundation|FoundationNetworking);$/gm,
|
|
33573
33694
|
"@import Foundation;"
|
|
33574
33695
|
).replace(/\b_TtC10Foundation\d+(NS\w+)\b/g, "$1").replace(/\b__attribute__\(\(objc_subclassing_restricted\)\)\s*/g, "");
|
|
33696
|
+
objcEnumerations = (header) => [
|
|
33697
|
+
...header.matchAll(
|
|
33698
|
+
/^\s*typedef\s+(?:NS|CF|SWIFT)_\w*(?:ENUM|OPTIONS)\w*\s*\(\s*\w+\s*,\s*(\w+)\b/gm
|
|
33699
|
+
)
|
|
33700
|
+
].map((match) => match[1]);
|
|
33701
|
+
sdkDeclarationOwners = /* @__PURE__ */ new Map();
|
|
33575
33702
|
swiftInterfaceDeclarations = (header) => /* @__PURE__ */ new Set([
|
|
33576
33703
|
...[
|
|
33577
33704
|
...header.matchAll(
|
|
@@ -33754,7 +33881,7 @@ int EXUpdatesApplyBSDiffPatch(const char * _Nonnull oldFilePath,
|
|
|
33754
33881
|
REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
|
|
33755
33882
|
MULTI_MANIFEST_VERSION = 68;
|
|
33756
33883
|
SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
|
|
33757
|
-
compilerSourceDigest = true ? "
|
|
33884
|
+
compilerSourceDigest = true ? "4a1be1d1296381c7090b5b2b704a7d2bebba03ceaa580613acd0f2c39c31ed4c" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
|
|
33758
33885
|
nativeCxxCompilerFlags = ["-fno-cxx-modules"];
|
|
33759
33886
|
cFlagArray = (flags) => JSON.stringify(withoutGlogModuleMap(flags));
|
|
33760
33887
|
cxxFlagArray = (flags) => JSON.stringify([...nativeCxxCompilerFlags, ...withoutGlogModuleMap(flags)]);
|
|
@@ -38228,7 +38355,7 @@ var init_swift_standin_digest = __esm({
|
|
|
38228
38355
|
STANDIN_DIGEST_ENTRYPOINTS = ["swift-standins.ts", "swift-objc-compile.ts"];
|
|
38229
38356
|
SPECIFIER = /from\s*['"]([^'"]+)['"]|import\s*\(\s*['"]([^'"]+)['"]\s*\)/g;
|
|
38230
38357
|
standinSourceDigest = (srcDir = __sootsim_import_meta_dirname) => sourceClosureDigest(srcDir, STANDIN_DIGEST_ENTRYPOINTS);
|
|
38231
|
-
STANDIN_SOURCE_DIGEST = true ? "
|
|
38358
|
+
STANDIN_SOURCE_DIGEST = true ? "977c30e838b3cb068d200b9a9a12851b01d2192d0d04e2b5a6abe8189c168d42" : standinSourceDigest();
|
|
38232
38359
|
}
|
|
38233
38360
|
});
|
|
38234
38361
|
|
|
@@ -40594,9 +40721,9 @@ function exec(file, args, cwd) {
|
|
|
40594
40721
|
}
|
|
40595
40722
|
function failure(error) {
|
|
40596
40723
|
const output2 = error && typeof error === "object" && "stderr" in error ? `${String(error.stderr)}
|
|
40597
|
-
${"stdout" in error ? String(error.stdout) : ""}` : String(error);
|
|
40598
|
-
const errors = output2.split("\n").filter((line) =>
|
|
40599
|
-
return [...new Set(errors)].slice(0, 3).join("; ") || output2.trim().slice(
|
|
40724
|
+
${"stdout" in error ? String(error.stdout) : ""}` : error instanceof Error ? error.message : String(error);
|
|
40725
|
+
const errors = output2.split("\n").filter((line) => /^(\S.*?:\d+:\d+: )?error:/.test(line)).map((line) => line.replace(/^(.*?:\d+:\d+: )?error:\s*/, "").trim());
|
|
40726
|
+
return [...new Set(errors)].slice(0, 3).join("; ") || output2.trim().slice(-600);
|
|
40600
40727
|
}
|
|
40601
40728
|
function treeDigest2(root) {
|
|
40602
40729
|
const names = [];
|
|
@@ -41107,6 +41234,8 @@ function peachModuleDirs(toolchain, imports2, sdkIncludes) {
|
|
|
41107
41234
|
target,
|
|
41108
41235
|
"-Xswiftc",
|
|
41109
41236
|
"-Osize",
|
|
41237
|
+
"-Xswiftc",
|
|
41238
|
+
"-gnone",
|
|
41110
41239
|
...plugins.libraries.flatMap((library) => [
|
|
41111
41240
|
"-Xswiftc",
|
|
41112
41241
|
"-load-plugin-library",
|
|
@@ -42742,10 +42871,9 @@ ${roots.map((file) => ` header "${file}"`).join("\n")}
|
|
|
42742
42871
|
) : binary2.cxxHeaders ? await cxxStandin(surface, binary2, toolchain, dir) : cStandin(surface, binary2, toolchain, dir)
|
|
42743
42872
|
);
|
|
42744
42873
|
} catch (error) {
|
|
42745
|
-
throw new Error(
|
|
42746
|
-
|
|
42747
|
-
|
|
42748
|
-
);
|
|
42874
|
+
throw new Error(`no stand-in for ${surface.module}: ${failure(error)}`, {
|
|
42875
|
+
cause: error
|
|
42876
|
+
});
|
|
42749
42877
|
}
|
|
42750
42878
|
}
|
|
42751
42879
|
publish(result);
|
|
@@ -48988,10 +49116,11 @@ function applyInstalledSwiftTargets(collection, snapshot, generatedTargets, root
|
|
|
48988
49116
|
].map((bundle) => [bundle.target, bundle])
|
|
48989
49117
|
).values()
|
|
48990
49118
|
];
|
|
48991
|
-
|
|
49119
|
+
const headerAliases = {
|
|
48992
49120
|
...collection.headerAliases,
|
|
48993
49121
|
...snapshot.input.headerAliases
|
|
48994
49122
|
};
|
|
49123
|
+
collection.headerAliases = headerAliases;
|
|
48995
49124
|
const canonical = /* @__PURE__ */ new Map();
|
|
48996
49125
|
for (const [key2, source] of Object.entries(snapshot.sourcePaths)) {
|
|
48997
49126
|
const real = import_node_fs85.default.realpathSync(source);
|
|
@@ -49061,6 +49190,8 @@ function applyInstalledSwiftTargets(collection, snapshot, generatedTargets, root
|
|
|
49061
49190
|
const match = supplied.get(file.slice(prefix.length))?.find((candidate) => candidate.content === content);
|
|
49062
49191
|
if (!match) continue;
|
|
49063
49192
|
roots2.add(match.root);
|
|
49193
|
+
aliases[file] = copy;
|
|
49194
|
+
headerAliases[file] = copy;
|
|
49064
49195
|
delete collection.files[file];
|
|
49065
49196
|
}
|
|
49066
49197
|
return roots2;
|
|
@@ -54535,7 +54666,7 @@ var init_nitro_superset = __esm({
|
|
|
54535
54666
|
init_nitroContract();
|
|
54536
54667
|
init_swift_standin_digest();
|
|
54537
54668
|
NITRO_SUPERSET_ENTRY_NAME = "superset";
|
|
54538
|
-
NITRO_COMPILER_DIGEST = true ? "
|
|
54669
|
+
NITRO_COMPILER_DIGEST = true ? "0429b227e3c07f9b7eede2db1261fa41aed089c33099b22004c3776da007bf07" : nitroCompilerSourceDigest(__sootsim_import_meta_dirname, STANDIN_SOURCE_DIGEST2);
|
|
54539
54670
|
nitroSupersetLock = parseLock(nitro_superset_lock_default);
|
|
54540
54671
|
nitroSupersetKey = (inputs) => nativeEntryKey({ ...inputs, compiler: NITRO_COMPILER_DIGEST });
|
|
54541
54672
|
published2 = /* @__PURE__ */ new Map();
|
|
@@ -54556,7 +54687,7 @@ var init_nitro_superset = __esm({
|
|
|
54556
54687
|
var runtime_companion_default;
|
|
54557
54688
|
var init_runtime_companion = __esm({
|
|
54558
54689
|
"runtime-companion.json"() {
|
|
54559
|
-
runtime_companion_default = { abi: 1, sha256: "
|
|
54690
|
+
runtime_companion_default = { abi: 1, sha256: "15053b90437ccef5f18e3e8cde5732e85d2dc9feb3a3e76076cb671a640c465e", file: "node/cli-15053b90437ccef5f18e3e8cde5732e85d2dc9feb3a3e76076cb671a640c465e.cjs" };
|
|
54560
54691
|
}
|
|
54561
54692
|
});
|
|
54562
54693
|
|
|
@@ -54639,7 +54770,8 @@ var init_cli_runtime = __esm({
|
|
|
54639
54770
|
// src/runtime-packs.ts
|
|
54640
54771
|
var runtime_packs_exports = {};
|
|
54641
54772
|
__export(runtime_packs_exports, {
|
|
54642
|
-
ensureRuntimePackFor: () => ensureRuntimePackFor
|
|
54773
|
+
ensureRuntimePackFor: () => ensureRuntimePackFor,
|
|
54774
|
+
installAllRuntimePacks: () => installAllRuntimePacks
|
|
54643
54775
|
});
|
|
54644
54776
|
function listedFiles(runtimeRoot) {
|
|
54645
54777
|
let listed = listedByRoot.get(runtimeRoot);
|
|
@@ -54702,6 +54834,11 @@ async function ensureRuntimePackFor(runtimeRoot, pathname) {
|
|
|
54702
54834
|
if (!/\.m?js$/.test(rel) || import_node_fs102.default.existsSync(import_node_path101.default.join(tenantDir, rel))) return;
|
|
54703
54835
|
await installNamedPack(runtimeRoot, RUNTIME_MERGE_PACK_DIR);
|
|
54704
54836
|
}
|
|
54837
|
+
async function installAllRuntimePacks(runtimeRoot) {
|
|
54838
|
+
for (const name3 of Object.keys(readPacks(runtimeRoot) ?? {}))
|
|
54839
|
+
if (!await installNamedPack(runtimeRoot, name3))
|
|
54840
|
+
throw new Error(`runtime pack ${name3} did not install under ${runtimeRoot}`);
|
|
54841
|
+
}
|
|
54705
54842
|
function installNamedPack(runtimeRoot, name3) {
|
|
54706
54843
|
if (name3 === RUNTIME_MERGE_PACK_DIR) {
|
|
54707
54844
|
const tenantDir = import_node_path101.default.join(runtimeRoot, RUNTIME_MERGE_PACK_DIR);
|
|
@@ -64119,7 +64256,7 @@ init_swift_native_pin();
|
|
|
64119
64256
|
init_xcode_project();
|
|
64120
64257
|
var EXPO_NATIVE_ENTRY_NAME = "ios";
|
|
64121
64258
|
function expoNativeCompilerDigestValue() {
|
|
64122
|
-
return true ? "
|
|
64259
|
+
return true ? "61015852e514afc4871689bd71712eb2a5ac95c8b04829519dc81f6855f86b30" : expoNativeCompilerDigest(__sootsim_import_meta_dirname);
|
|
64123
64260
|
}
|
|
64124
64261
|
var IDENTITY_SOURCE_SKIPS = 1 | 4 | 8 | 16 | 32 | 64 | 128 | 4096;
|
|
64125
64262
|
function readSources(value) {
|
|
@@ -68149,6 +68286,7 @@ async function compileNitroModule(options) {
|
|
|
68149
68286
|
options.packageRoots,
|
|
68150
68287
|
options.answers
|
|
68151
68288
|
).flatMap(({ config }) => config.swiftModule ? [config.swiftModule] : []);
|
|
68289
|
+
let installedTargets = [];
|
|
68152
68290
|
if (swiftModules.length > 0 && workspace) {
|
|
68153
68291
|
const available = new Set(
|
|
68154
68292
|
swiftAvailableModules(
|
|
@@ -68172,12 +68310,13 @@ async function compileNitroModule(options) {
|
|
|
68172
68310
|
},
|
|
68173
68311
|
async (root) => {
|
|
68174
68312
|
const snapshot = await installedWorkspaceInput(root, "main.swift");
|
|
68313
|
+
installedTargets = swiftManifestTargets(snapshot.input.files["Package.swift"]);
|
|
68175
68314
|
const swiftFiles = Object.keys(snapshot.input.files).filter(
|
|
68176
68315
|
(file) => file.endsWith(".swift")
|
|
68177
68316
|
);
|
|
68178
68317
|
const mixedTargets = /* @__PURE__ */ new Set([
|
|
68179
68318
|
...collection.targets.map(({ name: name3 }) => name3),
|
|
68180
|
-
...
|
|
68319
|
+
...installedTargets.filter(
|
|
68181
68320
|
(target) => swiftFiles.some((file) => file.startsWith(`${target.path}/`))
|
|
68182
68321
|
).map(({ name: name3 }) => name3)
|
|
68183
68322
|
]);
|
|
@@ -68218,6 +68357,23 @@ async function compileNitroModule(options) {
|
|
|
68218
68357
|
options.moduleRoot,
|
|
68219
68358
|
installedProviders ? [] : unresolvedFrameworkIncludes(collection.files)
|
|
68220
68359
|
);
|
|
68360
|
+
if (dependencies) {
|
|
68361
|
+
const podTargets = new Set(
|
|
68362
|
+
swiftManifestTargets(dependencies.files["Package.swift"]).map(
|
|
68363
|
+
({ name: name3 }) => name3
|
|
68364
|
+
)
|
|
68365
|
+
);
|
|
68366
|
+
for (const target of collection.targets) {
|
|
68367
|
+
const declared = installedTargets.find(({ name: name3 }) => name3 === target.name);
|
|
68368
|
+
const owned = new Set((target.dependencies ?? []).map(({ name: name3 }) => name3));
|
|
68369
|
+
target.dependencies = [
|
|
68370
|
+
...target.dependencies ?? [],
|
|
68371
|
+
...(declared?.dependencies ?? []).filter(
|
|
68372
|
+
(dependency) => dependency.kind === "target" && podTargets.has(dependency.name) && !owned.has(dependency.name)
|
|
68373
|
+
)
|
|
68374
|
+
];
|
|
68375
|
+
}
|
|
68376
|
+
}
|
|
68221
68377
|
}
|
|
68222
68378
|
const iosDeploymentTarget = readIosAppTarget(
|
|
68223
68379
|
options.projectRoot,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2250 | (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;
|
|
@@ -1421,7 +1421,7 @@ var run = (0, import_node_util.promisify)(import_node_child_process.execFile);
|
|
|
1421
1421
|
var import_plist5 = __toESM(require("plist"), 1);
|
|
1422
1422
|
|
|
1423
1423
|
// src/swift-standin-digest.ts
|
|
1424
|
-
var STANDIN_SOURCE_DIGEST = true ? "
|
|
1424
|
+
var STANDIN_SOURCE_DIGEST = true ? "977c30e838b3cb068d200b9a9a12851b01d2192d0d04e2b5a6abe8189c168d42" : standinSourceDigest();
|
|
1425
1425
|
|
|
1426
1426
|
// cli/commands/detect.ts
|
|
1427
1427
|
var import_json5 = __toESM(require_lib(), 1);
|
|
@@ -4516,7 +4516,7 @@ var FOUNDATION_IMPLICIT_MODULES = [
|
|
|
4516
4516
|
var FOUNDATION_IMPLICIT_FLAGS = FOUNDATION_IMPLICIT_MODULES.map(
|
|
4517
4517
|
(module2) => `, "-Xfrontend", "-import-module", "-Xfrontend", "${module2}"`
|
|
4518
4518
|
).join("");
|
|
4519
|
-
var compilerSourceDigest = true ? "
|
|
4519
|
+
var compilerSourceDigest = true ? "4a1be1d1296381c7090b5b2b704a7d2bebba03ceaa580613acd0f2c39c31ed4c" : swiftCompilerSourceDigest2(__sootsim_import_meta_dirname);
|
|
4520
4520
|
var CORE_FOUNDATION_HANDLE_IMPORTS = [
|
|
4521
4521
|
"CFAllocator",
|
|
4522
4522
|
"CFArray",
|
|
@@ -8927,7 +8927,7 @@ var import_node_module = require("node:module");
|
|
|
8927
8927
|
var import_node_path7 = require("node:path");
|
|
8928
8928
|
|
|
8929
8929
|
// runtime-companion.json
|
|
8930
|
-
var runtime_companion_default = { abi: 1, sha256: "
|
|
8930
|
+
var runtime_companion_default = { abi: 1, sha256: "15053b90437ccef5f18e3e8cde5732e85d2dc9feb3a3e76076cb671a640c465e", file: "node/cli-15053b90437ccef5f18e3e8cde5732e85d2dc9feb3a3e76076cb671a640c465e.cjs" };
|
|
8931
8931
|
|
|
8932
8932
|
// src/cli-runtime.ts
|
|
8933
8933
|
var CLI_COMPANION_ABI = 1;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2250 | (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 __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2250 | (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;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2250 | (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 __defProp = Object.defineProperty;
|