[buildbot] phase1: remove checkBuiltin deadcode
LEDE Commits
lede-commits at lists.infradead.org
Mon May 15 08:38:55 PDT 2023
ynezz pushed a commit to buildbot.git, branch master:
https://git.openwrt.org/6904fc5f2c92952fe12f30ccce83a96f84ba8c7a
commit 6904fc5f2c92952fe12f30ccce83a96f84ba8c7a
Author: Thibaut VARÈNE <hacks at slashdirt.org>
AuthorDate: Wed Oct 19 19:57:18 2022 +0200
phase1: remove checkBuiltin deadcode
Signed-off-by: Thibaut VARÈNE <hacks at slashdirt.org>
---
phase1/master.cfg | 55 -------------------------------------------------------
1 file changed, 55 deletions(-)
diff --git a/phase1/master.cfg b/phase1/master.cfg
index 16817d4..8c708d2 100644
--- a/phase1/master.cfg
+++ b/phase1/master.cfg
@@ -574,59 +574,6 @@ c['builders'] = []
dlLock = locks.WorkerLock("worker_dl")
-checkBuiltin = re.sub('[\t\n ]+', ' ', """
- checkBuiltin() {
- local symbol op path file;
- for file in $CHANGED_FILES; do
- case "$file" in
- package/*/*) : ;;
- *) return 0 ;;
- esac;
- done;
- while read symbol op path; do
- case "$symbol" in package-*)
- symbol="${symbol##*(}";
- symbol="${symbol%)}";
- for file in $CHANGED_FILES; do
- case "$file" in "package/$path/"*)
- grep -qsx "$symbol=y" .config && return 0
- ;; esac;
- done;
- esac;
- done < tmp/.packagedeps;
- return 1;
- }
-""").strip()
-
-
-class IfBuiltinShellCommand(ShellCommand):
- def _quote(self, str):
- if re.search("[^a-zA-Z0-9/_.-]", str):
- return "'%s'" %(re.sub("'", "'\"'\"'", str))
- return str
-
- def setCommand(self, command):
- if not isinstance(command, (str, unicode)):
- command = ' '.join(map(self._quote, command))
- self.command = [
- '/bin/sh', '-c',
- '%s; if checkBuiltin; then %s; else exit 0; fi' %(checkBuiltin, command)
- ]
-
- def setupEnvironment(self, cmd):
- workerEnv = self.workerEnvironment
- if workerEnv is None:
- workerEnv = { }
- changedFiles = { }
- for request in self.build.requests:
- for source in request.sources:
- for change in source.changes:
- for file in change.files:
- changedFiles[file] = True
- fullSlaveEnv = workerEnv.copy()
- fullSlaveEnv['CHANGED_FILES'] = ' '.join(changedFiles.keys())
- cmd.args['env'] = fullSlaveEnv
-
workerNames = [ ]
for worker in c['workers']:
@@ -1015,7 +962,6 @@ for target in targets:
haltOnFailure = True
))
- # factory.addStep(IfBuiltinShellCommand(
factory.addStep(ShellCommand(
name = "pkginstall",
description = "Installing packages",
@@ -1032,7 +978,6 @@ for target in targets:
haltOnFailure = True
))
- #factory.addStep(IfBuiltinShellCommand(
factory.addStep(ShellCommand(
name = "images",
description = "Building and installing images",
More information about the lede-commits
mailing list