You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
pnpm install multiple bindings of different libc #7362
@nachoaldamav I am having the same issue with @swc/core wich install both @next/swc-linux-x64-gnu and @next/swc-linux-x64-musl. I would like to clarify, this issue is caused by the missing libc field in package metadata provided by npm registry? If so, the issue will not be fixed until the npm registry starts filling this value?
@c0m1c5an5 Yes, but there is an option to fix it in pnpm itself, but we would need to fetch the whole manifests in order to make it work. Right now pnpm fetches the simplified manifests that includes the os and cpu but not the libc.
This seems to have popped up again, I'm using 10.8.0 and the same reproduction steps above work for me. I've also tried a couple of 9.15.x versions and have been able to reproduce there as well.
I traced through some of the pnpm code and it seems as though the PackageManifest object returned from the npm registry is not including the libc field.
Activity
[-]pnpm install multiple bindings of different bindings[/-][+]pnpm install multiple bindings of different libc[/+]adriaanmeuris commentedon Nov 30, 2023
I can confirm this behaviour as we're experiencing the same as described in this issue.
Our
package.jsoncontains the following configuration:{ "name": "sharp-binaries", "version": "1.0.0", "description": "", "main": "index.js", "scripts": {}, "dependencies": { "express": "4.18.2", "sharp": "0.33.0" }, "pnpm": { "supportedArchitectures": { "os": ["linux"], "cpu": ["x64"], "libc": ["musl"] } } }We're building with Docker:
After building, we're seeing both

linux-x64andlinuxmusl-x64packages:KSXGitHub commentedon Dec 4, 2023
The documentation doesn't tell much about how this is supposed to work.
Is this supposed to work with transitive optional dependencies, @zkochan?
nachoaldamav commentedon Dec 5, 2023
I think the problem is that pnpm is flagging every libc as
any, for exampleI'm checking it
c0m1c5an5 commentedon Feb 29, 2024
@nachoaldamav I am having the same issue with @swc/core wich install both @next/swc-linux-x64-gnu and @next/swc-linux-x64-musl. I would like to clarify, this issue is caused by the missing libc field in package metadata provided by npm registry? If so, the issue will not be fixed until the npm registry starts filling this value?
nachoaldamav commentedon Feb 29, 2024
@c0m1c5an5 Yes, but there is an option to fix it in pnpm itself, but we would need to fetch the whole manifests in order to make it work. Right now pnpm fetches the simplified manifests that includes the os and cpu but not the libc.
KSXGitHub commentedon Sep 25, 2024
fix: install packages with incompatible libc
fix: install packages with incompatible libc (pnpm#8569)
chore(deps): update pnpm to v9.12.0
mrstork commentedon Apr 10, 2025
This seems to have popped up again, I'm using
10.8.0and the same reproduction steps above work for me. I've also tried a couple of9.15.xversions and have been able to reproduce there as well.I traced through some of the
pnpmcode and it seems as though thePackageManifestobject returned from the npm registry is not including thelibcfield.fix(docker): Prune wrong-libc native bindings around a pnpm bug