!2 Package init

From: @baizg1107
Reviewed-by: @myeuler
Signed-off-by: @myeuler
This commit is contained in:
openeuler-ci-bot 2020-12-30 11:02:18 +08:00 committed by Gitee
commit dd6e1c2848
2 changed files with 83 additions and 0 deletions

BIN
iniconfig-1.1.1.tar.gz Normal file

Binary file not shown.

83
python-iniconfig.spec Normal file
View File

@ -0,0 +1,83 @@
%global _empty_manifest_terminate_build 0
Name: python-iniconfig
Version: 1.1.1
Release: 1
Summary: iniconfig: brain-dead simple config-ini parsing
License: MIT License
URL: http://github.com/RonnyPfannschmidt/iniconfig
Source0: https://files.pythonhosted.org/packages/23/a2/97899f6bd0e873fed3a7e67ae8d3a08b21799430fb4da15cfedf10d6e2c2/iniconfig-1.1.1.tar.gz
BuildArch: noarch
Recommends: %{name}-help = %{version}-%{release}
%global _description \
iniconfig is a small and simple INI-file parser module\
having a unique set of features:\
* tested against Python2.4 across to Python3.2, Jython, PyPy\
* maintains order of sections and entries\
* supports multi-line values with or without line-continuations\
* supports "#" comments everywhere\
* raises errors with proper line-numbers\
* no bells and whistles like automatic substitutions\
* iniconfig raises an Error if two sections have the same name.\
%description
%{_description}
%package -n python3-iniconfig
Summary: iniconfig: brain-dead simple config-ini parsing
Provides: python-iniconfig
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: python3-setuptools_scm
%description -n python3-iniconfig
%{_description}
%package help
Summary: Development documents and examples for iniconfig
Provides: python3-iniconfig-doc
%description help
%{_description}
%prep
%autosetup -n iniconfig-1.1.1
%build
%py3_build
%install
%py3_install
install -d -m755 %{buildroot}/%{_pkgdocdir}
if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
pushd %{buildroot}
if [ -d usr/lib ]; then
find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/lib64 ]; then
find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/bin ]; then
find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/sbin ]; then
find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
fi
touch doclist.lst
if [ -d usr/share/man ]; then
find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
fi
popd
mv %{buildroot}/filelist.lst .
mv %{buildroot}/doclist.lst .
%files -n python3-iniconfig -f filelist.lst
%dir %{python3_sitelib}/*
%files help -f doclist.lst
%{_pkgdocdir}
%changelog
* Tue Dec 08 2020 baizhonggui <baizhonggui@huawei.com> - 1.1.1-1
- Package init