-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow easy disabling of Werror in source code releases #7122
Comments
+1 |
Seconding. See also https://blog.flameeyes.eu/2009/02/future-proof-your-code-dont-use-werror/:
|
Also noting that it's not uncommon for projects using CMake to allow for users to specify CMake variables that determine if warnings are errors (e.g. LLVM's LLVM_ENABLE_WERROR http://llvm.org/docs/CMake.html). We could do something like that to turn |
@swgillespie, I think we can already do that: |
@am11 Yeah, if we had an equivalent of |
Add a build flag to make -Werror optional and let the build continue even in the presence of warnings. This option is very useful for anyone compiling with a different (version of the) compiler. A different (version of the) compiler may produce a different set of warnings and a piece of code that compiles without warnings may emit warnings with a different (version of the) compiler. Resolves https://github.com/dotnet/coreclr/issues/8586
Add a build flag to make -Werror optional and let the build continue even in the presence of warnings. This option is very useful for anyone compiling with a different (version of the) compiler. A different (version of the) compiler may produce a different set of warnings and a piece of code that compiles without warnings may emit warnings with a different (version of the) compiler. Resolves https://github.com/dotnet/coreclr/issues/8586
While
-Werror
is a great thing for engineering and especially for CI testing, it gives users unnecessary problems as compilers may add new warnings in new releases. Therefore, putting-Werror
in a non-development versions for users to compile is usually a short-sighted move.From what I can see now, CoreCLR's
-Werror
is especially troublesome for "cutting edge" distros like Arch Linux (#8317, #6941). It has also broken on "fresh" OS X releases (#7275) as well as with new library versions that deprecate old methods (#7376, #5914). Although these information can be helpful for CoreCLR developers in finding potential problems, it must be recognized that users should be given a easy way to just make it compile instead of having a package randomly break due to non-critical outside changes.(By "easy disabling" I am referring to some flags to append, not "just
sed
it away".)List of -Werror spots: https://github.com/dotnet/coreclr/search?utf8=%E2%9C%93&q=Werror
The text was updated successfully, but these errors were encountered: