pcl cuda cuda_runtime.h no such file or directory with ros

asked 2017-09-05 10:40:43 -0500

tobi93 gravatar image

Hello everybody.

I'm trying to use cuda in my pcl/ros application. I want to use the bodyparts_detector (pcl/gpu/people).

If I compile my project with the include:

#include <pcl/gpu/people/bodyparts_detector.h>

it throws everytime the error:

/usr/local/include/pcl-1.8/pcl/gpu/people/label_common.h:44:71: fatal error: cuda_runtime.h: No such file or directory
compilation terminated.

How can I solve this issue?

My CMakeLists.txt looks like this:

cmake_minimum_required(VERSION 2.8.3)
add_definitions(-std=c++11)
project(project)

find_package(catkin REQUIRED COMPONENTS
  cv_bridge
  cmake_modules
  image_transport
  pcl_conversions
  pcl_ros
  roscpp
  message_and_service
)
find_package(OpenCV REQUIRED)
find_package(PCL REQUIRED)
find_package(CUDA REQUIRED)

add_definitions(${PCL_DEFINITIONS})

#Searching CUDA
FIND_PACKAGE(CUDA)

#Include the FindCUDA script
INCLUDE(FindCUDA)


catkin_package(

)

add_executable(${PROJECT_NAME} src/main.cpp)


target_link_libraries(${PROJECT_NAME}
   ${catkin_LIBRARIES} ${OpenCV_LIBS} ${PCL_LIBS}
   ${PCL_LIBRARIES}
)

(This file is just a bit cleaned up now)

I hope someone can help me :)

Thank, Tobi

edit retag flag offensive close merge delete

Comments

I have similar problem, but I have another problem:

nvcc fatal : A single input file is required for a non-link phase when an outputfile is specified

CMake Error at XXXXX_generated_XXXXX.cu.o.cmake:207 (message):

So I want to ask you, how to pass compile?

lgLeo gravatar imagelgLeo ( 2018-01-31 09:10:37 -0500 )edit