Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src-draft/trunk]: src/sys/sys Fix ARM build
details: https://anonhg.NetBSD.org/src-all/rev/3f22de6e9559
branches: trunk
changeset: 931811:3f22de6e9559
user: Joerg Sonnenberger <joerg%bec.de@localhost>
date: Thu Apr 30 16:32:39 2020 +0200
description:
Fix ARM build
diffstat:
sys/sys/cdefs_elf.h | 20 +++++++++++++++++---
1 files changed, 17 insertions(+), 3 deletions(-)
diffs (37 lines):
diff -r 45beabeb7a63 -r 3f22de6e9559 sys/sys/cdefs_elf.h
--- a/sys/sys/cdefs_elf.h Fri Apr 17 18:26:28 2020 +0200
+++ b/sys/sys/cdefs_elf.h Thu Apr 30 16:32:39 2020 +0200
@@ -134,16 +134,30 @@
_C_LABEL_STRING(#name) " = " _C_LABEL_STRING(#resolver))
#endif
+#ifdef __arm__
#if __STDC__
-#define __SECTIONSTRING(_sec, _str) \
+# define __SECTIONSTRING(_sec, _str) \
+ __asm(".pushsection " #_sec ",\"MS\",%progbits,1\n" \
+ ".asciz \"" _str "\"\n" \
+ ".popsection")
+#else
+# define __SECTIONSTRING(_sec, _str) \
+ __asm(".pushsection " _sec ",\"MS\",%progbits,1\n" \
+ ".asciz \"" _str "\"\n" \
+ ".popsection")
+# endif
+#else
+# if __STDC__
+# define __SECTIONSTRING(_sec, _str) \
__asm(".pushsection " #_sec ",\"MS\",@progbits,1\n" \
".asciz \"" _str "\"\n" \
".popsection")
-#else
-#define __SECTIONSTRING(_sec, _str) \
+# else
+# define __SECTIONSTRING(_sec, _str) \
__asm(".pushsection " _sec ",\"MS\",@progbits,1\n" \
".asciz \"" _str "\"\n" \
".popsection")
+# endif
#endif
#define __IDSTRING(_n,_s) __SECTIONSTRING(.ident,_s)
Home |
Main Index |
Thread Index |
Old Index