This is an automated email from the ASF dual-hosted git repository.

acassis pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 4bcd031cf435d2b560ec1046ed4d077bdbae3e5c
Author: Marco Casaroli <[email protected]>
AuthorDate: Mon Oct 12 05:18:18 2026 +0200

    include/elf.h: Add the missing section index and type constants.
    
    Add SHN_LORESERVE, SHN_HIRESERVE, SHN_XINDEX, SHT_GROUP and
    SHT_SYMTAB_SHNDX.  They are part of the ELF specification and the C
    library of other systems defines them in <elf.h>.
    
    Assisted-by: Claude Code:claude-opus-5-5
    Signed-off-by: Marco Casaroli <[email protected]>
---
 include/elf.h | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/include/elf.h b/include/elf.h
index ec702dca4a5..803def5000f 100644
--- a/include/elf.h
+++ b/include/elf.h
@@ -158,10 +158,13 @@
 /* Table 7: Special Section Indexes */
 
 #define SHN_UNDEF          0
+#define SHN_LORESERVE      0xff00
 #define SHN_LOPROC         0xff00
 #define SHN_HIPROC         0xff1f
 #define SHN_ABS            0xfff1
 #define SHN_COMMON         0xfff2
+#define SHN_XINDEX         0xffff
+#define SHN_HIRESERVE      0xffff
 
 /* Figure 4-9: Section Types, sh_type */
 
@@ -180,6 +183,8 @@
 #define SHT_INIT_ARRAY     14
 #define SHT_FINI_ARRAY     15
 #define SHT_PREINIT_ARRAY  16
+#define SHT_GROUP          17
+#define SHT_SYMTAB_SHNDX   18
 #define SHT_LOPROC         0x70000000
 #define SHT_HIPROC         0x7fffffff
 #define SHT_LOUSER         0x80000000

Reply via email to