peachsim 0.1.2301 → 0.1.2303
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/commands/inspect.ts +2 -1
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.cjs +1 -1
- package/dist-lib/attached-projects.cjs +1 -1
- package/dist-lib/auth/shared-session.cjs +1 -1
- package/dist-lib/backend-origin.cjs +1 -1
- package/dist-lib/beta.cjs +1 -1
- package/dist-lib/beta.mjs +1 -1
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +1 -1
- package/dist-lib/bridge-contract-input.mjs +1 -1
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +1 -1
- package/dist-lib/bundle-channel.cjs +496 -312
- 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 +2 -2
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/expo-swift-bundle.cjs +447 -263
- 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 +493 -309
- 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 +4 -4
- 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 +4 -4
- 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 +1 -1
- package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
- package/dist-lib/sdk.cjs +1 -1
- package/dist-lib/sdk.mjs +1 -1
- package/dist-lib/skills.cjs +546 -362
- package/dist-lib/swift-compile.cjs +3 -17
- package/dist-lib/swift-compile.mjs +3 -16
- 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 +75 -18
- package/dist-lib/vite.cjs +4 -4
- package/dist-lib/worklet-executable.cjs +1 -1
- package/dist-lib/worklet-executable.mjs +1 -1
- package/dist-types/packages/peach-compat/src/stubs/native-seams/react-native-gesture-handler.d.ts +5 -20
- package/dist-types/packages/peach-engine/src/components/native-ui/webview-frame-bridge.d.ts +1 -0
- package/dist-types/packages/peach-engine/src/engine/native-layout.d.ts +1 -0
- package/dist-types/packages/peach-engine/src/render-worker/compositor-protocol.d.ts +4 -0
- package/dist-types/packages/peach-engine/src/render-worker/gesture-arbitration-native.d.ts +15 -2
- package/dist-types/packages/peach-kit/src/capabilities.d.ts +4 -0
- package/java-platform/licenses/fdlibm.txt +3 -0
- package/kotlin/sdk.tar.gz +0 -0
- package/package.json +1 -1
- package/runtime-companion.json +1 -1
- package/sdk/ios/System/Library/Frameworks/Accelerate.framework/Modules/module.modulemap +52 -0
- package/sdk/ios/System/Library/Frameworks/QuickLook.framework/Headers/QLPreviewController.h +1 -1
- package/src/core-data-model.ts +92 -3
- package/src/expo-native-workspace.ts +111 -39
- package/src/one-sdk-preparation.ts +61 -5
- package/src/swift-compile.ts +1 -25
- package/src/swift-packages.ts +22 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2303 | (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;
|
|
@@ -7703,7 +7703,7 @@ function linuxBrowserLibsKey(id, arch) {
|
|
|
7703
7703
|
return `linux-libs/${id}/${arch}.tar.gz`;
|
|
7704
7704
|
}
|
|
7705
7705
|
function missingLibraries(executablePath, libraryPath) {
|
|
7706
|
-
const ldd = (0,
|
|
7706
|
+
const ldd = (0, import_node_child_process13.spawnSync)("ldd", [executablePath], {
|
|
7707
7707
|
encoding: "utf8",
|
|
7708
7708
|
timeout: 3e4,
|
|
7709
7709
|
env: libraryPath ? {
|
|
@@ -7766,11 +7766,11 @@ async function ensureLinuxBrowserLibraries(executablePath, browser) {
|
|
|
7766
7766
|
}
|
|
7767
7767
|
return { ok: true, libraryPath };
|
|
7768
7768
|
}
|
|
7769
|
-
var
|
|
7769
|
+
var import_node_child_process13, import_node_fs26, import_node_path22, LINUX_BROWSER_LIBS_ARCHES, LINUX_BROWSER_LIBS_MARKER;
|
|
7770
7770
|
var init_linux_browser_libs = __esm({
|
|
7771
7771
|
"cli/drivers/linux-browser-libs.ts"() {
|
|
7772
7772
|
"use strict";
|
|
7773
|
-
|
|
7773
|
+
import_node_child_process13 = require("node:child_process");
|
|
7774
7774
|
import_node_fs26 = require("node:fs");
|
|
7775
7775
|
import_node_path22 = require("node:path");
|
|
7776
7776
|
init_src();
|
|
@@ -7938,7 +7938,7 @@ function ensureSwiftLinuxRuntime(release) {
|
|
|
7938
7938
|
`);
|
|
7939
7939
|
const download2 = `${plan.dest}.${process.pid}.tmp`;
|
|
7940
7940
|
try {
|
|
7941
|
-
(0,
|
|
7941
|
+
(0, import_node_child_process14.execFileSync)(
|
|
7942
7942
|
"curl",
|
|
7943
7943
|
[
|
|
7944
7944
|
"-fsSL",
|
|
@@ -8005,7 +8005,7 @@ function swiftCompilerRelease(release) {
|
|
|
8005
8005
|
}
|
|
8006
8006
|
function swiftToolchainBin(release) {
|
|
8007
8007
|
if (process.platform === "darwin") {
|
|
8008
|
-
const dirs = [
|
|
8008
|
+
const dirs = [import_node_os6.default.homedir(), "/"].map(
|
|
8009
8009
|
(base) => import_node_path25.default.join(base, `Library/Developer/Toolchains/${release}.xctoolchain/usr/bin`)
|
|
8010
8010
|
);
|
|
8011
8011
|
return dirs.find((dir) => import_node_fs30.default.existsSync(import_node_path25.default.join(dir, "swift"))) ?? dirs[0];
|
|
@@ -8051,7 +8051,7 @@ exec ${JSON.stringify(import_node_path25.default.join(toolchainBin, "wasm-ld"))}
|
|
|
8051
8051
|
}
|
|
8052
8052
|
function peachHome() {
|
|
8053
8053
|
const override = process.env.PEACH_HOME;
|
|
8054
|
-
return override ? import_node_path25.default.resolve(override) : import_node_path25.default.join(
|
|
8054
|
+
return override ? import_node_path25.default.resolve(override) : import_node_path25.default.join(import_node_os6.default.homedir(), ".peach");
|
|
8055
8055
|
}
|
|
8056
8056
|
function peachSwiftSdksDir() {
|
|
8057
8057
|
return process.env.PEACH_SWIFT_SDKS_PATH ?? import_node_path25.default.join(peachHome(), "swift", "sdks");
|
|
@@ -8060,7 +8060,7 @@ function agentSharedCacheRoot() {
|
|
|
8060
8060
|
if (process.platform !== "darwin" || !process.env.TM_SESSION) return null;
|
|
8061
8061
|
if (agentBuildersRoot) return agentBuildersRoot;
|
|
8062
8062
|
const policy = JSON.parse(
|
|
8063
|
-
(0,
|
|
8063
|
+
(0, import_node_child_process14.execFileSync)("tm", ["machine", "policy", "--json"], {
|
|
8064
8064
|
encoding: "utf8",
|
|
8065
8065
|
timeout: 3e4
|
|
8066
8066
|
})
|
|
@@ -8068,7 +8068,7 @@ function agentSharedCacheRoot() {
|
|
|
8068
8068
|
const mounts = policy.storage_mounts ?? [];
|
|
8069
8069
|
if (!Array.isArray(mounts)) throw new Error("storage_mounts must be a list");
|
|
8070
8070
|
const isMount = (directory2) => {
|
|
8071
|
-
const lines = (0,
|
|
8071
|
+
const lines = (0, import_node_child_process14.execFileSync)("/bin/df", ["-P", directory2], {
|
|
8072
8072
|
encoding: "utf8",
|
|
8073
8073
|
timeout: 3e4
|
|
8074
8074
|
}).trim().split("\n");
|
|
@@ -8083,13 +8083,13 @@ function agentSharedCacheRoot() {
|
|
|
8083
8083
|
throw new Error(`configured storage is not mounted: ${mount}`);
|
|
8084
8084
|
}
|
|
8085
8085
|
const heavy = policy.heavy_data_dir;
|
|
8086
|
-
if (heavy == null) return agentBuildersRoot = import_node_path25.default.join(
|
|
8086
|
+
if (heavy == null) return agentBuildersRoot = import_node_path25.default.join(import_node_os6.default.homedir(), "builders");
|
|
8087
8087
|
if (typeof heavy !== "string" || !import_node_path25.default.isAbsolute(heavy) || !import_node_fs30.default.statSync(heavy).isDirectory())
|
|
8088
8088
|
throw new Error(`configured heavy_data_dir is unavailable: ${heavy}`);
|
|
8089
8089
|
const mounted = isMount(heavy);
|
|
8090
8090
|
if (import_node_path25.default.dirname(heavy) === "/Volumes" && !mounted)
|
|
8091
8091
|
throw new Error(`configured storage is not mounted: ${heavy}`);
|
|
8092
|
-
return agentBuildersRoot = mounted && import_node_fs30.default.statSync(heavy).dev === import_node_fs30.default.statSync(
|
|
8092
|
+
return agentBuildersRoot = mounted && import_node_fs30.default.statSync(heavy).dev === import_node_fs30.default.statSync(import_node_os6.default.homedir()).dev ? import_node_path25.default.join(import_node_os6.default.homedir(), "builders") : import_node_path25.default.join(heavy, "builders");
|
|
8093
8093
|
}
|
|
8094
8094
|
function buildersRootEnv() {
|
|
8095
8095
|
const root = process.env[BUILDERS_ROOT_ENV]?.trim();
|
|
@@ -8187,7 +8187,7 @@ ${swiftInstallSteps(release, sdk2)}`
|
|
|
8187
8187
|
const swift = import_node_path25.default.join(bin, "swift");
|
|
8188
8188
|
const listed = [swift, sdk2.wasmSdkId, ...swiftSdkOptions()].join("\0");
|
|
8189
8189
|
if (!listedSdks.has(listed)) {
|
|
8190
|
-
const sdks = (0,
|
|
8190
|
+
const sdks = (0, import_node_child_process14.execFileSync)(swift, ["sdk", "list", ...swiftSdkOptions()], {
|
|
8191
8191
|
encoding: "utf8",
|
|
8192
8192
|
env: swiftEnvironment(),
|
|
8193
8193
|
stdio: ["ignore", "pipe", "pipe"]
|
|
@@ -8217,7 +8217,7 @@ function swiftSdkBundle(swift, id, options) {
|
|
|
8217
8217
|
const key2 = [swift, id, ...options].join("\0");
|
|
8218
8218
|
const known = sdkBundles.get(key2);
|
|
8219
8219
|
if (known && import_node_fs30.default.existsSync(known)) return known;
|
|
8220
|
-
const configuration = (0,
|
|
8220
|
+
const configuration = (0, import_node_child_process14.execFileSync)(
|
|
8221
8221
|
swift,
|
|
8222
8222
|
["sdk", "configure", ...options, "--show-configuration", id, "wasm64-unknown-wasip1"],
|
|
8223
8223
|
{ encoding: "utf8", env: swiftEnvironment(), stdio: ["ignore", "pipe", "pipe"] }
|
|
@@ -8319,7 +8319,7 @@ function installSwiftSdkArchive(swift, sdk2, archive) {
|
|
|
8319
8319
|
throw new Error("declared Swift SDK archive checksum mismatch");
|
|
8320
8320
|
const store = import_node_path25.default.join(staging, "sdks");
|
|
8321
8321
|
import_node_fs30.default.mkdirSync(store);
|
|
8322
|
-
(0,
|
|
8322
|
+
(0, import_node_child_process14.execFileSync)(
|
|
8323
8323
|
swift,
|
|
8324
8324
|
[
|
|
8325
8325
|
"sdk",
|
|
@@ -8339,7 +8339,7 @@ function installSwiftSdkArchive(swift, sdk2, archive) {
|
|
|
8339
8339
|
const expected = swiftSdkPayloadChecksum(stagedBundle);
|
|
8340
8340
|
const locks = import_node_path25.default.join(import_node_path25.default.resolve(peachSwiftSdksDir()), ".peach-locks");
|
|
8341
8341
|
import_node_fs30.default.mkdirSync(locks, { recursive: true });
|
|
8342
|
-
(0,
|
|
8342
|
+
(0, import_node_child_process14.execFileSync)(
|
|
8343
8343
|
"perl",
|
|
8344
8344
|
[
|
|
8345
8345
|
"-e",
|
|
@@ -8380,7 +8380,7 @@ function installSwiftSdkArchive(swift, sdk2, archive) {
|
|
|
8380
8380
|
}
|
|
8381
8381
|
}
|
|
8382
8382
|
function swiftSdkStagingDirectory(prefix) {
|
|
8383
|
-
const parent = scratch?.directory ??
|
|
8383
|
+
const parent = scratch?.directory ?? import_node_os6.default.tmpdir();
|
|
8384
8384
|
if (!import_node_fs30.default.existsSync(parent)) throw new Error(`Swift SDK install is missing ${parent}`);
|
|
8385
8385
|
return import_node_fs30.default.mkdtempSync(import_node_path25.default.join(parent, prefix));
|
|
8386
8386
|
}
|
|
@@ -8399,7 +8399,7 @@ function installSwiftWasmSdk(release, sdk2) {
|
|
|
8399
8399
|
if (sdk2.wasmSdkUrl.startsWith("file:"))
|
|
8400
8400
|
import_node_fs30.default.copyFileSync((0, import_node_url3.fileURLToPath)(sdk2.wasmSdkUrl), archive);
|
|
8401
8401
|
else
|
|
8402
|
-
(0,
|
|
8402
|
+
(0, import_node_child_process14.execFileSync)(
|
|
8403
8403
|
"curl",
|
|
8404
8404
|
[
|
|
8405
8405
|
"-fsSL",
|
|
@@ -8486,7 +8486,7 @@ async function swiftCompilerAsync(release, signal) {
|
|
|
8486
8486
|
throw new Error(`Swift compiler binary mismatch: ${relative3}`);
|
|
8487
8487
|
}
|
|
8488
8488
|
}
|
|
8489
|
-
const { stdout } = await (0, import_node_util6.promisify)(
|
|
8489
|
+
const { stdout } = await (0, import_node_util6.promisify)(import_node_child_process14.execFile)(binary2, ["--version"], {
|
|
8490
8490
|
encoding: "utf8",
|
|
8491
8491
|
env: swiftEnvironment(),
|
|
8492
8492
|
signal
|
|
@@ -8505,7 +8505,7 @@ function swiftCompiler(release) {
|
|
|
8505
8505
|
throw new Error(`Swift compiler ${release} is missing ${binary2}`);
|
|
8506
8506
|
if (release.includes("-custom-"))
|
|
8507
8507
|
verifySwiftHostCompiler(release, import_node_path25.default.resolve(bin, "../.."));
|
|
8508
|
-
const version2 = (0,
|
|
8508
|
+
const version2 = (0, import_node_child_process14.execFileSync)(binary2, ["--version"], {
|
|
8509
8509
|
encoding: "utf8",
|
|
8510
8510
|
env: swiftEnvironment(),
|
|
8511
8511
|
stdio: ["ignore", "pipe", "pipe"]
|
|
@@ -8576,14 +8576,14 @@ function swiftCompilerInstall(release) {
|
|
|
8576
8576
|
]
|
|
8577
8577
|
};
|
|
8578
8578
|
}
|
|
8579
|
-
var
|
|
8579
|
+
var import_node_child_process14, import_node_crypto10, import_node_fs30, import_node_os6, import_node_path25, import_node_url3, import_node_util6, SWIFT_HOST_COMPILER_RELEASE, SWIFT_HOST_COMPILER_ID, compilerArchives, linuxRuntimeLibs, SWIFT_PRIVATE_DISTRIBUTION_ENV, SWIFT_AUTOLINK_LINKER, BUILDERS_ROOT_ENV, agentBuildersRoot, scratch, linuxLibraryPath, linuxHostSdkRoot, listedSdks, sdkBundles, sdkFileHashes, sdkFilesHashed, loadedSdkHashFiles, verifiedCompilers;
|
|
8580
8580
|
var init_swift_toolchain = __esm({
|
|
8581
8581
|
"src/swift-toolchain.ts"() {
|
|
8582
8582
|
"use strict";
|
|
8583
|
-
|
|
8583
|
+
import_node_child_process14 = require("node:child_process");
|
|
8584
8584
|
import_node_crypto10 = require("node:crypto");
|
|
8585
8585
|
import_node_fs30 = __toESM(require("node:fs"), 1);
|
|
8586
|
-
|
|
8586
|
+
import_node_os6 = __toESM(require("node:os"), 1);
|
|
8587
8587
|
import_node_path25 = __toESM(require("node:path"), 1);
|
|
8588
8588
|
import_node_url3 = require("node:url");
|
|
8589
8589
|
import_node_util6 = require("node:util");
|
|
@@ -8875,7 +8875,7 @@ function swiftObjCPlatformFlags(toolchainBin, minimum) {
|
|
|
8875
8875
|
Math.floor(minimum % 1e4 / 100),
|
|
8876
8876
|
minimum % 100
|
|
8877
8877
|
].join(".");
|
|
8878
|
-
const result = (0,
|
|
8878
|
+
const result = (0, import_node_child_process15.spawnSync)(
|
|
8879
8879
|
import_node_path26.default.join(toolchainBin, "clang"),
|
|
8880
8880
|
[
|
|
8881
8881
|
"-target",
|
|
@@ -8908,11 +8908,11 @@ function swiftObjCPlatformFlags(toolchainBin, minimum) {
|
|
|
8908
8908
|
platforms.set(key2, flags);
|
|
8909
8909
|
return flags;
|
|
8910
8910
|
}
|
|
8911
|
-
var
|
|
8911
|
+
var import_node_child_process15, import_node_path26, platforms;
|
|
8912
8912
|
var init_swift_objc_platform = __esm({
|
|
8913
8913
|
"src/swift-objc-platform.ts"() {
|
|
8914
8914
|
"use strict";
|
|
8915
|
-
|
|
8915
|
+
import_node_child_process15 = require("node:child_process");
|
|
8916
8916
|
import_node_path26 = __toESM(require("node:path"), 1);
|
|
8917
8917
|
init_swift_toolchain();
|
|
8918
8918
|
platforms = /* @__PURE__ */ new Map();
|
|
@@ -10648,7 +10648,7 @@ function developerDirs() {
|
|
|
10648
10648
|
try {
|
|
10649
10649
|
add(
|
|
10650
10650
|
// runner-toolchain-platform: darwin
|
|
10651
|
-
(0,
|
|
10651
|
+
(0, import_node_child_process16.execFileSync)("xcode-select", ["-p"], {
|
|
10652
10652
|
encoding: "utf8",
|
|
10653
10653
|
stdio: ["ignore", "pipe", "pipe"]
|
|
10654
10654
|
}).trim()
|
|
@@ -10667,7 +10667,7 @@ function readNativeSdk(developerDir2) {
|
|
|
10667
10667
|
const env = { ...process.env, DEVELOPER_DIR: developerDir2 };
|
|
10668
10668
|
const xcrun = (args) => (
|
|
10669
10669
|
// runner-toolchain-platform: darwin
|
|
10670
|
-
(0,
|
|
10670
|
+
(0, import_node_child_process16.execFileSync)("xcrun", args, {
|
|
10671
10671
|
encoding: "utf8",
|
|
10672
10672
|
env,
|
|
10673
10673
|
stdio: ["ignore", "pipe", "pipe"]
|
|
@@ -10682,7 +10682,7 @@ function readNativeSdk(developerDir2) {
|
|
|
10682
10682
|
sdk: xcrun(["--sdk", "iphonesimulator", "--show-sdk-version"]),
|
|
10683
10683
|
settings: digest3("SDKSettings.json"),
|
|
10684
10684
|
build: digest3("System/Library/CoreServices/SystemVersion.plist"),
|
|
10685
|
-
compilerVersion: (0,
|
|
10685
|
+
compilerVersion: (0, import_node_child_process16.execFileSync)(compiler, ["--version"], {
|
|
10686
10686
|
encoding: "utf8",
|
|
10687
10687
|
env,
|
|
10688
10688
|
stdio: ["ignore", "pipe", "pipe"]
|
|
@@ -11152,7 +11152,7 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
|
|
|
11152
11152
|
for (let round = 0; ; round++) {
|
|
11153
11153
|
import_node_fs31.default.rmSync(out, { recursive: true, force: true });
|
|
11154
11154
|
import_node_fs31.default.mkdirSync(out, { recursive: true });
|
|
11155
|
-
const run8 = (0,
|
|
11155
|
+
const run8 = (0, import_node_child_process16.spawnSync)(
|
|
11156
11156
|
...withoutCoreDump(import_node_path28.default.join(toolchainBin, "swift-symbolgraph-extract"), [
|
|
11157
11157
|
"-module-name",
|
|
11158
11158
|
surface.module,
|
|
@@ -11337,7 +11337,7 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
|
|
|
11337
11337
|
)
|
|
11338
11338
|
].join("\n")
|
|
11339
11339
|
);
|
|
11340
|
-
const run8 = (0,
|
|
11340
|
+
const run8 = (0, import_node_child_process16.spawnSync)(
|
|
11341
11341
|
import_node_path28.default.join(toolchainBin, "swift-frontend"),
|
|
11342
11342
|
[
|
|
11343
11343
|
"-typecheck",
|
|
@@ -11465,7 +11465,7 @@ function inheritedDefaultInits(surface, graphs, toolchainBin, search, moduleCach
|
|
|
11465
11465
|
)
|
|
11466
11466
|
].join("\n")
|
|
11467
11467
|
);
|
|
11468
|
-
const run8 = (0,
|
|
11468
|
+
const run8 = (0, import_node_child_process16.spawnSync)(
|
|
11469
11469
|
import_node_path28.default.join(toolchainBin, "swift-frontend"),
|
|
11470
11470
|
[
|
|
11471
11471
|
"-dump-ast",
|
|
@@ -11538,7 +11538,7 @@ function requiredInits(surface, graphs, toolchainBin, search, moduleCache, work)
|
|
|
11538
11538
|
)
|
|
11539
11539
|
].join("\n")
|
|
11540
11540
|
);
|
|
11541
|
-
const run8 = (0,
|
|
11541
|
+
const run8 = (0, import_node_child_process16.spawnSync)(
|
|
11542
11542
|
import_node_path28.default.join(toolchainBin, "swift-frontend"),
|
|
11543
11543
|
[
|
|
11544
11544
|
"-typecheck",
|
|
@@ -11597,7 +11597,7 @@ function protocolProperties(surface, headersDir, graphs, toolchainBin, search, w
|
|
|
11597
11597
|
].map((file) => `#import ${JSON.stringify(file)}
|
|
11598
11598
|
`).join("")
|
|
11599
11599
|
);
|
|
11600
|
-
const run8 = (0,
|
|
11600
|
+
const run8 = (0, import_node_child_process16.spawnSync)(
|
|
11601
11601
|
import_node_path28.default.join(toolchainBin, "clang"),
|
|
11602
11602
|
[
|
|
11603
11603
|
"-x",
|
|
@@ -11680,7 +11680,7 @@ function objcDeclarationAST(surface, framework, toolchainBin, search, work, orig
|
|
|
11680
11680
|
"-ast-dump-all=json"
|
|
11681
11681
|
];
|
|
11682
11682
|
const dump2 = (filter) => {
|
|
11683
|
-
const run8 = (0,
|
|
11683
|
+
const run8 = (0, import_node_child_process16.spawnSync)(
|
|
11684
11684
|
import_node_path28.default.join(toolchainBin, "clang"),
|
|
11685
11685
|
[
|
|
11686
11686
|
...args,
|
|
@@ -11762,7 +11762,7 @@ function enumValues(graphs, surface, framework, toolchainBin, search, work, orig
|
|
|
11762
11762
|
if (flag === "-sdk") flags.push("-isysroot", dir);
|
|
11763
11763
|
else flags.push(flag, dir);
|
|
11764
11764
|
}
|
|
11765
|
-
const run8 = (0,
|
|
11765
|
+
const run8 = (0, import_node_child_process16.spawnSync)(
|
|
11766
11766
|
import_node_path28.default.join(toolchainBin, "clang"),
|
|
11767
11767
|
[
|
|
11768
11768
|
"-x",
|
|
@@ -11837,11 +11837,11 @@ function constantValue(node) {
|
|
|
11837
11837
|
}
|
|
11838
11838
|
return null;
|
|
11839
11839
|
}
|
|
11840
|
-
var
|
|
11840
|
+
var import_node_child_process16, import_node_crypto11, import_node_fs31, import_node_path28, REFINED_CONSTANT_TYPES, NATIVE_GRAPH_SDK_VERSION, WASI_EMULATION, WASI_EMULATION_FLAGS, NATIVE_GRAPH_INPUTS, NATIVE_GRAPH_ID, resolvedPinnedSdk, ROUNDS, sdkId, headerFiles, MISSING_IMPORT, FRAMEWORK_HEADER, FRAMEWORK_MODULEMAP, sdkDeclarations;
|
|
11841
11841
|
var init_swift_objc_standin = __esm({
|
|
11842
11842
|
"src/swift-objc-standin.ts"() {
|
|
11843
11843
|
"use strict";
|
|
11844
|
-
|
|
11844
|
+
import_node_child_process16 = require("node:child_process");
|
|
11845
11845
|
import_node_crypto11 = require("node:crypto");
|
|
11846
11846
|
import_node_fs31 = __toESM(require("node:fs"), 1);
|
|
11847
11847
|
import_node_path28 = __toESM(require("node:path"), 1);
|
|
@@ -12102,7 +12102,7 @@ function swiftSharedSdkViewOptions(moduleRoot, distribution, toolchainBin, sdk2)
|
|
|
12102
12102
|
]);
|
|
12103
12103
|
const cached2 = sdkViews.get(key2);
|
|
12104
12104
|
if (cached2 && import_node_fs32.default.existsSync(cached2.manifest)) return touchSdkView(cached2.options);
|
|
12105
|
-
const configuration = (0,
|
|
12105
|
+
const configuration = (0, import_node_child_process17.execFileSync)(
|
|
12106
12106
|
import_node_path29.default.join(toolchainBin, "swift"),
|
|
12107
12107
|
[
|
|
12108
12108
|
"sdk",
|
|
@@ -12231,11 +12231,11 @@ function swiftSharedSdkInputFiles(moduleRoot) {
|
|
|
12231
12231
|
const root = swiftSharedSdkRoot(moduleRoot, false);
|
|
12232
12232
|
return (0, import_node_fs32.readdirSync)(root, { recursive: true, withFileTypes: true }).filter((entry) => entry.isFile()).map((entry) => import_node_path29.default.relative(moduleRoot, import_node_path29.default.join(entry.parentPath, entry.name))).sort();
|
|
12233
12233
|
}
|
|
12234
|
-
var
|
|
12234
|
+
var import_node_child_process17, import_node_crypto12, import_node_fs32, import_node_path29, distributionHeaderRoots, WEAKEN_FOUNDATION_SYMS, sdkViews;
|
|
12235
12235
|
var init_swift_shared_sdk = __esm({
|
|
12236
12236
|
"src/swift-shared-sdk.ts"() {
|
|
12237
12237
|
"use strict";
|
|
12238
|
-
|
|
12238
|
+
import_node_child_process17 = require("node:child_process");
|
|
12239
12239
|
import_node_crypto12 = require("node:crypto");
|
|
12240
12240
|
import_node_fs32 = __toESM(require("node:fs"), 1);
|
|
12241
12241
|
import_node_path29 = __toESM(require("node:path"), 1);
|
|
@@ -12258,14 +12258,14 @@ var init_swift_shared_sdk = __esm({
|
|
|
12258
12258
|
// src/swift-darwin-records.ts
|
|
12259
12259
|
function compileDarwinRecords(args) {
|
|
12260
12260
|
const records = import_node_path30.default.join(args.packageRoot, "Sources/DarwinRecords");
|
|
12261
|
-
const runtime = (0, import_node_fs33.mkdtempSync)(import_node_path30.default.join((0,
|
|
12261
|
+
const runtime = (0, import_node_fs33.mkdtempSync)(import_node_path30.default.join((0, import_node_os7.tmpdir)(), "peach-objc-runtime-"));
|
|
12262
12262
|
(0, import_node_fs33.symlinkSync)(import_node_path30.default.join(args.darwin, "usr/include/objc"), import_node_path30.default.join(runtime, "objc"));
|
|
12263
12263
|
const objects = (0, import_node_fs33.readdirSync)(records).filter((file) => file.endsWith(".c") || file.endsWith(".m")).sort((a, b) => a < b ? -1 : a > b ? 1 : 0).map((file) => {
|
|
12264
12264
|
const object6 = import_node_path30.default.join(
|
|
12265
12265
|
args.out,
|
|
12266
12266
|
`${DARWIN_RECORDS_PREFIX}${file.replace(/\.[cm]$/, ".o")}`
|
|
12267
12267
|
);
|
|
12268
|
-
(0,
|
|
12268
|
+
(0, import_node_child_process18.execFileSync)(
|
|
12269
12269
|
import_node_path30.default.join(args.bin, "clang"),
|
|
12270
12270
|
[
|
|
12271
12271
|
"--target=wasm64-unknown-wasip1",
|
|
@@ -12300,13 +12300,13 @@ function compileDarwinRecords(args) {
|
|
|
12300
12300
|
(0, import_node_fs33.rmSync)(runtime, { recursive: true });
|
|
12301
12301
|
return objects;
|
|
12302
12302
|
}
|
|
12303
|
-
var
|
|
12303
|
+
var import_node_child_process18, import_node_fs33, import_node_os7, import_node_path30, DARWIN_RECORDS_PREFIX, darwinRecordsMinimum;
|
|
12304
12304
|
var init_swift_darwin_records = __esm({
|
|
12305
12305
|
"src/swift-darwin-records.ts"() {
|
|
12306
12306
|
"use strict";
|
|
12307
|
-
|
|
12307
|
+
import_node_child_process18 = require("node:child_process");
|
|
12308
12308
|
import_node_fs33 = require("node:fs");
|
|
12309
|
-
|
|
12309
|
+
import_node_os7 = require("node:os");
|
|
12310
12310
|
import_node_path30 = __toESM(require("node:path"), 1);
|
|
12311
12311
|
init_swift_objc_platform();
|
|
12312
12312
|
init_swift_objc_runtime();
|
|
@@ -14936,18 +14936,18 @@ function pruneSwiftWasmLink(directory2, toolchainBin, moduleRoot, staticClangTar
|
|
|
14936
14936
|
transformations
|
|
14937
14937
|
});
|
|
14938
14938
|
} else
|
|
14939
|
-
(0,
|
|
14939
|
+
(0, import_node_child_process19.execFileSync)(import_node_path31.default.join(toolchainBin, "wasm-ld"), [`@${prunedRspPath}`], {
|
|
14940
14940
|
stdio: "pipe",
|
|
14941
14941
|
maxBuffer: Infinity,
|
|
14942
14942
|
...owner
|
|
14943
14943
|
});
|
|
14944
14944
|
import_node_fs34.default.rmSync(rspPath, { force: true });
|
|
14945
14945
|
}
|
|
14946
|
-
var
|
|
14946
|
+
var import_node_child_process19, import_node_crypto13, import_node_fs34, import_node_path31, v2, HAS_ADDEND, WIDE_DATA_RELOCS, ROOT_SEG_PREFIXES, RECORD_SEGS, PARTITIONED_SEGS, PRUNED_SDK_ARCHIVES, OMIT_SDK_LIB_FLAGS, NEUTRALIZED_SWIFTRT_SECTIONS, parsedObjectCache, SWIFTUI_WRAPPER_HOST_PROTOCOLS;
|
|
14947
14947
|
var init_swift_wasm_prune = __esm({
|
|
14948
14948
|
"src/swift-wasm-prune.ts"() {
|
|
14949
14949
|
"use strict";
|
|
14950
|
-
|
|
14950
|
+
import_node_child_process19 = require("node:child_process");
|
|
14951
14951
|
import_node_crypto13 = require("node:crypto");
|
|
14952
14952
|
import_node_fs34 = __toESM(require("node:fs"), 1);
|
|
14953
14953
|
import_node_path31 = __toESM(require("node:path"), 1);
|
|
@@ -15038,7 +15038,7 @@ var init_swift_wasm_prune = __esm({
|
|
|
15038
15038
|
// src/swift-guest-archive.ts
|
|
15039
15039
|
function aliasGuestArchive(options) {
|
|
15040
15040
|
const original = readArMembers((0, import_node_fs35.readFileSync)(options.archive));
|
|
15041
|
-
const listed = (0,
|
|
15041
|
+
const listed = (0, import_node_child_process20.execFileSync)(options.llvmAr, ["t", options.archive], {
|
|
15042
15042
|
encoding: "utf8"
|
|
15043
15043
|
}).trimEnd().split("\n");
|
|
15044
15044
|
if (!original.length || listed.length !== original.length || original.some((member, index) => member.name !== listed[index]))
|
|
@@ -15064,7 +15064,7 @@ function aliasGuestArchive(options) {
|
|
|
15064
15064
|
);
|
|
15065
15065
|
const archive = import_node_path32.default.join(options.directory, "archive.a");
|
|
15066
15066
|
(0, import_node_fs35.rmSync)(archive, { force: true });
|
|
15067
|
-
(0,
|
|
15067
|
+
(0, import_node_child_process20.execFileSync)(options.llvmAr, ["rcsD", archive, `@${response}`], { stdio: "pipe" });
|
|
15068
15068
|
const rewritten = readArMembers((0, import_node_fs35.readFileSync)(archive));
|
|
15069
15069
|
if (rewritten.length !== members2.length || rewritten.some(
|
|
15070
15070
|
(member, index) => member.name !== members2[index].alias || (0, import_node_crypto14.createHash)("sha256").update(member.bytes).digest("hex") !== members2[index].sha256
|
|
@@ -15099,11 +15099,11 @@ function aliasGuestLinkIdentities(identities, archives) {
|
|
|
15099
15099
|
}
|
|
15100
15100
|
return result;
|
|
15101
15101
|
}
|
|
15102
|
-
var
|
|
15102
|
+
var import_node_child_process20, import_node_crypto14, import_node_fs35, import_node_path32;
|
|
15103
15103
|
var init_swift_guest_archive = __esm({
|
|
15104
15104
|
"src/swift-guest-archive.ts"() {
|
|
15105
15105
|
"use strict";
|
|
15106
|
-
|
|
15106
|
+
import_node_child_process20 = require("node:child_process");
|
|
15107
15107
|
import_node_crypto14 = require("node:crypto");
|
|
15108
15108
|
import_node_fs35 = require("node:fs");
|
|
15109
15109
|
import_node_path32 = __toESM(require("node:path"), 1);
|
|
@@ -17442,7 +17442,7 @@ function linkGuestImages(options) {
|
|
|
17442
17442
|
);
|
|
17443
17443
|
const output2 = import_node_fs38.default.openSync(trace, "w");
|
|
17444
17444
|
try {
|
|
17445
|
-
(0,
|
|
17445
|
+
(0, import_node_child_process21.execFileSync)(wasmLd, [`@${response}`], { stdio: ["ignore", output2, "pipe"] });
|
|
17446
17446
|
} finally {
|
|
17447
17447
|
import_node_fs38.default.closeSync(output2);
|
|
17448
17448
|
}
|
|
@@ -17456,7 +17456,7 @@ function linkGuestImages(options) {
|
|
|
17456
17456
|
source,
|
|
17457
17457
|
'#include "guest-image-projection.h"\nconst struct peach_guest_image __peach_guest_images[] = {{0}};\nconst uint32_t __peach_guest_image_count = 0;\n'
|
|
17458
17458
|
);
|
|
17459
|
-
(0,
|
|
17459
|
+
(0, import_node_child_process21.execFileSync)(
|
|
17460
17460
|
clang,
|
|
17461
17461
|
[...options.projection.clangOptions, "-c", source, "-o", discoveryProjection],
|
|
17462
17462
|
{ stdio: "pipe" }
|
|
@@ -17570,7 +17570,7 @@ function linkGuestImages(options) {
|
|
|
17570
17570
|
}
|
|
17571
17571
|
const members2 = archives.get(artifact.path);
|
|
17572
17572
|
if (!members2) continue;
|
|
17573
|
-
const listed = (0,
|
|
17573
|
+
const listed = (0, import_node_child_process21.execFileSync)(llvmAr, ["t", artifact.path], { encoding: "utf8" }).trimEnd().split("\n");
|
|
17574
17574
|
if (listed.length !== members2.length || new Set(listed).size !== listed.length || members2.some(
|
|
17575
17575
|
(member, i) => listed[i] !== member.name || import_node_path35.default.basename(member.name) !== member.name
|
|
17576
17576
|
))
|
|
@@ -17593,13 +17593,13 @@ function linkGuestImages(options) {
|
|
|
17593
17593
|
import_node_fs38.default.rmSync(output2, { force: true });
|
|
17594
17594
|
const response = import_node_path35.default.join(memberDir, "members.rsp");
|
|
17595
17595
|
import_node_fs38.default.writeFileSync(response, inputs.map((input) => JSON.stringify(input)).join(" "));
|
|
17596
|
-
(0,
|
|
17596
|
+
(0, import_node_child_process21.execFileSync)(llvmAr, ["rcs", output2, `@${response}`], { stdio: "pipe" });
|
|
17597
17597
|
replacements.set(artifact.path, output2);
|
|
17598
17598
|
}
|
|
17599
17599
|
const irPath = import_node_path35.default.join(directory2, "ledger.ll");
|
|
17600
17600
|
const ledgerObject = import_node_path35.default.join(directory2, "ledger.o");
|
|
17601
17601
|
import_node_fs38.default.writeFileSync(irPath, ledger.llvmIR);
|
|
17602
|
-
(0,
|
|
17602
|
+
(0, import_node_child_process21.execFileSync)(
|
|
17603
17603
|
clang,
|
|
17604
17604
|
["--target=wasm64-unknown-wasip1", "-c", irPath, "-o", ledgerObject],
|
|
17605
17605
|
{ stdio: "pipe" }
|
|
@@ -17641,7 +17641,7 @@ function linkGuestImages(options) {
|
|
|
17641
17641
|
const projectionSource = import_node_path35.default.join(directory2, "projection.c");
|
|
17642
17642
|
projectionObject = import_node_path35.default.join(directory2, "projection.o");
|
|
17643
17643
|
import_node_fs38.default.writeFileSync(projectionSource, projectionStorage.source);
|
|
17644
|
-
(0,
|
|
17644
|
+
(0, import_node_child_process21.execFileSync)(
|
|
17645
17645
|
clang,
|
|
17646
17646
|
[...projection.clangOptions, "-c", projectionSource, "-o", projectionObject],
|
|
17647
17647
|
{
|
|
@@ -17818,7 +17818,7 @@ function discoverGuestLinkInputs(options) {
|
|
|
17818
17818
|
const trace = import_node_path35.default.join(options.directory, "preselection-inputs.txt");
|
|
17819
17819
|
const traceOutput = import_node_fs38.default.openSync(trace, "w");
|
|
17820
17820
|
try {
|
|
17821
|
-
(0,
|
|
17821
|
+
(0, import_node_child_process21.execFileSync)(options.wasmLd, [`@${response}`], {
|
|
17822
17822
|
stdio: ["ignore", traceOutput, "pipe"]
|
|
17823
17823
|
});
|
|
17824
17824
|
} finally {
|
|
@@ -17976,7 +17976,7 @@ function verifyGuestSymbolScopes(options) {
|
|
|
17976
17976
|
const tracePath = import_node_path35.default.join(options.directory, "scope-trace.txt");
|
|
17977
17977
|
const traceOutput = import_node_fs38.default.openSync(tracePath, "w");
|
|
17978
17978
|
try {
|
|
17979
|
-
(0,
|
|
17979
|
+
(0, import_node_child_process21.execFileSync)(options.wasmLd, [`@${response}`], {
|
|
17980
17980
|
stdio: ["ignore", traceOutput, "pipe"]
|
|
17981
17981
|
});
|
|
17982
17982
|
} finally {
|
|
@@ -18242,11 +18242,11 @@ function linkPrunedGuestImages(options) {
|
|
|
18242
18242
|
if (!result) throw new Error("guest link did not receive pruned inputs");
|
|
18243
18243
|
return result;
|
|
18244
18244
|
}
|
|
18245
|
-
var
|
|
18245
|
+
var import_node_child_process21, import_node_fs38, import_node_path35, import_node_string_decoder;
|
|
18246
18246
|
var init_swift_guest_link = __esm({
|
|
18247
18247
|
"src/swift-guest-link.ts"() {
|
|
18248
18248
|
"use strict";
|
|
18249
|
-
|
|
18249
|
+
import_node_child_process21 = require("node:child_process");
|
|
18250
18250
|
import_node_fs38 = __toESM(require("node:fs"), 1);
|
|
18251
18251
|
import_node_path35 = __toESM(require("node:path"), 1);
|
|
18252
18252
|
import_node_string_decoder = require("node:string_decoder");
|
|
@@ -18350,7 +18350,7 @@ function sourceGuestClangLinkOptions(options) {
|
|
|
18350
18350
|
throw new Error(`missing clang ${flag} for ${file}`);
|
|
18351
18351
|
args[index2 + 1] = flag === "-o" ? output2 : `${output2}.d`;
|
|
18352
18352
|
}
|
|
18353
|
-
(0,
|
|
18353
|
+
(0, import_node_child_process22.execFileSync)(command.args[0], [...args, "-S", "-emit-llvm"], { stdio: "inherit" });
|
|
18354
18354
|
const flags = clangIrLinkOptions((0, import_node_fs39.readFileSync)(output2, "utf8"));
|
|
18355
18355
|
for (let index2 = 0; index2 < flags.length; index2++) {
|
|
18356
18356
|
const flag = flags[index2];
|
|
@@ -18488,7 +18488,7 @@ function sourceGuestRuntimeLinks(options) {
|
|
|
18488
18488
|
response,
|
|
18489
18489
|
image.objects.map((file) => JSON.stringify(file)).join("\n") + "\n"
|
|
18490
18490
|
);
|
|
18491
|
-
const autolink = image.objects.length ? (0,
|
|
18491
|
+
const autolink = image.objects.length ? (0, import_node_child_process22.execFileSync)(
|
|
18492
18492
|
import_node_path36.default.join(options.toolchainBin, "swift-autolink-extract"),
|
|
18493
18493
|
[`@${response}`, "-o", "-"],
|
|
18494
18494
|
{ encoding: "utf8" }
|
|
@@ -18581,11 +18581,11 @@ function logicalGuestLinkOptions(args, identities, roots) {
|
|
|
18581
18581
|
}
|
|
18582
18582
|
return output2;
|
|
18583
18583
|
}
|
|
18584
|
-
var
|
|
18584
|
+
var import_node_child_process22, import_node_crypto17, import_node_fs39, import_node_path36, CLANG_TARGET_MODULE_WRAPPER;
|
|
18585
18585
|
var init_swift_guest_source_inputs = __esm({
|
|
18586
18586
|
"src/swift-guest-source-inputs.ts"() {
|
|
18587
18587
|
"use strict";
|
|
18588
|
-
|
|
18588
|
+
import_node_child_process22 = require("node:child_process");
|
|
18589
18589
|
import_node_crypto17 = require("node:crypto");
|
|
18590
18590
|
import_node_fs39 = require("node:fs");
|
|
18591
18591
|
import_node_path36 = __toESM(require("node:path"), 1);
|
|
@@ -18854,7 +18854,7 @@ async function runWasmOpt(file, output2, optimize, skipPasses, binary2) {
|
|
|
18854
18854
|
const thunks = `${output2}.thunks.wat`;
|
|
18855
18855
|
(0, import_node_fs40.writeFileSync)(guest, narrowed.module);
|
|
18856
18856
|
(0, import_node_fs40.writeFileSync)(thunks, narrowed.thunks);
|
|
18857
|
-
await (0, import_node_util7.promisify)(
|
|
18857
|
+
await (0, import_node_util7.promisify)(import_node_child_process23.execFile)((0, import_node_path37.join)((0, import_node_path37.dirname)(binary2), "wasm-merge"), [
|
|
18858
18858
|
...features,
|
|
18859
18859
|
...names,
|
|
18860
18860
|
guest,
|
|
@@ -18913,11 +18913,11 @@ async function lowerWasm(file, output2, options) {
|
|
|
18913
18913
|
await installWasmOpt()
|
|
18914
18914
|
);
|
|
18915
18915
|
}
|
|
18916
|
-
var
|
|
18916
|
+
var import_node_child_process23, import_node_fs40, import_node_path37, import_node_util7, import_wasm_opt, FEATURES, KEEP_WASM_NAMES, LOWERING, WASM_LOWER_IDENTITY, PINNED_BINARYEN_VERSION, BINARYEN_RELEASES;
|
|
18917
18917
|
var init_wasm_optimize = __esm({
|
|
18918
18918
|
"src/wasm-optimize.ts"() {
|
|
18919
18919
|
"use strict";
|
|
18920
|
-
|
|
18920
|
+
import_node_child_process23 = require("node:child_process");
|
|
18921
18921
|
import_node_fs40 = require("node:fs");
|
|
18922
18922
|
import_node_path37 = require("node:path");
|
|
18923
18923
|
import_node_util7 = require("node:util");
|
|
@@ -19016,7 +19016,7 @@ async function compileGuestLink(options) {
|
|
|
19016
19016
|
stubSource,
|
|
19017
19017
|
'#include "guest-image-projection.h"\nconst struct peach_guest_image __peach_guest_images[] = {{0}};\nconst uint32_t __peach_guest_image_count = 0;\n'
|
|
19018
19018
|
);
|
|
19019
|
-
(0,
|
|
19019
|
+
(0, import_node_child_process24.execFileSync)(
|
|
19020
19020
|
import_node_path38.default.join(options.toolchainBin, "clang"),
|
|
19021
19021
|
[...clangOptions, "-c", stubSource, "-o", stub],
|
|
19022
19022
|
{ stdio: "pipe" }
|
|
@@ -19333,11 +19333,11 @@ async function compileGuestLink(options) {
|
|
|
19333
19333
|
});
|
|
19334
19334
|
(0, import_node_fs41.writeFileSync)(options.optimized, finalized.wasm);
|
|
19335
19335
|
}
|
|
19336
|
-
var
|
|
19336
|
+
var import_node_child_process24, import_node_fs41, import_node_path38;
|
|
19337
19337
|
var init_swift_guest_compile = __esm({
|
|
19338
19338
|
"src/swift-guest-compile.ts"() {
|
|
19339
19339
|
"use strict";
|
|
19340
|
-
|
|
19340
|
+
import_node_child_process24 = require("node:child_process");
|
|
19341
19341
|
import_node_fs41 = require("node:fs");
|
|
19342
19342
|
import_node_path38 = __toESM(require("node:path"), 1);
|
|
19343
19343
|
init_swift_guest_archive();
|
|
@@ -19528,7 +19528,7 @@ function swiftIcuAddress(icu) {
|
|
|
19528
19528
|
function swiftIcuPacked(icu) {
|
|
19529
19529
|
return memo(packedFiles, icu.sha256, async () => {
|
|
19530
19530
|
const file = import_node_path39.default.join(
|
|
19531
|
-
|
|
19531
|
+
import_node_os8.default.homedir(),
|
|
19532
19532
|
".peach",
|
|
19533
19533
|
"cache",
|
|
19534
19534
|
"swift-brotli",
|
|
@@ -19555,21 +19555,21 @@ async function swiftIcuBundleAsset(icu) {
|
|
|
19555
19555
|
contentType: "application/octet-stream"
|
|
19556
19556
|
};
|
|
19557
19557
|
}
|
|
19558
|
-
var
|
|
19558
|
+
var import_node_child_process25, import_node_crypto18, import_node_fs42, import_promises4, import_node_os8, import_node_path39, import_node_util8, import_node_zlib2, run5, deflate, compressBrotli, inflateGzip, ARCHIVE, MEMBER, raw, assets, packedFiles;
|
|
19559
19559
|
var init_swift_icu = __esm({
|
|
19560
19560
|
"src/swift-icu.ts"() {
|
|
19561
19561
|
"use strict";
|
|
19562
|
-
|
|
19562
|
+
import_node_child_process25 = require("node:child_process");
|
|
19563
19563
|
import_node_crypto18 = require("node:crypto");
|
|
19564
19564
|
import_node_fs42 = require("node:fs");
|
|
19565
19565
|
import_promises4 = require("node:fs/promises");
|
|
19566
|
-
|
|
19566
|
+
import_node_os8 = __toESM(require("node:os"), 1);
|
|
19567
19567
|
import_node_path39 = __toESM(require("node:path"), 1);
|
|
19568
19568
|
import_node_util8 = require("node:util");
|
|
19569
19569
|
import_node_zlib2 = require("node:zlib");
|
|
19570
19570
|
init_icuData();
|
|
19571
19571
|
init_swift_toolchain();
|
|
19572
|
-
run5 = (0, import_node_util8.promisify)(
|
|
19572
|
+
run5 = (0, import_node_util8.promisify)(import_node_child_process25.execFile);
|
|
19573
19573
|
deflate = (0, import_node_util8.promisify)(import_node_zlib2.gzip);
|
|
19574
19574
|
compressBrotli = (0, import_node_util8.promisify)(import_node_zlib2.brotliCompress);
|
|
19575
19575
|
inflateGzip = (0, import_node_util8.promisify)(import_node_zlib2.gunzip);
|
|
@@ -19752,7 +19752,7 @@ function prepareSwiftProjectProcess(root, user) {
|
|
|
19752
19752
|
(0, import_node_fs44.mkdirSync)(tmp, { recursive: true });
|
|
19753
19753
|
const caches = ["cache", "config", "security"].map((name3) => import_node_path41.default.join(swiftpm, name3));
|
|
19754
19754
|
for (const directory2 of caches) (0, import_node_fs44.mkdirSync)(directory2, { recursive: true });
|
|
19755
|
-
(0,
|
|
19755
|
+
(0, import_node_child_process26.execFileSync)("chown", ["-R", "-P", `${user.uid}:${user.gid}`, root, home]);
|
|
19756
19756
|
(0, import_node_fs44.chmodSync)(root, 448);
|
|
19757
19757
|
(0, import_node_fs44.chmodSync)(home, 448);
|
|
19758
19758
|
return {
|
|
@@ -19775,7 +19775,7 @@ function prepareSwiftProjectProcess(root, user) {
|
|
|
19775
19775
|
};
|
|
19776
19776
|
}
|
|
19777
19777
|
function endSwiftProjectProcesses(user) {
|
|
19778
|
-
(0,
|
|
19778
|
+
(0, import_node_child_process26.execFileSync)("sh", ["-c", "kill -s KILL -- -1 2>/dev/null || true"], {
|
|
19779
19779
|
uid: user.uid,
|
|
19780
19780
|
gid: user.gid
|
|
19781
19781
|
});
|
|
@@ -19802,11 +19802,11 @@ function removeProjectLinks(root) {
|
|
|
19802
19802
|
}
|
|
19803
19803
|
}
|
|
19804
19804
|
}
|
|
19805
|
-
var
|
|
19805
|
+
var import_node_child_process26, import_node_fs44, import_node_path41;
|
|
19806
19806
|
var init_swift_project_user = __esm({
|
|
19807
19807
|
"src/swift-project-user.ts"() {
|
|
19808
19808
|
"use strict";
|
|
19809
|
-
|
|
19809
|
+
import_node_child_process26 = require("node:child_process");
|
|
19810
19810
|
import_node_fs44 = require("node:fs");
|
|
19811
19811
|
import_node_path41 = __toESM(require("node:path"), 1);
|
|
19812
19812
|
}
|
|
@@ -19814,7 +19814,7 @@ var init_swift_project_user = __esm({
|
|
|
19814
19814
|
|
|
19815
19815
|
// src/swift-reproducible.ts
|
|
19816
19816
|
function swiftReproducibleBuildFlags(roots) {
|
|
19817
|
-
return [[
|
|
19817
|
+
return [[import_node_os9.default.homedir(), "home"], ...roots].flatMap(
|
|
19818
19818
|
([root, name3]) => [.../* @__PURE__ */ new Set([root, (0, import_node_fs45.realpathSync)(root)])].map((from) => `${from}=/peach/${name3}`)
|
|
19819
19819
|
).flatMap((map2) => [
|
|
19820
19820
|
"-Xswiftc",
|
|
@@ -19827,12 +19827,12 @@ function swiftReproducibleBuildFlags(roots) {
|
|
|
19827
19827
|
`-ffile-prefix-map=${map2}`
|
|
19828
19828
|
]);
|
|
19829
19829
|
}
|
|
19830
|
-
var import_node_fs45,
|
|
19830
|
+
var import_node_fs45, import_node_os9;
|
|
19831
19831
|
var init_swift_reproducible = __esm({
|
|
19832
19832
|
"src/swift-reproducible.ts"() {
|
|
19833
19833
|
"use strict";
|
|
19834
19834
|
import_node_fs45 = require("node:fs");
|
|
19835
|
-
|
|
19835
|
+
import_node_os9 = __toESM(require("node:os"), 1);
|
|
19836
19836
|
}
|
|
19837
19837
|
});
|
|
19838
19838
|
|
|
@@ -19919,11 +19919,11 @@ function groupAlive(table, leader) {
|
|
|
19919
19919
|
return table.some((candidate) => candidate.pgid === leader.pid && !candidate.zombie);
|
|
19920
19920
|
}
|
|
19921
19921
|
function swiftRootLocksDir() {
|
|
19922
|
-
return import_node_path42.default.join((0,
|
|
19922
|
+
return import_node_path42.default.join((0, import_node_os10.homedir)(), ".peach", "cache", "swift-root-locks");
|
|
19923
19923
|
}
|
|
19924
19924
|
function withCocoaPodsCacheLock(work) {
|
|
19925
19925
|
return withSwiftRootLock(
|
|
19926
|
-
process.env.CP_CACHE_DIR || import_node_path42.default.join((0,
|
|
19926
|
+
process.env.CP_CACHE_DIR || import_node_path42.default.join((0, import_node_os10.homedir)(), "Library/Caches/CocoaPods"),
|
|
19927
19927
|
work
|
|
19928
19928
|
);
|
|
19929
19929
|
}
|
|
@@ -20000,7 +20000,7 @@ async function withSwiftRootLock(root, work, signal, wait = true) {
|
|
|
20000
20000
|
}
|
|
20001
20001
|
},
|
|
20002
20002
|
spawn(command, args, options, companion) {
|
|
20003
|
-
const child = (0,
|
|
20003
|
+
const child = (0, import_node_child_process27.spawn)(
|
|
20004
20004
|
"/bin/sh",
|
|
20005
20005
|
["-c", 'IFS= read -r go || exit 1; exec "$@" </dev/null', "sh", command, ...args],
|
|
20006
20006
|
{ ...options, detached: true, stdio: ["pipe", "pipe", "pipe"] }
|
|
@@ -20030,14 +20030,14 @@ async function withSwiftRootLock(root, work, signal, wait = true) {
|
|
|
20030
20030
|
(0, import_node_fs46.writeFileSync)(import_node_path42.default.join(directory2, name2(held, "released")), "");
|
|
20031
20031
|
}
|
|
20032
20032
|
}
|
|
20033
|
-
var
|
|
20033
|
+
var import_node_child_process27, import_node_crypto19, import_node_fs46, import_node_os10, import_node_path42, POLL_MS, INSPECT_ATTEMPTS, START_TOLERANCE_MS, name2;
|
|
20034
20034
|
var init_swift_root_lock = __esm({
|
|
20035
20035
|
"src/swift-root-lock.ts"() {
|
|
20036
20036
|
"use strict";
|
|
20037
|
-
|
|
20037
|
+
import_node_child_process27 = require("node:child_process");
|
|
20038
20038
|
import_node_crypto19 = require("node:crypto");
|
|
20039
20039
|
import_node_fs46 = require("node:fs");
|
|
20040
|
-
|
|
20040
|
+
import_node_os10 = require("node:os");
|
|
20041
20041
|
import_node_path42 = __toESM(require("node:path"), 1);
|
|
20042
20042
|
init_process_group();
|
|
20043
20043
|
init_process_table();
|
|
@@ -20052,7 +20052,7 @@ var init_swift_root_lock = __esm({
|
|
|
20052
20052
|
function compileUniformTypeConstants(args) {
|
|
20053
20053
|
const source = import_node_path43.default.join(args.packageRoot, "runtime/UniformTypeIdentifiersConstants.m");
|
|
20054
20054
|
const object6 = import_node_path43.default.join(args.out, "UniformTypeIdentifiers-NativeConstants.o");
|
|
20055
|
-
(0,
|
|
20055
|
+
(0, import_node_child_process28.execFileSync)(
|
|
20056
20056
|
import_node_path43.default.join(args.bin, "clang"),
|
|
20057
20057
|
[
|
|
20058
20058
|
"--target=wasm64-unknown-wasip1",
|
|
@@ -20073,11 +20073,11 @@ function compileUniformTypeConstants(args) {
|
|
|
20073
20073
|
);
|
|
20074
20074
|
return object6;
|
|
20075
20075
|
}
|
|
20076
|
-
var
|
|
20076
|
+
var import_node_child_process28, import_node_path43;
|
|
20077
20077
|
var init_swift_uniform_type_constants = __esm({
|
|
20078
20078
|
"src/swift-uniform-type-constants.ts"() {
|
|
20079
20079
|
"use strict";
|
|
20080
|
-
|
|
20080
|
+
import_node_child_process28 = require("node:child_process");
|
|
20081
20081
|
import_node_path43 = __toESM(require("node:path"), 1);
|
|
20082
20082
|
init_swift_objc_runtime();
|
|
20083
20083
|
init_swift_objc_standin();
|
|
@@ -20217,7 +20217,7 @@ async function runCompiler(command, args, options, stream = false, quiet) {
|
|
|
20217
20217
|
detached: true,
|
|
20218
20218
|
stdio: ["ignore", "pipe", "pipe"]
|
|
20219
20219
|
};
|
|
20220
|
-
const child = options.lease ? options.lease.spawn(command, args, launch, options.frameworkLease) : (0,
|
|
20220
|
+
const child = options.lease ? options.lease.spawn(command, args, launch, options.frameworkLease) : (0, import_node_child_process29.spawn)(command, args, launch);
|
|
20221
20221
|
let stopping;
|
|
20222
20222
|
try {
|
|
20223
20223
|
return await new Promise((resolve3, reject) => {
|
|
@@ -20295,7 +20295,7 @@ function swiftBuildJobs() {
|
|
|
20295
20295
|
const admittedCores = windowAdmission()?.cores ?? Number(process.env.TM_EXEC_CPU_CORES);
|
|
20296
20296
|
return Math.min(
|
|
20297
20297
|
process.platform === "darwin" ? Infinity : 4,
|
|
20298
|
-
Math.max(1, Math.floor(
|
|
20298
|
+
Math.max(1, Math.floor(import_node_os11.default.availableParallelism() / 2)),
|
|
20299
20299
|
Number.isInteger(admittedCores) && admittedCores > 0 ? admittedCores : 4
|
|
20300
20300
|
);
|
|
20301
20301
|
}
|
|
@@ -20749,7 +20749,7 @@ function swiftSdkPaths(moduleRoot, toolchainBin) {
|
|
|
20749
20749
|
const key2 = JSON.stringify([toolchainBin, sdk2, options]);
|
|
20750
20750
|
const cached2 = sdkPaths.get(key2);
|
|
20751
20751
|
if (cached2) return cached2;
|
|
20752
|
-
const configuration = (0,
|
|
20752
|
+
const configuration = (0, import_node_child_process29.execFileSync)(
|
|
20753
20753
|
import_node_path46.default.join(toolchainBin, "swift"),
|
|
20754
20754
|
[
|
|
20755
20755
|
"sdk",
|
|
@@ -21604,18 +21604,6 @@ function lowerAVAssetURLCluster(source) {
|
|
|
21604
21604
|
out = out.slice(0, at) + insert + out.slice(at + remove);
|
|
21605
21605
|
return out;
|
|
21606
21606
|
}
|
|
21607
|
-
function lowerNSValueTimeBox(source) {
|
|
21608
|
-
const masked = swiftCodeMask(source);
|
|
21609
|
-
const pattern = /\bNSValue\s*\(\s*time\s*:/g;
|
|
21610
|
-
const edits = [];
|
|
21611
|
-
let hit;
|
|
21612
|
-
while ((hit = pattern.exec(masked)) !== null)
|
|
21613
|
-
edits.push([hit.index, "NSValue".length, "NSValue.boxedTime"]);
|
|
21614
|
-
let out = source;
|
|
21615
|
-
for (const [at, remove, insert] of edits.sort((a, b) => b[0] - a[0]))
|
|
21616
|
-
out = out.slice(0, at) + insert + out.slice(at + remove);
|
|
21617
|
-
return out;
|
|
21618
|
-
}
|
|
21619
21607
|
function swiftCodeMask(source) {
|
|
21620
21608
|
const chars = source.split("");
|
|
21621
21609
|
const blank = (from, to) => {
|
|
@@ -21827,7 +21815,7 @@ function swiftSourceAsIOS(source, overlayFrameworks, swiftPackage) {
|
|
|
21827
21815
|
continue;
|
|
21828
21816
|
}
|
|
21829
21817
|
}
|
|
21830
|
-
return
|
|
21818
|
+
return lowerAVAssetURLCluster(out + conditioned.slice(copied));
|
|
21831
21819
|
}
|
|
21832
21820
|
function swiftSourceClosure(files2, roots) {
|
|
21833
21821
|
const sources = /* @__PURE__ */ new Map();
|
|
@@ -25033,14 +25021,14 @@ function compileSwiftProjectOnce(input, options) {
|
|
|
25033
25021
|
options.signal
|
|
25034
25022
|
);
|
|
25035
25023
|
}
|
|
25036
|
-
var
|
|
25024
|
+
var import_node_child_process29, import_node_crypto20, import_node_fs49, import_node_os11, import_node_path46, 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, ARCH_ARM64, 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;
|
|
25037
25025
|
var init_swift_compile = __esm({
|
|
25038
25026
|
"src/swift-compile.ts"() {
|
|
25039
25027
|
"use strict";
|
|
25040
|
-
|
|
25028
|
+
import_node_child_process29 = require("node:child_process");
|
|
25041
25029
|
import_node_crypto20 = require("node:crypto");
|
|
25042
25030
|
import_node_fs49 = require("node:fs");
|
|
25043
|
-
|
|
25031
|
+
import_node_os11 = __toESM(require("node:os"), 1);
|
|
25044
25032
|
import_node_path46 = __toESM(require("node:path"), 1);
|
|
25045
25033
|
v5 = __toESM(require("valibot"), 1);
|
|
25046
25034
|
init_admitted_mac_build();
|
|
@@ -25270,7 +25258,7 @@ int EXUpdatesApplyBSDiffPatch(const char * _Nonnull oldFilePath,
|
|
|
25270
25258
|
REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
|
|
25271
25259
|
MULTI_MANIFEST_VERSION = 68;
|
|
25272
25260
|
SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
|
|
25273
|
-
compilerSourceDigest = true ? "
|
|
25261
|
+
compilerSourceDigest = true ? "38c735ffbd31a005ec0e9662f0fa716aaed8b65aeec0d1592bde2e835f179458" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
|
|
25274
25262
|
nativeCxxCompilerFlags = ["-fno-cxx-modules"];
|
|
25275
25263
|
cFlagArray = (flags) => JSON.stringify(withoutGlogModuleMap(flags));
|
|
25276
25264
|
cxxFlagArray = (flags) => JSON.stringify([...nativeCxxCompilerFlags, ...withoutGlogModuleMap(flags)]);
|
|
@@ -26106,7 +26094,7 @@ async function swiftDistributionRoot(signal) {
|
|
|
26106
26094
|
}
|
|
26107
26095
|
async function installSwiftToolchain(release, sdk2, signal, compilerOnly = false) {
|
|
26108
26096
|
const root = import_node_path47.default.resolve(swiftToolchainBin(release), "../..");
|
|
26109
|
-
const owned = process.platform === "darwin" ? import_node_path47.default.join(
|
|
26097
|
+
const owned = process.platform === "darwin" ? import_node_path47.default.join(import_node_os12.default.homedir(), "Library/Developer/Toolchains", `${release}.xctoolchain`) : import_node_path47.default.join(rnxHomeDir(), "swift", "toolchains", release);
|
|
26110
26098
|
const selectedCompiler = process.platform === "darwin" && import_node_fs50.default.existsSync(import_node_path47.default.join(root, "usr/bin/swift"));
|
|
26111
26099
|
if (release.includes("-custom-") && root === owned && !selectedCompiler && !swiftCompilerReady(release)) {
|
|
26112
26100
|
const archive = swiftHostCompilerArchive(release);
|
|
@@ -26209,12 +26197,12 @@ function swiftModuleToolchain(root) {
|
|
|
26209
26197
|
const { release } = swiftModuleCompiler(root);
|
|
26210
26198
|
return { release, toolchainBin: swiftToolchain(release, swiftModuleSdk(root)) };
|
|
26211
26199
|
}
|
|
26212
|
-
var import_node_fs50,
|
|
26200
|
+
var import_node_fs50, import_node_os12, import_node_path47, SWIFT_ENDPOINT_ENV, DEFAULT_SWIFT_ENDPOINT, installs, staleWarned;
|
|
26213
26201
|
var init_swift_distribution = __esm({
|
|
26214
26202
|
"src/swift-distribution.ts"() {
|
|
26215
26203
|
"use strict";
|
|
26216
26204
|
import_node_fs50 = __toESM(require("node:fs"), 1);
|
|
26217
|
-
|
|
26205
|
+
import_node_os12 = __toESM(require("node:os"), 1);
|
|
26218
26206
|
import_node_path47 = __toESM(require("node:path"), 1);
|
|
26219
26207
|
init_src();
|
|
26220
26208
|
init_linux_browser_libs();
|
|
@@ -26305,7 +26293,7 @@ function dumpInputs(dir) {
|
|
|
26305
26293
|
path: command,
|
|
26306
26294
|
realpath: import_node_fs51.default.realpathSync(command),
|
|
26307
26295
|
sha256: (0, import_node_crypto21.createHash)("sha256").update(import_node_fs51.default.readFileSync(command)).digest("hex"),
|
|
26308
|
-
version: (0,
|
|
26296
|
+
version: (0, import_node_child_process30.execFileSync)(command, ["--version"], {
|
|
26309
26297
|
encoding: "utf8",
|
|
26310
26298
|
env: swiftEnvironment(),
|
|
26311
26299
|
stdio: ["ignore", "pipe", "pipe"]
|
|
@@ -26368,7 +26356,7 @@ function dump(dir, requirePrepared = false) {
|
|
|
26368
26356
|
if (requirePrepared) throw new SwiftManifestPreparationRequired(dir);
|
|
26369
26357
|
let output2;
|
|
26370
26358
|
try {
|
|
26371
|
-
output2 = (0,
|
|
26359
|
+
output2 = (0, import_node_child_process30.execFileSync)(
|
|
26372
26360
|
command,
|
|
26373
26361
|
[
|
|
26374
26362
|
"package",
|
|
@@ -26708,7 +26696,7 @@ let package = Package(
|
|
|
26708
26696
|
]
|
|
26709
26697
|
)
|
|
26710
26698
|
`;
|
|
26711
|
-
const dir = import_node_fs51.default.mkdtempSync(import_node_path48.default.join(
|
|
26699
|
+
const dir = import_node_fs51.default.mkdtempSync(import_node_path48.default.join(import_node_os13.default.tmpdir(), "peach-resolve-"));
|
|
26712
26700
|
import_node_fs51.default.writeFileSync(import_node_path48.default.join(dir, "Package.swift"), manifest);
|
|
26713
26701
|
const args = [
|
|
26714
26702
|
"package",
|
|
@@ -26748,7 +26736,7 @@ async function resolveSwiftPackageRequirementsAsync(requirements, destination, s
|
|
|
26748
26736
|
const { dir, args, options, failed, publish } = resolveRequest(requirements);
|
|
26749
26737
|
try {
|
|
26750
26738
|
try {
|
|
26751
|
-
await (0, import_node_util9.promisify)(
|
|
26739
|
+
await (0, import_node_util9.promisify)(import_node_child_process30.execFile)(swiftCommand(), args, { ...options, signal });
|
|
26752
26740
|
} catch (error) {
|
|
26753
26741
|
throw failed(error);
|
|
26754
26742
|
}
|
|
@@ -26789,14 +26777,14 @@ function swiftTargetFiles(manifest, target) {
|
|
|
26789
26777
|
}
|
|
26790
26778
|
return [...new Set(files2)].sort();
|
|
26791
26779
|
}
|
|
26792
|
-
var
|
|
26780
|
+
var import_node_child_process30, import_node_crypto21, import_node_fs51, import_node_os13, import_node_path48, import_node_util9, TARGET_TYPES, targetRelative, isTargetType, record, array3, string4, cacheDir3, evaluated, execFileAsync, cachedToolchain, SwiftManifestPreparationRequired, manifestPreparations, GUEST_PLATFORMS, within, requirementClause;
|
|
26793
26781
|
var init_swift_package_manifest = __esm({
|
|
26794
26782
|
"src/swift-package-manifest.ts"() {
|
|
26795
26783
|
"use strict";
|
|
26796
|
-
|
|
26784
|
+
import_node_child_process30 = require("node:child_process");
|
|
26797
26785
|
import_node_crypto21 = require("node:crypto");
|
|
26798
26786
|
import_node_fs51 = __toESM(require("node:fs"), 1);
|
|
26799
|
-
|
|
26787
|
+
import_node_os13 = __toESM(require("node:os"), 1);
|
|
26800
26788
|
import_node_path48 = __toESM(require("node:path"), 1);
|
|
26801
26789
|
import_node_util9 = require("node:util");
|
|
26802
26790
|
init_home_paths();
|
|
@@ -26820,7 +26808,7 @@ var init_swift_package_manifest = __esm({
|
|
|
26820
26808
|
string4 = (value) => typeof value === "string" ? value : void 0;
|
|
26821
26809
|
cacheDir3 = import_node_path48.default.join(cacheDir(), "swift-manifests");
|
|
26822
26810
|
evaluated = /* @__PURE__ */ new Map();
|
|
26823
|
-
execFileAsync = (0, import_node_util9.promisify)(
|
|
26811
|
+
execFileAsync = (0, import_node_util9.promisify)(import_node_child_process30.execFile);
|
|
26824
26812
|
SwiftManifestPreparationRequired = class extends Error {
|
|
26825
26813
|
constructor(dir) {
|
|
26826
26814
|
super(`swift package manifest requires preparation: ${dir}`);
|
|
@@ -27497,7 +27485,7 @@ function loadProject(xcodeproj) {
|
|
|
27497
27485
|
function selectedDeveloperDir() {
|
|
27498
27486
|
developerDir ??= process.platform === "darwin" ? (
|
|
27499
27487
|
// runner-toolchain-platform: darwin
|
|
27500
|
-
(0,
|
|
27488
|
+
(0, import_node_child_process31.execFileSync)("xcode-select", ["-p"], {
|
|
27501
27489
|
encoding: "utf8",
|
|
27502
27490
|
stdio: ["ignore", "pipe", "pipe"]
|
|
27503
27491
|
}).trim()
|
|
@@ -27901,7 +27889,7 @@ function targetMembers(ref, settings, options, settingKeys, projectInputs) {
|
|
|
27901
27889
|
str(phase.shellPath) ?? "/bin/sh",
|
|
27902
27890
|
str(phase.shellScript) ?? ""
|
|
27903
27891
|
);
|
|
27904
|
-
(0,
|
|
27892
|
+
(0, import_node_child_process31.execFileSync)(shell, args, {
|
|
27905
27893
|
cwd: project.projectDir,
|
|
27906
27894
|
env,
|
|
27907
27895
|
stdio: ["ignore", "pipe", "pipe"],
|
|
@@ -28009,7 +27997,7 @@ ${output2}`
|
|
|
28009
27997
|
const families = settings("TARGETED_DEVICE_FAMILY").split(",").map((value) => value.trim());
|
|
28010
27998
|
if (families.includes("1")) args.push("--target-device", "iphone");
|
|
28011
27999
|
if (families.includes("2")) args.push("--target-device", "ipad");
|
|
28012
|
-
(0,
|
|
28000
|
+
(0, import_node_child_process31.execFileSync)("xcrun", args, {
|
|
28013
28001
|
cwd: project.projectDir,
|
|
28014
28002
|
stdio: ["ignore", "pipe", "pipe"],
|
|
28015
28003
|
timeout: runScriptTimeoutMs
|
|
@@ -28054,7 +28042,7 @@ ${output2}`
|
|
|
28054
28042
|
args.push("-swiftVersion", settings("SWIFT_VERSION") || "5.0");
|
|
28055
28043
|
if (settings("DEFINES_MODULE") === "YES")
|
|
28056
28044
|
args.push("-moduleName", settings("PRODUCT_MODULE_NAME"));
|
|
28057
|
-
(0,
|
|
28045
|
+
(0, import_node_child_process31.execFileSync)("xcrun", args, {
|
|
28058
28046
|
cwd: project.projectDir,
|
|
28059
28047
|
stdio: ["ignore", "pipe", "pipe"],
|
|
28060
28048
|
timeout: runScriptTimeoutMs
|
|
@@ -29279,11 +29267,11 @@ function readXcodeAppTarget(input, targetName, configurationName, options = {})
|
|
|
29279
29267
|
cocoapods
|
|
29280
29268
|
};
|
|
29281
29269
|
}
|
|
29282
|
-
var
|
|
29270
|
+
var import_node_child_process31, import_node_crypto22, import_node_fs52, import_node_path50, import_plist2, 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, isDirectory, loaded, developerDir, preparedSourcePhases, isPodsProject, targetRefs, workspaceResolvedFile, SwiftPackageResolutionRequired;
|
|
29283
29271
|
var init_xcode_project = __esm({
|
|
29284
29272
|
"src/xcode-project.ts"() {
|
|
29285
29273
|
"use strict";
|
|
29286
|
-
|
|
29274
|
+
import_node_child_process31 = require("node:child_process");
|
|
29287
29275
|
import_node_crypto22 = require("node:crypto");
|
|
29288
29276
|
import_node_fs52 = __toESM(require("node:fs"), 1);
|
|
29289
29277
|
import_node_path50 = __toESM(require("node:path"), 1);
|
|
@@ -29381,12 +29369,12 @@ function compiledSwiftHelper(swift, name3) {
|
|
|
29381
29369
|
try {
|
|
29382
29370
|
import_node_fs57.default.mkdirSync(cacheDir(), { recursive: true });
|
|
29383
29371
|
const source = import_node_path55.default.join(
|
|
29384
|
-
import_node_fs57.default.mkdtempSync(import_node_path55.default.join(
|
|
29372
|
+
import_node_fs57.default.mkdtempSync(import_node_path55.default.join(import_node_os15.default.tmpdir(), `${name3}-`)),
|
|
29385
29373
|
"main.swift"
|
|
29386
29374
|
);
|
|
29387
29375
|
import_node_fs57.default.writeFileSync(source, swift);
|
|
29388
29376
|
try {
|
|
29389
|
-
(0,
|
|
29377
|
+
(0, import_node_child_process34.execFileSync)("xcrun", ["swiftc", "-o", binary2, source], { stdio: "pipe" });
|
|
29390
29378
|
} finally {
|
|
29391
29379
|
import_node_fs57.default.rmSync(import_node_path55.default.dirname(source), { recursive: true, force: true });
|
|
29392
29380
|
}
|
|
@@ -29398,14 +29386,14 @@ function compiledSwiftHelper(swift, name3) {
|
|
|
29398
29386
|
);
|
|
29399
29387
|
}
|
|
29400
29388
|
}
|
|
29401
|
-
var
|
|
29389
|
+
var import_node_child_process34, import_node_crypto26, import_node_fs57, import_node_os15, import_node_path55;
|
|
29402
29390
|
var init_swift_helper = __esm({
|
|
29403
29391
|
"src/swift-helper.ts"() {
|
|
29404
29392
|
"use strict";
|
|
29405
|
-
|
|
29393
|
+
import_node_child_process34 = require("node:child_process");
|
|
29406
29394
|
import_node_crypto26 = require("node:crypto");
|
|
29407
29395
|
import_node_fs57 = __toESM(require("node:fs"), 1);
|
|
29408
|
-
|
|
29396
|
+
import_node_os15 = __toESM(require("node:os"), 1);
|
|
29409
29397
|
import_node_path55 = __toESM(require("node:path"), 1);
|
|
29410
29398
|
init_home_paths();
|
|
29411
29399
|
}
|
|
@@ -29471,7 +29459,7 @@ var init_swift_standin_digest = __esm({
|
|
|
29471
29459
|
STANDIN_DIGEST_ENTRYPOINTS = ["swift-standins.ts", "swift-objc-compile.ts"];
|
|
29472
29460
|
SPECIFIER = /from\s*['"]([^'"]+)['"]|import\s*\(\s*['"]([^'"]+)['"]\s*\)/g;
|
|
29473
29461
|
standinSourceDigest = (srcDir = __sootsim_import_meta_dirname) => sourceClosureDigest(srcDir, STANDIN_DIGEST_ENTRYPOINTS);
|
|
29474
|
-
STANDIN_SOURCE_DIGEST = true ? "
|
|
29462
|
+
STANDIN_SOURCE_DIGEST = true ? "ef95f9c4acc6f2d45a1510da2a7e3653243ffb1335362bc0d4996631fc6f0df3" : standinSourceDigest();
|
|
29475
29463
|
}
|
|
29476
29464
|
});
|
|
29477
29465
|
|
|
@@ -29919,12 +29907,12 @@ function rustStaticLibrary(file, moduleRoot) {
|
|
|
29919
29907
|
const flags = ["--no-sort", "--extern-only", "--defined-only", "--format=just-symbols"];
|
|
29920
29908
|
const options = { encoding: "utf8", maxBuffer: 64 * 1024 * 1024 };
|
|
29921
29909
|
const symbols = (input) => {
|
|
29922
|
-
const raw2 = (0,
|
|
29910
|
+
const raw2 = (0, import_node_child_process36.execFileSync)(
|
|
29923
29911
|
import_node_path64.default.join(toolchain.toolchainBin, "llvm-nm"),
|
|
29924
29912
|
[...flags, input],
|
|
29925
29913
|
options
|
|
29926
29914
|
).trim().split("\n");
|
|
29927
|
-
const demangled = (0,
|
|
29915
|
+
const demangled = (0, import_node_child_process36.execFileSync)(
|
|
29928
29916
|
import_node_path64.default.join(toolchain.toolchainBin, "llvm-nm"),
|
|
29929
29917
|
[...flags, "--demangle", input],
|
|
29930
29918
|
options
|
|
@@ -29939,7 +29927,7 @@ function rustStaticLibrary(file, moduleRoot) {
|
|
|
29939
29927
|
const stage = import_node_fs66.default.mkdtempSync(import_node_path64.default.join(directory2, "build-"));
|
|
29940
29928
|
try {
|
|
29941
29929
|
const object6 = import_node_path64.default.join(stage, "library.o");
|
|
29942
|
-
(0,
|
|
29930
|
+
(0, import_node_child_process36.execFileSync)(import_node_path64.default.join(toolchain.toolchainBin, "wasm-ld"), [
|
|
29943
29931
|
"-mwasm64",
|
|
29944
29932
|
"-r",
|
|
29945
29933
|
"--whole-archive",
|
|
@@ -29955,7 +29943,7 @@ function rustStaticLibrary(file, moduleRoot) {
|
|
|
29955
29943
|
);
|
|
29956
29944
|
import_node_fs66.default.writeFileSync(object6, localizeDefinedWasmSymbols(import_node_fs66.default.readFileSync(object6), names));
|
|
29957
29945
|
const output2 = import_node_path64.default.join(stage, "library.a");
|
|
29958
|
-
(0,
|
|
29946
|
+
(0, import_node_child_process36.execFileSync)(import_node_path64.default.join(toolchain.toolchainBin, "llvm-ar"), ["rcsD", output2, object6]);
|
|
29959
29947
|
import_node_fs66.default.renameSync(output2, archive);
|
|
29960
29948
|
} finally {
|
|
29961
29949
|
import_node_fs66.default.rmSync(stage, { recursive: true, force: true });
|
|
@@ -29974,7 +29962,7 @@ function combineNativeStaticLibraries(files2, moduleRoot) {
|
|
|
29974
29962
|
import_node_fs66.default.mkdirSync(directory2, { recursive: true });
|
|
29975
29963
|
const temporary = import_node_path64.default.join(directory2, `combined-${(0, import_node_crypto32.randomUUID)()}.a`);
|
|
29976
29964
|
try {
|
|
29977
|
-
(0,
|
|
29965
|
+
(0, import_node_child_process36.execFileSync)(import_node_path64.default.join(toolchain.toolchainBin, "llvm-ar"), [
|
|
29978
29966
|
"qcsDL",
|
|
29979
29967
|
temporary,
|
|
29980
29968
|
...files2
|
|
@@ -29985,11 +29973,11 @@ function combineNativeStaticLibraries(files2, moduleRoot) {
|
|
|
29985
29973
|
}
|
|
29986
29974
|
return archive;
|
|
29987
29975
|
}
|
|
29988
|
-
var
|
|
29976
|
+
var import_node_child_process36, import_node_crypto32, import_node_fs66, import_node_path64, NATIVE_STATIC_LIBRARY_RECIPES;
|
|
29989
29977
|
var init_native_static_libraries = __esm({
|
|
29990
29978
|
"src/native-static-libraries.ts"() {
|
|
29991
29979
|
"use strict";
|
|
29992
|
-
|
|
29980
|
+
import_node_child_process36 = require("node:child_process");
|
|
29993
29981
|
import_node_crypto32 = require("node:crypto");
|
|
29994
29982
|
import_node_fs66 = __toESM(require("node:fs"), 1);
|
|
29995
29983
|
import_node_path64 = __toESM(require("node:path"), 1);
|
|
@@ -30425,9 +30413,30 @@ async function fetchCheckout(checkouts, identity2, pin2, signal) {
|
|
|
30425
30413
|
if (preparedSwiftPin(checkouts, identity2, pin2.location, pin2.revision)) return;
|
|
30426
30414
|
requireNativeGit();
|
|
30427
30415
|
const key2 = checkoutKey(dir, pin2);
|
|
30416
|
+
const gitEnv = { ...process.env };
|
|
30417
|
+
for (const name3 of [
|
|
30418
|
+
"GIT_DIR",
|
|
30419
|
+
"GIT_COMMON_DIR",
|
|
30420
|
+
"GIT_WORK_TREE",
|
|
30421
|
+
"GIT_INDEX_FILE",
|
|
30422
|
+
"GIT_OBJECT_DIRECTORY",
|
|
30423
|
+
"GIT_ALTERNATE_OBJECT_DIRECTORIES",
|
|
30424
|
+
"GIT_PREFIX",
|
|
30425
|
+
"GIT_SHALLOW_FILE",
|
|
30426
|
+
"GIT_GRAFT_FILE",
|
|
30427
|
+
"GIT_NAMESPACE",
|
|
30428
|
+
"GIT_IMPLICIT_WORK_TREE",
|
|
30429
|
+
"GIT_CONFIG",
|
|
30430
|
+
"GIT_CEILING_DIRECTORIES",
|
|
30431
|
+
"GIT_DISCOVERY_ACROSS_FILESYSTEM",
|
|
30432
|
+
"GIT_SUPER_PREFIX"
|
|
30433
|
+
]) {
|
|
30434
|
+
delete gitEnv[name3];
|
|
30435
|
+
}
|
|
30436
|
+
gitEnv.GIT_TERMINAL_PROMPT = "0";
|
|
30428
30437
|
const git = async (cwd, ...args) => (await execFileAsync2("git", ["-C", cwd, ...args], {
|
|
30429
30438
|
encoding: "utf8",
|
|
30430
|
-
env:
|
|
30439
|
+
env: gitEnv,
|
|
30431
30440
|
signal
|
|
30432
30441
|
})).stdout.trim();
|
|
30433
30442
|
const lock = async () => {
|
|
@@ -31022,11 +31031,11 @@ function resolveSwiftPackages(options) {
|
|
|
31022
31031
|
result.nativeProducts.push({ name: name3, packageDir: manifest.dir, source });
|
|
31023
31032
|
return result;
|
|
31024
31033
|
}
|
|
31025
|
-
var
|
|
31034
|
+
var import_node_child_process37, import_node_crypto34, import_node_fs68, import_node_path66, import_promises7, import_node_util13, swiftBinaryOnDisk, SWIFT_PLACEHOLDER_PACKAGES, placeholderPackage, UNSUPPORTED_NATIVE, BINARY, blockers, verified, execFileAsync2, checkoutKey;
|
|
31026
31035
|
var init_swift_packages = __esm({
|
|
31027
31036
|
"src/swift-packages.ts"() {
|
|
31028
31037
|
"use strict";
|
|
31029
|
-
|
|
31038
|
+
import_node_child_process37 = require("node:child_process");
|
|
31030
31039
|
import_node_crypto34 = require("node:crypto");
|
|
31031
31040
|
import_node_fs68 = __toESM(require("node:fs"), 1);
|
|
31032
31041
|
import_node_path66 = __toESM(require("node:path"), 1);
|
|
@@ -31047,7 +31056,7 @@ var init_swift_packages = __esm({
|
|
|
31047
31056
|
BINARY = "is a binary framework";
|
|
31048
31057
|
blockers = (reasons) => [...new Set(reasons.flat())];
|
|
31049
31058
|
verified = /* @__PURE__ */ new Set();
|
|
31050
|
-
execFileAsync2 = (0, import_node_util13.promisify)(
|
|
31059
|
+
execFileAsync2 = (0, import_node_util13.promisify)(import_node_child_process37.execFile);
|
|
31051
31060
|
checkoutKey = (dir, pin2) => `${dir}\0${pin2.revision}`;
|
|
31052
31061
|
}
|
|
31053
31062
|
});
|
|
@@ -31114,10 +31123,10 @@ function privateSentrySlice(entry, moduleRoot) {
|
|
|
31114
31123
|
throw new Error(
|
|
31115
31124
|
"the Sentry slice for a private Swift distribution builds from a Contrast source checkout"
|
|
31116
31125
|
);
|
|
31117
|
-
const staging = import_node_fs69.default.mkdtempSync(import_node_path67.default.join(import_node_fs69.default.realpathSync(
|
|
31126
|
+
const staging = import_node_fs69.default.mkdtempSync(import_node_path67.default.join(import_node_fs69.default.realpathSync(import_node_os16.default.tmpdir()), "sentry-slice-"));
|
|
31118
31127
|
try {
|
|
31119
31128
|
process.stderr.write("peach: building the Sentry slice for a private distribution\u2026\n");
|
|
31120
|
-
(0,
|
|
31129
|
+
(0, import_node_child_process38.execFileSync)("bun", [script, "--output", staging, "--module-root", moduleRoot], {
|
|
31121
31130
|
cwd: import_node_path67.default.resolve(sourceSwiftCheckout(), "../.."),
|
|
31122
31131
|
stdio: ["ignore", 2, 2]
|
|
31123
31132
|
});
|
|
@@ -31192,14 +31201,14 @@ function nativeSwiftSlice(standin, moduleRoot, generator, configured, artifact)
|
|
|
31192
31201
|
}
|
|
31193
31202
|
};
|
|
31194
31203
|
}
|
|
31195
|
-
var
|
|
31204
|
+
var import_node_child_process38, import_node_crypto35, import_node_fs69, import_node_os16, import_node_path67, SENTRY_SWIFT_SLICE;
|
|
31196
31205
|
var init_native_swift_slices = __esm({
|
|
31197
31206
|
"src/native-swift-slices.ts"() {
|
|
31198
31207
|
"use strict";
|
|
31199
|
-
|
|
31208
|
+
import_node_child_process38 = require("node:child_process");
|
|
31200
31209
|
import_node_crypto35 = require("node:crypto");
|
|
31201
31210
|
import_node_fs69 = __toESM(require("node:fs"), 1);
|
|
31202
|
-
|
|
31211
|
+
import_node_os16 = __toESM(require("node:os"), 1);
|
|
31203
31212
|
import_node_path67 = __toESM(require("node:path"), 1);
|
|
31204
31213
|
init_native_prebuilt();
|
|
31205
31214
|
init_swift_compile();
|
|
@@ -31487,7 +31496,7 @@ async function emitCxxStandin(input) {
|
|
|
31487
31496
|
"-I",
|
|
31488
31497
|
input.headers
|
|
31489
31498
|
];
|
|
31490
|
-
const includes = (0,
|
|
31499
|
+
const includes = (0, import_node_child_process39.spawnSync)(input.clang, [...flags, "-M", "-MT", "peach", probe], {
|
|
31491
31500
|
encoding: "utf8",
|
|
31492
31501
|
env: swiftEnvironment(),
|
|
31493
31502
|
maxBuffer: 16 * 1024 * 1024
|
|
@@ -31507,7 +31516,7 @@ async function emitCxxStandin(input) {
|
|
|
31507
31516
|
const output2 = import_node_fs72.default.openSync(ast, "w");
|
|
31508
31517
|
let parsed;
|
|
31509
31518
|
try {
|
|
31510
|
-
parsed = (0,
|
|
31519
|
+
parsed = (0, import_node_child_process39.spawnSync)(
|
|
31511
31520
|
input.clang,
|
|
31512
31521
|
[...flags, "-fsyntax-only", "-Xclang", "-ast-dump=json", probe],
|
|
31513
31522
|
{ stdio: ["ignore", output2, "pipe"], encoding: "utf8", env: swiftEnvironment() }
|
|
@@ -31565,7 +31574,7 @@ async function emitCxxStandin(input) {
|
|
|
31565
31574
|
sourceFile,
|
|
31566
31575
|
[...prelude, ...live.map((item) => item.text)].join("\n") + "\n"
|
|
31567
31576
|
);
|
|
31568
|
-
const checked = (0,
|
|
31577
|
+
const checked = (0, import_node_child_process39.spawnSync)(
|
|
31569
31578
|
input.clang,
|
|
31570
31579
|
[
|
|
31571
31580
|
...flags,
|
|
@@ -31599,11 +31608,11 @@ async function emitCxxStandin(input) {
|
|
|
31599
31608
|
excluded
|
|
31600
31609
|
};
|
|
31601
31610
|
}
|
|
31602
|
-
var
|
|
31611
|
+
var import_node_child_process39, import_node_fs72, import_node_path69, QUALIFIERS, UNNAMEABLE;
|
|
31603
31612
|
var init_swift_cxx_standin = __esm({
|
|
31604
31613
|
"src/swift-cxx-standin.ts"() {
|
|
31605
31614
|
"use strict";
|
|
31606
|
-
|
|
31615
|
+
import_node_child_process39 = require("node:child_process");
|
|
31607
31616
|
import_node_fs72 = __toESM(require("node:fs"), 1);
|
|
31608
31617
|
import_node_path69 = __toESM(require("node:path"), 1);
|
|
31609
31618
|
init_swift_cxx_declarations();
|
|
@@ -31855,7 +31864,7 @@ var init_swift_standin_builtin_behavior = __esm({
|
|
|
31855
31864
|
|
|
31856
31865
|
// src/swift-standins.ts
|
|
31857
31866
|
function exec(file, args, cwd) {
|
|
31858
|
-
return (0,
|
|
31867
|
+
return (0, import_node_child_process40.execFileSync)(file, args, {
|
|
31859
31868
|
cwd,
|
|
31860
31869
|
encoding: "utf8",
|
|
31861
31870
|
env: swiftEnvironment(),
|
|
@@ -32541,7 +32550,7 @@ function placeholderStandin(surface, binary2, toolchain, work, behavior, sibling
|
|
|
32541
32550
|
const out = import_node_path70.default.join(work, "graphs");
|
|
32542
32551
|
import_node_fs73.default.mkdirSync(import_node_path70.default.join(work, "interface"), { recursive: true });
|
|
32543
32552
|
import_node_fs73.default.mkdirSync(out, { recursive: true });
|
|
32544
|
-
const extracted = (0,
|
|
32553
|
+
const extracted = (0, import_node_child_process40.spawnSync)(
|
|
32545
32554
|
import_node_path70.default.join(toolchain.toolchainBin, "swiftc"),
|
|
32546
32555
|
[
|
|
32547
32556
|
"-emit-module",
|
|
@@ -32942,7 +32951,7 @@ function graphStandin(module2, graphs, values, wasm, binary2, toolchain, work, r
|
|
|
32942
32951
|
);
|
|
32943
32952
|
}
|
|
32944
32953
|
import_node_fs73.default.writeFileSync(file, source + trailer);
|
|
32945
|
-
const check2 = (0,
|
|
32954
|
+
const check2 = (0, import_node_child_process40.spawnSync)(
|
|
32946
32955
|
import_node_path70.default.join(toolchain.toolchainBin, "swiftc"),
|
|
32947
32956
|
// emitting the module runs the diagnostics a typecheck skips, such as
|
|
32948
32957
|
// literal overflow, which the app's build of the stand-in reaches
|
|
@@ -33310,7 +33319,7 @@ async function cxxStandin(surface, binary2, toolchain, work) {
|
|
|
33310
33319
|
roots.map((root) => `#include ${JSON.stringify(root)}
|
|
33311
33320
|
`).join("")
|
|
33312
33321
|
);
|
|
33313
|
-
const language = (0,
|
|
33322
|
+
const language = (0, import_node_child_process40.spawnSync)(
|
|
33314
33323
|
import_node_path70.default.join(toolchain.toolchainBin, "clang"),
|
|
33315
33324
|
[
|
|
33316
33325
|
"-target",
|
|
@@ -33531,7 +33540,7 @@ function buildRustCrate(manifest, library, searchRoot, moduleRoot, entry = rustC
|
|
|
33531
33540
|
import_node_path70.default.relative(common2, crateWorkspace(manifest)),
|
|
33532
33541
|
"Cargo.lock"
|
|
33533
33542
|
);
|
|
33534
|
-
const result = (0,
|
|
33543
|
+
const result = (0, import_node_child_process40.spawnSync)(
|
|
33535
33544
|
process.execPath,
|
|
33536
33545
|
[
|
|
33537
33546
|
runner,
|
|
@@ -33679,7 +33688,7 @@ async function sourceStandins(binaries, toolchain, provided, behavior) {
|
|
|
33679
33688
|
})
|
|
33680
33689
|
);
|
|
33681
33690
|
const build = await new Promise((resolve3) => {
|
|
33682
|
-
const child = (0,
|
|
33691
|
+
const child = (0, import_node_child_process40.spawn)(
|
|
33683
33692
|
"bun",
|
|
33684
33693
|
[
|
|
33685
33694
|
import_node_path70.default.join(repo, "scripts/build/swift-standins-submit.ts"),
|
|
@@ -34208,11 +34217,11 @@ async function buildStandins(binaries, toolchain, provided, behavior) {
|
|
|
34208
34217
|
import_node_fs73.default.rmSync(modules, { recursive: true, force: true });
|
|
34209
34218
|
}
|
|
34210
34219
|
}
|
|
34211
|
-
var
|
|
34220
|
+
var import_node_child_process40, import_node_crypto36, import_node_fs73, import_node_path70, TRIPLE, cacheDir4, key, digests, isBinaryLibraryFile, REACH_STAGED_FRAMEWORKS, OBJC_IMPORT, files, OBJC, OBJC_ATTRIBUTE, TYPE_DECLARATION, OPTIONAL_REQUIREMENT, WASM_EH_FLAGS, OBJC_UNREPRESENTABLE, INERT_VALUE, identChar, RUST_TARGET, UNSEARCHED, RUST_TOOLCHAIN, built;
|
|
34212
34221
|
var init_swift_standins = __esm({
|
|
34213
34222
|
"src/swift-standins.ts"() {
|
|
34214
34223
|
"use strict";
|
|
34215
|
-
|
|
34224
|
+
import_node_child_process40 = require("node:child_process");
|
|
34216
34225
|
import_node_crypto36 = require("node:crypto");
|
|
34217
34226
|
import_node_fs73 = __toESM(require("node:fs"), 1);
|
|
34218
34227
|
import_node_path70 = __toESM(require("node:path"), 1);
|
|
@@ -34937,7 +34946,7 @@ function prepareXcodeSwiftProducts(app, binaries, moduleRoot) {
|
|
|
34937
34946
|
provided: [...providers.keys()]
|
|
34938
34947
|
};
|
|
34939
34948
|
try {
|
|
34940
|
-
const lock = (0,
|
|
34949
|
+
const lock = (0, import_node_child_process41.spawnSync)(
|
|
34941
34950
|
"perl",
|
|
34942
34951
|
["-e", 'open(my $f, ">&=", 3) or die $!; flock($f, 2) or die $!'],
|
|
34943
34952
|
{ stdio: ["ignore", "pipe", "pipe", descriptor], encoding: "utf8" }
|
|
@@ -35108,7 +35117,7 @@ function prepareXcodeSwiftProducts(app, binaries, moduleRoot) {
|
|
|
35108
35117
|
import_node_path71.default.join(work, `${target.moduleName}.o`)
|
|
35109
35118
|
]
|
|
35110
35119
|
];
|
|
35111
|
-
const result = (0,
|
|
35120
|
+
const result = (0, import_node_child_process41.spawnSync)(frontend, args, {
|
|
35112
35121
|
cwd: work,
|
|
35113
35122
|
encoding: "utf8",
|
|
35114
35123
|
env: swiftEnvironment(),
|
|
@@ -35228,7 +35237,7 @@ async function prepareXcodeObjCImplementations(app, binaries, moduleRoot) {
|
|
|
35228
35237
|
const work = import_node_path71.default.join(parent, key2);
|
|
35229
35238
|
const descriptor = import_node_fs74.default.openSync(`${work}.lock`, "a");
|
|
35230
35239
|
try {
|
|
35231
|
-
const locked = (0,
|
|
35240
|
+
const locked = (0, import_node_child_process41.spawnSync)(
|
|
35232
35241
|
"perl",
|
|
35233
35242
|
["-e", 'open(my $f, ">&=", 3) or die $!; flock($f, 2) or die $!'],
|
|
35234
35243
|
{ stdio: ["ignore", "pipe", "pipe", descriptor], encoding: "utf8" }
|
|
@@ -35476,7 +35485,7 @@ async function prepareXcodeObjCImplementations(app, binaries, moduleRoot) {
|
|
|
35476
35485
|
...dependencies ? ["-MD", "-MF", dependencies, "-H"] : []
|
|
35477
35486
|
];
|
|
35478
35487
|
const result = await new Promise((resolve3) => {
|
|
35479
|
-
const child = (0,
|
|
35488
|
+
const child = (0, import_node_child_process41.spawn)(
|
|
35480
35489
|
import_node_path71.default.join(toolchain.toolchainBin, cxx ? "clang++" : "clang"),
|
|
35481
35490
|
args,
|
|
35482
35491
|
{
|
|
@@ -35557,11 +35566,11 @@ ${reported.trimEnd() || `Clang exited with status ${result.status}`}`;
|
|
|
35557
35566
|
import_node_fs74.default.closeSync(descriptor);
|
|
35558
35567
|
}
|
|
35559
35568
|
}
|
|
35560
|
-
var
|
|
35569
|
+
var import_node_child_process41, import_node_crypto37, import_node_fs74, import_node_path71, SwiftObjCCompilationError, isDirectory2, isSdkInclude, FRAMEWORK_IMPORT, OWN_IMPORT;
|
|
35561
35570
|
var init_swift_objc_compile = __esm({
|
|
35562
35571
|
"src/swift-objc-compile.ts"() {
|
|
35563
35572
|
"use strict";
|
|
35564
|
-
|
|
35573
|
+
import_node_child_process41 = require("node:child_process");
|
|
35565
35574
|
import_node_crypto37 = require("node:crypto");
|
|
35566
35575
|
import_node_fs74 = __toESM(require("node:fs"), 1);
|
|
35567
35576
|
import_node_path71 = __toESM(require("node:path"), 1);
|
|
@@ -37351,7 +37360,51 @@ function userInfo(source, owner) {
|
|
|
37351
37360
|
]);
|
|
37352
37361
|
return source.tools < 11 && owner.attrs.syncable !== "YES" ? [...entries, ["com.apple.syncservices.Syncable", "NO"]] : entries;
|
|
37353
37362
|
}
|
|
37363
|
+
function decimal(text6) {
|
|
37364
|
+
const match = /^([+-]?)(\d*)(?:\.(\d*))?(?:[eE]([+-]?\d+))?$/.exec(text6);
|
|
37365
|
+
if (!match) return null;
|
|
37366
|
+
const [, sign, whole = "", fraction = "", power] = match;
|
|
37367
|
+
if (whole + fraction === "") return null;
|
|
37368
|
+
let mantissa = BigInt(whole + fraction);
|
|
37369
|
+
let exponent = Number(power ?? 0) - fraction.length;
|
|
37370
|
+
if (mantissa === 0n) {
|
|
37371
|
+
if (power !== void 0) return null;
|
|
37372
|
+
const zero = {
|
|
37373
|
+
kind: "decimal",
|
|
37374
|
+
length: 0,
|
|
37375
|
+
negative: false,
|
|
37376
|
+
compact: false,
|
|
37377
|
+
mantissa: Buffer.alloc(16)
|
|
37378
|
+
};
|
|
37379
|
+
return { ...zero, exponent: sign === "-" ? 0 : exponent };
|
|
37380
|
+
}
|
|
37381
|
+
while (mantissa % 10n === 0n) {
|
|
37382
|
+
mantissa /= 10n;
|
|
37383
|
+
exponent++;
|
|
37384
|
+
}
|
|
37385
|
+
if (mantissa >> 128n !== 0n || exponent < -128 || exponent > 127) return null;
|
|
37386
|
+
const words2 = Buffer.alloc(16);
|
|
37387
|
+
let length = 0;
|
|
37388
|
+
for (let word = 0; word < 8; word++) {
|
|
37389
|
+
const value = Number(mantissa >> BigInt(16 * word) & 0xffffn);
|
|
37390
|
+
words2.writeUInt16LE(value, 2 * word);
|
|
37391
|
+
if (value !== 0) length = word + 1;
|
|
37392
|
+
}
|
|
37393
|
+
return {
|
|
37394
|
+
kind: "decimal",
|
|
37395
|
+
exponent,
|
|
37396
|
+
length,
|
|
37397
|
+
negative: sign === "-",
|
|
37398
|
+
compact: true,
|
|
37399
|
+
mantissa: words2
|
|
37400
|
+
};
|
|
37401
|
+
}
|
|
37354
37402
|
function defaultValue(model, member, type) {
|
|
37403
|
+
const interval = member.attrs.defaultDateTimeInterval;
|
|
37404
|
+
if (type === "Date" && interval !== void 0 && Number.isFinite(Number(interval)))
|
|
37405
|
+
return { kind: "date", time: Math.floor(Number(interval) / 60) * 60 };
|
|
37406
|
+
if (interval !== void 0)
|
|
37407
|
+
refuse3(model, `${member.attrs.name} has the ${type} date interval ${interval}`);
|
|
37355
37408
|
const text6 = member.attrs.defaultValueString;
|
|
37356
37409
|
if (text6 === void 0) return null;
|
|
37357
37410
|
if (type.startsWith("Integer ") && /^-?\d+$/.test(text6)) return Number(text6);
|
|
@@ -37359,6 +37412,8 @@ function defaultValue(model, member, type) {
|
|
|
37359
37412
|
return Number(text6);
|
|
37360
37413
|
if (type === "Boolean" && (text6 === "YES" || text6 === "NO")) return text6 === "YES";
|
|
37361
37414
|
if (type === "String") return text6;
|
|
37415
|
+
const scanned = type === "Decimal" ? decimal(text6) : null;
|
|
37416
|
+
if (scanned) return scanned;
|
|
37362
37417
|
refuse3(model, `${member.attrs.name} has the ${type} default ${JSON.stringify(text6)}`);
|
|
37363
37418
|
}
|
|
37364
37419
|
function attribute(source, member) {
|
|
@@ -37368,6 +37423,7 @@ function attribute(source, member) {
|
|
|
37368
37423
|
"transient",
|
|
37369
37424
|
"attributeType",
|
|
37370
37425
|
"defaultValueString",
|
|
37426
|
+
"defaultDateTimeInterval",
|
|
37371
37427
|
"usesScalarValueType",
|
|
37372
37428
|
"customClassName",
|
|
37373
37429
|
"valueTransformerName",
|
|
@@ -37527,6 +37583,20 @@ function readModel(model, contents) {
|
|
|
37527
37583
|
versionIdentifiers: [tag.attrs.userDefinedModelVersionIdentifier ?? ""]
|
|
37528
37584
|
};
|
|
37529
37585
|
}
|
|
37586
|
+
function archiveDefault(archive, value) {
|
|
37587
|
+
if (value === null) return NULL;
|
|
37588
|
+
if (typeof value !== "object") return archive.add(value);
|
|
37589
|
+
if (value.kind === "date")
|
|
37590
|
+
return archive.fill(archive.reserve(), "NSDate", { "NS.time": value.time });
|
|
37591
|
+
return archive.fill(archive.reserve(), "NSDecimalNumberPlaceholder", {
|
|
37592
|
+
"NS.compact": value.compact,
|
|
37593
|
+
"NS.exponent": value.exponent,
|
|
37594
|
+
"NS.length": value.length,
|
|
37595
|
+
"NS.mantissa": value.mantissa,
|
|
37596
|
+
"NS.mantissa.bo": 1,
|
|
37597
|
+
"NS.negative": value.negative
|
|
37598
|
+
});
|
|
37599
|
+
}
|
|
37530
37600
|
function archiveModel(model) {
|
|
37531
37601
|
const archive = new KeyedArchive();
|
|
37532
37602
|
const modelIndex = archive.reserve();
|
|
@@ -37557,7 +37627,7 @@ function archiveModel(model) {
|
|
|
37557
37627
|
...shared,
|
|
37558
37628
|
NSAttributeType: property.type,
|
|
37559
37629
|
NSAttributeValueClassName: archive.string(property.className),
|
|
37560
|
-
NSDefaultValue:
|
|
37630
|
+
NSDefaultValue: archiveDefault(archive, property.defaultValue),
|
|
37561
37631
|
NSFlagsKey: property.flags,
|
|
37562
37632
|
NSValueTransformerName: archive.string(property.transformer),
|
|
37563
37633
|
...property.transient ? { NSIsTransient: true } : {},
|
|
@@ -37799,7 +37869,15 @@ var init_core_data_model = __esm({
|
|
|
37799
37869
|
NSMutableDictionary: ["NSMutableDictionary", "NSDictionary", "NSObject"],
|
|
37800
37870
|
NSArray: ["NSArray", "NSObject"],
|
|
37801
37871
|
NSMutableArray: ["NSMutableArray", "NSArray", "NSObject"],
|
|
37802
|
-
NSSet: ["NSSet", "NSObject"]
|
|
37872
|
+
NSSet: ["NSSet", "NSObject"],
|
|
37873
|
+
NSDate: ["NSDate", "NSObject"],
|
|
37874
|
+
NSDecimalNumberPlaceholder: [
|
|
37875
|
+
"NSDecimalNumberPlaceholder",
|
|
37876
|
+
"NSDecimalNumber",
|
|
37877
|
+
"NSNumber",
|
|
37878
|
+
"NSValue",
|
|
37879
|
+
"NSObject"
|
|
37880
|
+
]
|
|
37803
37881
|
};
|
|
37804
37882
|
KeyedArchive = class {
|
|
37805
37883
|
objects = ["$null"];
|
|
@@ -37965,7 +38043,7 @@ async function xcodeCxxReachable(app, binaries, moduleRoot, clang) {
|
|
|
37965
38043
|
failed = captured.failed;
|
|
37966
38044
|
reached = captured.reached;
|
|
37967
38045
|
} else {
|
|
37968
|
-
const result2 = (0,
|
|
38046
|
+
const result2 = (0, import_node_child_process42.spawnSync)(clang, [...cleaned, "-M", "-MT", "peach", "-H"], {
|
|
37969
38047
|
cwd: work,
|
|
37970
38048
|
encoding: "utf8",
|
|
37971
38049
|
env: swiftEnvironment(),
|
|
@@ -38088,11 +38166,11 @@ async function xcodeCxxReachable(app, binaries, moduleRoot, clang) {
|
|
|
38088
38166
|
);
|
|
38089
38167
|
return result;
|
|
38090
38168
|
}
|
|
38091
|
-
var
|
|
38169
|
+
var import_node_child_process42, import_node_crypto39, import_node_fs78, import_node_path75, cachedInputs;
|
|
38092
38170
|
var init_swift_cxx_reachable = __esm({
|
|
38093
38171
|
"src/swift-cxx-reachable.ts"() {
|
|
38094
38172
|
"use strict";
|
|
38095
|
-
|
|
38173
|
+
import_node_child_process42 = require("node:child_process");
|
|
38096
38174
|
import_node_crypto39 = require("node:crypto");
|
|
38097
38175
|
import_node_fs78 = __toESM(require("node:fs"), 1);
|
|
38098
38176
|
import_node_path75 = __toESM(require("node:path"), 1);
|
|
@@ -38181,19 +38259,19 @@ function rasterizePdfFile(diskPath, pdfSha256) {
|
|
|
38181
38259
|
} catch {
|
|
38182
38260
|
}
|
|
38183
38261
|
const out = import_node_path77.default.join(
|
|
38184
|
-
import_node_fs80.default.mkdtempSync(import_node_path77.default.join(
|
|
38262
|
+
import_node_fs80.default.mkdtempSync(import_node_path77.default.join(import_node_os17.default.tmpdir(), "swift-pdf-png-")),
|
|
38185
38263
|
"out.png"
|
|
38186
38264
|
);
|
|
38187
38265
|
try {
|
|
38188
38266
|
if (process.platform === "darwin") {
|
|
38189
|
-
(0,
|
|
38267
|
+
(0, import_node_child_process43.execFileSync)(
|
|
38190
38268
|
compiledSwiftHelper(RASTER_SWIFT, "swift-pdf-raster"),
|
|
38191
38269
|
[diskPath, "3", out],
|
|
38192
38270
|
{ stdio: "pipe" }
|
|
38193
38271
|
);
|
|
38194
38272
|
} else {
|
|
38195
38273
|
const { executable, prefixArgs } = rnxSelfInvocation();
|
|
38196
|
-
(0,
|
|
38274
|
+
(0, import_node_child_process43.execFileSync)(
|
|
38197
38275
|
executable,
|
|
38198
38276
|
[
|
|
38199
38277
|
...prefixArgs,
|
|
@@ -38228,11 +38306,11 @@ function rasterizeSvgFile(diskPath, svgSha256) {
|
|
|
38228
38306
|
const cached2 = import_node_path77.default.join(cacheDir(), `swift-svg-png-${tag}-${svgSha256}.png`);
|
|
38229
38307
|
if (import_node_fs80.default.existsSync(cached2)) return { bytes: import_node_fs80.default.readFileSync(cached2) };
|
|
38230
38308
|
const out = import_node_path77.default.join(
|
|
38231
|
-
import_node_fs80.default.mkdtempSync(import_node_path77.default.join(
|
|
38309
|
+
import_node_fs80.default.mkdtempSync(import_node_path77.default.join(import_node_os17.default.tmpdir(), "swift-svg-png-")),
|
|
38232
38310
|
"out.png"
|
|
38233
38311
|
);
|
|
38234
38312
|
try {
|
|
38235
|
-
(0,
|
|
38313
|
+
(0, import_node_child_process43.execFileSync)(binary2, [diskPath, "3", out], { stdio: "pipe" });
|
|
38236
38314
|
const bytes = import_node_fs80.default.readFileSync(out);
|
|
38237
38315
|
import_node_fs80.default.mkdirSync(cacheDir(), { recursive: true });
|
|
38238
38316
|
import_node_fs80.default.copyFileSync(out, cached2);
|
|
@@ -38245,14 +38323,14 @@ function rasterizeSvgFile(diskPath, svgSha256) {
|
|
|
38245
38323
|
import_node_fs80.default.rmSync(import_node_path77.default.dirname(out), { recursive: true, force: true });
|
|
38246
38324
|
}
|
|
38247
38325
|
}
|
|
38248
|
-
var
|
|
38326
|
+
var import_node_child_process43, import_node_crypto40, import_node_fs80, import_node_os17, import_node_path77, RASTER_SWIFT, RASTER_SVG_SWIFT;
|
|
38249
38327
|
var init_swift_pdf_raster = __esm({
|
|
38250
38328
|
"src/swift-pdf-raster.ts"() {
|
|
38251
38329
|
"use strict";
|
|
38252
|
-
|
|
38330
|
+
import_node_child_process43 = require("node:child_process");
|
|
38253
38331
|
import_node_crypto40 = require("node:crypto");
|
|
38254
38332
|
import_node_fs80 = __toESM(require("node:fs"), 1);
|
|
38255
|
-
|
|
38333
|
+
import_node_os17 = __toESM(require("node:os"), 1);
|
|
38256
38334
|
import_node_path77 = __toESM(require("node:path"), 1);
|
|
38257
38335
|
init_internal_child_contract();
|
|
38258
38336
|
init_self_invocation();
|
|
@@ -38469,7 +38547,7 @@ async function wasmPortableAssembly(binaries, toolchainBin, moduleRoot) {
|
|
|
38469
38547
|
const known = emptyWasmAssembly.get(key2);
|
|
38470
38548
|
if (known) return known;
|
|
38471
38549
|
const result = new Promise(
|
|
38472
|
-
(resolve3) => (0,
|
|
38550
|
+
(resolve3) => (0, import_node_child_process44.execFile)(
|
|
38473
38551
|
clang,
|
|
38474
38552
|
[
|
|
38475
38553
|
"-target",
|
|
@@ -39713,7 +39791,7 @@ function buildSwiftBundleFiles(packagePath, hosted, inputs, resourceBundles) {
|
|
|
39713
39791
|
}
|
|
39714
39792
|
}
|
|
39715
39793
|
if (xcode?.app.postBundleScripts.length) {
|
|
39716
|
-
const dir = import_node_fs81.default.mkdtempSync(import_node_path78.default.join(
|
|
39794
|
+
const dir = import_node_fs81.default.mkdtempSync(import_node_path78.default.join(import_node_os18.default.tmpdir(), "peach-xcode-bundle-"));
|
|
39717
39795
|
const wrapper = import_node_path78.default.basename(xcode.app.settings("UNLOCALIZED_RESOURCES_FOLDER_PATH")) || `${xcode.app.name}.app`;
|
|
39718
39796
|
const bundle = import_node_path78.default.join(dir, wrapper);
|
|
39719
39797
|
try {
|
|
@@ -39764,7 +39842,7 @@ function buildSwiftBundleFiles(packagePath, hosted, inputs, resourceBundles) {
|
|
|
39764
39842
|
});
|
|
39765
39843
|
try {
|
|
39766
39844
|
const [shell, ...args] = phase.command;
|
|
39767
|
-
(0,
|
|
39845
|
+
(0, import_node_child_process44.execFileSync)(shell, args, {
|
|
39768
39846
|
cwd: phase.directory,
|
|
39769
39847
|
env,
|
|
39770
39848
|
stdio: ["ignore", "pipe", "pipe"],
|
|
@@ -40444,15 +40522,15 @@ function scopedArtifact(project, entry, moduleRoot, signal) {
|
|
|
40444
40522
|
project.building = { stamp, promise: fresh, signal };
|
|
40445
40523
|
return fresh;
|
|
40446
40524
|
}
|
|
40447
|
-
var import_node_async_hooks2,
|
|
40525
|
+
var import_node_async_hooks2, import_node_child_process44, import_node_crypto41, import_node_fs81, import_node_os18, import_node_path78, RESOURCE_PATH, ICU_PATH, SKIP_ROOT_DIRS, NATIVE_DESCRIPTOR, NATIVE_GLUE, SwiftMissingModulesError, 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;
|
|
40448
40526
|
var init_swift_host = __esm({
|
|
40449
40527
|
"src/swift-host.ts"() {
|
|
40450
40528
|
"use strict";
|
|
40451
40529
|
import_node_async_hooks2 = require("node:async_hooks");
|
|
40452
|
-
|
|
40530
|
+
import_node_child_process44 = require("node:child_process");
|
|
40453
40531
|
import_node_crypto41 = require("node:crypto");
|
|
40454
40532
|
import_node_fs81 = __toESM(require("node:fs"), 1);
|
|
40455
|
-
|
|
40533
|
+
import_node_os18 = __toESM(require("node:os"), 1);
|
|
40456
40534
|
import_node_path78 = __toESM(require("node:path"), 1);
|
|
40457
40535
|
init_bundleAssets();
|
|
40458
40536
|
init_stringCatalog();
|
|
@@ -42333,11 +42411,11 @@ async function runInstalledTurboCodegen(appRoot, outDir, signal) {
|
|
|
42333
42411
|
files: hashTree(generatedRoot)
|
|
42334
42412
|
};
|
|
42335
42413
|
}
|
|
42336
|
-
var
|
|
42414
|
+
var import_node_child_process45, import_node_crypto42, import_node_fs83, import_node_module7, import_node_path80, import_node_util14, run6, RENDERER_PODS, RENDERER_PODS_VERSIONED, COMPILED_SOURCE, LEGACY_BRIDGE_DEV_SUPPORT, LEGACY_BRIDGE_PODS, LEGACY_BRIDGE_PODS_VERSIONED;
|
|
42337
42415
|
var init_turbo_codegen_intake = __esm({
|
|
42338
42416
|
"src/turbo-codegen-intake.ts"() {
|
|
42339
42417
|
"use strict";
|
|
42340
|
-
|
|
42418
|
+
import_node_child_process45 = require("node:child_process");
|
|
42341
42419
|
import_node_crypto42 = require("node:crypto");
|
|
42342
42420
|
import_node_fs83 = __toESM(require("node:fs"), 1);
|
|
42343
42421
|
import_node_module7 = require("node:module");
|
|
@@ -42347,7 +42425,7 @@ var init_turbo_codegen_intake = __esm({
|
|
|
42347
42425
|
init_is_record();
|
|
42348
42426
|
init_nitro_source();
|
|
42349
42427
|
init_podspec_sources();
|
|
42350
|
-
run6 = (0, import_node_util14.promisify)(
|
|
42428
|
+
run6 = (0, import_node_util14.promisify)(import_node_child_process45.execFile);
|
|
42351
42429
|
RENDERER_PODS = /* @__PURE__ */ new Set([
|
|
42352
42430
|
"React-Fabric",
|
|
42353
42431
|
"React-FabricComponents",
|
|
@@ -44710,11 +44788,11 @@ extern "C" __attribute__((export_name("peach_fabric_component_names"))) const ch
|
|
|
44710
44788
|
}
|
|
44711
44789
|
`;
|
|
44712
44790
|
}
|
|
44713
|
-
var
|
|
44791
|
+
var import_node_child_process46, import_node_crypto43, import_node_fs84, import_node_path81, import_node_util15, execFileAsync3, TURBO_CORE_TARGET, TURBO_FMT_TARGET, TURBO_ENTRY_HEADER, TURBO_CORE_PUBLIC_HEADERS, REGISTRATION, CODEGEN_OBJC, UNIT, HEADER3, 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, sha2564, versionParts, iosOf, JS_CALL_INVOKER, FABRIC_HOST_INCLUDES;
|
|
44714
44792
|
var init_turbo_source = __esm({
|
|
44715
44793
|
"src/turbo-source.ts"() {
|
|
44716
44794
|
"use strict";
|
|
44717
|
-
|
|
44795
|
+
import_node_child_process46 = require("node:child_process");
|
|
44718
44796
|
import_node_crypto43 = require("node:crypto");
|
|
44719
44797
|
import_node_fs84 = __toESM(require("node:fs"), 1);
|
|
44720
44798
|
import_node_path81 = __toESM(require("node:path"), 1);
|
|
@@ -44731,7 +44809,7 @@ var init_turbo_source = __esm({
|
|
|
44731
44809
|
init_swift_submit();
|
|
44732
44810
|
init_turbo_codegen_intake();
|
|
44733
44811
|
init_xcode_project();
|
|
44734
|
-
execFileAsync3 = (0, import_node_util15.promisify)(
|
|
44812
|
+
execFileAsync3 = (0, import_node_util15.promisify)(import_node_child_process46.execFile);
|
|
44735
44813
|
TURBO_CORE_TARGET = "TurboCore";
|
|
44736
44814
|
TURBO_FMT_TARGET = "TurboFmt";
|
|
44737
44815
|
TURBO_ENTRY_HEADER = "PeachTurboEntry.hpp";
|
|
@@ -45166,7 +45244,7 @@ async function buildReactNativeCore(project, reactNativeRoot, mode, moduleRoot)
|
|
|
45166
45244
|
import_node_fs85.default.mkdirSync(members2, { recursive: true });
|
|
45167
45245
|
const stripped2 = objects.map((file, index) => {
|
|
45168
45246
|
const output2 = import_node_path83.default.join(members2, `${index}-${import_node_path83.default.basename(file)}`);
|
|
45169
|
-
(0,
|
|
45247
|
+
(0, import_node_child_process47.execFileSync)(import_node_path83.default.join(module2.toolchainBin, "llvm-objcopy"), [
|
|
45170
45248
|
"--strip-debug",
|
|
45171
45249
|
file,
|
|
45172
45250
|
output2
|
|
@@ -45175,7 +45253,7 @@ async function buildReactNativeCore(project, reactNativeRoot, mode, moduleRoot)
|
|
|
45175
45253
|
});
|
|
45176
45254
|
const archive = import_node_path83.default.join(work, `lib${target.name}.a`);
|
|
45177
45255
|
import_node_fs85.default.rmSync(archive, { force: true });
|
|
45178
|
-
(0,
|
|
45256
|
+
(0, import_node_child_process47.execFileSync)(import_node_path83.default.join(module2.toolchainBin, "llvm-ar"), [
|
|
45179
45257
|
"rcsD",
|
|
45180
45258
|
archive,
|
|
45181
45259
|
...stripped2
|
|
@@ -45228,11 +45306,11 @@ async function buildReactNativeCore(project, reactNativeRoot, mode, moduleRoot)
|
|
|
45228
45306
|
return directory2;
|
|
45229
45307
|
});
|
|
45230
45308
|
}
|
|
45231
|
-
var
|
|
45309
|
+
var import_node_child_process47, import_node_fs85, import_node_path83;
|
|
45232
45310
|
var init_react_native_core_build = __esm({
|
|
45233
45311
|
"src/react-native-core-build.ts"() {
|
|
45234
45312
|
"use strict";
|
|
45235
|
-
|
|
45313
|
+
import_node_child_process47 = require("node:child_process");
|
|
45236
45314
|
import_node_fs85 = __toESM(require("node:fs"), 1);
|
|
45237
45315
|
import_node_path83 = __toESM(require("node:path"), 1);
|
|
45238
45316
|
init_home_paths();
|
|
@@ -45381,11 +45459,11 @@ module.exports = __toCommonJS(expo_swift_bundle_exports);
|
|
|
45381
45459
|
|
|
45382
45460
|
// src/expo-swift-host.ts
|
|
45383
45461
|
var import_node_async_hooks3 = require("node:async_hooks");
|
|
45384
|
-
var
|
|
45462
|
+
var import_node_child_process48 = require("node:child_process");
|
|
45385
45463
|
var import_node_crypto45 = require("node:crypto");
|
|
45386
45464
|
var import_node_fs87 = __toESM(require("node:fs"), 1);
|
|
45387
45465
|
var import_node_module9 = require("node:module");
|
|
45388
|
-
var
|
|
45466
|
+
var import_node_os19 = __toESM(require("node:os"), 1);
|
|
45389
45467
|
var import_node_path85 = __toESM(require("node:path"), 1);
|
|
45390
45468
|
var import_node_url6 = require("node:url");
|
|
45391
45469
|
var import_node_util17 = require("node:util");
|
|
@@ -49041,7 +49119,7 @@ function getCliVersion() {
|
|
|
49041
49119
|
}
|
|
49042
49120
|
|
|
49043
49121
|
// src/expo-native-workspace.ts
|
|
49044
|
-
var
|
|
49122
|
+
var import_node_child_process35 = require("node:child_process");
|
|
49045
49123
|
var import_node_crypto27 = require("node:crypto");
|
|
49046
49124
|
var import_node_fs59 = __toESM(require("node:fs"), 1);
|
|
49047
49125
|
var import_node_module4 = require("node:module");
|
|
@@ -49144,9 +49222,11 @@ function failedOutputLine(command, cwd, output2) {
|
|
|
49144
49222
|
init_native_git();
|
|
49145
49223
|
|
|
49146
49224
|
// src/one-sdk-preparation.ts
|
|
49225
|
+
var import_node_child_process12 = require("node:child_process");
|
|
49147
49226
|
var import_node_crypto5 = require("node:crypto");
|
|
49148
49227
|
var import_node_fs21 = __toESM(require("node:fs"), 1);
|
|
49149
49228
|
var import_node_module2 = require("node:module");
|
|
49229
|
+
var import_node_os5 = __toESM(require("node:os"), 1);
|
|
49150
49230
|
var import_node_path17 = __toESM(require("node:path"), 1);
|
|
49151
49231
|
var import_node_url2 = require("node:url");
|
|
49152
49232
|
init_native_prebuilt();
|
|
@@ -49167,6 +49247,53 @@ function readOneSDKSourceManifest(value) {
|
|
|
49167
49247
|
}
|
|
49168
49248
|
|
|
49169
49249
|
// src/one-sdk-preparation.ts
|
|
49250
|
+
var GENERATE_SCRIPT = `
|
|
49251
|
+
import { writeFileSync } from 'node:fs'
|
|
49252
|
+
import { pathToFileURL } from 'node:url'
|
|
49253
|
+
const [generatorFile, resultFile, frameworks] = process.argv.slice(1)
|
|
49254
|
+
const generator = await import(pathToFileURL(generatorFile).href)
|
|
49255
|
+
const { files, generation } = await generator.generateAppSdk(JSON.parse(frameworks))
|
|
49256
|
+
writeFileSync(resultFile, JSON.stringify({ generation, files: [...files] }))
|
|
49257
|
+
`;
|
|
49258
|
+
async function generateAppSdkInChild(generatorFile, frameworks) {
|
|
49259
|
+
const directory2 = import_node_fs21.default.mkdtempSync(import_node_path17.default.join(import_node_os5.default.tmpdir(), "peach-one-sdk-"));
|
|
49260
|
+
const resultFile = import_node_path17.default.join(directory2, "result.json");
|
|
49261
|
+
try {
|
|
49262
|
+
const child = (0, import_node_child_process12.spawn)(
|
|
49263
|
+
"node",
|
|
49264
|
+
[
|
|
49265
|
+
"--input-type=module",
|
|
49266
|
+
"-e",
|
|
49267
|
+
GENERATE_SCRIPT,
|
|
49268
|
+
generatorFile,
|
|
49269
|
+
resultFile,
|
|
49270
|
+
JSON.stringify(frameworks)
|
|
49271
|
+
],
|
|
49272
|
+
{ stdio: ["ignore", "ignore", "pipe"] }
|
|
49273
|
+
);
|
|
49274
|
+
let stderr = "";
|
|
49275
|
+
child.stderr.setEncoding("utf8");
|
|
49276
|
+
child.stderr.on("data", (chunk) => {
|
|
49277
|
+
stderr += chunk;
|
|
49278
|
+
});
|
|
49279
|
+
const [status, signal] = await new Promise(
|
|
49280
|
+
(resolve3, reject) => {
|
|
49281
|
+
child.once("error", reject);
|
|
49282
|
+
child.once("close", (code, closeSignal) => resolve3([code, closeSignal]));
|
|
49283
|
+
}
|
|
49284
|
+
);
|
|
49285
|
+
if (status !== 0)
|
|
49286
|
+
throw new Error(
|
|
49287
|
+
`One SDK source generation failed (${signal ?? `exit ${status}`})${stderr ? `: ${stderr.trim().slice(-2e3)}` : ""}`
|
|
49288
|
+
);
|
|
49289
|
+
const result = JSON.parse(
|
|
49290
|
+
import_node_fs21.default.readFileSync(resultFile, "utf8")
|
|
49291
|
+
);
|
|
49292
|
+
return { generation: result.generation, files: new Map(result.files) };
|
|
49293
|
+
} finally {
|
|
49294
|
+
import_node_fs21.default.rmSync(directory2, { recursive: true, force: true });
|
|
49295
|
+
}
|
|
49296
|
+
}
|
|
49170
49297
|
async function selectOneSDK(appRoot) {
|
|
49171
49298
|
const require2 = (0, import_node_module2.createRequire)(import_node_path17.default.join(appRoot, "package.json"));
|
|
49172
49299
|
let onePackage;
|
|
@@ -49223,7 +49350,10 @@ async function prepareOneSDKSources(appRoot, output2) {
|
|
|
49223
49350
|
import_node_fs21.default.copyFileSync(import_node_path17.default.join(published2, name3), import_node_path17.default.join(directory2, name3));
|
|
49224
49351
|
return;
|
|
49225
49352
|
}
|
|
49226
|
-
const generated = await
|
|
49353
|
+
const generated = await generateAppSdkInChild(
|
|
49354
|
+
import_node_path17.default.join(selected.one, "dist/sdk/app.mjs"),
|
|
49355
|
+
selected.frameworks
|
|
49356
|
+
);
|
|
49227
49357
|
if (generated.generation !== generation)
|
|
49228
49358
|
throw new Error("One SDK source generation differs from the installed facades");
|
|
49229
49359
|
import_node_fs21.default.rmSync(directory2, { recursive: true, force: true });
|
|
@@ -49245,9 +49375,9 @@ var import_node_path54 = __toESM(require("node:path"), 1);
|
|
|
49245
49375
|
init_is_record();
|
|
49246
49376
|
|
|
49247
49377
|
// src/native-firebase-config.ts
|
|
49248
|
-
var
|
|
49378
|
+
var import_node_child_process32 = require("node:child_process");
|
|
49249
49379
|
var import_node_fs53 = __toESM(require("node:fs"), 1);
|
|
49250
|
-
var
|
|
49380
|
+
var import_node_os14 = __toESM(require("node:os"), 1);
|
|
49251
49381
|
var import_node_path51 = __toESM(require("node:path"), 1);
|
|
49252
49382
|
init_is_record();
|
|
49253
49383
|
init_plist();
|
|
@@ -49310,13 +49440,13 @@ function readExpoConfigResult(resultPath, status, signal, stderr) {
|
|
|
49310
49440
|
if (!isRecord(resolved)) throw new Error("Expo native configuration is unavailable.");
|
|
49311
49441
|
return resolved;
|
|
49312
49442
|
}
|
|
49313
|
-
var resultDirectory = () => import_node_fs53.default.mkdtempSync(import_node_path51.default.join(
|
|
49443
|
+
var resultDirectory = () => import_node_fs53.default.mkdtempSync(import_node_path51.default.join(import_node_os14.default.tmpdir(), "peach-expo-config-"));
|
|
49314
49444
|
async function readExpoConfigAsync(projectRoot) {
|
|
49315
49445
|
if (!hasExpoConfig(projectRoot)) return {};
|
|
49316
49446
|
const directory2 = resultDirectory();
|
|
49317
49447
|
const resultPath = import_node_path51.default.join(directory2, "config.json");
|
|
49318
49448
|
try {
|
|
49319
|
-
const child = (0,
|
|
49449
|
+
const child = (0, import_node_child_process32.spawn)("node", expoConfigArgs(projectRoot, resultPath), {
|
|
49320
49450
|
cwd: projectRoot,
|
|
49321
49451
|
stdio: ["ignore", "ignore", "pipe"],
|
|
49322
49452
|
timeout: EXPO_CONFIG_TIMEOUT_MS
|
|
@@ -49373,7 +49503,7 @@ function portableInterfaceHash(directory2) {
|
|
|
49373
49503
|
}
|
|
49374
49504
|
|
|
49375
49505
|
// src/prepared-native-inventory.ts
|
|
49376
|
-
var
|
|
49506
|
+
var import_node_child_process33 = require("node:child_process");
|
|
49377
49507
|
var import_node_crypto24 = require("node:crypto");
|
|
49378
49508
|
var import_node_fs55 = __toESM(require("node:fs"), 1);
|
|
49379
49509
|
var import_node_module3 = require("node:module");
|
|
@@ -49393,7 +49523,7 @@ async function preparedNativeInventory(app, selected, signal) {
|
|
|
49393
49523
|
paths: [import_node_path53.default.dirname(require2.resolve("expo/package.json"))]
|
|
49394
49524
|
});
|
|
49395
49525
|
const cli = import_node_path53.default.join(import_node_path53.default.dirname(expo), "bin/expo-modules-autolinking.js");
|
|
49396
|
-
const searched = await (0, import_node_util10.promisify)(
|
|
49526
|
+
const searched = await (0, import_node_util10.promisify)(import_node_child_process33.execFile)(
|
|
49397
49527
|
process.execPath,
|
|
49398
49528
|
[cli, "search", ...autolinkerAppleFlags(expo, app), "--json"],
|
|
49399
49529
|
{
|
|
@@ -49567,6 +49697,29 @@ var isolatedGitEnv = {
|
|
|
49567
49697
|
GIT_CONFIG_GLOBAL: "/dev/null",
|
|
49568
49698
|
GIT_CONFIG_SYSTEM: "/dev/null"
|
|
49569
49699
|
};
|
|
49700
|
+
function cleanWorkspaceGitEnv() {
|
|
49701
|
+
const env = { ...process.env };
|
|
49702
|
+
for (const key2 of [
|
|
49703
|
+
"GIT_DIR",
|
|
49704
|
+
"GIT_COMMON_DIR",
|
|
49705
|
+
"GIT_WORK_TREE",
|
|
49706
|
+
"GIT_INDEX_FILE",
|
|
49707
|
+
"GIT_OBJECT_DIRECTORY",
|
|
49708
|
+
"GIT_ALTERNATE_OBJECT_DIRECTORIES",
|
|
49709
|
+
"GIT_PREFIX",
|
|
49710
|
+
"GIT_SHALLOW_FILE",
|
|
49711
|
+
"GIT_GRAFT_FILE",
|
|
49712
|
+
"GIT_NAMESPACE",
|
|
49713
|
+
"GIT_IMPLICIT_WORK_TREE",
|
|
49714
|
+
"GIT_CONFIG",
|
|
49715
|
+
"GIT_CEILING_DIRECTORIES",
|
|
49716
|
+
"GIT_DISCOVERY_ACROSS_FILESYSTEM",
|
|
49717
|
+
"GIT_SUPER_PREFIX"
|
|
49718
|
+
]) {
|
|
49719
|
+
delete env[key2];
|
|
49720
|
+
}
|
|
49721
|
+
return { ...env, ...isolatedGitEnv };
|
|
49722
|
+
}
|
|
49570
49723
|
var utf8Env = { ...process.env, LANG: "en_US.UTF-8", LC_ALL: "en_US.UTF-8" };
|
|
49571
49724
|
function reactNativePodsEnvironment() {
|
|
49572
49725
|
return {
|
|
@@ -49590,6 +49743,7 @@ function workspacePackageManager(root, declared, excluded) {
|
|
|
49590
49743
|
}
|
|
49591
49744
|
var NATIVE_CONFIG_FILE = /(^|\/)(package\.json|bun\.lockb?|package-lock\.json|pnpm-lock\.yaml|pnpm-workspace\.yaml|yarn\.lock|\.yarnrc\.yml|\.npmrc|app\.json|app\.config\.[cm]?[jt]s|Podfile(\.lock|\.properties)?|expo-module\.config\.json|react-native\.config\.[cm]?[jt]s|\.nvmrc|\.tool-versions|\.?mise(?:\.[^/]+)?\.toml)$|\.(podspec|patch|plist|entitlements|xcconfig|pbxproj|storyboard|xib|gradle|rb)$|(^|\/)(plugins|patches)\//;
|
|
49592
49745
|
var NATIVE_SOURCE_FILE2 = /\.(swift|mm?|hpp?|c|cc|cpp|kt|java)$/;
|
|
49746
|
+
var fileDigests = /* @__PURE__ */ new Map();
|
|
49593
49747
|
var NATIVE_PACKAGE_ENTRY = /^(ios|android|.*\.podspec|expo-module\.config\.json|react-native\.config\.[cm]?[jt]s|app\.plugin\.[cm]?js)$/;
|
|
49594
49748
|
async function hashExpoWorkspace(app, signal) {
|
|
49595
49749
|
if (process.platform !== "darwin") {
|
|
@@ -49691,40 +49845,67 @@ async function hashWorkspaceInputs(app, everyByte, signal, sourceOnly = false, p
|
|
|
49691
49845
|
const steersNative = (relative3) => !relative3.includes(import_node_path57.default.sep) || relative3.startsWith(`patches${import_node_path57.default.sep}`) || nativeDirectories.some(
|
|
49692
49846
|
(directory2) => directory2 === "" || relative3 === directory2 || relative3.startsWith(directory2 + import_node_path57.default.sep)
|
|
49693
49847
|
);
|
|
49694
|
-
const
|
|
49695
|
-
|
|
49696
|
-
|
|
49848
|
+
const steps = [];
|
|
49849
|
+
const unread = [];
|
|
49850
|
+
const walk3 = (directory2) => {
|
|
49851
|
+
const entries = import_node_fs59.default.readdirSync(directory2, { withFileTypes: true }).sort((a, b) => a.name.localeCompare(b.name));
|
|
49852
|
+
for (const entry of entries) {
|
|
49697
49853
|
signal?.throwIfAborted();
|
|
49698
49854
|
const file = import_node_path57.default.join(directory2, entry.name);
|
|
49699
49855
|
const relative3 = import_node_path57.default.relative(root, file);
|
|
49700
49856
|
if (excluded(relative3, entry.isDirectory())) continue;
|
|
49701
|
-
hash.update(`${relative3}\0`);
|
|
49857
|
+
steps.push(() => hash.update(`${relative3}\0`));
|
|
49702
49858
|
if (entry.isSymbolicLink()) {
|
|
49703
|
-
const link = `link\0${
|
|
49704
|
-
|
|
49705
|
-
|
|
49859
|
+
const link = `link\0${import_node_fs59.default.readlinkSync(file)}\0`;
|
|
49860
|
+
steps.push(() => {
|
|
49861
|
+
hash.update(link);
|
|
49862
|
+
if (steersNative(relative3)) native.update(`${relative3}\0${link}`);
|
|
49863
|
+
});
|
|
49706
49864
|
} else if (entry.isDirectory()) {
|
|
49707
|
-
hash.update("directory\0");
|
|
49708
|
-
|
|
49865
|
+
steps.push(() => hash.update("directory\0"));
|
|
49866
|
+
walk3(file);
|
|
49709
49867
|
} else if (entry.isFile()) {
|
|
49710
49868
|
const posix = relative3.split(import_node_path57.default.sep).join("/");
|
|
49711
49869
|
if (NATIVE_CONFIG_FILE.test(posix)) {
|
|
49712
|
-
const bytes =
|
|
49713
|
-
|
|
49714
|
-
|
|
49715
|
-
|
|
49716
|
-
|
|
49717
|
-
|
|
49718
|
-
|
|
49719
|
-
hash.update(`file\0${bytes.length}\0`).update(bytes);
|
|
49720
|
-
}
|
|
49721
|
-
if (NATIVE_SOURCE_FILE2.test(posix) && steersNative(relative3))
|
|
49722
|
-
native.update(`${posix}\0`);
|
|
49870
|
+
const bytes = import_node_fs59.default.readFileSync(file);
|
|
49871
|
+
steps.push(() => {
|
|
49872
|
+
if (everyByte) hash.update(`file\0${bytes.length}\0`).update(bytes);
|
|
49873
|
+
if (steersNative(relative3))
|
|
49874
|
+
native.update(`${posix}\0`).update(nativeConfigBytes(posix, bytes));
|
|
49875
|
+
});
|
|
49876
|
+
continue;
|
|
49723
49877
|
}
|
|
49878
|
+
if (everyByte) {
|
|
49879
|
+
const stat = import_node_fs59.default.statSync(file);
|
|
49880
|
+
const known = fileDigests.get(file);
|
|
49881
|
+
const content = known?.ino === stat.ino && known.size === stat.size && known.mtimeMs === stat.mtimeMs && known.ctimeMs === stat.ctimeMs ? known : {
|
|
49882
|
+
ino: stat.ino,
|
|
49883
|
+
size: stat.size,
|
|
49884
|
+
mtimeMs: stat.mtimeMs,
|
|
49885
|
+
ctimeMs: stat.ctimeMs,
|
|
49886
|
+
digest: ""
|
|
49887
|
+
};
|
|
49888
|
+
if (content !== known) unread.push({ file, content });
|
|
49889
|
+
steps.push(() => hash.update(`file\0${content.size}\0${content.digest}`));
|
|
49890
|
+
}
|
|
49891
|
+
if (NATIVE_SOURCE_FILE2.test(posix) && steersNative(relative3))
|
|
49892
|
+
steps.push(() => native.update(`${posix}\0`));
|
|
49724
49893
|
}
|
|
49725
49894
|
}
|
|
49726
49895
|
};
|
|
49727
|
-
|
|
49896
|
+
walk3(root);
|
|
49897
|
+
for (let start = 0; start < unread.length; start += 32) {
|
|
49898
|
+
signal?.throwIfAborted();
|
|
49899
|
+
await Promise.all(
|
|
49900
|
+
unread.slice(start, start + 32).map(async ({ file, content }) => {
|
|
49901
|
+
const bytes = await import_node_fs59.default.promises.readFile(file);
|
|
49902
|
+
content.size = bytes.length;
|
|
49903
|
+
content.digest = (0, import_node_crypto27.createHash)("sha256").update(bytes).digest("hex");
|
|
49904
|
+
fileDigests.set(file, content);
|
|
49905
|
+
})
|
|
49906
|
+
);
|
|
49907
|
+
}
|
|
49908
|
+
for (const step of steps) step();
|
|
49728
49909
|
if (sourceOnly) {
|
|
49729
49910
|
hash.update(`\0${appRelative}\0`);
|
|
49730
49911
|
return {
|
|
@@ -49735,29 +49916,32 @@ async function hashWorkspaceInputs(app, everyByte, signal, sourceOnly = false, p
|
|
|
49735
49916
|
excluded
|
|
49736
49917
|
};
|
|
49737
49918
|
}
|
|
49738
|
-
const execFileAsync4 = (0, import_node_util11.promisify)(
|
|
49739
|
-
const mac = process.platform === "darwin" ? await Promise.all([
|
|
49740
|
-
// runner-toolchain-platform: darwin
|
|
49741
|
-
execFileAsync4("pod", ["--version"], { env: utf8Env, signal }).catch(
|
|
49742
|
-
(cause) => {
|
|
49743
|
-
throw new Error("CocoaPods is required to install source dependencies", {
|
|
49744
|
-
cause
|
|
49745
|
-
});
|
|
49746
|
-
}
|
|
49747
|
-
),
|
|
49748
|
-
// runner-toolchain-platform: darwin
|
|
49749
|
-
execFileAsync4("xcodebuild", ["-version"], { env: utf8Env, signal })
|
|
49750
|
-
]).then(([pod, xcode]) => ({ podVersion: pod.stdout, xcode: xcode.stdout })) : {};
|
|
49919
|
+
const execFileAsync4 = (0, import_node_util11.promisify)(import_node_child_process35.execFile);
|
|
49751
49920
|
const pinnedNode = typeof manifest.engines?.node === "string" && /^\d+(\.\d+){0,2}$/.test(manifest.engines.node) ? `node@${manifest.engines.node}` : null;
|
|
49921
|
+
const [mac, node] = await Promise.all([
|
|
49922
|
+
process.platform === "darwin" ? Promise.all([
|
|
49923
|
+
// runner-toolchain-platform: darwin
|
|
49924
|
+
execFileAsync4("pod", ["--version"], { env: utf8Env, signal }).catch(
|
|
49925
|
+
(cause) => {
|
|
49926
|
+
throw new Error("CocoaPods is required to install source dependencies", {
|
|
49927
|
+
cause
|
|
49928
|
+
});
|
|
49929
|
+
}
|
|
49930
|
+
),
|
|
49931
|
+
// runner-toolchain-platform: darwin
|
|
49932
|
+
execFileAsync4("xcodebuild", ["-version"], { env: utf8Env, signal })
|
|
49933
|
+
]).then(([pod, xcode]) => ({ podVersion: pod.stdout, xcode: xcode.stdout })) : {},
|
|
49934
|
+
execFileAsync4(
|
|
49935
|
+
pinnedNode ? "mise" : "node",
|
|
49936
|
+
pinnedNode ? ["exec", pinnedNode, "--", "node", "--version"] : ["--version"],
|
|
49937
|
+
{ cwd: root, signal }
|
|
49938
|
+
)
|
|
49939
|
+
]);
|
|
49752
49940
|
const toolchain = JSON.stringify({
|
|
49753
49941
|
preparation: 7,
|
|
49754
49942
|
appRelative,
|
|
49755
49943
|
...mac,
|
|
49756
|
-
node: (
|
|
49757
|
-
pinnedNode ? "mise" : "node",
|
|
49758
|
-
pinnedNode ? ["exec", pinnedNode, "--", "node", "--version"] : ["--version"],
|
|
49759
|
-
{ cwd: root, signal }
|
|
49760
|
-
)).stdout.trim(),
|
|
49944
|
+
node: node.stdout.trim(),
|
|
49761
49945
|
packageManager: workspacePackageManager(root, manifest.packageManager, excluded),
|
|
49762
49946
|
podsEnvironment
|
|
49763
49947
|
});
|
|
@@ -49951,7 +50135,7 @@ async function copyInstalledWorkspace(root, destination, excluded) {
|
|
|
49951
50135
|
});
|
|
49952
50136
|
if (process.platform === "darwin") {
|
|
49953
50137
|
await new Promise((resolve3, reject) => {
|
|
49954
|
-
const child = (0,
|
|
50138
|
+
const child = (0, import_node_child_process35.execFile)(
|
|
49955
50139
|
compiledSwiftHelper(CLONE_SWIFT, "peach-clone-entries"),
|
|
49956
50140
|
(error) => error ? reject(error) : resolve3()
|
|
49957
50141
|
);
|
|
@@ -49967,7 +50151,7 @@ async function copyInstalledWorkspace(root, destination, excluded) {
|
|
|
49967
50151
|
const clone = async () => {
|
|
49968
50152
|
const relative3 = entries.pop();
|
|
49969
50153
|
if (relative3 === void 0) return;
|
|
49970
|
-
await (0, import_node_util11.promisify)(
|
|
50154
|
+
await (0, import_node_util11.promisify)(import_node_child_process35.execFile)("cp", [
|
|
49971
50155
|
"-R",
|
|
49972
50156
|
"-p",
|
|
49973
50157
|
import_node_path57.default.join(root, relative3),
|
|
@@ -49991,9 +50175,9 @@ function nativeWorkspacesDir(root) {
|
|
|
49991
50175
|
return import_node_path57.default.join(mount, ".peach-cache", "expo-native-workspaces");
|
|
49992
50176
|
}
|
|
49993
50177
|
function trackedSourceEntries(root, work) {
|
|
49994
|
-
const listed = (0,
|
|
50178
|
+
const listed = (0, import_node_child_process35.spawnSync)("git", ["ls-files", "--stage", "-z"], {
|
|
49995
50179
|
cwd: root,
|
|
49996
|
-
env:
|
|
50180
|
+
env: cleanWorkspaceGitEnv(),
|
|
49997
50181
|
maxBuffer: 256 * 1024 * 1024
|
|
49998
50182
|
});
|
|
49999
50183
|
if (listed.status !== 0) return [];
|
|
@@ -50004,9 +50188,9 @@ function trackedSourceEntries(root, work) {
|
|
|
50004
50188
|
}
|
|
50005
50189
|
function initializeWorkspaceGit(root, work) {
|
|
50006
50190
|
requireNativeGit();
|
|
50007
|
-
const env =
|
|
50008
|
-
(0,
|
|
50009
|
-
(0,
|
|
50191
|
+
const env = cleanWorkspaceGitEnv();
|
|
50192
|
+
(0, import_node_child_process35.execFileSync)("git", ["init", "--quiet"], { cwd: work, env });
|
|
50193
|
+
(0, import_node_child_process35.execFileSync)(
|
|
50010
50194
|
"git",
|
|
50011
50195
|
[
|
|
50012
50196
|
"-c",
|
|
@@ -50026,7 +50210,7 @@ function initializeWorkspaceGit(root, work) {
|
|
|
50026
50210
|
);
|
|
50027
50211
|
const tracked = trackedSourceEntries(root, work);
|
|
50028
50212
|
if (tracked.length > 0)
|
|
50029
|
-
(0,
|
|
50213
|
+
(0, import_node_child_process35.execFileSync)("git", ["update-index", "-z", "--index-info"], {
|
|
50030
50214
|
cwd: work,
|
|
50031
50215
|
env,
|
|
50032
50216
|
input: tracked.join("\0")
|
|
@@ -50082,7 +50266,7 @@ async function prepareWorkspace(app, stage, key2, podsEnvironment) {
|
|
|
50082
50266
|
}
|
|
50083
50267
|
const trustedConfigs = /* @__PURE__ */ new Set();
|
|
50084
50268
|
for (const cwd of [root, app]) {
|
|
50085
|
-
const result2 = (0,
|
|
50269
|
+
const result2 = (0, import_node_child_process35.spawnSync)("mise", ["config", "ls", "--json"], {
|
|
50086
50270
|
cwd,
|
|
50087
50271
|
encoding: "utf8"
|
|
50088
50272
|
});
|
|
@@ -50125,7 +50309,7 @@ async function prepareWorkspace(app, stage, key2, podsEnvironment) {
|
|
|
50125
50309
|
const command = [...prefix, ...args];
|
|
50126
50310
|
await run8(command[0], command.slice(1), cwd, env);
|
|
50127
50311
|
};
|
|
50128
|
-
const installedBun = manager.startsWith("bun@") ? (0,
|
|
50312
|
+
const installedBun = manager.startsWith("bun@") ? (0, import_node_child_process35.spawnSync)(bunExecutable, ["--version"], { encoding: "utf8" }) : null;
|
|
50129
50313
|
if (manager.startsWith("bun@") && (installedBun?.status !== 0 || installedBun.stdout.trim() !== manager.slice(4)))
|
|
50130
50314
|
await execute(
|
|
50131
50315
|
[
|
|
@@ -50244,7 +50428,7 @@ function stageCachedQuickCryptoOpenSsl(app) {
|
|
|
50244
50428
|
return;
|
|
50245
50429
|
import_node_fs59.default.rmSync(opensslDir, { recursive: true, force: true });
|
|
50246
50430
|
import_node_fs59.default.mkdirSync(opensslDir, { recursive: true });
|
|
50247
|
-
(0,
|
|
50431
|
+
(0, import_node_child_process35.execFileSync)("unzip", ["-q", "-o", archive, "-d", opensslDir]);
|
|
50248
50432
|
}
|
|
50249
50433
|
async function runAdmitted(lease, command, args, cwd, extraEnv) {
|
|
50250
50434
|
const admitted = teamMachineInstalled();
|
|
@@ -50846,7 +51030,7 @@ init_swift_native_pin();
|
|
|
50846
51030
|
init_xcode_project();
|
|
50847
51031
|
var EXPO_NATIVE_ENTRY_NAME = "ios";
|
|
50848
51032
|
function expoNativeCompilerDigestValue() {
|
|
50849
|
-
return true ? "
|
|
51033
|
+
return true ? "5bd208e7dcf4c6f40ee2cb35f3bc1f4c710be71d38a0d00ba5f8702ca05da987" : expoNativeCompilerDigest(__sootsim_import_meta_dirname);
|
|
50850
51034
|
}
|
|
50851
51035
|
var IDENTITY_SOURCE_SKIPS = 1 | 4 | 8 | 16 | 32 | 64 | 128 | 4096;
|
|
50852
51036
|
function readSources(value) {
|
|
@@ -51658,7 +51842,7 @@ init_swift_standins();
|
|
|
51658
51842
|
init_swift_submit();
|
|
51659
51843
|
init_swift_toolchain();
|
|
51660
51844
|
init_turbo_source();
|
|
51661
|
-
var run7 = (0, import_node_util17.promisify)(
|
|
51845
|
+
var run7 = (0, import_node_util17.promisify)(import_node_child_process48.execFile);
|
|
51662
51846
|
var scriptEnv = { ...process.env, [PEACH_FORKED_SCRIPT_ENV]: "1" };
|
|
51663
51847
|
var EXPO_SWIFT_ENTRY = "Sources/PeachExpoApp/PeachExpoEntry.swift";
|
|
51664
51848
|
var WITNESS_BATCH = 200;
|
|
@@ -53262,7 +53446,7 @@ function expoUnitAppPaths(unit2) {
|
|
|
53262
53446
|
});
|
|
53263
53447
|
}
|
|
53264
53448
|
function expoSwiftPackage(appKey, name3) {
|
|
53265
|
-
return import_node_path85.default.join(
|
|
53449
|
+
return import_node_path85.default.join(import_node_os19.default.tmpdir(), "peach-expo-swift", appKey, `p${process.pid}`, name3);
|
|
53266
53450
|
}
|
|
53267
53451
|
var ExpoSwiftLinkRefusal = class extends Error {
|
|
53268
53452
|
};
|