Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 893316 - go-module.eclass didn't respect jobs count from make.conf
Summary: go-module.eclass didn't respect jobs count from make.conf
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: William Hubbs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: makeopts-ignored
  Show dependency tree
 
Reported: 2023-02-05 21:08 UTC by outoftime
Modified: 2023-02-20 06:07 UTC (History)
4 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description outoftime 2023-02-05 21:08:34 UTC
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).
Comment 1 Ionen Wolkens gentoo-dev 2023-02-08 09:51:47 UTC
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.
Comment 2 Ionen Wolkens gentoo-dev 2023-02-08 10:10:05 UTC
(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.
Comment 3 Larry the Git Cow gentoo-dev 2023-02-17 03:20:23 UTC
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(-)
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-02-20 06:06:39 UTC
*** Bug 650944 has been marked as a duplicate of this bug. ***
Comment 5 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-02-20 06:07:14 UTC
*** Bug 649938 has been marked as a duplicate of this bug. ***