Commit Graph

209 Commits

Author SHA1 Message Date
Philip Withnall
e89f41d3bf ci: Rebuild Fedora Docker image for latest Dockerfile changes
See !1464.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2020-05-22 09:32:44 +01:00
Sebastian Dröge
12fbb286ae Merge branch 'fix-cpu-docker' into 'master'
ci: Update Android Docker image for aarch64 CPU naming change

See merge request GNOME/glib!1402
2020-05-14 15:12:48 +00:00
Bastien Nocera
555fc57a1c ci: Fix documentation tarball compression
Best compress using xz when using .tar.xz suffixes.
2020-05-07 11:14:35 +01:00
Bastien Nocera
48f756616d ci: Fix paths for dist'ed documentation 2020-05-07 11:14:35 +01:00
Christoph Reiter
c3645a84b6 CI: Switch to new Windows runners
gitlab will drop cmd.exe support with GitLab 13 so I took the opportunity to
add new runners with Windows 2016 and powershell as default.

These runners are tagged with win32-ps instead of win32. The old runners
will be switched off in the coming weeks.

The main difference is that all commands and env expansions use powershell
and Windows 2016 instead of 2012r2.
2020-04-29 08:56:56 +02:00
Xavier Claessens
be3728b9fa Meson: Add glib_checks and glib_asserts options
In cases where performance are critical it can be useful to disable
checks and asserts. GStreamer has those options too, using the same name
and setting them yielding means we can set those options on the main
project (e.g. gst-build) and glib will inherit the same value when built
as subproject.
2020-04-09 09:17:35 -04:00
Simon McVittie
dff2e3b4c7 CI: Show execution environment before we start
This will help to debug CI issues that are related to us running in
a container that might have unusual capabilities, mount points,
filesystems etc., such as (probably) #2027, #2028, #2029.

Signed-off-by: Simon McVittie <smcv@collabora.com>
2020-03-04 15:25:47 +00:00
Philip Withnall
b9e071f119 ci: Update Android Docker image for aarch64 CPU naming change
See !1376. Update the Docker image for Android after merging that
change.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2020-03-02 14:17:25 +00:00
Philip Withnall
2d7b2a014b ci: Enable parallelisation when running installed tests
This should speed up CI runs significantly, as the installed tests are
currently running in series.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2020-02-24 11:06:00 +00:00
Bastien Nocera
f333a8058d ci: Fix xdg-desktop-portal build
Newer versions of xdg-desktop-portal need a newer PipeWire, so use the
latest release that doesn't contain this change to avoid having
something else to build.
2020-02-21 19:50:12 +01:00
Bastien Nocera
7263fc5591 ci: Don't ignore xdg-desktop-portal build failure
CI scripts are done using a shell with 'set -e' enabled, but using
'&&' means that the line won't "fail". Run the different commands
sequentially instead.

Spotted by Simon McVittie <smcv@collabora.com>

Closes: #2043
2020-02-21 18:49:56 +01:00
Bastien Nocera
1cc2f51382 ci: Bump Fedora Docker image version
To incorporate changes from the previous 4 commits.
2020-02-04 17:52:16 +01:00
Bastien Nocera
6ff2a181bd ci: Install build deps for extra modules in Docker image
Rather than bringing build dependencies for gobject-introspection
and xdg-desktop-portal manually, install them in the Docker image.
2020-02-04 17:28:07 +01:00
Bastien Nocera
4aa14d5770 ci: Require some updated packages Fedora Docker image
Rather than installing those updates manually.
2020-02-04 17:28:07 +01:00
Emmanuele Bassi
5e20086edc Merge branch '1551-todo-ci' into 'master'
ci: Add checks for ‘TODO’ in merge requests

Closes #1551

See merge request GNOME/glib!794
2020-01-31 15:35:29 +00:00
Xavier Claessens
47a20304bd ci: Update Meson to 0.52.1 in fedora docker
This is required to be able to build the doc. The debian docker is still
pinned to 0.49.2 which ensure we can build with both versions of meson.

Meson 0.52.0 warns about adding -Wall flag manually, we can remove that
because warning_level=1 (the default) option already implies it.
2020-01-29 15:54:53 +01:00
Xavier Claessens
09d995286b doc: Run gtkdoc-check with unit tests
This has the side effect of always rebuilding the doc at each build when
gtk_doc option is enabled (not by default). Most importantly, this will
enable doc check on our CI.
2020-01-29 15:54:53 +01:00
Philip Withnall
3f51963b2d ci: Add checks for banned keywords in merge requests
Using the same approach as we have for code style checks (the
`style-check-diff` CI job), check the diff for any banned keywords like
‘TODO’, and also check the commit messages.

The keyword ‘TODO’ is often used by developers to indicate a part of a
commit which needs further work, and hence which shouldn’t yet be merged.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Fixes: #1551
2020-01-21 12:26:47 +00:00
Philip Withnall
df0610aa55 ci: Use --wrap-mode=default on macOS CI runner (only)
This is a partial revert of commit 595e12b5fb for macOS only, since we
can’t run a VM image on that CI runner, and hence can’t easily
pre-populate it with cached dependencies.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2020-01-20 15:30:44 +00:00
Xavier Claessens
595e12b5fb ci: Pass --wrap-mode=nodownload to every task
The CI should not waste resources in downloading subprojects for each
task. It should also not rely on external hosts to be available.

Windows case will be handled in MR #402 by migrating to docker.
2020-01-15 21:36:57 -05:00
Xavier Claessens
5f99781d70 ci: Update all docker images 2020-01-15 21:36:57 -05:00
Xavier Claessens
b077c1403e ci: Cache subprojects in docker images 2020-01-15 21:36:57 -05:00
Xavier Claessens
8661d94c3e ci: Install some missing packages in fedora docker image 2020-01-15 21:36:57 -05:00
Xavier Claessens
5daad373a3 ci: Use variables for docker images 2020-01-15 21:36:57 -05:00
Philip Withnall
076fd5a922 WIP: ci: Add macOS CI runner
We had one before, but the runner machine was too flaky to be useful.
Re-add it now that the Foundation have sorted out a more reliable
machine. (Thanks!)

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Fixes: #1416
2020-01-07 10:32:46 -05:00
Philip Withnall
de7d7dbd6c 2.63.3
Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-12-16 13:57:28 +00:00
Bastien Nocera
5a174d105d ci: Fix permission error in valgrind analysis stage
The valgrind analysis stage inherits from existing artefacts, so make
sure to reset the permissions on the glib build directory to avoid a new
build failing.

$ meson ${MESON_COMMON_OPTIONS} --werror -Dsystemtap=true -Ddtrace=true -Dfam=true -Dinstalled_tests=true _build
<snip>
PermissionError: [Errno 13] Permission denied: '/builds/GNOME/glib/_build/meson-logs/meson-log.txt'
2019-12-12 10:59:47 +01:00
Bastien Nocera
c782042087 ci: Disable xdg-desktop-portal tests
They're not needed to actually run xdg-desktop-portal itself, and
we won't need libportal then.
2019-12-11 15:23:31 +01:00
Bastien Nocera
4b6ad93c86 ci: GMemoryMonitor support is now merged in gobject-introspection 2019-12-11 15:12:01 +01:00
Bastien Nocera
5a58da36d2 ci: Fix installed-tests until a newer GLib is released
Force-enable portal memory monitor until 2.63.3 is released
2019-12-11 14:15:54 +01:00
Bastien Nocera
bf91e3adf7 ci: GMemoryMonitor support is now merged in xdg-desktop-portal 2019-12-11 14:15:54 +01:00
Bastien Nocera
ae26695843 ci: Add dependencies for newer installed tests 2019-12-11 11:44:42 +00:00
Bastien Nocera
8520163bdf ci: Work-around successful installed tests having no logs
This works around a bug in gnome-desktop-testing.

See: https://gitlab.gnome.org/GNOME/gnome-desktop-testing/merge_requests/2
2019-12-11 10:32:13 +01:00
Bastien Nocera
7ec118f93a ci: Log successes for installed-tests as well
Use newer version of gnome-desktop-testing to log test results even if
successful.
2019-12-04 14:06:23 +01:00
Bastien Nocera
3a3382c275 tests: Don't skip static-link test
Set GLIB_TEST_COMPILATION=1 envvar so that the static-link test is run.
2019-12-04 14:06:23 +01:00
Bastien Nocera
ead670b1c4 ci: Run installed-tests on Fedora
Run installed-tests on a Fedora system.
2019-12-04 14:06:23 +01:00
Philip Withnall
805dc2ae93 ci: Move style-check-diff commands out to a separate sh file
This doesn’t change how they run, but does split the code out a bit and
mean we can interleave it with comments. Should make it a little less
vile.

Suggested by Emmanuele Bassi; see !1252.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-11-28 11:47:48 +00:00
Philip Withnall
95b8c1c697 ci: Use extends rather than YAML anchors for only-default
This makes things slightly more extensible in future, but introduces no
functional differences right now.

See https://docs.gitlab.com/ce/ci/yaml/README.html#extends.

Suggested by Jordan Petridis.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-11-28 11:38:25 +00:00
Philip Withnall
cd11067a03 ci: Use new Fedora v5 Docker image for all CI jobs
v5 was built using the fedora.Dockerfile updates from the previous few
commits.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-11-27 13:23:45 +00:00
Philip Withnall
2daebc7674 ci: Fix running all jobs on merge requests
Since we added `only: [merge_requests]` for the `style-check-diff` job,
that started running detached pipelines only for merge requests and only
containing that job, and not running the other jobs for merge requests
(only for branches).

That wasn’t the intention.

Follow the guide on
https://docs.gitlab.com/ee/ci/merge_request_pipelines/index.html#excluding-certain-jobs
to ensure that all jobs (including `style-check-diff`) are run for merge
requests.

This means we can no longer unconditionally use
`${CI_MERGE_REQUEST_TARGET_BRANCH_{NAME,SHA}}`, since they are only
defined for jobs which are running against a merge request rather than a
branch. Instead, use some `git rev-list` magic from
https://stackoverflow.com/a/4991675/2931197 to find the newest common
ancestor commit between the detached head that CI is running on, and the
known or likely target branch. Do the style check against the diff
between the newest common ancestor commit and the detached head.

(Note that `${CI_MERGE_REQUEST_TARGET_BRANCH_SHA}` was never actually
defined for any of our pipelines, since it’s only available for CI
pipelines running on merged branches, which is a GitLab Premium
feature. Oops, my bad.)

In order to find the newest common ancestor commit, we need to pull the
upstream remote, since the CI pipeline might be running on a fork of the
main repository where various branches (particularly `master`) are out
of date.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-11-27 12:00:54 +00:00
Philip Withnall
3156ea5be7 ci: Factor out only/except properties from jobs
We can use a template to factor these out and make things a bit more
maintainable. This should introduce no functional changes.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-11-27 12:00:53 +00:00
Philip Withnall
efa7fa0375 ci: Run the style-check pipeline stage first
Don’t waste CI resources on compiling things which don’t comply with the
style rules.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-11-27 12:00:20 +00:00
Philip Withnall
b7fe4b84ee ci: Update all Debian CI runners to use v5 of the Dockerfile
This shouldn’t affect them (since it just adds the `clang-format-7`
package), but it’s good to keep everything on the same version.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

See: #1552
2019-11-25 10:51:14 +00:00
Pavlo Solntsev
e95f47c395
CI: Code check formating in CI 2019-11-21 14:03:01 -06:00
Philip Withnall
1a53b73816 ci: Update .gitlab-ci.yml to use the latest Docker images
This is a follow-up to !1177, now that we’ve generated the new images.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-11-04 15:25:38 +00:00
Philip Withnall
197eff3fc8 ci: Add valgrind memcheck support on Fedora
Add a separate CI job which runs memcheck on the unit tests. This is
done as a separate job from the main build, since we don’t want it to
interact with code coverage at all.

Currently, failure of this job is ignored. Issue #333 will eventually
fix that.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Fixes: #487
2019-09-02 14:16:33 +01:00
Philip Withnall
8d19b95bd8 ci: Add valgrind to fedora Docker image
It will be used in an upcoming commit.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Helps: #487
2019-09-02 14:16:33 +01:00
Emmanuele Bassi
bd372e3174 ci: Fix non-build jobs
All non-build jobs must share the same Docker image with the Fedora
build job.
2019-07-24 13:32:55 +01:00
Emmanuele Bassi
f0d713e50d ci: Use the new Docker images 2019-07-24 13:08:06 +01:00
Ting-Wei Lan
4bf3cb0e54 ci: Enable CI on FreeBSD 12 2019-06-25 00:46:52 +08:00
Philip Withnall
82906e5d5d ci: Run scan-build in a different build directory
The build artifacts from earlier jobs in the pipeline all use the
`_build` directory. When they are copied in to the scan-build job, they
are probably marked as read-only. This means that the `meson scan-build`
run can’t write to `_build/meson-logs/meson-log.txt` and fails.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-06-12 14:31:42 +01:00
Philip Withnall
d23a8bd6e4 ci: Add scan-build job in a new ‘analysis’ pipeline stage
Use Meson’s support for running scan-build (Clang’s static analyser)
against the build, so that we get static analysis of each pipeline. Add
it in a new pipeline stage, after code coverage, so that we don’t waste
resources on it unless the unit tests pass — a static analysis build
takes perhaps 10× as long as a normal GCC build.

https://mesonbuild.com/howtox.html#use-clang-static-analyzer

Currently, the static analysis results are uploaded as artifacts, but
the job will always succeed (regardless of whether there are any bugs
found in the analysis).

Currently, a large number of reports are outputted by the analyser,
which need to be fixed before we can gate the pipeline on it.
Furthermore, in order to get scan-build to exit with a non-zero status
if any bugs are found, we need to depend on Meson ≥ 0.49.0, which
contains the fix https://github.com/mesonbuild/meson/issues/4334,
allowing us to add the following to .gitlab-ci.yml:
```
variables:
  # Exit with a non-zero status if any bugs are found
  SCANBUILD: "scan-build --status-bugs"
```

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-05-01 12:48:08 +01:00
Emmanuele Bassi
0b609b53fa ci: Add a debian-stable job
So we can test ancient toolchains.
2019-04-30 18:26:15 +01:00
Emmanuele Bassi
992e7cee34 ci: Move to per-job images
We don't use a global Docker image any more.
2019-04-30 18:26:15 +01:00
Nirbheek Chauhan
17823fa820 ci: The iconv combo option values have changed 2019-04-12 11:12:28 +05:30
Chun-wei Fan
3e54a34e33 CI: Run test coverage for Visual Studio builds
Ensure that we do run it and upload the results.
2019-04-08 16:51:47 +08:00
Emmanuele Bassi
95b7a8ab10 ci: Run test coverage for MSYS2 job 2019-04-06 15:31:41 +01:00
Emmanuele Bassi
ed65996300 ci: Generate a cover report for the test suite
GitLab can show the results of a CI pipeline if the pipeline generates a
report using the JUnit XML format.

Since Meson provides a machine parseable output for `meson test`, we can
take that and turn it into XML soup.
2019-04-06 14:19:20 +01:00
Philip Withnall
9ce76b97f1 ci: Add a build with G_DISABLE_ASSERT defined
We want GLib to build correctly with this defined, and for all its tests
to still pass.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Helps: #1708
2019-03-08 19:46:21 +00:00
Philip Withnall
6a372bf703 Merge branch 'disable-tests' into 'master'
Temporarily disable flaky tests

See merge request GNOME/glib!579
2019-01-15 16:45:15 +00:00
Philip Withnall
c8797d7a42 ci: Drop autotools CI build
We’re about to drop autotools support entirely in master.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-01-15 15:11:43 +00:00
Philip Withnall
7058efb390 ci: Don’t run tests tagged as ‘flaky’ on the CI machines
This effectively renders those tests useless (since realistically nobody
runs tests locally), but it’s better than every other CI run failing for
unrelated reasons. The idea is that the ‘flaky’ tag can be temporarily
applied to a test while a problem is being investigated or fixed, and
then removed later.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2019-01-09 10:47:24 +00:00
Tomasz Miąsko
ee9f5c5717 ci: Update docker image to master:v11 2018-12-03 14:11:30 +01:00
Will Thompson
ab892acf11
ci: add bindfs and fuse to Fedora CI image
Without `bindfs` and `fusermount`, all tests in
g-file-info-filesystem-readonly.c are skipped.
2018-11-13 10:37:46 +00:00
Philip Withnall
304f84ba46 ci: Fix Docker image version
Someone uploaded a v9 image to the registry without updating the CI
YAML.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-10-29 13:30:28 +00:00
Xavier Claessens
7fa6e9e837 CI: Test static build on installed glib 2018-10-23 09:45:12 -04:00
Ting-Wei Lan
fb8d95467d ci: Enable FreeBSD CI in the official repository
Since we are unable to promote our FreeBSD runner to a shared runner,
we can only enable it in GNOME group. This should avoid problems when
submitting merge requests from forks.
2018-10-09 23:06:06 +08:00
Philip Withnall
8efe28c570 ci: Add lcov configuration to ignore g_return_*if_fail()/g_assert*()
While we can’t add markers to the macro implementations to cause lcov to
ignore them automatically, we can change our lcov configuration to
ignore all calls to them.

See https://github.com/linux-test-project/lcov/issues/44.

This causes all the un-takeable branches and un-reachable assertions to
be ignored by our code coverage, which bumps our statistics:
 • Lines: 74.9% → 74.8%
 • Functions: 82.3% → 82.3%
 • Branches: 53.3% → 64.2%

The rationale is that nobody should be testing programmer error
handling, as g_return_*if_fail() are used to guard against — so it’s not
reasonable to count missed branches like that in code coverage
statistics.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-10-06 00:19:20 +01:00
Philip Withnall
da8f1c6ac3 Revert "ci: Enable FreeBSD CI"
This partially reverts commit bfc362cb68.

The FreeBSD CI runner still seems to be a bit flakey, and appears to be
offline entirely at the moment.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
Reviewed-by: nobody
2018-10-03 13:12:22 +01:00
Ting-Wei Lan
bfc362cb68 ci: Enable FreeBSD CI 2018-09-29 01:05:39 +08:00
Xavier Claessens
4b983e5122 ci: Upgrade meson to 0.48.0 and use --fatal-meson-warnings 2018-09-27 16:00:53 -04:00
Xavier Claessens
90815c160b Merge branch 'autotools-config.h' into 'master'
ci: Include config.h in autotools output artifacts

See merge request GNOME/glib!281
2018-08-30 14:25:14 +00:00
Philip Withnall
3ced28df3e ci: Disable the coverage CI job when running dist on a release
It fails because dist-job (correctly) doesn’t build with the code
coverage CFLAGS enabled.

Leave coverage to be generated on master and development branches.

See this pipeline for an example of when it fails:
https://gitlab.gnome.org/GNOME/glib/pipelines/26349

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-08-30 13:51:59 +01:00
Philip Withnall
99decc0634 ci: Include config.h and glibconfig.h in CI output artifacts
It’s useful to see what configuration was generated.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-08-29 12:13:17 +01:00
Christoph Reiter
856f7ebe2b ci: Add an autotools job 2018-08-24 18:12:22 +02:00
Xavier Claessens
9f208e9f2b Fix failing tests when G_MESSAGES_DEBUG is set (again)
Similar issue was fixed with commit f929d148, but it's happening again.
Define G_MESSAGES_DEBUG=all when running CI to ensure we won't regress
anymore.
2018-08-16 15:55:51 -04:00
Christoph Reiter
31d34c22d2 ci: switch the freebsd-11 job to manual mode
So it doesn't block the pipeline until it times out.
According to the runner info page it hasn't been up for 16 days.
2018-07-12 11:05:56 +02:00
Philip Withnall
884c4f4eb6 ci: Add allow_failure: true to FreeBSD runner
The FreeBSD runner is not stable yet. See
https://gitlab.gnome.org/Infrastructure/GitLab/issues/286.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
Reviewed-by: nobody
2018-07-09 09:53:33 +01:00
Philip Withnall
6fea3289db Merge branch 'wip/lantw/ci-on-freebsd' into 'master'
Fix tests and add CI for FreeBSD

See merge request GNOME/glib!57
2018-07-08 18:41:30 +00:00
Philip Withnall
7c8aaa7e0d Merge branch 'ci-coverage-include-baseline' into 'master'
CI: Include coverage data of code which isn't executed by the test suite.

See merge request GNOME/glib!152
2018-07-06 12:28:52 +00:00
Christoph Reiter
69ae2f4242 CI: Include coverage data of code which isn't executed by the test suite.
See comment in !151. Using the "--initial" option of lcov we collect
the coverage of all compiled files and merge them later into the final
report. This way we can see which files are built but never executed
by the test suite.

Because the --initial switch also collects files in the ccache directory
we have to point it to the build directory instead, which in turn breaks
--no-external. Instead of using --no-external in the collection step,
filter out any files not in the source tree in the final coverage job
through a path filter.
2018-07-06 09:36:01 +02:00
Xavier Claessens
543a9c4f33 ci: Fix dist-job missing gobject/gio documentation
This requires meson >= 0.47.0 otherwise building the doc fails:
https://github.com/mesonbuild/meson/issues/3379

While at it, no need to to pass --prefix --libdir to meson, other CIs
don't have them.
2018-07-03 11:00:54 -04:00
Xavier Claessens
9d73ea8975 ci: Update meson to 0.47.0 in docker image 2018-07-03 11:00:54 -04:00
Xavier Claessens
cf9613056c ci: Add latest Android API level 28
- Split the download part into a separate script to so docker keeps that
step in cache and avoid redownloading it.

- With API level >= 28 libiconv is not needed anymore because it's part
of Android's libc.

- Generate standalone toolchains to reduce the docker image size. It's
also easier because it doesn't need to pass sysroot args.

- Use clang compiler because gcc is deprecated in this Android NDK and
will be removed in the next release.
2018-06-27 09:23:13 -04:00
Xavier Claessens
b3508123e2 ci: factor out cross compilation jobs definitions 2018-06-27 09:18:05 -04:00
Ting-Wei Lan
064cb2b001 ci: Add FreeBSD CI
We use 'freebsd-11' instead of 'freebsd' as tags here because newer
FreeBSD versions can include API changes which are worth testing.
2018-06-26 23:18:04 +08:00
Xavier Claessens
94748af0e1 ci: Use shorter job names
Job names in gitlab pipeline view gets truncated to  "fedora-meson-..."
for all jobs which is not really useful. All our CIs are using Meson,
and the host distro is not relevant when doing cross builds.
2018-06-22 11:49:08 -04:00
Xavier Claessens
9a76e08ae1 ci: Update Android NDK to r17b
We should be testing latest NDK release but keep using API level 21 to
ensure GLib does not start using newer APIs. We could also later add a
runner for latest API level 28 which includes iconv API in Android's
libc so we don't need GNU libiconv anymore.
2018-06-22 11:49:08 -04:00
Xavier Claessens
7016aedde8 ci: Build fam module on linux 2018-06-07 11:33:43 -04:00
Xavier Claessens
79c1cd21f2 ci: Be consistent on artifact naming 2018-06-05 14:01:53 -04:00
Xavier Claessens
a4ccb4972c ci: No need to "cd _build" and set prefix/libdir 2018-06-05 13:58:48 -04:00
Xavier Claessens
34e0c5a799 ci: Add missing "except: tags" 2018-06-05 13:39:26 -04:00
Philip Withnall
4100c84c06 Merge branch 'msys2-export-meson-logs-artifacts' into 'master'
ci: Export meson-logs from msys2-mingw32 build as artifacts

See merge request GNOME/glib!33
2018-05-29 10:45:28 +00:00
Philip Withnall
91208e8d3f ci: Clarify artifact naming
Put the job name and commit identifier in the artifact names.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-05-29 10:54:29 +01:00
Philip Withnall
a53d74e078 ci: Always export artifacts from Fedora build
The default `when: on_success` means no artifacts are exported when the
tests fail, which is precisely when we want to see the artifacts.

Always export them, and rely on GitLab to garbage collect them as
appropriate (typically after 30 days, I think).

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-05-29 10:53:41 +01:00
Philip Withnall
1041504099 ci: Export meson-logs from msys2-mingw32 build as artifacts
This means that compilation and test failures will leave logs on the CI
machines which we can use to debug the failures.

Always export the artifacts. The default `when: on_success` is
appropriate for now, but won’t be in future when the tests actual report
their success value correctly.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-05-29 10:52:01 +01:00
Xavier Claessens
cd47f8d8de Revert "Add macosx CI"
Disable macosx CI until we get proper hosting, the test machine we had
is too old and slow.

This reverts commit 042b057e4d.
2018-05-28 13:58:06 -04:00
Xavier Claessens
042b057e4d Add macosx CI
Fixes #265.
2018-05-28 11:15:01 -04:00
Xavier Claessens
3145d88f4b Add mingw64 cross build CI
Fixes #1387.
2018-05-28 09:22:55 -04:00
Xavier Claessens
f83493f83d Add Android CI
This adds to the CI a cross build for Android NDK r16 API 21 (because
thats what GStreamer currently use) for arm64.

GNU iconv must be built manually into our docker image because Android
NDK doesn't seems to ship it. The latest NDK r17 API 28 has iconv.h but
iconv_open() symbol isn't found by the linker. Looks like broken NDK.

libffi also needs to be built manually because the meson subproject
doesn't support building for Android platform. It needs a recent RC
release because latest stable release is 4 years old and fails to
build.

Fixes #1385.
2018-05-28 09:17:41 -04:00
Christoph Reiter
5dfdcb372f ci: unify the test timeout multiplier across jobs
Introduce a MESON_TEST_TIMEOUT_MULTIPLIER env var and use it in all test scripts.
2018-05-26 20:19:53 +02:00
Christoph Reiter
e7259c52ba ci: Add a VS2017 job
Thanks to Xavier Claessens for figuring out what is needed.
2018-05-25 11:44:14 +02:00
Philip Withnall
524d96fd92 ci: Add a regex to parse line coverage statistics from genhtml output
GitLab can then use this to annotate each pipeline with its code
coverage statistics. It can only use one figure, so we choose lines
(rather than function or branch coverage) since it’s the most intuitive
figure.

This parses the ‘lines’ line from output like:

Overall coverage rate:
  lines......: 76.7% (108959 of 142122 lines)
  functions..: 80.7% (10294 of 12763 functions)
  branches...: 51.3% (50226 of 97953 branches)

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-05-24 23:44:53 +01:00
Christoph Reiter
3d2ab4680d ci: use timeout-multiplier=2 for running the tests
It looks like the coverage generation makes the tests a bit slower and
some are now hitting timeouts. Flaky tests are always more annoying than
slow ones, and we don't know how much resources we get under CI,
so increase the timeout.

https://bugzilla.gnome.org/show_bug.cgi?id=795636
2018-05-02 14:52:50 +02:00
Christoph Reiter
961be2b0bf ci: collect test coverage and deploy a html report through gitlab pages
Use lcov for both Fedora and MSYS2 to create coverage reports and add a second
ci stage which merges the coverage and creates a html report using genhtml.

In the final stage, which is only run on master, the result is published on
gitlab pages.

https://bugzilla.gnome.org/show_bug.cgi?id=795636
2018-05-02 11:14:45 +01:00
Christoph Reiter
e8798a4c22 ci: update meson
Rebuild the fedora docker image to get the newest meson release and
use pip to install the newest version for MSYS2.

https://bugzilla.gnome.org/show_bug.cgi?id=795711
2018-05-02 11:09:25 +01:00
Philip Withnall
a20c8d4421 ci: Rename build-job to fedora-meson-x86_64 for uniqueness
Makes it a bit more easily differentiable from the new `msys2-mingw32`
job.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-04-26 10:11:29 +01:00
Christoph Reiter
995f75cdd7 gitlab-ci: Add 32bit MinGW jobs using MSYS2
This builds glib using meson/ninja/ccache with mingw-w64 on a Windows
machine.

The CI scripts expect a gitlab runner to exist with the "win32" tag
which uses the default "cmd" shell by default.

Before running the tests pacman is invoked to update the system
(potentially including bash etc, thus the extra step)
Then a login shell is started with CHERE_INVOKING to not change the
cwd and finally the test script is executed.

https://bugzilla.gnome.org/show_bug.cgi?id=793729
2018-04-25 17:23:49 +02:00
Emmanuele Bassi
e04d2e81fc ci: Add GitLab CI description file
We're mostly interested into building and testing everything that gets
pushed to the repository — including merge requests.

When pushing tags, though, we should assume we're spinning a release, so
let's run the dist target, and store the tarball, and the generated
documentation while we're at it, as artifacts on GitLab.

The Dockerfile for the image used for the build is included in tree, and
published on Docker Hub. Using a custom image allows us to avoid the
costly "download and install build dependencies" phase, as well as
controlling the environment a little bit better.

https://bugzilla.gnome.org/show_bug.cgi?id=793635
2018-02-20 13:49:21 +00:00