396af0456c
hopefully sixty seconds is enough
61 lines
1.6 KiB
Ruby
61 lines
1.6 KiB
Ruby
class Mal4s < Formula
|
|
desc "Malicious host finder based on gource"
|
|
homepage "https://github.com/secure411dotorg/mal4s/"
|
|
url "https://service.dissectcyber.com/mal4s/mal4s-1.2.8.tar.gz"
|
|
sha256 "1c40ca9d11d113278c4fbd5c7ec9ce0edc78d6c8bd1aa7d85fb6b9473e60f0f1"
|
|
revision 5
|
|
|
|
head "https://github.com/secure411dotorg/mal4s.git"
|
|
|
|
bottle do
|
|
rebuild 1
|
|
sha256 "5c426bbeed255731e25f1b1537adfc2b85f5cb7e3ff0a7be9571e48441f64c42" => :sierra
|
|
sha256 "5560115b97b1534f64bd3a91ff5b5306eafe1f2082f16ed8a68af98fc150416f" => :el_capitan
|
|
sha256 "4a52fb4aa8e7ceaae4e6235c528f0f1b28b80b438b4543745ec9e48f0009dc88" => :yosemite
|
|
end
|
|
|
|
depends_on "pkg-config" => :build
|
|
depends_on "autoconf" => :build
|
|
depends_on "automake" => :build
|
|
depends_on "libtool" => :build
|
|
depends_on "glm" => :build
|
|
depends_on "glew"
|
|
depends_on "jpeg"
|
|
depends_on "pcre"
|
|
depends_on "sdl2"
|
|
depends_on "sdl2_image"
|
|
depends_on "sdl2_mixer"
|
|
depends_on "freetype"
|
|
depends_on :x11 => :optional
|
|
|
|
if MacOS.version < :mavericks
|
|
depends_on "boost" => "c++11"
|
|
else
|
|
depends_on "boost"
|
|
end
|
|
|
|
needs :cxx11
|
|
|
|
def install
|
|
ENV.cxx11
|
|
|
|
args = ["--disable-dependency-tracking",
|
|
"--prefix=#{prefix}"]
|
|
args << "--without-x" if build.without? "x11"
|
|
system "autoreconf", "-f", "-i"
|
|
system "./configure", *args
|
|
system "make", "install"
|
|
end
|
|
|
|
test do
|
|
begin
|
|
pid = fork do
|
|
exec bin/"mal4s", "-t", "2", "-o", "out", pkgshare/"sample--newns.mal4s"
|
|
end
|
|
sleep 60
|
|
assert File.exist?("out"), "Failed to output PPM stream!"
|
|
ensure
|
|
Process.kill("TERM", pid)
|
|
end
|
|
end
|
|
end
|