about summary refs log tree commit diff
path: root/string
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2023-02-06 15:07:44 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2023-02-08 17:14:03 -0300
commitfb95c316382679c0826cc8399760977cd95f15c9 (patch)
treeeb1caaabd7d87d6d9478bbdabf7b02544f6399fd /string
parent22999b2f0fb62eed1af4095d062bd1272d6afeb1 (diff)
downloadglibc-fb95c316382679c0826cc8399760977cd95f15c9.tar.gz
glibc-fb95c316382679c0826cc8399760977cd95f15c9.tar.xz
glibc-fb95c316382679c0826cc8399760977cd95f15c9.zip
string: Disable stack protector in early static initialization
For powerpc, strncmp is used on _dl_string_platform issued by
__tcb_parse_hwcap_and_convert_at_platform.

Reviewed-by: Carlos Eduardo Seo <carlos.seo@linaro.org>
Diffstat (limited to 'string')
-rw-r--r--string/Makefile2
1 files changed, 2 insertions, 0 deletions
diff --git a/string/Makefile b/string/Makefile
index 3eced0d027..c84b49aaa5 100644
--- a/string/Makefile
+++ b/string/Makefile
@@ -230,6 +230,8 @@ LDFLAGS-tst-xbzero-opt = -z now
 # Called during TLS initialization.
 CFLAGS-memcpy.c += $(no-stack-protector)
 CFLAGS-wordcopy.c += $(no-stack-protector)
+# Called during static initialization
+CFLAGS-strncmp.c += $(no-stack-protector)
 
 CFLAGS-argz-next.c += $(config-cflags-wno-ignored-attributes)
 CFLAGS-basename.c += $(config-cflags-wno-ignored-attributes)