This is an archive of the discontinued LLVM Phabricator instance.

cmake: Use system llvm-lit when lit.py does not exist in srcdir
AbandonedPublic

Authored by mgorny on Aug 20 2016, 4:49 AM.

Details

Summary

Modify the add_lit_target function to use lit.py from LLVM_MAIN_SRC_DIR only when one does exist there, and otherwise fall back to looking for system install of llvm-lit. This is based on a similar conditional in clang's CMakeLists.txt, and makes it possible to run clang's tests when built separately from LLVM with no access to the original sources.

Diff Detail

Event Timeline

mgorny updated this revision to Diff 68773.Aug 20 2016, 4:49 AM
mgorny retitled this revision from to cmake: Use system llvm-lit when lit.py does not exist in srcdir.
mgorny updated this object.
mgorny added reviewers: garious, chapuni.
mgorny added a subscriber: llvm-commits.
mgorny abandoned this revision.Sep 30 2016, 12:58 AM

Merged into D25076.