[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen staging] CI: Add a CentOS 6 container and build jobs
commit 8eed571409a7f81ec9327cfa95d7c298333e22e4 Author: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> AuthorDate: Tue Mar 26 14:23:03 2019 +0000 Commit: Wei Liu <wei.liu2@xxxxxxxxxx> CommitDate: Tue Mar 26 15:36:19 2019 +0000 CI: Add a CentOS 6 container and build jobs CentOS 6 is probably the most frequently broken build, so adding it to CI would be a very good move. One problem is that CentOS 6 comes with Python 2.6, and Qemu requires 2.7. There appear to be no sensible ways to get Python 2.7 into a CentOS 6 environments, so modify the build script to skip the Qemu upstream build instead. Additionally, SeaBIOS requires GCC 4.6 or later, so skip it as well. Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> Acked-by: Wei Liu <wei.liu2@xxxxxxxxxx> --- automation/build/centos/6.dockerfile | 51 ++++++++++++++++++++++++++++++++++++ automation/gitlab-ci/build.yaml | 10 +++++++ automation/scripts/build | 16 +++++++++++ automation/scripts/containerize | 1 + 4 files changed, 78 insertions(+) diff --git a/automation/build/centos/6.dockerfile b/automation/build/centos/6.dockerfile new file mode 100644 index 0000000000..54d022be86 --- /dev/null +++ b/automation/build/centos/6.dockerfile @@ -0,0 +1,51 @@ +FROM centos:6 +LABEL maintainer.name="The Xen Project" \ + maintainer.email="xen-devel@xxxxxxxxxxxxxxxxxxxx" + +RUN mkdir /build +WORKDIR /build + +# work around https://github.com/moby/moby/issues/10180 +# and add EPEL for dev86 +RUN rpm --rebuilddb && \ + yum -y install \ + yum-plugin-ovl \ + epel-release \ + && yum clean all && \ + rm -rf /var/cache/yum + +# install Xen depends +RUN yum -y install \ + gcc \ + gcc-c++ \ + ncurses-devel \ + zlib-devel \ + openssl-devel \ + python-devel \ + libuuid-devel \ + pciutils-devel \ + pkgconfig \ + gettext \ + flex \ + bison \ + libaio-devel \ + glib2-devel \ + yajl-devel \ + pixman-devel \ + glibc-devel \ + glibc-devel.i686 \ + make \ + binutils \ + git \ + wget \ + acpica-tools \ + python-markdown \ + patch \ + checkpolicy \ + dev86 \ + iasl \ + xz-devel \ + bzip2 \ + nasm \ + && yum clean all && \ + rm -rf /var/cache/yum diff --git a/automation/gitlab-ci/build.yaml b/automation/gitlab-ci/build.yaml index 48bb039ab4..b70797e82d 100644 --- a/automation/gitlab-ci/build.yaml +++ b/automation/gitlab-ci/build.yaml @@ -149,6 +149,16 @@ centos-7-gcc-debug: variables: CONTAINER: centos:7 +centos-6-gcc: + extends: .gcc-x86-64-build + variables: + CONTAINER: centos:6 + +centos-6-gcc-debug: + extends: .gcc-x86-64-build-debug + variables: + CONTAINER: centos:6 + debian-jessie-clang: extends: .clang-x86-64-build variables: diff --git a/automation/scripts/build b/automation/scripts/build index db4bac3302..8a57e097a9 100755 --- a/automation/scripts/build +++ b/automation/scripts/build @@ -2,6 +2,12 @@ $CC --version +# Express the compiler version as an integer. e.g. GCC 4.9.2 => 0x040902 +cc-ver() +{ + $CC -dumpversion | awk -F. '{ printf "0x%02x%02x%02x", $1, $2, $3 }' +} + # random config or default config if [[ "${RANDCONFIG}" == "y" ]]; then make -C xen KCONFIG_ALLCONFIG=tools/kconfig/allrandom.config randconfig @@ -22,6 +28,16 @@ if [[ "${CC}" == "clang" ]]; then cfgargs+=("--disable-stubdom") fi +# Qemu requires Python 2.7 or later +if python -c "import sys; res = sys.version_info < (2, 7); exit(not(res))"; then + cfgargs+=("--with-system-qemu=/bin/false") +fi + +# SeaBIOS requires GCC 4.6 or later +if [[ "${CC}" == "gcc" && `cc-ver` -lt 0x040600 ]]; then + cfgargs+=("--with-system-seabios=/bin/false") +fi + ./configure "${cfgargs[@]}" make -j$(nproc) dist diff --git a/automation/scripts/containerize b/automation/scripts/containerize index b50ff99441..09d130bbd6 100755 --- a/automation/scripts/containerize +++ b/automation/scripts/containerize @@ -15,6 +15,7 @@ die() { # BASE="registry.gitlab.com/xen-project/xen" case "_${CONTAINER}" in + _centos6) CONTAINER="${BASE}/centos:6" ;; _centos7) CONTAINER="${BASE}/centos:7" ;; _centos72) CONTAINER="${BASE}/centos:7.2" ;; _trusty) CONTAINER="${BASE}/ubuntu:trusty" ;; -- generated by git-patchbot for /home/xen/git/xen.git#staging _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |