forked from rosa/hakurei
internal/rosa: migrate GNU software
These are quite trivial, so migrate them in one pass. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -388,7 +388,7 @@ type Helper interface {
|
||||
// also empty. The special value helperInPlace omits the cd statement.
|
||||
wantsDir() string
|
||||
// script returns the helper-specific segment of cure script.
|
||||
script(s *S, name string) string
|
||||
script(t Toolchain, name string) string
|
||||
}
|
||||
|
||||
// PackageAttr holds build-system-agnostic attributes.
|
||||
@@ -531,7 +531,7 @@ cd '/usr/src/` + name + `/'
|
||||
extraRes,
|
||||
attr.KnownChecksum,
|
||||
attr.Env,
|
||||
scriptEarly+helper.script(t.S, name),
|
||||
scriptEarly+helper.script(t, name),
|
||||
slices.Concat(attr.Paths, []pkg.ExecPath{
|
||||
pkg.Path(AbsUsrSrc.Append(
|
||||
name+sourceSuffix,
|
||||
@@ -545,11 +545,11 @@ 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 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 is expression for flag with double of preferred job count.
|
||||
jobsLFlagE = `"-j$(expr ` + jobsE + ` '*' 2)"`
|
||||
)
|
||||
|
||||
@@ -624,7 +624,7 @@ func init() {
|
||||
panic(err)
|
||||
}
|
||||
if err = native.EvaluateFS(sub); err != nil {
|
||||
println(err)
|
||||
println(err.Error())
|
||||
os.Exit(1)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user