diff --git a/meta-oe/recipes-extended/7zip/7zip_25.01.bb b/meta-oe/recipes-extended/7zip/7zip_25.01.bb index 779b708eee..f4ea6506e1 100644 --- a/meta-oe/recipes-extended/7zip/7zip_25.01.bb +++ b/meta-oe/recipes-extended/7zip/7zip_25.01.bb @@ -9,19 +9,13 @@ LIC_FILES_CHKSUM = "file://DOC/copying.txt;md5=4fbd65380cdd255951079008b364516c CVE_PRODUCT = "7-zip 7zip" SRC_URI = "git://github.com/ip7z/7zip.git;protocol=https;branch=main \ file://0001-support-yocto-cross-compiling.patch \ + file://0001-Remove-treating-warning-as-errors.patch \ file://7z_wrapper.sh \ " SRCREV = "5e96a8279489832924056b1fa82f29d5837c9469" UPSTREAM_CHECK_URI = "https://github.com/ip7z/7zip/releases/latest" - -# Support Yocto cross compiling -CXXFLAGS:append:toolchain-clang = " -Wno-error=cast-qual -Wno-error=sign-conversion \ - -Wno-error=disabled-macro-expansion \ - -Wno-error=shorten-64-to-32 \ - -Wno-error=cast-function-type-strict" - EXTRA_OEMAKE += " \ CXXFLAGS_EXTRA='${CXXFLAGS}' \ CFLAGS_BASE2='${CFLAGS}' \ diff --git a/meta-oe/recipes-extended/7zip/files/0001-Remove-treating-warning-as-errors.patch b/meta-oe/recipes-extended/7zip/files/0001-Remove-treating-warning-as-errors.patch new file mode 100644 index 0000000000..c2bef9616a --- /dev/null +++ b/meta-oe/recipes-extended/7zip/files/0001-Remove-treating-warning-as-errors.patch @@ -0,0 +1,31 @@ +From 4d12624e7d6f09d07816d3d0007465c8533af192 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Fri, 29 Aug 2025 15:29:13 -0700 +Subject: [PATCH] Remove treating warning as errors + +clang finds additional warnings with new versions e.g. +Clang 21 added a new warning, -Wimplicit-void-ptr-cast +(grouped under -Wc++-compat), which fires whenever a +void* is implicitly converted to another pointer +type (or returned as such). + +Upstream-Status: Inappropriate [Distro-specific] + +Signed-off-by: Khem Raj +--- + CPP/7zip/7zip_gcc.mak | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/CPP/7zip/7zip_gcc.mak b/CPP/7zip/7zip_gcc.mak +index 2722c93..b7db06a 100644 +--- a/CPP/7zip/7zip_gcc.mak ++++ b/CPP/7zip/7zip_gcc.mak +@@ -24,7 +24,7 @@ PROGPATH_STATIC = $(O)/$(PROG)s + + + ifneq ($(CC), xlc) +-CFLAGS_WARN_WALL = -Werror -Wall -Wextra ++CFLAGS_WARN_WALL = -Wall -Wextra + endif + + # for object file