Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support libc field in package.json #4454

Closed
1 task
yisibl opened this issue Mar 20, 2022 · 2 comments · Fixed by #4605
Closed
1 task

Support libc field in package.json #4454

yisibl opened this issue Mar 20, 2022 · 2 comments · Fixed by #4605
Milestone

Comments

@yisibl
Copy link

yisibl commented Mar 20, 2022

Describe the user story
Some packages (SWC, sharp, @napi-rs/canvas) publish native packages for both glibc and musl. At the moment users need to install both versions, as there is no conditional differentiator as for os and cpu.

Currently yarn 3.2+ and cnpm have implemented the libc field, the npm implementation is still under discussion.

@zkochan
Copy link
Member

zkochan commented Mar 21, 2022

Sounds good.

@yisibl
Copy link
Author

yisibl commented Mar 21, 2022

One difference between the yarn and cnpm implementations is that yarn gets the LibcFamily through process.report, while cnpm gets it through the detect-libc package.

cnpm/npminstall#388

process.report is not very compatible and depends on the Node.js version, while detect-libc does not have this problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants