Skip to content

Make all warnings fatal in CI builds

Dawid Wrobel requested to merge work/werror into master

This MR:

  • enables a feature that enforces all compiler/linker warnings reported as errors (-Werrors or /WX, depending on compiler)
    • also replaces set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}") calls with generic add_compile_options().
    • also adds -Werror=return-type to regular (i.e. non-Werror) gcc/clang builds. En equivalent C4716 on msvc is already an error by default.
      • The -Werror= list could be extended further for known warnings that we otherwise want to be firm failures.
  • enables that feature in CI builds
  • also enables CMake's own warnings to be reported as errors in CI builds
  • enables additional model tests in CI builds
  • fixes compilation warnings with gcc, clang and msvc
  • fixes CMake warnings, particularly regarding outdated/missing policy declarations
  • adds missing KF5 dependencies to .kde-ci, in order to enable compilation of optional plugins
    • some plugins, which depend on autotools libs, lik aqbanking, are still not available on some platforms, though
Edited by Dawid Wrobel

Merge request reports