-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Can't build on Ubuntu 18.04 #30
Comments
Are you sure |
Sorry, what? Is there documentation about how to compile this? Is this even the right package to satisfy |
In case this clarifies the situation: I'm trying to build another crate, I'm not trying to check out the Git repository of this package and compile it, it's a dependency specified in Cargo. |
Yeah, this is what I was trying to get at. OK, then it’s not relevant. Another thought is that the tool generating |
|
What command did you invoke to compile OpenBLAS? I guess the difference could be seen here. |
I did not invoke any command specifically to compile OpenBLAS. I've been running |
Sorry, I probably misread your comment. You mean you tried to install |
I installed |
I have update the version of OpenBLAS used internally. Could you please give it another try? |
Okay, what I did was to check out a version of
and it compiles! But then when I try to run
and I'm not sure where the responsibility lies between this package and |
You are disabling all features. Try adding |
Adding I would like to emphasize that I didn't write this Cargo.toml, so if the problem is which features |
I mean that default-features = false
features = ["static"] implies that LAPACKE is not build. In any case, if you want to use |
The reason I was changing its Cargo.toml was to attempt to use the new version of openblas-src you mentioned and tell you if it worked. If I just follow the instructions for
And the result I get is this:
|
I have tried to reproduce this in ubuntu:18.04. After starting the container, I did the following: apt-get update
apt-get install -y build-essential curl gfortran git vim
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
export PATH="$PATH:$HOME/.cargo/bin"
export USER=root
cargo new foo
cd foo/
vim Cargo.toml # See below
vim src/main.rs # See below
cargo run
[package]
name = "foo"
version = "0.1.0"
authors = ["root"]
edition = "2018"
[dependencies]
ndarray = "0.13"
ndarray-linalg = "0.12"
openblas-src = "0.7"
extern crate ndarray;
extern crate ndarray_linalg;
extern crate openblas_src;
use ndarray::*;
use ndarray_linalg::*;
// Solve `Ax=b`
fn solve() -> Result<(), error::LinalgError> {
let a: Array2<f64> = random((3, 3));
let b: Array1<f64> = random(3);
let _x = a.solve(&b)?;
Ok(())
}
// Solve `Ax=b` for many b with fixed A
fn factorize() -> Result<(), error::LinalgError> {
let a: Array2<f64> = random((3, 3));
let f = a.factorize_into()?; // LU factorize A (A is consumed)
for _ in 0..10 {
let b: Array1<f64> = random(3);
let _x = f.solve_into(b)?; // solve Ax=b using factorized L, U
}
Ok(())
}
fn main() {
solve().unwrap();
factorize().unwrap();
} It seems to work. Do you have a similar setup? |
I made a project where I ran exactly what you said, and I got the same error about a Makefile. |
Did you also run the commands shown on top, including |
Yes, and build-essential was already installed anyway. |
I didn't run |
Hmm, mystery. Yeah, that My another suggestion is to run the Docker image, ensure that it works, and then compare the packages installed there with the ones you have. |
Another guess is that something is wrong with the unpacked package. All the errors are about missing make-related files. Take a look at what you have in the following folder:
You should see |
|
Yeah, that’s why; the files are not there. Please try to remove the whole |
Hi all, I was having a pretty similar issue. Removing openblas-src from the cargo cache and src and then rebuilding fixed the issue for me on my local machines and remote servers. However, openblas-src still won't build on Travis CI even after clearing the cache there. I've compared my .travis.yml to the openblas-src .travsi.yml and pretty much everything is the same. Cheers, |
I think it might be related to #31. The way the source code of OpenBLAS is handled at the moment is not ideal. |
Please give a try to version 0.9.0. It might reduce confusion with build directories. See also the new feature |
I added openblas-src as a dependency to my Cargo.toml as recommended by this issue: rust-ndarray/ndarray-linalg#171
The output I got is:
The text was updated successfully, but these errors were encountered: