about summary refs log tree commit diff
path: root/pkgs/development/python-modules/Theano/default.nix
diff options
context:
space:
mode:
authorDmitry Kalinkin <dmitry.kalinkin@gmail.com>2019-12-23 17:55:13 -0500
committerDmitry Kalinkin <dmitry.kalinkin@gmail.com>2019-12-23 18:08:28 -0500
commitd4f1fa709cd1ac66a0a1299803c5bd8c32758044 (patch)
tree558196150b6165a8ccc04de8faac16e4577c9162 /pkgs/development/python-modules/Theano/default.nix
parent3bb44f0f9dcea06dd9927b608b8dea0e25c00d26 (diff)
downloadnixlib-d4f1fa709cd1ac66a0a1299803c5bd8c32758044.tar
nixlib-d4f1fa709cd1ac66a0a1299803c5bd8c32758044.tar.gz
nixlib-d4f1fa709cd1ac66a0a1299803c5bd8c32758044.tar.bz2
nixlib-d4f1fa709cd1ac66a0a1299803c5bd8c32758044.tar.lz
nixlib-d4f1fa709cd1ac66a0a1299803c5bd8c32758044.tar.xz
nixlib-d4f1fa709cd1ac66a0a1299803c5bd8c32758044.tar.zst
nixlib-d4f1fa709cd1ac66a0a1299803c5bd8c32758044.zip
pythonPackages.Theano: fix darwin build
This only formally fixes the name of the compiler. Theano appears to be
working on darwin after this.
Diffstat (limited to 'pkgs/development/python-modules/Theano/default.nix')
-rw-r--r--pkgs/development/python-modules/Theano/default.nix6
1 files changed, 5 insertions, 1 deletions
diff --git a/pkgs/development/python-modules/Theano/default.nix b/pkgs/development/python-modules/Theano/default.nix
index 554eaf977911..67600a6e5fd8 100644
--- a/pkgs/development/python-modules/Theano/default.nix
+++ b/pkgs/development/python-modules/Theano/default.nix
@@ -35,7 +35,11 @@ let
     '';
 
   # Theano spews warnings and disabled flags if the compiler isn't named g++
-  cxx_compiler = wrapped "g++" "\\$HOME/.theano"
+  cxx_compiler_name =
+    if stdenv.cc.isGNU then "g++" else
+    if stdenv.cc.isClang then "clang++" else
+    throw "Unknown C++ compiler";
+  cxx_compiler = wrapped cxx_compiler_name "\\$HOME/.theano"
     (    stdenv.lib.optional cudaSupport libgpuarray_
       ++ stdenv.lib.optional cudnnSupport cudnn );