how to build OpenJDK from source

Asked by Avin

I am refereeing to this tar file
link1:
https://launchpad.net/ubuntu/+archive/primary/+files/openjdk-8_8u91-b14.orig.tar.xz
I am not able to find any MAKE in this source

but I am able to find in this link
link2
http://download.oracle.com/otn-pub/java/jdk/8u91-b14/jdk-8u91-linux-x64.tar.gz

please help me how to build from link1

Thanks
Avinash

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Manfred Hampl
Solved:
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

For Oracle Java you can use:

sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java8-installer

Why do you want to compile OpenJDK ?

Revision history for this message
Avin (avinashub211) said :
#2

the directory structure in link1 and link2 are not same, that's what my concern is.
then what's the use of downloading source from link1, if I am not able to build from the source
link1
https://launchpad.net/ubuntu/+archive/primary/+files/openjdk-8_8u91-b14.orig.tar.xz

I am trying to build a debug version of OpenJDK in link1

Thanks.

Revision history for this message
Best Manfred Hampl (m-hampl) said :
#3

Oracle jdk and the jdk from openjdk are not the same.
Oracle's version has certain licensing restrictions that are different from those that OpenJDK has.

Debug symbols for openjdk8 are available in the standard Ubuntu repositories in the package openjdk-8-dbg

You have to understand that on Ubuntu you always have two source packages that go together.
In this case openjdk-8_8u91-b14.orig.tar.xz containg the original source. and the Ubuntu (or Debian) additions and modifications in a file named something like openjdk-8_8u91-b14-0ubuntu4~16.04.1.debian.tar.xz

This second package should contain everything needed in addition to the original source package, to build the .deb packages with the debuild command.

Revision history for this message
Avin (avinashub211) said :
#4

Thanks Manfred Hampl, that solved my question.