From 1063bba06b4e4236350c426d3edf37f069728465 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Mon, 21 Jan 2019 15:00:34 +0000 Subject: [PATCH] CI: Do the CMake native debug build from an Autotools `make dist` We officially release dbus in the form of Autotools `make dist` tarballs, but people who have downloaded those tarballs should be able to choose the CMake build system. Our CI should assert that they can. (The Autotools debug build already does a `make distcheck`, which asserts that tarball releases can be used for an Autotools build.) Signed-off-by: Simon McVittie Resolves: dbus#255 --- .gitlab-ci.yml | 2 +- .travis.yml | 2 +- tools/ci-build.sh | 15 ++++++++++++++- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e1cefb73f..f291803b5 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -82,7 +82,7 @@ build:cmake: stage: build image: "debian:stretch-slim" variables: - ci_buildsys: "cmake" + ci_buildsys: "cmake-dist" script: *script build:i686-w64-mingw32-debug: diff --git a/.travis.yml b/.travis.yml index a609d774b..026cd06c1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -32,7 +32,7 @@ env: - ci_variant=debug - ci_variant=reduced - ci_variant=legacy - - ci_buildsys=cmake + - ci_buildsys=cmake-dist - ci_host=i686-w64-mingw32 - ci_host=i686-w64-mingw32 ci_buildsys=cmake ci_variant=debug - ci_host=x86_64-w64-mingw32 ci_variant=debug diff --git a/tools/ci-build.sh b/tools/ci-build.sh index 8e22f84d5..a4e1e1828 100755 --- a/tools/ci-build.sh +++ b/tools/ci-build.sh @@ -101,6 +101,19 @@ maybe_fail_tests () { # own checks. NOCONFIGURE=1 ./autogen.sh +case "$ci_buildsys" in + (cmake-dist) + # Do an Autotools `make dist`, then build *that* with CMake, + # to assert that our official release tarballs will be enough + # to build with CMake. + mkdir ci-build-dist + ( cd ci-build-dist; ../configure ) + make -C ci-build-dist dist + tar --xz -xvf ci-build-dist/dbus-1.*.tar.xz + cd dbus-1.*/ + ;; +esac + srcdir="$(pwd)" mkdir ci-build-${ci_variant}-${ci_host} cd ci-build-${ci_variant}-${ci_host} @@ -287,7 +300,7 @@ case "$ci_buildsys" in fi ;; - (cmake) + (cmake|cmake-dist) case "$ci_host" in (*-w64-mingw32) set _ "$@" -- 2.47.3