blob: fc493e480fda75f81055ea42843a348591f5acf8 [file] [log] [blame]
Douglas Gregor20d58fb2009-11-26 02:28:53 +00001# -*- Python -*-
2
3# Configuration file for the 'lit' test runner.
4
5def getRoot(config):
6 if not config.parent:
7 return config
8 return getRoot(config.parent)
9
10root = getRoot(config)
11
12# testFormat: The test format to use to interpret tests.
13cxxflags = ['-D__STDC_LIMIT_MACROS',
14 '-D__STDC_CONSTANT_MACROS',
15 '-Wno-sign-compare',
16 '-I%s/include' % root.llvm_src_root,
17 '-I%s/include' % root.llvm_obj_root]
18config.test_format = \
19 lit.formats.OneCommandPerFileTest(command=[root.clang, '-emit-llvm', '-c',
20 '-o', '/dev/null'] + cxxflags,
21 dir='%s/lib' % root.llvm_src_root,
22 recursive=True,
23 pattern='^(.*\\.cpp)$')
24