manifest.xml to build own library [closed]

asked 2014-02-28 04:23:38 -0500

Barbara gravatar image

updated 2014-02-28 04:26:40 -0500

I could not find a post which answers my question. But in case there already exists one just close this.

I am new to ROS and I want to compile a library I have written for another application and needs to be for ROS now. When I compile my code I get an error and compilation is aborted. The compilation fails because there is no manifest.xml in my src folder. (At least I guess it is the reason.) Isn't package.xml enough? Do I need a second one? Do I need to change some things after I create a catkin package if I want to build a library? I mean from obvious things like my code etc.

Thnx

I have this in my CMakeList.txt

cmake_minimum_required(VERSION 2.8.3)
project(libusermediator)
find_package(catkin REQUIRED COMPONENTS roscpp rospy std_msgs genmsg)

catkin_package(
INCLUDE_DIRS header header/network
)

include_directories(include ${catkin_INCLUDE_DIRS})

include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake)
rosbuild_init()
rosbuild_add_library(usermediator src/ *.cpp src/network/ *.cpp)

(Just without the spaces before the *. it becomes a comment here)

If the error message helps:

Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/opt/ros/hydro/lib/python2.7/dist-packages/roslib/manifest.py", line 139, in parse_file
return roslib.manifestlib.parse_file(Manifest(), file)
File "/opt/ros/hydro/lib/python2.7/dist-packages/roslib/manifestlib.py", line 491, in parse_file
raise ValueError("Invalid/non-existent manifest file: %s"%file)
ValueError: Invalid/non-existent manifest file: manifest.xml
CMake Error at /opt/ros/hydro/share/ros/core/rosbuild/private.cmake:78 (message):
[rosbuild] Syntax check of src/manifest.xml failed; aborting
Call Stack (most recent call first):
/opt/ros/hydro/share/ros/core/rosbuild/public.cmake:174 (_rosbuild_check_manifest)
libusermediator/CMakeLists.txt:255 (rosbuild_init)
-- Configuring incomplete, errors occurred!
make: *** [cmake_check_build_system] Error 1
Invoking "make cmake_check_build_system" failed
edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Barbara
close date 2014-03-03 00:26:47

Comments

1

It seems like you are mixing rosbuild commands and catkin commands in CMakeLists.txt. Those are actually two different build systems. You might actually be OK with just removing the rosbuild_ everywhere.

dornhege gravatar image dornhege  ( 2014-02-28 04:35:35 -0500 )edit

That was the reason. Thank you

Barbara gravatar image Barbara  ( 2014-03-03 00:26:22 -0500 )edit