rnk wrote:

Sorry for not responding, I've had multiple trips this year where I've 
basically had to ignore all incoming mail after the fact.

I think folks should probably stand back and really try to think about what 
their goals are. I understand the desire to have something resembling a sysroot 
for targeting Windows. It sure would be great if the Windows SDK and Visual CRT 
headers weren't so obnoxiously non-standard, and had consistent casing. But, as 
has been mentioned, the goal of `clang-cl` has primarily been to be something 
that is easy for MSVC users to adopt, not to make cross-compilation easy. We 
can totally do both things, and have different features for different use cases.

MinGW is clearly an example of how you can solve this problem, if you're 
willing to invasively rewrite all the C headers. It just depends on how close 
you want to hew to the interfaces pushed out by the platform owner, Microsoft. 
Clearly, LLVM wouldn't care at all if someone tried to call the LLVM C/C++ APIs 
using their own bespoke, written-from-scratch header files.

I'm not sure I fully endorse all the choices made in 
[makesysroot.py](https://github.com/trcrsired/windows-msvc-sysroot/blob/main/share/tools/makesysroot.py),
 but I think I could be OK with having `--sysroot=` disable all the other 
Windows-host-specific SDK/VC detection logic. 

https://github.com/llvm/llvm-project/pull/96417
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to