o3de / o3de

Open 3D Engine (O3DE) is an Apache 2.0-licensed multi-platform 3D engine that enables developers and content creators to build AAA games, cinema-quality 3D worlds, and high-fidelity simulations without any fees or commercial obligations.
https://o3de.org
Other
7.67k stars 2.18k forks source link

Update the FindNvCloth.cmake script to not force use of the MSVC link.exe when using Windows clang #13702

Open lemonade-dm opened 1 year ago

lemonade-dm commented 1 year ago

Currently the using the LLVM Clang compiler on Windows can compile and link o3de using the lld-link.exe that comes with the LLVM toolset. The one exception is that the NvCloth 3rdParty library is forcing the linker command to use link.exe via -fuse-ld=link.exe which is the MSVC linker.

Since the NvCloth static library is already built without link time code generation /LTCG:OFF and without whole program optimization /GL- there is no need to specify that the MSVC linker be used.

The logic to remove the LTCG and GL flag is in the build_package_image.py for the NvCloth 3rdParty.

The change that is needed to not force the use of MSVC link.exe is to remove -fuse-ld=link.exe option from FindNvCloth.cmake

hultonha commented 1 year ago

sig-simulation triage session - Moving to triage/accepted as @moraaar has self assigned this and is investigating.