https://sourceware.org/bugzilla/show_bug.cgi?id=29263
--- Comment #10 from dave.anglin at bell dot net --- On 2022-06-20 12:38 p.m., nickc at redhat dot com wrote: > https://sourceware.org/bugzilla/show_bug.cgi?id=29263 > > --- Comment #7 from Nick Clifton <nickc at redhat dot com> --- > Created attachment 14152 > --> https://sourceware.org/bugzilla/attachment.cgi?id=14152&action=edit > Proposed Patch > I believe the RWX warning comes from the second LOAD segment. It needs to be executable because of trampoline at the end of the PLT. Maybe second comment in patch could be adjusted. dave@mx3210:~/shmat$ readelf -a a.out Version: 0x1 Entry point address: 0x10334 Start of program headers: 52 (bytes into file) Start of section headers: 6804 (bytes into file) Flags: 0x210, PA-RISC 1.1 Size of this header: 52 (bytes) Size of program headers: 32 (bytes) Number of program headers: 7 Size of section headers: 40 (bytes) Number of section headers: 30 Section header string table index: 29 Section Headers: [Nr] Name Type Addr Off Size ES Flg Lk Inf Al [ 0] NULL 00000000 000000 000000 00 0 0 0 [ 1] .interp PROGBITS 00010114 000114 00000d 00 A 0 0 1 [ 2] .note.gnu.bu[...] NOTE 00010124 000124 000024 00 A 0 0 4 [ 3] .note.ABI-tag NOTE 00010148 000148 000020 00 A 0 0 4 [ 4] .hash HASH 00010168 000168 00002c 04 A 6 0 4 [ 5] .gnu.hash GNU_HASH 00010194 000194 000020 04 A 6 0 4 [ 6] .dynsym DYNSYM 000101b4 0001b4 000060 10 A 7 1 4 [ 7] .dynstr STRTAB 00010214 000214 000082 00 A 0 0 1 [ 8] .gnu.version VERSYM 00010296 000296 00000c 02 A 6 0 2 [ 9] .gnu.version_r VERNEED 000102a4 0002a4 000020 00 A 7 1 4 [10] .rela.plt RELA 000102c4 0002c4 000030 0c AI 6 23 4 [11] .init PROGBITS 000102f4 0002f4 00002c 00 AX 0 0 4 [12] .text PROGBITS 00010320 000320 0004e0 00 AX 0 0 4 [13] .fini PROGBITS 00010800 000800 000028 00 AX 0 0 4 [14] .rodata PROGBITS 00010828 000828 00001c 00 A 0 0 4 [15] .PARISC.unwind PROGBITS 00010844 000844 000100 04 AI 0 12 4 [16] .eh_frame PROGBITS 00010944 000944 000004 00 A 0 0 4 [17] .init_array INIT_ARRAY 00011000 001000 000004 04 WA 0 0 1 [18] .ctors PROGBITS 00011004 001004 000008 00 WA 0 0 4 [19] .dtors PROGBITS 0001100c 00100c 000008 00 WA 0 0 4 [20] .data.rel.ro PROGBITS 00011014 001014 000004 00 WA 0 0 4 [21] .dynamic DYNAMIC 00011018 001018 0000c8 08 WA 7 0 4 [22] .data PROGBITS 000110e0 0010e0 000008 00 WA 0 0 4 [23] .plt PROGBITS 000110e8 0010e8 00005c 00 WAX 0 0 8 [24] .got PROGBITS 00011144 001144 00001c 04 WA 0 0 4 [25] .bss NOBITS 00011160 001160 000010 00 WA 0 0 4 [26] .comment PROGBITS 00000000 001160 00001e 01 MS 0 0 1 [27] .symtab SYMTAB 00000000 001180 000570 10 28 65 4 [28] .strtab STRTAB 00000000 0016f0 0002a1 00 0 0 1 [29] .shstrtab STRTAB 00000000 001991 000100 00 0 0 1 Key to Flags: W (write), A (alloc), X (execute), M (merge), S (strings), I (info), L (link order), O (extra OS processing required), G (group), T (TLS), C (compressed), x (unknown), o (OS specific), E (exclude), R (retain), D (mbind), p (processor specific) There are no section groups in this file. Program Headers: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align PHDR 0x000034 0x00010034 0x00010034 0x000e0 0x000e0 R 0x4 INTERP 0x000114 0x00010114 0x00010114 0x0000d 0x0000d R 0x1 [Requesting program interpreter: /lib/ld.so.1] LOAD 0x000000 0x00010000 0x00010000 0x00948 0x00948 R E 0x1000 LOAD 0x001000 0x00011000 0x00011000 0x00160 0x00170 RWE 0x1000 DYNAMIC 0x001018 0x00011018 0x00011018 0x000c8 0x000c8 RW 0x4 NOTE 0x000124 0x00010124 0x00010124 0x00044 0x00044 R 0x4 GNU_STACK 0x000000 0x00000000 0x00000000 0x00000 0x00000 RWE 0x10 Dave -- You are receiving this mail because: You are on the CC list for the bug.