1. Download from http://www.java.com the lastest JAVA (~70MB) version tar.gz (the zip things for linux NOT the RPM) for your Architecture (64 for 64bits and 32 for 32 bits, you can check this by using " uname -p " on a terminal, if it displays x86_64 then x64 is for you).
2. Open the terminal (yeah, the one and only)
3. Do this set of commands when your file is DOWNLOADED (sentences next to "#" explain what each command does):
Code: Select all
mkdir /usr/java/ #creates java directory
cd /usr/java/ #sets working directory to the one just created
cp ~/Downloads/jre*.tar.gz /usr/java/ #copies the downloaded file to the folder previously mentioned.
tar zxvf jre*.tar.gz #unpacks the file into a directory
ln -s -v /usr/java/jre*/bin/java /usr/bin/java #makes a link to be able to issue the "java" command on the terminal, you should change the "jre*" bit to the name of the folder that the tar command created
cd /etc/profile.d/ #places terminal on the profile.d directory.
mp java #creates and edits a java file
Code: Select all
mkdir /usr/java/; cd /usr/java/; cp ~/Downloads/jre*.tar.gz /usr/java/; tar zxvf jre*.tar.gz; ln -s -v /usr/java/jre*/bin/java /usr/bin/java; cd /etc/profile.d/; mp java
4. Now you should have a text editor open, you should paste the following commands:
Code: Select all
JAVA_HOME=$(ls -d /usr/java/jre* | tail -n 1); export JAVA_HOME #Creates the JAVA_HOME env variable for proper jar use
echo $PATH|grep -q "$JAVA_HOME" || export PATH=$PATH:$JAVA_HOME/bin; #adds the JAVA_HOME to the PATH
LD_LIBRARY_PATH=$JAVA_HOME/lib:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH #Adds the libs of java to the libs library
Code: Select all
rm "/usr/java/jre-*.tar.gz"
And that's it! If you want to know where did I get this information, check this links:
http://www.murga-linux.com/puppy/viewto ... 031#710031
http://murga-linux.com/puppy/viewtopic. ... 1&start=17