When I build a project with ecbuild, the software automatically adds its own compiler flags into the project, for example https://github.com/ecmwf/ecbuild/blob/develop/cmake/compiler_flags/Intel_Fortran.cmake
I don't want that, in fact, I think ecbuild should never impose its own flags. Projects are written around the default cmake flags, depending on the build type, and only the software itself knows which flags are appropriate and needed.
For the above example Intel/Fortran, there is a -check all flag. Not every projects wants that, and there is no way to get rid of it except manually editing an ecbuild installation (which not everyone has the rights to do so) and commenting out those flags.
Question: Is there a way to disable using the ecbuild default flags using a cmake macro/flag to pass to ecbuild? I looked in https://github.com/ecmwf/ecbuild/blob/develop/bin/ecbuild but didn't see anything.
Ultimately, I think ecbuild should not add any additional flags and purely rely on the default flags for the cmake build type and what the developers add as appropriate for their own code.