From a4f36d49a53506be9c2a4b93844f28b10f098abe Mon Sep 17 00:00:00 2001 From: obadz Date: Mon, 4 Apr 2016 15:41:01 +0100 Subject: [PATCH] citrix-receiver: fix patchelf error during installPhase Due to recent change in patchelf, it's now necessary to run chmod u+w prior to running patchelf itself. Fixes #14440 for citrix-receiver --- .../networking/remote/citrix-receiver/default.nix | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/networking/remote/citrix-receiver/default.nix b/pkgs/applications/networking/remote/citrix-receiver/default.nix index 056d28eb3cd..6d14761356a 100644 --- a/pkgs/applications/networking/remote/citrix-receiver/default.nix +++ b/pkgs/applications/networking/remote/citrix-receiver/default.nix @@ -121,9 +121,14 @@ stdenv.mkDerivation rec { find $ICAInstDir -type f -exec file {} \; | grep 'ELF.*executable' | cut -f 1 -d : | - xargs -t -n 1 patchelf \ - --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \ - --set-rpath "$ICAInstDir:$libPath" + while read f + do + echo "Patching ELF intrepreter and rpath for $f" + chmod u+w "$f" + patchelf \ + --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \ + --set-rpath "$ICAInstDir:$libPath" "$f" + done echo "Wrapping wfica..." mkdir "$out/bin"