Ann:

target_link_libraries(Pytorch_test PRIVATE -Wl,–whole-archive “${CMAKE_CURRENT_LIST_DIR}/*.lib”)


Please rewrite this line to generate the following options for MSVC. (e.g. /WHOLEARCHIVE c10.lib /WHOLEARCHIVE torch_cuda.lib [and more]).