about summary refs log tree commit diff
path: root/pkgs/tools/misc/hdf5
diff options
context:
space:
mode:
authorSukant Hajra <rrudbskr5g@snkmail.com>2017-09-28 02:09:16 -0500
committerFrederik Rietdijk <fridh@fridh.nl>2017-09-28 10:41:38 +0200
commit82667fee37e306deb20cf7abdfe9ed0b896a7183 (patch)
tree8c75dad4461950d8d0ff99f25a8fd32152bbf0a8 /pkgs/tools/misc/hdf5
parent036a7fb976b864275d223d6032cff0ea354ea3b8 (diff)
downloadnixlib-82667fee37e306deb20cf7abdfe9ed0b896a7183.tar
nixlib-82667fee37e306deb20cf7abdfe9ed0b896a7183.tar.gz
nixlib-82667fee37e306deb20cf7abdfe9ed0b896a7183.tar.bz2
nixlib-82667fee37e306deb20cf7abdfe9ed0b896a7183.tar.lz
nixlib-82667fee37e306deb20cf7abdfe9ed0b896a7183.tar.xz
nixlib-82667fee37e306deb20cf7abdfe9ed0b896a7183.tar.zst
nixlib-82667fee37e306deb20cf7abdfe9ed0b896a7183.zip
hdf5: remove references to stdenv.cc
The build provides as text a summary of the build, including the
absolute path of the compiler used for compilation.  Unfortunately, this
pulls in stdenv.cc as a transitive closure.

So this change just calls remove-references-to as a postInstall step for
the one stdenv.cc dependency.

See #29889 for details.
Diffstat (limited to 'pkgs/tools/misc/hdf5')
-rw-r--r--pkgs/tools/misc/hdf5/default.nix8
1 files changed, 8 insertions, 0 deletions
diff --git a/pkgs/tools/misc/hdf5/default.nix b/pkgs/tools/misc/hdf5/default.nix
index eb29e7d914c5..257ade407279 100644
--- a/pkgs/tools/misc/hdf5/default.nix
+++ b/pkgs/tools/misc/hdf5/default.nix
@@ -1,5 +1,7 @@
 { stdenv
 , fetchurl
+, gcc
+, removeReferencesTo
 , cpp ? false
 , gfortran ? null
 , zlib ? null
@@ -30,6 +32,8 @@ stdenv.mkDerivation rec {
     inherit mpi;
   };
 
+  nativeBuildInputs = [ removeReferencesTo ];
+
   buildInputs = []
     ++ optional (gfortran != null) gfortran
     ++ optional (szip != null) szip;
@@ -47,6 +51,10 @@ stdenv.mkDerivation rec {
 
   patches = [./bin-mv.patch];
 
+  postInstall = ''
+    find "$out" -type f -exec remove-references-to -t ${stdenv.cc} '{}' +
+  '';
+
   meta = {
     description = "Data model, library, and file format for storing and managing data";
     longDescription = ''