Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

catkin build error #15

Open
doublestrong opened this issue Jun 17, 2020 · 2 comments
Open

catkin build error #15

doublestrong opened this issue Jun 17, 2020 · 2 comments

Comments

@doublestrong
Copy link

Hi, I encounter an error when building it. I have class_loader package in /opt/ros/melodic/share/class_loader. The error message is shown as follows. I am trying to build it with the github version of class_loader but am struggling on modifying the CMakelist. Any idea to solve this issue?

chad@chad-Oryx-Pro:~/vnav_ws$ catkin build rviz_textured_quads 
--------------------------------------------------------------------------------------------------------------------------------------------------------
Profile:                     default
Extending:          [cached] /home/chad/Research/racecar-ws/devel:/home/chad/Research/math_ws/devel:/home/chad/Research/catkin_ws/devel:/opt/ros/melodic
Workspace:                   /home/chad/vnav_ws
--------------------------------------------------------------------------------------------------------------------------------------------------------
Build Space:        [exists] /home/chad/vnav_ws/build
Devel Space:        [exists] /home/chad/vnav_ws/devel
Install Space:      [unused] /home/chad/vnav_ws/install
Log Space:          [exists] /home/chad/vnav_ws/logs
Source Space:       [exists] /home/chad/vnav_ws/src
DESTDIR:            [unused] None
--------------------------------------------------------------------------------------------------------------------------------------------------------
Devel Space Layout:          linked
Install Space Layout:        None
--------------------------------------------------------------------------------------------------------------------------------------------------------
Additional CMake Args:       -DCMAKE_BUILD_TYPE=Debug
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
Cache Job Environments:      False
--------------------------------------------------------------------------------------------------------------------------------------------------------
Whitelisted Packages:        None
Blacklisted Packages:        None
--------------------------------------------------------------------------------------------------------------------------------------------------------


--------------------------------------------------------------------------------------------------------------------------------------------------------
WARNING: Your current environment's CMAKE_PREFIX_PATH is different from the cached CMAKE_PREFIX_PATH used the last time this workspace was built.

If you want to use a different CMAKE_PREFIX_PATH you should call `catkin clean` to remove all references to the previous CMAKE_PREFIX_PATH.

Cached CMAKE_PREFIX_PATH:
	/home/chad/Research/racecar-ws/devel:/home/chad/Research/math_ws/devel:/home/chad/Research/catkin_ws/devel:/opt/ros/melodic
Current CMAKE_PREFIX_PATH:
	/opt/ros/melodic
--------------------------------------------------------------------------------------------------------------------------------------------------------

[build] Found '57' packages in 0.0 seconds.                                                                                                                                   
[build] Package table is up to date.                                                                                                                                          
Starting  >>> class_loader                                                                                                                                                    
Finished  <<< class_loader                       [ 0.2 seconds ]                                                                                                              
Starting  >>> rviz_textured_quads                                                                                                                                             
______________________________________________________________________________________________________________________________________________________________________________
Errors     << rviz_textured_quads:cmake /home/chad/vnav_ws/logs/rviz_textured_quads/build.cmake.018.log                                                                       
CMake Warning (dev) at /usr/src/googletest/CMakeLists.txt:3 (project):
  Policy CMP0048 is not set: project() command manages VERSION variables.
  Run "cmake --help-policy CMP0048" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.

  The following variable(s) would be set to empty:

    PROJECT_VERSION
    PROJECT_VERSION_MAJOR
    PROJECT_VERSION_MINOR
    PROJECT_VERSION_PATCH
This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Warning (dev) at /usr/src/googletest/googlemock/CMakeLists.txt:40 (project):
  Policy CMP0048 is not set: project() command manages VERSION variables.
  Run "cmake --help-policy CMP0048" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.

  The following variable(s) would be set to empty:

    PROJECT_VERSION
    PROJECT_VERSION_MAJOR
    PROJECT_VERSION_MINOR
    PROJECT_VERSION_PATCH
This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Warning (dev) at /usr/src/googletest/googletest/CMakeLists.txt:47 (project):
  Policy CMP0048 is not set: project() command manages VERSION variables.
  Run "cmake --help-policy CMP0048" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.

  The following variable(s) would be set to empty:

    PROJECT_VERSION
    PROJECT_VERSION_MAJOR
    PROJECT_VERSION_MINOR
    PROJECT_VERSION_PATCH
This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Error at /opt/ros/melodic/share/class_loader/cmake/class_loaderConfig.cmake:173 (message):
  Project 'rviz_textured_quads' tried to find library 'dl'.  The library is
  neither a target nor built/installed properly.  Did you compile project
  'class_loader'? Did you find_package() it before the subdirectory
  containing its code is included?
Call Stack (most recent call first):
  /opt/ros/melodic/share/pluginlib/cmake/pluginlibConfig.cmake:197 (find_package)
  /opt/ros/melodic/share/catkin/cmake/catkinConfig.cmake:76 (find_package)
  CMakeLists.txt:6 (find_package)


cd /home/chad/vnav_ws/build/rviz_textured_quads; catkin build --get-env rviz_textured_quads | catkin env -si  /usr/bin/cmake /home/chad/vnav_ws/src/rviz_textured_quads --no-warn-unused-cli -DCATKIN_DEVEL_PREFIX=/home/chad/vnav_ws/devel/.private/rviz_textured_quads -DCMAKE_INSTALL_PREFIX=/home/chad/vnav_ws/install -DCMAKE_BUILD_TYPE=Debug; cd -
..............................................................................................................................................................................
Failed     << rviz_textured_quads:cmake          [ Exited with code 1 ]                                                                                                       
Failed    <<< rviz_textured_quads                [ 0.6 seconds ]                                                                                                              
[build] Summary: 1 of 2 packages succeeded.                                                                                                                                   
[build]   Ignored:   55 packages were skipped or are blacklisted.                                                                                                             
[build]   Warnings:  None.                                                                                                                                                    
[build]   Abandoned: None.                                                                                                                                                    
[build]   Failed:    1 packages failed.                                                                                                                                       
[build] Runtime: 0.9 seconds total.
@lucasw
Copy link
Owner

lucasw commented Jun 25, 2020

I notice your workspace extension has a lot in it:

Extending:          [cached] /home/chad/Research/racecar-ws/devel:/home/chad/Research/math_ws/devel:/home/chad/Research/catkin_ws/devel:/opt/ros/melodic

Also this is a clue that your workspaces are possibly fouled up:

WARNING: Your current environment's CMAKE_PREFIX_PATH is different from the cached CMAKE_PREFIX_PATH used the last time this workspace was built.

You may want to try compiling in a simpler clean setup that only extends /opt/ros/melodic and add more workspaces from there.

The action files may provide some clues also, take a look at what this file https://github.com/lucasw/rviz_textured_quads/blob/image_topic/.github/workflows/ubuntu_18_04.yml does to build the package.

@lucasw
Copy link
Owner

lucasw commented Jun 25, 2020

Another thing is that maybe class_loader doesn't really belong in the dependencies at all (I could have left it in there when I forked this package originally), you could try removing it from package.xml and CMakeLists.txt.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants