Accepting request 925702 from home:bnavigator:branches:devel:languages:python
- Update to v0.7.0 Full changelog at https://pypa-build.readthedocs.io/en/stable/changelog.html * Dropped support for Python 2 and 3.5 - Avoid possible bootstrap build depcycles with _multibuild - Drop remove-unused-import.patch OBS-URL: https://build.opensuse.org/request/show/925702 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-build?expand=0&rev=5
This commit is contained in:
parent
646c68d5a9
commit
65e3a5efb5
3
_multibuild
Normal file
3
_multibuild
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<multibuild>
|
||||||
|
<package>test</package>
|
||||||
|
</multibuild>
|
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:caec66a086a3fdad0c03b36ea82598c071b5c1a98c20d499ef9ae81540ff2463
|
|
||||||
size 21837
|
|
3
build-0.7.0.tar.gz
Normal file
3
build-0.7.0.tar.gz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:1f1a52767a0b92b37e53eb1fa6017b3d08fddf99e3341a37d2535bc03177b243
|
||||||
|
size 37127
|
@ -1,3 +1,13 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Sat Oct 16 12:24:15 UTC 2021 - Ben Greiner <code@bnavigator.de>
|
||||||
|
|
||||||
|
- Update to v0.7.0
|
||||||
|
Full changelog at
|
||||||
|
https://pypa-build.readthedocs.io/en/stable/changelog.html
|
||||||
|
* Dropped support for Python 2 and 3.5
|
||||||
|
- Avoid possible bootstrap build depcycles with _multibuild
|
||||||
|
- Drop remove-unused-import.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu Dec 17 14:52:54 UTC 2020 - Benjamin Greiner <code@bnavigator.de>
|
Thu Dec 17 14:52:54 UTC 2020 - Benjamin Greiner <code@bnavigator.de>
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package python-build
|
# spec file
|
||||||
#
|
#
|
||||||
# Copyright (c) 2020 SUSE LLC
|
# Copyright (c) 2021 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -16,52 +16,54 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%global flavor @BUILD_FLAVOR@%{nil}
|
||||||
# TW defined --without python2
|
%if "%{flavor}" == "test"
|
||||||
%bcond_without python2
|
%define psuffix -test
|
||||||
Name: python-build
|
%bcond_without test
|
||||||
Version: 0.1.0
|
%else
|
||||||
|
%define psuffix %{nil}
|
||||||
|
%bcond_with test
|
||||||
|
%endif
|
||||||
|
%{?!python_module:%define python_module() python3-%{**}}
|
||||||
|
%define skip_python2 1
|
||||||
|
Name: python-build%{psuffix}
|
||||||
|
Version: 0.7.0
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: Simple PEP517 package builder
|
Summary: Simple PEP517 package builder
|
||||||
License: MIT
|
License: MIT
|
||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
URL: https://github.com/pypa/build
|
URL: https://github.com/pypa/build
|
||||||
Source: https://github.com/pypa/build/archive/%{version}.tar.gz#/build-%{version}.tar.gz
|
Source0: https://github.com/pypa/build/archive/%{version}.tar.gz#/build-%{version}.tar.gz
|
||||||
# PATCH-FIX-UPSTREAM remove-unused-import.patch -- remove unused import https://github.com/pypa/build/commit/efa3710
|
BuildRequires: %{python_module importlib-metadata >= 0.22 if %python-base < 3.8}
|
||||||
Patch0: remove-unused-import.patch
|
BuildRequires: %{python_module packaging >= 19.0}
|
||||||
BuildRequires: %{python_module packaging}
|
BuildRequires: %{python_module pep517 >= 0.9.1}
|
||||||
BuildRequires: %{python_module pep517 >= 0.9}
|
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: %{python_module toml}
|
BuildRequires: %{python_module tomli >= 1.0.0}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
%if %{with python2}
|
Requires: python-packaging >= 0.19.0
|
||||||
BuildRequires: python-typing
|
Requires: python-pep517 >= 0.9.1
|
||||||
BuildRequires: python-virtualenv >= 20.0.35
|
Requires: python-tomli
|
||||||
%endif
|
Requires: (python-importlib-metadata >= 0.22 if python-base < 3.8)
|
||||||
BuildRequires: (python3-importlib_metadata if python3-base < 3.8)
|
Recommends: python-virtualenv >= 20.0.35
|
||||||
BuildRequires: (python36-importlib_metadata if python36-base)
|
|
||||||
Requires: python-packaging
|
|
||||||
Requires: python-pep517 >= 0.9
|
|
||||||
Requires: python-toml
|
|
||||||
Requires: (python-importlib_metadata if python-base < 3.8)
|
|
||||||
%ifpython2
|
|
||||||
Requires: python-typing
|
|
||||||
Requires: python-virtualenv >= 20.0.35
|
|
||||||
%endif
|
|
||||||
Requires(post): update-alternatives
|
Requires(post): update-alternatives
|
||||||
Requires(postun): update-alternatives
|
Requires(postun):update-alternatives
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
# SECTION test requirements
|
%if %{with test}
|
||||||
BuildRequires: %{python_module filelock}
|
BuildRequires: %{python_module build = %{version}}
|
||||||
BuildRequires: %{python_module pytest-mock}
|
BuildRequires: %{python_module filelock >= 3}
|
||||||
BuildRequires: %{python_module pytest-xdist}
|
BuildRequires: %{python_module pytest-mock >= 2}
|
||||||
|
BuildRequires: %{python_module pytest-rerunfailures >= 9.1}
|
||||||
|
BuildRequires: %{python_module pytest-xdist >= 1.34}
|
||||||
BuildRequires: %{python_module pytest}
|
BuildRequires: %{python_module pytest}
|
||||||
# /SECTION
|
BuildRequires: %{python_module toml >= 0.10.0}
|
||||||
|
BuildRequires: %{python_module wheel >= 0.36}
|
||||||
|
%endif
|
||||||
%python_subpackages
|
%python_subpackages
|
||||||
|
|
||||||
%description
|
%description
|
||||||
Simple PEP517 package builder.
|
Build will invoke the PEP 517 hooks to build a distribution package.
|
||||||
|
It is a simple build tool and does not perform any dependency management.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%autosetup -p1 -n build-%{version}
|
%autosetup -p1 -n build-%{version}
|
||||||
@ -69,15 +71,25 @@ Simple PEP517 package builder.
|
|||||||
%build
|
%build
|
||||||
%python_build
|
%python_build
|
||||||
|
|
||||||
|
%if !%{with test}
|
||||||
%install
|
%install
|
||||||
%python_install
|
%python_install
|
||||||
%python_clone -a %{buildroot}%{_bindir}/pyproject-build
|
%python_clone -a %{buildroot}%{_bindir}/pyproject-build
|
||||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%if %{with test}
|
||||||
%check
|
%check
|
||||||
# test_create_isolated_build_host (x2) fail due to venv/test rig
|
# obs can't download packages into "isolated" envs
|
||||||
%pytest -k 'not (test_create_isolated_build_host_with_no_pip or test_create_isolated_build_has_with_pip)'
|
donttest="test_build_package"
|
||||||
|
donttest+=" or (test_wheel_metadata and True)"
|
||||||
|
donttest+=" or test_with_get_requires"
|
||||||
|
donttest+=" or test_wheel_metadata_isolation"
|
||||||
|
donttest+=" or test_output and (via-sdist-isolation or wheel-direct-isolation)"
|
||||||
|
%pytest tests -n auto -k "not ($donttest)"
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%if !%{with test}
|
||||||
%post
|
%post
|
||||||
%python_install_alternative pyproject-build
|
%python_install_alternative pyproject-build
|
||||||
|
|
||||||
@ -88,6 +100,8 @@ Simple PEP517 package builder.
|
|||||||
%doc README.md
|
%doc README.md
|
||||||
%license LICENSE
|
%license LICENSE
|
||||||
%python_alternative %{_bindir}/pyproject-build
|
%python_alternative %{_bindir}/pyproject-build
|
||||||
%{python_sitelib}/*
|
%{python_sitelib}/build
|
||||||
|
%{python_sitelib}/build-%{version}*-info
|
||||||
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
@ -1,20 +0,0 @@
|
|||||||
Index: build-0.1.0/tests/test_projectbuilder.py
|
|
||||||
===================================================================
|
|
||||||
--- build-0.1.0.orig/tests/test_projectbuilder.py
|
|
||||||
+++ build-0.1.0/tests/test_projectbuilder.py
|
|
||||||
@@ -13,15 +13,10 @@ import pytest
|
|
||||||
import build
|
|
||||||
|
|
||||||
if sys.version_info >= (3, 8): # pragma: no cover
|
|
||||||
- import email
|
|
||||||
from importlib import metadata as importlib_metadata
|
|
||||||
-
|
|
||||||
- email_message_from_string = email.message_from_string
|
|
||||||
else: # pragma: no cover
|
|
||||||
import importlib_metadata
|
|
||||||
|
|
||||||
- email_message_from_string = importlib_metadata._compat.email_message_from_string
|
|
||||||
-
|
|
||||||
if sys.version_info >= (3,): # pragma: no cover
|
|
||||||
build_open_owner = 'builtins'
|
|
||||||
else: # pragma: no cover
|
|
Loading…
Reference in New Issue
Block a user