Date: Thu, 29 Sep 2022 22:07:46 GMT From: John Baldwin <jhb@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: cdfe82d35abb - main - qat: Fix build with GCC. Message-ID: <202209292207.28TM7kYX003082@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=cdfe82d35abb12b1363b545934d4f9c3fc3e60f1 commit cdfe82d35abb12b1363b545934d4f9c3fc3e60f1 Author: John Baldwin <jhb@FreeBSD.org> AuthorDate: 2022-09-29 22:07:02 +0000 Commit: John Baldwin <jhb@FreeBSD.org> CommitDate: 2022-09-29 22:07:02 +0000 qat: Fix build with GCC. Use the correct option to suppress warnings due to discarding const from pointers on GCC vs clang. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D36780 --- sys/modules/qat/qat/Makefile | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sys/modules/qat/qat/Makefile b/sys/modules/qat/qat/Makefile index a8b58573a272..ae9f1bda0fd8 100644 --- a/sys/modules/qat/qat/Makefile +++ b/sys/modules/qat/qat/Makefile @@ -18,7 +18,12 @@ CFLAGS+= -I${SRCTOP}/sys/dev/qat/qat_api/qat_direct/include CFLAGS+= -I${SRCTOP}/sys/dev/qat/qat_api/firmware/include CFLAGS+= -I${SRCTOP}/sys/dev/qat/qat_api/common/crypto/sym/include +.include <bsd.kmod.mk> + +.if ${COMPILER_TYPE} == "clang" CWARNFLAGS.qat_ocf.c += -Wno-incompatible-pointer-types-discards-qualifiers CWARNFLAGS.qat_ocf_utils.c += -Wno-incompatible-pointer-types-discards-qualifiers - -.include <bsd.kmod.mk> +.elif ${COMPILER_TYPE} == "gcc" +CWARNFLAGS.qat_ocf.c += -Wno-discarded-qualifiers +CWARNFLAGS.qat_ocf_utils.c += -Wno-discarded-qualifiers +.endif
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202209292207.28TM7kYX003082>