Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 908685 - net-libs/nodejs should support corepack, and symlink binaries if enabled
Summary: net-libs/nodejs should support corepack, and symlink binaries if enabled
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal enhancement
Assignee: William Hubbs
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2023-06-17 13:35 UTC by Amit Prakash Ambasta
Modified: 2023-07-27 17:01 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Support for corepack as a useflag (0001-feat-net-libs-nodejs-support-for-corepack.patch,3.11 KB, patch)
2023-06-17 13:42 UTC, Amit Prakash Ambasta
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Amit Prakash Ambasta 2023-06-17 13:35:12 UTC
nodejs ships with corepack behind an default configure flag (--with-corepack). However, currently to use corepack with nodejs, the user has to manually enable corepack via `corepack enable`, which ends up creating symlinks in `/usr/bin` thus polluting it.

It would be better to expose corepack as a USE flag, and create the symlinks as part of the install phase.

Reproducible: Always
Comment 1 Amit Prakash Ambasta 2023-06-17 13:42:12 UTC
Created attachment 864052 [details, diff]
Support for corepack as a useflag

This patch enables corepack as a useflag thus making it optional, blocks
installation of yarn if enabled, and installs the symlinks as part of
the ebuild install phase to allow portage to track ownership of
binaries.
Comment 2 Amit Prakash Ambasta 2023-06-17 13:44:49 UTC
Additional information on the feature here
https://github.com/nodejs/node/blob/main/doc/api/corepack.md
Comment 3 Larry the Git Cow gentoo-dev 2023-07-27 17:01:04 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d10165aee072a96e13c6f1c84cca54e74e90f55d

commit d10165aee072a96e13c6f1c84cca54e74e90f55d
Author:     William Hubbs <williamh@gentoo.org>
AuthorDate: 2023-07-27 16:59:05 +0000
Commit:     William Hubbs <williamh@gentoo.org>
CommitDate: 2023-07-27 16:59:05 +0000

    net-libs/nodejs: support the corepack experimental pkg management tool
    
    Closes: https://bugs.gentoo.org/908685
    Signed-off-by: William Hubbs <williamh@gentoo.org>

 net-libs/nodejs/metadata.xml | 1 +
 1 file changed, 1 insertion(+)