The basic difference between JDK and JRE is that jdk is the complete
development environment that includes the compiler (javac), while jre
just contains the basic VM to run the java code (.class and .jar
files), so, if you need to compile a .java file, you will need the jdk
but if you just need to run something that is already compiled, you
just use the VM.
JDK contains the VM.

[]s
Felipe



On 12/19/05, Holly Bostick <[EMAIL PROTECTED]> wrote:
> John Jolet schreef:
> >
> > On Dec 18, 2005, at 8:58 PM, Mark Knecht wrote:
> >
> >> On 12/18/05, Holly Bostick <[EMAIL PROTECTED]> wrote:
> >>
> >>> Mark Knecht schreef:
> >>>
> >>>>
> >>>> Do anyone know what was meant by the final comment? I've copied
> >>>>  it here for ease of discussion. How do I set the Java VM to
> >>>> the JDK?  Why is this recommended?
> >>>
> >>>
> >>> 1) java-config.
> >>
> >>
> >> OK. Thanks Holly. But if I'm going to set the VM to be the jdk,
> >> then why install the jre? I guess I have no clue about the
> >> difference between the jre and the jdk or why both are needed or
> >> what each one does. I can say that installing the jdk broke one
> >> aspect of the sun jre. Bummer for me.
> >>
> > this has always confused me...if you install the jdk, in the path
> > with the jdk (/usr/local/java for instance), there's a jre
> > directory...you have /usr/local/java/bin/java and
> > /usr/local/java/jre/ bin/java.....both.  so you don't need to install
> >  both.  the jdk is INCLUSIVE of the jre.
>
> Not on my system (32-bit). If I try to use the Sun jre alone, I get the
> same errors that Mark reported if I try to set it as the system VM;
> using it as user VM seemed OK as I recall. Eventually I got tired of
> having the system vm and the user vm being different (probably me being
> anal rather than a real "issue"), and since using Sun 1.5.0.* as the
> user VM hadn't seemed to cause any major issues, I attempted to make it
> the system VM as well, at which point I got this stuff (this is Mark's,
> but this was the same error I got):
>
>
>  * Found no JDK, setting sun-jre-bin-1.5.0.06 as default system VM
> javac not found at /opt/sun-jre-bin-1.5.0.06/bin/javac or
> /opt/sun-jre-bin-1.5.0.06/jre/bin/javac
> javadoc not found at /opt/sun-jre-bin-1.5.0.06/bin/javadoc or
> /opt/sun-jre-bin-1.5.0.06/jre/bin/javadoc
> jar not found at /opt/sun-jre-bin-1.5.0.06/bin/jar or
> /opt/sun-jre-bin-1.5.0.06/jre/bin/jar
> rmic not found at /opt/sun-jre-bin-1.5.0.06/bin/rmic or
> /opt/sun-jre-bin-1.5.0.06/jre/bin/rmic
> THIS SYSTEM VM IS NOT SUFFICIENT, REQUIRED BINARIES WERE NOT FOUND
> System Virtual Machine set
> You may want to update your enviroment by running:
>         "/usr/sbin/env-update && source /etc/profile"
>
> Unfortunately I don't remember what was actually in the /bin folder as I
> have since uninstalled the jre and set both the user and system vm to
> the sun jdk. But either java and jar really weren't there, or they were
> and java-config couldn't find them, and in either case I really didn't
> have the time or interest to investigate the root issue (gotta choose
> your battles with Gentoo, sometimes ;-) ), so I just switched everything
> to the jdk (which works fine, despite being only 1.4.2, when some apps I
> use recommend 1.5.0+), uninstalled the jre (I had previously
> unmerged/masked the blackdown jre when I installed Sun's) and went on
> with my week (last week, I think this was). Haven't noticed any issues
> with having done so; web browsers seem to work, as well as what
> java-based apps I use.
>
> So I admit I don't know what the problem is, and I also concede that it
> probably shouldn't be happening (as you say), but I confirm that Mark's
> original issue does seem to be real and that is the workaround/hack I
> used to bypass it when I encountered it.
>
> However, any "real" Java users/developers might find it is inappropriate
> and I make no guarantees that it is. It's just what worked for me,
> because I didn't like that error at all-- though I don't necessarily
> think that it was fatal or even critical or that I would have had
> "problems" had I just let it stand and used the Sun jre as the system vm
> (after all, what do I do as root with Java? Nothing, afaik).
>
> Holly
>
> --
> gentoo-user@gentoo.org mailing list
>
>

-- 
gentoo-user@gentoo.org mailing list

Reply via email to