[igt-dev] [PATCH i-g-t] gitlab-CI: add armhf

Tomi Valkeinen tomi.valkeinen at ti.com
Wed Feb 13 13:14:28 UTC 2019


Add CI for armhf environment.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen at ti.com>
---

I'm no expert on gitlab CI, and this was mostly a copy-paste &
search-replace type of work. So review carefully =). The armhf build
does fail for me, as supposed, as the current HEAD is broken. So that's
a good sign.

 .gitlab-ci.yml          | 28 +++++++++++++++++++++++++
 Dockerfile.debian-armhf | 46 +++++++++++++++++++++++++++++++++++++++++
 meson-cross-armhf.txt   | 12 +++++++++++
 3 files changed, 86 insertions(+)
 create mode 100644 Dockerfile.debian-armhf
 create mode 100644 meson-cross-armhf.txt

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 4bd4130f..ad938979 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -58,6 +58,17 @@ build:tests-debian-meson:
     paths:
       - meson-test-list.txt
 
+build:tests-debian-meson-armhf:
+  image: $CI_REGISTRY/$CI_PROJECT_PATH/igt-debian-armhf:latest
+  stage: build
+  script:
+    - export PKG_CONFIG_PATH=/usr/lib/arm-linux-gnueabihf/pkgconfig/
+    - meson --cross-file meson-cross-armhf.txt build
+    - ninja -C build
+  artifacts:
+    paths:
+      - build
+
 build:tests-debian-meson-arm64:
   image: $CI_REGISTRY/$CI_PROJECT_PATH/igt-debian-arm64:latest
   stage: build
@@ -143,6 +154,23 @@ containers:igt-debian:
     - docker build -t $CI_REGISTRY/$CI_PROJECT_PATH/igt-debian -f Dockerfile.debian .
     - docker push $CI_REGISTRY/$CI_PROJECT_PATH/igt-debian
 
+containers:igt-debian-armhf:
+  stage: containers
+  image: docker:stable
+  only:
+    changes:
+      - Dockerfile.debian-armhf
+      - .gitlab-ci.yml
+  services:
+    - docker:dind
+  variables:
+    DOCKER_HOST: tcp://docker:2375
+    DOCKER_DRIVER: overlay2
+  script:
+    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
+    - docker build -t $CI_REGISTRY/$CI_PROJECT_PATH/igt-debian-armhf -f Dockerfile.debian-armhf .
+    - docker push $CI_REGISTRY/$CI_PROJECT_PATH/igt-debian-armhf
+
 containers:igt-debian-arm64:
   stage: containers
   image: docker:stable
diff --git a/Dockerfile.debian-armhf b/Dockerfile.debian-armhf
new file mode 100644
index 00000000..81ad5c61
--- /dev/null
+++ b/Dockerfile.debian-armhf
@@ -0,0 +1,46 @@
+FROM debian:stretch-backports
+
+RUN apt-get update
+RUN apt-get install -y \
+			flex \
+			bison \
+			pkg-config \
+			x11proto-dri2-dev \
+			python-docutils \
+			valgrind \
+			peg
+
+RUN dpkg --add-architecture armhf
+RUN apt-get update
+RUN apt-get install -y \
+			gcc-arm-linux-gnueabihf \
+			libpciaccess-dev:armhf \
+			libkmod-dev:armhf \
+			libprocps-dev:armhf \
+			libunwind-dev:armhf \
+			libdw-dev:armhf \
+			zlib1g-dev:armhf \
+			liblzma-dev:armhf \
+			libcairo-dev:armhf \
+			libpixman-1-dev:armhf \
+			libudev-dev:armhf \
+			libgsl-dev:armhf \
+			libasound2-dev:armhf \
+			libjson-c-dev:armhf \
+			libcurl4-openssl-dev:armhf \
+			libxrandr-dev:armhf \
+			libxv-dev:armhf
+
+RUN apt-get install -t stretch-backports -y \
+					meson \
+					libdrm-dev:armhf \
+					qemu-user \
+					qemu-user-static
+
+# autotools build deps
+RUN apt-get install -y \
+			autoconf \
+			automake \
+			xutils-dev \
+			libtool \
+			make
diff --git a/meson-cross-armhf.txt b/meson-cross-armhf.txt
new file mode 100644
index 00000000..36260faa
--- /dev/null
+++ b/meson-cross-armhf.txt
@@ -0,0 +1,12 @@
+[binaries]
+c = '/usr/bin/arm-linux-gnueabihf-gcc'
+ar = '/usr/bin/arm-linux-gnueabihf-gcc-ar'
+strip = '/usr/bin/arm-linux-gnueabihf-strip'
+pkgconfig = 'pkg-config'
+exe_wrapper = 'qemu-arm'
+
+[host_machine]
+system = 'linux'
+cpu_family = 'arm'
+cpu = 'armv7'
+endian = 'little'
-- 
Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki.
Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki



More information about the igt-dev mailing list