Announcement

Collapse
No announcement yet.

Linux 5.15's New "-Werror" Behavior Is Causing A Lot Of Pain

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Linux 5.15's New "-Werror" Behavior Is Causing A Lot Of Pain

    Phoronix: Linux 5.15's New "-Werror" Behavior Is Causing A Lot Of Pain

    Landing this past weekend was the surprise move by Linus Torvalds to enable "-Werror" behavior by default for all kernel builds. That compiler flag addition makes all warnings be treated as errors, which in turn stops the kernel build. As expected, this change has led to quite a mess...

    https://www.phoronix.com/scan.php?pa...15-Werror-Pain

  • #2
    Different gcc versions print different warnings. Other gcc versions have buggy warnings. Good luck building the kernel everywhere.

    Comment


    • #3
      Heh, especially with C's limited functionality I wonder how many warnings are going to be "worked-around" instead of actually fixed. Seems like a plan is forming to not use -Werror anyway.

      Comment


      • #4
        If this had been done a long time ago as it should have been it wouldn't be pain. But it wasn't and now the issue has just gotten worse over time. It'll take more pain before it will get better, but it'll be dealt with.

        Comment


        • #5
          Originally posted by marek View Post
          Different gcc versions print different warnings. Other gcc versions have buggy warnings. Good luck building the kernel everywhere.
          Other operating systems have been doing this for ages. Buggy warnings can be easily disabled. It's just excuses.

          Comment


          • #6
            It would be great if distros enabled this flag for all packages. There should be no production ready source code which generates warnings - it reeks of sloppy coding.

            Besides GCC does very basic checks, so a ton of real bugs will still be there but at least the most obvious ones will be put to rest.

            Comment


            • #7
              Linus Based!

              Comment


              • #8
                Nick Desaulniers of Google
                do google wants to sideline linus using his own typical mercurial behaviour or strong reasoned opinions. better linus just question patch submitter for each warning. let patch submitter be frustated and finally use method proposed by linus.

                btw, this might be positive or encourage devs to fix compiler errors.

                Comment


                • #9
                  Originally posted by avem View Post
                  It would be great if distros enabled this flag for all packages. There should be no production ready source code which generates warnings - it reeks of sloppy coding.

                  Besides GCC does very basic checks, so a ton of real bugs will still be there but at least the most obvious ones will be put to rest.
                  For the kernel where it's a more controlled environment it is easier to do this. For package builds it is extremely unrealistic and cannot be done.

                  Comment


                  • #10
                    This should be a net positive. A warning that is a nuisance either shouldn't be a warning (compiler should be fixed), or, it is a warning and the code should be fixed.

                    Comment

                    Working...
                    X