comparison armadillo-2.4.4/build_aux/cmake/Modules/ARMA_FindCBLAS.cmake @ 0:8b6102e2a9b0

Armadillo Library
author maxzanoni76 <max.zanoni@eecs.qmul.ac.uk>
date Wed, 11 Apr 2012 09:27:06 +0100
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:8b6102e2a9b0
1 # - Find CBLAS (includes and library)
2 # This module defines
3 # CBLAS_INCLUDE_DIR
4 # CBLAS_LIBRARIES
5 # CBLAS_FOUND
6 # also defined, but not for general use are
7 # CBLAS_LIBRARY, where to find the library.
8
9 FIND_PATH(CBLAS_INCLUDE_DIR cblas.h
10 /usr/include/atlas/
11 /usr/local/include/atlas/
12 /usr/include/
13 /usr/local/include/
14 )
15
16 SET(CBLAS_NAMES ${CBLAS_NAMES} cblas)
17 FIND_LIBRARY(CBLAS_LIBRARY
18 NAMES ${CBLAS_NAMES}
19 PATHS /usr/lib64/atlas /usr/lib/atlas /usr/local/lib64/atlas /usr/local/lib/atlas /usr/lib64 /usr/lib /usr/local/lib64 /usr/local/lib
20 )
21
22 IF (CBLAS_LIBRARY AND CBLAS_INCLUDE_DIR)
23 SET(CBLAS_LIBRARIES ${CBLAS_LIBRARY})
24 SET(CBLAS_FOUND "YES")
25 ELSE (CBLAS_LIBRARY AND CBLAS_INCLUDE_DIR)
26 SET(CBLAS_FOUND "NO")
27 ENDIF (CBLAS_LIBRARY AND CBLAS_INCLUDE_DIR)
28
29
30 IF (CBLAS_FOUND)
31 IF (NOT CBLAS_FIND_QUIETLY)
32 MESSAGE(STATUS "Found a CBLAS library: ${CBLAS_LIBRARIES}")
33 ENDIF (NOT CBLAS_FIND_QUIETLY)
34 ELSE (CBLAS_FOUND)
35 IF (CBLAS_FIND_REQUIRED)
36 MESSAGE(FATAL_ERROR "Could not find a CBLAS library")
37 ENDIF (CBLAS_FIND_REQUIRED)
38 ENDIF (CBLAS_FOUND)
39
40 # Deprecated declarations.
41 SET (NATIVE_CBLAS_INCLUDE_PATH ${CBLAS_INCLUDE_DIR} )
42 GET_FILENAME_COMPONENT (NATIVE_CBLAS_LIB_PATH ${CBLAS_LIBRARY} PATH)
43
44 MARK_AS_ADVANCED(
45 CBLAS_LIBRARY
46 CBLAS_INCLUDE_DIR
47 )