Skip to content

Commit 93e9b1d

Browse files
authored
Merge pull request swiftlang#18810 from adrian-prantl/36031890
2 parents fa8ac95 + 2f33dfa commit 93e9b1d

File tree

1 file changed

+31
-2
lines changed

1 file changed

+31
-2
lines changed

utils/build-script-impl

Lines changed: 31 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ KNOWN_SETTINGS=(
6060
lldb-no-debugserver "" "delete debugserver after building it, and don't try to codesign it"
6161
lldb-use-system-debugserver "" "don't try to codesign debugserver, and use the system's debugserver instead"
6262
lldb-assertions "1" "build lldb with assertions enabled"
63+
lldb-test-swift-compatibility "" "specify additional Swift compilers to test lldb with"
6364
llvm-build-type "Debug" "the CMake build variant for LLVM and Clang (Debug, RelWithDebInfo, Release, MinSizeRel). Defaults to Debug."
6465
swift-build-type "Debug" "the CMake build variant for Swift"
6566
swift-enable-assertions "1" "enable assertions in Swift"
@@ -2872,8 +2873,19 @@ for host in "${ALL_HOSTS[@]}"; do
28722873
with_pushd ${lldb_build_dir} \
28732874
call ${NINJA_BIN} unittests/LLDBUnitTests
28742875
with_pushd ${results_dir} \
2875-
call "${llvm_build_dir}/bin/llvm-lit" "${lldb_build_dir}/lit" -sv --xunit-xml-output=${results_dir}/results.xml --param dotest-args="--build-dir ${lldb_build_dir}/lldb-test-build.noindex ${LLDB_TEST_SUBDIR_CLAUSE} ${LLDB_TEST_CATEGORIES} -E \"${DOTEST_EXTRA}\""
2876-
2876+
echo call "${llvm_build_dir}/bin/llvm-lit" \
2877+
"${lldb_build_dir}/lit" -sv \
2878+
--xunit-xml-output=${results_dir}/results.xml \
2879+
--param dotest-args="--build-dir ${lldb_build_dir}/lldb-test-build.noindex ${LLDB_TEST_SUBDIR_CLAUSE} ${LLDB_TEST_CATEGORIES} -E \"${DOTEST_EXTRA}\""
2880+
if [[ -x "${LLDB_TEST_SWIFT_COMPATIBILITY}" ]] ; then
2881+
echo "Running LLDB swift compatibility tests against" \
2882+
"${LLDB_TEST_SWIFT_COMPATIBILITY}"
2883+
with_pushd ${results_dir} \
2884+
call "${llvm_build_dir}/bin/llvm-lit" \
2885+
"${lldb_build_dir}/lit" -sv \
2886+
--xunit-xml-output=${results_dir}/results.xml \
2887+
--param dotest-args="--build-dir ${lldb_build_dir}/lldb-test-build.noindex ${LLDB_TEST_SUBDIR_CLAUSE} ${LLDB_TEST_CATEGORIES} -G swift-history --swift-compiler \"${LLDB_TEST_SWIFT_COMPATIBILITY}\" -E \"${DOTEST_EXTRA}\""
2888+
fi
28772889
else
28782890
with_pushd "${results_dir}" \
28792891
call env SWIFTC="$(build_directory $LOCAL_HOST swift)/bin/swiftc" \
@@ -2887,6 +2899,23 @@ for host in "${ALL_HOSTS[@]}"; do
28872899
${LLDB_FORMATTER_OPTS} \
28882900
--build-dir "${lldb_build_dir}/lldb-test-build.noindex" \
28892901
-E "${DOTEST_EXTRA}"
2902+
if [[ -x "${LLDB_TEST_SWIFT_COMPATIBILITY}" ]] ; then
2903+
echo "Running LLDB swift compatibility tests against" \
2904+
"${LLDB_TEST_SWIFT_COMPATIBILITY}"
2905+
call env SWIFTC="$(build_directory $LOCAL_HOST swift)/bin/swiftc" \
2906+
SWIFTLIBS="${swift_build_dir}/lib/swift" \
2907+
"${LLDB_SOURCE_DIR}"/test/dotest.py \
2908+
--executable "${lldb_executable}" \
2909+
${LLDB_TEST_DEBUG_SERVER} \
2910+
${LLDB_TEST_SUBDIR_CLAUSE} \
2911+
${LLDB_TEST_CATEGORIES} \
2912+
${LLDB_DOTEST_CC_OPTS} \
2913+
${LLDB_FORMATTER_OPTS} \
2914+
--build-dir "${lldb_build_dir}/lldb-test-build.noindex" \
2915+
-G swift-history \
2916+
--swift-compiler "${LLDB_TEST_SWIFT_COMPATIBILITY}" \
2917+
-E "${DOTEST_EXTRA}"
2918+
fi
28902919
fi
28912920

28922921
continue

0 commit comments

Comments
 (0)