[lldb] Remove LLDB session dir and just store test traces in the respective test...
[lldb.git] / lldb / utils / lldb-dotest / lldb-dotest.in
1 #!@Python3_EXECUTABLE@
2 import subprocess
3 import sys
4
5 dotest_path = '@LLDB_SOURCE_DIR_CONFIGURED@/test/API/dotest.py'
6 dotest_args_str = '@LLDB_DOTEST_ARGS_CONFIGURED@'
7 arch = '@LLDB_TEST_ARCH@'
8 executable = '@LLDB_TEST_EXECUTABLE_CONFIGURED@'
9 compiler = '@LLDB_TEST_COMPILER_CONFIGURED@'
10 dsymutil = '@LLDB_TEST_DSYMUTIL_CONFIGURED@'
11 filecheck = '@LLDB_TEST_FILECHECK_CONFIGURED@'
12 yaml2obj = '@LLDB_TEST_YAML2OBJ_CONFIGURED@'
13 server = '@LLDB_TEST_SERVER_CONFIGURED@'
14 lldb_build_dir = '@LLDB_TEST_BUILD_DIRECTORY_CONFIGURED@'
15 lldb_build_intel_pt = "@LLDB_BUILD_INTEL_PT@"
16 lldb_framework_dir = "@LLDB_FRAMEWORK_DIR_CONFIGURED@"
17 lldb_libs_dir = "@LLDB_LIBS_DIR_CONFIGURED@"
18
19 if __name__ == '__main__':
20     wrapper_args = sys.argv[1:]
21     dotest_args = dotest_args_str.split(';')
22     # Build dotest.py command.
23     cmd = [sys.executable, dotest_path]
24     cmd.extend(['--arch', arch])
25     cmd.extend(dotest_args)
26     cmd.extend(['--build-dir', lldb_build_dir])
27     cmd.extend(['--executable', executable])
28     cmd.extend(['--compiler', compiler])
29     cmd.extend(['--dsymutil', dsymutil])
30     cmd.extend(['--yaml2obj', yaml2obj])
31     cmd.extend(['--filecheck', filecheck])
32     cmd.extend(['--lldb-libs-dir', lldb_libs_dir])
33     if server:
34         cmd.extend(['--server', server])
35     if lldb_framework_dir:
36         cmd.extend(['--framework', lldb_framework_dir])
37     if lldb_build_intel_pt == "1":
38         cmd.extend(['--enable-plugin', 'intel-pt'])
39     cmd.extend(wrapper_args)
40     # Invoke dotest.py and return exit code.
41     print(' '.join(cmd))
42     sys.exit(subprocess.call(cmd))