summaryrefslogtreecommitdiff
path: root/.gitlab-ci.yml
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2019-09-04 12:37:04 +1000
committerSergey Udaltsov <sergey.udaltsov@gmail.com>2020-06-19 21:46:51 +0000
commit7095744237eeb7eccfd72d9958191d990587f1d5 (patch)
tree80b3d7cce6b2487fae6cdd8c4bdcc2621f1c8929 /.gitlab-ci.yml
parent3e39f931e39a81870f966f8e9fe24e1dd447e51b (diff)
downloadxkeyboard-config-7095744237eeb7eccfd72d9958191d990587f1d5.tar.gz
Add support for the meson build system
This produces virtually the same installed tree as the autotools builds with the following exceptions: - rules symlinks is no longer supported. This option is 16y old and likely hasn't been used in the last decade or so - the xkeyboard-config.pc file uses expanded paths now, e.g. xkb_base=/usr/share/X11/xkb vs autotools' xkb_base=${datarootdir}/X11/xkb The values are the same for both so this is not a functional change. - substitutions in the man page are hardcoded since we can't use the m4 XORG_MACROS. This appears to only matter for the miscmansuffix and there only for solaris up to including 11.3. so... meh? - the .mo files differ, but it's hard to say why since they're generated Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r--.gitlab-ci.yml37
1 files changed, 36 insertions, 1 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 1b008e5..6f26f3b 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -4,7 +4,7 @@
variables:
# minimal set of packages required to build xkeyboard-config. extra packages
# will be installed in the tests where required.
- ARCH_PKGS: 'xorg-util-macros autoconf automake make gettext pkg-config gcc grep m4 python'
+ ARCH_PKGS: 'xorg-util-macros autoconf automake make gettext pkg-config gcc grep m4 python meson ninja git'
BUILDDIR: '_build'
# installation directory must be inside $CI_PROJECT_DIR to allow for artifact caching
INSTDIR: '$CI_PROJECT_DIR/_inst'
@@ -33,6 +33,15 @@ variables:
- make
- if test x"$MAKE_EXTRA_COMMAND" != "x"; then make $MAKE_EXTRA_COMMAND; fi
+
+.meson_build:
+ extends: .default_setup
+ script:
+ - meson "$BUILDDIR" -Dprefix="$INSTDIR"
+ - meson configure "$BUILDDIR"
+ - ninja -C "$BUILDDIR"
+ - if test x"$NINJA_EXTRA_COMMAND" != "x"; then ninja -C "$BUILDDIR" $NINJA_EXTRA_COMMAND; fi
+
make_install:
extends: .default_build
stage: build
@@ -59,6 +68,32 @@ make_distcheck:
variables:
MAKE_EXTRA_COMMAND: "distcheck"
+meson_build:
+ extends: .meson_build
+ stage: build
+ variables:
+ NINJA_EXTRA_COMMAND: "install"
+ after_script:
+ - pacman -S --noconfirm tree
+ - tree $INSTDIR
+ artifacts:
+ name: installed files
+ expire_in: 20 min
+ paths:
+ - $INSTDIR/
+
+meson_test:
+ extends: .meson_build
+ stage: build
+ variables:
+ NINJA_EXTRA_COMMAND: "test"
+
+meston_dist:
+ extends: .meson_build
+ stage: build
+ variables:
+ NINJA_EXTRA_COMMAND: "dist"
+
xmllint:
image: archlinux/base
dependencies: ['make_install']