summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLubomir Rintel <lkundrak@v3.sk>2018-05-28 17:06:46 +0200
committerLubomir Rintel <lkundrak@v3.sk>2018-05-31 17:36:17 +0200
commit05b935e9f8f2d805e885538de475e1dc59916afb (patch)
tree385a2d204cb05ee7e3119f058e45d7a5b214ca01
parent678890ed0347849990787e8893122a39f95cb708 (diff)
downloadnetwork-manager-applet-05b935e9f8f2d805e885538de475e1dc59916afb.tar.gz
build: add GNOME GitLab CI configurationlr/gitlab-ci
The pipeline begins with "build" stage doing a distcheck on Fedora 28 (which is still known to ship libnm-glib) and outputting a tarball artifact. The output is then used in the "test" stage. Some repetition is avoided with YAML map capability, but that's fairly limited. Both autotools and meson build/installs are done with both autotools and meson on latest Fedora (happens to be Fedora 28 too). That seems to be a reasonable enough for start, given we can't test all possible combinations. In future, builds on some older platforms, CentOS and Ubuntu and clang builds would be nice. Not implemented at this point, but it should be straightforward enough. Maybe a build with a Git snapshot of NetworkManager would be useful at some point, but that's not implemented wither.
-rw-r--r--.gitlab-ci.yml187
1 files changed, 187 insertions, 0 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 00000000..9594cddd
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,187 @@
+# Quick syntax check:
+# python -c 'import sys, yaml; yaml.dump (yaml.load (sys.stdin), sys.stdout)' <.gitlab-ci.yml
+
+# If things don't seem to work, this can help:
+# https://gitlab.gnome.org/GNOME/network-manager-applet/-/ci/lint
+
+.fedora_minimal: &fedora_minimal
+ before_script:
+ - dnf -y install
+ file
+ findutils
+ gcc
+ desktop-file-utils
+ gettext-devel
+ glib2-devel
+ gtk3-devel
+ intltool
+ libgudev1-devel
+ libnotify-devel
+ libsecret-devel
+ NetworkManager-libnm-devel
+ pkgconfig
+ /usr/bin/autopoint
+
+.fedora_full: &fedora_full
+ before_script:
+ - dnf -y install
+ file
+ findutils
+ gcc
+ desktop-file-utils
+ gettext-devel
+ glib2-devel
+ gtk3-devel
+ intltool
+ libgudev1-devel
+ libnotify-devel
+ libsecret-devel
+ NetworkManager-libnm-devel
+ pkgconfig
+ /usr/bin/autopoint
+ gcr-devel
+ gobject-introspection-devel redhat-rpm-config
+ gtk-doc
+ iso-codes-devel
+ jansson-devel
+ ModemManager-glib-devel
+ libselinux-devel
+
+.dist: &dist
+ stage: test
+ dependencies:
+ - fedora28_dist
+ variables:
+ GIT_STRATEGY: none
+
+.fedora_meson_minimal: &fedora_meson_minimal
+ <<: *fedora_minimal
+ <<: *dist
+ script:
+ - tar xJf network-manager-applet-*.tar.xz
+ - dnf -y install meson
+ - meson
+ -Dlibnm_gtk=false
+ -Dwwan=false
+ -Dselinux=false
+ -Dteam=false
+ -Dgcr=false
+ -Diso_codes=false
+ -Dld_gc=false
+ -Dgtk_doc=false
+ -Dintrospection=false
+ -Dappindicator=no
+ -Dmore_asserts=no
+ network-manager-applet-*/ build
+ - ninja -v -C build
+ - ninja -v -C build test
+ - ninja -v -C build install
+ - ninja -v -C build uninstall
+
+.fedora_meson_full: &fedora_meson_full
+ <<: *fedora_full
+ <<: *dist
+ script:
+ - dnf -y install meson
+ - tar xJf network-manager-applet-*.tar.xz
+ - meson
+ -Dlibnm_gtk=false
+ -Dwwan=true
+ -Dselinux=true
+ -Dteam=true
+ -Dgcr=true
+ -Diso_codes=true
+ -Dld_gc=true
+ -Dgtk_doc=true
+ -Dintrospection=true
+ -Dappindicator=no
+ -Dmore_asserts=yes
+ network-manager-applet-*/ build
+ - ninja -v -C build
+ - ninja -v -C build test
+ - ninja -v -C build install
+ - ninja -v -C build uninstall
+
+.fedora_autotools_minimal: &fedora_autotools_minimal
+ <<: *fedora_minimal
+ <<: *dist
+ script:
+ - dnf -y install make
+ - tar xJf network-manager-applet-*.tar.xz
+ - cd network-manager-applet-*/
+ - ./configure
+ --disable-silent-rules
+ --with-more-asserts=no
+ --without-libnm-gtk
+ --disable-nls
+ --disable-iso-codes
+ --disable-gtk-doc
+ --disable-introspection
+ --disable-schemas-compile
+ --disable-more-warnings
+ --without-appindicator
+ --without-wwan
+ --without-selinux
+ --without-team
+ --without-gcr
+ - make -j
+ - make -j check
+ - make -j install
+ - make -j uninstall
+
+.fedora_autotools_full: &fedora_autotools_full
+ <<: *fedora_full
+ <<: *dist
+ script:
+ - dnf -y install make
+ - tar xJf network-manager-applet-*.tar.xz
+ - cd network-manager-applet-*/
+ - ./configure
+ --disable-silent-rules
+ --with-more-asserts=yes
+ --without-libnm-gtk
+ --enable-nls
+ --enable-iso-codes
+ --enable-gtk-doc
+ --enable-introspection
+ --enable-schemas-compile
+ --enable-more-warnings
+ --with-wwan
+ --with-selinux
+ --with-team
+ --with-gcr
+ - make -j
+ - make -j check
+ - make -j install
+ - make -j uninstall
+
+fedora28_dist:
+ <<: *fedora_full
+ image: fedora:28
+ stage: build
+ script:
+ - dnf -y install
+ autoconf automake make
+ NetworkManager-devel
+ NetworkManager-glib-devel
+ - sh autogen.sh
+ - make -j distcheck
+ artifacts:
+ paths:
+ - "*.xz"
+
+fedora_meson_minimal:
+ <<: *fedora_meson_minimal
+ image: fedora:latest
+
+fedora_meson_full:
+ <<: *fedora_meson_full
+ image: fedora:latest
+
+fedora_autotools_minimal:
+ <<: *fedora_autotools_minimal
+ image: fedora:latest
+
+fedora_autotools_full:
+ <<: *fedora_autotools_full
+ image: fedora:latest