@@ -1,5 +1,9 @@
language: c
+os:
+ - linux
+ - linux-ppc64le
+
cache: ccache
env:
@@ -25,6 +29,18 @@ matrix:
allow_failures:
- env: RUN_ON_CONTAINER=fedora-rawhide
- env: RUN_ON_CONTAINER=debian-unstable
+ exclude:
+ - os: linux-ppc64le
+ env: RUN_ON_CONTAINER=ubuntu-12.04
+ - os: linux-ppc64le
+ env: RUN_ON_CONTAINER=fedora24
+ - os: linux-ppc64le
+ env: RUN_ON_CONTAINER=fedora25
+ - os: linux-ppc64le
+ env: RUN_ON_CONTAINER=centos6
+ - os: linux-ppc64le
+ env: RUN_ON_CONTAINER=centos7
+
sudo: required
services: docker
@@ -1,13 +1,11 @@
FROM centos:7
RUN yum -y update && yum clean all
RUN yum -y install wget curl xterm gcc git xz make diffutils findutils expect valgrind valgrind-devel ccache dtc openssl-devel openssl
-RUN wget https://www.kernel.org/pub/tools/crosstool/files/bin/x86_64/4.8.0/x86_64-gcc-4.8.0-nolibc_powerpc64-linux.tar.xz
RUN mkdir /opt/cross
-RUN tar -C /opt/cross -xf x86_64-gcc-4.8.0-nolibc_powerpc64-linux.tar.xz
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p8/packages/v1.0-2/systemsim-p8-1.0-2.el7.x86_64.rpm
-RUN yum install -y systemsim-p8-1.0-2.el7.x86_64.rpm
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.0-0/systemsim-p9-1.0-0.el7.x86_64.rpm
-RUN yum install -y systemsim-p9-1.0-0.el7.x86_64.rpm
+RUN if [ `arch` == "x86_64" ]; then wget https://www.kernel.org/pub/tools/crosstool/files/bin/x86_64/4.8.0/x86_64-gcc-4.8.0-nolibc_powerpc64-linux.tar.xz; tar -C /opt/cross -xf x86_64-gcc-4.8.0-nolibc_powerpc64-linux.tar.xz; fi
+RUN if [ `arch` == "ppc64le" ]; then wget https://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/ppc64le/4.9.4/ppc64le-gcc-4.9.4-nolibc-powerpc64-linux.tar.xz; tar -C /opt/cross -xf ppc64le-gcc-4.9.4-nolibc-powerpc64-linux.tar.xz; fi
+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.el7.x86_64.rpm; yum install -y systemsim-p8-1.0-2.el7.x86_64.rpm; fi
+RUN if [ `arch` == "x86_64" ]; then curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.0-0/systemsim-p9-1.0-0.el7.x86_64.rpm; yum install -y systemsim-p9-1.0-0.el7.x86_64.rpm; fi
RUN yum install -y flex bison
RUN curl -L https://github.com/dgibson/dtc/archive/v1.4.2.tar.gz|tar xfz -
RUN (cd dtc-1.4.2; make PREFIX=/usr/local install)
@@ -1,13 +1,9 @@
FROM debian:stretch
RUN apt-get update -qq
-RUN apt-get install -y gcc-powerpc64le-linux-gnu gcc ccache expect libssl-dev
-RUN apt-get install -y wget xterm curl device-tree-compiler
-RUN apt-get install -y gcc-arm-linux-gnueabi
-RUN apt-get install -y libtcl8.6
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.0-0/systemsim-p9-1.0-0-trusty_amd64.deb
-RUN dpkg -i systemsim-p9-1.0-0-trusty_amd64.deb
-RUN apt-get -y install eatmydata
-RUN eatmydata apt-get -y install build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind
+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 xterm curl 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
+RUN apt-get update -qq && apt-get install -y gcc-arm-linux-gnueabi || true
+RUN if [ `arch` == "x86_64" ]; then curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.0-0/systemsim-p9-1.0-0-trusty_amd64.deb; dpkg -i systemsim-p9-1.0-0-trusty_amd64.deb; fi
COPY . /build/
WORKDIR /build
ENTRYPOINT ./opal-ci/build-ubuntu-16.04.sh
@@ -1,15 +1,10 @@
FROM debian:unstable
RUN apt-get update -qq
-RUN apt-get install -y gcc-powerpc64le-linux-gnu gcc ccache expect libssl-dev
-RUN apt-get install -y wget xterm curl device-tree-compiler
-RUN apt-get install -y gcc-arm-linux-gnueabi
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p8/packages/v1.0-2/systemsim-p8_1.0-2_amd64.deb
-RUN dpkg -i systemsim-p8_1.0-2_amd64.deb
-RUN apt-get install -y libtcl8.6
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.0-0/systemsim-p9-1.0-0-trusty_amd64.deb
-RUN dpkg -i systemsim-p9-1.0-0-trusty_amd64.deb
-RUN apt-get -y install eatmydata
-RUN eatmydata apt-get -y install build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind
+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 xterm curl 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
+RUN apt-get update -qq && apt-get install -y gcc-arm-linux-gnueabi || true
+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 -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.0-0/systemsim-p9-1.0-0-trusty_amd64.deb; dpkg -i systemsim-p9-1.0-0-trusty_amd64.deb; fi
COPY . /build/
WORKDIR /build
ENTRYPOINT ./opal-ci/build-ubuntu-16.04.sh
@@ -1,7 +1,7 @@
FROM fedora:rawhide
RUN dnf -y install wget curl xterm gcc git xz make diffutils findutils expect valgrind valgrind-devel ccache dtc openssl-devel
RUN dnf -y install gcc-powerpc64-linux-gnu
-RUN dnf -y install http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0.f22.x86_64.rpm
+RUN if [ `arch` == "x86_64" ]; then dnf -y install http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0.f22.x86_64.rpm; fi
COPY . /build/
WORKDIR /build
ENTRYPOINT ./opal-ci/build-fedora24.sh
@@ -1,7 +1,7 @@
FROM fedora:26
RUN dnf -y install wget curl xterm gcc git xz make diffutils findutils expect valgrind valgrind-devel ccache dtc openssl-devel
RUN dnf -y install gcc-powerpc64-linux-gnu
-RUN dnf -y install http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0.f22.x86_64.rpm
+RUN if [ `arch` == "x86_64" ]; then dnf -y install http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0.f22.x86_64.rpm; fi
COPY . /build/
WORKDIR /build
ENTRYPOINT ./opal-ci/build-fedora24.sh
@@ -1,7 +1,7 @@
FROM fedora:27
RUN dnf -y install wget curl xterm gcc git xz make diffutils findutils expect valgrind valgrind-devel ccache dtc openssl-devel
RUN dnf -y install gcc-powerpc64-linux-gnu
-RUN dnf -y install http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0.f22.x86_64.rpm
+RUN if [ `arch` == "x86_64" ]; then dnf -y install http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0.f22.x86_64.rpm; fi
COPY . /build/
WORKDIR /build
ENTRYPOINT ./opal-ci/build-fedora24.sh
@@ -3,20 +3,15 @@ RUN sudo apt-get update -qq
RUN sudo apt-get install -y software-properties-common
RUN sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
RUN sudo apt-get update -qq
-RUN sudo apt-get install -y gcc-4.8 libstdc++6 valgrind expect xterm ccache expect device-tree-compiler libssl-dev
-RUN sudo apt-get install -y gcc-arm-linux-gnueabi gcc-powerpc64le-linux-gnu gcc
+RUN sudo apt-get install -y gcc-4.8 libstdc++6 valgrind expect xterm ccache expect device-tree-compiler libssl-dev gcc wget curl build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 libtcl8.6
+RUN apt-get update -qq && apt-get install -y gcc-arm-linux-gnueabi || true
+RUN if [ `arch` != "ppc64le" ]; then apt-get update -qq && apt-get install -y gcc-powerpc64le-linux-gnu; fi
RUN sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 50
-RUN sudo apt-get install -y wget curl
RUN curl -L -O https://www.kernel.org/pub/tools/crosstool/files/bin/x86_64/4.8.0/x86_64-gcc-4.8.0-nolibc_powerpc64-linux.tar.xz
RUN sudo mkdir /opt/cross
RUN sudo tar -C /opt/cross -xf x86_64-gcc-4.8.0-nolibc_powerpc64-linux.tar.xz
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p8/packages/v1.0-2/systemsim-p8_1.0-2_amd64.deb
-RUN sudo dpkg -i systemsim-p8_1.0-2_amd64.deb
-RUN apt-get install -y libtcl8.6
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0-trusty_amd64.deb
-RUN sudo dpkg -i systemsim-p9-1.1-0-trusty_amd64.deb
-RUN sudo apt-get -y install eatmydata
-RUN sudo eatmydata apt-get -y install build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6
+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/
WORKDIR /build
ENTRYPOINT ./opal-ci/build-ubuntu-12.04.sh
@@ -1,15 +1,10 @@
FROM ubuntu:16.04
RUN apt-get update -qq
-RUN apt-get install -y gcc-powerpc64le-linux-gnu gcc ccache expect libssl-dev
-RUN apt-get install -y wget curl xterm device-tree-compiler
-RUN apt-get install -y gcc-arm-linux-gnueabi
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p8/packages/v1.0-2/systemsim-p8_1.0-2_amd64.deb
-RUN dpkg -i systemsim-p8_1.0-2_amd64.deb
-RUN apt-get install -y libtcl8.6
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0-trusty_amd64.deb
-RUN dpkg -i systemsim-p9-1.1-0-trusty_amd64.deb
-RUN apt-get -y install eatmydata
-RUN eatmydata apt-get -y install build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind
+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
+RUN apt-get update -qq && apt-get install -y gcc-arm-linux-gnueabi || true
+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/
WORKDIR /build
ENTRYPOINT ./opal-ci/build-ubuntu-16.04.sh
@@ -1,15 +1,10 @@
FROM ubuntu:latest
RUN apt-get update -qq
-RUN apt-get install -y gcc-powerpc64le-linux-gnu gcc ccache expect libssl-dev
-RUN apt-get install -y wget xterm curl device-tree-compiler
-RUN apt-get install -y gcc-arm-linux-gnueabi
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p8/packages/v1.0-2/systemsim-p8_1.0-2_amd64.deb
-RUN dpkg -i systemsim-p8_1.0-2_amd64.deb
-RUN apt-get install -y libtcl8.6
-RUN curl -L -O http://public.dhe.ibm.com/software/server/powerfuncsim/p9/packages/v1.1-0/systemsim-p9-1.1-0-trusty_amd64.deb
-RUN dpkg -i systemsim-p9-1.1-0-trusty_amd64.deb
-RUN apt-get -y install eatmydata
-RUN eatmydata apt-get -y install build-essential gcc python g++ pkg-config libz-dev libglib2.0-dev libpixman-1-dev libfdt-dev git libstdc++6 valgrind
+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
+RUN apt-get update -qq && apt-get install -y gcc-arm-linux-gnueabi || true
+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/
WORKDIR /build
ENTRYPOINT ./opal-ci/build-ubuntu-16.04.sh
@@ -7,8 +7,13 @@ set -vx
# We're limited as to what we want to bother to run on CentOS7
# It's fairly old and some of the things (e.g. build+run qemu) we don't
# want to bother doing.
-
-export CROSS=/opt/cross/gcc-4.8.0-nolibc/powerpc64-linux/bin/powerpc64-linux-
+if [ `arch` == "x86_64" ]; then
+ export CROSS=/opt/cross/gcc-4.8.0-nolibc/powerpc64-linux/bin/powerpc64-linux-
+fi
+# Note that this doesn't work on centos7 because "/lib64/ld64.so.2: version `GLIBC_2.22' not found"
+if [ `arch` == "ppc64le" ]; then
+ export CROSS=/opt/cross/gcc-4.9.4-nolibc/powerpc64-linux/bin/powerpc64-linux-
+fi
MAKE_J=`grep -c processor /proc/cpuinfo`
@@ -13,7 +13,15 @@ make -j${MAKE_J} all
./opal-ci/fetch-debian-jessie-installer.sh
make -j${MAKE_J} check
(make clean; cd external/gard && CROSS= make -j${MAKE_J})
-(cd external/pflash; ./build-all-arch.sh)
+# because some ppc64le versions don't have arm cross compiler
+if which arm-linux-gnueabi-gcc; then
+ ( cd external/pflash;
+ echo "Building for ARM..."
+ make clean && make distclean
+ CROSS_COMPILE=arm-linux-gnueabi- make || { echo "ARM build failed"; exit 1; }
+ )
+fi
+(cd external/pflash; make clean && make distclean && make)
make clean
SKIBOOT_GCOV=1 make -j${MAKE_J}
SKIBOOT_GCOV=1 make -j${MAKE_J} check