clang: only link if LLVMgold exists
buildEnv now errors with broken symlinks. Lots of things like this
still exist.
Discussion in #39038.
(cherry picked from commit 7b73c7f49a
)
This commit is contained in:
parent
4ffa8b6125
commit
d417ada9a6
7 changed files with 28 additions and 7 deletions
|
@ -29,7 +29,10 @@ stdenv.mkDerivation {
|
|||
# Clang expects to find LLVMgold in its own prefix
|
||||
# Clang expects to find sanitizer libraries in its own prefix
|
||||
postInstall = ''
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
if [ -e ${llvm}/lib/LLVMgold.so ]; then
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
fi
|
||||
|
||||
ln -sv ${llvm}/lib/clang/${version}/lib $out/lib/clang/${version}/
|
||||
'';
|
||||
|
||||
|
|
|
@ -31,7 +31,10 @@ in stdenv.mkDerivation {
|
|||
# Clang expects to find LLVMgold in its own prefix
|
||||
# Clang expects to find sanitizer libraries in its own prefix
|
||||
postInstall = ''
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
if [ -e ${llvm}/lib/LLVMgold.so ]; then
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
fi
|
||||
|
||||
ln -sv ${llvm}/lib/clang/${version}/lib $out/lib/clang/${version}/
|
||||
ln -sv $out/bin/clang $out/bin/cpp
|
||||
'';
|
||||
|
|
|
@ -32,7 +32,10 @@ let
|
|||
# Clang expects to find LLVMgold in its own prefix
|
||||
# Clang expects to find sanitizer libraries in its own prefix
|
||||
postInstall = ''
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
if [ -e ${llvm}/lib/LLVMgold.so ]; then
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
fi
|
||||
|
||||
ln -sv ${llvm}/lib/clang/${version}/lib $out/lib/clang/${version}/
|
||||
ln -sv $out/bin/clang $out/bin/cpp
|
||||
'';
|
||||
|
|
|
@ -34,7 +34,10 @@ let
|
|||
# Clang expects to find LLVMgold in its own prefix
|
||||
# Clang expects to find sanitizer libraries in its own prefix
|
||||
postInstall = ''
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
if [ -e ${llvm}/lib/LLVMgold.so ]; then
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
fi
|
||||
|
||||
ln -sv ${llvm}/lib/clang/${version}/lib $out/lib/clang/${version}/
|
||||
ln -sv $out/bin/clang $out/bin/cpp
|
||||
|
||||
|
|
|
@ -36,7 +36,10 @@ let
|
|||
# Clang expects to find LLVMgold in its own prefix
|
||||
# Clang expects to find sanitizer libraries in its own prefix
|
||||
postInstall = ''
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
if [ -e ${llvm}/lib/LLVMgold.so ]; then
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
fi
|
||||
|
||||
ln -sv ${llvm}/lib/clang/${version}/lib $out/lib/clang/${version}/
|
||||
ln -sv $out/bin/clang $out/bin/cpp
|
||||
|
||||
|
|
|
@ -52,7 +52,10 @@ let
|
|||
# Clang expects to find LLVMgold in its own prefix
|
||||
# Clang expects to find sanitizer libraries in its own prefix
|
||||
postInstall = ''
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
if [ -e ${llvm}/lib/LLVMgold.so ]; then
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
fi
|
||||
|
||||
ln -sv ${llvm}/lib/clang/${release_version}/lib $out/lib/clang/${release_version}/
|
||||
ln -sv $out/bin/clang $out/bin/cpp
|
||||
|
||||
|
|
|
@ -53,7 +53,10 @@ let
|
|||
# Clang expects to find LLVMgold in its own prefix
|
||||
# Clang expects to find sanitizer libraries in its own prefix
|
||||
postInstall = ''
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
if [ -e ${llvm}/lib/LLVMgold.so ]; then
|
||||
ln -sv ${llvm}/lib/LLVMgold.so $out/lib
|
||||
fi
|
||||
|
||||
ln -sv ${llvm}/lib/clang/${release_version}/lib $out/lib/clang/${release_version}/
|
||||
ln -sv $out/bin/clang $out/bin/cpp
|
||||
|
||||
|
|
Loading…
Reference in a new issue