Skip to content

Commit 1dfe307

Browse files
committed
[stdlib] Don't make the stack executable
If some object file doesn't contain a section of the name '.note.GNU-stack', the linker make the stack executable. We append the section to swift_begin.o and swift_end.o because don't need executable stack. (reference: http://en.chys.info/2010/12/note-gnu-stack/)
1 parent 3081a1e commit 1dfe307

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

stdlib/public/runtime/swift_sections.S

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,3 +76,4 @@ define_simple_section swift3_assocty
7676

7777
define_sized_section swift2_protocol_conformances
7878
define_sized_section swift2_type_metadata
79+
.section .note.GNU-stack,"",@progbits

0 commit comments

Comments
 (0)