+2018-07-05 Florian Weimer <fweimer@redhat.com>
+ Carlos O'Donell <carlos@redhat.com>
+
+ * debug/Makefile (CFLAGS-stack_chk_fail_local.c): Remove
+ $(no-stack-protector). stack_chk_fail_local.c can be compiled
+ with stack protector enabled because there is no risk of infinite
+ recursion.
+
2018-07-05 Maciej W. Rozycki <macro@mips.com>
[BZ #19818]
elide-routines.o := stack_chk_fail_local
# Building the stack-protector failure routines with stack protection
-# makes no sense.
+# is not required since we have already failed a stack check and are
+# exiting the process. However, the local aliases which jump to the
+# real routines should still be compiled with stack protection
+# (stack_chk_fail_local.c), so that the statically linked parts of the
+# library have the expected flags.
CFLAGS-stack_chk_fail.c += $(no-stack-protector)
-CFLAGS-stack_chk_fail_local.c += $(no-stack-protector)
CFLAGS-backtrace.c += -fno-omit-frame-pointer -funwind-tables
CFLAGS-sprintf_chk.c += $(libio-mtsafe)