Skip to content
This repository has been archived by the owner on Apr 13, 2024. It is now read-only.

Tuxbuild #243

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Tuxbuild #243

wants to merge 2 commits into from

Conversation

nickdesaulniers
Copy link
Member

I expect the first run to fail; we need to figure out how to ship the tuxbuild client in our docker image. Once that's sorted, we can:

  1. rekick the buildbot.
  2. drop the top patch, it should not be merged.

tuxbuild (https://gitlab.com/Linaro/tuxbuild) is a new microservice from
Linaro for building Linux kernel images.

We can build clang kernel images with it via:
$ tuxbuild build \
  --git-repo https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git \
  --git-ref master --target-arch arm64 --kconfig defconfig --toolchain clang-9
to build mainline ARCH=arm64 defconfig with Clang 9.

This requires a tuxbuild client installed, and an API key. For example,
I have requested 2 API keys; one is in my ~/.config/tuxbuild/config.ini,
one is stored in an environmental variable TUXBUILD_TOKEN in
https://travis-ci.com/github/ClangBuiltLinux/continuous-integration/settings.
See https://gitlab.com/Linaro/tuxbuild#setup-config for more
information.

This change allows driver.sh to use tuxbuild rather than fetching and
building kernel images locally.  The above command with driver.sh would
look like:
$ TUX_BUILD=1 ARCH=arm64 REPO=linux LLVM_VERSION=9 ./driver.sh

This change turns on 3 daily builds with tuxbuild; all mainline
defconfigs with clang-9, one arm64, one arm32_v7, and on x86_64.
for testing TUX_BUILD=1 builds on travisci.

# https://gitlab.com/Linaro/tuxbuild/-/issues/56
start=$(date +%s)
build_url=$(timeout 50m ${cmd} | grep -o https://builds.tuxbuild.com/.\* | head -n1)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am fairly certain Travis will timeout here because there will not be any output for ten minutes. I am not sure how to get around that, we'll have to brain storm (or maybe reach out to Travis support and see if there is any way for that restriction to be waved).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Last time I contacted Travis CI support, they told me there is no way to change the 10-minute silence timeout. The easiest way to get around that restriction is to just print something every 10 minutes.

# https://builds.tuxbuild.com/neNnj76CSx8sDEbwlUHGbA/ arm64 31:06
# https://builds.tuxbuild.com/9ieKegqDeZBTCMaG3et7ig/ arm64
# https://builds.tuxbuild.com/rPqYnwW4B8xhi8i6atmcpg/ arm
cmd="tuxbuild build --git-repo ${url} --git-ref ${branch:=master} --target-arch ${tux_arch} --kconfig ${config} --toolchain clang-${LLVM_VERSION}"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be an array:

cmd=( tuxbuild build --git-repo ${url} --git-ref ${branch:=master} --target-arch ${tux_arch} --kconfig ${config} --toolchain clang-${LLVM_VERSION} )

...

build_url=$(timeout 50m "${cmd[@]}" | ...)

start=$(date +%s)
build_url=$(timeout 50m ${cmd} | grep -o https://builds.tuxbuild.com/.\* | head -n1)
end=$(date +%s)
runtime=$((${end}-${start}))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be runtime=$((end - start))

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants