Skip to content

Commit

Permalink
llvmPackages_git.libcxx: remove preInstall phase for Darwin
Browse files Browse the repository at this point in the history
This has not been added for `llvmPackages_15.libcxx`, therefore, we do not need
it anymore.
  • Loading branch information
RaitoBezarius committed Mar 26, 2023
1 parent 2f0ae7f commit 7702f9f
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions pkgs/development/compilers/llvm/git/libcxx/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -91,20 +91,6 @@ stdenv.mkDerivation rec {
ninjaFlags = lib.optional headersOnly "generate-cxx-headers";
installTargets = lib.optional headersOnly "install-cxx-headers";

preInstall = lib.optionalString (stdenv.isDarwin && !headersOnly) ''
for file in lib/*.dylib; do
if [ -L "$file" ]; then continue; fi
baseName=$(basename $(${stdenv.cc.targetPrefix}otool -D $file | tail -n 1))
installName="$out/lib/$baseName"
abiName=$(echo "$baseName" | sed -e 's/libc++/libc++abi/')
for other in $(${stdenv.cc.targetPrefix}otool -L $file | awk '$1 ~ "/libc\\+\\+abi" { print $1 }'); do
${stdenv.cc.targetPrefix}install_name_tool -change $other ${cxxabi}/lib/$abiName $file
done
done
'';

passthru = {
isLLVM = true;
inherit cxxabi;
Expand Down

0 comments on commit 7702f9f

Please sign in to comment.