]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
gentpl.py: Ensure output is deterministic
authorAlexander Kanavin <alex.kanavin@gmail.com>
Thu, 1 Jun 2023 07:38:18 +0000 (09:38 +0200)
committerDaniel Kiper <daniel.kiper@oracle.com>
Tue, 13 Jun 2023 12:08:09 +0000 (14:08 +0200)
The output of the SOURCES lines in grub-core/Makefile.core.am, generated
from grub-core/Makefile.core.def with gentpl.py is not deterministic due to
missing sorting of the list used to generate it. Add such a sort.

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
gentpl.py

index d0470b3b2b120e32267483045feeb7f8754c72ee..bfab2113a1da7f979b07e3172a9600832a0b3bef 100644 (file)
--- a/gentpl.py
+++ b/gentpl.py
@@ -569,6 +569,7 @@ def foreach_platform_value(defn, platform, suffix, closure):
     for group in RMAP[platform]:
         for value in defn.find_all(group + suffix):
             r.append(closure(value))
+    r.sort()
     return ''.join(r)
 
 def platform_conditional(platform, closure):