ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

Rosjava install problem ./gradlew install

asked 2012-09-10 06:27:52 -0600

LargeBearCat gravatar image

Hi, I am trying to install ROSJava (Fuerte). I have already installed the regular ROS (Fuerte). I am working through the rosjava building steps (http://docs.rosjava.googlecode.com/hg/rosjava_core/html/building.html).

When I get to ./gradlew install it shows a lot of Java errors:

Downloading http://services.gradle.org/distributions/gradle-1.0-milestone-9-bin.zip

Exception in thread "main" java.net.ConnectException: Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:391) at java.net.Socket.connect(Socket.java:579) at java.net.Socket.connect(Socket.java:528) at sun.net.NetworkClient.doConnect(NetworkClient.java:180) at sun.net.www.http.HttpClient.openServer(HttpClient.java:378) at sun.net.www.http.HttpClient.openServer(HttpClient.java:473) at sun.net.www.http.HttpClient.<init>(HttpClient.java:203) at sun.net.www.http.HttpClient.New(HttpClient.java:290) at sun.net.www.http.HttpClient.New(HttpClient.java:306) at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:995) at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:931) at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:849) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1299) at org.gradle.wrapper.Download.downloadInternal(Download.java:61) at org.gradle.wrapper.Download.download(Download.java:49) at org.gradle.wrapper.Install.createDist(Install.java:51) at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:129) at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:47)

I have installed the Oracle Java JDK, set JAVA_HOME with PATH="....:$JAVA_HOME/bin", Mercurial and Maven.

Help!

edit retag flag offensive close merge delete

4 Answers

Sort by ยป oldest newest most voted
2

answered 2012-09-11 02:27:47 -0600

KruseT gravatar image

Gradle needs an internet connection. Gradle tries to donwnload that file, but got a connection error. You can also try manually:

wget http://services.gradle.org/distributions/gradle-1.0-milestone-9-bin.zip

if that works, the gradle command should also work.

edit flag offensive delete link more
0

answered 2012-09-12 02:56:46 -0600

LargeBearCat gravatar image

Thanks for the answer.

The solution is even more trivial. Turns out the Ubuntu proxy server settings is not directly used by rosjava.

--> How/Where can I specify proxy settings in rosjava? Could not google it up so far.

edit flag offensive delete link more

Comments

Ok, not rosjava proxy settings but gradle proxy settings. The download has now started, hope no more new errors.

LargeBearCat gravatar image LargeBearCat  ( 2012-09-12 03:10:06 -0600 )edit
0

answered 2013-06-25 11:22:08 -0600

I solved adding proxy parameters of this way

./gradlew -Dhttp.proxyHost=10.12.0.9 -Dhttp.proxyPort=8002 clean build

edit flag offensive delete link more
0

answered 2012-10-05 20:35:50 -0600

Jalan gravatar image

updated 2012-10-06 06:03:52 -0600

Hey,

How did you solve the problem? I am still stuck with same problem as yours. How did you specify proxy settings for gradle?

I am using Ubuntu 12.04 and ROS Fuerte.

Thanks a lot in advance. :)

EDIT: Hey, Sorry for the trouble. I figured out finally. :)

You just have to add this to your ~/.bashrc or ~/.zshrc configuration file:

export JAVA_OPTS='-Dhttp.proxyHost=proxyhostURL -Dhttp.proxyPort=proxyPortNumber -Dhttp.proxyUser=someUserName -Dhttp.proxyPassword=somePassword'

Now it should work flawlessly. :)

Links: [1] [Gradle Installation](http://www.gradle.org/installation) (Refer section: JVM OPTIONS)

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2012-09-10 06:27:52 -0600

Seen: 1,700 times

Last updated: Jun 25 '13