From 6a367fa1a97ae3c7ec4f8cfd38d03cdbb31336d2 Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Wed, 30 Jul 2003 14:11:03 +0000 Subject: [PATCH] * config/obj-elf.c (obj_elf_change_section): Allow "x" for .note*. --- gas/ChangeLog | 4 ++++ gas/config/obj-elf.c | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/gas/ChangeLog b/gas/ChangeLog index 0478ffe85d..3e3df65211 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,7 @@ +2003-07-30 Alan Modra + + * config/obj-elf.c (obj_elf_change_section): Allow "x" for .note*. + 2003-07-29 Alan Modra * config/tc-sh.c (tc_gen_reloc): Test for R_SH_IND12W only when ELF. diff --git a/gas/config/obj-elf.c b/gas/config/obj-elf.c index 7a2ad34671..ec63baa082 100644 --- a/gas/config/obj-elf.c +++ b/gas/config/obj-elf.c @@ -675,8 +675,9 @@ obj_elf_change_section (name, type, attr, entsize, group_name, linkonce, push) /* As a GNU extension, we permit a .note section to be allocatable. If the linker sees an allocateable .note section, it will create a PT_NOTE segment in the output - file. */ - if (strcmp (name, ".note") != 0 || attr != SHF_ALLOC) + file. We also allow "x" for .note.GNU-stack. */ + if (!(def_type == SHT_NOTE + && (attr == SHF_ALLOC || attr == SHF_EXECINSTR))) as_warn (_("setting incorrect section attributes for %s"), name); } -- 2.11.0