-
-
Notifications
You must be signed in to change notification settings - Fork 15.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BLAS/LAPACK fixup and expand docs #85799
Conversation
To match the soname, we need to use libblas.so.3, liblapack.so.3.
To avoid segmentation fault on MKL, we need to use the CBLAS ABI. Normally, scipy will autodetect this, but here we don’t link using the ‘libmkl_rt.so’ name. So we need to manually set this. See https://github.com/scipy/scipy/blob/50012918db47f0ec3418dd53f0277daa589f82e3/doc/source/building/linux.rst#fortran-abi-mismatch
This adds some more information to the documentation as well as addressing review from NixOS#85636.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Diff LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Found an issue w/ the docs; otherwise LGTM. Currently compiling with and without mkl
in the stack and will report back when it's done.
ln -s $out/lib/libopenblas${stdenv.hostPlatform.extensions.sharedLibrary} $out/lib/libblas${stdenv.hostPlatform.extensions.sharedLibrary}${stdenv.lib.optionalString stdenv.hostPlatform.isLinux ".3"} | ||
ln -s $out/lib/libopenblas${stdenv.hostPlatform.extensions.sharedLibrary} $out/lib/libcblas${stdenv.hostPlatform.extensions.sharedLibrary}${stdenv.lib.optionalString stdenv.hostPlatform.isLinux ".3"} | ||
ln -s $out/lib/libopenblas${stdenv.hostPlatform.extensions.sharedLibrary} $out/lib/liblapack${stdenv.hostPlatform.extensions.sharedLibrary}${stdenv.lib.optionalString stdenv.hostPlatform.isLinux ".3"} | ||
ln -s $out/lib/libopenblas${stdenv.hostPlatform.extensions.sharedLibrary} $out/lib/liblapacke${stdenv.hostPlatform.extensions.sharedLibrary}${stdenv.lib.optionalString stdenv.hostPlatform.isLinux ".3"} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is getting long enough that it might be worth factoring out into a helper var.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes - we can actually use passthru from blas/lapack here without infinite recursion, but it's kind of confusing conceptually
Great, managed to build through most of the scientific computing stack with Just the one documentation fix on |
Since I just had a documentation comment and others have approved the PR, and since it's fixing builds on master and causing a lot of rebuilds, I went ahead and applied my doc update, then merged it so that Hydra can catch up. |
Alright! |
Addresses comments left in #85636.
/cc @drewrisinger @bhipple
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)