phantomjs: remove stable inreplace, fix HEAD build

Closes Homebrew/homebrew#47932.

Signed-off-by: Alex Dunn <dunn.alex@gmail.com>
This commit is contained in:
Alex Dunn 2016-01-10 08:31:08 -08:00
parent fed0045fa4
commit a72046c3ac

View file

@ -17,9 +17,13 @@ class Phantomjs < Formula
depends_on "openssl"
def install
inreplace "src/qt/preconfig.sh", "QT_CFG+=' -openssl -openssl-linked'",
"QT_CFG+=' -openssl -openssl-linked -I #{Formula["openssl"].opt_include} -L #{Formula["openssl"].opt_lib}'"
system "./build.sh", "--confirm", "--jobs", ENV.make_jobs
if build.stable?
system "./build.sh", "--confirm", "--jobs", ENV.make_jobs,
"--qt-config", "-I #{Formula["openssl"].opt_include} -L #{Formula["openssl"].opt_lib}"
else
inreplace "build.py", "/usr/local", HOMEBREW_PREFIX
system "./build.py", "--confirm", "--jobs", ENV.make_jobs
end
bin.install "bin/phantomjs"
(share/"phantomjs").install "examples"
end