libtool-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Allow -Werror and -Werror=* through flag filtering


From: Alex Ameen
Subject: Re: [PATCH] Allow -Werror and -Werror=* through flag filtering
Date: Fri, 16 Dec 2022 12:40:10 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.5.1

Thanks I'll take this for a spin and keep you in the loop.

On 12/9/22 20:33, Sam James wrote:
* build-aux/ltmain.in (func_mode_link): allow -Werror and -Werror=* through
   flat filtering at link time.

   This is needed for detecting likely-runtime problems with LTO using
   e.g. -Werror=odr or -Werror=lto-type-mismatch.

Bug: https://bugs.gentoo.org/884767
Signed-off-by: Sam James <sam@gentoo.org>
---
  build-aux/ltmain.in | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/build-aux/ltmain.in b/build-aux/ltmain.in
index a5f21a1d..3b76bd08 100644
--- a/build-aux/ltmain.in
+++ b/build-aux/ltmain.in
@@ -5408,10 +5408,11 @@ func_mode_link ()
        # -fsanitize=*         Clang/GCC memory and address sanitizer
        # -fuse-ld=*           Linker select flags for GCC
        # -Wa,*                Pass flags directly to the assembler
+      # -Werror, -Werror=*   Report (specified) warnings as errors
        -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
        
-t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
        
-O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \
-      -specs=*|-fsanitize=*|-fuse-ld=*|-Wa,*)
+      -specs=*|-fsanitize=*|-fuse-ld=*|-Wa,*|-Werror|-Werror=*)
          func_quote_arg pretty "$arg"
        arg=$func_quote_arg_result
          func_append compile_command " $arg"



reply via email to

[Prev in Thread] Current Thread [Next in Thread]