about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--pkgs/build-support/auto-patchelf/default.nix1
-rw-r--r--pkgs/build-support/auto-patchelf/setup-hook.sh7
-rw-r--r--pkgs/games/build-support/build-game.nix7
3 files changed, 7 insertions, 8 deletions
diff --git a/pkgs/build-support/auto-patchelf/default.nix b/pkgs/build-support/auto-patchelf/default.nix
index c7a055cb..dfd8e64b 100644
--- a/pkgs/build-support/auto-patchelf/default.nix
+++ b/pkgs/build-support/auto-patchelf/default.nix
@@ -8,7 +8,6 @@ substituteAll {
   inherit (stdenv) shell;
   file = "${file}/bin/file";
   find = "${findutils}/bin/find";
-  grep = "${gnugrep}/bin/grep";
   ldd = "${glibc.bin}/bin/ldd";
   objdump = "${binutils-unwrapped}/bin/objdump";
   patchelf = "${patchelf}/bin/patchelf";
diff --git a/pkgs/build-support/auto-patchelf/setup-hook.sh b/pkgs/build-support/auto-patchelf/setup-hook.sh
index 6e34b4ef..51a6a888 100644
--- a/pkgs/build-support/auto-patchelf/setup-hook.sh
+++ b/pkgs/build-support/auto-patchelf/setup-hook.sh
@@ -41,13 +41,6 @@ getDepsFromSo() {
     @ldd@ "$1" 2> /dev/null | @sed@ -n -e 's/[^=]*=> *\(.\+\) \+([^)]*)$/\1/p'
 }
 
-checkElfDep() {
-    local errors ldout="$(@ldd@ "$1" 2> /dev/null)"
-    if errors="$(echo "$ldout" | @grep@ -F "not found")"; then
-        echo -e "Library dependencies missing for $1:\n$errors"
-    fi
-}
-
 populateCacheWithRecursiveDeps() {
     local so found foundso
     for so in "${cachedDependencies[@]}"; do
diff --git a/pkgs/games/build-support/build-game.nix b/pkgs/games/build-support/build-game.nix
index e4d019af..ea97d72a 100644
--- a/pkgs/games/build-support/build-game.nix
+++ b/pkgs/games/build-support/build-game.nix
@@ -51,6 +51,13 @@ buildSandbox (stdenv.mkDerivation ({
 
     echo "checking dependencies for libraries and executables" >&2
 
+    checkElfDep() {
+        local errors ldout="$(ldd "$1" 2> /dev/null)"
+        if errors="$(echo "$ldout" | grep -F "not found")"; then
+            echo -e "Library dependencies missing for $1:\n$errors"
+        fi
+    }
+
     local errors="$(
         IFS=$'\n'
         for elf in $(findElfs "$prefix"); do checkElfDep "$elf"; done