Error when trying to build .so file from TFlite C++ API

I tried to build my own C++ shared libraries on Windows, but encountered some Bazel build errors.
My Android NDK version is 21.1.6352462, Bazel version is 6.3.2.
Here is my configure setting:

Would you like to interactively configure ./WORKSPACE for Android builds? [y/N]: y
Please specify the (min) Android NDK API level to use.:21
Please specify the Android SDK API level to use.:31
Please specify an Android build tools version to use.:33.0.0

I have tried the following two build commands:

bazel build -c opt --config=android_arm //tensorflow/
bazel build -c opt --config=android_arm64 //tensorflow/

But I keep getting this error:

Clang error: No such file or directory: /d2ReducedOptimizeHugeFunctions

d2ReducedOptimizeHugeFunctions is an option for Windows build.

Are you using Windows? Does it work if you remove those lines?

Hi Terry_Woncheol_Heo,
Thank you for your reply.
Yes, I build the library on windows, and I attempted to comment out these two lines of code in .bazelrc.

build:windows --copt=/d2ReducedOptimizeHugeFunctions
build:windows --host_copt=/d2ReducedOptimizeHugeFunctions

The same error still persists.

C:/users/administrator/_bazel_administrator/ejytmwk2/external/XNNPACK/BUILD.bazel:4739:19: Compiling src/f32-gemm/gen/f32-gemminc-1x12-minmax-asm-aarch64-neonfma-cortex-a53.S failed: (Exit 1): clang failed: error executing command (from target @XNNPACK//:asm_microkernels) external\androidndk\ndk\toolchains\llvm\prebuilt\windows-x86_64\bin\clang -gcc-toolchain external/androidndk/ndk/toolchains/aarch64-linux-android-4.9/prebuilt/windows-x86_64 -target ... (remaining 52 arguments skipped)
clang: error: no such file or directory: '/d2ReducedOptimizeHugeFunctions'