python-packaging-vl.spec 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. %bcond_with test
  2. %global pypi_name packaging
  3. #global build_wheel 1
  4. %global with_python3 1
  5. Summary: Core utilities for Python packages
  6. Name: python-%{pypi_name}
  7. Version: 20.4
  8. Release: 1%{?_dist_release}
  9. Group: programming
  10. Vendor: Project Vine
  11. Distribution: Vine Linux
  12. License: BSD or ASL 2.0
  13. URL: https://github.com/pypa/packaging
  14. Source0: https://files.pythonhosted.org/packages/source/p/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
  15. BuildArch: noarch
  16. # Dependencies with different names in Fedora and Epel7
  17. BuildRequires: python-rpm-macros
  18. BuildRequires: python2-rpm-macros
  19. BuildRequires: python-setuptools
  20. BuildRequires: python-devel
  21. BuildRequires: python-pyparsing
  22. BuildRequires: python-six
  23. %if %{with test}
  24. BuildRequires: python-pytest
  25. BuildRequires: python-pretend
  26. %endif
  27. # Build Python 3 subpackage only for Fedora
  28. %if 0%{?with_python3}
  29. BuildRequires: python3-rpm-macros
  30. BuildRequires: python3-setuptools
  31. BuildRequires: python3-devel
  32. BuildRequires: python3-pyparsing
  33. BuildRequires: python3-six
  34. %if %{with test}
  35. BuildRequires: python3-pytest
  36. BuildRequires: python3-pretend
  37. %endif
  38. %endif
  39. Requires: python-pyparsing
  40. Requires: python-six
  41. %{?python_provide:%python_provide python2-%{pypi_name}}
  42. %description
  43. python-packaging provides core utilities for Python packages like utilities for
  44. dealing with versions, specifiers, markers etc.
  45. %if 0%{?with_python3}
  46. %package -n python3-%{pypi_name}
  47. Summary: %{summary}
  48. %{?python_provide:%python_provide python3-%{pypi_name}}
  49. Requires: python3-pyparsing
  50. Requires: python3-six
  51. %description -n python3-%{pypi_name}
  52. python3-packaging provides core utilities for Python packages like utilities for
  53. dealing with versions, specifiers, markers etc.
  54. %endif
  55. %prep
  56. %autosetup -n %{pypi_name}-%{version}
  57. # Remove bundled egg-info
  58. rm -rf %{pypi_name}.egg-info
  59. %build
  60. %py2_build
  61. %if 0%{?with_python3}
  62. %py3_build
  63. %endif
  64. %install
  65. %py2_install
  66. %if 0%{?with_python3}
  67. %py3_install
  68. %endif
  69. %check
  70. %if %{with test}
  71. %{__python2} -m pytest tests/
  72. %{__python3} -m pytest tests/
  73. %endif
  74. %files
  75. %license LICENSE LICENSE.APACHE LICENSE.BSD
  76. %doc README.rst CHANGELOG.rst CONTRIBUTING.rst
  77. %{python2_sitelib}/%{pypi_name}/
  78. %{python2_sitelib}/%{pypi_name}-*-info/
  79. %if 0%{?with_python3}
  80. %files -n python3-%{pypi_name}
  81. %license LICENSE LICENSE.APACHE LICENSE.BSD
  82. %doc README.rst CHANGELOG.rst CONTRIBUTING.rst
  83. %{python3_sitelib}/%{pypi_name}/
  84. %{python3_sitelib}/%{pypi_name}-*-info/
  85. %endif
  86. %changelog
  87. * Sun Aug 16 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 20.4-1
  88. - new upstream release.
  89. * Wed Nov 28 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 18.0-1
  90. - new upstream release.
  91. - initial build for Vine Linux.
  92. * Tue Jul 31 2018 Charalampos Stratakis <cstratak@redhat.com> - 17.1-1
  93. - Update to 17.1
  94. * Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 16.8-11
  95. - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
  96. * Sat Jun 16 2018 Miro Hrončok <mhroncok@redhat.com> - 16.8-10
  97. - Rebuilt for Python 3.7
  98. * Thu Jun 14 2018 Miro Hrončok <mhroncok@redhat.com> - 16.8-9
  99. - Bootstrap for Python 3.7
  100. * Fri Feb 09 2018 Iryna Shcherbina <ishcherb@redhat.com> - 16.8-8
  101. - Update Python 2 dependency declarations to new packaging standards
  102. (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
  103. * Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 16.8-7
  104. - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
  105. * Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 16.8-6
  106. - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
  107. * Wed Mar 22 2017 Lumir Balhar <lbalhar@redhat.com> - 16.8-5
  108. - Epel7 compatible spec/package
  109. * Mon Feb 13 2017 Charalampos Stratakis <cstratak@redhat.com> - 16.8-4
  110. - Rebuild as wheel
  111. * Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 16.8-3
  112. - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
  113. * Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 16.8-2
  114. - Rebuild for Python 3.6
  115. * Wed Nov 02 2016 Lumir Balhar <lbalhar@redhat.com> - 16.8-1
  116. - New upstream version
  117. * Fri Sep 16 2016 Lumir Balhar <lbalhar@redhat.com> - 16.7-1
  118. - Initial package.