Skip to content

Commit 08c04d1

Browse files
committed
---
yaml --- r: 349494 b: refs/heads/master-next c: f221594 h: refs/heads/master
1 parent 771b7b8 commit 08c04d1

File tree

3 files changed

+49
-206
lines changed

3 files changed

+49
-206
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
refs/heads/master: 3574c513bbc5578dd9346b4ea9ab5995c5927bb5
3-
refs/heads/master-next: 61b9d499d9c262dc9a83e320ac8c022eff3c0ffe
3+
refs/heads/master-next: f2215943d8e8554ce962d64259aa0ecb5e1b7c64
44
refs/tags/osx-passed: b6b74147ef8a386f532cf9357a1bde006e552c54
55
refs/tags/swift-2.2-SNAPSHOT-2015-12-01-a: 6bb18e013c2284f2b45f5f84f2df2887dc0f7dea
66
refs/tags/swift-2.2-SNAPSHOT-2015-12-01-b: 66d897bfcf64a82cb9a87f5e663d889189d06d07

branches/master-next/utils/build-script

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,6 @@ class BuildScriptInvocation(object):
299299
"--swift-build-type", args.swift_build_variant,
300300
"--swift-stdlib-build-type", args.swift_stdlib_build_variant,
301301
"--lldb-build-type", args.lldb_build_variant,
302-
"--lldb-build-with-xcode", args.lldb_build_with_xcode,
303302
"--foundation-build-type", args.foundation_build_variant,
304303
"--libdispatch-build-type", args.libdispatch_build_variant,
305304
"--libicu-build-type", args.libicu_build_variant,

branches/master-next/utils/build-script-impl

Lines changed: 48 additions & 204 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@ KNOWN_SETTINGS=(
5353
ninja-bin "" "the path to Ninja tool"
5454
cmark-build-type "Debug" "the CMake build variant for CommonMark (Debug, RelWithDebInfo, Release, MinSizeRel). Defaults to Debug."
5555
lldb-extra-cmake-args "" "extra command line args to pass to lldb cmake"
56-
lldb-extra-xcodebuild-args "" "extra command line args to pass to lldb xcodebuild"
5756
lldb-test-cc "" "CC to use for building LLDB testsuite test inferiors. Defaults to just-built, in-tree clang. If set to 'host-toolchain', sets it to same as host-cc."
5857
lldb-test-with-curses "" "run test lldb test runner using curses terminal control"
5958
lldb-test-swift-only "0" "when running lldb tests, only include Swift-specific tests"
@@ -74,7 +73,6 @@ KNOWN_SETTINGS=(
7473
swift-stdlib-enable-assertions "1" "enable assertions in Swift"
7574
swift-stdlib-use-nonatomic-rc "0" "build the Swift stdlib and overlays with nonatomic reference count operations enabled"
7675
lldb-build-type "Debug" "the CMake build variant for LLDB"
77-
lldb-build-with-xcode "0" "Use xcodebuild to build LLDB, instead of CMake"
7876
llbuild-build-type "Debug" "the CMake build variant for llbuild"
7977
foundation-build-type "Debug" "the build variant for Foundation"
8078
libdispatch-build-type "Debug" "the build variant for libdispatch"
@@ -1929,64 +1927,6 @@ function set_swiftevolve_build_command() {
19291927
swiftevolve_build_command=("${stresstester_build_script_helper_command[@]}")
19301928
}
19311929

1932-
# Construct the appropriate options to pass to an Xcode
1933-
# build of any LLDB target.
1934-
function set_lldb_xcodebuild_options() {
1935-
llvm_build_dir=$(build_directory ${host} llvm)
1936-
cmark_build_dir=$(build_directory ${host} cmark)
1937-
lldb_build_dir=$(build_directory ${host} lldb)
1938-
swift_build_dir=$(build_directory ${host} swift)
1939-
1940-
lldb_xcodebuild_options=(
1941-
LLDB_PATH_TO_LLVM_SOURCE="${LLVM_SOURCE_DIR}"
1942-
LLDB_PATH_TO_CLANG_SOURCE="${CLANG_SOURCE_DIR}"
1943-
LLDB_PATH_TO_SWIFT_SOURCE="${SWIFT_SOURCE_DIR}"
1944-
LLDB_PATH_TO_LLVM_BUILD="${llvm_build_dir}"
1945-
LLDB_PATH_TO_CLANG_BUILD="${llvm_build_dir}"
1946-
LLDB_PATH_TO_SWIFT_BUILD="${swift_build_dir}"
1947-
LLDB_IS_BUILDBOT_BUILD="${LLDB_IS_BUILDBOT_BUILD}"
1948-
LLDB_BUILD_DATE="\"${LLDB_BUILD_DATE}\""
1949-
SYMROOT="${lldb_build_dir}"
1950-
OBJROOT="${lldb_build_dir}"
1951-
-UseNewBuildSystem=NO
1952-
${LLDB_EXTRA_XCODEBUILD_ARGS}
1953-
MACOSX_DEPLOYMENT_TARGET=10.13
1954-
)
1955-
if [[ "${LLDB_NO_DEBUGSERVER}" ]] ; then
1956-
lldb_xcodebuild_options=(
1957-
"${lldb_xcodebuild_options[@]}"
1958-
DEBUGSERVER_DISABLE_CODESIGN="1"
1959-
DEBUGSERVER_DELETE_AFTER_BUILD="1"
1960-
)
1961-
fi
1962-
if [[ "${LLDB_USE_SYSTEM_DEBUGSERVER}" ]] ; then
1963-
lldb_xcodebuild_options=(
1964-
"${lldb_xcodebuild_options[@]}"
1965-
DEBUGSERVER_USE_FROM_SYSTEM="1"
1966-
)
1967-
fi
1968-
if [[ "${ENABLE_ASAN}" ]] ; then
1969-
lldb_xcodebuild_options=(
1970-
"${lldb_xcodebuild_options[@]}"
1971-
ENABLE_ADDRESS_SANITIZER="YES"
1972-
-enableAddressSanitizer=YES
1973-
)
1974-
fi
1975-
if [[ "${ENABLE_UBSAN}" ]] ; then
1976-
lldb_xcodebuild_options=(
1977-
"${lldb_xcodebuild_options[@]}"
1978-
ENABLE_UNDEFINED_BEHAVIOR_SANITIZER="YES"
1979-
-enableUndefinedBehaviorSanitizer=YES
1980-
)
1981-
fi
1982-
if [[ "$(true_false ${LLDB_ASSERTIONS})" == "FALSE" ]]; then
1983-
lldb_xcodebuild_options=(
1984-
"${lldb_xcodebuild_options[@]}"
1985-
OTHER_CFLAGS="-DNDEBUG"
1986-
)
1987-
fi
1988-
}
1989-
19901930
#
19911931
# Configure and build each product
19921932
#
@@ -2518,49 +2458,36 @@ for host in "${ALL_HOSTS[@]}"; do
25182458
# Get the build date
25192459
LLDB_BUILD_DATE=$(date +%Y-%m-%d)
25202460

2521-
using_xcodebuild="FALSE"
2522-
if [[ "$(uname -s)" == "Darwin" && "$(true_false ${LLDB_BUILD_WITH_XCODE})" == "TRUE" ]] ; then
2523-
using_xcodebuild="TRUE"
2524-
fi
25252461

2526-
if [[ "${using_xcodebuild}" == "TRUE" ]] ; then
2527-
# Set up flags to pass to xcodebuild
2528-
set_lldb_xcodebuild_options
2529-
set_lldb_build_mode
2530-
with_pushd ${source_dir} \
2531-
call xcodebuild -target desktop -configuration ${LLDB_BUILD_MODE} ${lldb_xcodebuild_options[@]}
2532-
continue
2462+
if [[ "$(uname -s)" == "Darwin" ]] ; then
2463+
cmake_cache="Apple-lldb-macOS.cmake"
25332464
else
2534-
if [[ "$(uname -s)" == "Darwin" ]] ; then
2535-
cmake_cache="Apple-lldb-macOS.cmake"
2536-
else
2537-
cmake_cache="Apple-lldb-Linux.cmake"
2538-
fi
2465+
cmake_cache="Apple-lldb-Linux.cmake"
2466+
fi
25392467

2540-
cmake_options=(
2541-
"${cmake_options[@]}"
2542-
-C${LLDB_SOURCE_DIR}/cmake/caches/${cmake_cache}
2543-
-DCMAKE_BUILD_TYPE:STRING="${LLDB_BUILD_TYPE}"
2544-
-DLLDB_SWIFTC:PATH="$(build_directory ${LOCAL_HOST} swift)/bin/swiftc"
2545-
-DLLDB_SWIFT_LIBS:PATH="$(build_directory ${LOCAL_HOST} swift)/lib/swift"
2546-
-DCMAKE_INSTALL_PREFIX:PATH="$(get_host_install_prefix ${host})"
2547-
-DLLDB_FRAMEWORK_INSTALL_DIR="$(get_host_install_prefix ${host})../System/Library/PrivateFrameworks"
2548-
-DClang_DIR:PATH=${llvm_build_dir}/lib/cmake/clang
2549-
-DLLVM_DIR:PATH=${llvm_build_dir}/lib/cmake/llvm
2550-
-DSwift_DIR:PATH=${swift_build_dir}/lib/cmake/swift
2551-
-DLLDB_PATH_TO_SWIFT_SOURCE:PATH="${SWIFT_SOURCE_DIR}"
2552-
-DLLDB_IS_BUILDBOT_BUILD:BOOL="${LLDB_IS_BUILDBOT_BUILD}"
2553-
-DLLDB_BUILD_DATE:STRING="\"${LLDB_BUILD_DATE}\""
2554-
-DLLDB_ALLOW_STATIC_BINDINGS:BOOL=1
2555-
-DLLDB_INCLUDE_TESTS:BOOL=$(false_true ${BUILD_TOOLCHAIN_ONLY})
2556-
)
2468+
cmake_options=(
2469+
"${cmake_options[@]}"
2470+
-C${LLDB_SOURCE_DIR}/cmake/caches/${cmake_cache}
2471+
-DCMAKE_BUILD_TYPE:STRING="${LLDB_BUILD_TYPE}"
2472+
-DLLDB_SWIFTC:PATH="$(build_directory ${LOCAL_HOST} swift)/bin/swiftc"
2473+
-DLLDB_SWIFT_LIBS:PATH="$(build_directory ${LOCAL_HOST} swift)/lib/swift"
2474+
-DCMAKE_INSTALL_PREFIX:PATH="$(get_host_install_prefix ${host})"
2475+
-DClang_DIR:PATH=${llvm_build_dir}/lib/cmake/clang
2476+
-DLLVM_DIR:PATH=${llvm_build_dir}/lib/cmake/llvm
2477+
-DLLDB_PATH_TO_CLANG_BUILD:PATH="${llvm_build_dir}"
2478+
-DLLDB_PATH_TO_SWIFT_SOURCE:PATH="${SWIFT_SOURCE_DIR}"
2479+
-DLLDB_PATH_TO_SWIFT_BUILD:PATH="${swift_build_dir}"
2480+
-DLLDB_IS_BUILDBOT_BUILD:BOOL="${LLDB_IS_BUILDBOT_BUILD}"
2481+
-DLLDB_BUILD_DATE:STRING="\"${LLDB_BUILD_DATE}\""
2482+
-DLLDB_ALLOW_STATIC_BINDINGS:BOOL=1
2483+
-DLLDB_INCLUDE_TESTS:BOOL=$(false_true ${BUILD_TOOLCHAIN_ONLY})
2484+
)
25572485

2558-
if [[ "$(uname -s)" == "Darwin" ]] ; then
2559-
cmake_options+=(
2560-
-DLLDB_CODESIGN_IDENTITY=""
2561-
-DLLDB_USE_SYSTEM_DEBUGSERVER:BOOL="${LLDB_USE_SYSTEM_DEBUGSERVER}"
2562-
)
2563-
fi
2486+
if [[ "$(uname -s)" == "Darwin" ]] ; then
2487+
cmake_options+=(
2488+
-DLLDB_CODESIGN_IDENTITY=""
2489+
-DLLDB_USE_SYSTEM_DEBUGSERVER:BOOL="${LLDB_USE_SYSTEM_DEBUGSERVER}"
2490+
)
25642491
fi
25652492
;;
25662493
llbuild)
@@ -3056,34 +2983,7 @@ for host in "${ALL_HOSTS[@]}"; do
30562983
swift_build_dir=$(build_directory ${host} swift)
30572984
module_cache="${build_dir}/module-cache"
30582985

3059-
using_xcodebuild="FALSE"
3060-
if [[ "$(uname -s)" == "Darwin" && "$(true_false ${LLDB_BUILD_WITH_XCODE})" == "TRUE" ]] ; then
3061-
using_xcodebuild="TRUE"
3062-
fi
3063-
3064-
3065-
# Run the unittests.
3066-
# FIXME: The xcode build project currently doesn't know how to run the lit style tests.
3067-
if [[ "$using_xcodebuild" == "TRUE" ]] ; then
3068-
set_lldb_xcodebuild_options
3069-
set_lldb_build_mode
3070-
# Run the LLDB unittests (gtests).
3071-
with_pushd ${LLDB_SOURCE_DIR} \
3072-
call xcodebuild -scheme lldb-gtest -configuration ${LLDB_BUILD_MODE} ${lldb_xcodebuild_options[@]}
3073-
rc=$?
3074-
if [[ "$rc" -ne 0 ]] ; then
3075-
>&2 echo "error: LLDB gtests failed"
3076-
exit 1
3077-
fi
3078-
fi
3079-
3080-
# Setup lldb executable path
3081-
if [[ "$using_xcodebuild" == "TRUE" ]] ; then
3082-
lldb_executable="${lldb_build_dir}"/${LLDB_BUILD_MODE}/lldb
3083-
else
3084-
lldb_executable="${lldb_build_dir}"/bin/lldb
3085-
fi
3086-
2986+
lldb_executable="${lldb_build_dir}"/bin/lldb
30872987
results_dir="${lldb_build_dir}/test-results"
30882988

30892989
# Handle test results formatter
@@ -3156,10 +3056,6 @@ for host in "${ALL_HOSTS[@]}"; do
31563056
fi
31573057
call mkdir -p "${results_dir}"
31583058

3159-
if [[ "$using_xcodebuild" == "TRUE" ]] ; then
3160-
LLDB_DOTEST_CC_OPTS="${LLDB_DOTEST_CC_OPTS} --filecheck $(build_directory $LOCAL_HOST llvm)/bin/FileCheck --dsymutil $(build_directory $LOCAL_HOST llvm)/bin/dsymutil"
3161-
fi
3162-
31633059
# Prefer to use lldb-dotest, as building it guarantees that we build all
31643060
# test dependencies. Ultimately we want to delete as much lldb-specific logic
31653061
# from this file as possible and just have a single call to lldb-dotest.
@@ -3169,65 +3065,32 @@ for host in "${ALL_HOSTS[@]}"; do
31693065
LLVM_LIT_ARGS="${LLVM_LIT_ARGS} -j $(sysctl hw.physicalcpu | awk -v N=${BUILD_JOBS} '{ print (N < $2) ? N : $2 }')"
31703066
fi
31713067

3172-
if [[ "$(true_false ${LLDB_TEST_SWIFT_ONLY})" == "TRUE" ]]; then
3173-
LLVM_LIT_ARGS="${LLVM_LIT_ARGS} --filter=[sS]wift"
3174-
fi
3068+
if [[ "$(true_false ${LLDB_TEST_SWIFT_ONLY})" == "TRUE" ]]; then
3069+
LLVM_LIT_ARGS="${LLVM_LIT_ARGS} --filter=[sS]wift"
3070+
fi
31753071

31763072
# Record the times test took and report the slowest.
31773073
LLVM_LIT_ARGS="${LLVM_LIT_ARGS} -v --time-tests"
3178-
if [[ "$using_xcodebuild" == "FALSE" ]] ; then
3179-
with_pushd ${lldb_build_dir} \
3180-
call ${NINJA_BIN} -j ${BUILD_JOBS} unittests/LLDBUnitTests
3181-
with_pushd ${lldb_build_dir} \
3182-
call ${NINJA_BIN} -j ${BUILD_JOBS} lldb-test-deps
3074+
with_pushd ${lldb_build_dir} \
3075+
call ${NINJA_BIN} -j ${BUILD_JOBS} unittests/LLDBUnitTests
3076+
with_pushd ${lldb_build_dir} \
3077+
call ${NINJA_BIN} -j ${BUILD_JOBS} lldb-test-deps
3078+
with_pushd ${results_dir} \
3079+
call "${llvm_build_dir}/bin/llvm-lit" \
3080+
"${lldb_build_dir}/lit" \
3081+
${LLVM_LIT_ARGS} \
3082+
--xunit-xml-output=${results_dir}/results.xml \
3083+
--param dotest-args="--build-dir ${lldb_build_dir}/lldb-test-build.noindex ${LLDB_TEST_SUBDIR_CLAUSE} ${LLDB_TEST_CATEGORIES} -t -E \"${DOTEST_EXTRA}\""
3084+
if [[ -x "${LLDB_TEST_SWIFT_COMPATIBILITY}" ]] ; then
3085+
echo "Running LLDB swift compatibility tests against" \
3086+
"${LLDB_TEST_SWIFT_COMPATIBILITY}"
31833087
with_pushd ${results_dir} \
3184-
call "${llvm_build_dir}/bin/llvm-lit" \
3185-
"${lldb_build_dir}/lit" \
3186-
${LLVM_LIT_ARGS} \
3187-
--xunit-xml-output=${results_dir}/results.xml \
3188-
--param dotest-args="--build-dir ${lldb_build_dir}/lldb-test-build.noindex ${LLDB_TEST_SUBDIR_CLAUSE} ${LLDB_TEST_CATEGORIES} -t -E \"${DOTEST_EXTRA}\""
3189-
if [[ -x "${LLDB_TEST_SWIFT_COMPATIBILITY}" ]] ; then
3190-
echo "Running LLDB swift compatibility tests against" \
3191-
"${LLDB_TEST_SWIFT_COMPATIBILITY}"
3192-
with_pushd ${results_dir} \
3193-
call "${llvm_build_dir}/bin/llvm-lit" \
3194-
"${lldb_build_dir}/lit" \
3195-
${LLVM_LIT_ARGS} \
3196-
--xunit-xml-output=${results_dir}/results.xml \
3197-
--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}\" -t -E \"${DOTEST_EXTRA}\"" --filter=compat
3198-
fi
3199-
else
3200-
with_pushd "${results_dir}" \
3201-
call env SWIFTC="$(build_directory $LOCAL_HOST swift)/bin/swiftc" \
3202-
SWIFTLIBS="${swift_build_dir}/lib/swift" \
3203-
"${LLDB_SOURCE_DIR}"/test/dotest.py \
3204-
--executable "${lldb_executable}" \
3205-
${LLDB_TEST_DEBUG_SERVER} \
3206-
${LLDB_TEST_SUBDIR_CLAUSE} \
3207-
${LLDB_TEST_CATEGORIES} \
3208-
${LLDB_DOTEST_CC_OPTS} \
3209-
${LLDB_FORMATTER_OPTS} \
3210-
--build-dir "${lldb_build_dir}/lldb-test-build.noindex" \
3211-
-t -E "${DOTEST_EXTRA}"
3212-
if [[ -x "${LLDB_TEST_SWIFT_COMPATIBILITY}" ]] ; then
3213-
echo "Running LLDB swift compatibility tests against" \
3214-
"${LLDB_TEST_SWIFT_COMPATIBILITY}"
3215-
call env SWIFTC="$(build_directory $LOCAL_HOST swift)/bin/swiftc" \
3216-
SWIFTLIBS="${swift_build_dir}/lib/swift" \
3217-
"${LLDB_SOURCE_DIR}"/test/dotest.py \
3218-
--executable "${lldb_executable}" \
3219-
${LLDB_TEST_DEBUG_SERVER} \
3220-
${LLDB_TEST_SUBDIR_CLAUSE} \
3221-
${LLDB_TEST_CATEGORIES} \
3222-
${LLDB_DOTEST_CC_OPTS} \
3223-
${LLDB_FORMATTER_OPTS} \
3224-
--build-dir "${lldb_build_dir}/lldb-test-build.noindex" \
3225-
-G swift-history \
3226-
--swift-compiler "${LLDB_TEST_SWIFT_COMPATIBILITY}" \
3227-
-t -E "${DOTEST_EXTRA}"
3228-
fi
3088+
call "${llvm_build_dir}/bin/llvm-lit" \
3089+
"${lldb_build_dir}/lit" \
3090+
${LLVM_LIT_ARGS} \
3091+
--xunit-xml-output=${results_dir}/results.xml \
3092+
--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}\" -t -E \"${DOTEST_EXTRA}\"" --filter=compat
32293093
fi
3230-
32313094
continue
32323095
;;
32333096
llbuild)
@@ -3575,25 +3438,6 @@ for host in "${ALL_HOSTS[@]}"; do
35753438
echo "--install-destdir is required to install products."
35763439
exit 1
35773440
fi
3578-
if [[ "$using_xcodebuild" == "TRUE" ]] ; then
3579-
case ${host} in
3580-
linux-*)
3581-
;;
3582-
freebsd-*)
3583-
;;
3584-
cygwin-*)
3585-
;;
3586-
haiku-*)
3587-
;;
3588-
macosx-*)
3589-
set_lldb_xcodebuild_options
3590-
set_lldb_build_mode
3591-
with_pushd ${LLDB_SOURCE_DIR} \
3592-
call xcodebuild -target toolchain -configuration ${LLDB_BUILD_MODE} install ${lldb_xcodebuild_options[@]} DSTROOT="${host_install_destdir}" LLDB_TOOLCHAIN_PREFIX="${TOOLCHAIN_PREFIX}"
3593-
continue
3594-
;;
3595-
esac
3596-
fi
35973441
;;
35983442
swiftpm)
35993443
if [[ -z "${INSTALL_SWIFTPM}" ]] ; then

0 commit comments

Comments
 (0)