ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
gradle install approach still does not work, but compilation now works with copy-paste gradlew. I had the gradle configuration files inside the package folder instead of outside.
2 | No.2 Revision |
gradle install approach still does not work, but compilation now works with copy-paste gradlew. I had the gradle configuration files inside the package folder instead of outside.
Edit:
Nope, still problems :-). Forget what I wrote before.
I can build the example packages in the rosjava_core folder as described in (http://docs.rosjava.googlecode.com/hg/rosjava_core/html/getting_started.html).
What I did next was copy pasting the example package "rosjava_tutorial_pubsub" and renaming the package to "rosjava_testPackage" as a test. In the folder rosjava_testPackage I renamed everything accordingly. But now ../gradlew installApp yields the errors:
FAILURE: Build failed with an exception.
* Where:
Build file '/home/userName/ros_workspace/rosjava_core/rosjava_testPackage/build.gradle'
line: 22
* What went wrong:
A problem occurred evaluating root project 'rosjava_testPackage'.
Project with path ':rosjava' could not be found in root project 'rosjava_testPackage'.
* Try:
Run with --stacktrace option to get the stack trace.
Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 0.834 secs
I used the same gradlebuild file as in the example package "rosjava_tutorial_pubsub", which looks like this:
/* .... */
apply plugin: 'application'
mainClassName = 'org.ros.RosRun'
dependencies {
compile project(':rosjava')
}
Line 22 refers to "compile project(':rosjava')".
How can there be errors if the test package is a renamed copy of the tutorial package?
3 | Problem solved |
gradle install approach still does not work, but compilation now works with copy-paste gradlew. I had the gradle configuration files inside the package folder instead of outside.
Edit:
Nope, still problems :-). Forget what I wrote before.
I can build the example packages in the rosjava_core folder as described in (http://docs.rosjava.googlecode.com/hg/rosjava_core/html/getting_started.html).
What I did next was copy pasting the example package "rosjava_tutorial_pubsub" and renaming the package to "rosjava_testPackage" as a test. In the folder rosjava_testPackage I renamed everything accordingly. But now ../gradlew installApp yields the errors:
FAILURE: Build failed with an exception.
* Where:
Build file '/home/userName/ros_workspace/rosjava_core/rosjava_testPackage/build.gradle'
line: 22
* What went wrong:
A problem occurred evaluating root project 'rosjava_testPackage'.
Project with path ':rosjava' could not be found in root project 'rosjava_testPackage'.
* Try:
Run with --stacktrace option to get the stack trace.
Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 0.834 secs
I used the same gradlebuild file as in the example package "rosjava_tutorial_pubsub", which looks like this:
/* .... */
apply plugin: 'application'
mainClassName = 'org.ros.RosRun'
dependencies {
compile project(':rosjava')
}
Line 22 refers to "compile project(':rosjava')".
How can there be errors if the test package is a renamed copy of the tutorial package?
Edit 2: Problem solved. I had to manually register the package in gradle settings.