As I understood from this text`
The rustc-link-arg instruction tells Cargo to pass the -C link-arg=FLAG option to the compiler, but only when building supported targets (benchmarks, binaries, cdylib crates, examples, and tests). Its usage is highly platform specific. It is useful to set the shared library version or linker script.
cargo:rustc-link-arg deliberately limits the list of targets to which flags are applied, and flags will not be applied to targets such as dylib or rlib, why does it limit targets?
Where can I find documentation on all the flags of cargo:rustc-link-arg?. which I believe are transmitted to linker.exe, I searched on the Internet, but according to the search engine results, I did not find any complete list