bazelbuild / rules_android_ndk

Apache License 2.0
31 stars 15 forks source link

Normalize ndk_path for Windows #79

Open meteorcloudy opened 3 months ago

meteorcloudy commented 3 months ago

Otherwise we may get this error when ANDROID_NDK_PATH=C:\android_ndk\r25b

ERROR: An error occurred during the fetch of repository 'rules_android_ndk~~android_ndk_repository_extension~androidndk':
   Traceback (most recent call last):
        File "C:/tmp/tq5vzwuk/external/rules_android_ndk~/rules.bzl", line 49, column 21, in _android_ndk_repository_impl
                _create_symlinks(ctx, ndk_path, clang_directory, sysroot_directory)
        File "C:/tmp/tq5vzwuk/external/rules_android_ndk~/rules.bzl", line 116, column 24, in _create_symlinks
                ctx.symlink(p, repo_relative_path)
Error in symlink: Cannot write outside of the repository directory for path C:/android_ndk/r25b/toolchains/llvm/prebuilt/windows-x86_64/AndroidVersion.txt