forked from ahmadia/homebrew-science
-
Notifications
You must be signed in to change notification settings - Fork 0
/
diamond.rb
29 lines (23 loc) · 806 Bytes
/
diamond.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
class Diamond < Formula
homepage "http://ab.inf.uni-tuebingen.de/software/diamond/"
# doi "10.1038/nmeth.3176"
# tag "bioinformatics"
url "https://github.com/bbuchfink/diamond/archive/v0.7.7.tar.gz"
sha256 "e5be7ea7e35d32bbe7c66d767e0a4e7c5a7482ee44e35cdadf84f207295e6e6d"
# Fix fatal error: 'omp.h' file not found
needs :openmp
depends_on "boost"
def install
Dir.chdir("src") do
inreplace "Makefile", "-Iboost/include", "-I#{Formula["boost"].include}"
inreplace "Makefile", "LIBS=-l", "LIBS=-L#{Formula["boost"].lib} -l"
inreplace "Makefile", "-lboost_thread", "-lboost_thread-mt"
system "make"
end
bin.install "bin/diamond"
doc.install "README.rst"
end
test do
assert_match "gapextend", shell_output("diamond -h 2>&1", 0)
end
end