File tree Expand file tree Collapse file tree 2 files changed +15
-4
lines changed Expand file tree Collapse file tree 2 files changed +15
-4
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,10 @@ elseif (CMAKE_Fortran_COMPILER_ID STREQUAL "Intel")
1818 set (CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -free -stand=f18 -fpp -heap-arrays" )
1919 set (CMAKE_Fortran_FLAGS_RELEASE "-O3 -g" )
2020 set (CMAKE_Fortran_FLAGS_DEBUG "-O2 -debug" )
21+ elseif (CMAKE_Fortran_COMPILER_ID STREQUAL "IntelLLVM" )
22+ set (CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -free -stand f18 -fpp -heap-arrays" )
23+ set (CMAKE_Fortran_FLAGS_RELEASE "-O3 -g" )
24+ set (CMAKE_Fortran_FLAGS_DEBUG "-O2 -debug" )
2125elseif (CMAKE_Fortran_COMPILER_ID STREQUAL "PGI" )
2226 set (CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -Mfreeform -Mextend -Mallocatable=03" ) # -Mallocatable=03: enable F2003+ assignment semantics
2327 set (CMAKE_Fortran_FLAGS_RELEASE "-fast" )
@@ -67,6 +71,9 @@ elseif (CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang")
6771elseif (CMAKE_CXX_COMPILER_ID STREQUAL "Intel" )
6872 set (CMAKE_CXX_FLAGS_RELEASE "-O3 -g" )
6973 set (CMAKE_CXX_FLAGS_DEBUG "-O0 -debug" )
74+ elseif (CMAKE_CXX_COMPILER_ID STREQUAL "IntelLLVM" )
75+ set (CMAKE_CXX_FLAGS_RELEASE "-O3 -g" )
76+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -debug" )
7077elseif (CMAKE_CXX_COMPILER_ID STREQUAL "PGI" )
7178 set (CMAKE_CXX_FLAGS_RELEASE "-fast" )
7279 set (CMAKE_CXX_FLAGS_DEBUG "-g" )
Original file line number Diff line number Diff line change @@ -14,8 +14,10 @@ foreach (dbcsr_program_src ${DBCSR_PROGRAM_SRCS_FTN})
1414
1515 # with the Intel compiler CMake 3.12 seems to forget that the source is
1616 # actually Fortran and needs to be told explicitly:
17- set_target_properties (${dbcsr_program_name} PROPERTIES LINKER_LANGUAGE
18- Fortran)
17+ if (NOT "${CMAKE_Fortran_COMPILER_ID} " STREQUAL IntelLLVM)
18+ set_target_properties (${dbcsr_program_name} PROPERTIES LINKER_LANGUAGE
19+ Fortran)
20+ endif ()
1921endforeach ()
2022
2123# override -Werror for certain translation units
@@ -32,8 +34,10 @@ if (WITH_C_API)
3234 set (dbcsr_program_name ${dbcsr_program_name} _cpp)
3335 add_executable (${dbcsr_program_name} ${dbcsr_program_src} )
3436 target_link_libraries (${dbcsr_program_name} dbcsr_c MPI::MPI_CXX)
35- set_target_properties (${dbcsr_program_name} PROPERTIES LINKER_LANGUAGE
36- Fortran)
37+ if (NOT "${CMAKE_Fortran_COMPILER_ID} " STREQUAL IntelLLVM)
38+ set_target_properties (${dbcsr_program_name} PROPERTIES LINKER_LANGUAGE
39+ Fortran)
40+ endif ()
3741 if (OpenMP_FOUND)
3842 target_compile_options (${dbcsr_program_name} PRIVATE ${OpenMP_CXX_FLAGS} )
3943 target_link_libraries (${dbcsr_program_name} OpenMP::OpenMP_Fortran)
You can’t perform that action at this time.
0 commit comments