Description
Error linking TensortRT…
I am following the sample SSD example provided on GitHub and during build the tensorRT libraries do not link. I tried to add the following line to cmake - target_link_libraries(Project PUBLIC /usr/lib/libnvinfer.so)
and the new error during compilation is - No Rule to make target /usr/lib/libnvinfer.so needed by Project
My Cmake file is as follows -
cmake_minimum_required(VERSION 3.17)
project(Project)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_PREFIX_PATH "/usr/local/cuda/")
find_package(OpenCV REQUIRED)
find_package(realsense2 REQUIRED)
find_package(dlib REQUIRED)
find_package(CUDA REQUIRED)
include_directories(${OpenCV_INCLUDE_DIRS})
include_directories(${CUDA_INCLUDE_DIRS})
add_executable(Project main.cpp tracker.cpp tracker.h SSD.cpp SSD.h argsParser.h BatchStream.h buffers.h common.h
EntropyCalibrator.h logger.cpp logging.h half.h)
target_link_libraries(Project PUBLIC ${OpenCV_LIBS})
target_link_libraries(Project PUBLIC dlib::dlib)
target_link_librarie(Project PUBLIC realsense2::realsense2 realsense2::realsense-file)
target_link_libraries(Project PUBLIC ${CUDA_LIBS})
target_link_libraries(Project PUBLIC -fopenmp -fopenmp-simd)
target_link_libraries(Project PUBLIC /usr/lib/libnvinfer.so)
Environment
TensorRT Version: - 7.1.3
GPU Type: - RTX 2070
Nvidia Driver Version: 440.100
CUDA Version: 10.2
CUDNN Version: 8.0.2
Operating System + Version: Ubuntu 20.04 LTS
Python Version (if applicable): 3.8
TensorFlow Version (if applicable):
PyTorch Version (if applicable):
Baremetal or Container (if container which image + tag):
Steps To Reproduce
I am following the sampleSSD example in tensorRT examples. My TensortRT .h and .cpp are in /usr/include and .so files are in /usr/lib.
I used the .deb file to install the library.