Merge pull request #17 from XSShawnZeng/master

Fix the nvsci lib finding issue for auto-linux and update sm list for Tegra samples
This commit is contained in:
Rob Armstrong 2025-02-06 08:28:21 -08:00 committed by GitHub
commit fd5674f9e5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
13 changed files with 81 additions and 45 deletions

View File

@ -22,12 +22,19 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
# Find the NVSCI libraries
# use CMAKE_LIBRARY_PATH so that users can also specify the NVSCI lib path in cmake command
set(CMAKE_LIBRARY_PATH "/usr/lib" ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscisync.so
)
foreach(LIBRARY_PATH ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${LIBRARY_PATH}/libnvscibuf.so
${LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${LIBRARY_PATH}/libnvscisync.so
${LIBRARY_PATH}/*/libnvscisync.so
)
if(NVSCIBUF_LIB AND NVSCISYNC_LIB)
break()
endif()
endforeach()
# Find the NVSCI header files
# use CMAKE_INCLUDE_PATH so that users can also specify the NVSCI include path in cmake command

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 50 52 60 61 70 75 80 86 89 90 100 101 120)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
# set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -G") # enable cuda-gdb (expensive)

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 53 61 70 72 75 80 86 87 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 53 61 70 72 75 80 86 87 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 53 61 70 72 75 80 86 87 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 53 61 70 72 75 80 86 87 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
@ -25,12 +25,19 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
# Find the NVSCI libraries
# use CMAKE_LIBRARY_PATH so that users can also specify the NVSCI lib path in cmake command
set(CMAKE_LIBRARY_PATH "/usr/lib" ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscisync.so
)
foreach(LIBRARY_PATH ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${LIBRARY_PATH}/libnvscibuf.so
${LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${LIBRARY_PATH}/libnvscisync.so
${LIBRARY_PATH}/*/libnvscisync.so
)
if(NVSCIBUF_LIB AND NVSCISYNC_LIB)
break()
endif()
endforeach()
# Find the NVSCI header files
# use CMAKE_INCLUDE_PATH so that users can also specify the NVSCI include path in cmake command

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 53 61 70 72 75 80 86 87 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
@ -25,12 +25,19 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
# Find the NVSCI libraries
# use CMAKE_LIBRARY_PATH so that users can also specify the NVSCI lib path in cmake command
set(CMAKE_LIBRARY_PATH "/usr/lib" ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscisync.so
)
foreach(LIBRARY_PATH ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${LIBRARY_PATH}/libnvscibuf.so
${LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${LIBRARY_PATH}/libnvscisync.so
${LIBRARY_PATH}/*/libnvscisync.so
)
if(NVSCIBUF_LIB AND NVSCISYNC_LIB)
break()
endif()
endforeach()
# Find the NVSCI header files
# use CMAKE_INCLUDE_PATH so that users can also specify the NVSCI include path in cmake command

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 53 61 70 72 75 80 86 87 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
@ -22,12 +22,19 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
# Find the NVSCI libraries
# use CMAKE_LIBRARY_PATH so that users can also specify the NVSCI lib path in cmake command
set(CMAKE_LIBRARY_PATH "/usr/lib" ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscisync.so
)
foreach(LIBRARY_PATH ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${LIBRARY_PATH}/libnvscibuf.so
${LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${LIBRARY_PATH}/libnvscisync.so
${LIBRARY_PATH}/*/libnvscisync.so
)
if(NVSCIBUF_LIB AND NVSCISYNC_LIB)
break()
endif()
endforeach()
# Find the NVSCI header files
# use CMAKE_INCLUDE_PATH so that users can also specify the NVSCI include path in cmake command

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 53 61 70 72 75 80 86 87 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
@ -22,15 +22,23 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
# Find the NVSCI/NVMEDIA libraries
# use CMAKE_LIBRARY_PATH so that users can also specify the NVSCI lib path in cmake command
set(CMAKE_LIBRARY_PATH "/usr/lib" ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${CMAKE_LIBRARY_PATH}/*/libnvscisync.so
)
file(GLOB_RECURSE NVMEDIA_LIB
${CMAKE_LIBRARY_PATH}/*/libnvmedia.so
)
foreach(LIBRARY_PATH ${CMAKE_LIBRARY_PATH})
file(GLOB_RECURSE NVSCIBUF_LIB
${LIBRARY_PATH}/libnvscibuf.so
${LIBRARY_PATH}/*/libnvscibuf.so
)
file(GLOB_RECURSE NVSCISYNC_LIB
${LIBRARY_PATH}/libnvscisync.so
${LIBRARY_PATH}/*/libnvscisync.so
)
file(GLOB_RECURSE NVMEDIA_LIB
${LIBRARY_PATH}/libnvmedia.so
${LIBRARY_PATH}/*/libnvmedia.so
)
if(NVSCIBUF_LIB AND NVSCISYNC_LIB AND NVMEDIA_LIB)
break()
endif()
endforeach()
# Find the NVSCI/NVMEDIA header files
# use CMAKE_INCLUDE_PATH so that users can also specify the NVSCI/NVMEDIA include path in cmake command

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 50 52 60 61 70 75 80 86 89 90 100 101 120)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
# set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -G") # enable cuda-gdb (expensive)

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 50 52 60 61 70 72 75 80 86 87 89 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 53 61 70 72 75 80 86 87 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")

View File

@ -8,7 +8,7 @@ find_package(CUDAToolkit REQUIRED)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_CUDA_ARCHITECTURES 53 61 70 72 75 80 86 87 90)
set(CMAKE_CUDA_ARCHITECTURES 72 87 101)
set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Wno-deprecated-gpu-targets")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")