-
Notifications
You must be signed in to change notification settings - Fork 355
/
CMakeLists.txt
46 lines (33 loc) · 1.29 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved.
#
# NVIDIA CORPORATION and its licensors retain all intellectual property
# and proprietary rights in and to this software, related documentation
# and any modifications thereto. Any use, reproduction, disclosure or
# distribution of this software and related documentation without an express
# license agreement from NVIDIA CORPORATION is strictly prohibited.
#
cmake_minimum_required(VERSION 3.13 FATAL_ERROR)
project(nvJPEGROIDecode LANGUAGES CXX CUDA)
# ---[ Project specIFication.
SET(PROJECT_NAME nvJPEGROIDecode)
PROJECT(${PROJECT_NAME} LANGUAGES CUDA CXX)
if(NOT DEFINED CMAKE_CUDA_STANDARD)
set(CMAKE_CUDA_STANDARD 11)
set(CMAKE_CUDA_STANDARD_REQUIRED ON)
endif()
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)
include_directories(
SYSTEM ${CMAKE_CUDA_TOOLKIT_INCLUDE_DIRECTORIES}
)
SET(EXAMPLES_DESCRIPTOR_SOURCES "nvJPEGROIDecode.cpp")
add_executable(nvJPEGROIDecode ${EXAMPLES_DESCRIPTOR_SOURCES})
find_library(NVJPEG_LIB
NAMES nvjpeg
PATHS ${CMAKE_CUDA_IMPLICIT_LINK_DIRECTORIES})
find_library(CUDART_LIB
NAMES cudart
PATHS ${CMAKE_CUDA_IMPLICIT_LINK_DIRECTORIES})
target_link_libraries(nvJPEGROIDecode PUBLIC ${NVJPEG_LIB} ${CUDART_LIB} pthread)