mirror of
https://github.com/dart-lang/sdk
synced 2024-10-02 23:39:19 +00:00
[infra] Update alpine sysroot
Closes https://github.com/dart-lang/sdk/pull/55255 GitOrigin-RevId: d754c894720403f1a4c712855ed3fc718b6d2d06 Change-Id: I577f03977025156f14dc7207c0a50fde6fc0c10c Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/358860 Reviewed-by: Slava Egorov <vegorov@google.com> Commit-Queue: Slava Egorov <vegorov@google.com>
This commit is contained in:
parent
6f4e0b403c
commit
867610409a
6
build/.gitignore
vendored
6
build/.gitignore
vendored
|
@ -1,8 +1,2 @@
|
||||||
# Generated file containing information about the VS toolchain on Windows.
|
# Generated file containing information about the VS toolchain on Windows.
|
||||||
win_toolchain.json
|
win_toolchain.json
|
||||||
|
|
||||||
# Pulled linux sysroots.
|
|
||||||
# Regex to prevent large when comparing checkouts with commits in which the
|
|
||||||
# sysroot has been rolled.
|
|
||||||
linux/alpine-linux-**-sysroot
|
|
||||||
linux/debian_**-sysroot
|
|
||||||
|
|
|
@ -19,18 +19,18 @@ if (is_linux) {
|
||||||
if (dart_sysroot == "alpine") {
|
if (dart_sysroot == "alpine") {
|
||||||
if (current_cpu == "x86") {
|
if (current_cpu == "x86") {
|
||||||
target_sysroot =
|
target_sysroot =
|
||||||
rebase_path("//build/linux/alpine-linux-x86-sysroot", root_build_dir)
|
rebase_path("//buildtools/sysroot/alpine-linux-x86", root_build_dir)
|
||||||
} else if (current_cpu == "x64") {
|
} else if (current_cpu == "x64") {
|
||||||
target_sysroot = rebase_path("//build/linux/alpine-linux-x86_64-sysroot",
|
target_sysroot = rebase_path("//buildtools/sysroot/alpine-linux-x86_64",
|
||||||
root_build_dir)
|
root_build_dir)
|
||||||
} else if (current_cpu == "arm") {
|
} else if (current_cpu == "arm") {
|
||||||
target_sysroot = rebase_path("//build/linux/alpine-linux-armv7-sysroot",
|
target_sysroot = rebase_path("//buildtools/sysroot/alpine-linux-armv7",
|
||||||
root_build_dir)
|
root_build_dir)
|
||||||
} else if (current_cpu == "arm64") {
|
} else if (current_cpu == "arm64") {
|
||||||
target_sysroot = rebase_path("//build/linux/alpine-linux-aarch64-sysroot",
|
target_sysroot = rebase_path("//buildtools/sysroot/alpine-linux-aarch64",
|
||||||
root_build_dir)
|
root_build_dir)
|
||||||
} else if (current_cpu == "riscv64") {
|
} else if (current_cpu == "riscv64") {
|
||||||
target_sysroot = rebase_path("//build/linux/alpine-linux-riscv64-sysroot",
|
target_sysroot = rebase_path("//buildtools/sysroot/alpine-linux-riscv64",
|
||||||
root_build_dir)
|
root_build_dir)
|
||||||
} else {
|
} else {
|
||||||
print("There is no $dart_sysroot sysroot present for $current_cpu")
|
print("There is no $dart_sysroot sysroot present for $current_cpu")
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
# Install Alpine sysroots for building with musl libc.
|
# Install Alpine sysroots for building with musl libc.
|
||||||
#
|
#
|
||||||
# Sysroots will be installed into //build/linux/alpine-linux-$arch-sysroot
|
# Sysroots will be installed into //buildtools/sysroot/alpine-linux-$arch
|
||||||
#
|
#
|
||||||
# Architectures to be installed can be configured at the end of the script
|
# Architectures to be installed can be configured at the end of the script
|
||||||
#
|
#
|
||||||
|
@ -18,10 +18,10 @@ fi
|
||||||
|
|
||||||
SCRIPT="$(readlink -f -- "$0")"
|
SCRIPT="$(readlink -f -- "$0")"
|
||||||
|
|
||||||
WORKDIR="$(dirname -- "$(dirname -- "$SCRIPT")")"
|
WORKDIR="$(dirname -- "$(dirname -- "$(dirname -- "$(dirname -- "$SCRIPT")")")")"
|
||||||
|
|
||||||
if test $# -eq 0; then
|
if test $# -eq 0; then
|
||||||
set aarch64 armv7 x86_64 x86
|
set aarch64 armv7 x86_64 x86
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "$@" | xargs -n 1 -- sh -xc 'apk add --root "$1/alpine-linux-$2-sysroot" --repositories-file /etc/apk/repositories --allow-untrusted --arch "$2" --no-cache --no-scripts --initdb -- alpine-base alpine-sdk linux-headers' -- "$WORKDIR"
|
echo "$@" | xargs -n 1 -- sh -xc 'apk add --root "$1/buildtools/sysroot/alpine-linux-$2" --repositories-file /etc/apk/repositories --allow-untrusted --arch "$2" --no-cache --no-scripts --initdb -- build-base linux-headers' -- "$WORKDIR"
|
||||||
|
|
Loading…
Reference in a new issue