Ask Your Question

How to rosmake rosjava from source?

asked 2012-03-07 07:58:05 -0500

updated 2012-03-07 10:08:35 -0500

I have tried to follow the tutorials regarding building rosjava:

First, I installed rosjava from source, as described here:

Next, I tried to build it: roscd rosjava_core rosmake There were no errors, but plenty of warnings, including: [rosmake-0] Finished <<< rosjava No Makefile in package rosjava

What steps am I missing? Do I create a makefile by hand as described for a new package? Ant does not work, because there is not a build.xml file. There is, however, a build.gradle file. However running gradle returns an error.

Basically, I would like to compile rosjava from source and then run the tutorial as described here:

What am I missing to get rosjava installed and built?

Thanks in advance.

Update: I should add that when I tried to run 'gradle build' in the rosjava_core directory, the error was something like, "Could not find method maven() for arguments". Then, I updated my gradle by downloading it, to version 1.0-milestone-8a, and that error went away.

Now, when I try to run 'gradle build', it gets much farther, but then stops at another error: Could not resolve all dependencies for configuration ':rosjava:compile'.

Could not find group:ros, module:message.std_msgs, version:0.0.0-SNAPSHOT. Required by: ros.rosjava_core:rosjava:0.0.0-SNAPSHOT Could not find group:ros, module:message.rosgraph_msgs, version:0.0.0-SNAPSHOT. Required by: ros.rosjava_core:rosjava:0.0.0-SNAPSHOT

This seems very similar to an unresolved issue:

Perhaps the current source snapshot of rosjava is not buildable? Please correct me if I am building this incorrectly, the tutorial seems to be out of date. Thanks.

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2012-03-07 15:41:45 -0500

I'm having the same problem. I updated from the repo on Monday and everything built fine. I updated again Tuesday afternoon and it failed to build. It appears the problem is with the commits merged by Damon on Tuesday morning.

Going back to hash 1084ec6c569c (the last commit before his changes) builds for me with no modifications. This is a slightly newer version than the one suggested in the previous answer.

edit flag offensive delete link more


Thanks for confirming the issue. I tried this later version, and it works as well: rosinstall using that tag; roscd rosjava_core; rosmake. That worked. Then, I followed the steps on the tutorial to run roscore, the listener and the talker. Thanks!

ceverett gravatar image ceverett  ( 2012-03-07 16:17:17 -0500 )edit

Also, if you are using rosjava for Android, the repository should be checked out with revision hash 2feb1d497d6e. Changes were made to convert it to Gradle at the same time as rosjava and seem to have broken it as well.

david.hodo gravatar image david.hodo  ( 2012-03-08 16:15:52 -0500 )edit

FYI, I've started adding documentation on the new build system:

damonkohler gravatar image damonkohler  ( 2012-03-11 21:08:04 -0500 )edit

answered 2012-03-07 10:36:39 -0500

jamuraa gravatar image

updated 2012-03-07 10:55:15 -0500

I solved this issue this way, by using an old version of rosjava for now, and also modifying the files slightly.

  • Use the rosjava_core from hash ea121c0749f2 by using this .rosinstall snippet:
- hg:
    local-name: rosjava_core
    version: ea121c0749f2
  • Running rosmake rosjava doesn't just work on that for me (although it might for you) so I had to also remove references to debuglevel="${debuglevel}" in the files rosjava/build.xml and rosjava_bootstrap/scripts/build-msg.xml.

Once I did these two things, rosmake rosjava worked as expected, and the tutorial steps on the Tutorial Page worked as expected.

edit flag offensive delete link more


Thanks for your help. That works. I suppose this will suffice until the latest rosjava is working. I got the version you showed here, did rosmake in rosjava_core, and the tutorial steps work.

ceverett gravatar image ceverett  ( 2012-03-07 16:13:28 -0500 )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



Asked: 2012-03-07 07:58:05 -0500

Seen: 720 times

Last updated: Mar 07 '12