moriarty / ros-ev3

How to install ROS (ros_comm) on an ev3 with ev3dev
GNU General Public License v2.0
24 stars 19 forks source link

is CMakeLists patch necessary? #17

Open MadsFox opened 7 years ago

MadsFox commented 7 years ago

I was wondering if the CMakeLists patch is necessary and what the reason is to make that patch?

I just tried to do this:

GET AND RUN DOCKER IMAGE $ docker pull ev3dev/debian-stretch-armel-cross $ docker tag ev3dev/debian-stretch-armel-cross ev3-stretch $ docker run --rm -it -v /mnt/catkin_ws/:/home/compiler/catkin_ws -w /home/compiler/catkin_ws ev3-stretch

INSTALL ROS_CORE $ sudo apt-get update $ sudo apt-get install build-essential $ sudo apt-get update $ sudo apt-get install ros-core-dev $ sudo apt-get update

INSTALL EV3 CPP LIB $ cd / $ sudo git clone https://github.com/ddemidov/ev3dev-lang-cpp $ cd ev3dev-lang-cpp $ sudo mkdir build $ cd build $ sudo cmake .. -DEV3DEV_PLATFORM=EV3 $ sudo make $ sudo make install

INSTALL EV3DEV_ROS_DEMO $ cd /home/compiler $ sudo mkdir -r catkin_ws/src $ cd catkin_ws $ catkin_make $ cd src $ sudo git clone https://github.com/moriarty/ev3dev_ros_demo.git $ cd .. $ sudo catkin_make

Haven't tested it on the EV3 brick, but the only sign that something would be wrong is a "CMake Warning" when running the last sudo catkin_make: CMake Warning at /usr/share/catkin/cmake/catkin_package.cmake:166 (message): catkin_package() DEPENDS on 'ev3dev' but neither 'ev3dev_INCLUDE_DIRS' nor 'ev3dev_LIBRARIES' is defined. Call Stack (most recent call first): /usr/share/catkin/cmake/catkin_package.cmake:102 (_catkin_package) ev3dev_ros_demo/CMakeLists.txt:21 (catkin_package)

Is the patch to fix this last warning? and can't that be fixed by referencing the ev3dev library to the local folder in the package CMakeLists file?

moriarty commented 6 years ago

Sorry for the delay, it might not be needed anymore. I haven't had time to check it against the latest ev3dev-lang-cpp.