diff options
Diffstat (limited to 'pkgs/development/compilers/llvm/10/libcxxabi/default.nix')
-rw-r--r-- | pkgs/development/compilers/llvm/10/libcxxabi/default.nix | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkgs/development/compilers/llvm/10/libcxxabi/default.nix b/pkgs/development/compilers/llvm/10/libcxxabi/default.nix index 0af20699a1d..d62422fc9a1 100644 --- a/pkgs/development/compilers/llvm/10/libcxxabi/default.nix +++ b/pkgs/development/compilers/llvm/10/libcxxabi/default.nix @@ -45,7 +45,7 @@ stdenv.mkDerivation { if [ -L "$file" ]; then continue; fi # Fix up the install name. Preserve the basename, just replace the path. - installName="$out/lib/$(basename $(otool -D $file | tail -n 1))" + installName="$out/lib/$(basename $(${stdenv.cc.targetPrefix}otool -D $file | tail -n 1))" # this should be done in CMake, but having trouble figuring out # the magic combination of necessary CMake variables @@ -56,7 +56,7 @@ stdenv.mkDerivation { # cc-wrapper passes '-lc++abi' to all c++ link steps, but that causes # libcxxabi to sometimes link against a different version of itself. # Here we simply make that second reference point to ourselves. - for other in $(otool -L $file | awk '$1 ~ "/libc\\+\\+abi" { print $1 }'); do + for other in $(${stdenv.cc.targetPrefix}otool -L $file | awk '$1 ~ "/libc\\+\\+abi" { print $1 }'); do ${stdenv.cc.targetPrefix}install_name_tool -change $other $installName $file done done |