llvm-mos-sdk
llvm-mos-sdk copied to clipboard
Building fails unless SDK and compiler version match exactly
On line 17 of mos-platform/common/crt/CMakeLists.txt, there is the following line:
find_library(builtins clang_rt.builtins REQUIRED PATHS ${compiler_dir}/../lib/clang/22/lib/mos-unknown-unknown NO_DEFAULT_PATH)
This code forces each release of the SDK to match a specific version of the compiler, EXACTLY. Failing to follow this rule causes odd breakages when referring to clang builtins. This is quite fragile.
The SDK should probably get the right directories from one of the following:
mos-clang -print-search-dirs
mos-clang -print-resource-dir
This is a good idea; I have been rather annoyed by trying to keep this up to date when pulling from upstream too. I may take this on the next time I need to change this.
+1 :)