git.iko.soy/typeable/nixpkgs
on master help sign in
openblas_2_14: init at 0.2.14
commit3e476a73ef455484e7b60a36364bd29fd60bfd4a authorFrederik Rietdijk <fridh@fridh.nl> dateThu 4 Feb 2016, 21:29 (11 years ago) parent63cf61e
2 files changed+67
pkgs/development/libraries/science/math/openblas/0.2.14.nix+65 pkgs/top-level/all-packages.nix+2
pkgs/development/libraries/science/math/openblas/0.2.14.nixnew file+65
@@ -0,0 +1,65 @@
1+{ stdenv, fetchurl, gfortran, perl, which, config, coreutils
2+# Most packages depending on openblas expect integer width to match pointer width,
3+# but some expect to use 32-bit integers always (for compatibility with reference BLAS).
4+, blas64 ? null
5+}:
6+
7+with stdenv.lib;
8+
9+let blas64_ = blas64; in
10+
11+let local = config.openblas.preferLocalBuild or false;
12+ binary =
13+ { i686-linux = "32";
14+ x86_64-linux = "64";
15+ x86_64-darwin = "64";
16+ }."${stdenv.system}" or (throw "unsupported system: ${stdenv.system}");
17+ genericFlags =
18+ [ "DYNAMIC_ARCH=1"
19+ "NUM_THREADS=64"
20+ ];
21+ localFlags = config.openblas.flags or
22+ optionals (hasAttr "target" config.openblas) [ "TARGET=${config.openblas.target}" ];
23+ blas64 = if blas64_ != null then blas64_ else hasPrefix "x86_64" stdenv.system;
24+
25+ version = "0.2.14";
26+in
27+stdenv.mkDerivation {
28+ name = "openblas-${version}";
29+ src = fetchurl {
30+ url = "https://github.com/xianyi/OpenBLAS/archive/v${version}.tar.gz";
31+ sha256 = "2411c4f56f477b42dff54db2b7ffc0b7cf53bb9778d54982595c64cc69c40fc1";
32+ name = "openblas-${version}.tar.gz";
33+ };
34+
35+ inherit blas64;
36+
37+ nativeBuildInputs = optionals stdenv.isDarwin [coreutils] ++ [gfortran perl which];
38+
39+ makeFlags =
40+ (if local then localFlags else genericFlags)
41+ ++
42+ optionals stdenv.isDarwin ["MACOSX_DEPLOYMENT_TARGET=10.9"]
43+ ++
44+ [
45+ "FC=gfortran"
46+ # Note that clang is available through the stdenv on OSX and
47+ # thus is not an explicit dependency.
48+ "CC=${if stdenv.isDarwin then "clang" else "gcc"}"
49+ ''PREFIX="''$(out)"''
50+ "BINARY=${binary}"
51+ "USE_OPENMP=${if stdenv.isDarwin then "0" else "1"}"
52+ "INTERFACE64=${if blas64 then "1" else "0"}"
53+ ];
54+
55+ doCheck = true;
56+ checkTarget = "tests";
57+
58+ meta = with stdenv.lib; {
59+ description = "Basic Linear Algebra Subprograms";
60+ license = licenses.bsd3;
61+ homepage = "https://github.com/xianyi/OpenBLAS";
62+ platforms = platforms.unix;
63+ maintainers = with maintainers; [ ttuegel ];
64+ };
65+}
pkgs/top-level/all-packages.nix+2
@@ -15029,10 +15029,12 @@ let
1502915029 liblbfgs = callPackage ../development/libraries/science/math/liblbfgs { };
1503015030
1503115031 openblas = callPackage ../development/libraries/science/math/openblas { };
15032+ openblas_2_14 = callPackage ../development/libraries/science/math/openblas/0.2.14.nix { };
1503215033
1503315034 # A version of OpenBLAS using 32-bit integers on all platforms for compatibility with
1503415035 # standard BLAS and LAPACK.
1503515036 openblasCompat = openblas.override { blas64 = false; };
15037+ openblasCompat_2_14 = openblas_2_14.override { blas64 = false; };
1503615038
1503715039 openlibm = callPackage ../development/libraries/science/math/openlibm {};
1503815040