summaryrefslogtreecommitdiffstats
path: root/Modules/FindLAPACK.cmake
diff options
context:
space:
mode:
authorAlin Elena <alinm.elena@gmail.com>2008-07-21 17:40:31 (GMT)
committerAlin Elena <alinm.elena@gmail.com>2008-07-21 17:40:31 (GMT)
commit834dd533ed7d73d8e97aea64bb276b4b86e71eea (patch)
tree942f7514868e72178c54b3f6d84e8685c9274021 /Modules/FindLAPACK.cmake
parentff63bb1b4441e8ef2eb2eb3cfa65cc5125e0b462 (diff)
downloadCMake-834dd533ed7d73d8e97aea64bb276b4b86e71eea.zip
CMake-834dd533ed7d73d8e97aea64bb276b4b86e71eea.tar.gz
CMake-834dd533ed7d73d8e97aea64bb276b4b86e71eea.tar.bz2
ENH: checks if Fortran is enbaled. If not an error message is produced.
Diffstat (limited to 'Modules/FindLAPACK.cmake')
-rw-r--r--Modules/FindLAPACK.cmake8
1 files changed, 7 insertions, 1 deletions
diff --git a/Modules/FindLAPACK.cmake b/Modules/FindLAPACK.cmake
index 693287d..b3fece3 100644
--- a/Modules/FindLAPACK.cmake
+++ b/Modules/FindLAPACK.cmake
@@ -1,4 +1,5 @@
-# - Find LAPACK library
+# - Find a Fortran LAPACK library
+# N.B. Fortran only. This module cannot be used to find a C LAPACK library.
# This module finds an installed fortran library that implements the LAPACK
# linear-algebra interface (see http://www.netlib.org/lapack/).
#
@@ -17,6 +18,11 @@
#
+get_property(_LANGUAGES_ GLOBAL PROPERTY ENABLED_LANGUAGES)
+if(NOT _LANGUAGES_ MATCHES Fortran)
+ message(FATAL_ERROR "FindLAPACK is Fortran-only so Fortran must be enabled.")
+endif(NOT _LANGUAGES_ MATCHES Fortran)
+
include(CheckFortranFunctionExists)
set(LAPACK_FOUND FALSE)