forked from swiftlang/swift
-
Notifications
You must be signed in to change notification settings - Fork 0
/
lit.site.cfg.in
51 lines (42 loc) · 1.7 KB
/
lit.site.cfg.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
import os
import platform
import sys
## Autogenerated by Swift configuration.
# Do not edit!
config.llvm_src_root = "@LLVM_MAIN_SRC_DIR@"
config.llvm_obj_root = "@LLVM_BINARY_DIR@"
config.llvm_tools_dir = "@LLVM_TOOLS_DIR@"
config.llvm_libs_dir = "@LLVM_LIBS_DIR@"
config.lit_tools_dir = "@LLVM_LIT_TOOLS_DIR@"
config.swift_src_root = lit_config.params.get("swift_src_root", "@SWIFT_SOURCE_DIR@")
config.swift_obj_root = "@SWIFT_BINARY_DIR@"
config.target_triple = "@TARGET_TRIPLE@"
config.targets_to_build = "@TARGETS_TO_BUILD@"
config.variant_triple = "@VARIANT_TRIPLE@"
config.variant_sdk = "@VARIANT_SDK@"
config.swiftlib_dir = "@LIT_SWIFTLIB_DIR@"
if "@SWIFT_ASAN_BUILD@" == "TRUE":
config.available_features.add("asan")
else:
config.available_features.add('no_asan')
if "@LLVM_ENABLE_ASSERTIONS@" == "TRUE":
config.available_features.add('asserts')
else:
config.available_features.add('no_asserts')
if "@SWIFT_STDLIB_ASSERTIONS@" == "TRUE":
config.available_features.add('swift_stdlib_asserts')
else:
config.available_features.add('swift_stdlib_no_asserts')
if "@SWIFT_AST_VERIFIER@" == "TRUE":
config.available_features.add('swift_ast_verifier')
if "@SWIFT_OPTIMIZED@" == "TRUE":
config.available_features.add("optimized_stdlib")
if "@SWIFT_HAVE_WORKING_STD_REGEX@" == "FALSE":
config.available_features.add('broken_std_regex')
if "@SWIFT_BUILD_SOURCEKIT@" == "TRUE" or "@SWIFT_BUILD_SOURCEKIT@" == "ON":
config.available_features.add('sourcekit')
# Let the main config do the real work.
if config.test_exec_root is None:
config.test_exec_root = os.path.dirname(os.path.realpath(__file__))
lit_config.load_config(
config, os.path.join(config.swift_src_root, "test", "lit.cfg"))