You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by Jun Li <jl...@gmail.com> on 2013/07/13 12:37:04 UTC
How to build Hadoop from source using Ant
Hello,
I have downloaded from the Apache web site the Hadoop.1.1.2, the current
stable version. Then I simply used the command of:
ant -Dcompile-core=true
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.
Thank you!
Jun
RE: How to build Hadoop from source using Ant
Posted by Chuan Liu <ch...@microsoft.com>.
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
-Chuan
From: Jun Li [mailto:jltz922181@gmail.com]
Sent: Saturday, July 13, 2013 3:37 AM
To: user@hadoop.apache.org
Subject: How to build Hadoop from source using Ant
Hello,
I have downloaded from the Apache web site the Hadoop.1.1.2, the current stable version. Then I simply used the command of:
ant -Dcompile-core=true
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.
Thank you!
Jun
RE: How to build Hadoop from source using Ant
Posted by Chuan Liu <ch...@microsoft.com>.
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
-Chuan
From: Jun Li [mailto:jltz922181@gmail.com]
Sent: Saturday, July 13, 2013 3:37 AM
To: user@hadoop.apache.org
Subject: How to build Hadoop from source using Ant
Hello,
I have downloaded from the Apache web site the Hadoop.1.1.2, the current stable version. Then I simply used the command of:
ant -Dcompile-core=true
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.
Thank you!
Jun
RE: How to build Hadoop from source using Ant
Posted by Chuan Liu <ch...@microsoft.com>.
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
-Chuan
From: Jun Li [mailto:jltz922181@gmail.com]
Sent: Saturday, July 13, 2013 3:37 AM
To: user@hadoop.apache.org
Subject: How to build Hadoop from source using Ant
Hello,
I have downloaded from the Apache web site the Hadoop.1.1.2, the current stable version. Then I simply used the command of:
ant -Dcompile-core=true
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.
Thank you!
Jun
RE: How to build Hadoop from source using Ant
Posted by Chuan Liu <ch...@microsoft.com>.
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
-Chuan
From: Jun Li [mailto:jltz922181@gmail.com]
Sent: Saturday, July 13, 2013 3:37 AM
To: user@hadoop.apache.org
Subject: How to build Hadoop from source using Ant
Hello,
I have downloaded from the Apache web site the Hadoop.1.1.2, the current stable version. Then I simply used the command of:
ant -Dcompile-core=true
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.
Thank you!
Jun