From: Thomas Weißschuh Date: Mon, 25 May 2026 08:27:17 +0000 (+0200) Subject: selftests/nolibc: test against -Wwrite-strings X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3850c2920a10d5f50f5c2f8acccfb3925002f30b;p=thirdparty%2Flinux.git selftests/nolibc: test against -Wwrite-strings Users may use this warning when building their own applications. Make sure that nolibc does not trigger any such warnings. Signed-off-by: Thomas Weißschuh Acked-by: Willy Tarreau Link: https://patch.msgid.link/20260525-nolibc-write-strings-v2-3-ab5cc16c7b23@weissschuh.net --- diff --git a/tools/testing/selftests/nolibc/Makefile.include b/tools/testing/selftests/nolibc/Makefile.include index 96fe2bc2191eb..c30ca3a9ef142 100644 --- a/tools/testing/selftests/nolibc/Makefile.include +++ b/tools/testing/selftests/nolibc/Makefile.include @@ -6,7 +6,7 @@ _CFLAGS_STACKPROTECTOR ?= $(call try-run, \ $(__CFLAGS_STACKPROTECTOR)) _CFLAGS_SANITIZER ?= $(call cc-option,-fsanitize=undefined -fsanitize-trap=all) CFLAGS_NOLIBC_TEST ?= -Os -fno-ident -fno-asynchronous-unwind-tables -std=c89 \ - -W -Wall -Wextra -Wundef \ + -W -Wall -Wextra -Wundef -Wwrite-strings \ $(call cc-option,-fno-stack-protector) $(call cc-option,-Wmissing-prototypes) \ $(_CFLAGS_STACKPROTECTOR) $(_CFLAGS_SANITIZER)