@naarang/ccc 3.3.0-beta.11 → 3.3.0-beta.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +428 -428
- package/dist/scripts/build-binaries.ts +24 -11
- package/package.json +1 -1
- package/scripts/build-binaries.ts +24 -11
|
@@ -525,17 +525,30 @@ for (const { name, target, outfile, ptyLib, ngrokLib, ngrokPkg } of selectedTarg
|
|
|
525
525
|
|
|
526
526
|
// Build the binary (bun-pty and ngrok are now bundled via the generated loaders).
|
|
527
527
|
//
|
|
528
|
-
//
|
|
529
|
-
//
|
|
530
|
-
//
|
|
531
|
-
//
|
|
532
|
-
//
|
|
533
|
-
//
|
|
534
|
-
//
|
|
535
|
-
//
|
|
536
|
-
//
|
|
537
|
-
//
|
|
538
|
-
|
|
528
|
+
// --bytecode is safe again on Linux/macOS — it previously broke
|
|
529
|
+
// the Pi SDK loader (oven-sh/bun#6893, #11732) but the loader
|
|
530
|
+
// now uses static imports of a bundled Pi so resolution happens
|
|
531
|
+
// at build time. Bytecode caching => faster startup.
|
|
532
|
+
//
|
|
533
|
+
// On Windows, --bytecode + --compile triggers a Bun internal
|
|
534
|
+
// panic ("Internal assertion failure: total_insertions ... !=
|
|
535
|
+
// output_files.items.len ..."). Tracked in oven-sh/bun#23490
|
|
536
|
+
// and elsewhere; intermittently reintroduced across Bun
|
|
537
|
+
// releases. Skip --bytecode on Windows to keep the build green.
|
|
538
|
+
const useBytecode = !target.startsWith('bun-windows');
|
|
539
|
+
const buildArgs = [
|
|
540
|
+
'build',
|
|
541
|
+
'--compile',
|
|
542
|
+
'--minify',
|
|
543
|
+
...(useBytecode ? ['--bytecode'] : []),
|
|
544
|
+
`--target=${target}`,
|
|
545
|
+
'--define',
|
|
546
|
+
`BUILD_VERSION="${VERSION}"`,
|
|
547
|
+
'src/index.ts',
|
|
548
|
+
'--outfile',
|
|
549
|
+
outfilePath,
|
|
550
|
+
];
|
|
551
|
+
await $`bun ${buildArgs}`;
|
|
539
552
|
console.log(` ✓ Built ${outfile}`);
|
|
540
553
|
} catch (error) {
|
|
541
554
|
console.error(` ✗ Failed to build ${name}:`, error);
|
package/package.json
CHANGED
|
@@ -525,17 +525,30 @@ for (const { name, target, outfile, ptyLib, ngrokLib, ngrokPkg } of selectedTarg
|
|
|
525
525
|
|
|
526
526
|
// Build the binary (bun-pty and ngrok are now bundled via the generated loaders).
|
|
527
527
|
//
|
|
528
|
-
//
|
|
529
|
-
//
|
|
530
|
-
//
|
|
531
|
-
//
|
|
532
|
-
//
|
|
533
|
-
//
|
|
534
|
-
//
|
|
535
|
-
//
|
|
536
|
-
//
|
|
537
|
-
//
|
|
538
|
-
|
|
528
|
+
// --bytecode is safe again on Linux/macOS — it previously broke
|
|
529
|
+
// the Pi SDK loader (oven-sh/bun#6893, #11732) but the loader
|
|
530
|
+
// now uses static imports of a bundled Pi so resolution happens
|
|
531
|
+
// at build time. Bytecode caching => faster startup.
|
|
532
|
+
//
|
|
533
|
+
// On Windows, --bytecode + --compile triggers a Bun internal
|
|
534
|
+
// panic ("Internal assertion failure: total_insertions ... !=
|
|
535
|
+
// output_files.items.len ..."). Tracked in oven-sh/bun#23490
|
|
536
|
+
// and elsewhere; intermittently reintroduced across Bun
|
|
537
|
+
// releases. Skip --bytecode on Windows to keep the build green.
|
|
538
|
+
const useBytecode = !target.startsWith('bun-windows');
|
|
539
|
+
const buildArgs = [
|
|
540
|
+
'build',
|
|
541
|
+
'--compile',
|
|
542
|
+
'--minify',
|
|
543
|
+
...(useBytecode ? ['--bytecode'] : []),
|
|
544
|
+
`--target=${target}`,
|
|
545
|
+
'--define',
|
|
546
|
+
`BUILD_VERSION="${VERSION}"`,
|
|
547
|
+
'src/index.ts',
|
|
548
|
+
'--outfile',
|
|
549
|
+
outfilePath,
|
|
550
|
+
];
|
|
551
|
+
await $`bun ${buildArgs}`;
|
|
539
552
|
console.log(` ✓ Built ${outfile}`);
|
|
540
553
|
} catch (error) {
|
|
541
554
|
console.error(` ✗ Failed to build ${name}:`, error);
|