69d11ca
# Tests works with enabled network. Also possible to run tests in COPR:
69d11ca
# https://download.copr.fedorainfracloud.org/results/atim/buildstream/fedora-35-x86_64/02660103-buildstream/builder-live.log.gz
077c0f4
%bcond_without test
69d11ca
dd9ff5d
Name:          buildstream
dd9ff5d
Summary:       Build/integrate software stacks
dd9ff5d
License:       LGPLv2+
07cf2fc
URL:           https://buildstream.build/
dd9ff5d
08d4990
Version:       1.6.7
ddb0ef0
Release:       %autorelease
dd4ab34
Source0:       https://github.com/apache/buildstream/archive/%{version}/buildstream-%{version}.tar.gz
dd9ff5d
a71704a
BuildRequires: bubblewrap >= 0.1.2
69d11ca
BuildRequires: make
a71704a
BuildRequires: python3-devel >= 3.5
dd9ff5d
BuildRequires: python3-pytest-runner
dd9ff5d
BuildRequires: python3-sphinx
5f979fd
BuildRequires: python3-sphinx_rtd_theme
69d11ca
BuildRequires: python3-sphinx-click
dd9ff5d
69d11ca
# These from plugin-requirements.in + requirements.in
dd9ff5d
BuildRequires: fuse-libs
dd9ff5d
BuildRequires: ostree-libs
dd9ff5d
BuildRequires: python3-arpy
dd9ff5d
BuildRequires: python3-click
dd9ff5d
BuildRequires: python3-gobject
69d11ca
BuildRequires: python3-grpcio >= 1.30
dd9ff5d
BuildRequires: python3-jinja2 >= 2.10
dd9ff5d
BuildRequires: python3-pluginbase
16495ef
BuildRequires: python3-protobuf >= 3.19
dd9ff5d
BuildRequires: python3-psutil
08d4990
BuildRequires: python3-ruamel-yaml >= 0.16
69d11ca
BuildRequires: python3-setuptools
189a02e
BuildRequires: python3-ujson
dd9ff5d
69d11ca
%if %{with test}
077c0f4
BuildRequires: zip
077c0f4
BuildRequires: tar
077c0f4
BuildRequires: lzip
077c0f4
BuildRequires: git-core
077c0f4
BuildRequires: bzr
077c0f4
BuildRequires: ostree
077c0f4
BuildRequires: python3-pip
077c0f4
# These from dev-requirements.in
69d11ca
BuildRequires: python3-pytest >= 3.7
69d11ca
BuildRequires: python3-pytest-datafiles
69d11ca
BuildRequires: python3-pytest-env
077c0f4
BuildRequires: python3-pytest-timeout
077c0f4
BuildRequires: python3-pytest-xdist
077c0f4
# Not available: pyftpdlib (we skip the associated tests)
69d11ca
077c0f4
# We do not need linters (nor omitted coverage from cov-requirements.in); see:
077c0f4
# https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_linters
077c0f4
#
077c0f4
# BuildRequires: python3-pep8
077c0f4
# BuildRequires: python3-pylint >= 2.10
077c0f4
%endif
69d11ca
69d11ca
Requires:      bubblewrap >= 0.1.2
a68bb50
Requires:      fuse
dd9ff5d
Requires:      fuse-libs
fe7ea62
Requires:      git
fe7ea62
Requires:      lzip
dd9ff5d
Requires:      ostree-libs
fe7ea62
Requires:      patch
dd9ff5d
Requires:      python3-arpy
dd9ff5d
Requires:      python3-click
dd9ff5d
Requires:      python3-gobject
69d11ca
Requires:      python3-grpcio >= 1.30
dd9ff5d
Requires:      python3-jinja2 >= 2.10
dd9ff5d
Requires:      python3-pluginbase
69d11ca
Requires:      python3-protobuf >= 3.6
dd9ff5d
Requires:      python3-psutil
08d4990
Requires:      python3-ruamel-yaml >= 0.16
dd9ff5d
Requires:      python3-setuptools
189a02e
Requires:      python3-ujson
fe7ea62
Requires:      tar
dd9ff5d
dd9ff5d
BuildArch:     noarch
dd9ff5d
dd9ff5d
%description
dd9ff5d
BuildStream is a Free Software tool for building/integrating software stacks.
dd9ff5d
It takes inspiration, lessons and use-cases from various projects including
dd9ff5d
OBS, Reproducible Builds, Yocto, Baserock, Buildroot, Aboriginal, GNOME
dd9ff5d
Continuous, JHBuild, Flatpak Builder and Android repo.
dd9ff5d
dd9ff5d
BuildStream supports multiple build-systems (e.g. autotools, cmake, cpan,
dd9ff5d
distutils, make, meson, qmake), and can create outputs in a range of formats
dd9ff5d
(e.g. debian packages, flatpak runtimes, sysroots, system images) for multiple
dd9ff5d
platforms and chipsets.
dd9ff5d
dd9ff5d
07cf2fc
%package       docs
dd9ff5d
Summary:       BuildStream documentation
dd9ff5d
07cf2fc
%description   docs
dd9ff5d
BuildStream is a Free Software tool for building/integrating software stacks.
dd9ff5d
It takes inspiration, lessons and use-cases from various projects including
dd9ff5d
OBS, Reproducible Builds, Yocto, Baserock, Buildroot, Aboriginal, GNOME
dd9ff5d
Continuous, JHBuild, Flatpak Builder and Android repo.
dd9ff5d
dd9ff5d
BuildStream supports multiple build-systems (e.g. autotools, cmake, cpan,
dd9ff5d
distutils, make, meson, qmake), and can create outputs in a range of formats
dd9ff5d
(e.g. debian packages, flatpak runtimes, sysroots, system images) for multiple
dd9ff5d
platforms and chipsets.
dd9ff5d
dd9ff5d
This package provides the documentation for BuildStream.
dd9ff5d
dd9ff5d
dd9ff5d
%prep
dd9ff5d
%autosetup -n %{name}-%{version} -p1
dd9ff5d
dd9ff5d
dd9ff5d
%build
6a05666
%py3_build
dd9ff5d
dd9ff5d
pushd doc
dd9ff5d
make devhelp
dd9ff5d
popd
dd9ff5d
dd9ff5d
dd9ff5d
%install
6a05666
%py3_install
dd9ff5d
dd9ff5d
mkdir -p %{buildroot}%{_datadir}/gtk-doc/html/
dd9ff5d
cp -pr doc/build/devhelp %{buildroot}%{_datadir}/gtk-doc/html/BuildStream
dd9ff5d
dd9ff5d
69d11ca
%if %{with test}
dd9ff5d
%check
8a9a56b
# The following fail in koji but not in a local mock build; this seems to have
8a9a56b
# something to do with sandboxing.
8a9a56b
k="${k-}${k+ and }not test_push_pull"
8a9a56b
k="${k-}${k+ and }not test_push_pull_all"
8a9a56b
k="${k-}${k+ and }not test_pull_secondary_cache"
8a9a56b
k="${k-}${k+ and }not test_push_pull_specific_remote"
8a9a56b
k="${k-}${k+ and }not test_push_pull_non_strict"
8a9a56b
k="${k-}${k+ and }not test_push_pull_track_non_strict"
8a9a56b
k="${k-}${k+ and }not test_push_pull_cross_junction"
8a9a56b
k="${k-}${k+ and }not test_pull_missing_blob"
8a9a56b
k="${k-}${k+ and }not test_pull_access_rights"
8a9a56b
k="${k-}${k+ and }not test_push"
8a9a56b
k="${k-}${k+ and }not test_push_all"
8a9a56b
k="${k-}${k+ and }not test_push_after_pull"
8a9a56b
k="${k-}${k+ and }not test_artifact_expires"
8a9a56b
k="${k-}${k+ and }not test_artifact_too_large"
8a9a56b
k="${k-}${k+ and }not test_recently_pulled_artifact_does_not_expire"
8a9a56b
k="${k-}${k+ and }not test_push_cross_junction"
8a9a56b
k="${k-}${k+ and }not test_push_already_cached"
8a9a56b
# This test expects 'arch' to be 'x86_64' or 'x86_32', so it fails when the
8a9a56b
# builder is anything but x86_64. Even 32-bit x86 fails, as 'arch' is 'i686'.
8a9a56b
# Since the package is noarch, we just skip it unconditionally.
8a9a56b
k="${k-}${k+ and }not test_project_error"
077c0f4
# Ignored tests would require pyftpdlib, which is not packaged
8a9a56b
%pytest -vv -k "${k-}" \
077c0f4
    --ignore=tests/testutils/file_server.py \
077c0f4
    --ignore=tests/testutils/ftp_server.py \
077c0f4
    --ignore=tests/sources/remote.py \
077c0f4
    --ignore=tests/sources/tar.py \
08d4990
    --ignore=tests/sources/zip.py \
c769ffe
    %dnl # Some tests fail probably due new Python 3.11
08d4990
    %if 0%{?fedora} >= 36
08d4990
    --ignore=tests/frontend/compose_splits.py \
08d4990
    --ignore=tests/frontend/overlaps.py \
08d4990
    --ignore=tests/plugins/filter.py \
08d4990
    --ignore=tests/sources/deb.py \
08d4990
    --ignore=tests/sources/pip.py \
08d4990
    %else
08d4990
    %endif
69d11ca
%endif
dd9ff5d
dd9ff5d
dd9ff5d
%files
dd9ff5d
%doc NEWS README.rst
dd9ff5d
%license COPYING
dd9ff5d
%{_bindir}/bst*
dd9ff5d
%{python3_sitelib}/BuildStream-%{version}*.egg-info
69d11ca
%{python3_sitelib}/%{name}/
dd9ff5d
%{_datadir}/bash-completion/completions/bst
69d11ca
%{_mandir}/man1/*.1*
dd9ff5d
dd9ff5d
%files docs
dd9ff5d
%{_datadir}/gtk-doc
dd9ff5d
dd9ff5d
dd9ff5d
%changelog
ddb0ef0
%autochangelog