mirror of
https://github.com/NVIDIA/cuda-samples.git
synced 2026-10-25 22:28:17 +08:00
Changes for building for aarch64, specifically jetson orin nano
This commit is contained in:
@@ -14,17 +14,21 @@ endif()
|
||||
# Include directories and libraries
|
||||
include_directories(../../../Common)
|
||||
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||
# Source file
|
||||
# Add target for systemWideAtomics
|
||||
add_executable(systemWideAtomics systemWideAtomics.cu)
|
||||
|
||||
target_compile_options(systemWideAtomics PRIVATE $<$<COMPILE_LANGUAGE:CUDA>:--extended-lambda>)
|
||||
|
||||
target_compile_features(systemWideAtomics PRIVATE cxx_std_17 cuda_std_17)
|
||||
|
||||
set_target_properties(systemWideAtomics PROPERTIES CUDA_SEPARABLE_COMPILATION ON)
|
||||
|
||||
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
|
||||
message(STATUS "Will not build sample systemWideAtomics - not supported on aarch64")
|
||||
else()
|
||||
message(STATUS "Will not build sample systemWideAtomics - requires Linux OS")
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||
# Source file
|
||||
# Add target for systemWideAtomics
|
||||
add_executable(systemWideAtomics systemWideAtomics.cu)
|
||||
|
||||
target_compile_options(systemWideAtomics PRIVATE $<$<COMPILE_LANGUAGE:CUDA>:--extended-lambda>)
|
||||
|
||||
target_compile_features(systemWideAtomics PRIVATE cxx_std_17 cuda_std_17)
|
||||
|
||||
set_target_properties(systemWideAtomics PROPERTIES CUDA_SEPARABLE_COMPILATION ON)
|
||||
|
||||
else()
|
||||
message(STATUS "Will not build sample systemWideAtomics - requires Linux OS")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user