Skip to content

Commit 8bce8cc

Browse files
authored
Merge pull request #959 from rust-ndarray/blas-test
Update blas test for blas-src 0.8
2 parents 5b8f6de + 86accd6 commit 8bce8cc

File tree

5 files changed

+27
-13
lines changed

5 files changed

+27
-13
lines changed

README.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,12 +133,13 @@ explicitly including it in your code::
133133
extern crate blas_src;
134134

135135
The following versions have been verified to work together. For ndarray 0.15 or later,
136-
there is no tight coupling to the ``blas-src`` version, so any version should in theory work.
136+
there is no tight coupling to the ``blas-src`` version, so version selection is more flexible.
137137

138138
=========== ============ ================ ==============
139139
``ndarray`` ``blas-src`` ``openblas-src`` ``netlib-src``
140140
=========== ============ ================ ==============
141-
0.15 0.7.0 0.9.0 0.8.0
141+
0.15 0.8 0.10 0.8
142+
0.15 0.7 0.9 0.8
142143
0.14 0.6.1 0.9.0
143144
0.13 0.2.0 0.6.0
144145
=========== ============ ================ ==============

scripts/all-tests.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ cargo test --verbose --features "$FEATURES"
1515
cargo test --manifest-path=ndarray-rand/Cargo.toml --no-default-features --verbose
1616
cargo test --manifest-path=ndarray-rand/Cargo.toml --features quickcheck --verbose
1717
cargo test --manifest-path=xtest-serialization/Cargo.toml --verbose
18-
cargo test --manifest-path=xtest-blas/Cargo.toml --verbose
18+
cargo test --manifest-path=xtest-blas/Cargo.toml --verbose --features openblas-system
1919
cargo test --examples
2020
CARGO_TARGET_DIR=target/ cargo test --manifest-path=xtest-numeric/Cargo.toml --verbose
2121
CARGO_TARGET_DIR=target/ cargo test --manifest-path=xtest-numeric/Cargo.toml --verbose --features test_blas

xtest-blas/Cargo.toml

Lines changed: 15 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,24 @@ publish = false
88
test = false
99

1010
[dev-dependencies]
11-
ndarray = { path = "../", features = ["approx", "blas"] }
12-
1311
approx = "0.4"
1412
defmac = "0.2"
1513
num-traits = "0.2"
1614

17-
blas-src = { version = "0.7.0", features = ["openblas"] }
18-
openblas-src = { version = "0.9.0", features = ["system"] }
15+
[dependencies]
16+
ndarray = { path = "../", features = ["approx", "blas"] }
17+
18+
blas-src = { version = "0.8", optional = true }
1919

20-
#blas-src = { version = "0.7.0", features = ["netlib"] }
21-
#netlib-src = { version = "0.8.0", default-features = false, features = ["cblas", "system"] }
20+
openblas-src = { version = "0.10", optional = true }
21+
netlib-src = { version = "0.8", optional = true }
22+
blis-src = { version = "0.2", features = ["system"], optional = true }
2223

23-
#blas-src = { version = "0.7.0", features = ["blis"] }
24-
#blis-src = { version = "0.2.0", features = ["system"] }
24+
[features]
25+
# Just for making an example and to help testing, , multiple different possible
26+
# configurations are selectable here.
27+
openblas-system = ["blas-src", "blas-src/openblas", "openblas-src/system"]
28+
openblas-cache = ["blas-src", "blas-src/openblas", "openblas-src/cache"]
29+
netlib = ["blas-src", "blas-src/netlib"]
30+
netlib-system = ["blas-src", "blas-src/netlib", "netlib-src/system"]
31+
blis-system = ["blas-src", "blas-src/blis", "blis-src/system"]

xtest-blas/src/lib.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
2+
#[cfg(not(feature = "blas-src"))]
3+
compile_error!("Missing backend: could not compile.
4+
Help: For this testing crate, select one of the blas backend features, for example \
5+
openblas-system");
6+

xtest-numeric/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ ndarray = { path = "..", features = ["approx"] }
1010
ndarray-rand = { path = "../ndarray-rand/" }
1111
rand_distr = "0.4"
1212

13-
blas-src = { optional = true, version = "0.7.0", default-features = false, features = ["openblas"] }
14-
openblas-src = { optional = true, version = "0.9", default-features = false, features = ["cblas", "system"] }
13+
blas-src = { optional = true, version = "0.8", default-features = false, features = ["openblas"] }
14+
openblas-src = { optional = true, version = "0.10", default-features = false, features = ["cblas", "system"] }
1515

1616
[dependencies.rand]
1717
version = "0.8.0"

0 commit comments

Comments
 (0)