mirror of
https://github.com/pytorch/pytorch.git
synced 2025-11-18 09:34:57 +08:00
Preferred solution to #166380 Changes: - Moved summary print to bottom of CMakeLists.txt - Fix the problem 'add_compile_options' should be called before targets defined, so opted for `append_cxx_flag_if_supported` and `append_c_flag_if_supported` ( new ). - Added extra verbosity so it can be seen when linker script added. ( unfortunately linker script has to be added per-target rather than globally due to ninja/cmake depdendency tracking ). Also move summary print to bottom of CMakeLists.txt and improve logging Pull Request resolved: https://github.com/pytorch/pytorch/pull/166407 Approved by: https://github.com/Aidyn-A, https://github.com/atalman