Last active
          May 23, 2018 18:50 
        
      - 
      
- 
        Save dlo/2d1d9aeb78d7e1f2d584cc03848632f0 to your computer and use it in GitHub Desktop. 
Revisions
- 
        dlo revised this gist May 23, 2018 . 1 changed file with 0 additions and 8 deletions.There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -53,10 +53,6 @@ def install ENV["JAVA_HOME"] = "/Library/Java/JavaVirtualMachines/jdk1.8.0_162.jdk/Contents/Home" ENV["OPENSSL_ROOT_DIR"] = Formula["openssl"].opt_include system "mvn", "package", "-Pdist,native", "-DskipTests", "-Dtar", "-Dmaven.javadoc.skip=true" cd "hadoop-dist/target/hadoop-2.4.1" do @@ -66,8 +62,4 @@ def install sbin.write_exec_script Dir["#{libexec}/sbin/*"] end end end 
- 
        dlo revised this gist May 23, 2018 . No changes.There are no files selected for viewing
- 
        dlo revised this gist May 23, 2018 . 1 changed file with 3 additions and 1 deletion.There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -18,7 +18,6 @@ class HadoopAT24 < Formula conflicts_with "yarn", :because => "both install `yarn` binaries" patch do # https://gauravkohli.com/tag/hadoop-2-5-1/ # https://issues.apache.org/jira/browse/YARN-2161 @@ -40,6 +39,7 @@ class HadoopAT24 < Formula sha256 "d89f3fac5b523fd752f8c7c8e783e1c9cc6727771b33b530db46a5a318624285" end ## See BUILDING in hadoop source. def caveats; <<~EOS You may need to run the following for the build to succeed: @@ -49,7 +49,9 @@ def caveats; <<~EOS end def install # Update to the location of `/usr/libexec/java_home -v 1.8` ENV["JAVA_HOME"] = "/Library/Java/JavaVirtualMachines/jdk1.8.0_162.jdk/Contents/Home" ENV["OPENSSL_ROOT_DIR"] = Formula["openssl"].opt_include # rm_f Dir["bin/*.cmd", "sbin/*.cmd", "libexec/*.cmd", "etc/hadoop/*.cmd"] # libexec.install %w[bin sbin libexec share etc] 
- 
        dlo revised this gist May 23, 2018 . No changes.There are no files selected for viewing
- 
        dlo created this gist May 23, 2018 .There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,71 @@ class HadoopAT24 < Formula desc "Framework for distributed processing of large data sets" homepage "https://hadoop.apache.org/" url "https://archive.apache.org/dist/hadoop/common/hadoop-2.4.1/hadoop-2.4.1-src.tar.gz" sha256 "09f897738e9d34bceb7e7d4494bbc75e363fb32993f56dc5a6de8aab3419b990" env :std bottle :unneeded depends_on :java => "1.8+" depends_on "maven" => :build depends_on "cmake" => :build depends_on "zlib" => :build depends_on "[email protected]" => :build depends_on "snappy" => :build depends_on "openssl" conflicts_with "yarn", :because => "both install `yarn` binaries" ## See BUILDING file in hadoop repo patch do # https://gauravkohli.com/tag/hadoop-2-5-1/ # https://issues.apache.org/jira/browse/YARN-2161 # https://issues.apache.org/jira/secure/attachment/12650514/YARN-2161.v1.patch url "https://gist.github.com/dlo/765fc37d83d65be31ec33a18d82d1c32/raw/5124604bc037c8c4476bde3d33abe285421ce3ec/configuration.c.patch" sha256 "1c00b7a0165530a52f23c72173c0d183079a91df34bb5961b9ba2b9503dfd74c" end patch do # https://issues.apache.org/jira/browse/HADOOP-10699 # https://issues.apache.org/jira/secure/attachment/12617363/HADOOP-9648.v2.patch url "https://gist.github.com/dlo/765fc37d83d65be31ec33a18d82d1c32/raw/db1cdafffad48696088fb27ff998461abda8b1eb/JniBasedUnixGroupsNetgroupMapping.c.patch" sha256 "9550429d306ccc6b458c11c5af629c76df48c3163c0d82056a198300e132cc4f" end patch do # http://sunnytalkstech.blogspot.in/2011/08/maven-dependency-for-toolsjar-in-jdk7.html url "https://gist.github.com/dlo/765fc37d83d65be31ec33a18d82d1c32/raw/a7ebd3fba5ad8609c9e97af703d21fbccf703022/pom.xml.patch" sha256 "d89f3fac5b523fd752f8c7c8e783e1c9cc6727771b33b530db46a5a318624285" end def caveats; <<~EOS You may need to run the following for the build to succeed: sudo mkdir `/usr/libexec/java_home`/Classes sudo ln -s `/usr/libexec/java_home`/lib/tools.jar `/usr/libexec/java_home`/Classes/classes.jar EOS end def install ENV["JAVA_HOME"] = "/Library/Java/JavaVirtualMachines/jdk1.8.0_162.jdk/Contents/Home" ENV["OPENSSL_ROOT_DIR"] = Formula["openssl"].opt_include # rm_f Dir["bin/*.cmd", "sbin/*.cmd", "libexec/*.cmd", "etc/hadoop/*.cmd"] # libexec.install %w[bin sbin libexec share etc] # bin.write_exec_script Dir["#{libexec}/bin/*"] # sbin.write_exec_script Dir["#{libexec}/sbin/*"] system "mvn", "package", "-Pdist,native", "-DskipTests", "-Dtar", "-Dmaven.javadoc.skip=true" cd "hadoop-dist/target/hadoop-2.4.1" do rm_f Dir["bin/*.cmd", "sbin/*.cmd", "libexec/*.cmd", "etc/hadoop/*.cmd"] libexec.install %w[bin sbin include lib libexec share etc] bin.write_exec_script Dir["#{libexec}/bin/*"] sbin.write_exec_script Dir["#{libexec}/sbin/*"] end end # test do # system bin/"hadoop", "fs", "-ls" # end end