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

Mavros library depends on mavros_msgs headers #391

Merged
merged 1 commit into from
Sep 23, 2015

Conversation

jonbinney
Copy link
Contributor

Adding this dependency makes sure that mavros_msgs message headers are generated before the mavros library is built, since it needs those headers.

Otherwise you get intermittent build errors when building using multiple catkin_make threads, such as:

[  4%] Building CXX object third_party/mavros/mavros/CMakeFiles/mavros.dir/src/lib/uas_data.cpp.o
In file included from /home/odroid/ros/src/third_party/mavros/mavros/include/mavros/utils.h:21:0,
                 from /home/odroid/ros/src/third_party/mavros/mavros/src/lib/uas_data.cpp:18:
/home/odroid/ros/src/third_party/mavros/mavros_msgs/include/mavros_msgs/mavlink_convert.h:17:33: fatal error: mavros_msgs/Mavlink.h: No such file or directory
 #include <mavros_msgs/Mavlink.h>
                                 ^
compilation terminated.

Adding this dependency makes sure that mavros_msgs message headers are
generated before the mavros library is built, since it needs those
headers.
@vooon
Copy link
Member

vooon commented Sep 22, 2015

Hmm, i'm never got this error. Perhaps because catkin builds <depend> before.

@jonbinney
Copy link
Contributor Author

Do you use catkin tools? In that case yes, it builds each package as their own cmake workspace, and orders them using <depend>. catkin_make builds everything in one cmake workspace so you need to get the cmake dependencies just right or else you get intermittent errors.

@vooon
Copy link
Member

vooon commented Sep 23, 2015

Yes, catkin_tools is more friendly and handy than catkin_make.

@vooon vooon added this to the Version 0.16 milestone Sep 23, 2015
vooon added a commit that referenced this pull request Sep 23, 2015
Mavros library depends on mavros_msgs headers
@vooon vooon merged commit d8efeb2 into mavlink:master Sep 23, 2015
@vooon vooon mentioned this pull request Nov 8, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants