Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
09-03-2003, 03:57 AM
|
#1
|
LQ Newbie
Registered: Sep 2003
Location: Portland, Oregon
Distribution: Debian and Gentoo
Posts: 27
Rep:
|
Program not finding java VM libraries
I have installed Java 2 Runtime Environment version 1.4.2 on 2 systems and have met the same difficulties. I can get the Mozilla plugin to work easily, also I can install J2RE and use the GUI program when viewing java programs. However the problem that plagues me is installing other programs dependent on J2RE libraries (Java was installed in the directory /usr/java/j2re1.4.2_01 all the binaries and libraries are within just as they should be). For example, if I wanted to install Lime Wire for Linux (which requires J2RE) I will get a message stating that the installer cannot find my Java Virtual Machine. I have tried placing hard links to the 'java' and 'java_vm' binaries in the /usr/java/j2re1.4.2_01/bin/ directory from the directory where I would think the java installer would search for the binary, '/usr/bin/'. Once done I have had better results, the installer will extract its installation resources and configure itself for my system's environment, however once it begins to launch the installer program itself, an error occurs. It reports that the installer cannot find libjava.so and the Java 2 Runtime Environment. I later tried to place both a sym link and a hard link of libjava.so in both /usr/lib/ and /lib/ with no success and me out of ideas, I have given up for the time being.
I know that I am probably making a common mistake for early users to Linux, any suggestions would be highly appreciated.
|
|
|
09-03-2003, 06:29 AM
|
#2
|
Member
Registered: Aug 2003
Location: Portland, Oregon
Distribution: RedHat, Libranet
Posts: 438
Rep:
|
Something to try would be to make an entry in /etc/ld.so.conf for the location of your unfound libraries, and then invoking (as root):
ldconfig
See the ldconfig man page for details.
|
|
|
09-03-2003, 04:42 PM
|
#3
|
LQ Newbie
Registered: Sep 2003
Location: Portland, Oregon
Distribution: Debian and Gentoo
Posts: 27
Original Poster
Rep:
|
that seemed promising
I have tried placing the directory /usr/java/j2re1.4.2/lib in my /etc/ld.so.conf file and executed as root ldconf with no success. Well, better said, I had success doing these things however the program installer still does not find the libjava.so file. Which seems strange because when I execute ldconf -v and view which libraries it is searching for, libjava.so exists in this list of libraries. Is it necessary to list the binary directory of java in some file too? What kind of link would be appropriate if I have to link the binaries (symbolic or hard) and does it matter which binary directory I link them to? Thank you in advance! 
|
|
|
09-03-2003, 07:36 PM
|
#4
|
Senior Member
Registered: Apr 2003
Location: Eire
Distribution: Slackware 12.0, OpenSuse 10.3
Posts: 1,120
Rep:
|
A lot of programs will look for the JAVA_HOME environment variable to work out where it is
Add
JAVA_HOME=complete_path_to_java_runtime_directory
export JAVA_HOME
to an appropriate file such as
/etc/profile
or your .bash_profile
logout and back in and see if it helps
if that don't work add the java /bin directory to your path but unless you're using the sdk most of the time the first way works
|
|
|
09-03-2003, 10:27 PM
|
#5
|
LQ Veteran
Registered: Feb 2003
Location: Maryland
Distribution: Slackware
Posts: 7,803
|
You also should put the /usr/java/yadayadaJRE in your PATH. You can do that either in your .bashrc or you /etc/profile. You can use a line like
PATH = $PATH:/usr/java/jre_directory
export PATH
|
|
|
09-04-2003, 01:20 AM
|
#6
|
LQ Newbie
Registered: Sep 2003
Location: Portland, Oregon
Distribution: Debian and Gentoo
Posts: 27
Original Poster
Rep:
|
Changing the PATH variable worked, thank you very much for your assistance!
|
|
|
All times are GMT -5. The time now is 05:49 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|