Open jevillard opened 4 days ago
cc @Brooooooklyn
@jevillard we have fallback logic if musl is null here: https://github.com/swc-project/swc/blob/main/packages/core/binding.js#L14-L18
Yes but in my case it does not work because i have a dockerfile with an alpine image, and inside this alpine I have nix without musl.
So the first function, isMuslFromFilesystem
, doesn't return null, but on the other hand inside my nix store I don't have musl and so when I run my pnpm test
with swc
it doesn't work.
My hook for the moment is mv /usr/bin/ldd /usr/bin/ldd.old
.
Describe the bug
I have installed Nix on an Alpine docker image and I want to run my unit tests with swc from the nix shell
nix develop -c pnpm test:cov
Input code
No response
Config
Playground link (or link to the minimal reproduction)
https://play.swc.rs/?version=1.7.26&code=H4sIAAAAAAAAA9PXV%2FBUSMnPUy9RyM7LL1coz0gsUSjJVygoLVHIzFMoyUhVKMhJrEwvyi%2FNSwFJFKUWFOWnlCancgEAvo2EiDsAAAA%3D&config=H4sIAAAAAAAAA1WPQQ7CIBBF95yCzNqtLryDhyA4bVAYCEOjpOndCy1Uu2P%2Bf8ODWUgJL9Zwl3M5liGoyBiPuSScKalvSSDlgKyjCQkuvU1cq0FZxi1a9gaSiiOmuoV8bThY7xk73jJnyAz5X6i9CxGZz2BFFY0WzzrRlOD8c9rK9pH62F1%2Fgx%2FUZcfFYPjRN2GiN%2FkPgVhWEupbFxkBAAA%3D
SWC Info output
No response
Expected behavior
That my unit tests work in a Nix environment installed on an Alpine docker image.
Actual behavior
Version
1.7.26
Additional context
I think we can change the code of this function
isMuslFromFilesystem
by