2019-09-30 11:15:23 -04:00
|
|
|
Name: python-pycparser
|
|
|
|
|
Summary: A parser for the C language
|
2020-07-28 17:46:00 +08:00
|
|
|
Version: 2.20
|
2020-10-30 14:22:06 +08:00
|
|
|
Release: 3
|
2019-09-30 11:15:23 -04:00
|
|
|
License: BSD
|
|
|
|
|
URL: http://github.com/eliben/pycparser
|
2020-09-05 17:30:46 +08:00
|
|
|
Source0: http://github.com/eliben/pycparser/archive/release_v%{version}.tar.gz
|
2019-09-30 11:15:23 -04:00
|
|
|
# source1 from https://koji.fedoraproject.org/koji/buildinfo?buildID=1092324
|
|
|
|
|
Source1: pycparser-0.91.1-remove-relative-sys-path.py
|
|
|
|
|
# patch1 is adapted from https://koji.fedoraproject.org/koji/buildinfo?buildID=1092324
|
|
|
|
|
# remove embedded libraries during packaging
|
|
|
|
|
Patch1: pycparser-2.10-ply.patch
|
|
|
|
|
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
2020-10-30 14:22:06 +08:00
|
|
|
BuildRequires: python3-pycparser python3-unversioned-command
|
2019-09-30 11:15:23 -04:00
|
|
|
# for unit tests
|
2020-10-30 14:22:06 +08:00
|
|
|
BuildRequires: dos2unix python3-devel python3-setuptools python3-ply
|
2019-09-30 11:15:23 -04:00
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
pycparser is a parser for the C language, written in pure Python.
|
|
|
|
|
It is a module designed to be easily integrated into applications
|
|
|
|
|
that need to parse C source code.
|
|
|
|
|
|
|
|
|
|
%package devel
|
|
|
|
|
Summary: Development files for %{name}
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
%description devel
|
|
|
|
|
This package contains development files for %{name}
|
|
|
|
|
|
|
|
|
|
%package -n python3-pycparser
|
|
|
|
|
Summary: A parser for the C language
|
|
|
|
|
Group: System Environment/Libraries
|
|
|
|
|
Requires: python3-ply
|
|
|
|
|
%{?python_provide:%python_provide python3-pycparser}
|
|
|
|
|
|
|
|
|
|
%description -n python3-pycparser
|
|
|
|
|
pycparser is a parser for the C language, written in pure Python.
|
|
|
|
|
It is a module designed to be easily integrated into applications
|
|
|
|
|
that need to parse C source code.
|
|
|
|
|
This package is for Python3.
|
|
|
|
|
%prep
|
|
|
|
|
%autosetup -n pycparser-release_v%{version} -p1
|
|
|
|
|
# remove embedded copy of ply
|
|
|
|
|
rm -rf pycparser/ply
|
2020-10-30 14:22:06 +08:00
|
|
|
%{__python3} %{SOURCE1} examples
|
2019-09-30 11:15:23 -04:00
|
|
|
dos2unix LICENSE
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
%py3_build
|
|
|
|
|
pushd build/lib/pycparser
|
|
|
|
|
%{__python3} _build_tables.py
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
%py3_install
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
%{__python3} tests/all_tests.py
|
|
|
|
|
|
|
|
|
|
%files devel
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%doc examples
|
|
|
|
|
|
|
|
|
|
%files -n python3-pycparser
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%license LICENSE
|
|
|
|
|
%{python3_sitelib}/pycparser/
|
|
|
|
|
%{python3_sitelib}/pycparser-*.egg-info
|
|
|
|
|
|
|
|
|
|
%changelog
|
2020-10-30 14:22:06 +08:00
|
|
|
* Fri Oct 30 2020 tianwei<tianwei12@huawei.com> - 2.20-3
|
|
|
|
|
- remove python2
|
|
|
|
|
|
2020-09-05 17:30:46 +08:00
|
|
|
* Sat Sep 5 2020 shixuantong<shixuantong@huawei.com> - 2.20-2
|
|
|
|
|
- update source0 and change tar package name
|
|
|
|
|
|
2020-07-28 17:46:00 +08:00
|
|
|
* Tue Jul 28 2020 jinzhimin<jinzhimin2@huawei.com> - 2.20-1
|
|
|
|
|
- update to 2.20
|
|
|
|
|
|
2019-09-30 11:15:23 -04:00
|
|
|
* Sun Sep 15 2019 openEuler Buildteam <buildteam@openeuler.org> - 2.19-1
|
|
|
|
|
- Package init
|