报错:
error: linking with `D:/NDK/android-ndk-r25c/toolchains/llvm/prebuilt/windows-x86_64/bin/aarch64-linux-android30-clang.cmd` failed: exit code: 255
|
= note: "D:/NDK/android-ndk-r25c/toolchains/llvm/prebuilt/windows-x86_64/bin/aarch64-linux-android30-clang.cmd" "-Wl,--version-script=C:\\Users\\Liste\\AppData\\Local\\Temp\\rustcPwRX2e\\list" "-Wl,--no-undefi
ned-version" "C:\\Users\\Liste\\AppData\\Local\\Temp\\rustcPwRX2e\\symbols.o" "E:\\idea_projects\\my_lib\\target\\aarch64-linux-android\\release\\deps\\my_lib.my_lib.d56b3372c49eacad-cgu.0.rcgu.o" "
-Wl,--as-needed" "-L" "E:\\idea_projects\\my_lib\\target\\aarch64-linux-android\\release\\deps" "-L" "E:\\idea_projects\\my_lib\\target\\release\\deps" "-L" "C:\\Users\\Liste\\.rustup\\toolchains\\stable-
x86_64-pc-windows-msvc\\lib\\rustlib\\aarch64-linux-android\\lib" "-Wl,-Bstatic" "C:\\Users\\Liste\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\aarch64-linux-android\\lib\\libcompiler_builtins-0
1f0855226f8e564.rlib" "-Wl,-Bdynamic" "-ldl" "-llog" "-lunwind" "-ldl" "-lm" "-lc" "-Wl,--eh-frame-hdr" "-Wl,-z,noexecstack" "-L" "C:\\Users\\Liste\\.rustup\\toolchains\\stable-x86_64-pc-windows-msvc\\lib\\rustlib\\a
arch64-linux-android\\lib" "-o" "E:\\idea_projects\\my_lib\\target\\aarch64-linux-android\\release\\deps\\libmy_lib.so" "-Wl,--gc-sections" "-shared" "-Wl,-z,relro,-z,now" "-Wl,--strip-all" "-nodefaultlibs"
= note: --version-script=C:\Users\Liste\AppData\Local\Temp\rustcPwRX2e\list"" was unexpected at this time.
warning: `my_lib` (lib) generated 2 warnings
error: could not compile `my_lib` (lib) due to previous error; 2 warnings emitted
详情:
https://github.com/rust-lang/rust/issues/113711#issuecomment-1659964557
临时解决,退回到1.68.2: rustup default 1.68.2