-
Notifications
You must be signed in to change notification settings - Fork 35
/
suite-sparse-julia.rb
36 lines (29 loc) · 1.15 KB
/
suite-sparse-julia.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
require 'formula'
class SuiteSparseJulia < Formula
homepage 'http://faculty.cse.tamu.edu/davis/suitesparse.html'
url 'http://faculty.cse.tamu.edu/davis/SuiteSparse/SuiteSparse-4.4.6.tar.gz'
sha256 '7f22509d87ada8506580d537efde79cf90e28e228355c18b8bf603aad1a2d7b6'
revision 3
bottle do
root_url 'https://juliabottles.s3.amazonaws.com'
cellar :any_skip_relocation
sha256 "e428e61322e9f0a35170b75f2e5c74784b417c920e6367197733c850373bfdff" => :sierra
sha256 "ecb71d3b9710795e8d31f457cce4c2274b714adccd25a711f26943c460e9f97e" => :el_capitan
end
keg_only 'Conflicts with suite-sparse in homebrew-science.'
depends_on "tbb" => :optional
depends_on "staticfloat/julia/openblas-julia"
def install
# SuiteSparse doesn't like to build in parallel
ENV.deparallelize
makevars = ["BLAS=-lopenblas", "LAPACK=-lopenblas"]
makevars << "INSTALL_LIB='#{lib}'"
makevars << "INSTALL_INCLUDE='#{include}'"
makevars << "SPQR_CONFIG='-DNCAMD -DNPARTITION'"
makevars << "CHOLMOD_CONFIG='-DNCAMD -DNPARTITION'"
system "make", "library", *makevars
lib.mkpath
include.mkpath
system "make", "install", *makevars
end
end