nixpkgs/pkgs/applications/science/math/sage/spkg-git.patch
Timo Kaufmann 272e930827 sage: fix non-deterministic build failures
The build was failing on some machines because of a `find` command that
touched files in different orders on different machines.

That confused `make`s timestamp mechanism.
2018-02-05 15:03:24 +01:00

19 lines
529 B
Diff

diff --git a/build/pkgs/git/spkg-install b/build/pkgs/git/spkg-install
index 87874de3d8..b0906245fa 100644
--- a/build/pkgs/git/spkg-install
+++ b/build/pkgs/git/spkg-install
@@ -33,6 +33,13 @@ fi
cd src
+# Fix hardcoded paths, while making sure to only update timestamps of actually
+# changed files (otherwise confuses make)
+grep -rlF '/usr/bin/perl' . | while read file
+do
+ sed -e 's@/usr/bin/perl@perl@g' -i "$file"
+done
+
# We don't want to think about Fink or Macports
export NO_FINK=1
export NO_DARWIN_PORTS=1