From e674826fc4162eeab7b9549f2b4467c5324c75d8 Mon Sep 17 00:00:00 2001 From: Nathan Chancellor Date: Thu, 9 Apr 2020 11:46:04 -0700 Subject: [PATCH] driver/travis: Replace AS=clang with LLVM_IAS=1 [skip ci] Fixes: https://travis-ci.com/github/ClangBuiltLinux/continuous-integration/jobs/317603327 Presubmit: https://travis-ci.com/github/nathanchance/continuous-integration/builds/159668906 Signed-off-by: Nathan Chancellor --- .travis.yml | 6 +++--- driver.sh | 10 ++++++---- usage.txt | 5 +++-- 3 files changed, 12 insertions(+), 9 deletions(-) diff --git a/.travis.yml b/.travis.yml index 40a7130..9757fcb 100644 --- a/.travis.yml +++ b/.travis.yml @@ -54,8 +54,8 @@ jobs: - name: "ARCH=ppc64le LD=ld.lld REPO=linux-next" env: ARCH=ppc64le LD=ld.lld REPO=linux-next if: type = cron - - name: "ARCH=riscv AS=clang REPO=linux-next BOOT=0" - env: ARCH=riscv AS=clang REPO=linux-next + - name: "ARCH=riscv LLVM_IAS=1 REPO=linux-next BOOT=0" + env: ARCH=riscv LLVM_IAS=1 REPO=linux-next if: type = cron - name: "ARCH=s390 BOOT=0 REPO=linux-next" env: ARCH=s390 REPO=linux-next @@ -194,8 +194,8 @@ script: - | docker run \ --env ARCH=${ARCH} \ - --env AS=${AS} \ --env LD=${LD} \ + --env LLVM_IAS=${LLVM_IAS} \ --env REPO=${REPO} \ --rm \ --workdir /travis \ diff --git a/driver.sh b/driver.sh index 547d838..af1b1c4 100755 --- a/driver.sh +++ b/driver.sh @@ -5,7 +5,7 @@ set -eu setup_variables() { while [[ ${#} -ge 1 ]]; do case ${1} in - "AR="*|"ARCH="*|"AS="*|"CC="*|"LD="*|"NM"=*|"OBJDUMP"=*|"OBJSIZE"=*|"REPO="*) export "${1?}" ;; + "AR="*|"ARCH="*|"CC="*|"LD="*|"LLVM_IAS="*|"NM"=*|"OBJDUMP"=*|"OBJSIZE"=*|"REPO="*) export "${1?}" ;; "-c"|"--clean") cleanup=true ;; "-j"|"--jobs") shift; jobs=$1 ;; "-j"*) jobs=${1/-j} ;; @@ -159,7 +159,6 @@ function update_boot_utils() { check_dependencies() { # Check for existence of needed binaries command -v nproc - command -v "${CROSS_COMPILE:-}"as command -v timeout command -v unbuffer command -v zstd @@ -188,7 +187,10 @@ check_dependencies() { # avoid architecture specific selection logic. "${LD:="${CROSS_COMPILE:-}"ld}" --version - "${AS:="${CROSS_COMPILE:-}"as}" --version + if [[ -z "${LLVM_IAS:-}" ]]; then + LLVM_IAS=0 + command -v "${CROSS_COMPILE:-}"as + fi if [[ -z "${CC:-}" ]]; then CC=clang @@ -308,12 +310,12 @@ mako_reactor() { KBUILD_BUILD_HOST=clangbuiltlinux \ make -j"${jobs:-$(nproc)}" \ AR="${AR}" \ - AS="${AS}" \ CC="${CC}" \ HOSTCC="${CC}" \ HOSTLD="${HOSTLD:-ld}" \ KCFLAGS="-Wno-implicit-fallthrough" \ LD="${LD}" \ + LLVM_IAS="${LLVM_IAS}" \ NM="${NM}" \ OBJCOPY="${OBJCOPY}" \ OBJDUMP="${OBJDUMP}" \ diff --git a/usage.txt b/usage.txt index 92ac9fc..75ee30e 100644 --- a/usage.txt +++ b/usage.txt @@ -13,8 +13,6 @@ Environment variables: If no AR value is specified, the script will attempt to set AR to llvm-ar-10 llvm-ar-9, llvm-ar-8, llvm-ar-7, llvm-ar, then ${CROSS_COMPILE}ar if they are found in PATH. - AS: - If no AS value is specified, ${CROSS_COMPILE}as is used. ARCH (required): If no ARCH value is specified, it's an error; there is no default. Currently, arm32_v7, arm32_v6, arm32_v5, arm64, mips, mipsel, ppc32, @@ -25,6 +23,9 @@ Environment variables: in PATH. LD: If no LD value is specified, ${CROSS_COMPILE}ld is used. + LLVM_IAS: + If this is set to 1, the integrated assembler is used. No value means + ${CROSS_COMPILE}as is used for assembling. REPO: Nicknames for trees: linux (default)