mirror of
https://gitlab.com/libvirt/libvirt-python.git
synced 2024-10-26 07:55:06 +03:00
ee54658eb5
There a lot happening here, but that's because otherwise lcitool fails to regenerate files. Firstly, CentOS 8 is dropped as it's unsupported now. Secondly, Fedora 40 is introduced and Fedora 38 is dropped. And lastly, Ubuntu 24.04 is introduced and Ubuntu 20.04 is dropped. Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
76 lines
2.3 KiB
YAML
76 lines
2.3 KiB
YAML
|
|
stages:
|
|
- containers
|
|
- builds
|
|
- sanity_checks
|
|
|
|
.git_build_vars: &git_build_vars |
|
|
export MAKEFLAGS="-j$(getconf _NPROCESSORS_ONLN)"
|
|
export SCRATCH_DIR="$PWD/scratch"
|
|
export VROOT="$SCRATCH_DIR/vroot"
|
|
export LIBDIR="$VROOT/lib"
|
|
export LD_LIBRARY_PATH="$LIBDIR"
|
|
export PATH="$VROOT/bin:$PATH"
|
|
export PKG_CONFIG_PATH="$LIBDIR/pkgconfig"
|
|
export CFLAGS="-Werror"
|
|
|
|
.native_git_build_job:
|
|
extends:
|
|
- .gitlab_native_build_job
|
|
script:
|
|
- *git_build_vars
|
|
- pushd "$PWD"
|
|
- mkdir -p "$SCRATCH_DIR"
|
|
- cd "$SCRATCH_DIR"
|
|
- git clone --depth 1 https://gitlab.com/libvirt/libvirt.git
|
|
- cd libvirt
|
|
- meson build -Ddriver_libvirtd=disabled "--prefix=$VROOT" "--libdir=$LIBDIR"
|
|
- ninja -C build install
|
|
- popd
|
|
- $PYTHON -m build -n -x
|
|
- $PYTHON -m venv test-venv --system-site-packages --symlinks
|
|
- test-venv/bin/python -m pip install dist/libvirt_python*.whl
|
|
- test-venv/bin/python -m pytest tests
|
|
- if test -x /usr/bin/rpmbuild && test "$RPM" != "skip" ;
|
|
then
|
|
unset CFLAGS ;
|
|
rpmbuild --clean --nodeps --define "_topdir $PWD/rpmbuild" -ta dist/libvirt-python*tar.gz ;
|
|
mv rpmbuild/RPMS/x86_64/ libvirt-python-rpms ;
|
|
fi
|
|
|
|
.native_build_job:
|
|
extends:
|
|
- .gitlab_native_build_job
|
|
script:
|
|
- export MAKEFLAGS="-j$(getconf _NPROCESSORS_ONLN)"
|
|
- export CFLAGS="-Werror"
|
|
- $PYTHON -m build -n -x
|
|
- $PYTHON -m venv test-venv --system-site-packages --symlinks
|
|
- test-venv/bin/python -m pip install dist/libvirt_python*.whl
|
|
- test-venv/bin/python -m pytest tests
|
|
- if test -x /usr/bin/rpmbuild && test "$RPM" != "skip" ;
|
|
then
|
|
unset CFLAGS ;
|
|
rpmbuild --clean --nodeps --define "_topdir $PWD/rpmbuild" -ta dist/libvirt-python*tar.gz ;
|
|
mv rpmbuild/RPMS/x86_64/ libvirt-python-rpms ;
|
|
fi
|
|
|
|
include: '/ci/gitlab.yml'
|
|
|
|
api_coverage_job:
|
|
extends:
|
|
- .gitlab_native_build_job
|
|
needs:
|
|
- job: x86_64-centos-stream-9-git
|
|
artifacts: true
|
|
stage: sanity_checks
|
|
script:
|
|
- *git_build_vars
|
|
- $PYTHON -m venv test-venv --system-site-packages --symlinks
|
|
- test-venv/bin/python -m pip install dist/libvirt_python*.whl
|
|
- LIBVIRT_API_COVERAGE=1 test-venv/bin/python -m pytest tests
|
|
allow_failure: true
|
|
variables:
|
|
NAME: centos-stream-9
|
|
TARGET_BASE_IMAGE: quay.io/centos/centos:stream9
|