Ask Your Question
0

My own library wont include

asked 2016-11-22 05:54:27 -0600

neobonde gravatar image

updated 2016-11-22 06:40:37 -0600

I have made my own library, and i want to include it in an other package, but i keep running in to this problem:

CMake Warning at /opt/ros/indigo/share/catkin/cmake/catkinConfig.cmake:76 (find_package):
  Could not find a package configuration file provided by "lib_polygon" with
  any of the following names:

    lib_polygonConfig.cmake
    lib_polygon-config.cmake

  Add the installation prefix of "lib_polygon" to CMAKE_PREFIX_PATH or set
  "lib_polygon_DIR" to a directory containing one of the above files.  If
  "lib_polygon" provides a separate development package or SDK, be sure it
  has been installed.
Call Stack (most recent call first):
  ci-rss-golfpicker/ci-ros-common/ci_executors/path_recorder/CMakeLists.txt:7 (find_package)


-- Could not find the required component 'lib_polygon'. The following CMake error indicates that you either need to install the package with the same name or change your environment so that it can be found.
CMake Error at /opt/ros/indigo/share/catkin/cmake/catkinConfig.cmake:83 (find_package):
  Could not find a package configuration file provided by "lib_polygon" with
  any of the following names:

    lib_polygonConfig.cmake
    lib_polygon-config.cmake

  Add the installation prefix of "lib_polygon" to CMAKE_PREFIX_PATH or set
  "lib_polygon_DIR" to a directory containing one of the above files.  If
  "lib_polygon" provides a separate development package or SDK, be sure it
  has been installed.
Call Stack (most recent call first):
  ci-rss-golfpicker/ci-ros-common/ci_executors/path_recorder/CMakeLists.txt:7 (find_package)


-- Configuring incomplete, errors occurred!
See also "/home/bonde/catkin_ws/golfpicker/build/CMakeFiles/CMakeOutput.log".
See also "/home/bonde/catkin_ws/golfpicker/build/CMakeFiles/CMakeError.log".
make: *** [cmake_check_build_system] Error 1

My library cmake file:

    cmake_minimum_required(VERSION 2.8.3)
project(lib_polygon)

## Find catkin macros and libraries
## if COMPONENTS list like find_package(catkin REQUIRED COMPONENTS xyz)
## is used, also find other catkin packages
find_package(catkin REQUIRED COMPONENTS
  roscpp
  ci_msgs
  msgs
)

## System dependencies are found with CMake's conventions
# find_package(Boost REQUIRED COMPONENTS system)


## Uncomment this if the package has a setup.py. This macro ensures
## modules and global scripts declared therein get installed
## See http://ros.org/doc/api/catkin/html/user_guide/setup_dot_py.html
# catkin_python_setup()

################################################
## Declare ROS messages, services and actions ##
################################################

## To declare and build messages, services or actions from within this
## package, follow these steps:
## * Let MSG_DEP_SET be the set of packages whose message types you use in
##   your messages/services/actions (e.g. std_msgs, actionlib_msgs, ...).
## * In the file package.xml:
##   * add a build_depend tag for "message_generation"
##   * add a build_depend and a run_depend tag for each package in MSG_DEP_SET
##   * If MSG_DEP_SET isn't empty the following dependency has been pulled in
##     but can be declared for certainty nonetheless:
##     * add a run_depend tag for "message_runtime"
## * In this file (CMakeLists.txt):
##   * add "message_generation" and every package in MSG_DEP_SET to
##     find_package(catkin REQUIRED COMPONENTS ...)
##   * add "message_runtime" and every package in MSG_DEP_SET to
##     catkin_package(CATKIN_DEPENDS ...)
##   * uncomment the add_*_files sections below as needed
##     and list every .msg/.srv/.action file to be processed
##   * uncomment the generate_messages entry below
##   * add every package in MSG_DEP_SET to generate_messages(DEPENDENCIES ...)

## Generate messages in the 'msg' folder
# add_message_files(
#   FILES
#   Message1.msg
#   Message2.msg
# )

## Generate services in the 'srv' folder ...
(more)
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
0

answered 2016-11-22 06:26:58 -0600

gvdhoorn gravatar image
find_package(catkin REQUIRED COMPONENTS
  [..]
  lib_polygon
  [..]
)

Your "library package" is called ci_can_lib, but your path_recorder package searches for lib_polygon?

If there is no lib_polygon, then Catkin (really: CMake) will emit those errors.

edit flag offensive delete link more
0

answered 2016-11-22 06:23:15 -0600

mgruhler gravatar image

Well, the error output is pretty clear. You are looking for a library called lib_polygon in your pathrecorder, but this cannot be find_package'd.

Either is is not installed, not in your path, not built or not configured correctly.

Without more details I cannot help you more. What is this lib_polygon, how did you install it, is it a ROS package, something else, ....?

edit flag offensive delete link more

Comments

It is a rospackage but it uses no ros specific things. it is this: http://geomalgorithms.com/a09-_avl_co...

neobonde gravatar imageneobonde ( 2016-11-22 06:41:21 -0600 )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-11-22 05:54:27 -0600

Seen: 76 times

Last updated: Nov 22 '16