- Added a sanity check with Clang_FOUND to verify that find_package succeeded
- Made sure that find_package won't use any of CMake's standard paths to guarantee that only the path provided with CLANG_DIR is considered (implemented through NO_DEFAULT_PATH)
- Made the call to get_filename_component more explicit (so that it is clear what the base directory is)
- Updated comments to clarify what CLANG_DIR means
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
One quick question. Otherwise looks good.
flang/CMakeLists.txt | ||
---|---|---|
54 | Why CLANG_DIR_ABSOLUTEDIR when the var above is declared as CLANG_DIR_ABSOLUTE? Am I missing something? |
Comment Actions
That was a typo, cheers for pointing out!
I've updated this patch a bit more. I think that the semantics of CLANG_DIR (and {LLVM|MLIR}_DIR) are a bit too convoluted. I hope that this will help clarifying. If this makes sense, I'll update MLIR_DIR and LLVM_DIR vars in a separate patch.
Why CLANG_DIR_ABSOLUTEDIR when the var above is declared as CLANG_DIR_ABSOLUTE? Am I missing something?