[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 1/1] gensymlist: fix clang build with exporting of __builtin_trap
From: |
Darren Kenny |
Subject: |
[PATCH 1/1] gensymlist: fix clang build with exporting of __builtin_trap |
Date: |
Tue, 14 Jun 2022 13:35:44 +0000 |
clang expands the abort function to __builtin_trap, but that cannot be
exported.
The script that generates the symlist.c file should also exclude any
symbols that start with __builtin_.
Signed-off-by: Darren Kenny <darren.kenny@oracle.com>
---
grub-core/gensymlist.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/grub-core/gensymlist.sh b/grub-core/gensymlist.sh
index 5074ef6aad58..a2e5b85d0a71 100644
--- a/grub-core/gensymlist.sh
+++ b/grub-core/gensymlist.sh
@@ -58,6 +58,7 @@ EOF
(while read LINE; do echo $LINE; done) \
| grep -v '^#' \
+ | grep -v 'EXPORT_FUNC *(__builtin_[a-zA-Z0-9_]*)' \
| sed -n \
-e '/EXPORT_FUNC *([a-zA-Z0-9_]*)/{s/.*EXPORT_FUNC
*(\([a-zA-Z0-9_]*\)).*/ {"\1", \1, 1},/;p;}' \
-e '/EXPORT_VAR *([a-zA-Z0-9_]*)/{s/.*EXPORT_VAR
*(\([a-zA-Z0-9_]*\)).*/ {"\1", (void *) \&\1, 0},/;p;}' \
--
2.31.1