PRBonn / depth_clustering

:taxi: Fast and robust clustering of point clouds generated with a Velodyne sensor.
MIT License
1.2k stars 378 forks source link

Errors during compiling #10

Closed RabahZeroukhi closed 7 years ago

RabahZeroukhi commented 7 years ago

Hello, I tried to compile the package using the tool catkin_make in workspace path and I had these errors

error

any help will be appreciated

niosus commented 7 years ago

Please install catkin_tools:

supo pip install catkin_tools

and run catkin build instead of catkin_make. It will probably produce either a proper build or a better error. Also, make sure that you have eigen3 library installed.

RabahZeroukhi commented 7 years ago

thanks for reply, I want to build using cmake .. and make -j4, it was configured well after editing Cmakelist.txt removing "find_package(eigen3 required)" and adding "find_package(PkgConfig) pkg_search_module(Eigen3 REQUIRED eigen3)", because i had the problem which you mentioned (eigen 3 lib) cmake and then when i run " make -j4" it didn't compile the whole package make-j4

for you information, i have ubuntu 14.04 as OS and ROS indigo. thanks again.

niosus commented 7 years ago

It looks like smth is wrong with your system. eigen3 should be found on a system with ROS indigo out of the box using find_package(Eigen3 REQUIRED) (make sure to spell Eigen3 exactly like here).

To check this, I have just spawned a new docker image with image: ros:indigo-perception and after following the installation steps everything builds as expected using cmake and make. You can also do it yourself if you have docker running on your system. Here are all commands:

Run the docker container:

sudo docker run -it ros:indigo-perception bash

Now from this container install the libraries missing out of the box:

apt update
apt install -y libqglviewer-dev freeglut3-dev

Now with libraries installed, clone and build the code:

mkdir -p catkin_ws/src && cd catkin_ws/src
git clone https://github.com/Photogrammetry-Robotics-Bonn/depth_clustering.git
cd depth_clustering && mkdir build && cd build
cmake ..
make -j4

This builds the code for me with no issues and proves that the code builds on a clean system. Therefore, I feel that there is smth strange going on on your side. I can't really tell you more, I guess...

RabahZeroukhi commented 7 years ago

Yes it works, thanks very much.

LiShuaixin commented 5 years ago

HI @niosus I still meet the error while I use catkin build instead of catkin_make. default

any help will be appreciated!

LiShuaixin commented 5 years ago

HI @niosus I still meet the error while I use catkin build instead of catkin_make. default

any help will be appreciated!

It can be solved by adding FIND_PACKAGE(GTest) and commenting ADD_SUBDIRECTORY(/usr/src/gtest/ gtest)

anyone could refer to Stack Overflow to find the principle behind of this case.

tornadomeet commented 5 years ago

@LiShuaixin still the same error after doing

It can be solved by adding
FIND_PACKAGE(GTest)
and commenting
ADD_SUBDIRECTORY(/usr/src/gtest/ gtest)