diff options
| author | Marc Abramowitz | 2011-12-21 10:43:37 -0800 |
|---|---|---|
| committer | Adam Vandenberg | 2012-01-22 09:39:01 -0800 |
| commit | 580a3ab9f5f43f31bfcf4f8edb688d37f33e67ee (patch) | |
| tree | 53f04b11f65f6a411c0e2b5f7b4ad282896eb292 /Library/Formula | |
| parent | 362d7f7a6287a2281f5932bf4aab04458f397cac (diff) | |
| download | homebrew-580a3ab9f5f43f31bfcf4f8edb688d37f33e67ee.tar.bz2 | |
justniffer 0.5.11
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library/Formula')
| -rw-r--r-- | Library/Formula/justniffer.rb | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/Library/Formula/justniffer.rb b/Library/Formula/justniffer.rb new file mode 100644 index 000000000..8799dbf4e --- /dev/null +++ b/Library/Formula/justniffer.rb @@ -0,0 +1,59 @@ +# vim:set sts=2 sw=2: + +require 'formula' + +class Justniffer < Formula + url 'http://downloads.sourceforge.net/project/justniffer/justniffer/justniffer%200.5.11/justniffer_0.5.11.tar.gz' + homepage 'http://justniffer.sourceforge.net/' + md5 '8545b817c479444b01e74aa7b79fd2c6' + + depends_on "boost" + + # Patch lib/libnids-1.21_patched/configure.gnu so that CFLAGS and/or + # CXXFLAGS with multiple words doesn't cause an error -- e.g.: + # + # === configuring in lib/libnids-1.21_patched + # (/private/tmp/homebrew-justniffer-0.5.11-yNmj/justniffer-0.5.11/lib/libnids-1.21_patched) + # configure: running /bin/sh ./configure.gnu --disable-option-checking + # '--prefix=/usr/local/Cellar/justniffer/0.5.11' 'CXX=/usr/bin/llvm-g++' + # 'CXXFLAGS=-O3 -w -pipe -march=core2 -msse4' 'CC=/usr/bin/llvm-gcc' + # 'CFLAGS=-O3 -w -pipe -march=core2 -msse4' --cache-file=/dev/null--srcdir=. + # configure: error: unrecognized option: `-w' + # Try `./configure --help' for more information + # configure: error: ./configure.gnu failed for lib/libnids-1.21_patched + # + # I submitted this patch to the upstream author, Oreste Notelli, on + # 2011-12-22, so this patch will probably not be necessary with future + # justniffer versions after 0.5.11. + def patches + DATA + end + + def install + system "./configure --prefix=#{prefix}" + system "make install" + end + + def test + system "justniffer --version | grep '^justniffer'" + end + + def caveats; <<-EOS.undent + Sample invocation to get you started: + justniffer -i en1 -p "port 80" + + "en1" is my wireless inteface; "en0" is Ethernet; see output of ifconfig + EOS + end +end + + +__END__ +--- a/lib/libnids-1.21_patched/configure.gnu 2011-12-21 22:48:23.000000000 -0800 ++++ b/lib/libnids-1.21_patched/configure.gnu 2011-12-21 22:54:37.000000000 -0800 +@@ -1,3 +1,3 @@ + #!/bin/sh + +-./configure --disable-libnet --disable-libglib $@ +\ No newline at end of file ++./configure --disable-libnet --disable-libglib "$@" |
