mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Remove ICU from the toolchain (#75262)
* Remove ICU from the toolchain * Remove icu comment from GettingStarted.md
This commit is contained in:
@@ -135,9 +135,6 @@ toolchain as a one-off, there are a couple of differences:
|
||||
- Before running `update-checkout`, double-check that `swift` is the only
|
||||
repository inside the `swift-project` directory. Otherwise,
|
||||
`update-checkout` may not clone the necessary dependencies.
|
||||
- Running `update-checkout` may fail if the `git-lfs` dependency is not
|
||||
installed. This may report as an error related to `icu`. A workaround is
|
||||
passing `--skip-repository icu` to `update-checkout`.
|
||||
|
||||
## Installing dependencies
|
||||
|
||||
|
||||
@@ -840,7 +840,6 @@ llbuild
|
||||
swiftpm
|
||||
swift-driver
|
||||
xctest
|
||||
libicu
|
||||
swiftdocc
|
||||
swiftformat
|
||||
|
||||
@@ -854,7 +853,6 @@ install-swiftpm
|
||||
install-swift-driver
|
||||
install-swiftsyntax
|
||||
install-xctest
|
||||
install-libicu
|
||||
install-prefix=/usr
|
||||
install-sourcekit-lsp
|
||||
install-swiftformat
|
||||
@@ -951,7 +949,6 @@ skip-test-xctest
|
||||
skip-test-foundation
|
||||
skip-test-libdispatch
|
||||
skip-test-playgroundsupport
|
||||
skip-test-libicu
|
||||
skip-test-indexstore-db
|
||||
skip-test-sourcekit-lsp
|
||||
skip-test-swiftdocc
|
||||
@@ -1179,7 +1176,6 @@ mixin-preset=
|
||||
mixin_linux_install_components_with_clang
|
||||
build-subdir=buildbot_incremental
|
||||
|
||||
libicu
|
||||
llbuild
|
||||
swiftpm
|
||||
swift-driver
|
||||
@@ -1194,7 +1190,6 @@ install-llvm
|
||||
install-static-linux-config
|
||||
install-swift
|
||||
install-llbuild
|
||||
install-libicu
|
||||
install-swiftpm
|
||||
install-swift-driver
|
||||
install-swiftsyntax
|
||||
@@ -1788,7 +1783,6 @@ skip-test-osx
|
||||
llvm-cmake-options=-DCLANG_DEFAULT_LINKER=gold
|
||||
|
||||
foundation
|
||||
libicu
|
||||
libdispatch
|
||||
test
|
||||
|
||||
@@ -1832,17 +1826,14 @@ mixin-preset=
|
||||
mixin_linux_install_components_with_clang
|
||||
|
||||
libdispatch
|
||||
libicu
|
||||
foundation
|
||||
xctest
|
||||
libcxx=false
|
||||
|
||||
install-libicu
|
||||
install-foundation
|
||||
install-libdispatch
|
||||
install-xctest
|
||||
|
||||
skip-test-libicu
|
||||
skip-test-foundation
|
||||
skip-test-libdispatch
|
||||
skip-test-xctest
|
||||
@@ -2113,7 +2104,6 @@ mixin-preset=buildbot_indexstoredb_linux,sanitize
|
||||
mixin-preset=
|
||||
mixin_linux_install_components_with_clang
|
||||
|
||||
libicu
|
||||
llbuild
|
||||
swiftpm
|
||||
xctest
|
||||
@@ -2129,7 +2119,6 @@ reconfigure
|
||||
|
||||
install-foundation
|
||||
install-libdispatch
|
||||
install-libicu
|
||||
install-libcxx
|
||||
install-llvm
|
||||
install-static-linux-config
|
||||
@@ -3056,7 +3045,6 @@ mixin-preset=
|
||||
[preset: linux_lldb]
|
||||
lldb
|
||||
foundation
|
||||
libicu
|
||||
libdispatch
|
||||
build-ninja
|
||||
|
||||
|
||||
@@ -298,7 +298,6 @@ components=(
|
||||
foundation
|
||||
libcxx
|
||||
libdispatch
|
||||
libicu
|
||||
libxml2
|
||||
zlib
|
||||
curl
|
||||
@@ -1249,7 +1248,6 @@ FOUNDATION_SWIFTFOUNDATION_SOURCE_DIR="${WORKSPACE}/swift-foundation"
|
||||
FOUNDATION_SWIFTFOUNDATIONICU_SOURCE_DIR="${WORKSPACE}/swift-foundation-icu"
|
||||
LIBDISPATCH_SOURCE_DIR="${WORKSPACE}/swift-corelibs-libdispatch"
|
||||
LIBDISPATCH_STATIC_SOURCE_DIR="${WORKSPACE}/swift-corelibs-libdispatch"
|
||||
LIBICU_SOURCE_DIR="${WORKSPACE}/icu"
|
||||
LIBCXX_SOURCE_DIR="${WORKSPACE}/llvm-project/runtimes"
|
||||
SWIFT_COLLECTIONS_SOURCE_DIR="${WORKSPACE}/swift-collections"
|
||||
SWIFT_PATH_TO_STRING_PROCESSING_SOURCE="${WORKSPACE}/swift-experimental-string-processing"
|
||||
@@ -1257,7 +1255,6 @@ SWIFTSYNTAX_SOURCE_DIR="${WORKSPACE}/swift-syntax"
|
||||
SWIFT_SYNTAX_SOURCE_DIR="${WORKSPACE}/swift-syntax"
|
||||
|
||||
[[ "${SKIP_BUILD_LIBCXX}" ]] || PRODUCTS+=(libcxx)
|
||||
[[ "${SKIP_BUILD_LIBICU}" ]] || PRODUCTS+=(libicu)
|
||||
[[ "${SKIP_BUILD_SWIFT}" ]] || PRODUCTS+=(swift)
|
||||
[[ "${SKIP_BUILD_LLDB}" ]] || PRODUCTS+=(lldb)
|
||||
[[ "${SKIP_BUILD_LIBDISPATCH}" ]] || PRODUCTS+=(libdispatch)
|
||||
@@ -1345,8 +1342,6 @@ function build_directory_bin() {
|
||||
libdispatch|libdispatch_static)
|
||||
echo "${root}/${LIBDISPATCH_BUILD_TYPE}/bin"
|
||||
;;
|
||||
libicu)
|
||||
;;
|
||||
*)
|
||||
echo "error: unknown product: ${product}"
|
||||
exit 1
|
||||
@@ -1485,8 +1480,6 @@ function cmake_config_opt() {
|
||||
libdispatch|libdispatch_static)
|
||||
echo "--config ${LIBDISPATCH_BUILD_TYPE}"
|
||||
;;
|
||||
libicu)
|
||||
;;
|
||||
*)
|
||||
echo "error: unknown product: ${product}"
|
||||
exit 1
|
||||
@@ -2420,29 +2413,6 @@ for host in "${ALL_HOSTS[@]}"; do
|
||||
continue
|
||||
fi
|
||||
|
||||
if [[ ! "${SKIP_BUILD_LIBICU}" ]] ; then
|
||||
ICU_ROOT=$(build_directory ${host} libicu)/tmp_install
|
||||
ICU_LIBDIR="$(build_directory ${host} swift)/lib/swift/${SWIFT_HOST_VARIANT}/${SWIFT_HOST_VARIANT_ARCH}"
|
||||
LIBICU_BUILD_ARGS=(
|
||||
-DICU_ROOT:PATH=${ICU_ROOT}
|
||||
-DICU_INCLUDE_DIR:PATH=${ICU_ROOT}/include
|
||||
-DICU_DATA_LIBRARIES:FILEPATH=${ICU_LIBDIR}/libicudataswift.so
|
||||
-DICU_DATA_LIBRARY:FILEPATH=${ICU_LIBDIR}/libicudataswift.so
|
||||
-DICU_DATA_LIBRARY_DEBUG:FILEPATH=${ICU_LIBDIR}/libicudataswift.so
|
||||
-DICU_DATA_LIBRARY_RELEASE:FILEPATH=${ICU_LIBDIR}/libicudataswift.so
|
||||
-DICU_UC_LIBRARIES:FILEPATH=${ICU_LIBDIR}/libicuucswift.so
|
||||
-DICU_UC_LIBRARY:FILEPATH=${ICU_LIBDIR}/libicuucswift.so
|
||||
-DICU_UC_LIBRARY_DEBUG:FILEPATH=${ICU_LIBDIR}/libicuucswift.so
|
||||
-DICU_UC_LIBRARY_RELEASE:FILEPATH=${ICU_LIBDIR}/libicuucswift.so
|
||||
-DICU_I18N_LIBRARIES:FILEPATH=${ICU_LIBDIR}/libicui18nswift.so
|
||||
-DICU_I18N_LIBRARY:FILEPATH=${ICU_LIBDIR}/libicui18nswift.so
|
||||
-DICU_I18N_LIBRARY_DEBUG:FILEPATH=${ICU_LIBDIR}/libicui18nswift.so
|
||||
-DICU_I18N_LIBRARY_RELEASE:FILEPATH=${ICU_LIBDIR}/libicui18nswift.so
|
||||
)
|
||||
else
|
||||
LIBICU_BUILD_ARGS=()
|
||||
fi
|
||||
|
||||
if [[ ! "${SKIP_BUILD_LIBXML2}" ]]; then
|
||||
BASE_INSTALL_DIR="$(get_host_install_destdir ${host})"
|
||||
LIBXML2_HEADERS="${BASE_INSTALL_DIR}/usr/include/libxml2"
|
||||
@@ -2506,12 +2476,6 @@ for host in "${ALL_HOSTS[@]}"; do
|
||||
call rm -rf "${build_dir}"
|
||||
fi
|
||||
|
||||
# Set the PKG_CONFIG_PATH so that core-foundation can find the libraries and
|
||||
# header files
|
||||
LIBICU_BUILD_DIR="$(build_directory ${host} libicu)"
|
||||
export PKG_CONFIG_PATH="${LIBICU_BUILD_DIR}/config:${PKG_CONFIG_PATH}"
|
||||
export LD_LIBRARY_PATH="${LD_LIBRARY_PATH}":"${LIBICU_BUILD_DIR}/lib"
|
||||
|
||||
cmake_options=(
|
||||
${cmake_options[@]}
|
||||
-DCMAKE_BUILD_TYPE:STRING=${FOUNDATION_BUILD_TYPE}
|
||||
@@ -2522,8 +2486,6 @@ for host in "${ALL_HOSTS[@]}"; do
|
||||
-DCMAKE_Swift_FLAGS:STRING="$(common_swift_flags)"
|
||||
-DCMAKE_INSTALL_PREFIX:PATH=$(get_host_install_prefix ${host})
|
||||
|
||||
${LIBICU_BUILD_ARGS[@]}
|
||||
|
||||
${LIBXML2_BUILD_ARGS[@]}
|
||||
|
||||
${ZLIB_BUILD_ARGS[@]}
|
||||
@@ -2551,7 +2513,7 @@ for host in "${ALL_HOSTS[@]}"; do
|
||||
if [[ $(is_cross_tools_host ${host}) ]] ; then
|
||||
cmake_options+=("${SWIFT_TARGET_CMAKE_OPTIONS[@]}")
|
||||
|
||||
# Foundation looks for the ICU, libXML2 and libcurl libraries
|
||||
# Foundation looks for the libXML2 and libcurl libraries
|
||||
# using find_package(), so search for them in
|
||||
# CROSS_COMPILE_DEPS_PATH using the CMake process for doing
|
||||
# so, see the linked CMake docs for more info:
|
||||
@@ -2611,62 +2573,6 @@ for host in "${ALL_HOSTS[@]}"; do
|
||||
;;
|
||||
esac
|
||||
|
||||
;;
|
||||
libicu)
|
||||
SWIFT_BUILD_PATH=$(build_directory ${host} swift)
|
||||
LIBICU_BUILD_DIR=$(build_directory ${host} ${product})
|
||||
ICU_TMPINSTALL=$LIBICU_BUILD_DIR/tmp_install
|
||||
ICU_TMPLIBDIR="${SWIFT_BUILD_PATH}/lib/swift/${SWIFT_HOST_VARIANT}/${SWIFT_HOST_VARIANT_ARCH}"
|
||||
if [[ "${RECONFIGURE}" || ! -f "${LIBICU_BUILD_DIR}"/config.status ]]; then
|
||||
echo "Reconfiguring libicu"
|
||||
if [[ "$LIBICU_BUILD_TYPE" != "Release" ]] ; then
|
||||
libicu_enable_debug="--enable-debug"
|
||||
else
|
||||
libicu_enable_debug=""
|
||||
fi
|
||||
call mkdir -p "${LIBICU_BUILD_DIR}"
|
||||
|
||||
if [ $(true_false "${BUILD_SWIFT_STATIC_STDLIB}") == "TRUE" ]; then
|
||||
libicu_enable_static="--enable-static"
|
||||
else
|
||||
libicu_enable_static=""
|
||||
fi
|
||||
|
||||
with_pushd "${LIBICU_BUILD_DIR}" \
|
||||
call env CXXFLAGS=-fPIC LDFLAGS='-Wl,-rpath=\$$ORIGIN' \
|
||||
"${LIBICU_SOURCE_DIR}"/icu4c/source/runConfigureICU Linux \
|
||||
${icu_build_variant_arg} --prefix=${ICU_TMPINSTALL} \
|
||||
${libicu_enable_debug} \
|
||||
--enable-renaming --with-library-suffix=swift \
|
||||
--libdir=${ICU_TMPLIBDIR} \
|
||||
--enable-shared --enable-static \
|
||||
--enable-strict --disable-icuio \
|
||||
--disable-plugins --disable-dyload --disable-extras \
|
||||
--disable-samples --disable-layoutex --with-data-packaging=auto
|
||||
else
|
||||
echo "Skipping reconfiguration of libicu"
|
||||
fi
|
||||
with_pushd "${LIBICU_BUILD_DIR}" \
|
||||
call make -j ${BUILD_JOBS} install
|
||||
ICU_LIBDIR="$(build_directory ${host} swift)/lib/swift/${SWIFT_HOST_VARIANT}/${SWIFT_HOST_VARIANT_ARCH}"
|
||||
ICU_LIBDIR_STATIC="$(build_directory ${host} swift)/lib/swift_static/${SWIFT_HOST_VARIANT}"
|
||||
ICU_LIBDIR_STATIC_ARCH="$(build_directory ${host} swift)/lib/swift_static/${SWIFT_HOST_VARIANT}/${SWIFT_HOST_VARIANT_ARCH}"
|
||||
# Add in the ICU renaming config into uconfig.h
|
||||
call sed -e "/^#define __UCONFIG_H__/ r ${LIBICU_BUILD_DIR}/uconfig.h.prepend" -i ${ICU_TMPINSTALL}/include/unicode/uconfig.h
|
||||
|
||||
if [ $(true_false "${BUILD_SWIFT_STATIC_STDLIB}") == "TRUE" ]; then
|
||||
# Copy the static libs into the swift_static directory
|
||||
call mkdir -p "${ICU_LIBDIR_STATIC_ARCH}"
|
||||
for l in uc i18n data
|
||||
do
|
||||
lib="${ICU_LIBDIR}/libicu${l}swift.a"
|
||||
call cp "${lib}" "${ICU_LIBDIR_STATIC}"
|
||||
call cp "${lib}" "${ICU_LIBDIR_STATIC_ARCH}"
|
||||
done
|
||||
fi
|
||||
|
||||
# libicu builds itself and doesn't use cmake
|
||||
continue
|
||||
;;
|
||||
*)
|
||||
echo "error: unknown product: ${product}"
|
||||
@@ -2947,17 +2853,6 @@ for host in "${ALL_HOSTS[@]}"; do
|
||||
# libdispatch_static
|
||||
continue
|
||||
;;
|
||||
libicu)
|
||||
if [[ "${SKIP_TEST_LIBICU}" ]]; then
|
||||
continue
|
||||
fi
|
||||
LIBICU_BUILD_DIR=$(build_directory ${host} ${product})
|
||||
echo "--- Running tests for ${product} ---"
|
||||
with_pushd "${LIBICU_BUILD_DIR}/test" \
|
||||
call make -j ${BUILD_JOBS}
|
||||
echo "--- Finished tests for ${product} ---"
|
||||
continue
|
||||
;;
|
||||
*)
|
||||
echo "error: unknown product: ${product}"
|
||||
exit 1
|
||||
@@ -3136,42 +3031,6 @@ for host in "${ALL_HOSTS[@]}"; do
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
libicu)
|
||||
if [[ -z "${INSTALL_LIBICU}" ]]; then
|
||||
continue
|
||||
fi
|
||||
echo "--- Installing ${product} ---"
|
||||
ICU_BUILD_DIR=$(build_directory ${host} ${product})
|
||||
ICU_INSTALL_DIR="$(get_host_install_destdir ${host})$(get_host_install_prefix ${host})"
|
||||
ICU_LIBDIR="$(build_directory ${host} swift)/lib/swift/${SWIFT_HOST_VARIANT}/${SWIFT_HOST_VARIANT_ARCH}"
|
||||
LIBICU_DEST_DIR="${ICU_INSTALL_DIR}lib/swift/${SWIFT_HOST_VARIANT}"
|
||||
call mkdir -p ${LIBICU_DEST_DIR}
|
||||
|
||||
for l in uc i18n data
|
||||
do
|
||||
lib=${ICU_LIBDIR}/libicu${l}swift
|
||||
echo "${lib} => ${LIBICU_DEST_DIR}"
|
||||
call cp -d ${lib}.so ${lib}.so.* ${LIBICU_DEST_DIR}
|
||||
done
|
||||
|
||||
if [ $(true_false "${BUILD_SWIFT_STATIC_STDLIB}") == "TRUE" ]; then
|
||||
LIBICU_DEST_DIR_STATIC="${ICU_INSTALL_DIR}lib/swift_static/${SWIFT_HOST_VARIANT}"
|
||||
call mkdir -p ${LIBICU_DEST_DIR_STATIC}
|
||||
for l in uc i18n data
|
||||
do
|
||||
lib=${ICU_LIBDIR}/libicu${l}swift
|
||||
echo "${lib} => ${LIBICU_DEST_DIR_STATIC}"
|
||||
call cp -d ${lib}.a ${LIBICU_DEST_DIR_STATIC}
|
||||
done
|
||||
fi
|
||||
|
||||
ICU_TMP_INSTALL_DIR="${ICU_BUILD_DIR}/tmp_install"
|
||||
call mkdir -p "${ICU_INSTALL_DIR}include"
|
||||
call cp -a "${ICU_TMP_INSTALL_DIR}/include/unicode" "${ICU_INSTALL_DIR}include"
|
||||
call mkdir -p "${ICU_INSTALL_DIR}share/icuswift"
|
||||
call cp -a "${ICU_TMP_INSTALL_DIR}/share/icuswift" "${ICU_INSTALL_DIR}share"
|
||||
continue
|
||||
;;
|
||||
*)
|
||||
echo "error: unknown product: ${product}"
|
||||
exit 1
|
||||
|
||||
@@ -1543,43 +1543,6 @@ function Build-CURL([Platform]$Platform, $Arch) {
|
||||
})
|
||||
}
|
||||
|
||||
function Build-ICU([Platform]$Platform, $Arch) {
|
||||
$ArchName = $Arch.LLVMName
|
||||
|
||||
if (-not $ToBatch) {
|
||||
if (-not (Test-Path -Path "$SourceCache\icu\icu4c\CMakeLists.txt")) {
|
||||
Copy-Item $SourceCache\swift-installer-scripts\shared\ICU\CMakeLists.txt $SourceCache\icu\icu4c\
|
||||
Copy-Item $SourceCache\swift-installer-scripts\shared\ICU\icupkg.inc.cmake $SourceCache\icu\icu4c\
|
||||
}
|
||||
}
|
||||
|
||||
if ($Platform -eq "Windows" -and (($Arch.CMakeName -eq $BuildArch.CMakeName) -or ($Arch.CMakeName -ne "ARM64"))) {
|
||||
$BuildToolsDefines = @{BUILD_TOOLS = "YES"}
|
||||
} else {
|
||||
$BuildToolsDefines = @{
|
||||
BUILD_TOOLS = "NO";
|
||||
BUILD_DATA = if ($Platform -eq "Android") { "NO" } else { "YES" };
|
||||
ICU_TOOLS_DIR = "$($BuildArch.BinaryCache)\windows\icu-69.1"
|
||||
}
|
||||
}
|
||||
|
||||
Build-CMakeProject `
|
||||
-Src $SourceCache\icu\icu4c `
|
||||
-Bin "$($Arch.BinaryCache)\$Platform\icu-69.1" `
|
||||
-InstallTo "$LibraryRoot\icu-69.1\usr" `
|
||||
-Arch $Arch `
|
||||
-Platform $Platform `
|
||||
-UseMSVCCompilers C,CXX `
|
||||
-BuildTargets default `
|
||||
-Defines ($BuildToolsDefines + @{
|
||||
BUILD_SHARED_LIBS = "NO";
|
||||
CMAKE_SYSTEM_NAME = $Platform.ToString();
|
||||
CMAKE_POSITION_INDEPENDENT_CODE = "YES";
|
||||
CMAKE_INSTALL_BINDIR = "bin/$Platform/$ArchName";
|
||||
CMAKE_INSTALL_LIBDIR = "lib/$Platform/$ArchName";
|
||||
})
|
||||
}
|
||||
|
||||
function Build-Runtime([Platform]$Platform, $Arch) {
|
||||
$PlatformDefines = @{}
|
||||
if ($Platform -eq "Android") {
|
||||
@@ -1687,28 +1650,7 @@ function Build-Foundation([Platform]$Platform, $Arch, [switch]$Test = $false) {
|
||||
-BuildTargets $Targets `
|
||||
-Defines (@{
|
||||
FOUNDATION_BUILD_TOOLS = if ($Platform -eq "Windows") { "YES" } else { "NO" };
|
||||
# Turn off safeseh for lld as it has safeseh enabled by default
|
||||
# and fails with an ICU data object file icudt69l_dat.obj. This
|
||||
# matters to X86 only.
|
||||
CMAKE_Swift_FLAGS = if ($Arch -eq $ArchX86) { @("-Xlinker", "/SAFESEH:NO") } else { "" };
|
||||
CURL_DIR = "$LibraryRoot\curl-8.5.0\usr\lib\$Platform\$ShortArch\cmake\CURL";
|
||||
ICU_DATA_LIBRARY_RELEASE = if ($Platform -eq "Windows") {
|
||||
"$LibraryRoot\icu-69.1\usr\lib\$Platform\$ShortArch\sicudt69.lib"
|
||||
} else {
|
||||
"$LibraryRoot\icu-69.1\usr\lib\$Platform\$ShortArch\libicudt69.a"
|
||||
};
|
||||
ICU_I18N_LIBRARY_RELEASE = if ($Platform -eq "Windows") {
|
||||
"$LibraryRoot\icu-69.1\usr\lib\$Platform\$ShortArch\sicuin69.lib"
|
||||
} else {
|
||||
"$LibraryRoot\icu-69.1\usr\lib\$Platform\$ShortArch\libicuin69.a"
|
||||
};
|
||||
ICU_ROOT = "$LibraryRoot\icu-69.1\usr";
|
||||
ICU_INCLUDE_DIR = "$LibraryRoot\icu-69.1\usr\include";
|
||||
ICU_UC_LIBRARY_RELEASE = if ($Platform -eq "Windows") {
|
||||
"$LibraryRoot\icu-69.1\usr\lib\$Platform\$ShortArch\sicuuc69.lib";
|
||||
} else {
|
||||
"$LibraryRoot\icu-69.1\usr\lib\$Platform\$ShortArch\libicuuc69.a"
|
||||
};
|
||||
LIBXML2_LIBRARY = if ($Platform -eq "Windows") {
|
||||
"$LibraryRoot\libxml2-2.11.5\usr\lib\$Platform\$ShortArch\libxml2s.lib";
|
||||
} else {
|
||||
@@ -2353,7 +2295,6 @@ if (-not $SkipBuild) {
|
||||
Invoke-BuildStep Build-ZLib Windows $Arch
|
||||
Invoke-BuildStep Build-XML2 Windows $Arch
|
||||
Invoke-BuildStep Build-CURL Windows $Arch
|
||||
Invoke-BuildStep Build-ICU Windows $Arch
|
||||
Invoke-BuildStep Build-LLVM Windows $Arch
|
||||
|
||||
# Build platform: SDK, Redist and XCTest
|
||||
@@ -2367,7 +2308,6 @@ if (-not $SkipBuild) {
|
||||
Invoke-BuildStep Build-ZLib Android $Arch
|
||||
Invoke-BuildStep Build-XML2 Android $Arch
|
||||
Invoke-BuildStep Build-CURL Android $Arch
|
||||
Invoke-BuildStep Build-ICU Android $Arch
|
||||
Invoke-BuildStep Build-LLVM Android $Arch
|
||||
|
||||
# Build platform: SDK, Redist and XCTest
|
||||
|
||||
@@ -99,9 +99,6 @@ def _apply_default_arguments(args):
|
||||
if args.libdispatch_build_variant is None:
|
||||
args.libdispatch_build_variant = args.build_variant
|
||||
|
||||
if args.libicu_build_variant is None:
|
||||
args.libicu_build_variant = args.build_variant
|
||||
|
||||
if args.libxml2_build_variant is None:
|
||||
args.libxml2_build_variant = args.build_variant
|
||||
|
||||
@@ -820,9 +817,6 @@ def create_argument_parser():
|
||||
option('--libdispatch', toggle_true('build_libdispatch'),
|
||||
help='build libdispatch')
|
||||
|
||||
option('--libicu', toggle_true('build_libicu'),
|
||||
help='build libicu')
|
||||
|
||||
option('--static-libxml2', toggle_true('build_libxml2'), default=False,
|
||||
help='build static libxml2')
|
||||
|
||||
@@ -946,10 +940,6 @@ def create_argument_parser():
|
||||
const='Debug',
|
||||
help='build the Debug variant of libdispatch')
|
||||
|
||||
option('--debug-libicu', store('libicu_build_variant'),
|
||||
const='Debug',
|
||||
help='build the Debug variant of libicu')
|
||||
|
||||
option('--debug-libxml2', store('libxml2_build_variant'),
|
||||
const='Debug',
|
||||
help='build the Debug variant of libxml2')
|
||||
@@ -1583,7 +1573,6 @@ SWIFT_SOURCE_ROOT: a directory containing the source for LLVM, Clang, Swift.
|
||||
/swift-corelibs-xctest (optional)
|
||||
/swift-corelibs-foundation (optional)
|
||||
/swift-corelibs-libdispatch (optional)
|
||||
/icu (optional)
|
||||
/libxml2 (optional)
|
||||
/zlib (optional)
|
||||
/curl (optional)
|
||||
|
||||
@@ -534,7 +534,6 @@ class TestDriverArgumentParser(
|
||||
self.assertEqual(namespace.cmark_build_variant, 'Debug')
|
||||
self.assertEqual(namespace.foundation_build_variant, 'Debug')
|
||||
self.assertEqual(namespace.libdispatch_build_variant, 'Debug')
|
||||
self.assertEqual(namespace.libicu_build_variant, 'Debug')
|
||||
self.assertEqual(namespace.lldb_build_variant, 'Debug')
|
||||
self.assertEqual(namespace.llvm_build_variant, 'Debug')
|
||||
self.assertEqual(namespace.swift_build_variant, 'Debug')
|
||||
|
||||
@@ -64,7 +64,6 @@ EXPECTED_DEFAULTS = {
|
||||
'build_ios_simulator': False,
|
||||
'build_jobs': multiprocessing.cpu_count(),
|
||||
'build_libdispatch': False,
|
||||
'build_libicu': False,
|
||||
'build_libxml2': False,
|
||||
'build_zlib': False,
|
||||
'build_curl': False,
|
||||
@@ -214,7 +213,6 @@ EXPECTED_DEFAULTS = {
|
||||
'ios_all': False,
|
||||
'legacy_impl': False,
|
||||
'libdispatch_build_variant': 'Debug',
|
||||
'libicu_build_variant': 'Debug',
|
||||
'libxml2_build_variant': 'Debug',
|
||||
'linux_archs': None,
|
||||
'lit_jobs': multiprocessing.cpu_count(),
|
||||
@@ -480,7 +478,6 @@ EXPECTED_OPTIONS = [
|
||||
dest='foundation_build_variant', value='Debug'),
|
||||
SetOption('--debug-libdispatch',
|
||||
dest='libdispatch_build_variant', value='Debug'),
|
||||
SetOption('--debug-libicu', dest='libicu_build_variant', value='Debug'),
|
||||
SetOption('--debug-libxml2', dest='libxml2_build_variant', value='Debug'),
|
||||
SetOption('--debug-zlib', dest='zlib_build_variant', value='Debug'),
|
||||
SetOption('--debug-curl', dest='curl_build_variant', value='Debug'),
|
||||
@@ -632,7 +629,6 @@ EXPECTED_OPTIONS = [
|
||||
EnableOption('--only-executable-test'),
|
||||
EnableOption('--only-non-executable-test'),
|
||||
EnableOption('--libdispatch', dest='build_libdispatch'),
|
||||
EnableOption('--libicu', dest='build_libicu'),
|
||||
EnableOption('--static-libxml2', dest='build_libxml2'),
|
||||
EnableOption('--static-zlib', dest='build_zlib'),
|
||||
EnableOption('--static-curl', dest='build_curl'),
|
||||
|
||||
@@ -112,7 +112,6 @@ class BuildScriptInvocation(object):
|
||||
"--lldb-build-type", args.lldb_build_variant,
|
||||
"--foundation-build-type", args.foundation_build_variant,
|
||||
"--libdispatch-build-type", args.libdispatch_build_variant,
|
||||
"--libicu-build-type", args.libicu_build_variant,
|
||||
"--xctest-build-type", args.build_variant,
|
||||
"--llbuild-build-type", args.build_variant,
|
||||
"--swift-enable-assertions", str(args.swift_assertions).lower(),
|
||||
@@ -274,7 +273,6 @@ class BuildScriptInvocation(object):
|
||||
(args.build_llbuild, "llbuild"),
|
||||
(args.build_libcxx, "libcxx"),
|
||||
(args.build_libdispatch, "libdispatch"),
|
||||
(args.build_libicu, "libicu"),
|
||||
(args.build_libxml2, 'libxml2'),
|
||||
(args.build_zlib, 'zlib'),
|
||||
(args.build_curl, 'curl')
|
||||
@@ -310,7 +308,6 @@ class BuildScriptInvocation(object):
|
||||
"--skip-test-xctest",
|
||||
"--skip-test-foundation",
|
||||
"--skip-test-libdispatch",
|
||||
"--skip-test-libicu",
|
||||
]
|
||||
if args.build_runtime_with_host_compiler:
|
||||
impl_args += ["--build-runtime-with-host-compiler"]
|
||||
@@ -637,8 +634,6 @@ class BuildScriptInvocation(object):
|
||||
|
||||
builder.add_impl_product(products.LibCXX,
|
||||
is_enabled=self.args.build_libcxx)
|
||||
builder.add_impl_product(products.LibICU,
|
||||
is_enabled=self.args.build_libicu)
|
||||
builder.add_impl_product(products.Swift,
|
||||
is_enabled=self.args.build_swift)
|
||||
builder.add_impl_product(products.LLDB,
|
||||
|
||||
@@ -18,7 +18,6 @@ from .foundation import Foundation
|
||||
from .indexstoredb import IndexStoreDB
|
||||
from .libcxx import LibCXX
|
||||
from .libdispatch import LibDispatch
|
||||
from .libicu import LibICU
|
||||
from .libxml2 import LibXML2
|
||||
from .llbuild import LLBuild
|
||||
from .lldb import LLDB
|
||||
@@ -50,7 +49,6 @@ __all__ = [
|
||||
'Foundation',
|
||||
'LibCXX',
|
||||
'LibDispatch',
|
||||
'LibICU',
|
||||
'LibXML2',
|
||||
'Zlib',
|
||||
'LibCurl',
|
||||
|
||||
@@ -17,7 +17,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -90,7 +89,6 @@ class Benchmarks(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -14,7 +14,6 @@ from . import cmark
|
||||
from . import curl
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import libxml2
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -52,7 +51,6 @@ class Foundation(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
libxml2.LibXML2,
|
||||
|
||||
@@ -18,7 +18,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -74,7 +73,6 @@ class IndexStoreDB(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
# swift_build_support/products/libicu.py -------------------------------------
|
||||
#
|
||||
# This source file is part of the Swift.org open source project
|
||||
#
|
||||
# Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors
|
||||
# Licensed under Apache License v2.0 with Runtime Library Exception
|
||||
#
|
||||
# See https://swift.org/LICENSE.txt for license information
|
||||
# See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
|
||||
#
|
||||
# ----------------------------------------------------------------------------
|
||||
|
||||
from . import cmark
|
||||
from . import libcxx
|
||||
from . import llvm
|
||||
from . import product
|
||||
|
||||
|
||||
class LibICU(product.Product):
|
||||
@classmethod
|
||||
def is_build_script_impl_product(cls):
|
||||
"""is_build_script_impl_product -> bool
|
||||
|
||||
Whether this product is produced by build-script-impl.
|
||||
"""
|
||||
return True
|
||||
|
||||
@classmethod
|
||||
def is_before_build_script_impl_product(cls):
|
||||
"""is_before_build_script_impl_product -> bool
|
||||
|
||||
Whether this product is built before any build-script-impl products.
|
||||
"""
|
||||
return False
|
||||
|
||||
@classmethod
|
||||
def product_source_name(cls):
|
||||
"""product_source_name() -> str
|
||||
|
||||
The name of the source code directory of this product.
|
||||
"""
|
||||
return "icu"
|
||||
|
||||
@classmethod
|
||||
def is_nondarwin_only_build_product(cls):
|
||||
return True
|
||||
|
||||
@classmethod
|
||||
def get_dependencies(cls):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX]
|
||||
@@ -14,7 +14,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llvm
|
||||
from . import product
|
||||
from . import swift
|
||||
@@ -43,7 +42,6 @@ class LLBuild(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -12,7 +12,6 @@
|
||||
|
||||
from . import cmark
|
||||
from . import libcxx
|
||||
from . import libicu
|
||||
from . import llvm
|
||||
from . import product
|
||||
from . import swift
|
||||
@@ -40,5 +39,4 @@ class LLDB(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift]
|
||||
|
||||
@@ -17,7 +17,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import lldb
|
||||
from . import llvm
|
||||
@@ -131,7 +130,6 @@ class PlaygroundSupport(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
lldb.LLDB,
|
||||
libdispatch.LibDispatch,
|
||||
|
||||
@@ -19,7 +19,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -111,7 +110,6 @@ class SKStressTester(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -15,7 +15,6 @@ from . import foundation
|
||||
from . import indexstoredb
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -68,7 +67,6 @@ class SourceKitLSP(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -18,7 +18,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -106,7 +105,6 @@ class SwiftDocC(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -16,7 +16,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -51,7 +50,6 @@ class SwiftDriver(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -18,7 +18,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -170,7 +169,6 @@ class SwiftFormat(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -17,7 +17,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -68,7 +67,6 @@ class SwiftInspect(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -16,7 +16,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -138,7 +137,6 @@ class SwiftPM(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -19,7 +19,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -150,7 +149,6 @@ class SwiftSyntax(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -16,7 +16,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llbuild
|
||||
from . import llvm
|
||||
from . import product
|
||||
@@ -100,7 +99,6 @@ class TSanLibDispatch(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation,
|
||||
|
||||
@@ -14,7 +14,6 @@ from . import cmark
|
||||
from . import foundation
|
||||
from . import libcxx
|
||||
from . import libdispatch
|
||||
from . import libicu
|
||||
from . import llvm
|
||||
from . import product
|
||||
from . import swift
|
||||
@@ -46,7 +45,6 @@ class XCTest(product.Product):
|
||||
return [cmark.CMark,
|
||||
llvm.LLVM,
|
||||
libcxx.LibCXX,
|
||||
libicu.LibICU,
|
||||
swift.Swift,
|
||||
libdispatch.LibDispatch,
|
||||
foundation.Foundation]
|
||||
|
||||
@@ -101,9 +101,6 @@
|
||||
"curl": {
|
||||
"remote": { "id": "curl/curl" }
|
||||
},
|
||||
"icu": {
|
||||
"remote": { "id": "unicode-org/icu" }
|
||||
},
|
||||
"libxml2": {
|
||||
"remote": { "id": "gnome/libxml2" }
|
||||
},
|
||||
@@ -161,7 +158,6 @@
|
||||
"wasi-libc": "wasi-sdk-20",
|
||||
"wasmkit": "0.0.3",
|
||||
"curl": "curl-8_5_0",
|
||||
"icu": "maint/maint-69",
|
||||
"libxml2": "v2.11.5",
|
||||
"zlib": "v1.3.1"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user