[librsvg/librsvg-2.52: 16/19] Copy CI templates configuration from the main branch
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [librsvg/librsvg-2.52: 16/19] Copy CI templates configuration from the main branch
- Date: Thu, 17 Feb 2022 03:49:56 +0000 (UTC)
commit 0f194657fcfd399ab085bcad97094d4c5ea0d978
Author: Federico Mena Quintero <federico gnome org>
Date: Wed Feb 16 20:56:13 2022 -0600
Copy CI templates configuration from the main branch
Maybe we can have nice things here, too?
.gitlab-ci.yml | 415 +++++++++++++++++++++++++++-------------
.gitlab-ci/container_builds.yml | 175 +++++++++++++++++
.gitlab-ci/env.sh | 2 +
.gitlab-ci/install-rust.sh | 36 ++++
.gitlab-ci/test-msys2.sh | 2 +
5 files changed, 493 insertions(+), 137 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 35037a3ce..5db70d1ca 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -1,19 +1,15 @@
# -*- indent-tabs-mode: nil -*-
-variables:
- # Container(OCI) images for various distros
-
- AMD64_FEDORA_LATEST: "registry.gitlab.gnome.org/gnome/librsvg-oci-images/amd64/fedora:latest"
- AMD64_OPENSUSE_TUMBLEWEED: "registry.gitlab.gnome.org/gnome/librsvg-oci-images/amd64/opensuse:tumbleweed"
- AMD64_DEBIAN_TESTING: "registry.gitlab.gnome.org/gnome/librsvg-oci-images/amd64/debian:testing"
+include:
+ - local: '.gitlab-ci/container_builds.yml'
+variables:
LIBRSVG_DEBUG: "yes"
# Turn compiler warnings into errors
RUSTFLAGS: '-D warnings'
-image: $AMD64_OPENSUSE_TUMBLEWEED
-
stages:
+ - container-build
- check
- build
- lint
@@ -26,12 +22,178 @@ stages:
default:
interruptible: true
+check:
+ extends:
+ - '.container.opensuse@x86_64.stable'
+ - '.fdo.distribution-image@opensuse'
+ - '.cache_push'
+ stage: check
+ needs: ['opensuse-container@x86_64.stable']
+ script:
+ - cargo check --all-targets
+
+cargo_test:
+ stage: check
+ extends:
+ - '.container.opensuse@x86_64.stable'
+ - '.fdo.distribution-image@opensuse'
+ # Tests require extra crates, hence cache is pushed
+ - '.cache_push'
+ needs:
+ - job: check
+ artifacts:
+ when: 'on_failure'
+ paths:
+ - _build/tests/output
+ expire_in: 1 day
+ variables:
+ OUT_DIR: "${CI_PROJECT_DIR}/tests/output"
+ script:
+ - cargo test -- --skip loading_crash --skip reference --skip render_crash
+
+.build-rsvg:
+ extends: '.cache'
+ stage: build
+ script:
+ - mkdir -p _build
+ - cd _build
+ - ../autogen.sh --enable-gtk-doc --enable-vala
+ - make
+ - make check
+ artifacts:
+ when: 'on_failure'
+ paths:
+ - _build/tests/*.log
+ - _build/tests/output
+ expire_in: 1 day
+
+build-rsvg-opensuse@x86_64.stable:
+ extends:
+ - '.container.opensuse@x86_64.stable'
+ - .fdo.distribution-image@opensuse
+ - .build-rsvg
+ # make check runs extra tests that require extra crates, hence cache is pushed
+ - .cache_push
+ needs:
+ - job: opensuse-container@x86_64.stable
+ artifacts: false
+ - job: check
+ artifacts: false
+
+build-rsvg-opensuse@x86_64.minimum:
+ extends:
+ - '.container.opensuse@x86_64.minimum'
+ - .fdo.distribution-image@opensuse
+ - .build-rsvg
+ needs:
+ - job: opensuse-container@x86_64.minimum
+ artifacts: false
+ - job: check
+ artifacts: false
+
+build-rsvg-opensuse@x86_64.nightly:
+ extends:
+ - '.container.opensuse@x86_64.nightly'
+ - .fdo.distribution-image@opensuse
+ - .build-rsvg
+ needs:
+ - job: opensuse-container@x86_64.nightly
+ artifacts: false
+ - job: check
+ artifacts: false
+
+.build-rsvg-opensuse@aarch64:
+ extends:
+ - .container.opensuse@aarch64
+ - .fdo.distribution-image@opensuse
+ - .build-rsvg
+ needs:
+ - job: opensuse-container@aarch64
+ artifacts: false
+ - job: check
+ artifacts: false
+
+.build-rsvg-fedora@x86_64:
+ extends:
+ - .container.fedora@x86_64
+ - .fdo.distribution-image@fedora
+ - .build-rsvg
+ needs:
+ - job: fedora-container@x86_64
+ artifacts: false
+ - job: check
+ artifacts: false
+ rules:
+ - if: '$CI_PIPELINE_SOURCE == "push"'
+ when: manual
+ allow_failure: true
+ - if: '$CI_PIPELINE_SOURCE == "schedule"'
+
+.build-rsvg-fedora@aarch64:
+ extends:
+ - .container.fedora@aarch64
+ - .fdo.distribution-image@fedora
+ - .build-rsvg
+ needs:
+ - job: fedora-container@aarch64
+ artifacts: false
+ - job: check
+ artifacts: false
+ rules:
+ - if: '$CI_PIPELINE_SOURCE == "push"'
+ when: manual
+ allow_failure: true
+ - if: '$CI_PIPELINE_SOURCE == "schedule"'
+
+.build-rsvg-debian@x86_64:
+ extends:
+ - '.container.debian@x86_64'
+ - '.fdo.distribution-image@debian'
+ - '.build-rsvg'
+ variables:
+ # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=907306
+ # export GDK_PIXBUF_QUERYLOADERS=/usr/lib/$(dpkg-architecture
-qDEB_HOST_MULTIARCH)/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders
+ GDK_PIXBUF_QUERYLOADERS: '/usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders'
+ LIBRSVG_DEBUG: "no"
+ needs:
+ - job: debian-container@x86_64
+ artifacts: false
+ - job: check
+ artifacts: false
+ rules:
+ - if: '$CI_PIPELINE_SOURCE == "push"'
+ when: manual
+ allow_failure: true
+ - if: '$CI_PIPELINE_SOURCE == "schedule"'
+
+.build-rsvg-debian@aarch64:
+ extends:
+ - '.container.debian@aarch64'
+ - '.fdo.distribution-image@debian'
+ - '.build-rsvg'
+ variables:
+ # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=907306
+ # export GDK_PIXBUF_QUERYLOADERS=/usr/lib/$(dpkg-architecture
-qDEB_HOST_MULTIARCH)/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders
+ GDK_PIXBUF_QUERYLOADERS: '/usr/lib/aarch64-linux-gnu/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders'
+ LIBRSVG_DEBUG: "no"
+ needs:
+ - job: debian-container@aarch64
+ artifacts: false
+ - job: check
+ artifacts: false
+ rules:
+ - if: '$CI_PIPELINE_SOURCE == "push"'
+ when: manual
+ allow_failure: true
+ - if: '$CI_PIPELINE_SOURCE == "schedule"'
+
.cache:
variables:
# Only stuff inside the repo directory can be cached
# Override the CARGO_HOME variable to force its location
CARGO_HOME: "${CI_PROJECT_DIR}/cargo_cache"
before_script:
+ - source ./.gitlab-ci/env.sh
- mkdir -p cargo_cache
cache:
key:
@@ -48,98 +210,93 @@ default:
.cache_push:
extends: .cache
- after_script:
- # Fix up ownership of the cache, not all builds use sudo
- - sudo chown -R "$(id -u):$(id -g)" ${CI_PROJECT_DIR}/cargo_cache
cache:
policy: pull-push
-check:
- stage: check
- extends: '.cache_push'
- needs: []
+fmt:
+ extends:
+ - '.container.opensuse@x86_64.stable'
+ - '.fdo.distribution-image@opensuse'
+ - '.cache'
+ stage: lint
+ needs:
+ - job: check
script:
- - sudo -E cargo check --all-targets
-
-# fmt:
-# stage: lint
-# extends: '.cache'
-# needs:
-# - job: check
-# script:
-# - sudo -E cargo fmt --all -- --check
-
-# clippy:
-# stage: lint
-# extends: '.cache'
-# needs:
-# - job: check
-# script:
-# - cargo clippy --version
-# - gitlab-clippy --version
-# - sudo -E cargo clippy
-# after_script:
-# - sudo -E cargo clippy --message-format=json | /opt/cargo/bin/gitlab-clippy -o
gl-code-quality-report.json
-# artifacts:
-# reports:
-# codequality: gl-code-quality-report.json
-# expire_in: 1 week
-# rules:
-# - if: '$CODE_QUALITY_DISABLED'
-# when: never
-# - if: '$CI_PIPELINE_SOURCE == "push"'
+ - cargo fmt --all -- --check
-cargo_test:
- stage: unit test
+clippy:
extends:
- # Tests require extra crates, hence cache is pushed
- - .cache_push
+ - '.container.opensuse@x86_64.stable'
+ - '.fdo.distribution-image@opensuse'
+ - '.cache'
+ stage: lint
needs:
- job: check
+ script:
+ - cargo clippy --version
+ - gitlab-clippy --version
+ - cargo clippy
+ after_script:
+ - cargo clippy --message-format=json | gitlab-clippy -o gl-code-quality-report.json
artifacts:
- when: 'on_failure'
- paths:
- - _build/tests/output
- expire_in: 1 day
+ reports:
+ codequality: gl-code-quality-report.json
+ expire_in: 1 week
+ rules:
+ - if: '$CODE_QUALITY_DISABLED'
+ when: never
+ - if: '$CI_PIPELINE_SOURCE == "push"'
+
+coverage:
+ extends:
+ - '.container.opensuse@x86_64.nightly'
+ - .fdo.distribution-image@opensuse
+ stage: unit test
+ needs:
+ - job: opensuse-container@x86_64.nightly
+ - job: check
+ artifacts: false
variables:
- OUT_DIR: "${CI_PROJECT_DIR}/tests/output"
+ RUSTFLAGS: "-Zinstrument-coverage"
+ RUSTDOCFLAGS: "-Zinstrument-coverage"
+ LLVM_PROFILE_FILE: "coverage-%p-%m.profraw"
script:
- - sudo -E cargo test -- --skip loading_crash --skip reference --skip render_crash
-
-# coverage:
-# image: "rustlang/rust:nightly-bullseye"
-# stage: unit test
-# needs:
-# - job: check
-# artifacts: false
-# variables:
-# RUSTFLAGS: "-Zinstrument-coverage"
-# RUSTDOCFLAGS: "-Zinstrument-coverage"
-# LLVM_PROFILE_FILE: "coverage-%p-%m.profraw"
-# before_script:
-# - apt update -yqq && apt install -yqq --no-install-recommends libgdk-pixbuf2.0-dev libpango1.0-dev
libcairo2-dev lcov
-# - rustup component add llvm-tools-preview
-# - curl -L https://github.com/mozilla/grcov/releases/latest/download/grcov-linux-x86_64.tar.bz2 | tar
jxf -
-# script:
-# - cargo +nightly test --no-fail-fast || true
-# - ./grcov . --binary-path ./target/debug/ --source-dir . --output-type lcov --llvm
--ignore-not-existing --ignore "*cargo*" --output-path lcov.info
-# - lcov --summary lcov.info
+ - cargo +nightly test --no-fail-fast || true
+ after_script:
+ - source ./.gitlab-ci/env.sh
+ - grcov . --binary-path ./target/debug/ --source-dir . --output-type cobertura --llvm --branch
--ignore-not-existing --ignore "*cargo*" -o coverage.xml
+ - grcov . --binary-path ./target/debug/ --source-dir . --output-type html --llvm --branch
--ignore-not-existing --ignore "build.rs" --output-path ./target/debug/coverage/
+ - mkdir -p public/coverage
+ - cp -r target/debug/coverage/* public/coverage
+ - grep -Eo 'line-rate="[^"]+"' coverage.xml | head -n 1 | grep -Eo '[0-9.]+' | awk '{ print "Coverage:",
$1 * 100 }'
+ coverage: '/Coverage: \d+\.\d+/'
+ artifacts:
+ name: ${CI_JOB_NAME}-${CI_COMMIT_REF_NAME}-${CI_COMMIT_SHA}
+ expire_in: 2 days
+ reports:
+ cobertura: coverage.xml
+ paths:
+ - public
cargo_bench:
+ extends:
+ - '.container.opensuse@x86_64.stable'
+ - '.fdo.distribution-image@opensuse'
+ - '.cache'
stage: unit test
needs:
- job: check
script: |
BENCHES=("box_blur" "composite" "lighting" "path_parser" "pixbuf_from_surface" "pixel_iterators"
"pixel_ops" "srgb" "surface_from_pixbuf")
- sudo -E git checkout ${CI_DEFAULT_BRANCH}
+ git checkout ${CI_DEFAULT_BRANCH}
for BENCH in "${BENCHES[@]}"
do
- sudo -E cargo bench --bench $BENCH -- --noplot --save-baseline main
+ cargo bench --bench $BENCH -- --noplot --save-baseline main
done
- sudo -E git checkout ${CI_COMMIT_SHA}
+ git checkout ${CI_COMMIT_SHA}
for BENCH in "${BENCHES[@]}"
do
- sudo -E cargo bench --bench $BENCH -- --noplot --baseline main
+ cargo bench --bench $BENCH -- --noplot --baseline main
done
rules:
- if: '$CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH != "main"'
@@ -150,64 +307,13 @@ cargo_bench:
- target/criterion
expire_in: 1 week
-.make:
- extends: '.cache'
- needs:
- - job: cargo_test
- script:
- - mkdir -p _build
- - cd _build
- - sudo ../autogen.sh --enable-gtk-doc --enable-vala
- - sudo -E make
- - sudo -E make check
- artifacts:
- when: 'on_failure'
- paths:
- - _build/tests/*.log
- - _build/tests/output
- expire_in: 1 day
- rules:
- - if: '$CI_PIPELINE_SOURCE == "push"'
- when: manual
- allow_failure: true
- - if: '$CI_PIPELINE_SOURCE == "schedule"'
-
-opensuse:tumbleweed:
- stage: acceptance test
- extends:
- - .make
- # make check runs extra tests that require extra crates, hence cache is pushed
- - .cache_push
- rules:
- - if: '$CI_PIPELINE_SOURCE == "push"'
- - if: '$CI_PIPELINE_SOURCE == "schedule"'
-
-.distro:
- stage: cross distro
- extends: .make
- variables:
- LIBRSVG_DEBUG: "no"
-
-fedora:latest:
- image: $AMD64_FEDORA_LATEST
- extends: .distro
-
-debian:testing:
- image: $AMD64_DEBIAN_TESTING
- extends: .distro
- script:
- # TODO: delete after sudo is no longer needed on the other builds
- - mkdir -p _build
- - cd _build
- - ../autogen.sh --enable-gtk-doc --enable-vala
- - make
- - make check
- allow_failure: true
msys2-mingw64:
stage: acceptance test
tags:
- win32-ps
+ needs:
+ - job: check
variables:
MSYSTEM: "MINGW64"
CHERE_INVOKING: "yes"
@@ -220,13 +326,19 @@ msys2-mingw64:
distcheck:
stage: release
- extends: .distro
+ extends:
+ - '.container.opensuse@x86_64.stable'
+ - '.fdo.distribution-image@opensuse'
+ - '.cache'
+ needs:
+ - job: check
variables:
DESTDIR: "/tmp/distcheck"
+ LIBRSVG_DEBUG: "no"
script:
- - sudo ./autogen.sh --enable-gtk-doc --enable-vala
- - sudo -E make
- - sudo -E make distcheck
+ - ./autogen.sh --enable-vala
+ - make
+ - make distcheck
artifacts:
when: 'on_success'
paths:
@@ -238,15 +350,44 @@ distcheck:
allow_failure: true
- if: '$CI_PIPELINE_SOURCE == "schedule"'
+reference:
+ extends:
+ - '.container.opensuse@x86_64.stable'
+ - '.fdo.distribution-image@opensuse'
+ - '.cache'
+ stage: docs
+ needs:
+ - job: opensuse-container@x86_64.stable
+ artifacts: false
+ - job: check
+ artifacts: false
+ script:
+ - mkdir -p _build
+ - cd _build
+ - ../autogen.sh --enable-vala
+ - make
+ - cd ..
+ - mkdir -p public/
+ - mv _build/doc/Rsvg-2.0 public/
+ artifacts:
+ paths:
+ - public
+
pages:
stage: docs
- extends: '.cache'
+ extends:
+ - '.container.opensuse@x86_64.stable'
+ - '.fdo.distribution-image@opensuse'
+ - '.cache'
+ needs:
+ - job: reference
+ - job: coverage
script:
- mkdir -p public/internals
- - sudo -E cargo doc --document-private-items --no-deps
+ - cargo doc --document-private-items --no-deps
- cp -r target/doc/* public/internals
- mkdir -p public/doc
- - sudo -E cargo doc --no-deps --lib
+ - cargo doc --no-deps --lib
- cp -r target/doc/* public/doc
artifacts:
paths:
diff --git a/.gitlab-ci/container_builds.yml b/.gitlab-ci/container_builds.yml
new file mode 100644
index 000000000..8e485635a
--- /dev/null
+++ b/.gitlab-ci/container_builds.yml
@@ -0,0 +1,175 @@
+include:
+ - remote:
"https://gitlab.freedesktop.org/freedesktop/ci-templates/-/raw/80f87b3058efb75a1faae11826211375fba77e7f/templates/fedora.yml"
+ - remote:
"https://gitlab.freedesktop.org/freedesktop/ci-templates/-/raw/80f87b3058efb75a1faae11826211375fba77e7f/templates/debian.yml"
+ - remote:
"https://gitlab.freedesktop.org/freedesktop/ci-templates/-/raw/80f87b3058efb75a1faae11826211375fba77e7f/templates/opensuse.yml"
+
+variables:
+ # When branching change the suffix to avoid conflicts with images
+ # from the main branch
+ BASE_TAG: "2022-01-24.0-main"
+ RUST_STABLE: "1.58.0"
+ RUST_MINIMUM: "1.56.1"
+
+.container.opensuse@common:
+ stage: "container-build"
+ before_script:
+ - source ./.gitlab-ci/env.sh
+ variables:
+ FDO_DISTRIBUTION_VERSION: "tumbleweed"
+ FDO_UPSTREAM_REPO: "gnome/librsvg"
+ FDO_DISTRIBUTION_PACKAGES: >-
+ gcc gdb make vala
+ automake autoconf curl gettext git itstool libtool
+ gtk-doc gobject-introspection-devel gtk3-devel
+ cairo-devel libxml2-devel wget openssl-devel
+ pango-devel gdk-pixbuf-devel ccache gettext-tools
+ sudo shadow system-group-wheel xz python38-docutils python3-pip
+
+.container.opensuse@x86_64.stable:
+ extends: .container.opensuse@common
+ variables:
+ FDO_DISTRIBUTION_TAG: "x86_64-${RUST_STABLE}-${BASE_TAG}"
+ FDO_DISTRIBUTION_EXEC: >-
+ bash .gitlab-ci/install-rust.sh ${RUST_STABLE} x86_64-unknown-linux-gnu &&
+ pip3 install gi-docgen
+
+.container.opensuse@x86_64.minimum:
+ extends: .container.opensuse@common
+ variables:
+ FDO_DISTRIBUTION_TAG: "x86_64-${RUST_MINIMUM}-${BASE_TAG}"
+ FDO_DISTRIBUTION_EXEC: >-
+ bash .gitlab-ci/install-rust.sh ${RUST_MINIMUM} x86_64-unknown-linux-gnu &&
+ pip3 install gi-docgen
+
+.container.opensuse@x86_64.nightly:
+ extends: .container.opensuse@common
+ variables:
+ FDO_DISTRIBUTION_TAG: "x86_64-nightly-${BASE_TAG}"
+ FDO_DISTRIBUTION_EXEC: >-
+ bash .gitlab-ci/install-rust.sh nightly x86_64-unknown-linux-gnu &&
+ pip3 install gi-docgen
+
+.container.opensuse@aarch64:
+ extends: .container.opensuse@common
+ variables:
+ FDO_DISTRIBUTION_TAG: "aarch64-${RUST_STABLE}-${BASE_TAG}"
+ FDO_DISTRIBUTION_EXEC: >-
+ bash .gitlab-ci/install-rust.sh ${RUST_STABLE} aarch64-unknown-linux-gnu &&
+ pip3 install gi-docgen
+ tags:
+ - aarch64
+
+opensuse-container@x86_64.stable:
+ extends:
+ - .fdo.container-build@opensuse@x86_64
+ - .container.opensuse@x86_64.stable
+ stage: "container-build"
+
+opensuse-container@x86_64.minimum:
+ extends:
+ - .fdo.container-build@opensuse@x86_64
+ - .container.opensuse@x86_64.minimum
+ stage: "container-build"
+
+opensuse-container@x86_64.nightly:
+ extends:
+ - .fdo.container-build@opensuse@x86_64
+ - .container.opensuse@x86_64.nightly
+ stage: "container-build"
+
+.opensuse-container@aarch64:
+ extends:
+ - .fdo.container-build@opensuse@aarch64
+ - .container.opensuse@aarch64
+ stage: "container-build"
+
+.container.fedora@common:
+ before_script:
+ - source ./.gitlab-ci/env.sh
+ variables:
+ FDO_DISTRIBUTION_VERSION: "34"
+ FDO_UPSTREAM_REPO: "gnome/librsvg"
+ FDO_DISTRIBUTION_PACKAGES: >-
+ gcc make vala curl
+ automake autoconf libtool gettext itstool
+ gdk-pixbuf2-devel gobject-introspection-devel
+ gtk-doc git redhat-rpm-config gtk3-devel ccache
+ libxml2-devel cairo-devel pango-devel wget openssl-devel
+ gettext-devel python3-docutils python3-pip
+
+.container.fedora@x86_64:
+ extends: .container.fedora@common
+ variables:
+ FDO_DISTRIBUTION_TAG: "x86_64-${RUST_STABLE}-${BASE_TAG}"
+ FDO_DISTRIBUTION_EXEC: >-
+ bash .gitlab-ci/install-rust.sh ${RUST_STABLE} x86_64-unknown-linux-gnu &&
+ pip3 install gi-docgen
+
+.container.fedora@aarch64:
+ extends: .container.fedora@common
+ variables:
+ FDO_DISTRIBUTION_TAG: "aarch64-${RUST_STABLE}-${BASE_TAG}"
+ FDO_DISTRIBUTION_EXEC: >-
+ bash .gitlab-ci/install-rust.sh ${RUST_STABLE} aarch64-unknown-linux-gnu &&
+ pip3 install gi-docgen
+ tags:
+ - aarch64
+
+.fedora-container@x86_64:
+ extends:
+ - .fdo.container-build@fedora@x86_64
+ - .container.fedora@x86_64
+ stage: "container-build"
+
+.fedora-container@aarch64:
+ extends:
+ - .fdo.container-build@fedora@aarch64
+ - .container.fedora@aarch64
+ stage: "container-build"
+
+.container.debian@common:
+ extends:
+ - .fdo.container-build@debian@x86_64
+ before_script:
+ - source ./.gitlab-ci/env.sh
+ variables:
+ FDO_DISTRIBUTION_VERSION: "testing"
+ FDO_UPSTREAM_REPO: "gnome/librsvg"
+ FDO_DISTRIBUTION_PACKAGES: >-
+ curl gcc make valac git wget
+ automake autoconf libtool gettext itstool
+ libgdk-pixbuf2.0-dev libgirepository1.0-dev
+ gtk-doc-tools libpango1.0-dev libgtk-3-dev
+ libxml2-dev libcairo2-dev python3-docutils
+ ca-certificates openssl libssl-dev python3-pip
+ autotools-dev libltdl-dev autopoint
+
+.container.debian@x86_64:
+ extends: .container.debian@common
+ variables:
+ FDO_DISTRIBUTION_TAG: "x86_64-${RUST_STABLE}-${BASE_TAG}"
+ FDO_DISTRIBUTION_EXEC: >-
+ bash .gitlab-ci/install-rust.sh ${RUST_STABLE} x86_64-unknown-linux-gnu &&
+ pip3 install gi-docgen
+
+.container.debian@aarch64:
+ extends: .container.debian@common
+ variables:
+ FDO_DISTRIBUTION_TAG: "aarch64-${RUST_STABLE}-${BASE_TAG}"
+ FDO_DISTRIBUTION_EXEC: >-
+ bash .gitlab-ci/install-rust.sh ${RUST_STABLE} aarch64-unknown-linux-gnu &&
+ pip3 install gi-docgen
+ tags:
+ - aarch64
+
+.debian-container@x86_64:
+ extends:
+ - .fdo.container-build@debian@x86_64
+ - .container.debian@x86_64
+ stage: "container-build"
+
+.debian-container@aarch64:
+ extends:
+ - .fdo.container-build@debian@aarch64
+ - .container.debian@aarch64
+ stage: "container-build"
diff --git a/.gitlab-ci/env.sh b/.gitlab-ci/env.sh
new file mode 100644
index 000000000..6f47f12e4
--- /dev/null
+++ b/.gitlab-ci/env.sh
@@ -0,0 +1,2 @@
+export RUSTUP_HOME='/usr/local/rustup'
+export PATH=$PATH:/usr/local/cargo/bin
\ No newline at end of file
diff --git a/.gitlab-ci/install-rust.sh b/.gitlab-ci/install-rust.sh
new file mode 100755
index 000000000..9bd9e1750
--- /dev/null
+++ b/.gitlab-ci/install-rust.sh
@@ -0,0 +1,36 @@
+source ./.gitlab-ci/env.sh
+
+set -eu
+export CARGO_HOME='/usr/local/cargo'
+
+RUSTUP_VERSION=1.24.3
+RUST_VERSION=$1
+RUST_ARCH=$2
+
+RUSTUP_URL=https://static.rust-lang.org/rustup/archive/$RUSTUP_VERSION/$RUST_ARCH/rustup-init
+wget $RUSTUP_URL
+
+chmod +x rustup-init;
+./rustup-init -y --no-modify-path --profile minimal --default-toolchain $RUST_VERSION;
+rm rustup-init;
+chmod -R a+w $RUSTUP_HOME $CARGO_HOME
+
+rustup --version
+cargo --version
+rustc --version
+
+rustup component add clippy-preview
+rustup component add rustfmt
+cargo install --force cargo-c
+cargo install --version ^1.0 gitlab_clippy
+# cargo install --force cargo-deny
+# cargo install --force cargo-outdated
+
+if [ "$RUST_VERSION" = "nightly" ]; then
+ # Coverage tools
+ cargo install grcov
+ rustup component add llvm-tools-preview
+
+ # Documentation tools
+ cargo install --force rustdoc-stripper
+fi
\ No newline at end of file
diff --git a/.gitlab-ci/test-msys2.sh b/.gitlab-ci/test-msys2.sh
index 6fa64a56d..5c92ec975 100644
--- a/.gitlab-ci/test-msys2.sh
+++ b/.gitlab-ci/test-msys2.sh
@@ -13,6 +13,7 @@ pacman --noconfirm -Suy
pacman --noconfirm -S --needed \
base-devel \
mingw-w64-$MSYS2_ARCH-gtk-doc \
+ mingw-w64-$MSYS2_ARCH-gi-docgen \
mingw-w64-$MSYS2_ARCH-gobject-introspection \
mingw-w64-$MSYS2_ARCH-gdk-pixbuf2 \
mingw-w64-$MSYS2_ARCH-harfbuzz \
@@ -21,6 +22,7 @@ pacman --noconfirm -S --needed \
mingw-w64-$MSYS2_ARCH-libthai \
mingw-w64-$MSYS2_ARCH-cairo \
mingw-w64-$MSYS2_ARCH-pango \
+ mingw-w64-$MSYS2_ARCH-python-docutils \
mingw-w64-$MSYS2_ARCH-libxml2 \
mingw-w64-$MSYS2_ARCH-toolchain \
mingw-w64-$MSYS2_ARCH-rust \
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]