forked from ahmadia/homebrew-science
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbowtie.rb
47 lines (38 loc) · 1.24 KB
/
bowtie.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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
require "formula"
class Bowtie < Formula
homepage "http://bowtie-bio.sourceforge.net/index.shtml"
#doi "10.1186/gb-2009-10-3-r25"
url "https://github.com/BenLangmead/bowtie/archive/v1.0.1.tar.gz"
sha256 "aedcada44803dbe6e3e2fa7bd13a040733fac95032b4102918612310f5bbaa54"
head "https://github.com/BenLangmead/bowtie.git"
fails_with :clang do
build 503
cause %q[error: reference to 'lock_guard' is ambiguous. See #476]
end
def install
inreplace "Makefile", "-Wl,-macosx_version_min,10.6", ""
system "make", "allall"
# preserve directory structure for tests/scripts
libexec.install %W[
bowtie bowtie-debug
bowtie-build bowtie-build-debug
bowtie-inspect bowtie-inspect-debug
scripts
genomes indexes reads
]
bin.install_symlink %W[
#{libexec}/bowtie
#{libexec}/bowtie-build
#{libexec}/bowtie-inspect
]
doc.install %W[AUTHORS LICENSE MANUAL MANUAL.markdown NEWS TUTORIAL]
inreplace libexec/"scripts/test/simple_tests.pl" do |s|
s.gsub! "$bowtie = \"\"", "$bowtie = \"#{bin}/bowtie\""
s.gsub! "$bowtie_build = \"\"", "$bowtie_build = \"#{bin}/bowtie-build\""
end
end
test do
cd libexec
system "sh", "./scripts/test/all.sh"
end
end