This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Java hello world link error


Jon,
installing libiconv and using "--main=Test" did the trick.
Thanks.
I looked at http://gcc.gnu.org/java/ and found
http://www.linuxjournal.com/article.php?sid=4860
which discusses compiling java.

One last thing.
I noticed that the resulting Test.exe attempts to access the internet.
Is this expected ?
Its trying to access 24.25.4.107 which my getHost tool tells me is
rlghnc-dns-cac-02-dmfe1.nc.rr.com.

Mauro


mauro zallocco wrote:
> $ gcj Test.java
> /usr/lib/gcc-lib/i686-pc-cygwin/3.3.1/../../../../i686-pc-cygwin/bin/ld:
> cannot
> find -liconv
> collect2: ld returned 1 exit status
> 

Jon A. Lambert" <at alltel dot net>
You probably need to install one or both of these:

$ cygcheck -c | grep iconv
libiconv                1.9.1-3            OK
libiconv2               1.9.1-3            OK

----------------------------------------------------
Test.java

class Test {
  public static void main(String argv[]) {
      System.out.println("Hello World");
  }
}

/Mauro 

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]