|
|
@ -1,16 +1,29 @@
|
|
|
|
%global modname ply
|
|
|
|
%global modname ply
|
|
|
|
|
|
|
|
|
|
|
|
%bcond_without tests
|
|
|
|
%if 0%{?fedora} || 0%{?rhel} >= 8
|
|
|
|
|
|
|
|
%bcond_without python3
|
|
|
|
|
|
|
|
%else
|
|
|
|
|
|
|
|
%bcond_with python3
|
|
|
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if 0%{?rhel} > 7
|
|
|
|
|
|
|
|
# Disable python2 build by default
|
|
|
|
|
|
|
|
%bcond_with python2
|
|
|
|
|
|
|
|
%else
|
|
|
|
|
|
|
|
%bcond_without python2
|
|
|
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
|
|
Name: python-%{modname}
|
|
|
|
Name: python-%{modname}
|
|
|
|
Summary: Python Lex-Yacc
|
|
|
|
Summary: Python Lex-Yacc
|
|
|
|
Version: 3.11
|
|
|
|
Version: 3.9
|
|
|
|
Release: 14%{?dist}
|
|
|
|
Release: 9%{?dist}
|
|
|
|
License: BSD
|
|
|
|
License: BSD
|
|
|
|
URL: http://www.dabeaz.com/ply/
|
|
|
|
URL: http://www.dabeaz.com/ply/
|
|
|
|
Source0: http://www.dabeaz.com/ply/%{modname}-%{version}.tar.gz
|
|
|
|
Source0: http://www.dabeaz.com/ply/%{modname}-%{version}.tar.gz
|
|
|
|
BuildArch: noarch
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Patch1: Make-MD5-fingerprint-FIPS-compatible.patch
|
|
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
%description
|
|
|
|
PLY is a straightforward lex/yacc implementation. Here is a list of its
|
|
|
|
PLY is a straightforward lex/yacc implementation. Here is a list of its
|
|
|
|
essential features:
|
|
|
|
essential features:
|
|
|
@ -25,6 +38,31 @@ essential features:
|
|
|
|
functionality. In other words, it's not a large parsing framework or a
|
|
|
|
functionality. In other words, it's not a large parsing framework or a
|
|
|
|
component of some larger system.
|
|
|
|
component of some larger system.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if %{with python2}
|
|
|
|
|
|
|
|
%package -n python2-%{modname}
|
|
|
|
|
|
|
|
Summary: Python Lex-Yacc
|
|
|
|
|
|
|
|
%{?python_provide:%python_provide python2-%{modname}}
|
|
|
|
|
|
|
|
BuildRequires: python2-devel
|
|
|
|
|
|
|
|
BuildRequires: python2-setuptools
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%description -n python2-%{modname}
|
|
|
|
|
|
|
|
PLY is a straightforward lex/yacc implementation. Here is a list of its
|
|
|
|
|
|
|
|
essential features:
|
|
|
|
|
|
|
|
* It is implemented entirely in Python.
|
|
|
|
|
|
|
|
* It uses LR-parsing which is reasonably efficient and well suited for larger
|
|
|
|
|
|
|
|
grammars.
|
|
|
|
|
|
|
|
* PLY provides most of the standard lex/yacc features including support
|
|
|
|
|
|
|
|
for empty productions, precedence rules, error recovery, and support
|
|
|
|
|
|
|
|
for ambiguous grammars.
|
|
|
|
|
|
|
|
* PLY is straightforward to use and provides very extensive error checking.
|
|
|
|
|
|
|
|
* PLY doesn't try to do anything more or less than provide the basic lex/yacc
|
|
|
|
|
|
|
|
functionality. In other words, it's not a large parsing framework or a
|
|
|
|
|
|
|
|
component of some larger system.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Python 2 version.
|
|
|
|
|
|
|
|
%endif # with python2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if %{with python3}
|
|
|
|
%package -n python3-%{modname}
|
|
|
|
%package -n python3-%{modname}
|
|
|
|
Summary: Python Lex-Yacc
|
|
|
|
Summary: Python Lex-Yacc
|
|
|
|
%{?python_provide:%python_provide python3-%{modname}}
|
|
|
|
%{?python_provide:%python_provide python3-%{modname}}
|
|
|
@ -46,90 +84,104 @@ essential features:
|
|
|
|
component of some larger system.
|
|
|
|
component of some larger system.
|
|
|
|
|
|
|
|
|
|
|
|
Python 3 version.
|
|
|
|
Python 3 version.
|
|
|
|
|
|
|
|
%endif # with python3
|
|
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%prep
|
|
|
|
%autosetup -n %{modname}-%{version}
|
|
|
|
%autosetup -c -N
|
|
|
|
find example/ -type f -executable -exec chmod -x {} ';'
|
|
|
|
|
|
|
|
find example/ -type f -name '*.py' -exec sed -i \
|
|
|
|
pushd %{modname}-%{version}
|
|
|
|
|
|
|
|
%patch1 -p1
|
|
|
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if %{with python2}
|
|
|
|
|
|
|
|
cp -ai %{modname}-%{version} python2
|
|
|
|
|
|
|
|
find python2/example/ -type f -exec chmod -x {} ';'
|
|
|
|
|
|
|
|
find python2/example/ -type f -name '*.py' -exec sed -i \
|
|
|
|
-e '1{\@^#!/usr/bin/env python@d}' -e '1{\@^#!/usr/local/bin/python@d}' \
|
|
|
|
-e '1{\@^#!/usr/bin/env python@d}' -e '1{\@^#!/usr/local/bin/python@d}' \
|
|
|
|
{} ';'
|
|
|
|
{} ';'
|
|
|
|
rm -rf *.egg-info
|
|
|
|
rm -rf python2/*.egg-info
|
|
|
|
|
|
|
|
# extract license block from beginning of README.md
|
|
|
|
|
|
|
|
grep -B1000 "POSSIBILITY OF SUCH DAMAGE" python2/README.md > python2/LICENSE
|
|
|
|
|
|
|
|
%endif # with python2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if %{with python3}
|
|
|
|
|
|
|
|
cp -ai %{modname}-%{version} python3
|
|
|
|
# extract license block from beginning of README.md
|
|
|
|
# extract license block from beginning of README.md
|
|
|
|
grep -B1000 "POSSIBILITY OF SUCH DAMAGE" README.md > LICENSE
|
|
|
|
grep -B1000 "POSSIBILITY OF SUCH DAMAGE" python3/README.md > python3/LICENSE
|
|
|
|
|
|
|
|
%endif # with python3
|
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
%build
|
|
|
|
%py3_build
|
|
|
|
%if %{with python2}
|
|
|
|
|
|
|
|
pushd python2
|
|
|
|
|
|
|
|
%py2_build
|
|
|
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
%endif # with python2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if 0%{?with_python3}
|
|
|
|
|
|
|
|
pushd python3
|
|
|
|
|
|
|
|
%py3_build
|
|
|
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
%endif # with python3
|
|
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
%install
|
|
|
|
%py3_install
|
|
|
|
%if %{with python2}
|
|
|
|
|
|
|
|
pushd python2
|
|
|
|
|
|
|
|
%py2_install
|
|
|
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
%endif # with python2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if %{with python3}
|
|
|
|
|
|
|
|
pushd python3
|
|
|
|
|
|
|
|
%py3_install
|
|
|
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
%endif # with python3
|
|
|
|
|
|
|
|
|
|
|
|
%if %{with tests}
|
|
|
|
|
|
|
|
%check
|
|
|
|
%check
|
|
|
|
pushd test
|
|
|
|
%if %{with python2}
|
|
|
|
|
|
|
|
pushd python2/test
|
|
|
|
|
|
|
|
./cleanup.sh
|
|
|
|
|
|
|
|
%{__python2} testlex.py
|
|
|
|
|
|
|
|
%{__python2} testyacc.py
|
|
|
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
%endif # with python2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if %{with python3}
|
|
|
|
|
|
|
|
pushd python3/test
|
|
|
|
./cleanup.sh
|
|
|
|
./cleanup.sh
|
|
|
|
%{__python3} testlex.py
|
|
|
|
%{__python3} testlex.py
|
|
|
|
%{__python3} testyacc.py
|
|
|
|
%{__python3} testyacc.py
|
|
|
|
popd
|
|
|
|
popd
|
|
|
|
%endif
|
|
|
|
%endif # with python3
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if %{with python2}
|
|
|
|
|
|
|
|
%files -n python2-%{modname}
|
|
|
|
|
|
|
|
%doc python2/CHANGES python2/README.md
|
|
|
|
|
|
|
|
%license python2/LICENSE
|
|
|
|
|
|
|
|
%{python2_sitelib}/%{modname}/
|
|
|
|
|
|
|
|
%{python2_sitelib}/%{modname}-%{version}-*.egg-info/
|
|
|
|
|
|
|
|
%endif # with python2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if %{with python3}
|
|
|
|
%files -n python3-%{modname}
|
|
|
|
%files -n python3-%{modname}
|
|
|
|
%doc CHANGES README.md
|
|
|
|
%doc python3/CHANGES python3/README.md
|
|
|
|
%license LICENSE
|
|
|
|
%license python3/LICENSE
|
|
|
|
%{python3_sitelib}/%{modname}/
|
|
|
|
%{python3_sitelib}/%{modname}/
|
|
|
|
%{python3_sitelib}/%{modname}-%{version}-*.egg-info/
|
|
|
|
%{python3_sitelib}/%{modname}-%{version}-*.egg-info/
|
|
|
|
|
|
|
|
%endif # with python3
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
%changelog
|
|
|
|
* Tue Feb 08 2022 Tomáš Hrnčiar <thrnciar@redhat.com> - 3.11-14
|
|
|
|
* Wed Jul 26 2023 MSVSphere Packaging Team <packager@msvsphere.ru> - 3.9-9
|
|
|
|
- Add automatically generated Obsoletes tag with the python39- prefix
|
|
|
|
- Rebuilt for MSVSphere 8.8
|
|
|
|
for smoother upgrade from RHEL8
|
|
|
|
|
|
|
|
- Related: rhbz#1990421
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 3.11-13
|
|
|
|
|
|
|
|
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
|
|
|
|
|
|
|
Related: rhbz#1991688
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 3.11-12
|
|
|
|
|
|
|
|
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-11
|
|
|
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Tue Jan 5 15:25:57 CET 2021 Christian Heimes <cheimes@redhat.com> - 3.11-10
|
|
|
|
|
|
|
|
- Extract and ship license file (#1912893)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-9
|
|
|
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Sat May 23 2020 Miro Hrončok <mhroncok@redhat.com> - 3.11-8
|
|
|
|
|
|
|
|
- Rebuilt for Python 3.9
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-7
|
|
|
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Sun Oct 20 2019 Miro Hrončok <mhroncok@redhat.com> - 3.11-6
|
|
|
|
|
|
|
|
- Subpackage python2-ply has been removed
|
|
|
|
|
|
|
|
See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 3.11-5
|
|
|
|
|
|
|
|
- Rebuilt for Python 3.8.0rc1 (#1748018)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Thu Aug 15 2019 Miro Hrončok <mhroncok@redhat.com> - 3.11-4
|
|
|
|
|
|
|
|
- Rebuilt for Python 3.8
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-3
|
|
|
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-2
|
|
|
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Fri Jan 11 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 3.11-1
|
|
|
|
* Wed Jan 6 14:57:34 CET 2021 Christian Heimes <cheimes@redhat.com> - 3.9-9
|
|
|
|
- Update to 3.11
|
|
|
|
- Include README.MD and LICENSE (#1464435)
|
|
|
|
|
|
|
|
|
|
|
|
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.9-8
|
|
|
|
* Mon Nov 11 2019 Christian Heimes <cheimes@redhat.com> - 3.9-8
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
|
|
|
- Make MD5 fingerprint FIPS compliant
|
|
|
|
|
|
|
|
- Resolves: rhbz#1747490
|
|
|
|
|
|
|
|
|
|
|
|
* Fri Jun 15 2018 Miro Hrončok <mhroncok@redhat.com> - 3.9-7
|
|
|
|
* Fri Jun 15 2018 Charalampos Stratakis <cstratak@redhat.com> - 3.9-7
|
|
|
|
- Rebuilt for Python 3.7
|
|
|
|
- Conditionalize the python2 subpackage
|
|
|
|
|
|
|
|
|
|
|
|
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.9-6
|
|
|
|
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.9-6
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
|
|
|