Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 1 | #!/usr/bin/env bash |
| 2 | #===----------------------------------------------------------------------===## |
| 3 | # |
| 4 | # Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
| 5 | # See https://llvm.org/LICENSE.txt for license information. |
| 6 | # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
| 7 | # |
| 8 | #===----------------------------------------------------------------------===## |
| 9 | |
| 10 | set -ex |
Marek Kurdej | 0544936 | 2021-02-04 21:13:22 +0100 | [diff] [blame] | 11 | set -o pipefail |
Arthur O'Dwyer | 757d5bd | 2021-04-30 14:43:33 -0400 | [diff] [blame] | 12 | unset LANG |
| 13 | unset LC_ALL |
| 14 | unset LC_COLLATE |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 15 | |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 16 | PROGNAME="$(basename "${0}")" |
| 17 | |
| 18 | function usage() { |
| 19 | cat <<EOF |
| 20 | Usage: |
| 21 | ${PROGNAME} [options] <BUILDER> |
| 22 | |
| 23 | [-h|--help] Display this help and exit. |
| 24 | |
| 25 | --llvm-root <DIR> Path to the root of the LLVM monorepo. By default, we try |
| 26 | to figure it out based on the current working directory. |
| 27 | |
Louis Dionne | 04bf103 | 2020-11-05 19:09:03 -0500 | [diff] [blame] | 28 | --build-dir <DIR> The directory to use for building the library. By default, |
| 29 | this is '<llvm-root>/build/<builder>'. |
| 30 | |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 31 | --osx-roots <DIR> Path to pre-downloaded macOS dylibs. By default, we download |
| 32 | them from Green Dragon. This is only relevant at all when |
| 33 | running back-deployment testing if one wants to override |
| 34 | the old dylibs we use to run the tests with different ones. |
| 35 | EOF |
| 36 | } |
| 37 | |
| 38 | while [[ $# -gt 0 ]]; do |
| 39 | case ${1} in |
| 40 | -h|--help) |
| 41 | usage |
| 42 | exit 0 |
| 43 | ;; |
| 44 | --llvm-root) |
| 45 | MONOREPO_ROOT="${2}" |
| 46 | shift; shift |
| 47 | ;; |
Louis Dionne | 04bf103 | 2020-11-05 19:09:03 -0500 | [diff] [blame] | 48 | --build-dir) |
| 49 | BUILD_DIR="${2}" |
| 50 | shift; shift |
| 51 | ;; |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 52 | --osx-roots) |
| 53 | OSX_ROOTS="${2}" |
| 54 | shift; shift |
| 55 | ;; |
| 56 | *) |
| 57 | BUILDER="${1}" |
| 58 | shift |
| 59 | ;; |
| 60 | esac |
| 61 | done |
| 62 | |
| 63 | MONOREPO_ROOT="${MONOREPO_ROOT:="$(git rev-parse --show-toplevel)"}" |
Louis Dionne | 04bf103 | 2020-11-05 19:09:03 -0500 | [diff] [blame] | 64 | BUILD_DIR="${BUILD_DIR:=${MONOREPO_ROOT}/build/${BUILDER}}" |
Louis Dionne | 485f4c0 | 2021-01-07 17:37:09 -0500 | [diff] [blame] | 65 | INSTALL_DIR="${BUILD_DIR}/install" |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 66 | |
Louis Dionne | 6f96e99 | 2021-05-07 13:14:57 -0400 | [diff] [blame] | 67 | # If we can find Ninja/CMake provided by Xcode, use those since we know their |
| 68 | # version will generally work with the Clang shipped in Xcode (e.g. if Clang |
| 69 | # knows about -std=c++20, the CMake bundled in Xcode will probably know about |
| 70 | # that flag too). |
| 71 | if xcrun --find ninja &>/dev/null; then NINJA="$(xcrun --find ninja)"; else NINJA="ninja"; fi |
| 72 | if xcrun --find cmake &>/dev/null; then CMAKE="$(xcrun --find cmake)"; else CMAKE="cmake"; fi |
Louis Dionne | 7a8d536 | 2021-03-04 16:01:36 -0500 | [diff] [blame] | 73 | |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 74 | function clean() { |
| 75 | rm -rf "${BUILD_DIR}" |
| 76 | } |
| 77 | |
Martin Storsjö | 47cd346 | 2021-04-06 00:17:30 +0300 | [diff] [blame] | 78 | function generate-cmake-base() { |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 79 | echo "--- Generating CMake" |
Louis Dionne | 6f96e99 | 2021-05-07 13:14:57 -0400 | [diff] [blame] | 80 | ${CMAKE} \ |
Louis Dionne | 076fd0c | 2021-10-07 16:19:11 -0400 | [diff] [blame] | 81 | -S "${MONOREPO_ROOT}/runtimes" \ |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 82 | -B "${BUILD_DIR}" \ |
Louis Dionne | 7a8d536 | 2021-03-04 16:01:36 -0500 | [diff] [blame] | 83 | -GNinja -DCMAKE_MAKE_PROGRAM="${NINJA}" \ |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 84 | -DCMAKE_BUILD_TYPE=RelWithDebInfo \ |
| 85 | -DCMAKE_INSTALL_PREFIX="${INSTALL_DIR}" \ |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 86 | -DLLVM_LIT_ARGS="-sv --show-unsupported --xunit-xml-output test-results.xml" \ |
Martin Storsjö | 47cd346 | 2021-04-06 00:17:30 +0300 | [diff] [blame] | 87 | "${@}" |
| 88 | } |
| 89 | |
| 90 | function generate-cmake() { |
| 91 | generate-cmake-base \ |
Louis Dionne | 076fd0c | 2021-10-07 16:19:11 -0400 | [diff] [blame] | 92 | -DLLVM_ENABLE_RUNTIMES="libcxx;libcxxabi;libunwind" \ |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 93 | -DLIBCXX_CXX_ABI=libcxxabi \ |
Louis Dionne | 662aaa2 | 2020-11-05 10:47:06 -0500 | [diff] [blame] | 94 | "${@}" |
| 95 | } |
| 96 | |
Martin Storsjö | 47cd346 | 2021-04-06 00:17:30 +0300 | [diff] [blame] | 97 | function generate-cmake-libcxx-win() { |
| 98 | # TODO: Clang-cl in MSVC configurations don't have access to compiler_rt |
| 99 | # builtins helpers for int128 division. See |
| 100 | # https://reviews.llvm.org/D91139#2429595 for a comment about longterm |
| 101 | # intent for handling the issue. In the meantime, define |
| 102 | # -D_LIBCPP_HAS_NO_INT128 (both when building the library itself and |
| 103 | # when building tests) to allow enabling filesystem for running tests, |
| 104 | # even if it uses a non-permanent ABI. |
| 105 | |
| 106 | generate-cmake-base \ |
Louis Dionne | 076fd0c | 2021-10-07 16:19:11 -0400 | [diff] [blame] | 107 | -DLLVM_ENABLE_RUNTIMES="libcxx" \ |
Martin Storsjö | 47cd346 | 2021-04-06 00:17:30 +0300 | [diff] [blame] | 108 | -DCMAKE_C_COMPILER=clang-cl \ |
| 109 | -DCMAKE_CXX_COMPILER=clang-cl \ |
| 110 | -DLIBCXX_ENABLE_FILESYSTEM=YES \ |
| 111 | -DCMAKE_CXX_FLAGS="-D_LIBCPP_HAS_NO_INT128" \ |
| 112 | -DLIBCXX_TEST_COMPILER_FLAGS="-D_LIBCPP_HAS_NO_INT128" \ |
| 113 | "${@}" |
| 114 | } |
| 115 | |
David Tenty | 823e74d | 2021-10-13 11:41:47 -0400 | [diff] [blame] | 116 | function generate-cmake-aix() { |
| 117 | generate-cmake-base \ |
| 118 | -S "${MONOREPO_ROOT}/llvm" \ |
| 119 | -DLLVM_ENABLE_PROJECTS="libcxx;libcxxabi" \ |
| 120 | "${@}" |
| 121 | } |
| 122 | |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 123 | function check-runtimes() { |
| 124 | echo "--- Installing libc++, libc++abi and libunwind to a fake location" |
| 125 | ${NINJA} -vC "${BUILD_DIR}" install-cxx install-cxxabi install-unwind |
Louis Dionne | eacce54 | 2021-03-24 09:50:59 -0400 | [diff] [blame] | 126 | |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 127 | echo "+++ Running the libc++ tests" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 128 | ${NINJA} -vC "${BUILD_DIR}" check-cxx |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 129 | |
| 130 | echo "+++ Running the libc++abi tests" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 131 | ${NINJA} -vC "${BUILD_DIR}" check-cxxabi |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 132 | |
| 133 | echo "+++ Running the libunwind tests" |
| 134 | ${NINJA} -vC "${BUILD_DIR}" check-unwind |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 135 | } |
| 136 | |
Louis Dionne | dfbd00e | 2020-11-26 15:00:42 -0500 | [diff] [blame] | 137 | # TODO: The goal is to test this against all configurations. We should also move |
| 138 | # this to the Lit test suite instead of being a separate CMake target. |
| 139 | function check-abi-list() { |
| 140 | echo "+++ Running the libc++ ABI list test" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 141 | ${NINJA} -vC "${BUILD_DIR}" check-cxx-abilist || ( |
Marek Kurdej | 718b62c | 2020-12-02 08:57:02 +0100 | [diff] [blame] | 142 | echo "+++ Generating the libc++ ABI list after failed check" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 143 | ${NINJA} -vC "${BUILD_DIR}" generate-cxx-abilist |
Marek Kurdej | 718b62c | 2020-12-02 08:57:02 +0100 | [diff] [blame] | 144 | false |
| 145 | ) |
Louis Dionne | dfbd00e | 2020-11-26 15:00:42 -0500 | [diff] [blame] | 146 | } |
| 147 | |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 148 | function check-cxx-benchmarks() { |
| 149 | echo "--- Running the benchmarks" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 150 | ${NINJA} -vC "${BUILD_DIR}" check-cxx-benchmarks |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 151 | } |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 152 | |
Louis Dionne | 6bd3e65 | 2021-04-01 13:40:04 -0400 | [diff] [blame] | 153 | # Print the version of a few tools to aid diagnostics in some cases |
Louis Dionne | 6f96e99 | 2021-05-07 13:14:57 -0400 | [diff] [blame] | 154 | ${CMAKE} --version |
Louis Dionne | 6bd3e65 | 2021-04-01 13:40:04 -0400 | [diff] [blame] | 155 | ${NINJA} --version |
| 156 | |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 157 | case "${BUILDER}" in |
Marek Kurdej | 0544936 | 2021-02-04 21:13:22 +0100 | [diff] [blame] | 158 | check-format) |
| 159 | clean |
| 160 | echo "+++ Checking formatting" |
| 161 | # We need to set --extensions so that clang-format checks extensionless files. |
| 162 | mkdir -p ${BUILD_DIR} |
| 163 | git-clang-format \ |
| 164 | --binary /usr/bin/clang-format --diff \ |
| 165 | --extensions ',h,hh,hpp,hxx,c,cc,cxx,cpp' HEAD~1 \ |
| 166 | -- \ |
| 167 | libcxx/{benchmarks,include,src,test} \ |
| 168 | libcxxabi/{fuzz,include,src,test} \ |
| 169 | | tee ${BUILD_DIR}/clang-format.patch |
| 170 | # Check if the diff is empty, fail otherwise. |
| 171 | ! grep -q '^--- a' ${BUILD_DIR}/clang-format.patch |
| 172 | ;; |
Mark de Wever | 53efa10 | 2021-04-04 20:11:48 +0200 | [diff] [blame] | 173 | check-generated-output) |
Mark de Wever | b10c97d | 2021-04-28 19:13:52 +0200 | [diff] [blame] | 174 | # `! foo` doesn't work properly with `set -e`, use `! foo || false` instead. |
| 175 | # https://stackoverflow.com/questions/57681955/set-e-does-not-respect-logical-not |
Mark de Wever | 53efa10 | 2021-04-04 20:11:48 +0200 | [diff] [blame] | 176 | clean |
Louis Dionne | 8096e24 | 2021-07-15 10:19:39 -0400 | [diff] [blame] | 177 | generate-cmake |
| 178 | |
| 179 | # Reject patches that forgot to re-run the generator scripts. |
| 180 | echo "+++ Making sure the generator scripts were run" |
| 181 | ${NINJA} -vC "${BUILD_DIR}" libcxx-generate-files |
Mark de Wever | 53efa10 | 2021-04-04 20:11:48 +0200 | [diff] [blame] | 182 | git diff | tee ${BUILD_DIR}/generated_output.patch |
Mark de Wever | dfd86e3 | 2021-07-22 11:17:53 +0200 | [diff] [blame] | 183 | git ls-files -o --exclude-standard | tee ${BUILD_DIR}/generated_output.status |
Mark de Wever | b10c97d | 2021-04-28 19:13:52 +0200 | [diff] [blame] | 184 | ! grep -q '^--- a' ${BUILD_DIR}/generated_output.patch || false |
Mark de Wever | dfd86e3 | 2021-07-22 11:17:53 +0200 | [diff] [blame] | 185 | if [ -s ${BUILD_DIR}/generated_output.status ]; then |
| 186 | echo "It looks like not all the generator scripts were run," |
| 187 | echo "did you forget to build the libcxx-generate-files target?" |
| 188 | echo "Did you add all new files it generated?" |
| 189 | false |
| 190 | fi |
Louis Dionne | 8096e24 | 2021-07-15 10:19:39 -0400 | [diff] [blame] | 191 | |
Mark de Wever | b10c97d | 2021-04-28 19:13:52 +0200 | [diff] [blame] | 192 | # Reject patches that introduce non-ASCII characters or hard tabs. |
Arthur O'Dwyer | 757d5bd | 2021-04-30 14:43:33 -0400 | [diff] [blame] | 193 | # Depends on LC_COLLATE set at the top of this script. |
Mark de Wever | b10c97d | 2021-04-28 19:13:52 +0200 | [diff] [blame] | 194 | ! grep -rn '[^ -~]' libcxx/include/ || false |
Louis Dionne | 8096e24 | 2021-07-15 10:19:39 -0400 | [diff] [blame] | 195 | |
| 196 | # Reject patches that introduce dependency cycles in the headers. |
Arthur O'Dwyer | bba78c3 | 2021-04-17 09:56:34 -0400 | [diff] [blame] | 197 | python3 libcxx/utils/graph_header_deps.py >/dev/null |
Mark de Wever | 53efa10 | 2021-04-04 20:11:48 +0200 | [diff] [blame] | 198 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 199 | generic-cxx03) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 200 | clean |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 201 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-cxx03.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 202 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 203 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 204 | check-runtimes |
Louis Dionne | dfbd00e | 2020-11-26 15:00:42 -0500 | [diff] [blame] | 205 | check-abi-list |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 206 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 207 | generic-cxx11) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 208 | clean |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 209 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-cxx11.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 210 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 211 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 212 | check-runtimes |
Louis Dionne | dfbd00e | 2020-11-26 15:00:42 -0500 | [diff] [blame] | 213 | check-abi-list |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 214 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 215 | generic-cxx14) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 216 | clean |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 217 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-cxx14.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 218 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 219 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 220 | check-runtimes |
Louis Dionne | dfbd00e | 2020-11-26 15:00:42 -0500 | [diff] [blame] | 221 | check-abi-list |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 222 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 223 | generic-cxx17) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 224 | clean |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 225 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-cxx17.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 226 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 227 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 228 | check-runtimes |
Louis Dionne | dfbd00e | 2020-11-26 15:00:42 -0500 | [diff] [blame] | 229 | check-abi-list |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 230 | ;; |
Marek Kurdej | 24b4c51 | 2021-01-07 12:29:04 +0100 | [diff] [blame] | 231 | generic-cxx20) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 232 | clean |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 233 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-cxx20.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 234 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 235 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 236 | check-runtimes |
Louis Dionne | dfbd00e | 2020-11-26 15:00:42 -0500 | [diff] [blame] | 237 | check-abi-list |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 238 | ;; |
Marek Kurdej | 758067c | 2021-01-08 18:40:42 +0100 | [diff] [blame] | 239 | generic-cxx2b) |
Marek Kurdej | 758067c | 2021-01-08 18:40:42 +0100 | [diff] [blame] | 240 | clean |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 241 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-cxx2b.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 242 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 243 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 244 | check-runtimes |
Marek Kurdej | 758067c | 2021-01-08 18:40:42 +0100 | [diff] [blame] | 245 | check-abi-list |
| 246 | ;; |
Louis Dionne | 732192e | 2021-06-09 09:41:27 -0400 | [diff] [blame] | 247 | generic-assertions) |
Louis Dionne | 732192e | 2021-06-09 09:41:27 -0400 | [diff] [blame] | 248 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 249 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-assertions.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 250 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 251 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 252 | check-runtimes |
Louis Dionne | 732192e | 2021-06-09 09:41:27 -0400 | [diff] [blame] | 253 | check-abi-list |
| 254 | ;; |
Arthur O'Dwyer | 64e0247 | 2021-04-20 11:27:03 -0400 | [diff] [blame] | 255 | generic-debug-iterators) |
Arthur O'Dwyer | 64e0247 | 2021-04-20 11:27:03 -0400 | [diff] [blame] | 256 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 257 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-debug-iterators.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 258 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 259 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 260 | check-runtimes |
Arthur O'Dwyer | 64e0247 | 2021-04-20 11:27:03 -0400 | [diff] [blame] | 261 | check-abi-list |
| 262 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 263 | generic-noexceptions) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 264 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 265 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-noexceptions.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 266 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 267 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 268 | check-runtimes |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 269 | ;; |
Louis Dionne | 00005a9 | 2021-06-02 17:07:57 -0400 | [diff] [blame] | 270 | generic-modules) |
Louis Dionne | 00005a9 | 2021-06-02 17:07:57 -0400 | [diff] [blame] | 271 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 272 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-modules.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 273 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 274 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 275 | check-runtimes |
Louis Dionne | 00005a9 | 2021-06-02 17:07:57 -0400 | [diff] [blame] | 276 | ;; |
Louis Dionne | eacce54 | 2021-03-24 09:50:59 -0400 | [diff] [blame] | 277 | generic-static) |
Louis Dionne | eacce54 | 2021-03-24 09:50:59 -0400 | [diff] [blame] | 278 | clean |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 279 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-static.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 280 | -DLIBCXX_TEST_CONFIG="llvm-libc++-static.cfg.in" \ |
| 281 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-static.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 282 | check-runtimes |
Louis Dionne | eacce54 | 2021-03-24 09:50:59 -0400 | [diff] [blame] | 283 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 284 | generic-32bit) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 285 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 286 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-32bits.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 287 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 288 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 289 | check-runtimes |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 290 | ;; |
Mark de Wever | d535299 | 2021-10-23 13:08:01 +0200 | [diff] [blame^] | 291 | generic-clang-12) |
| 292 | export CC=clang-12 |
| 293 | export CXX=clang++-12 |
Louis Dionne | 6f4796b | 2021-07-08 12:26:33 -0400 | [diff] [blame] | 294 | clean |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 295 | generate-cmake -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 296 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 297 | check-runtimes |
Louis Dionne | 6f4796b | 2021-07-08 12:26:33 -0400 | [diff] [blame] | 298 | ;; |
Mark de Wever | d535299 | 2021-10-23 13:08:01 +0200 | [diff] [blame^] | 299 | generic-clang-13) |
| 300 | export CC=clang-13 |
| 301 | export CXX=clang++-13 |
Louis Dionne | 6f4796b | 2021-07-08 12:26:33 -0400 | [diff] [blame] | 302 | clean |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 303 | generate-cmake -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 304 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 305 | check-runtimes |
Louis Dionne | 6f4796b | 2021-07-08 12:26:33 -0400 | [diff] [blame] | 306 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 307 | generic-gcc) |
Louis Dionne | 566a51d | 2021-06-15 15:07:03 -0400 | [diff] [blame] | 308 | export CC=gcc-11 |
| 309 | export CXX=g++-11 |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 310 | clean |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 311 | generate-cmake -DLIBCXX_TEST_CONFIG="llvm-libc++-shared-gcc.cfg.in" \ |
| 312 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 313 | check-runtimes |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 314 | ;; |
Louis Dionne | 657b479 | 2021-07-15 09:46:36 -0400 | [diff] [blame] | 315 | generic-gcc-cxx11) |
| 316 | export CC=gcc-11 |
| 317 | export CXX=g++-11 |
| 318 | clean |
Louis Dionne | 1cb657a | 2021-10-07 14:54:14 -0400 | [diff] [blame] | 319 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-cxx11.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 320 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared-gcc.cfg.in" \ |
| 321 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 322 | check-runtimes |
Louis Dionne | 657b479 | 2021-07-15 09:46:36 -0400 | [diff] [blame] | 323 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 324 | generic-asan) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 325 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 326 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-asan.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 327 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 328 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 329 | check-runtimes |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 330 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 331 | generic-msan) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 332 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 333 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-msan.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 334 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 335 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 336 | check-runtimes |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 337 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 338 | generic-tsan) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 339 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 340 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-tsan.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 341 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 342 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 343 | check-runtimes |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 344 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 345 | generic-ubsan) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 346 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 347 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-ubsan.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 348 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 349 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 350 | check-runtimes |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 351 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 352 | generic-with_llvm_unwinder) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 353 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 354 | generate-cmake -DLIBCXXABI_USE_LLVM_UNWINDER=ON \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 355 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 356 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 357 | check-runtimes |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 358 | ;; |
Louis Dionne | 6f8038c | 2020-10-01 13:55:39 -0400 | [diff] [blame] | 359 | generic-singlethreaded) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 360 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 361 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-singlethreaded.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 362 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 363 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 364 | check-runtimes |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 365 | ;; |
Louis Dionne | abcfdbc | 2021-03-23 14:09:52 -0400 | [diff] [blame] | 366 | generic-no-debug) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 367 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 368 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-no-debug.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 369 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 370 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 371 | check-runtimes |
Louis Dionne | 4396f9b | 2020-10-06 16:46:58 -0400 | [diff] [blame] | 372 | ;; |
Louis Dionne | db84e12 | 2021-01-18 12:18:18 -0500 | [diff] [blame] | 373 | generic-no-filesystem) |
Louis Dionne | db84e12 | 2021-01-18 12:18:18 -0500 | [diff] [blame] | 374 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 375 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-no-filesystem.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 376 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 377 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 378 | check-runtimes |
Louis Dionne | db84e12 | 2021-01-18 12:18:18 -0500 | [diff] [blame] | 379 | ;; |
Louis Dionne | 3777e68 | 2020-10-15 10:32:09 -0400 | [diff] [blame] | 380 | generic-no-random_device) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 381 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 382 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-no-random_device.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 383 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 384 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 385 | check-runtimes |
Louis Dionne | 3777e68 | 2020-10-15 10:32:09 -0400 | [diff] [blame] | 386 | ;; |
Louis Dionne | 8d053eb | 2020-10-09 15:31:05 -0400 | [diff] [blame] | 387 | generic-no-localization) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 388 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 389 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-no-localization.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 390 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 391 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 392 | check-runtimes |
Louis Dionne | 8d053eb | 2020-10-09 15:31:05 -0400 | [diff] [blame] | 393 | ;; |
Mark de Wever | ebbd3b6 | 2021-05-25 20:11:08 +0200 | [diff] [blame] | 394 | generic-no-unicode) |
Mark de Wever | ebbd3b6 | 2021-05-25 20:11:08 +0200 | [diff] [blame] | 395 | clean |
Louis Dionne | 24a32ac | 2021-10-05 13:37:43 -0400 | [diff] [blame] | 396 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-no-unicode.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 397 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 398 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 399 | check-runtimes |
Mark de Wever | ebbd3b6 | 2021-05-25 20:11:08 +0200 | [diff] [blame] | 400 | ;; |
Louis Dionne | 8925814 | 2021-08-23 15:32:36 -0400 | [diff] [blame] | 401 | generic-no-wide-characters) |
| 402 | clean |
| 403 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-no-wide-characters.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 404 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 405 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 8925814 | 2021-08-23 15:32:36 -0400 | [diff] [blame] | 406 | check-runtimes |
| 407 | ;; |
Louis Dionne | a93dd78 | 2021-10-15 00:21:26 -0400 | [diff] [blame] | 408 | apple-system) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 409 | clean |
Louis Dionne | a93dd78 | 2021-10-15 00:21:26 -0400 | [diff] [blame] | 410 | |
| 411 | sdk_root="$(xcrun --sdk macosx --show-sdk-path)" |
| 412 | arch="$(uname -m)" |
| 413 | |
| 414 | ${MONOREPO_ROOT}/libcxx/utils/ci/apple-install-libcxx.sh \ |
| 415 | --llvm-root ${MONOREPO_ROOT} \ |
| 416 | --build-dir ${BUILD_DIR} \ |
| 417 | --install-dir ${INSTALL_DIR} \ |
| 418 | --symbols-dir "${BUILD_DIR}/symbols" \ |
| 419 | --sdk "macosx" \ |
| 420 | --architectures "${arch}" \ |
| 421 | --version "999.99" |
| 422 | |
| 423 | # TODO: It would be better to run the tests against the fake-installed version of libc++ instead |
| 424 | xcrun --sdk macosx ninja -vC "${BUILD_DIR}/${arch}" check-cxx check-cxxabi |
Louis Dionne | 89d0eb2 | 2020-10-01 08:55:40 -0400 | [diff] [blame] | 425 | ;; |
Louis Dionne | a93dd78 | 2021-10-15 00:21:26 -0400 | [diff] [blame] | 426 | apple-system-backdeployment-*) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 427 | clean |
Louis Dionne | 662aaa2 | 2020-11-05 10:47:06 -0500 | [diff] [blame] | 428 | |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 429 | if [[ "${OSX_ROOTS}" == "" ]]; then |
| 430 | echo "--- Downloading previous macOS dylibs" |
Louis Dionne | c767535 | 2021-03-25 14:14:20 -0400 | [diff] [blame] | 431 | PREVIOUS_DYLIBS_URL="https://dl.dropboxusercontent.com/s/liu4fmc53qzlfly/libcxx-roots.tar.gz" |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 432 | OSX_ROOTS="${BUILD_DIR}/macos-roots" |
| 433 | mkdir -p "${OSX_ROOTS}" |
| 434 | curl "${PREVIOUS_DYLIBS_URL}" | tar -xz --strip-components=1 -C "${OSX_ROOTS}" |
| 435 | fi |
Louis Dionne | 662aaa2 | 2020-11-05 10:47:06 -0500 | [diff] [blame] | 436 | |
Louis Dionne | a93dd78 | 2021-10-15 00:21:26 -0400 | [diff] [blame] | 437 | DEPLOYMENT_TARGET="${BUILDER#apple-system-backdeployment-}" |
Louis Dionne | 84ad13b | 2020-07-08 16:38:54 -0400 | [diff] [blame] | 438 | |
| 439 | # TODO: On Apple platforms, we never produce libc++abi.1.dylib, always libc++abi.dylib. |
| 440 | # Fix that in the build so that the tests stop searching for @rpath/libc++abi.1.dylib. |
| 441 | cp "${OSX_ROOTS}/macOS/libc++abi/${DEPLOYMENT_TARGET}/libc++abi.dylib" \ |
| 442 | "${OSX_ROOTS}/macOS/libc++abi/${DEPLOYMENT_TARGET}/libc++abi.1.dylib" |
| 443 | |
Louis Dionne | a93dd78 | 2021-10-15 00:21:26 -0400 | [diff] [blame] | 444 | arch="$(uname -m)" |
| 445 | PARAMS="target_triple=${arch}-apple-macosx${DEPLOYMENT_TARGET}" |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 446 | PARAMS+=";cxx_runtime_root=${OSX_ROOTS}/macOS/libc++/${DEPLOYMENT_TARGET}" |
Louis Dionne | 84ad13b | 2020-07-08 16:38:54 -0400 | [diff] [blame] | 447 | PARAMS+=";abi_runtime_root=${OSX_ROOTS}/macOS/libc++abi/${DEPLOYMENT_TARGET}" |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 448 | PARAMS+=";use_system_cxx_lib=True" |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 449 | |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 450 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Apple.cmake" \ |
| 451 | -DLIBCXX_TEST_PARAMS="${PARAMS}" \ |
| 452 | -DLIBCXXABI_TEST_PARAMS="${PARAMS}" |
| 453 | |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 454 | check-runtimes |
Louis Dionne | 662aaa2 | 2020-11-05 10:47:06 -0500 | [diff] [blame] | 455 | ;; |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 456 | benchmarks) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 457 | clean |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 458 | generate-cmake -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 459 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | f9c11b0 | 2020-10-23 10:02:14 -0400 | [diff] [blame] | 460 | check-cxx-benchmarks |
Louis Dionne | 89d0eb2 | 2020-10-01 08:55:40 -0400 | [diff] [blame] | 461 | ;; |
Louis Dionne | aa4e44f | 2020-11-05 14:34:29 -0500 | [diff] [blame] | 462 | documentation) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 463 | clean |
| 464 | generate-cmake -DLLVM_ENABLE_SPHINX=ON |
| 465 | |
| 466 | echo "+++ Generating documentation" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 467 | ${NINJA} -vC "${BUILD_DIR}" docs-libcxx-html |
Louis Dionne | aa4e44f | 2020-11-05 14:34:29 -0500 | [diff] [blame] | 468 | ;; |
Louis Dionne | 64a3f22 | 2021-10-20 17:43:55 -0400 | [diff] [blame] | 469 | bootstrapping-build) |
Louis Dionne | 61b63fd | 2021-03-16 11:57:42 -0700 | [diff] [blame] | 470 | clean |
| 471 | |
| 472 | echo "--- Generating CMake" |
Louis Dionne | 64a3f22 | 2021-10-20 17:43:55 -0400 | [diff] [blame] | 473 | # TODO: We currently enable modules and assertions in the bootstrapping build |
Louis Dionne | 65faaa7 | 2021-06-14 14:36:13 -0400 | [diff] [blame] | 474 | # because that provides coverage for some specific Clang failures |
| 475 | # we've been seeing recently, however it would be better to instead |
| 476 | # run all CI configurations against a Clang that has assertions enabled. |
Louis Dionne | 6f96e99 | 2021-05-07 13:14:57 -0400 | [diff] [blame] | 477 | ${CMAKE} \ |
| 478 | -S "${MONOREPO_ROOT}/llvm" \ |
Louis Dionne | 61b63fd | 2021-03-16 11:57:42 -0700 | [diff] [blame] | 479 | -B "${BUILD_DIR}" \ |
Louis Dionne | 6f96e99 | 2021-05-07 13:14:57 -0400 | [diff] [blame] | 480 | -GNinja -DCMAKE_MAKE_PROGRAM="${NINJA}" \ |
Louis Dionne | 61b63fd | 2021-03-16 11:57:42 -0700 | [diff] [blame] | 481 | -DCMAKE_BUILD_TYPE=RelWithDebInfo \ |
| 482 | -DCMAKE_INSTALL_PREFIX="${INSTALL_DIR}" \ |
| 483 | -DLLVM_ENABLE_PROJECTS="clang" \ |
| 484 | -DLLVM_ENABLE_RUNTIMES="libcxx;libcxxabi" \ |
Christopher Di Bella | a49edef | 2021-06-08 00:09:36 +0000 | [diff] [blame] | 485 | -DLLVM_RUNTIME_TARGETS="x86_64-unknown-linux-gnu" \ |
Louis Dionne | 65faaa7 | 2021-06-14 14:36:13 -0400 | [diff] [blame] | 486 | -DLLVM_ENABLE_ASSERTIONS=ON \ |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 487 | -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-modules.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 488 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 489 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 61b63fd | 2021-03-16 11:57:42 -0700 | [diff] [blame] | 490 | |
| 491 | echo "+++ Running the libc++ and libc++abi tests" |
| 492 | ${NINJA} -C "${BUILD_DIR}" check-runtimes |
| 493 | |
| 494 | echo "--- Installing libc++ and libc++abi to a fake location" |
Louis Dionne | 4b1b70d | 2021-07-06 10:39:01 -0400 | [diff] [blame] | 495 | ${NINJA} -C "${BUILD_DIR}" install-runtimes |
Louis Dionne | 61b63fd | 2021-03-16 11:57:42 -0700 | [diff] [blame] | 496 | ;; |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 497 | legacy-test-config) |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 498 | clean |
Louis Dionne | 6be4405 | 2021-09-29 15:26:05 -0400 | [diff] [blame] | 499 | generate-cmake -DLIBCXX_TEST_CONFIG="legacy.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 500 | check-runtimes |
Louis Dionne | 77fc7de | 2021-02-26 13:18:21 -0500 | [diff] [blame] | 501 | ;; |
Louis Dionne | 076fd0c | 2021-10-07 16:19:11 -0400 | [diff] [blame] | 502 | legacy-project-build) |
| 503 | clean |
| 504 | |
| 505 | echo "--- Generating CMake" |
| 506 | ${CMAKE} \ |
| 507 | -S "${MONOREPO_ROOT}/llvm" \ |
| 508 | -B "${BUILD_DIR}" \ |
| 509 | -DLLVM_ENABLE_PROJECTS="libcxx;libunwind;libcxxabi" \ |
| 510 | -GNinja -DCMAKE_MAKE_PROGRAM="${NINJA}" \ |
| 511 | -DCMAKE_BUILD_TYPE=RelWithDebInfo \ |
| 512 | -DCMAKE_INSTALL_PREFIX="${INSTALL_DIR}" \ |
| 513 | -DLLVM_LIT_ARGS="-sv --show-unsupported --xunit-xml-output test-results.xml" \ |
| 514 | -DLIBCXX_CXX_ABI=libcxxabi |
| 515 | check-runtimes |
| 516 | ;; |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 517 | legacy-standalone) |
Louis Dionne | bb7be75 | 2020-11-05 19:02:32 -0500 | [diff] [blame] | 518 | clean |
| 519 | |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 520 | echo "--- Generating CMake" |
Louis Dionne | 6f96e99 | 2021-05-07 13:14:57 -0400 | [diff] [blame] | 521 | ${CMAKE} \ |
| 522 | -S "${MONOREPO_ROOT}/libcxx" \ |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 523 | -B "${BUILD_DIR}/libcxx" \ |
Louis Dionne | 7a8d536 | 2021-03-04 16:01:36 -0500 | [diff] [blame] | 524 | -GNinja -DCMAKE_MAKE_PROGRAM="${NINJA}" \ |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 525 | -DCMAKE_BUILD_TYPE=RelWithDebInfo \ |
| 526 | -DCMAKE_INSTALL_PREFIX="${INSTALL_DIR}" \ |
| 527 | -DLLVM_PATH="${MONOREPO_ROOT}/llvm" \ |
| 528 | -DLIBCXX_CXX_ABI=libcxxabi \ |
| 529 | -DLIBCXX_CXX_ABI_INCLUDE_PATHS="${MONOREPO_ROOT}/libcxxabi/include" \ |
| 530 | -DLIBCXX_CXX_ABI_LIBRARY_PATH="${BUILD_DIR}/libcxxabi/lib" |
| 531 | |
Louis Dionne | 6f96e99 | 2021-05-07 13:14:57 -0400 | [diff] [blame] | 532 | ${CMAKE} \ |
| 533 | -S "${MONOREPO_ROOT}/libcxxabi" \ |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 534 | -B "${BUILD_DIR}/libcxxabi" \ |
Louis Dionne | 7a8d536 | 2021-03-04 16:01:36 -0500 | [diff] [blame] | 535 | -GNinja -DCMAKE_MAKE_PROGRAM="${NINJA}" \ |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 536 | -DCMAKE_BUILD_TYPE=RelWithDebInfo \ |
| 537 | -DCMAKE_INSTALL_PREFIX="${INSTALL_DIR}" \ |
| 538 | -DLLVM_PATH="${MONOREPO_ROOT}/llvm" \ |
| 539 | -DLIBCXXABI_LIBCXX_PATH="${MONOREPO_ROOT}/libcxx" \ |
Louis Dionne | 94870d8 | 2020-06-26 12:08:59 -0400 | [diff] [blame] | 540 | -DLIBCXXABI_LIBCXX_INCLUDES="${BUILD_DIR}/libcxx/include/c++/v1" \ |
Louis Dionne | 5be8b09 | 2020-10-26 14:25:49 -0400 | [diff] [blame] | 541 | -DLIBCXXABI_LIBCXX_LIBRARY_PATH="${BUILD_DIR}/libcxx/lib" |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 542 | |
Louis Dionne | 94870d8 | 2020-06-26 12:08:59 -0400 | [diff] [blame] | 543 | echo "+++ Generating libc++ headers" |
| 544 | ${NINJA} -vC "${BUILD_DIR}/libcxx" generate-cxx-headers |
| 545 | |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 546 | echo "+++ Building libc++abi" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 547 | ${NINJA} -vC "${BUILD_DIR}/libcxxabi" cxxabi |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 548 | |
| 549 | echo "+++ Building libc++" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 550 | ${NINJA} -vC "${BUILD_DIR}/libcxx" cxx |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 551 | |
| 552 | echo "+++ Running the libc++ tests" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 553 | ${NINJA} -vC "${BUILD_DIR}/libcxx" check-cxx |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 554 | |
| 555 | echo "+++ Running the libc++abi tests" |
Louis Dionne | 1fcb041 | 2021-03-19 16:26:15 -0700 | [diff] [blame] | 556 | ${NINJA} -vC "${BUILD_DIR}/libcxxabi" check-cxxabi |
Louis Dionne | 435c36b | 2020-10-23 16:27:41 -0400 | [diff] [blame] | 557 | ;; |
David Spickett | 77471a1 | 2021-02-08 10:43:21 +0000 | [diff] [blame] | 558 | aarch64) |
| 559 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 560 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/AArch64.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 561 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 562 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 563 | check-runtimes |
David Spickett | 77471a1 | 2021-02-08 10:43:21 +0000 | [diff] [blame] | 564 | ;; |
| 565 | aarch64-noexceptions) |
| 566 | clean |
| 567 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/AArch64.cmake" \ |
Louis Dionne | 4b85fc3 | 2021-07-15 13:29:47 -0400 | [diff] [blame] | 568 | -DLIBCXX_ENABLE_EXCEPTIONS=OFF \ |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 569 | -DLIBCXXABI_ENABLE_EXCEPTIONS=OFF \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 570 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 571 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 572 | check-runtimes |
David Spickett | 77471a1 | 2021-02-08 10:43:21 +0000 | [diff] [blame] | 573 | ;; |
David Spickett | a16b886 | 2021-03-02 15:07:19 +0000 | [diff] [blame] | 574 | # Aka Armv8 32 bit |
| 575 | armv8) |
| 576 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 577 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Armv8Arm.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 578 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 579 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 580 | check-runtimes |
David Spickett | a16b886 | 2021-03-02 15:07:19 +0000 | [diff] [blame] | 581 | ;; |
| 582 | armv8-noexceptions) |
| 583 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 584 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Armv8Thumb-noexceptions.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 585 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 586 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 587 | check-runtimes |
David Spickett | a16b886 | 2021-03-02 15:07:19 +0000 | [diff] [blame] | 588 | ;; |
| 589 | # Armv7 32 bit. One building Arm only one Thumb only code. |
| 590 | armv7) |
| 591 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 592 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Armv7Arm.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 593 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 594 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 595 | check-runtimes |
David Spickett | a16b886 | 2021-03-02 15:07:19 +0000 | [diff] [blame] | 596 | ;; |
| 597 | armv7-noexceptions) |
| 598 | clean |
Louis Dionne | 81b7dc2 | 2021-05-31 12:44:48 -0400 | [diff] [blame] | 599 | generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Armv7Thumb-noexceptions.cmake" \ |
Louis Dionne | 16b20d0 | 2021-10-12 12:46:21 -0400 | [diff] [blame] | 600 | -DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \ |
| 601 | -DLIBUNWIND_TEST_CONFIG="llvm-libunwind-shared.cfg.in" |
Louis Dionne | 1f54452 | 2021-09-30 15:11:48 -0400 | [diff] [blame] | 602 | check-runtimes |
David Spickett | a16b886 | 2021-03-02 15:07:19 +0000 | [diff] [blame] | 603 | ;; |
Martin Storsjö | 47cd346 | 2021-04-06 00:17:30 +0300 | [diff] [blame] | 604 | windows-dll) |
Martin Storsjö | 2ffae01 | 2021-03-17 12:10:42 +0200 | [diff] [blame] | 605 | clean |
Martin Storsjö | 2ffae01 | 2021-03-17 12:10:42 +0200 | [diff] [blame] | 606 | # TODO: Currently, building with the experimental library breaks running |
| 607 | # tests (the test linking look for the c++experimental library with the |
| 608 | # wrong name, and the statically linked c++experimental can't be linked |
| 609 | # correctly when libc++ visibility attributes indicate dllimport linkage |
| 610 | # anyway), thus just disable the experimental library. Remove this |
| 611 | # setting when cmake and the test driver does the right thing automatically. |
Martin Storsjö | 47cd346 | 2021-04-06 00:17:30 +0300 | [diff] [blame] | 612 | generate-cmake-libcxx-win -DLIBCXX_ENABLE_EXPERIMENTAL_LIBRARY=OFF |
| 613 | echo "+++ Running the libc++ tests" |
| 614 | ${NINJA} -vC "${BUILD_DIR}" check-cxx |
| 615 | ;; |
| 616 | windows-static) |
| 617 | clean |
| 618 | generate-cmake-libcxx-win -DLIBCXX_ENABLE_SHARED=OFF |
Martin Storsjö | 2ffae01 | 2021-03-17 12:10:42 +0200 | [diff] [blame] | 619 | echo "+++ Running the libc++ tests" |
| 620 | ${NINJA} -vC "${BUILD_DIR}" check-cxx |
| 621 | ;; |
David Tenty | 823e74d | 2021-10-13 11:41:47 -0400 | [diff] [blame] | 622 | aix) |
| 623 | export CC=ibm-clang |
| 624 | export CXX=ibm-clang++_r |
| 625 | clean |
| 626 | generate-cmake-aix -C "${MONOREPO_ROOT}/libcxx/cmake/caches/AIX.cmake" \ |
| 627 | -DLIBCXX_TEST_CONFIG="ibm-libc++-shared.cfg.in" \ |
| 628 | -DLIBCXXABI_TEST_CONFIG="ibm-libc++abi-shared.cfg.in" |
| 629 | # TODO: use check-runtimes once libunwind builds cleanly on AIX. |
| 630 | ${NINJA} -vC "${BUILD_DIR}" install-cxx install-cxxabi |
| 631 | ${NINJA} -vC "${BUILD_DIR}" check-cxx check-cxxabi |
| 632 | ;; |
Louis Dionne | 04915f9 | 2021-05-27 16:51:38 -0400 | [diff] [blame] | 633 | ################################################################# |
| 634 | # Insert vendor-specific internal configurations below. |
| 635 | # |
| 636 | # This allows vendors to extend this file with their own internal |
| 637 | # configurations without running into merge conflicts with upstream. |
| 638 | ################################################################# |
| 639 | |
| 640 | ################################################################# |
Louis Dionne | ce55605 | 2020-09-23 09:20:03 -0400 | [diff] [blame] | 641 | *) |
| 642 | echo "${BUILDER} is not a known configuration" |
| 643 | exit 1 |
| 644 | ;; |
| 645 | esac |