diff options
| author | Christian Moritz | 2014-02-20 01:08:37 +0100 | 
|---|---|---|
| committer | Adam Vandenberg | 2014-03-06 22:16:59 -0800 | 
| commit | 46a9af403a733d5332401db2c4abd6c1a7db49d4 (patch) | |
| tree | e50a711cbaadc49a1eb8fcde0ef916080a0ba6f1 /Library/Formula/xulrunner.rb | |
| parent | 8be24fcd3d6f7989a7500ecc8ae067eb5d1f4629 (diff) | |
| download | homebrew-46a9af403a733d5332401db2c4abd6c1a7db49d4.tar.bz2 | |
xulrunner: fix build
* depends_on :xcode
* specify MacOS.sdk_path :python is :build dependency
* ENV.deparallelize
Fixes #26846.
Closes #26862.
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library/Formula/xulrunner.rb')
| -rw-r--r-- | Library/Formula/xulrunner.rb | 36 | 
1 files changed, 19 insertions, 17 deletions
diff --git a/Library/Formula/xulrunner.rb b/Library/Formula/xulrunner.rb index dff054420..bca4e8112 100644 --- a/Library/Formula/xulrunner.rb +++ b/Library/Formula/xulrunner.rb @@ -35,12 +35,12 @@ end  class Xulrunner < Formula    homepage "https://developer.mozilla.org/docs/XULRunner"    url "http://ftp.mozilla.org/pub/mozilla.org/xulrunner/releases/27.0.1/source/xulrunner-27.0.1.source.tar.bz2" -  sha1 'c9c5a6142fc9c50113c18eb8b1fb9249c08c4aac' +  sha1 "c9c5a6142fc9c50113c18eb8b1fb9249c08c4aac"    devel do -    url "http://ftp.mozilla.org/pub/mozilla.org/xulrunner/releases/28.0b3/source/xulrunner-28.0b3.source.tar.bz2" -    sha1 'f35c986e2889dcee1d9f458ff7942ec6d3b1bbe9' -    version '28.0b3' +    url "http://ftp.mozilla.org/pub/mozilla.org/xulrunner/releases/28.0b8/source/xulrunner-28.0b8.source.tar.bz2" +    sha1 "2c2bda033f7ce771b0aff82237551264911a32c3" +    version "28.0b8"    end    head do @@ -51,8 +51,9 @@ class Xulrunner < Formula    end    depends_on :macos => :lion # needs clang++ -  depends_on Python273Requirement -  depends_on :python +  depends_on :xcode +  depends_on :python => :build +  depends_on Python273Requirement => :build    depends_on "gnu-tar" => :build    depends_on "pkg-config" => :build    depends_on "yasm" @@ -65,12 +66,6 @@ class Xulrunner < Formula      cause "Mozilla XULRunner only supports Clang on OS X"    end -  resource "mozconfig" do -    url "https://gist.github.com/chrmoritz/7815762/raw/d1ec6a29fe3ee2e59f39f854371ee9978cdb684a/mozconfig" -    sha1 "af105b46d126ee0b25f2f2487eb2b577725aa3c0" -    version "1.0" -  end -    resource "autoconf213" do      url "http://ftpmirror.gnu.org/autoconf/autoconf-2.13.tar.gz"      mirror "http://ftp.gnu.org/gnu/autoconf/autoconf-2.13.tar.gz" @@ -86,12 +81,21 @@ class Xulrunner < Formula        ENV["AUTOCONF"] = buildpath/"ac213/bin/autoconf213"      end -    # build xulrunner to objdir and disable tests, updater.app and crashreporter.app -    buildpath.install resource("mozconfig") +    # build xulrunner to objdir and disable tests, updater.app and crashreporter.app, specify sdk path +    (buildpath/"mozconfig").write <<-EOS.undent +      . $topsrcdir/xulrunner/config/mozconfig +      mk_add_options MOZ_OBJDIR=objdir +      ac_add_options --disable-tests +      ac_add_options --disable-updater +      ac_add_options --disable-crashreporter +      ac_add_options --with-macos-sdk=#{MacOS.sdk_path} +    EOS      # fixed usage of bsdtar with unsupported parameters (replaced with gnu-tar)      inreplace "toolkit/mozapps/installer/packager.mk", "$(TAR) -c --owner=0 --group=0 --numeric-owner",                "#{Formula["gnu-tar"].bin}/gtar -c --owner=0 --group=0 --numeric-owner" +    # nss is not fully parallel build safe (fixes rare ld: library not found for -lplc4 issues) +    ENV.deparallelize      system "make", "-f", "client.mk", "build"      system "make", "-f", "client.mk", "package" @@ -99,10 +103,8 @@ class Xulrunner < Formula      if build.head?        # update HEAD version here with every version bump        tar_path = "objdir/dist/xulrunner-30.0a1.en-US.mac64.tar.bz2" -    elsif build.devel? -      tar_path = "objdir/dist/xulrunner-#{version.to_s[/\d+.\d/]}.en-US.mac64.tar.bz2"      else -      tar_path = "objdir/dist/xulrunner-#{version}.en-US.mac64.tar.bz2" +      tar_path = "objdir/dist/xulrunner-#{version.to_s[/\d+\.\d+(\.\d+)?/]}.en-US.mac64.tar.bz2"      end      system "tar", "-xvj", "-C", frameworks, "-f", tar_path  | 
