summaryrefslogtreecommitdiff
path: root/libc/sysdeps
diff options
context:
space:
mode:
Diffstat (limited to 'libc/sysdeps')
-rw-r--r--libc/sysdeps/linux/common/Makefile.in8
-rw-r--r--libc/sysdeps/linux/common/ssp-local.c4
-rw-r--r--libc/sysdeps/linux/common/ssp.c3
3 files changed, 6 insertions, 9 deletions
diff --git a/libc/sysdeps/linux/common/Makefile.in b/libc/sysdeps/linux/common/Makefile.in
index b287d5de9..5d3d1e293 100644
--- a/libc/sysdeps/linux/common/Makefile.in
+++ b/libc/sysdeps/linux/common/Makefile.in
@@ -14,19 +14,17 @@ ifeq ($(EXCLUDE_BRK),y)
CSRC:=$(filter-out sbrk.c,$(CSRC))
endif
-COMMON_SSP:=ssp.c ssp-local.c
-
# full list
#COMMON_NO_MULTI:=getcwd.c getrlimit.c getrlimit64.c setrlimit.c setrlimit64.c getpriority.c getpriority64.c setpriority.c getrusage.c wait4.c getitimer.c setitimer.c open.c open64.c uname.c __syscall_fcntl.c __syscall_fcntl64.c
COMMON_NO_MULTI:=getrlimit.c getrlimit64.c setrlimit.c setrlimit64.c getpriority.c setpriority.c getrusage.c getitimer.c setitimer.c uname.c __syscall_rt_sigaction.c
+CSRC:=$(filter-out ssp-local.c,$(CSRC))
ifneq ($(UCLIBC_HAS_SSP),y)
-CSRC:=$(filter-out $(COMMON_SSP),$(CSRC))
+CSRC:=$(filter-out ssp.c,$(CSRC))
endif
ifneq ($(DOMULTI),n)
CSRC:=$(filter-out $(COMMON_NO_MULTI),$(CSRC))
-CSRC:=$(filter-out $(COMMON_SSP),$(CSRC))
endif
# fails for some reason
@@ -42,11 +40,11 @@ COMMON_OBJ:=$(patsubst %.c,$(COMMON_OUT)/%.o,$(CSRC))
libc-a-y+=$(COMMON_OBJ)
libc-so-y+=$(COMMON_OBJ:.o=.os)
+libc-static-$(UCLIBC_HAS_SSP)+=$(COMMON_OUT)/ssp-local.o
libc-nonshared-$(UCLIBC_HAS_SSP)+=$(COMMON_OUT)/ssp-local.os
libc-multi-y+=$(COMMON_SRC)
libc-nomulti-y+=$(patsubst %.c,$(COMMON_OUT)/%.o,$(COMMON_NO_MULTI))
-libc-nomulti-$(UCLIBC_HAS_SSP)+=$(patsubst %.c,$(COMMON_OUT)/%.o,$(COMMON_SSP))
objclean-y+=common_objclean
diff --git a/libc/sysdeps/linux/common/ssp-local.c b/libc/sysdeps/linux/common/ssp-local.c
index 11ae654c8..091c34c5d 100644
--- a/libc/sysdeps/linux/common/ssp-local.c
+++ b/libc/sysdeps/linux/common/ssp-local.c
@@ -23,7 +23,7 @@
#include <features.h>
-extern void __stack_chk_fail_internal (void) attribute_noreturn;
+extern void __stack_chk_fail (void) attribute_noreturn;
/* On some architectures, this helps needless PIC pointer setup
that would be needed just for the __stack_chk_fail call. */
@@ -31,5 +31,5 @@ extern void __stack_chk_fail_internal (void) attribute_noreturn;
void attribute_noreturn attribute_hidden
__stack_chk_fail_local (void)
{
- __stack_chk_fail_internal ();
+ __stack_chk_fail ();
}
diff --git a/libc/sysdeps/linux/common/ssp.c b/libc/sysdeps/linux/common/ssp.c
index 9efcd1a89..ecd9dd8d7 100644
--- a/libc/sysdeps/linux/common/ssp.c
+++ b/libc/sysdeps/linux/common/ssp.c
@@ -88,7 +88,7 @@ void attribute_noreturn __stack_smash_handler(char func[], int damaged)
terminate();
}
-void attribute_noreturn attribute_hidden __stack_chk_fail_internal(void)
+void attribute_noreturn __stack_chk_fail(void)
{
static const char msg1[] = "stack smashing detected: ";
static const char msg3[] = " terminated";
@@ -101,7 +101,6 @@ void attribute_noreturn attribute_hidden __stack_chk_fail_internal(void)
while(1)
terminate();
}
-strong_alias(__stack_chk_fail_internal,__stack_chk_fail)
#if 0
void attribute_noreturn __chk_fail(void)