aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Baldwin <jhb@FreeBSD.org>2022-11-22 16:36:40 +0000
committerJohn Baldwin <jhb@FreeBSD.org>2023-03-22 18:16:20 +0000
commitfbe7e06a3ce279e0d0afd37118a46981b5d25f05 (patch)
treebd1bc9dfe875d85d150e450cc4d8d551a7aa5ac2
parentdf3d0c0d0d0440e5fdc3b8fe0696269ca01f6476 (diff)
downloadsrc-fbe7e06a3ce279e0d0afd37118a46981b5d25f05.tar.gz
src-fbe7e06a3ce279e0d0afd37118a46981b5d25f05.zip
libsa: Add missing GNU-stack annotations to _setjmp.S.
ld.bfd marks the stack as executable for the crt objects due to the missing annotations which raises a fatal warning starting with version 2.39. (cherry picked from commit 69f6399c3733d717bc3dcefda7fcc031f06cef0d)
-rw-r--r--stand/libsa/amd64/_setjmp.S2
-rw-r--r--stand/libsa/i386/_setjmp.S2
-rw-r--r--stand/libsa/mips/_setjmp.S2
-rw-r--r--stand/libsa/powerpc/_setjmp.S2
-rw-r--r--stand/libsa/sparc64/_setjmp.S2
5 files changed, 10 insertions, 0 deletions
diff --git a/stand/libsa/amd64/_setjmp.S b/stand/libsa/amd64/_setjmp.S
index 53ea6e9b5d52..38f27dc1968d 100644
--- a/stand/libsa/amd64/_setjmp.S
+++ b/stand/libsa/amd64/_setjmp.S
@@ -90,3 +90,5 @@ ENTRY(_longjmp)
1: movq %rcx,0(%rsp)
ret
END(_longjmp)
+
+ .section .note.GNU-stack,"",%progbits
diff --git a/stand/libsa/i386/_setjmp.S b/stand/libsa/i386/_setjmp.S
index 95b0ea8037f5..5766b25816ae 100644
--- a/stand/libsa/i386/_setjmp.S
+++ b/stand/libsa/i386/_setjmp.S
@@ -75,3 +75,5 @@ ENTRY(_longjmp)
1: movl %ecx,0(%esp)
ret
END(_longjmp)
+
+ .section .note.GNU-stack,"",%progbits
diff --git a/stand/libsa/mips/_setjmp.S b/stand/libsa/mips/_setjmp.S
index 972fb2cc1ec8..68a5d8cbf5be 100644
--- a/stand/libsa/mips/_setjmp.S
+++ b/stand/libsa/mips/_setjmp.S
@@ -105,3 +105,5 @@ botch:
jal _C_LABEL(abort)
nop
END(_longjmp)
+
+ .section .note.GNU-stack,"",%progbits
diff --git a/stand/libsa/powerpc/_setjmp.S b/stand/libsa/powerpc/_setjmp.S
index 7c7c24b1237c..e5b589cf7269 100644
--- a/stand/libsa/powerpc/_setjmp.S
+++ b/stand/libsa/powerpc/_setjmp.S
@@ -113,3 +113,5 @@ ASENTRY_NOPROF(_longjmp)
/* f14-f31, fpscr */
mr 3, 4
blr
+
+ .section .note.GNU-stack,"",%progbits
diff --git a/stand/libsa/sparc64/_setjmp.S b/stand/libsa/sparc64/_setjmp.S
index 8df29e6ba750..9927b8364850 100644
--- a/stand/libsa/sparc64/_setjmp.S
+++ b/stand/libsa/sparc64/_setjmp.S
@@ -92,3 +92,5 @@ ENTRY(_longjmp)
retl
mov %g1, %o0
END(_longjmp)
+
+ .section .note.GNU-stack,"",%progbits