From: Martin Quinson Date: Mon, 9 Sep 2019 06:42:25 +0000 (+0200) Subject: harden fortran builds to please debian X-Git-Tag: v3.24~69^2~18 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/5dd0dada0d453b81d01de62a9b0859c617c73357 harden fortran builds to please debian --- diff --git a/tools/cmake/Flags.cmake b/tools/cmake/Flags.cmake index 99f597630f..cb7a0c2276 100644 --- a/tools/cmake/Flags.cmake +++ b/tools/cmake/Flags.cmake @@ -60,6 +60,9 @@ endif() if(enable_compile_warnings AND enable_debug) set(warnCFLAGS "${warnCFLAGS} -Werror") set(warnCXXFLAGS "${warnCXXFLAGS} -Werror") + if(CMAKE_Fortran_COMPILER_ID MATCHES "GCC") + set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -Werror -Werror=format-security") + endif() endif() # Activate the warnings on #if FOOBAR when FOOBAR has no value