-RE: How to build Hadoop from source using Ant
Chuan Liu 2013-07-15, 16:35
If you want to build release tarball, you can use the ant target 'tar'. If you want native libraries built, you need to set 'complile.native' flag to true. 'forrest.home' need to be set to Apache Forrest location in order to build java doc.
So you will have a command like the following:
>ant -Dcompile.native=true -Dforrest.home=/path/to/forrest tar
From: Jun Li [mailto:[EMAIL PROTECTED]]
Sent: Saturday, July 13, 2013 3:37 AM
To: [EMAIL PROTECTED]
Subject: How to build Hadoop from source using Ant
I have downloaded from the Apache web site the Hadoop.1.1.2, the current stable version. Then I simply used the command of:
to try to build the Hadoop core.
After the successful compilation, I used the diff tool to try to compare the hardoop-core.jar that I just built, with the one comes with the Hadoop-1.1.2 tar.gz from the Apache web site. I see a lot of class files are different in my compiled JAR file and the ones from the hadoop-1.1.2.tar.gz from the Apache Web site. Then I picked, for example, the class: org/apache/hadoop/security/UserGroupInformation.class, and used md5sum to make the comparison, and confirmed that the file content is really different for two class files.
My java compiler is Sun Java build 1.6.0_45-b06.
I like to know what is the correct command to invoke ANT to compile the java code from the Hadoop Source code.