the --disable-werror flag is very useful for distributions and dealing with a
myriad of build systems / versions / etc... unfortunately, libgfortran doesnt
respect this flag.
# Add -Wall -fno-repack-arrays -fno-underscoring if we are using GCC.
if test "x$GCC" = "xyes"; then
AM_FCFLAGS="-I . -Wall -Werror -fimplicit-none -fno-repack-arrays -fno-underscoring"
Well, libgfortran only uses -Werror for the Fortran code. I think it is extremely unlikely to trigger there. (That part uses no system-specific code.)
Using -Werror for libgfortran's C code would be nice, but it fails too often. (I tried it once.) Thus, libgfortran's C code is compiled without -Werror by default - even without an explicit --disable-werror.
Thus, I think your issue is rather hypothetical and I don't think it makes sense to fix it.
i'm 50/50 on this. if the code doesn't utilize anything beyond the local code base, and isn't compiled/processed by anything other than the local compiler, then the -Werror shouldn't be a problem. but i noticed -Werror was being used because some flags *were* causing warnings and so the build errored out (bug 54725). granted, this warning was valid and it's good that it broke (otherwise i might not have noticed as soon as i did), but in general, it's indeterminate warnings like that why distros want to turn off -Werror in their builds.
(1) I think that using --disable-werror is a very bad idea.
(2) I cannot remember a single instance of libgfortran being broken because of -Werror.
So I agree with Tobias:
> Thus, I think your issue is rather hypothetical and I don't think it makes
> sense to fix it.
Thus closing as WONTFIX.