Commit f5d345c4 authored by Tomáš Oberhuber's avatar Tomáš Oberhuber

Fixed linking of libcudadevrt.

parent 3897ad06
if( BUILD_CUDA )
cuda_add_executable( tnl-benchmark-blas tnl-benchmark-blas.cu )
cuda_add_cublas_to_target( tnl-benchmark-blas )
target_link_libraries( tnl-benchmark-blas ${CUDA_TOOLKIT_ROOT_DIR}/lib64/libcudadevrt.a )
#find_library( CUDADEVRT NAMES cudadevrt )
cuda_add_executable( tnl-benchmark-blas tnl-benchmark-blas.cu )
cuda_add_cublas_to_target( tnl-benchmark-blas )
#target_link_libraries( tnl-benchmark-blas ${CUDADEVRT} )#${CUDA_TOOLKIT_ROOT_DIR}/lib64/libcudadevrt.a )
else()
add_executable( tnl-benchmark-blas tnl-benchmark-blas.cpp )
endif()
......
if( BUILD_CUDA )
CUDA_ADD_EXECUTABLE( tnl-benchmark-spmv tnl-benchmark-spmv.cu )
TARGET_LINK_LIBRARIES( tnl-benchmark-spmv ${CUDA_cusparse_LIBRARY} ${CUDA_TOOLKIT_ROOT_DIR}/lib64/libcudadevrt.a )
TARGET_LINK_LIBRARIES( tnl-benchmark-spmv ${CUDA_cusparse_LIBRARY} -lcudadevrt )
else()
ADD_EXECUTABLE( tnl-benchmark-spmv tnl-benchmark-spmv.cpp )
endif()
......
......@@ -15,7 +15,7 @@ IF( BUILD_CUDA )
TARGET_LINK_LIBRARIES( Legacy_SparseMatrixTest_ChunkedEllpack ${GTEST_BOTH_LIBRARIES} )
CUDA_ADD_EXECUTABLE( Legacy_SparseMatrixTest_CSR SparseMatrixTest_CSR.cu OPTIONS ${CXX_TESTS_FLAGS} )
TARGET_LINK_LIBRARIES( Legacy_SparseMatrixTest_CSR ${GTEST_BOTH_LIBRARIES} ${CUDA_TOOLKIT_ROOT_DIR}/lib64/libcudadevrt.a )
TARGET_LINK_LIBRARIES( Legacy_SparseMatrixTest_CSR ${GTEST_BOTH_LIBRARIES} -lcudadevrt )
CUDA_ADD_EXECUTABLE( Legacy_SparseMatrixTest_Ellpack SparseMatrixTest_Ellpack.cu OPTIONS ${CXX_TESTS_FLAGS} )
TARGET_LINK_LIBRARIES( Legacy_SparseMatrixTest_Ellpack ${GTEST_BOTH_LIBRARIES} )
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment