@ -27,10 +27,17 @@
# t o l i n k a g a i n s t t o u s e B L A S 9 5 i n t e r f a c e
# B L A S 9 5 _ F O U N D - s e t t o t r u e i f a l i b r a r y i m p l e m e n t i n g t h e B L A S f 9 5 i n t e r f a c e
# i s f o u n d
#
# T h e f o l l o w i n g v a r i a b l e s c a n b e u s e d t o c o n t r o l t h i s m o d u l e :
#
# : :
#
# B L A _ S T A T I C i f s e t o n t h i s d e t e r m i n e s w h a t k i n d o f l i n k a g e w e do ( static )
# B L A _ V E N D O R i f s e t c h e c k s o n l y t h e s p e c i f i e d v e n d o r , i f n o t s e t c h e c k s
# a l l t h e p o s s i b i l i t i e s
# B L A _ F 9 5 i f s e t o n t r i e s t o f i n d t h e f 9 5 i n t e r f a c e s f o r B L A S / L A P A C K
# B L A _ P R E F E R _ P K G C O N F I G i f s e t p k g - c o n f i g w i l l b e u s e d t o s e a r c h f o r a B L A S
# l i b r a r y f i r s t a n d i f o n e i s f o u n d t h a t i s p r e f e r r e d
#
# L i s t o f vendors ( BLA_VENDOR ) v a l i d i n t h i s m o d u l e :
#
@ -79,6 +86,18 @@ if( NOT (CMAKE_C_COMPILER_LOADED OR CMAKE_CXX_COMPILER_LOADED OR CMAKE_Fortran_C
endif ( )
endif ( )
if ( BLA_PREFER_PKGCONFIG )
find_package ( PkgConfig )
pkg_check_modules ( PKGC_BLAS IMPORTED_TARGET blas )
if ( PKGC_BLAS_FOUND )
set ( BLAS_LIBRARIES PkgConfig::PKGC_BLAS )
find_package_handle_standard_args ( BLAS
R E Q U I R E D _ V A R S B L A S _ L I B R A R I E S
V E R S I O N _ V A R P K G C _ B L A S _ V E R S I O N )
return ( )
endif ( )
endif ( )
macro ( Check_Fortran_Libraries LIBRARIES _prefix _name _flags _list _thread )
# T h i s m a c r o c h e c k s f o r t h e e x i s t e n c e o f t h e c o m b i n a t i o n o f f o r t r a n l i b r a r i e s
# g i v e n b y _ l i s t . I f t h e c o m b i n a t i o n i s f o u n d , t h i s m a c r o checks ( using the