squid 3.5.11

I can't get the test to work under sandbox at all, even after an hour of playing
with configuration files, so I've killed it with an explanatory in-formula note.

Closes Homebrew/homebrew#43631.
Closes Homebrew/homebrew#44348.

Closes Homebrew/homebrew#45897.

Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>
This commit is contained in:
Dominyk Tiller 2015-11-11 20:33:51 +00:00
parent 8de6247711
commit b4d6765243

View file

@ -1,8 +1,8 @@
class Squid < Formula class Squid < Formula
desc "Advanced proxy caching server for HTTP, HTTPS, FTP, and Gopher" desc "Advanced proxy caching server for HTTP, HTTPS, FTP, and Gopher"
homepage "http://www.squid-cache.org/" homepage "http://www.squid-cache.org/"
url "http://www.squid-cache.org/Versions/v3/3.5/squid-3.5.7.tar.xz" url "http://www.squid-cache.org/Versions/v3/3.5/squid-3.5.11.tar.xz"
sha256 "ec6f861bddee007b1dd320667a26ddc9ff76847bbe4cbb59c0134588e65c8699" sha256 "c26211b8e349fd9a5fd357da33074ff6523c111024dd3a5a1f77153538aa40cf"
bottle do bottle do
sha256 "86efd34595ad766563daca8e7138af030b7c3f5dab158813b5d31726fdce7d01" => :el_capitan sha256 "86efd34595ad766563daca8e7138af030b7c3f5dab158813b5d31726fdce7d01" => :el_capitan
@ -24,6 +24,7 @@ class Squid < Formula
--disable-dependency-tracking --disable-dependency-tracking
--prefix=#{prefix} --prefix=#{prefix}
--localstatedir=#{var} --localstatedir=#{var}
--sysconfdir=#{etc}
--enable-ssl --enable-ssl
--enable-ssl-crtd --enable-ssl-crtd
--disable-eui --disable-eui
@ -61,16 +62,11 @@ class Squid < Formula
end end
test do test do
pid = fork do # This test should start squid and then check it runs correctly.
exec "#{sbin}/squid" # However currently dies under the sandbox and "Current Directory"
end # seems to be set hard on HOMEBREW_PREFIX/var/cache/squid.
sleep 2 # https://github.com/Homebrew/homebrew/pull/44348#issuecomment-143477353
# If you can fix this, please submit a PR. Thank you!
begin assert_match version.to_s, shell_output("#{sbin}/squid -v")
system "#{sbin}/squid", "-k", "check"
ensure
exec "#{sbin}/squid -k interrupt"
Process.wait(pid)
end
end end
end end