From ac5c90d77197778ea26b5ef1ec8d25c0cb0911b4 Mon Sep 17 00:00:00 2001 From: Nikos Mavrogiannopoulos Date: Fri, 29 Jun 2018 16:29:34 +0200 Subject: [PATCH] gitlab-ci: Add build for mips platform This tests multiple items, (1) cross compilation, (2) compilation on debian and (3) CI run on MIPS systems, tested under qemu. This target was originally written for GnuTLS by Michael Weiser. Signed-off-by: Nikos Mavrogiannopoulos Reviewed-by: Andreas Schneider --- .gitlab-ci.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 70ec46ac..18cef9cb 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -252,3 +252,28 @@ mingw32: when: on_failure paths: - build/ + +.Debian.cross.template: &Debian_cross_template + stage: stage1-testing + image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$DEBIAN_CROSS_BUILD + script: + - build=$(dpkg-architecture -qDEB_HOST_GNU_TYPE) + - host="${CI_JOB_NAME#*.cross.}" + - export CC="$(which $host-gcc)" + - export CXX="$(which $host-g++)" + - mkdir -p obj && cd obj && cmake -DUNIT_TESTING=ON -DCMAKE_BUILD_TYPE=Debug + -DWITH_SFTP=ON -DWITH_SERVER=ON -DWITH_ZLIB=ON -DCMAKE_SYSTEM_NAME="$host" + -DWITH_PCAP=ON .. && make -j$(nproc) + - ctest --output-on-failure -j$(nproc) + tags: + - shared + except: + - tags + artifacts: + expire_in: 1 week + when: on_failure + paths: + - obj/ + +Debian.cross.mips-linux-gnu: + <<: *Debian_cross_template