phase1: remove now redundant 'njobs' (== 'nprocs') property
authorThibaut VARÈNE <hacks@slashdirt.org>
Thu, 20 Oct 2022 18:16:10 +0000 (20:16 +0200)
committerPetr Štetiar <ynezz@true.cz>
Mon, 15 May 2023 15:36:01 +0000 (17:36 +0200)
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
phase1/master.cfg

index 8129d717f0316311764420c4a6d42ac2494ec658..3bf9338325086c3fdd651d525f7b3f5ebaef376e 100644 (file)
@@ -31,7 +31,7 @@ from buildbot.schedulers.basic import SingleBranchScheduler
 from buildbot.schedulers.forcesched import BaseParameter
 from buildbot.schedulers.forcesched import ForceScheduler
 from buildbot.schedulers.forcesched import ValidationError
-from buildbot.steps.master import MasterShellCommand, SetProperty
+from buildbot.steps.master import MasterShellCommand
 from buildbot.steps.shell import SetPropertyFromCommand
 from buildbot.steps.shell import ShellCommand
 from buildbot.steps.source.git import Git
@@ -531,13 +531,6 @@ for target in targets:
                description = "Finding number of CPUs",
                command = ["nproc"]))
 
-       # set number of jobs
-       factory.addStep(SetProperty(
-               name = "njobs",
-               property = "njobs",
-               description = "Set max concurrency",
-               value = Interpolate("%(prop:nproc:-1)s")))
-
        # find gcc and g++ compilers
        factory.addStep(FileDownload(
                name = "dlfindbinpl",
@@ -792,7 +785,7 @@ for target in targets:
        factory.addStep(ShellCommand(
                name = "dltar",
                description = "Building and installing GNU tar",
-               command = ["make", Interpolate("-j%(prop:njobs)s"), "tools/tar/compile", "V=s"],
+               command = ["make", Interpolate("-j%(prop:nproc:-1)s"), "tools/tar/compile", "V=s"],
                env = MakeEnv(tryccache=True),
                haltOnFailure = True
        ))
@@ -801,7 +794,7 @@ for target in targets:
        factory.addStep(ShellCommand(
                name = "dlrun",
                description = "Populating dl/",
-               command = ["make", Interpolate("-j%(prop:njobs)s"), "download", "V=s"],
+               command = ["make", Interpolate("-j%(prop:nproc:-1)s"), "download", "V=s"],
                env = MakeEnv(),
                logEnviron = False,
                locks = properties.FlattenList(NetLockDl, [dlLock.access('exclusive')]),
@@ -817,7 +810,7 @@ for target in targets:
        factory.addStep(ShellCommand(
                name = "tools",
                description = "Building and installing tools",
-               command = ["make", Interpolate("-j%(prop:njobs)s"), "tools/install", "V=s"],
+               command = ["make", Interpolate("-j%(prop:nproc:-1)s"), "tools/install", "V=s"],
                env = MakeEnv(tryccache=True),
                haltOnFailure = True
        ))
@@ -825,7 +818,7 @@ for target in targets:
        factory.addStep(ShellCommand(
                name = "toolchain",
                description = "Building and installing toolchain",
-               command=["make", Interpolate("-j%(prop:njobs)s"), "toolchain/install", "V=s"],
+               command=["make", Interpolate("-j%(prop:nproc:-1)s"), "toolchain/install", "V=s"],
                env = MakeEnv(),
                haltOnFailure = True
        ))
@@ -833,7 +826,7 @@ for target in targets:
        factory.addStep(ShellCommand(
                name = "kmods",
                description = "Building kmods",
-               command=["make", Interpolate("-j%(prop:njobs)s"), "target/compile", "V=s", "IGNORE_ERRORS=n m", "BUILD_LOG=1"],
+               command=["make", Interpolate("-j%(prop:nproc:-1)s"), "target/compile", "V=s", "IGNORE_ERRORS=n m", "BUILD_LOG=1"],
                env = MakeEnv(),
                haltOnFailure = True
        ))
@@ -856,7 +849,7 @@ for target in targets:
        factory.addStep(ShellCommand(
                name = "pkgbuild",
                description = "Building packages",
-               command=["make", Interpolate("-j%(prop:njobs)s"), "package/compile", "V=s", "IGNORE_ERRORS=n m", "BUILD_LOG=1"],
+               command=["make", Interpolate("-j%(prop:nproc:-1)s"), "package/compile", "V=s", "IGNORE_ERRORS=n m", "BUILD_LOG=1"],
                env = MakeEnv(),
                haltOnFailure = True
        ))
@@ -864,7 +857,7 @@ for target in targets:
        factory.addStep(ShellCommand(
                name = "pkginstall",
                description = "Installing packages",
-               command=["make", Interpolate("-j%(prop:njobs)s"), "package/install", "V=s"],
+               command=["make", Interpolate("-j%(prop:nproc:-1)s"), "package/install", "V=s"],
                env = MakeEnv(),
                haltOnFailure = True
        ))
@@ -872,7 +865,7 @@ for target in targets:
        factory.addStep(ShellCommand(
                name = "pkgindex",
                description = "Indexing packages",
-               command=["make", Interpolate("-j%(prop:njobs)s"), "package/index", "V=s", "CONFIG_SIGNED_PACKAGES="],
+               command=["make", Interpolate("-j%(prop:nproc:-1)s"), "package/index", "V=s", "CONFIG_SIGNED_PACKAGES="],
                env = MakeEnv(),
                haltOnFailure = True
        ))
@@ -880,7 +873,7 @@ for target in targets:
        factory.addStep(ShellCommand(
                name = "images",
                description = "Building and installing images",
-               command=["make", Interpolate("-j%(prop:njobs)s"), "target/install", "V=s"],
+               command=["make", Interpolate("-j%(prop:nproc:-1)s"), "target/install", "V=s"],
                env = MakeEnv(),
                haltOnFailure = True
        ))
@@ -929,7 +922,7 @@ for target in targets:
                factory.addStep(ShellCommand(
                        name = "kmodindex",
                        description = "Indexing kmod archive",
-                       command=["make", Interpolate("-j%(prop:njobs)s"), "package/index", "V=s", "CONFIG_SIGNED_PACKAGES=",
+                       command=["make", Interpolate("-j%(prop:nproc:-1)s"), "package/index", "V=s", "CONFIG_SIGNED_PACKAGES=",
                                Interpolate("PACKAGE_SUBDIRS=bin/targets/%(kw:target)s/%(kw:subtarget)s%(prop:libc)s/kmods/%(prop:kernelversion)s/", target=ts[0], subtarget=ts[1])],
                        env = MakeEnv(),
                        haltOnFailure = True