summaryrefslogtreecommitdiffstats
path: root/Modules/FortranCInterface
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/FortranCInterface')
-rw-r--r--Modules/FortranCInterface/Detect.cmake3
1 files changed, 3 insertions, 0 deletions
diff --git a/Modules/FortranCInterface/Detect.cmake b/Modules/FortranCInterface/Detect.cmake
index 70dbe27..0f964a9 100644
--- a/Modules/FortranCInterface/Detect.cmake
+++ b/Modules/FortranCInterface/Detect.cmake
@@ -39,6 +39,9 @@ try_compile(FortranCInterface_COMPILED
${FortranCInterface_BINARY_DIR}
${FortranCInterface_SOURCE_DIR}
FortranCInterface
+ CMAKE_FLAGS
+ "-DCMAKE_C_FLAGS=${CMAKE_C_FLAGS}"
+ "-DCMAKE_Fortran_FLAGS=${CMAKE_Fortran_FLAGS}"
OUTPUT_VARIABLE FortranCInterface_OUTPUT)
set(FortranCInterface_COMPILED ${FortranCInterface_COMPILED})
unset(FortranCInterface_COMPILED CACHE)