This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
RE: GCJ RMI, does it work on Windows?
- From: "Rui Wang" <Rui dot Wang at newcastle dot ac dot uk>
- To: <java at gcc dot gnu dot org>
- Date: Mon, 7 Nov 2005 12:17:10 -0000
- Subject: RE: GCJ RMI, does it work on Windows?
I have solved most of my problems by now. Although the RMI server is
still not working.
>From my experience, the correct version GCC binary seems to be
important.
Previous problems are caused by gcj 3.4.* from MinGW. So if you wanna
use GCJ on windows, I would strongly suggest that go the following
website and download the GCC 4.*
http://www.thisiscool.com/gcc_mingw.htm
Thanks
Rui
>-----Original Message-----
>From: java-owner@gcc.gnu.org [mailto:java-owner@gcc.gnu.org]
>On Behalf Of Rui Wang
>Sent: 05 November 2005 14:49
>To: java@gcc.gnu.org
>Subject: GCJ RMI, does it work on Windows?
>
>Judging from this archives, I seem to be the only one having
>problems on compiling RMI under gcj on Windows.
>Ok, I admit I am new to GCJ. But I have a very simple wish in my mind:
>testing GCJ on a helloworld-based RMI code. My code is a
>client that calls a getSum(int x, int y) method on a server,
>it is running fine on Sun JVM.
>
>I'm using windows XP, with the following packages:
> - MinGW-4.1.0 (gcj 3.4.2 comes with it) on my C drive.
> - libiconv-1.8.1
>
>I then set system path point to C:\MinGW\bin, and add
>C:\MinGW\lib to system classpath. Everything is running fine.
>GCJ is capable of compiling some sample java code.
>
>The problem came when I was trying to run the rmiregistry from
>gcj. A error was thrown out:
>
>WARNING: could not properly read security provider files:
> file:///mingw/lib/security/libgcj.security
> file:///mingw/lib/security/classpath.security
> Falling back to standard GNU security provider
>java.rmi.RemoteException: failed to export: class
>gnu.java.rmi.dgc.DGCImpl
> at 0x00418d4e (Unknown Source)
> at 0x00419242 (Unknown Source)
> at 0x004436f4 (Unknown Source)
>
>I checked mingw/lib/security directory, both security files
>are there and the registry seems still running. I don't really
>know what cause the problem? Do I need to configure mingw to
>run gcj properly?
>
>Another problem is found when I was trying to generate
>stub/skeleton using GCJ's rmic. I notice -classpath flag is
>ignored at this moment.
>Therefore, I used the following batch file to do the job:
>
>::set CLASSPATH=.;%cd%\bin;
>grmic -vcompat RMIServerImpl.class
>
>A "java.lang.ClassNotFoundException: RMIServerImpl.class not
>found exception" is thrown out. I did try a few other
>approaches by calling grmic in the same directory of the class
>file, or using Sun rmic to generate stub/skeleton files then
>use it with gcj compiled files. But they all fall short.
>
>One final question, how to make use of policy file in RMI
>setting with GCJ RMI? The file I am currently using is:
>Policy.all
>grant {
> permission java.security.AllPermission; };
>
>if anyone out there is using GCJ RMI on windows successfully
>and wouldn't mind to helping me figure this out, I would much
>appreciate your effort, since I am stacked by these problem
>for three days.
>
>Regards
>Rui
>