diff options
| author | Arthur Liu | 2015-01-25 09:49:25 +1100 |
|---|---|---|
| committer | Misty De Meo | 2015-01-24 23:45:47 -0800 |
| commit | af2839cb97f8f6775ea8b9e567da4ece62cc4c72 (patch) | |
| tree | 8d5687709def9179930bcaddea1a4d201a6c507b /Library/Formula/libforensic1394.rb | |
| parent | c1dfdba18bcfeb1c34bd1077a412f7e38220c6d8 (diff) | |
| download | homebrew-af2839cb97f8f6775ea8b9e567da4ece62cc4c72.tar.bz2 | |
libforensic1394 0.2 (new formula)
Diffstat (limited to 'Library/Formula/libforensic1394.rb')
| -rw-r--r-- | Library/Formula/libforensic1394.rb | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/Library/Formula/libforensic1394.rb b/Library/Formula/libforensic1394.rb new file mode 100644 index 000000000..7632ff4a5 --- /dev/null +++ b/Library/Formula/libforensic1394.rb @@ -0,0 +1,29 @@ +class Libforensic1394 < Formula + homepage "https://freddie.witherden.org/tools/libforensic1394/" + url "https://freddie.witherden.org/tools/libforensic1394/releases/libforensic1394-0.2.tar.gz" + sha1 "179526652977c291303e4f7edc3c7ed487eb0eca" + head "git://git.freddie.witherden.org/forensic1394.git" + + depends_on "cmake" => :build + + def install + system "cmake", ".", *std_cmake_args + system "make", "install" + end + + test do + (testpath/"test.c").write <<-EOS.undent + #include <assert.h> + #include <forensic1394.h> + int main() { + forensic1394_bus *bus; + bus = forensic1394_alloc(); + assert(NULL != bus); + forensic1394_destroy(bus); + return 0; + } + EOS + system ENV.cc, "test.c", "-L#{lib}", "-lforensic1394", "-o", "test" + system "./test" + end +end |
