]> git.ipfire.org Git - thirdparty/zstd.git/commitdiff
[contrib][linux] Fix build with CONFIG_WERROR
authorAlexander Lobakin <alobakin@pm.me>
Tue, 21 Sep 2021 18:06:49 +0000 (20:06 +0200)
committerAlexander Lobakin <alobakin@pm.me>
Thu, 23 Sep 2021 14:39:10 +0000 (16:39 +0200)
Linux 5.15 introduces a new Kconfig option, CONFIG_WERROR, which
forces -Werror for the entire kernel.
Current in-kernel ZSTD implementation uses functions deprecated
in 1.5.0, and thus fails on -Wdeprecated-declarations.
Turn this particular error into warning to be able to build the
kernel with CONFIG_WERROR. I'm not disabling them completely to
make sure they'll be visible and [hopefully] fixed sooner or later.

Signed-off-by: Alexander Lobakin <alobakin@pm.me>
contrib/linux-kernel/linux.mk

index 65218ec5b8f2a4e506796a755143513f6922a3c9..a26bd332509a7d74f4f0d2999fcd5bebbc48fa50 100644 (file)
@@ -12,6 +12,7 @@ obj-$(CONFIG_ZSTD_COMPRESS) += zstd_compress.o
 obj-$(CONFIG_ZSTD_DECOMPRESS) += zstd_decompress.o
 
 ccflags-y += -O3
+ccflags-y += -Wno-error=deprecated-declarations
 
 zstd_compress-y := \
                zstd_compress_module.o \