Fix cross-compilation target by passing os/arch via --target flag instead of env vars
This commit is contained in:
parent
fca779b064
commit
c16fdaa2a2
|
|
@ -44,7 +44,7 @@ async function buildTarget(target: BuildTarget) {
|
||||||
ENTRY_POINT,
|
ENTRY_POINT,
|
||||||
'--compile',
|
'--compile',
|
||||||
'--target',
|
'--target',
|
||||||
'bun',
|
`bun-${target.os}-${target.arch}`,
|
||||||
'--minify',
|
'--minify',
|
||||||
'--sourcemap=external',
|
'--sourcemap=external',
|
||||||
'--outfile',
|
'--outfile',
|
||||||
|
|
@ -52,11 +52,6 @@ async function buildTarget(target: BuildTarget) {
|
||||||
], {
|
], {
|
||||||
stdout: 'inherit',
|
stdout: 'inherit',
|
||||||
stderr: 'inherit',
|
stderr: 'inherit',
|
||||||
env: {
|
|
||||||
...process.env,
|
|
||||||
BUN_TARGET_OS: target.os,
|
|
||||||
BUN_TARGET_ARCH: target.arch,
|
|
||||||
},
|
|
||||||
})
|
})
|
||||||
|
|
||||||
const exitCode = await proc.exited
|
const exitCode = await proc.exited
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user