]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
tools/nolibc: always use 64-bit mode for s390 header checks
authorThomas Weißschuh <linux@weissschuh.net>
Wed, 3 Dec 2025 19:08:00 +0000 (20:08 +0100)
committerThomas Weißschuh <linux@weissschuh.net>
Sun, 4 Jan 2026 09:28:56 +0000 (10:28 +0100)
32-bit s390 support was recently removed from nolibc.
If the compiler defaults to 32-bit during the header checks, they fail.

Make sure to always use 64-bit mode for s390 heafer checks.

Fixes: 169ebcbb9082 ("tools: Remove s390 compat support")
Acked-by: Willy Tarreau <w@1wt.eu>
Acked-by: Heiko Carstens <hca@linux.ibm.com>
Link: https://patch.msgid.link/20251203-nolibc-headers-check-s390-v1-1-5d35e52a83ba@weissschuh.net
Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
tools/include/nolibc/Makefile

index 8b883a6fe580bd74ee2940835601dd0688fffebc..1958dda988954d8a604b28f5feb75ebb67ee2e14 100644 (file)
@@ -104,9 +104,12 @@ headers_standalone: headers
        $(Q)$(MAKE) -C $(srctree) headers
        $(Q)$(MAKE) -C $(srctree) headers_install INSTALL_HDR_PATH=$(OUTPUT)sysroot
 
+CFLAGS_s390 := -m64
+CFLAGS := $(CFLAGS_$(ARCH))
+
 headers_check: headers_standalone
        $(Q)for header in $(filter-out crt.h std.h,$(all_files)); do \
-               $(CC) $(CLANG_CROSS_FLAGS) -Wall -Werror -nostdinc -fsyntax-only -x c /dev/null \
+               $(CC) $(CFLAGS) $(CLANG_CROSS_FLAGS) -Wall -Werror -nostdinc -fsyntax-only -x c /dev/null \
                        -I$(or $(objtree),$(srctree))/usr/include -include $$header -include $$header || exit 1; \
        done