hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t...@apache.org
Subject svn commit: r1183068 - in /hadoop/common/trunk: hadoop-assemblies/src/main/resources/assemblies/hadoop-mapreduce-dist.xml hadoop-dist/pom.xml
Date Thu, 13 Oct 2011 20:23:59 GMT
Author: tucu
Date: Thu Oct 13 20:23:59 2011
New Revision: 1183068

URL: http://svn.apache.org/viewvc?rev=1183068&view=rev
Log:
HADOOP-7737. normalize hadoop-mapreduce & hadoop-dist dist/tar build with common/hdfs
(tucu)

Modified:
    hadoop/common/trunk/hadoop-assemblies/src/main/resources/assemblies/hadoop-mapreduce-dist.xml
    hadoop/common/trunk/hadoop-dist/pom.xml

Modified: hadoop/common/trunk/hadoop-assemblies/src/main/resources/assemblies/hadoop-mapreduce-dist.xml
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-assemblies/src/main/resources/assemblies/hadoop-mapreduce-dist.xml?rev=1183068&r1=1183067&r2=1183068&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-assemblies/src/main/resources/assemblies/hadoop-mapreduce-dist.xml
(original)
+++ hadoop/common/trunk/hadoop-assemblies/src/main/resources/assemblies/hadoop-mapreduce-dist.xml
Thu Oct 13 20:23:59 2011
@@ -3,9 +3,9 @@
   xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0
http://maven.apache.org/xsd/assembly-1.1.0.xsd">
   <id>hadoop-mapreduce-dist</id>
   <formats>
-    <format>tar.gz</format>
+    <format>dir</format>
   </formats>
-  <includeBaseDirectory>true</includeBaseDirectory>
+  <includeBaseDirectory>false</includeBaseDirectory>
   <!-- TODO: this layout is wrong. We need module specific bin files in module specific
dirs -->
   <fileSets>
     <fileSet>

Modified: hadoop/common/trunk/hadoop-dist/pom.xml
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-dist/pom.xml?rev=1183068&r1=1183067&r2=1183068&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-dist/pom.xml (original)
+++ hadoop/common/trunk/hadoop-dist/pom.xml Thu Oct 13 20:23:59 2011
@@ -85,13 +85,13 @@
             <executions>
               <execution>
                 <id>dist</id>
-                <phase>package</phase>
+                <phase>prepare-package</phase>
                 <goals>
                   <goal>run</goal>
                 </goals>
                 <configuration>
-                  <target if="tar">
-                    <echo file="${project.build.directory}/dist-tar-stitching.sh">
+                  <target>
+                    <echo file="${project.build.directory}/dist-layout-stitching.sh">
                       run() {
                         echo "\$ ${@}"
                         "${@}"
@@ -110,9 +110,9 @@
                       run rm -rf hadoop-${project.version}
                       run mkdir hadoop-${project.version}
                       run cd hadoop-${project.version}
-                      run tar xzf $ROOT/hadoop-common-project/hadoop-common/target/hadoop-common-${project.version}.tar.gz
--strip-components 1
-                      run tar xzf $ROOT/hadoop-hdfs-project/hadoop-hdfs/target/hadoop-hdfs-${project.version}.tar.gz
--strip-components 1
-                      run tar xzf $ROOT/hadoop-mapreduce-project/target/hadoop-mapreduce-${project.version}.tar.gz
--strip-components 1
+                      run cp -r $ROOT/hadoop-common-project/hadoop-common/target/hadoop-common-${project.version}/*
.
+                      run cp -r $ROOT/hadoop-hdfs-project/hadoop-hdfs/target/hadoop-hdfs-${project.version}/*
.
+                      run cp -r $ROOT/hadoop-mapreduce-project/target/hadoop-mapreduce-${project.version}/*
.
                       COMMON_LIB=share/hadoop/common/lib
                       MODULES=../../../../modules
                       run ln -s $MODULES/hadoop-mapreduce-client-app-${project.version}.jar
$COMMON_LIB
@@ -122,7 +122,36 @@
                       run ln -s $MODULES/hadoop-mapreduce-client-core-${project.version}.jar
$COMMON_LIB
                       run ln -s $MODULES/hadoop-yarn-server-common-${project.version}.jar
$COMMON_LIB
                       run ln -s $MODULES/hadoop-mapreduce-client-jobclient-${project.version}.jar
$COMMON_LIB
-                      run cd -
+                      echo
+                      echo "Hadoop dist layout available at: ${project.build.directory}/hadoop-${project.version}"
+                      echo
+                    </echo>
+                    <exec executable="sh" dir="${project.build.directory}" failonerror="true">
+                      <arg line="./dist-layout-stitching.sh"/>
+                    </exec>
+                  </target>
+                </configuration>
+              </execution>
+              <execution>
+                <id>tar</id>
+                <phase>package</phase>
+                <goals>
+                  <goal>run</goal>
+                </goals>
+                <configuration>
+                  <target if="tar">
+                    <echo file="${project.build.directory}/dist-tar-stitching.sh">
+                      run() {
+                        echo "\$ ${@}"
+                        "${@}"
+                        if [ $? != 0 ]; then
+                          echo
+                          echo "Failed!"
+                          echo
+                          exit $?
+                        fi
+                      }
+
                       run tar czf hadoop-${project.version}.tar.gz hadoop-${project.version}
                       echo
                       echo "Hadoop dist tar available at: ${project.build.directory}/hadoop-${project.version}.tar.gz"



Mime
View raw message