diff options
| author | Dominyk Tiller | 2015-03-12 00:45:52 +0000 |
|---|---|---|
| committer | Mike McQuaid | 2015-03-12 08:21:55 +0000 |
| commit | 4e1f1781904f7afbf947392fd9d98b52f47b2d0f (patch) | |
| tree | 7140291547484d5a031d6bf24695686d1c9131b2 /Library | |
| parent | 99795d4c7fc366bf512f0610117397185b57d499 (diff) | |
| download | homebrew-4e1f1781904f7afbf947392fd9d98b52f47b2d0f.tar.bz2 | |
snort: install etc files
For some reason, snort’s `make install` isn’t installing the files in
`etc` even though upstream pretty much vouch for how useful they can
be. This fixes that.
Closes #37609.
Closes #37614.
Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Formula/snort.rb | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/Library/Formula/snort.rb b/Library/Formula/snort.rb index 1073afb28..c0b341f89 100644 --- a/Library/Formula/snort.rb +++ b/Library/Formula/snort.rb @@ -1,9 +1,7 @@ -require "formula" - class Snort < Formula homepage "https://www.snort.org" url "https://www.snort.org/downloads/snort/snort-2.9.7.0.tar.gz" - sha1 "29eddcfaf8a4d02a4d68d88fa97c0275e4f0cc75" + sha256 "9738afea45d20b7f77997cc00055e7dd70f6aea0101209d87efec4bc4eace49b" bottle do cellar :any @@ -19,13 +17,16 @@ class Snort < Formula depends_on "pcre" depends_on "openssl" - option "enable-debug", "Compile Snort with --enable-debug and --enable-debug-msgs" + option "with-debug", "Compile Snort with debug options enabled" + + deprecated_option "enable-debug" => "with-debug" def install openssl = Formula["openssl"] args = %W[ --prefix=#{prefix} + --sysconfdir=#{etc}/snort --disable-dependency-tracking --disable-silent-rules --enable-gre @@ -41,7 +42,7 @@ class Snort < Formula --enable-flexresp3 ] - if build.include? "enable-debug" + if build.with? "debug" args << "--enable-debug" args << "--enable-debug-msgs" else @@ -50,6 +51,9 @@ class Snort < Formula system "./configure", *args system "make", "install" + + rm Dir[buildpath/"etc/Makefile*"] + (etc+"snort").install Dir[buildpath/"etc/*"] end def caveats; <<-EOS.undent @@ -59,4 +63,8 @@ class Snort < Formula or you could create a startup item to do this for you. EOS end + + test do + system bin/"snort", "-V" + end end |
