hive: set HIVE_HOME in wrapper script
Updated java version and wrapper generation code for hive
This commit is contained in:
parent
9fa40677bf
commit
9fe7f1f7f9
1 changed files with 7 additions and 7 deletions
|
@ -6,25 +6,25 @@ class Hive < Formula
|
|||
|
||||
bottle :unneeded
|
||||
|
||||
depends_on :java => "1.7+"
|
||||
depends_on "hadoop"
|
||||
depends_on :java
|
||||
|
||||
def install
|
||||
rm_f Dir["bin/*.cmd", "bin/ext/*.cmd", "bin/ext/util/*.cmd"]
|
||||
libexec.install %w[bin conf examples hcatalog lib scripts]
|
||||
bin.write_exec_script Dir["#{libexec}/bin/*"]
|
||||
|
||||
Pathname.glob("#{libexec}/bin/*") do |file|
|
||||
next if file.directory?
|
||||
(bin/file.basename).write_env_script file,
|
||||
Language::Java.java_home_env("1.7+").merge(:HIVE_HOME => libexec)
|
||||
end
|
||||
end
|
||||
|
||||
def caveats; <<-EOS.undent
|
||||
Hadoop must be in your path for hive executable to work.
|
||||
After installation, set $HIVE_HOME in your profile:
|
||||
export HIVE_HOME=#{libexec}
|
||||
|
||||
If you want to use HCatalog with Pig, set $HCAT_HOME in your profile:
|
||||
export HCAT_HOME=#{libexec}/hcatalog
|
||||
|
||||
You may need to set JAVA_HOME:
|
||||
export JAVA_HOME="$(/usr/libexec/java_home)"
|
||||
EOS
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue