1 2find_package(ATLAS) 3if (ATLAS_FOUND) 4 btl_add_bench(btl_atlas main.cpp) 5 if(BUILD_btl_atlas) 6 target_link_libraries(btl_atlas ${ATLAS_LIBRARIES}) 7 set_target_properties(btl_atlas PROPERTIES COMPILE_FLAGS "-DCBLASNAME=ATLAS -DHAS_LAPACK=1") 8 endif(BUILD_btl_atlas) 9endif (ATLAS_FOUND) 10 11find_package(MKL) 12if (MKL_FOUND) 13 btl_add_bench(btl_mkl main.cpp) 14 if(BUILD_btl_mkl) 15 target_link_libraries(btl_mkl ${MKL_LIBRARIES}) 16 set_target_properties(btl_mkl PROPERTIES COMPILE_FLAGS "-DCBLASNAME=INTEL_MKL -DHAS_LAPACK=1") 17 endif(BUILD_btl_mkl) 18endif (MKL_FOUND) 19 20 21find_package(GOTO2) 22if (GOTO2_FOUND) 23 btl_add_bench(btl_goto2 main.cpp) 24 if(BUILD_btl_goto2) 25 target_link_libraries(btl_goto2 ${GOTO_LIBRARIES} ) 26 set_target_properties(btl_goto2 PROPERTIES COMPILE_FLAGS "-DCBLASNAME=GOTO2") 27 endif(BUILD_btl_goto2) 28endif (GOTO2_FOUND) 29 30find_package(GOTO) 31if (GOTO_FOUND) 32 if(GOTO2_FOUND) 33 btl_add_bench(btl_goto main.cpp OFF) 34 else() 35 btl_add_bench(btl_goto main.cpp) 36 endif() 37 if(BUILD_btl_goto) 38 target_link_libraries(btl_goto ${GOTO_LIBRARIES} ) 39 set_target_properties(btl_goto PROPERTIES COMPILE_FLAGS "-DCBLASNAME=GOTO") 40 endif(BUILD_btl_goto) 41endif (GOTO_FOUND) 42 43find_package(ACML) 44if (ACML_FOUND) 45 btl_add_bench(btl_acml main.cpp) 46 if(BUILD_btl_acml) 47 target_link_libraries(btl_acml ${ACML_LIBRARIES} ) 48 set_target_properties(btl_acml PROPERTIES COMPILE_FLAGS "-DCBLASNAME=ACML -DHAS_LAPACK=1") 49 endif(BUILD_btl_acml) 50endif (ACML_FOUND) 51 52if(Eigen_SOURCE_DIR AND CMAKE_Fortran_COMPILER_WORKS) 53 # we are inside Eigen and blas/lapack interface is compilable 54 include_directories(${Eigen_SOURCE_DIR}) 55 btl_add_bench(btl_eigenblas main.cpp) 56 if(BUILD_btl_eigenblas) 57 target_link_libraries(btl_eigenblas eigen_blas eigen_lapack ) 58 set_target_properties(btl_eigenblas PROPERTIES COMPILE_FLAGS "-DCBLASNAME=EigenBLAS") 59 endif() 60endif() 61