From 91a24f08c7f07319fd0f8b7d6eef8506b6e73acb Mon Sep 17 00:00:00 2001 From: Tom Westerhout <14264576+twesterhout@users.noreply.github.com> Date: Wed, 20 Sep 2023 15:10:05 +0200 Subject: [PATCH] arrayfire: explain why 64-bit BLAS is not supported; explain how to use nvidiaComputDrivers --- .../libraries/arrayfire/default.nix | 28 +++++++++++++++---- 1 file changed, 22 insertions(+), 6 deletions(-) diff --git a/pkgs/development/libraries/arrayfire/default.nix b/pkgs/development/libraries/arrayfire/default.nix index 6aa9171fd59f..a75ada8c1eb6 100644 --- a/pkgs/development/libraries/arrayfire/default.nix +++ b/pkgs/development/libraries/arrayfire/default.nix @@ -16,7 +16,6 @@ , lib , libGL , mesa -, openblas , ocl-icd , opencl-clhpp , pkg-config @@ -33,11 +32,29 @@ # OpenCL needs mesa which is broken on Darwin , openclSupport ? !stdenv.isDarwin # This argument lets one run CUDA & OpenCL tests on non-NixOS systems by - # telling Nix where to find the drivers. + # telling Nix where to find the drivers. If you know the version of the + # NVidia driver that is installed on your system, you can do: + # + # arrayfire.override { + # nvidiaComputeDrivers = + # callPackage + # (prev.linuxPackages.nvidiaPackages.mkDriver { + # version = cudaVersion; # our driver version + # sha256_64bit = cudaHash; # sha256 of the .run binary + # useGLVND = false; + # useProfiles = false; + # useSettings = false; + # usePersistenced = false; + # ... + # }) + # { libsOnly = true; }; + # } , nvidiaComputeDrivers ? null }: -# assert blas.isILP64 == false; +# ArrayFire compiles with 64-bit BLAS, but some tests segfault or throw +# exceptions, which means that it isn't really supported yet... +assert blas.isILP64 == false; stdenv.mkDerivation rec { pname = "arrayfire"; @@ -164,7 +181,7 @@ stdenv.mkDerivation rec { ''; buildInputs = [ - # blas + blas boost.dev boost.out clblast @@ -175,11 +192,10 @@ stdenv.mkDerivation rec { forge freeimage gtest - # lapack + lapack libGL ocl-icd opencl-clhpp - openblas span-lite ] ++ lib.optionals cudaSupport [