Date : 21 / 04 / 2019
I thought to write this gist due to the difficulties which I had to face when installing Oracle Java Development Kit to my Arch Linux OS. At this moment, AUR links not working for installations because of direct downloads are no longer available. You have to create an Oracle account, download, and put in with the PKGBUILD.
This solution will work with Arch Linux and Manjaro.
Now let's do it.
- Its probably easiest to just do it manually instead of trying to dance with an automated helper and its directories.
cd ~/Downloads && git clone https://aur.archlinux.org/jdk8.git
- Now you should have a jdk8 folder in Downloads. Move that ".tar.gz" which you downloaded from oracle to that folder, If it is also in downloads, and I got the filename right, the command would be like this.
mv ~/Downloads/jdk-8u212-linux-x64.tar.gz ~/Downloads/jdk8/
- Now we will enter the jdk8 folder and should edit the PKGBUILD.
cd jdk8 && nano PKGBUILD
- The source line we want to change from is....
"https://download.oracle.com/otn-pub/java/jdk/${pkgver}-${_build}/${_hash}/${_pkgname}-${pkgver}-linux-x64.tar.gz"
to the filename we now have in folder,
jdk-8u212-linux-x64.tar.gz
- Save and exit the PKGBUILD. Now we can build and install from within that directory.
makepkg -sric
- If everything looks like it went fine you can just remove that directory when you are done.
cd ~ && rm -r ~/Downloads/jdk8
Thanks for this guide, i setup oracle jdk8 on Manjaro