From ff4e54d44e7e0d06f171dca38ca0e03a3d614d26 Mon Sep 17 00:00:00 2001 From: Oliver O'Halloran Date: Fri, 12 Jun 2020 12:24:52 +1000 Subject: travis: Add clang specific build job Right now clang doesn't support the -ffixed-r compiler options that we rely on for the skiboot cpu_thread pointer so it can't build skiboot. Remove the clang builds from the debian-unstable and ubuntu-latest and builds in favour of a clang specific job. This allows those jobs to pass normally and gives us as specific job to monitor to see when support for those options lands in clang. Signed-off-by: Oliver O'Halloran --- .travis.yml | 3 +++ opal-ci/Dockerfile-clang | 6 ++++++ opal-ci/Dockerfile-debian-unstable | 2 +- opal-ci/Dockerfile-ubuntu-18.04 | 2 +- opal-ci/Dockerfile-ubuntu-20.04 | 2 +- opal-ci/Dockerfile-ubuntu-latest | 2 +- opal-ci/build-clang.sh | 10 ++++++++++ opal-ci/build-ubuntu-latest.sh | 5 ----- 8 files changed, 23 insertions(+), 9 deletions(-) create mode 100644 opal-ci/Dockerfile-clang create mode 100755 opal-ci/build-clang.sh diff --git a/.travis.yml b/.travis.yml index 860d204..6eaf0a9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -26,11 +26,14 @@ jobs: - env: RUN_ON_CONTAINER=fedora-rawhide - env: RUN_ON_CONTAINER=debian-unstable - env: RUN_ON_CONTAINER=ubuntu-latest + - env: RUN_ON_CONTAINER=clang exclude: - os: linux-ppc64le env: RUN_ON_CONTAINER=centos7 - os: linux-ppc64le env: RUN_ON_CONTAINER=docs + - os: linux-ppc64le + env: RUN_ON_CONTAINER=clang install: - docker build --pull -t ${RUN_ON_CONTAINER} -f opal-ci/Dockerfile-${RUN_ON_CONTAINER} . diff --git a/opal-ci/Dockerfile-clang b/opal-ci/Dockerfile-clang new file mode 100644 index 0000000..02a0bf5 --- /dev/null +++ b/opal-ci/Dockerfile-clang @@ -0,0 +1,6 @@ +FROM ubuntu:rolling +ENV DEBIAN_FRONTEND noninteractive +RUN apt-get update -qq +RUN apt-get install -y clang device-tree-compiler +COPY . /build/ +WORKDIR /build diff --git a/opal-ci/Dockerfile-debian-unstable b/opal-ci/Dockerfile-debian-unstable index 04ff179..13c157f 100644 --- a/opal-ci/Dockerfile-debian-unstable +++ b/opal-ci/Dockerfile-debian-unstable @@ -5,7 +5,7 @@ RUN apt-get update -qq && apt-get install -y gcc-arm-linux-gnueabi || true RUN apt-get update -qq && apt-get install -y gcc ccache expect libssl-dev wget \ curl xterm device-tree-compiler build-essential gcc python g++ pkg-config \ libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind \ - libtcl8.6 clang qemu-system-ppc opal-utils + libtcl8.6 qemu-system-ppc opal-utils RUN if [ `arch` = "x86_64" ]; then curl -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0-trusty_amd64.deb; dpkg -i systemsim-p9-1.1-0-trusty_amd64.deb; fi COPY . /build/ WORKDIR /build diff --git a/opal-ci/Dockerfile-ubuntu-18.04 b/opal-ci/Dockerfile-ubuntu-18.04 index 1743df2..3a031c3 100644 --- a/opal-ci/Dockerfile-ubuntu-18.04 +++ b/opal-ci/Dockerfile-ubuntu-18.04 @@ -2,7 +2,7 @@ FROM ubuntu:18.04 ENV DEBIAN_FRONTEND noninteractive RUN if [ `arch` != "ppc64le" ]; then apt-get update -qq && apt-get install -y gcc-powerpc64le-linux-gnu; fi RUN apt-get update -qq && apt-get install -y gcc-arm-linux-gnueabi || true -RUN apt-get update -qq && apt-get install -y gcc ccache expect libssl-dev wget curl xterm device-tree-compiler build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind libtcl8.6 clang qemu-system-ppc +RUN apt-get update -qq && apt-get install -y gcc ccache expect libssl-dev wget curl xterm device-tree-compiler build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind libtcl8.6 qemu-system-ppc RUN if [ `arch` = "x86_64" ]; then curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p8/packages/v1.0-2/systemsim-p8_1.0-2_amd64.deb; dpkg -i systemsim-p8_1.0-2_amd64.deb; fi RUN if [ `arch` = "x86_64" ]; then curl -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0-trusty_amd64.deb; dpkg -i systemsim-p9-1.1-0-trusty_amd64.deb; fi COPY . /build/ diff --git a/opal-ci/Dockerfile-ubuntu-20.04 b/opal-ci/Dockerfile-ubuntu-20.04 index 2770951..515ec5c 100644 --- a/opal-ci/Dockerfile-ubuntu-20.04 +++ b/opal-ci/Dockerfile-ubuntu-20.04 @@ -3,7 +3,7 @@ ENV DEBIAN_FRONTEND noninteractive RUN apt-get update -qq RUN if [ `arch` != "ppc64le" ]; then apt-get update -qq && apt-get install -y gcc-powerpc64le-linux-gnu; fi RUN apt-get update -qq && apt-get install -y gcc-arm-linux-gnueabi || true -RUN apt-get update -qq && apt-get install -y gcc ccache expect libssl-dev wget curl xterm device-tree-compiler build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind libtcl8.6 clang qemu-system-ppc +RUN apt-get update -qq && apt-get install -y gcc ccache expect libssl-dev wget curl xterm device-tree-compiler build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind libtcl8.6 qemu-system-ppc RUN if [ `arch` = "x86_64" ]; then curl -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0-trusty_amd64.deb; dpkg -i systemsim-p9-1.1-0-trusty_amd64.deb; fi COPY . /build/ WORKDIR /build diff --git a/opal-ci/Dockerfile-ubuntu-latest b/opal-ci/Dockerfile-ubuntu-latest index ce9cbdd..577d7a4 100644 --- a/opal-ci/Dockerfile-ubuntu-latest +++ b/opal-ci/Dockerfile-ubuntu-latest @@ -2,7 +2,7 @@ FROM ubuntu:rolling ENV DEBIAN_FRONTEND noninteractive RUN apt-get update -qq RUN if [ `arch` != "ppc64le" ]; then apt-get update -qq && apt-get install -y gcc-powerpc64le-linux-gnu; fi -RUN apt-get update -qq && apt-get install -y gcc ccache expect libssl-dev wget curl xterm device-tree-compiler build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind libtcl8.6 clang qemu-system-ppc +RUN apt-get update -qq && apt-get install -y gcc ccache expect libssl-dev wget curl xterm device-tree-compiler build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind libtcl8.6 qemu-system-ppc RUN apt-get update -qq && apt-get install -y gcc-arm-linux-gnueabi || true RUN if [ `arch` = "x86_64" ]; then curl -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0-trusty_amd64.deb; dpkg -i systemsim-p9-1.1-0-trusty_amd64.deb; fi COPY . /build/ diff --git a/opal-ci/build-clang.sh b/opal-ci/build-clang.sh new file mode 100755 index 0000000..09377c0 --- /dev/null +++ b/opal-ci/build-clang.sh @@ -0,0 +1,10 @@ +#!/bin/bash + +set -uo pipefail +set -e +set -vx + +MAKE_J=$(nproc) + +make -j${MAKE_J} CC=clang +make -j${MAKE_J} CC=clang check diff --git a/opal-ci/build-ubuntu-latest.sh b/opal-ci/build-ubuntu-latest.sh index 16c33a9..ea27bba 100755 --- a/opal-ci/build-ubuntu-latest.sh +++ b/opal-ci/build-ubuntu-latest.sh @@ -28,8 +28,3 @@ rm -rf builddir mkdir builddir make SRC=$(pwd) -f ../Makefile -C builddir -j${MAKE_J} make clean - -echo "Building with clang..." -make clean -make -j${MAKE_J} CC=clang -make -j${MAKE_J} CC=clang check -- cgit v1.1