File tree Expand file tree Collapse file tree 2 files changed +13
-0
lines changed
Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -36,6 +36,7 @@ system = []
3636libc = " 0.2"
3737
3838[build-dependencies ]
39+ pkg-config = " 0.3.30"
3940dirs = " 5.0.1"
4041openblas-build = { version = " 0.10.9" , path = " ../openblas-build" }
4142
Original file line number Diff line number Diff line change @@ -76,12 +76,24 @@ fn macos_system() {
7676}
7777
7878fn main ( ) {
79+ if env:: var ( "DOCS_RS" ) . is_ok ( ) {
80+ return ;
81+ }
7982 let link_kind = if feature_enabled ( "static" ) {
8083 "static"
8184 } else {
8285 "dylib"
8386 } ;
8487 if feature_enabled ( "system" ) {
88+ // Use pkg-config to find OpenBLAS
89+ if pkg_config:: Config :: new ( )
90+ . statik ( feature_enabled ( "static" ) )
91+ . probe ( "openblas" )
92+ . is_ok ( )
93+ {
94+ return ;
95+ }
96+
8597 if cfg ! ( target_os = "windows" ) {
8698 if cfg ! ( target_env = "gnu" ) {
8799 windows_gnu_system ( ) ;
You can’t perform that action at this time.
0 commit comments