LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
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


Reply
  Search this Thread
Old 07-20-2004, 02:09 AM   #1
murbz
LQ Newbie
 
Registered: Jul 2004
Distribution: Red Hat Linux Shrike
Posts: 11

Rep: Reputation: 0
Question Java Programming: Java Runtime Environment not found when trying to compile


Hey Guys!

Yeah im back with another little problem. I previously had the problem with Java Virtual Machine. I got some advice and help from you guys and changed my .bash_profile with PATHS and stuff. Now i encoutered another problem. I just downlaopded a 90mb file from Java Sun Microsystems , a SDK with NetBeans IDE 3.6. Now ive installed the NetBean IDE program and is working sweet. however my "Beginning Programming for Dummies" wants me to use a text editor instead. ok im fine with that, following the instructions in the book, chapter-by-chapter. Then trying to compile the program that ive made is another story. I can't seem to use the 'javac' command. It prompts

"Error: could not find libjava.so
Error: could not find Java 2 Runtime Environment."

how can i sort this problem out guys? If someone could help me, that would be awsome.
Thanx again...

... MURBZ


Ohh: Heres a copy of my ".bash_profile" if it helps
>
---------------------------------------------------------------------------
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi

# User specific environment and startup programs

path=PATH:/usr/j2re1.3.1/bin/
export PATH
unset USERNAME
CLASSPATH=/usr/java/lib
export CLASSPATH
JAVA_HOME=/usr/local/java
export JAVA_HOME
PATH=/bin:$PATH; ---> from the book instructions exactly
export PATH --->
CLASSPATH=.; export CLASSPATH --->

------------------------------------------------------------------------------
 
Old 07-20-2004, 02:15 AM   #2
Mega Man X
LQ Guru
 
Registered: Apr 2003
Location: ~
Distribution: Ubuntu, FreeBSD, Solaris, DSL
Posts: 5,339

Rep: Reputation: 65
I think that error is because you've installed JRE, which does not include the compiler (javac). You could:

1 - download and install J2SDK. Since J2SDK includes the RE, you might want to remove the java runtime environment and stick with J2SDK instead, or:

2 - In the directory where netbeans is installed, you will find "javac" compiler insider a /bin directory. Simply make a link:

ln -s /wherever_netbeans_is/bin/javac /usr/bin/javac

Good luck!
 
Old 03-26-2009, 03:04 AM   #3
lgeood03
LQ Newbie
 
Registered: Mar 2009
Posts: 1

Rep: Reputation: 0
Java Error

Hi Mega Man,

what is the extension name for javac compiler.. try to search it and found only javac.jar only.

Do I need to install or run this file?

What do you mean about "Simply make a link"


Thanks,

lgeood03





Quote:
Originally Posted by Mega Man X View Post
I think that error is because you've installed JRE, which does not include the compiler (javac). You could:

1 - download and install J2SDK. Since J2SDK includes the RE, you might want to remove the java runtime environment and stick with J2SDK instead, or:

2 - In the directory where netbeans is installed, you will find "javac" compiler insider a /bin directory. Simply make a link:

ln -s /wherever_netbeans_is/bin/javac /usr/bin/javac

Good luck!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Java runtime environment Ab3n Linux - Newbie 5 08-19-2005 03:50 PM
Installing JAva runtime environment jcai Linux - General 3 09-28-2004 03:48 PM
Which Java Runtime Environment to use? r_jensen11 Linux - Software 4 09-13-2003 06:43 PM
Java Runtime Environment J_Szucs Linux - Newbie 6 02-18-2002 06:25 PM
StarOffice 5.2 and Java Runtime Environment glock19 Linux - General 3 01-02-2002 06:32 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration