diff options
author | Jan Malakhovski <oxij@oxij.org> | 2019-02-03 15:32:15 +0000 |
---|---|---|
committer | Jan Malakhovski <oxij@oxij.org> | 2019-02-03 15:32:15 +0000 |
commit | 31aa884b7f9108103e244ade50fe3c9ce4d6b9c3 (patch) | |
tree | d5128861ff53b8bffb2a70fc8c2422b6290b5194 /pkgs | |
parent | 49148a3ea264bf89db13879c6f3bbeba43dad1bb (diff) | |
download | nixpkgs-31aa884b7f9108103e244ade50fe3c9ce4d6b9c3.tar nixpkgs-31aa884b7f9108103e244ade50fe3c9ce4d6b9c3.tar.gz nixpkgs-31aa884b7f9108103e244ade50fe3c9ce4d6b9c3.tar.bz2 nixpkgs-31aa884b7f9108103e244ade50fe3c9ce4d6b9c3.tar.lz nixpkgs-31aa884b7f9108103e244ade50fe3c9ce4d6b9c3.tar.xz nixpkgs-31aa884b7f9108103e244ade50fe3c9ce4d6b9c3.tar.zst nixpkgs-31aa884b7f9108103e244ade50fe3c9ce4d6b9c3.zip |
caffe: move defaults to package file
Diffstat (limited to 'pkgs')
-rw-r--r-- | pkgs/applications/science/math/caffe/default.nix | 6 | ||||
-rw-r--r-- | pkgs/top-level/all-packages.nix | 12 |
2 files changed, 7 insertions, 11 deletions
diff --git a/pkgs/applications/science/math/caffe/default.nix b/pkgs/applications/science/math/caffe/default.nix index e56c63e01bf..c0c26d6e453 100644 --- a/pkgs/applications/science/math/caffe/default.nix +++ b/pkgs/applications/science/math/caffe/default.nix @@ -1,4 +1,4 @@ -{ stdenv, lib, runCommand +{ config, stdenv, lib, runCommand , fetchFromGitHub , fetchurl , cmake @@ -13,8 +13,8 @@ , Accelerate, CoreGraphics, CoreVideo , lmdbSupport ? true, lmdb , leveldbSupport ? true, leveldb, snappy -, cudaSupport ? stdenv.isLinux, cudatoolkit -, cudnnSupport ? false, cudnn ? null +, cudaSupport ? config.cudaSupport or false, cudatoolkit +, cudnnSupport ? cudaSupport, cudnn ? null , ncclSupport ? false, nccl ? null , pythonSupport ? false, python ? null, numpy ? null }: diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 23d20a9682e..4a87efeded7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -21850,20 +21850,16 @@ in ### SCIENCE / MATH - caffe = callPackage ../applications/science/math/caffe rec { - cudaSupport = config.caffe.cudaSupport or config.cudaSupport or false; - cudnnSupport = cudaSupport; - # Used only for image loading. - opencv3 = opencv3WithoutCuda; + caffe = callPackage ../applications/science/math/caffe ({ + opencv3 = opencv3WithoutCuda; # Used only for image loading. inherit (darwin.apple_sdk.frameworks) Accelerate CoreGraphics CoreVideo; - }; + } // (config.caffe or {})); caffe2 = callPackage ../development/libraries/science/math/caffe2 (rec { inherit (python36Packages) python future six numpy pydot; protobuf = protobuf3_1; python-protobuf = python36Packages.protobuf.override { inherit protobuf; }; - # Used only for image loading. - opencv3 = opencv3WithoutCuda; + opencv3 = opencv3WithoutCuda; # Used only for image loading. }); cntk = callPackage ../applications/science/math/cntk rec { |