mirror of
https://github.com/oven-sh/bun
synced 2026-02-09 18:38:55 +00:00
## Summary Adds a new CLI flag `--compile-executable-path` that allows specifying a custom Bun executable path for cross-compilation instead of downloading from the npm registry. ## Usage ```bash bun build --compile --target=bun-linux-x64 \ --compile-executable-path=/path/to/bun-linux-x64 app.ts ``` ## Motivation The `executablePath` option was already available in the JavaScript `Bun.build()` API. This exposes the same functionality from the CLI. ## Changes - Added `--compile-executable-path <STR>` CLI parameter in `src/cli/Arguments.zig` - Added `compile_executable_path` field to `BundlerOptions` in `src/cli.zig` - Wired the option through to `StandaloneModuleGraph.toExecutable()` in `src/cli/build_command.zig` --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
15 KiB
15 KiB