Skip to content

Commit 6d13961

Browse files
authored
[libc++][test] Improves substitution naming (#80471)
Using the `-dir` suffix for directories makes it easier to understand. Fixes: #78310
1 parent b33b91a commit 6d13961

30 files changed

+72
-72
lines changed

libcxx/test/configs/apple-libc++-backdeployment.cfg.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,10 @@ config.substitutions.append(('%{flags}',
4545
'-isysroot {}'.format('@CMAKE_OSX_SYSROOT@') if '@CMAKE_OSX_SYSROOT@' else ''
4646
))
4747
config.substitutions.append(('%{compile_flags}',
48-
'-nostdinc++ -I %{include} -I %{libcxx}/test/support'
48+
'-nostdinc++ -I %{include-dir} -I %{libcxx-dir}/test/support'
4949
))
5050
config.substitutions.append(('%{link_flags}',
51-
'-nostdlib++ -L %{lib} -lc++'
51+
'-nostdlib++ -L %{lib-dir} -lc++'
5252
))
5353
config.substitutions.append(('%{exec}',
5454
'%{executor} --execdir %T --env DYLD_LIBRARY_PATH="%{cxx-runtime-root}:%{abi-runtime-root}:%{unwind-runtime-root}" -- '

libcxx/test/configs/apple-libc++-shared.cfg.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@ config.substitutions.append(('%{flags}',
1313
'-isysroot {}'.format('@CMAKE_OSX_SYSROOT@') if '@CMAKE_OSX_SYSROOT@' else ''
1414
))
1515
config.substitutions.append(('%{compile_flags}',
16-
'-nostdinc++ -I %{include} -I %{libcxx}/test/support'
16+
'-nostdinc++ -I %{include-dir} -I %{libcxx-dir}/test/support'
1717
))
1818
config.substitutions.append(('%{link_flags}',
19-
'-nostdlib++ -L %{lib} -lc++'
19+
'-nostdlib++ -L %{lib-dir} -lc++'
2020
))
2121
config.substitutions.append(('%{exec}',
22-
'%{executor} --execdir %T --env DYLD_LIBRARY_PATH=%{lib} -- '
22+
'%{executor} --execdir %T --env DYLD_LIBRARY_PATH=%{lib-dir} -- '
2323
))
2424

2525
config.stdlib = 'apple-libc++'

libcxx/test/configs/armv7m-picolibc-libc++.cfg.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ libc_linker_script = '@CMAKE_INSTALL_PREFIX@/lib/picolibcpp.ld'
55
config.substitutions.append(('%{flags}', '--sysroot=@CMAKE_INSTALL_PREFIX@'))
66

77
config.substitutions.append(('%{compile_flags}',
8-
'-nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support'
8+
'-nostdinc++ -I %{include-dir} -I %{target-include-dir} -I %{libcxx-dir}/test/support'
99

1010
# Disable warnings in cxx_atomic_impl.h:
1111
# "large atomic operation may incur significant performance penalty; the
@@ -17,7 +17,7 @@ config.substitutions.append(('%{compile_flags}',
1717
' -include picolibc.h'
1818
))
1919
config.substitutions.append(('%{link_flags}',
20-
'-nostdlib -nostdlib++ -L %{lib} -lc++ -lc++abi'
20+
'-nostdlib -nostdlib++ -L %{lib-dir} -lc++ -lc++abi'
2121
' -lc -lm -lclang_rt.builtins -lsemihost -lcrt0-semihost' +
2222
' -T {}'.format(libc_linker_script) +
2323
' -Wl,--defsym=__flash=0x0'

libcxx/test/configs/cmake-bridge.cfg.in

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ config.test_exec_root = os.path.join('@CMAKE_BINARY_DIR@', 'test')
2525
# Add substitutions for bootstrapping the test suite configuration
2626
import shlex
2727
config.substitutions.append(('%{cxx}', shlex.quote('@CMAKE_CXX_COMPILER@')))
28-
config.substitutions.append(('%{libcxx}', '@LIBCXX_SOURCE_DIR@'))
29-
config.substitutions.append(('%{include}', '@LIBCXX_GENERATED_INCLUDE_DIR@'))
30-
config.substitutions.append(('%{target-include}', '@LIBCXX_GENERATED_INCLUDE_TARGET_DIR@'))
31-
config.substitutions.append(('%{lib}', '@LIBCXX_LIBRARY_DIR@'))
32-
config.substitutions.append(('%{module}', '@LIBCXX_GENERATED_MODULE_DIR@'))
33-
config.substitutions.append(('%{test-tools}', '@LIBCXX_TEST_TOOLS_PATH@'))
28+
config.substitutions.append(('%{libcxx-dir}', '@LIBCXX_SOURCE_DIR@'))
29+
config.substitutions.append(('%{include-dir}', '@LIBCXX_GENERATED_INCLUDE_DIR@'))
30+
config.substitutions.append(('%{target-include-dir}', '@LIBCXX_GENERATED_INCLUDE_TARGET_DIR@'))
31+
config.substitutions.append(('%{lib-dir}', '@LIBCXX_LIBRARY_DIR@'))
32+
config.substitutions.append(('%{module-dir}', '@LIBCXX_GENERATED_MODULE_DIR@'))
33+
config.substitutions.append(('%{test-tools-dir}', '@LIBCXX_TEST_TOOLS_PATH@'))

libcxx/test/configs/ibm-libc++-shared.cfg.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ if lit.util.isAIXTriple(config.target_triple):
1212

1313
config.substitutions.append(('%{flags}', '-pthread'))
1414
config.substitutions.append(('%{compile_flags}',
15-
'-nostdinc++ -D__LIBC_NO_CPP_MATH_OVERLOADS__ -I %{include} -I %{libcxx}/test/support'
15+
'-nostdinc++ -D__LIBC_NO_CPP_MATH_OVERLOADS__ -I %{include-dir} -I %{libcxx-dir}/test/support'
1616
))
1717
config.substitutions.append(('%{link_flags}',
18-
'-nostdlib++ -L %{lib} -lc++ -lc++abi -latomic -Wl,-bbigtoc'
18+
'-nostdlib++ -L %{lib-dir} -lc++ -lc++abi -latomic -Wl,-bbigtoc'
1919
))
2020
config.substitutions.append(('%{exec}',
21-
'%{executor} --execdir %T --env LIBPATH=%{lib} -- '
21+
'%{executor} --execdir %T --env LIBPATH=%{lib-dir} -- '
2222
))
2323

2424
# LIBCXX-AIX-FIXME is the feature name used to XFAIL the

libcxx/test/configs/llvm-libc++-android-ndk.cfg.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ config.substitutions.append(('%{flags}',
1616
'--sysroot @CMAKE_SYSROOT@' if '@CMAKE_SYSROOT@' else ''
1717
))
1818

19-
compile_flags = '-nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support'
19+
compile_flags = '-nostdinc++ -I %{include-dir} -I %{target-include-dir} -I %{libcxx-dir}/test/support'
2020
if re.match(r'i686-linux-android(21|22|23)$', config.target_triple):
2121
# 32-bit x86 Android has a bug where the stack is sometimes misaligned.
2222
# The problem appears limited to versions before Android N (API 24) and only
@@ -31,7 +31,7 @@ config.substitutions.append(('%{compile_flags}', compile_flags))
3131
# libc++_shared.so because older Bionic dynamic loaders don't support rpath
3232
# lookup.
3333
config.substitutions.append(('%{link_flags}',
34-
'-nostdlib++ -L %{lib} -lc++_shared'
34+
'-nostdlib++ -L %{lib-dir} -lc++_shared'
3535
))
3636
config.substitutions.append(('%{exec}',
3737
'%{executor}' +

libcxx/test/configs/llvm-libc++-mingw.cfg.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ lit_config.load_config(config, '@CMAKE_CURRENT_BINARY_DIR@/cmake-bridge.cfg')
55

66
config.substitutions.append(('%{flags}', ''))
77
config.substitutions.append(('%{compile_flags}',
8-
'-nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support'
8+
'-nostdinc++ -I %{include-dir} -I %{target-include-dir} -I %{libcxx-dir}/test/support'
99
))
1010
config.substitutions.append(('%{link_flags}',
11-
'-nostdlib++ -L %{lib} -lc++'
11+
'-nostdlib++ -L %{lib-dir} -lc++'
1212
))
1313
config.substitutions.append(('%{exec}',
14-
'%{executor} --execdir %T --prepend_env PATH=%{lib} -- '
14+
'%{executor} --execdir %T --prepend_env PATH=%{lib-dir} -- '
1515
))
1616

1717
import os, site

libcxx/test/configs/llvm-libc++-shared-clangcl.cfg.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ lit_config.load_config(config, '@CMAKE_CURRENT_BINARY_DIR@/cmake-bridge.cfg')
55

66
config.substitutions.append(('%{flags}', '--driver-mode=g++'))
77
config.substitutions.append(('%{compile_flags}',
8-
'-fms-runtime-lib=' + config.fms_runtime_lib + ' -nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_STDIO_ISO_WIDE_SPECIFIERS -DNOMINMAX' + config.dbg_include
8+
'-fms-runtime-lib=' + config.fms_runtime_lib + ' -nostdinc++ -I %{include-dir} -I %{target-include-dir} -I %{libcxx-dir}/test/support -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_STDIO_ISO_WIDE_SPECIFIERS -DNOMINMAX' + config.dbg_include
99
))
1010
config.substitutions.append(('%{link_flags}',
11-
'-nostdlib -L %{lib} -lc++ -l' + config.cxx_lib
11+
'-nostdlib -L %{lib-dir} -lc++ -l' + config.cxx_lib
1212
))
1313
config.substitutions.append(('%{exec}',
14-
'%{executor} --execdir %T --prepend_env PATH=%{lib} -- '
14+
'%{executor} --execdir %T --prepend_env PATH=%{lib-dir} -- '
1515
))
1616

1717
import os, site

libcxx/test/configs/llvm-libc++-shared-gcc.cfg.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ lit_config.load_config(config, '@CMAKE_CURRENT_BINARY_DIR@/cmake-bridge.cfg')
66

77
config.substitutions.append(('%{flags}', '-pthread'))
88
config.substitutions.append(('%{compile_flags}',
9-
'-nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support'
9+
'-nostdinc++ -I %{include-dir} -I %{target-include-dir} -I %{libcxx-dir}/test/support'
1010
))
1111
config.substitutions.append(('%{link_flags}',
12-
'-nostdlib++ -L %{lib} -Wl,-rpath,%{lib} -lc++ -lm'
12+
'-nostdlib++ -L %{lib-dir} -Wl,-rpath,%{lib-dir} -lc++ -lm'
1313
))
1414
config.substitutions.append(('%{exec}',
1515
'%{executor} --execdir %T -- '

libcxx/test/configs/llvm-libc++-shared-no-vcruntime-clangcl.cfg.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@ lit_config.load_config(config, '@CMAKE_CURRENT_BINARY_DIR@/cmake-bridge.cfg')
66

77
config.substitutions.append(('%{flags}', '--driver-mode=g++'))
88
config.substitutions.append(('%{compile_flags}',
9-
'-fms-runtime-lib=' + config.fms_runtime_lib + ' -nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_STDIO_ISO_WIDE_SPECIFIERS -DNOMINMAX -D_HAS_EXCEPTIONS=0' + config.dbg_include
9+
'-fms-runtime-lib=' + config.fms_runtime_lib + ' -nostdinc++ -I %{include-dir} -I %{target-include-dir} -I %{libcxx-dir}/test/support -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_STDIO_ISO_WIDE_SPECIFIERS -DNOMINMAX -D_HAS_EXCEPTIONS=0' + config.dbg_include
1010
))
1111
config.substitutions.append(('%{link_flags}',
12-
'-nostdlib -L %{lib} -lc++ -l' + config.cxx_lib
12+
'-nostdlib -L %{lib-dir} -lc++ -l' + config.cxx_lib
1313
))
1414
config.substitutions.append(('%{exec}',
15-
'%{executor} --execdir %T --prepend_env PATH=%{lib} -- '
15+
'%{executor} --execdir %T --prepend_env PATH=%{lib-dir} -- '
1616
))
1717

1818
import os, site

libcxx/test/configs/llvm-libc++-shared.cfg.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ config.substitutions.append(('%{flags}',
77
'-pthread' + (' -isysroot {}'.format('@CMAKE_OSX_SYSROOT@') if '@CMAKE_OSX_SYSROOT@' else '')
88
))
99
config.substitutions.append(('%{compile_flags}',
10-
'-nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support'
10+
'-nostdinc++ -I %{include-dir} -I %{target-include-dir} -I %{libcxx-dir}/test/support'
1111
))
1212
config.substitutions.append(('%{link_flags}',
13-
'-nostdlib++ -L %{lib} -Wl,-rpath,%{lib} -lc++'
13+
'-nostdlib++ -L %{lib-dir} -Wl,-rpath,%{lib-dir} -lc++'
1414
))
1515
config.substitutions.append(('%{exec}',
1616
'%{executor} --execdir %T -- '

libcxx/test/configs/llvm-libc++-static-clangcl.cfg.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ lit_config.load_config(config, '@CMAKE_CURRENT_BINARY_DIR@/cmake-bridge.cfg')
55

66
config.substitutions.append(('%{flags}', '--driver-mode=g++'))
77
config.substitutions.append(('%{compile_flags}',
8-
'-fms-runtime-lib=' + config.fms_runtime_lib + ' -nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_STDIO_ISO_WIDE_SPECIFIERS -DNOMINMAX' + config.dbg_include
8+
'-fms-runtime-lib=' + config.fms_runtime_lib + ' -nostdinc++ -I %{include-dir} -I %{target-include-dir} -I %{libcxx-dir}/test/support -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_STDIO_ISO_WIDE_SPECIFIERS -DNOMINMAX' + config.dbg_include
99
))
1010
config.substitutions.append(('%{link_flags}',
11-
'-nostdlib -L %{lib} -llibc++ -l' + config.cxx_lib
11+
'-nostdlib -L %{lib-dir} -llibc++ -l' + config.cxx_lib
1212
))
1313
config.substitutions.append(('%{exec}',
1414
'%{executor} --execdir %T -- '

libcxx/test/configs/llvm-libc++-static.cfg.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ config.substitutions.append(('%{flags}',
77
'-pthread' + (' -isysroot {}'.format('@CMAKE_OSX_SYSROOT@') if '@CMAKE_OSX_SYSROOT@' else '')
88
))
99
config.substitutions.append(('%{compile_flags}',
10-
'-nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support'
10+
'-nostdinc++ -I %{include-dir} -I %{target-include-dir} -I %{libcxx-dir}/test/support'
1111
))
1212
config.substitutions.append(('%{link_flags}',
13-
'-nostdlib++ -L %{lib} -lc++ -lc++abi'
13+
'-nostdlib++ -L %{lib-dir} -lc++ -lc++abi'
1414
))
1515
config.substitutions.append(('%{exec}',
1616
'%{executor} --execdir %T -- '

libcxx/test/libcxx/assertions/headers_declare_verbose_abort.gen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
# is required for users to be able to include any public header and then override
1111
# the function using a strong definition.
1212

13-
# RUN: %{python} %s %{libcxx}/utils
13+
# RUN: %{python} %s %{libcxx-dir}/utils
1414

1515
import sys
1616
sys.path.append(sys.argv[1])

libcxx/test/libcxx/clang_modules_include.gen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
# This is important notably because the LLDB data formatters use
1111
# libc++ headers with modules enabled.
1212

13-
# RUN: %{python} %s %{libcxx}/utils
13+
# RUN: %{python} %s %{libcxx-dir}/utils
1414

1515
import sys
1616
sys.path.append(sys.argv[1])

libcxx/test/libcxx/clang_tidy.gen.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
# Run our custom libc++ clang-tidy checks on all public headers.
1010

11-
# RUN: %{python} %s %{libcxx}/utils
11+
# RUN: %{python} %s %{libcxx-dir}/utils
1212

1313
import sys
1414
sys.path.append(sys.argv[1])
@@ -27,8 +27,8 @@
2727
{lit_header_restrictions.get(header, '')}
2828
2929
// TODO: run clang-tidy with modules enabled once they are supported
30-
// RUN{BLOCKLIT}: %{{clang-tidy}} %s --warnings-as-errors=* -header-filter=.* --checks='-*,libcpp-*' --load=%{{test-tools}}/clang_tidy_checks/libcxx-tidy.plugin -- %{{compile_flags}} -fno-modules
31-
// RUN{BLOCKLIT}: %{{clang-tidy}} %s --warnings-as-errors=* -header-filter=.* --config-file=%{{libcxx}}/.clang-tidy -- -Wweak-vtables %{{compile_flags}} -fno-modules
30+
// RUN{BLOCKLIT}: %{{clang-tidy}} %s --warnings-as-errors=* -header-filter=.* --checks='-*,libcpp-*' --load=%{{test-tools-dir}}/clang_tidy_checks/libcxx-tidy.plugin -- %{{compile_flags}} -fno-modules
31+
// RUN{BLOCKLIT}: %{{clang-tidy}} %s --warnings-as-errors=* -header-filter=.* --config-file=%{{libcxx-dir}}/.clang-tidy -- -Wweak-vtables %{{compile_flags}} -fno-modules
3232
3333
#include <{header}>
3434
""")

libcxx/test/libcxx/double_include.gen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
# Test that we can include each header in two TU's and link them together.
1010

11-
# RUN: %{python} %s %{libcxx}/utils
11+
# RUN: %{python} %s %{libcxx-dir}/utils
1212

1313
import sys
1414
sys.path.append(sys.argv[1])

libcxx/test/libcxx/header_inclusions.gen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# Test that all headers include all the other headers they're supposed to, as
1010
# prescribed by the Standard.
1111

12-
# RUN: %{python} %s %{libcxx}/utils
12+
# RUN: %{python} %s %{libcxx-dir}/utils
1313

1414
import sys
1515
sys.path.append(sys.argv[1])

libcxx/test/libcxx/headers_in_modulemap.sh.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# RUN: %{python} %s %{libcxx}/utils %{include}
1+
# RUN: %{python} %s %{libcxx-dir}/utils %{include-dir}
22

33
import sys
44

libcxx/test/libcxx/libcpp_version.gen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
# Test that all headers define the _LIBCPP_VERSION macro.
1010

11-
# RUN: %{python} %s %{libcxx}/utils
11+
# RUN: %{python} %s %{libcxx-dir}/utils
1212

1313
import sys
1414
sys.path.append(sys.argv[1])

libcxx/test/libcxx/module_std.gen.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# to be one monolitic test. Since the test doesn't take very long it's
1717
# not a huge issue.
1818

19-
# RUN: %{python} %s %{libcxx}/utils
19+
# RUN: %{python} %s %{libcxx-dir}/utils
2020

2121
import sys
2222

@@ -25,9 +25,9 @@
2525

2626
generator = module_test_generator(
2727
"%t",
28-
"%{module}",
28+
"%{module-dir}",
2929
"%{clang-tidy}",
30-
"%{test-tools}/clang_tidy_checks/libcxx-tidy.plugin",
30+
"%{test-tools-dir}/clang_tidy_checks/libcxx-tidy.plugin",
3131
"%{cxx}",
3232
"%{flags} %{compile_flags}",
3333
"std",

libcxx/test/libcxx/module_std_compat.gen.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# to be one monolitic test. Since the test doesn't take very long it's
1717
# not a huge issue.
1818

19-
# RUN: %{python} %s %{libcxx}/utils
19+
# RUN: %{python} %s %{libcxx-dir}/utils
2020

2121
import sys
2222

@@ -26,9 +26,9 @@
2626

2727
generator = module_test_generator(
2828
"%t",
29-
"%{module}",
29+
"%{module-dir}",
3030
"%{clang-tidy}",
31-
"%{test-tools}/clang_tidy_checks/libcxx-tidy.plugin",
31+
"%{test-tools-dir}/clang_tidy_checks/libcxx-tidy.plugin",
3232
"%{cxx}",
3333
"%{flags} %{compile_flags}",
3434
"std.compat",

libcxx/test/libcxx/no_assert_include.gen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# Ensure that none of the standard C++ headers implicitly include cassert or
1010
# assert.h (because assert() is implemented as a macro).
1111

12-
# RUN: %{python} %s %{libcxx}/utils
12+
# RUN: %{python} %s %{libcxx-dir}/utils
1313

1414
import sys
1515
sys.path.append(sys.argv[1])

libcxx/test/libcxx/system_reserved_names.gen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
# alphabetic macros. Also ensure that we don't swallow the definition of user
1111
# provided macros (in other words, ensure that we push/pop correctly everywhere).
1212

13-
# RUN: %{python} %s %{libcxx}/utils
13+
# RUN: %{python} %s %{libcxx-dir}/utils
1414

1515
import sys
1616
sys.path.append(sys.argv[1])

libcxx/test/libcxx/transitive_includes.gen.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# forever, however we do try to group removals for a couple of releases
1717
# to avoid breaking users at every release.
1818

19-
# RUN: %{python} %s %{libcxx}/utils
19+
# RUN: %{python} %s %{libcxx-dir}/utils
2020

2121
import sys
2222
sys.path.append(sys.argv[1])
@@ -48,7 +48,7 @@
4848
all_traces.append(f'%t/trace-includes.{normalized_header}.txt')
4949

5050
print(f"""\
51-
// RUN{BLOCKLIT}: %{{python}} %{{libcxx}}/test/libcxx/transitive_includes_to_csv.py {' '.join(all_traces)} > %{{libcxx}}/test/libcxx/transitive_includes/%{{cxx_std}}.csv
51+
// RUN{BLOCKLIT}: %{{python}} %{{libcxx-dir}}/test/libcxx/transitive_includes_to_csv.py {' '.join(all_traces)} > %{{libcxx-dir}}/test/libcxx/transitive_includes/%{{cxx_std}}.csv
5252
""")
5353

5454
else:
@@ -83,8 +83,8 @@
8383
8484
// RUN{BLOCKLIT}: mkdir %t
8585
// RUN{BLOCKLIT}: %{{cxx}} %s %{{flags}} %{{compile_flags}} --trace-includes -fshow-skipped-includes --preprocess > /dev/null 2> %t/trace-includes.txt
86-
// RUN{BLOCKLIT}: %{{python}} %{{libcxx}}/test/libcxx/transitive_includes_to_csv.py %t/trace-includes.txt > %t/actual_transitive_includes.csv
87-
// RUN{BLOCKLIT}: cat %{{libcxx}}/test/libcxx/transitive_includes/%{{cxx_std}}.csv | awk '/^{escaped_header} / {{ print }}' > %t/expected_transitive_includes.csv
86+
// RUN{BLOCKLIT}: %{{python}} %{{libcxx-dir}}/test/libcxx/transitive_includes_to_csv.py %t/trace-includes.txt > %t/actual_transitive_includes.csv
87+
// RUN{BLOCKLIT}: cat %{{libcxx-dir}}/test/libcxx/transitive_includes/%{{cxx_std}}.csv | awk '/^{escaped_header} / {{ print }}' > %t/expected_transitive_includes.csv
8888
// RUN{BLOCKLIT}: diff -w %t/expected_transitive_includes.csv %t/actual_transitive_includes.csv
8989
#include <{header}>
9090
""")

0 commit comments

Comments
 (0)