scripts/tracetool generates a C preprocessor macro from the name of the
build directory. Any characters which are possible in a directory name
but not allowed in a macro name must be substituted, otherwise builds
will fail.

Signed-off-by: Stefan Weil <>

I had problems with a build directory of the form "host,variant".
Is this fix needed for stable, too?

Stefan W.

 scripts/ | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/ b/scripts/
index 629b259..fe9c9e9 100755
--- a/scripts/
+++ b/scripts/
@@ -70,7 +70,7 @@ def make_group_name(filename):
     if dirname == "":
         return "common"
-    return re.sub(r"/|-", "_", dirname)
+    return re.sub(r"[^A-Za-z0-9]", "_", dirname)
 def main(args):
     global _SCRIPT

Reply via email to