Re: [oe] [PATCH] assimp: use CXXFLAGS to suppress GCC 16 unused-but-set-variable error

Khem Raj <[email protected]>
Newsgroups org.openembedded.lists.openembedded-devel
Message-ID <CAMKF1srEpQ50APyZuoa7XjhjC52wRTLa8HZy2BbUPi9Qs3JOxA@mail.gmail.com>
On Tue, Aug 11, 2026 at 2:13 AM Ashwin Prabhakar via lists.openembedded.org
<[email protected]> wrote:

> The CMake option -DASSIMP_WARNINGS_AS_ERRORS=OFF is not reliably honored
> by the upstream build system, so the build still fails with GCC 16.
> Instead, pass -Wno-error=unused-but-set-variable via CXXFLAGS to
> directly override the compiler behavior regardless of how upstream
> manages -Werror.
>

It seems you have root caused it to a certain extent, I would encourage to
report it upstream as well. We don't want to disable more than what
upstream allows us to


>
> Signed-off-by: Ashwin Prabhakar <[email protected]>
> ---
>  meta-oe/recipes-graphics/assimp/assimp_git.bb | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/meta-oe/recipes-graphics/assimp/assimp_git.bb
> b/meta-oe/recipes-graphics/assimp/assimp_git.bb
> index 4cf2d1f787..32c5cdebb1 100644
> --- a/meta-oe/recipes-graphics/assimp/assimp_git.bb
> +++ b/meta-oe/recipes-graphics/assimp/assimp_git.bb
> @@ -17,10 +17,11 @@ PV = "5.x+git${SRCPV}"
>
>  inherit cmake
>
> +CXXFLAGS += "-Wno-error=unused-but-set-variable"
> +
>  EXTRA_OECMAKE = "\
>      -DASSIMP_BUILD_ASSIMP_TOOLS=OFF \
>      -DASSIMP_BUILD_TESTS=OFF \
> -    -DASSIMP_WARNINGS_AS_ERRORS=OFF \
>      -DASSIMP_LIB_INSTALL_DIR=${baselib} \
>      -DCMAKE_INSTALL_PREFIX=${prefix} \
>      -DCMAKE_INSTALL_LIBDIR=${baselib} \
> --
> 2.43.0
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#128925):
> https://lists.openembedded.org/g/openembedded-devel/message/128925
> Mute This Topic: https://lists.openembedded.org/mt/120699011/1997914
> Group Owner: [email protected]
> Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [
> [email protected]]
> -=-=-=-=-=-=-=-=-=-=-=-
>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.