cmake: Check for Fortran compiler early on
This commit is contained in:
parent
138ed79fe7
commit
f047ca3111
|
@ -93,6 +93,17 @@ endif()
|
|||
|
||||
message(WARNING "CMake support is experimental. It does not yet support all build options and may not produce the same Makefiles that OpenBLAS ships with.")
|
||||
|
||||
if(NOT NOFORTRAN)
|
||||
# Check for working Fortran compiler
|
||||
include(CheckLanguage)
|
||||
check_language(Fortran)
|
||||
if(CMAKE_Fortran_COMPILER)
|
||||
enable_language(Fortran)
|
||||
else()
|
||||
set(NOFORTRAN 1)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
include("${PROJECT_SOURCE_DIR}/cmake/utils.cmake")
|
||||
include("${PROJECT_SOURCE_DIR}/cmake/system.cmake")
|
||||
|
||||
|
|
|
@ -20,12 +20,7 @@
|
|||
# NEEDBUNDERSCORE
|
||||
# NEED2UNDERSCORES
|
||||
|
||||
include(CheckLanguage)
|
||||
check_language(Fortran)
|
||||
if(CMAKE_Fortran_COMPILER)
|
||||
enable_language(Fortran)
|
||||
else()
|
||||
set (NOFORTRAN 1)
|
||||
if(NOT CMAKE_Fortran_COMPILER)
|
||||
if (NOT NO_LAPACK)
|
||||
if (NOT XXXXX)
|
||||
message(STATUS "No Fortran compiler found, can build only BLAS and f2c-converted LAPACK")
|
||||
|
|
Loading…
Reference in New Issue