mxnet: fix library dependencies.

- mxnet now builds the open source MKL DNN library. However, this
  was not included with the build.
- mxnet builds its own OpenMP library, even when OpenMP is provided
  by the system. This leads to problems, so remove the included
  OpenMP implementation:

  https://github.com/apache/incubator-mxnet/pull/12160
This commit is contained in:
Daniël de Kok 2018-09-04 20:27:25 +02:00
parent da0c385a69
commit 590ce7d1ae

View file

@ -34,11 +34,14 @@ stdenv.mkDerivation rec {
postPatch = ''
substituteInPlace 3rdparty/mkldnn/tests/CMakeLists.txt \
--replace "/bin/bash" "${bash}/bin/bash"
# Build against the system version of OpenMP.
# https://github.com/apache/incubator-mxnet/pull/12160
rm -rf 3rdparty/openmp
'';
installPhase = ''
install -Dm755 libmxnet.so $out/lib/libmxnet.so
cp -r ../include $out
postInstall = ''
rm "$out"/lib/*.a
'';
enableParallelBuilding = true;