0
$\begingroup$

Rosanswers logo

I'm using hydro with catkin (v. 0.5.77) and I'm using a metapackage because I want to enhance a rosbuild-stack, which I catkinized. My problem is, that catkin_make recognizes my metapackage, but doesn't touch (in terms of compile) the package within the metapackage.

To show the problem, I created a metapackage called "metapackage" in catkins source directory (~/catkin_ws/src/metapackage) and a package "package1" in the directory of the metapackage (~/catkin_ws/src/metapackage/package1). The package "package1" is working fine and compiling, when I move it in catkins source directory. But if it's in the metapackages directory, it isn't touched by catkin.

I went through all the ros-answers questions and the wiki, but I didn't find another way telling catkin about my package except the run_depend-tag, which doesn't change anything.

Thanks in advance.

Information

- That's the CMakeLists.txt of my metapackage:

cmake_minimum_required(VERSION 2.8.3)
project(metapackage)
find_package(catkin REQUIRED)
catkin_metapackage()

  • That's the package.xml of my metapackage:
<?xml version="1.0"?>
<package>
  <name>metapackage</name>
  <version>0.0.0</version>
  <description>The metapackage package</description>
 
  <maintainer email="[email protected]">user</maintainer>
  <license>TODO</license>
 
  <buildtool_depend>catkin</buildtool_depend>
  <run_depend>package1</run_depend>
 
 
  <!-- The export tag contains other, unspecified, tags -->
  <export>
    <!-- You can specify that this package is a metapackage here: -->
    <metapackage/>
    <!-- Other tools can request additional information be placed here-->
 
  </export>
</package>
  • If it's interesting, that's my toplevel CMakeLists.txt: pastebin.com/h6ssccXC
    (it needs a http:// prefix as I do not have enough karma to post links, but it's too long to post it here)

Originally posted by MatthiasMayr on ROS Answers with karma: 48 on 2013-12-02

Post score: 1

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

Uhm, I don't think packages are allowed to reside within outher packages. Have you seen any indications for that to work?

Usually the parent folder, named like the meta package or just the repo name, contains no package.xml but all packages and also the folder again named like the meta package, containing the package.xml with the meta-declaration.


Originally posted by felix k with karma: 1650 on 2013-12-02

This answer was ACCEPTED on the original site

Post score: 3


Original comments

Comment by MatthiasMayr on 2013-12-02:
Your tip with the folder worked. I didn't know, that the metapackages packages.xml and CMakeLists.txt have to be within a folder named like the metapackage. I also didn't find any documentation saying that.

Comment by neuronet on 2016-08-03:
This, maybe? http://wiki.ros.org/catkin/migrating_from_rosbuild#Package_Layout_in_Workspace

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.