Last active
December 15, 2015 01:59
-
-
Save kennycason/5184385 to your computer and use it in GitHub Desktop.
Install JDK 1.7.0 (x86 & x86-64 Linux)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
#TARFILE="jdk-7u17-linux-x64.tar.gz" | |
TARFILE="jdk-7u17-linux-i586.tar.gz" | |
# wget http://www.ken-soft.com/dl/jdk/$TARFILE | |
tar -xvf $TARFILE | |
if [ ! -d "/usr/lib/jvm/jdk1.7.0/" ]; then | |
sudo mkdir /usr/lib/jvm/jdk1.7.0/ | |
fi | |
sudo cp -Rf ./jdk1.7.0_17/* /usr/lib/jvm/jdk1.7.0 | |
sudo update-alternatives --install "/usr/bin/java" "java" "/usr/lib/jvm/jdk1.7.0/bin/java" 1 | |
sudo update-alternatives --install "/usr/bin/javac" "javac" "/usr/lib/jvm/jdk1.7.0/bin/javac" 1 | |
sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/lib/jvm/jdk1.7.0/bin/javaws" 1 | |
sudo update-alternatives --config java | |
echo "Checking Installed version. Should be 1.7.0" | |
java -version | |
sudo update-alternatives --config javac | |
sudo update-alternatives --config javaws | |
echo "Installing Firefox Plugin" | |
if [ ! -d "~/.mozilla/plugins/" ]; then | |
mkdir ~/.mozilla/plugins/ | |
fi | |
ln -s /usr/lib/jvm/jdk1.7.0/jre/lib/amd64/libnpjp2.so ~/.mozilla/plugins/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@phodamentals @brittcagnina