The only way to limit number of jobs for go packages right now is to provide `GOMAXPROCS=n` environment variable. Expected behavior for go-module.eclass is to set this variable based on value from make.conf (maybe even from `MAKEOPTS` environment in order to stay consictant).
Alternatively eclass could add `-p=$(makeopts_jobs)` to GOFLAGS rather than set more env vars. Help text: > -p n > the number of programs, such as build commands or > test binaries, that can be run in parallel. > The default is GOMAXPROCS, normally the number of CPUs available.
(In reply to Ionen Wolkens from comment #1) > Alternatively eclass could add `-p=$(makeopts_jobs)` to GOFLAGS rather than > set more env vars. Albeit I can see that being a problem either way, I don't think it's sane to run $(makeopts_jobs) in global scope.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b2ef3711590017fec705bbb8a9f00268781128a1 commit b2ef3711590017fec705bbb8a9f00268781128a1 Author: William Hubbs <williamh@gentoo.org> AuthorDate: 2023-02-17 03:13:31 +0000 Commit: William Hubbs <williamh@gentoo.org> CommitDate: 2023-02-17 03:20:13 +0000 go-module.eclass: fix -buildmode=pie, support makeopts Closes: https://bugs.gentoo.org/893316 Signed-off-by: William Hubbs <williamh@gentoo.org> eclass/go-module.eclass | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)
*** Bug 650944 has been marked as a duplicate of this bug. ***
*** Bug 649938 has been marked as a duplicate of this bug. ***