You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bigtop.apache.org by bm...@apache.org on 2011/10/14 07:27:54 UTC

svn commit: r1183219 - /incubator/bigtop/trunk/bigtop-packages/src/common/hadoop/install_hadoop.sh

Author: bmahe
Date: Fri Oct 14 05:27:53 2011
New Revision: 1183219

URL: http://svn.apache.org/viewvc?rev=1183219&view=rev
Log:
BIGTOP-119. Create version-less symlinks of hadoop jars

Modified:
    incubator/bigtop/trunk/bigtop-packages/src/common/hadoop/install_hadoop.sh

Modified: incubator/bigtop/trunk/bigtop-packages/src/common/hadoop/install_hadoop.sh
URL: http://svn.apache.org/viewvc/incubator/bigtop/trunk/bigtop-packages/src/common/hadoop/install_hadoop.sh?rev=1183219&r1=1183218&r2=1183219&view=diff
==============================================================================
--- incubator/bigtop/trunk/bigtop-packages/src/common/hadoop/install_hadoop.sh (original)
+++ incubator/bigtop/trunk/bigtop-packages/src/common/hadoop/install_hadoop.sh Fri Oct 14 05:27:53 2011
@@ -172,6 +172,18 @@ cp -a ${BUILD_SRC_DIR}/* ${SRC_DIR}/
 install -d -m 0755 $ETC_DIR/conf.empty
 (cd ${BUILD_DIR}/conf && tar cf - .) | (cd $ETC_DIR/conf.empty && tar xf -)
 
+# Create symlinks to preserve old jar names
+# Also create symlinks of versioned jars to jars without version names, which other
+# packages can depend on
+(cd $LIB_DIR &&
+for j in hadoop-*.jar; do
+  if [[ $j =~ hadoop-(.*)-([^-]+).jar ]]; then
+    ver=${BASH_REMATCH[1]}
+    name=${BASH_REMATCH[2]}
+    ln -s hadoop-$ver-$name.jar hadoop-$name.jar
+  fi
+done)
+
 # Link the HADOOP_HOME conf, log and pid dir to installed locations
 rm -rf $LIB_DIR/conf
 ln -s ${ETC_DIR#$PREFIX}/conf $LIB_DIR/conf