Skip to content

Commit 2a495ab

Browse files
Add files via upload
1 parent edf8e54 commit 2a495ab

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

CMakeLists.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ if(CMAKE_Fortran_COMPILER_ID STREQUAL GNU)
2222
endif()
2323
elseif(CMAKE_Fortran_COMPILER_ID STREQUAL Intel)
2424
add_compile_options(-warn declarations,general,usage,interfaces,unused)
25-
add_compile_options(-standard-semantics)
25+
if(NOT CMAKE_Fortran_COMPILER_VERSION VERSION_EQUAL 20.2.1.20200827)
26+
add_compile_options(-standard-semantics)
27+
endif()
2628
if(CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 18.0)
2729
add_compile_options(-stand f15)
2830
else()
@@ -35,7 +37,7 @@ endif()
3537
# --- compiler feature checks
3638
include(CheckFortranSourceCompiles)
3739
include(CheckFortranSourceRuns)
38-
check_fortran_source_compiles("error stop i; end" f18errorstop SRC_EXT f90)
40+
check_fortran_source_runs("i=0; error stop i; end" f18errorstop SRC_EXT f90)
3941
check_fortran_source_compiles("real, allocatable :: array(:, :, :, :, :, :, :, :, :, :); end" f03rank SRC_EXT f90)
4042
check_fortran_source_runs("use, intrinsic :: iso_fortran_env, only : real128; real(real128) :: x; x = x+1; end" f03real128)
4143

0 commit comments

Comments
 (0)