Converted lapack/Makefile to cmake.
This commit is contained in:
parent
2828f6630c
commit
373a1bdadb
|
@ -32,7 +32,7 @@ if (DEFINED SANITY_CHECK)
|
|||
endif ()
|
||||
|
||||
set(SUBDIRS ${BLASDIRS})
|
||||
if (NOT ${NO_LAPACK})
|
||||
if (NOT NO_LAPACK)
|
||||
list(APPEND SUBDIRS lapack)
|
||||
endif ()
|
||||
|
||||
|
@ -55,8 +55,8 @@ if (${NO_STATIC} AND ${NO_SHARED})
|
|||
endif ()
|
||||
|
||||
set(DBLAS_OBJS "")
|
||||
foreach (BLAS_DIR ${BLASDIRS})
|
||||
add_subdirectory(${BLAS_DIR})
|
||||
foreach (SUBDIR ${SUBDIRS})
|
||||
add_subdirectory(${SUBDIR})
|
||||
endforeach ()
|
||||
|
||||
# get obj vars into format that add_library likes: $<TARGET_OBJS:objlib> (see http://www.cmake.org/cmake/help/v3.0/command/add_library.html)
|
||||
|
|
|
@ -0,0 +1,83 @@
|
|||
|
||||
include_directories(${CMAKE_SOURCE_DIR})
|
||||
|
||||
# TODO: laswp needs arch specific code
|
||||
# TODO: getrs needs to be compiled with and without TRANS (and up to TRANS=4 in the complex case)
|
||||
# TODO: trti2 needs to be compiled with and without UNIT
|
||||
# TODO: trtri needs to be compiled with and without UNIT
|
||||
|
||||
set(LAPACK_SOURCES
|
||||
getf2/getf2_k.c
|
||||
getrf/getrf_single.c
|
||||
getrs/getrs_single.c
|
||||
potrf/potrf_U_single.c
|
||||
potrf/potrf_L_single.c
|
||||
potf2/potf2_U.c
|
||||
potf2/potf2_L.c
|
||||
lauu2/lauu2_U.c
|
||||
lauu2/lauu2_L.c
|
||||
lauum/lauum_U_single.c
|
||||
lauum/lauum_L_single.c
|
||||
trti2/trti2_U.c
|
||||
trti2/trti2_L.c
|
||||
trtri/trtri_U_single.c
|
||||
trtri/trtri_L_single.c
|
||||
)
|
||||
|
||||
set(ZLAPACK_SOURCES
|
||||
getf2/zgetf2_k.c
|
||||
getrf/getrf_single.c
|
||||
getrs/zgetrs_single.c
|
||||
potrf/potrf_U_single.c
|
||||
potrf/potrf_L_single.c
|
||||
potf2/potf2_U.c
|
||||
potf2/potf2_L.c
|
||||
lauu2/zlauu2_U.c
|
||||
lauu2/zlauu2_L.c
|
||||
lauum/lauum_U_single.c
|
||||
lauum/lauum_L_single.c
|
||||
trti2/ztrti2_U.c
|
||||
trti2/ztrti2_L.c
|
||||
trtri/trtri_U_single.c
|
||||
trtri/trtri_L_single.c
|
||||
)
|
||||
|
||||
GenerateNamedObjects("${LAPACK_SOURCES}" "DOUBLE" "" "" 0)
|
||||
list(APPEND DBLAS_OBJS ${OBJ_LIST_OUT})
|
||||
|
||||
if (SMP)
|
||||
|
||||
if (USE_OPENMP)
|
||||
set(GETRF_SRC getrf/getrf_parallel_omp.c)
|
||||
else ()
|
||||
set(GETRF_SRC getrf/getrf_parallel.c)
|
||||
endif ()
|
||||
|
||||
set(PARALLEL_SOURCES
|
||||
${GETRF_SRC}
|
||||
getrs/getrs_parallel.c
|
||||
potrf/potrf_U_parallel.c
|
||||
potrf/potrf_L_parallel.c
|
||||
lauum/lauum_U_parallel.c
|
||||
lauum/lauum_L_parallel.c
|
||||
trtri/trtri_U_parallel.c
|
||||
trtri/trtri_L_parallel.c
|
||||
)
|
||||
|
||||
set(ZPARALLEL_SOURCES
|
||||
${GETRF_SRC}
|
||||
getrs/zgetrs_parallel.c
|
||||
potrf/potrf_U_parallel.c
|
||||
potrf/potrf_L_parallel.c
|
||||
lauum/lauum_U_parallel.c
|
||||
lauum/lauum_L_parallel.c
|
||||
trtri/trtri_U_parallel.c
|
||||
trtri/trtri_L_parallel.c
|
||||
)
|
||||
|
||||
GenerateNamedObjects("${PARALLEL_SOURCES}" "DOUBLE" "" "" 0)
|
||||
list(APPEND DBLAS_OBJS ${OBJ_LIST_OUT})
|
||||
endif ()
|
||||
|
||||
set(DBLAS_OBJS ${DBLAS_OBJS} PARENT_SCOPE) # list append removes the scope from DBLAS_OBJS
|
||||
|
Loading…
Reference in New Issue