Ask Your Question
0

ROS Can't find my executable - install_isolated

asked 2016-04-25 06:29:43 -0500

Tardoe gravatar image

updated 2016-04-25 18:27:22 -0500

Dirk Thomas gravatar image

Running ROS Indigo on Raspbian I run "catkin_make_isolated --install" and I cannot seem to run my C++ node with:

pi@rospi:~/ros_catkin_ws $ rosrun eyebot_testing eybot_testing_node
[rosrun] Couldn't find executable named eybot_testing_node below /home/pi/ros_catkin_ws/install_isolated/share/eyebot_testing

This is my CMakeLists.txt file that compiles just fine.

cmake_minimum_required(VERSION 2.8.3)
project(eyebot_testing)

find_package(catkin REQUIRED COMPONENTS
  roscpp
  rospy
  std_msgs
)

catkin_package(
  INCLUDE_DIRS include
)

include_directories(include
  ${catkin_INCLUDE_DIRS}
  /home/pi/eyebot/include
)

add_executable(eyebot_testing_node src/eyebot_testing_node.cpp)

find_library(eyebot_testing_node /home/pi/eyebot/lib)
target_link_libraries(eyebot_testing_node
   ${catkin_LIBRARIES}
   wiringPi
   mpsse
   X11
   lirc_client
   m
   opencv_core
   opencv_highgui
   opencv_imgproc
   eyebot
 )

My source statements are also correct, these are the two lines in my .basrc file:

source /opt/ros/indigo/setup.bash
source /home/pi/ros_catkin_ws/install_isolated/setup.bash

Upon attempting to locate my binary (as the compilation and linking was successful), I can only find them in /home/pi/ros_catkin_ws/devel_isolated/eyebot_testing/lib/eyebot_testing/eyebot_testing_node

If I attempt to source from there using the devel setup.bash script it won't find the package at all.

Ideas?

Update:

I added this for installation and it didn't change where the binary ended up, same result.

## Mark executables and/or libraries for installation
 install(TARGETS eyebot_testing_node
   ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
   LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
   RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)

## Mark cpp header files for installation
 install(DIRECTORY include/${PROJECT_NAME}/
   DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION}
   FILES_MATCHING PATTERN "*.h"
#   PATTERN ".svn" EXCLUDE
)
edit retag flag offensive close merge delete

Comments

1

You don not seem to have install targets in your CMakeLists which is why it won't put anything in the install dir.

Chrissi gravatar image Chrissi  ( 2016-04-25 09:56:14 -0500 )edit

I added the installation target info as below and it didn't help - care to point me in the right direction?

Tardoe gravatar image Tardoe  ( 2016-04-25 18:10:33 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2016-04-25 18:30:00 -0500

Dirk Thomas gravatar image

In the posted CMake code you reuse the variable name eyebot_testing_node. After creating the executable target you are overwriting it with the find_library call (which I don't know why you are calling this function in the first place).

edit flag offensive delete link more

Comments

Ah that seems to have fixed it. I added the find_library() call to locate my libeyebot.a library file but simply commenting out that line appears to have worked.

Tardoe gravatar image Tardoe  ( 2016-04-25 20:57:51 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2016-04-25 06:29:43 -0500

Seen: 560 times

Last updated: Apr 25 '16