[PATCH 1/3] scripts: Fix minor lint warnings in build-many-glibcs.py

Yury Khrustalev yury.khrustalev@arm.com
Wed Nov 12 11:45:14 GMT 2025


---
 scripts/build-many-glibcs.py | 21 +++++++++++++--------
 1 file changed, 13 insertions(+), 8 deletions(-)

diff --git a/scripts/build-many-glibcs.py b/scripts/build-many-glibcs.py
index 732cfe2585..67fe279d6c 100755
--- a/scripts/build-many-glibcs.py
+++ b/scripts/build-many-glibcs.py
@@ -56,9 +56,11 @@ import sys
 import time
 import urllib.request
 
+REQUIRED_TOOLS = {}
+
 # This is a list of system utilities that are expected to be available
 # to this script, and, if a non-zero version is included, the minimum
-# version required to work with this sccript.
+# version required to work with this script.
 def get_list_of_required_tools():
     global REQUIRED_TOOLS
     REQUIRED_TOOLS = {
@@ -109,6 +111,9 @@ class Context(object):
     def __init__(self, topdir, parallelism, keep, replace_sources, strip,
                  full_gcc, action, exclude, shallow=False):
         """Initialize the context."""
+        self.bot_config = None
+        self.build_state = None
+        self.versions = None
         self.topdir = topdir
         self.parallelism = parallelism
         self.keep = keep
@@ -1918,7 +1923,7 @@ def get_version_common(progname,line,word,arg1):
         v = re.match(r'[0-9]+(.[0-9]+)*', v).group()
         return [int(x) for x in v.split('.')]
     except:
-        return 'missing';
+        return 'missing'
 
 def get_version_common_stderr(progname,line,word,arg1):
     try:
@@ -1931,16 +1936,16 @@ def get_version_common_stderr(progname,line,word,arg1):
         v = re.match(r'[0-9]+(.[0-9]+)*', v).group()
         return [int(x) for x in v.split('.')]
     except:
-        return 'missing';
+        return 'missing'
 
 def get_version(progname):
-    return get_version_common(progname, 0, -1, '--version');
+    return get_version_common(progname, 0, -1, '--version')
 
 def get_version_awk(progname):
-    return get_version_common(progname, 0, 2, '--version');
+    return get_version_common(progname, 0, 2, '--version')
 
 def get_version_bzip2(progname):
-    return get_version_common_stderr(progname, 0, 6, '-h');
+    return get_version_common_stderr(progname, 0, 6, '-h')
 
 def check_version(ver, req):
     for v, r in zip(ver, req):
@@ -1978,11 +1983,11 @@ def check_for_required_tools():
                     version_str(v[1])))
 
     if count_old_tools > 0 or count_missing_tools > 0:
-        exit (1);
+        exit (1)
 
 def main(argv):
     """The main entry point."""
-    check_for_required_tools();
+    check_for_required_tools()
     parser = get_parser()
     opts = parser.parse_args(argv)
     topdir = os.path.abspath(opts.topdir)
-- 
2.47.3



More information about the Libc-alpha mailing list