forked from rosa/hakurei
internal/rosa: respect preferred job count
This discontinues use of nproc, and also overrides detection behaviour in ninja. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -602,6 +602,17 @@ cd '/usr/src/` + name + `/'
|
||||
)
|
||||
}
|
||||
|
||||
const (
|
||||
// jobsE is expression for preferred job count set by [pkg].
|
||||
jobsE = `"$` + pkg.EnvJobs + `"`
|
||||
// jobsE is expression for flag with preferred job count.
|
||||
jobsFlagE = `"-j$` + pkg.EnvJobs + `"`
|
||||
// jobsLE is expression for twice of preferred job count set by [pkg].
|
||||
jobsLE = `"$(expr ` + jobsE + ` '*' 2)"`
|
||||
// jobsE is expression for flag with double of preferred job count.
|
||||
jobsLFlagE = `"-j$(expr ` + jobsE + ` '*' 2)"`
|
||||
)
|
||||
|
||||
// newTar wraps [pkg.NewHTTPGetTar] with a simpler function signature.
|
||||
func newTar(url, checksum string, compression uint32) pkg.Artifact {
|
||||
return pkg.NewHTTPGetTar(nil, url, mustDecode(checksum), compression)
|
||||
|
||||
Reference in New Issue
Block a user