2011-10-02 18:26:42 +00:00
|
|
|
require 'formula'
|
|
|
|
|
|
|
|
class Chkrootkit < Formula
|
|
|
|
homepage 'http://www.chkrootkit.org/'
|
2012-09-06 03:37:46 +00:00
|
|
|
url 'http://ftp.de.debian.org/debian/pool/main/c/chkrootkit/chkrootkit_0.49.orig.tar.gz'
|
|
|
|
sha1 'cec1a3c482b95b20d3a946b07fffb23290abc4a6'
|
2011-10-02 18:26:42 +00:00
|
|
|
|
|
|
|
def install
|
2011-10-03 01:06:53 +00:00
|
|
|
chmod 0644, 'Makefile' # Makefile is read-only
|
2011-10-02 18:26:42 +00:00
|
|
|
|
|
|
|
inreplace 'Makefile' do |s|
|
2011-10-03 01:06:53 +00:00
|
|
|
s.remove_make_var! 'STATIC'
|
2011-10-02 18:26:42 +00:00
|
|
|
end
|
|
|
|
|
2012-02-10 02:56:21 +00:00
|
|
|
system "make", "CC=#{ENV.cc}",
|
|
|
|
"CFLAGS=#{ENV.cflags}",
|
|
|
|
"sense", "all"
|
2011-10-02 18:26:42 +00:00
|
|
|
|
2012-02-10 02:56:21 +00:00
|
|
|
sbin.install %w{check_wtmpx chkdirs chklastlog chkproc
|
|
|
|
chkrootkit chkutmp chkwtmp ifpromisc
|
|
|
|
strings-static}
|
|
|
|
doc.install %w{README README.chklastlog README.chkwtmp}
|
2011-10-02 18:26:42 +00:00
|
|
|
end
|
|
|
|
|
2013-03-24 05:07:42 +00:00
|
|
|
test do
|
|
|
|
`#{sbin}/chkrootkit -V 2>&1`.strip == "chkrootkit version #{version}"
|
2011-10-02 18:26:42 +00:00
|
|
|
end
|
|
|
|
end
|