Update to add Cuda to build system

This commit is contained in:
Alex Selimov 2025-04-15 14:10:01 -04:00
parent 8408036078
commit 68f8b02f0a
8 changed files with 120 additions and 17 deletions

18
kernels/CMakeLists.txt Normal file
View file

@ -0,0 +1,18 @@
project(${CMAKE_PROJECT_NAME}_cuda_lib CUDA CXX)
set(HEADER_FILES
hello_world.h
)
set(SOURCE_FILES
hello_world.cu
)
# The library contains header and source files.
add_library(${CMAKE_PROJECT_NAME}_cuda_lib STATIC
${SOURCE_FILES}
${HEADER_FILES}
)
if(CMAKE_COMPILER_IS_GNUCXX)
target_compile_options(${CMAKE_PROJECT_NAME}_cuda_lib PRIVATE -Wno-gnu-line-marker)
endif()