You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kylin.apache.org by sh...@apache.org on 2015/12/28 08:05:51 UTC

[2/2] kylin git commit: KYLIN-1119 enhance find-hive-dependency.sh

KYLIN-1119 enhance find-hive-dependency.sh

Project: http://git-wip-us.apache.org/repos/asf/kylin/repo
Commit: http://git-wip-us.apache.org/repos/asf/kylin/commit/82e258b6
Tree: http://git-wip-us.apache.org/repos/asf/kylin/tree/82e258b6
Diff: http://git-wip-us.apache.org/repos/asf/kylin/diff/82e258b6

Branch: refs/heads/2.0-rc
Commit: 82e258b69f4d74e29795c2035e2fd24b845fd1a7
Parents: 56e1a1d
Author: shaofengshi <sh...@apache.org>
Authored: Mon Dec 28 15:05:16 2015 +0800
Committer: shaofengshi <sh...@apache.org>
Committed: Mon Dec 28 15:05:16 2015 +0800

----------------------------------------------------------------------
 build/bin/find-hive-dependency.sh | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kylin/blob/82e258b6/build/bin/find-hive-dependency.sh
----------------------------------------------------------------------
diff --git a/build/bin/find-hive-dependency.sh b/build/bin/find-hive-dependency.sh
index ee36fc3..47f0fbc 100644
--- a/build/bin/find-hive-dependency.sh
+++ b/build/bin/find-hive-dependency.sh
@@ -40,10 +40,12 @@ done
 # in some versions of hive hcatalog is not in hive's classpath, find it separately
 if [ -z "$HCAT_HOME" ]
 then
-    echo "HCAT_HOME not found, try to find hcatalog path from hive home"
-    hive_home=`echo $hive_exec_path | awk -F '/hive.*/lib/' '{print $1}'`
-    if [ -d "${hive_home}/hive-hcatalog" ]; then
-      hcatalog_home=${hive_home}/hive-hcatalog
+    echo "HCAT_HOME not found, try to find hcatalog path from hadoop home"
+    hadoop_home=`echo $hive_exec_path | awk -F '/hive.*/lib/' '{print $1}'`
+    if [ -d "${hadoop_home}/hive-hcatalog" ]; then
+      hcatalog_home=${hadoop_home}/hive-hcatalog
+    elif [ -d "${hadoop_home}/hive/hcatalog" ]; then
+      hcatalog_home=${hadoop_home}/hive/hcatalog
     else 
       echo "Couldn't locate hcatalog installation, please make sure it is installed and set HCAT_HOME to the path."
       exit 1