You are not logged in.

#1 2010-11-24 09:03:47

panosk
Member
From: Athens, Greece
Registered: 2008-10-29
Posts: 241

trying to use a java 32bit program in Arch 64bit

After giving up some time ago, I decided once more to try to run a commercial 32bit Java application in my Arch 64bit. The same program runs fine in a vm with Ubuntu 64bit. Also, I installed bin32-jre from aur and I messed up the jre.sh and jdk.sh scripts in /etc/profile.d/ and made it work, but then my native Java 64 bit programs won't run.

To sum up, is there a way to achieve the same Java compatibility that Ubuntu offers? What libs or packages do I have to install and how should I configure them to run every java program, no matter if it is 32 or 64 bit?

Thanks.

Offline

#2 2010-11-24 10:27:34

Awebb
Member
Registered: 2010-05-06
Posts: 6,298

Re: trying to use a java 32bit program in Arch 64bit

Java applications are compiled to bytecode. This bytecode is interpreted by the JRE to run on your specific environment. I don't see how a Java application could be either "32bit" or "64bit". This is the big benefit of Java: Write your code, compile it and run it on every machine that has Java installed.

Let's try to run your "32bit Java application" on 64bit JRE. What errors do you encounter that make you think you need a different environment?

Offline

#3 2010-11-24 10:44:25

panosk
Member
From: Athens, Greece
Registered: 2008-10-29
Posts: 241

Re: trying to use a java 32bit program in Arch 64bit

Awebb wrote:

Java applications are compiled to bytecode. This bytecode is interpreted by the JRE to run on your specific environment. I don't see how a Java application could be either "32bit" or "64bit". This is the big benefit of Java: Write your code, compile it and run it on every machine that has Java installed.

Let's try to run your "32bit Java application" on 64bit JRE. What errors do you encounter that make you think you need a different environment?

Truth is that things are not so simple. This application uses the SWT toolkit for its interface and has other dependencies besides jre (gtk is one for sure). I would be very grateful if you could download the fully functional demo version from here http://www.wordfast.com/zip/2.4.0.1/lin … nux.tar.gz and give it a try. If you can't do that, I can provide some logs. I am sure the problem is not how Java behaves but the way this app is developed and packaged. I have bought a license some years ago, but I still haven't managed to run it properly on any of my Arch machines and I just wait for the devs to take some action on this issue. I have also asked for help, but it seems that they take for granted that their Linux users use distros with mixed libs (like Ubuntu).

Anyways, thx for your reply.

Offline

#4 2010-11-24 12:44:20

ngoonee
Forum Fellow
From: Between Thailand and Singapore
Registered: 2009-03-17
Posts: 7,356

Re: trying to use a java 32bit program in Arch 64bit

Java applications can indeed by 32-bit, in my experience. Best hope is to get a 32-bit chroot set up, the wiki has instructions. Also, why use jre instead of openjdk, in my experience that's more likely to work (and I think its what Ubuntu uses by default).


Allan-Volunteer on the (topic being discussed) mailn lists. You never get the people who matters attention on the forums.
jasonwryan-Installing Arch is a measure of your literacy. Maintaining Arch is a measure of your diligence. Contributing to Arch is a measure of your competence.
Griemak-Bleeding edge, not bleeding flat. Edge denotes falls will occur from time to time. Bring your own parachute.

Offline

#5 2010-11-24 14:12:30

panosk
Member
From: Athens, Greece
Registered: 2008-10-29
Posts: 241

Re: trying to use a java 32bit program in Arch 64bit

ngoonee wrote:

Java applications can indeed by 32-bit, in my experience. Best hope is to get a 32-bit chroot set up, the wiki has instructions. Also, why use jre instead of openjdk, in my experience that's more likely to work (and I think its what Ubuntu uses by default).

Tried opendjk but still no luck. I guess I will try the 32-bit chroot method.

Thanks.

Offline

#6 2010-11-25 08:56:15

saline
Member
Registered: 2010-02-20
Posts: 86

Re: trying to use a java 32bit program in Arch 64bit

I installed the 64-bit JRE from Sun/Oracle into /opt/java, symlinked the plugin .so into /usr/lib/mozilla/plugins and the java bin to /usr/bin/java and then installed the 32-bit JRE from S/O over that (overwriting the files so it still starts with the 64-bit plugin).  It's nasty, but I have to work with a VPN browser plugin for my school that breaks on a 64-bit JRE.  This is the only way I've got it to work.  I haven't had any problems with other Java programs, but I don't run much.  I also have a 64-bit JDK in my home for other things.  You might try something like that.

Offline

Board footer

Powered by FluxBB