androidenv: fix NDK toolchain linking issues

Fixes #298285, alternative to #300386.

As suggested in #298285 `lib64` was renamed to `lib`, so just doing the same
as for `lib64` seems to fix the issue.

See also recent discussion in #300386.
This commit is contained in:
Philipp Mildenberger 2024-05-21 00:08:09 +02:00
parent 26c9d4cc48
commit de0fdc1c78
No known key found for this signature in database
GPG Key ID: D2480C382214FD8E

View File

@ -24,7 +24,11 @@ deployAndroidPackage rec {
addAutoPatchelfSearchPath $out/libexec/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/lib64
fi
find toolchains -type d -name bin -or -name lib64 | while read dir; do
if [ -d $out/libexec/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/lib ]; then
addAutoPatchelfSearchPath $out/libexec/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/lib
fi
find toolchains -type d -name bin -or -name lib64 -or -name lib | while read dir; do
autoPatchelf "$dir"
done