python-PyMySQL/python-PyMySQL.spec

84 lines
2.5 KiB
RPMSpec
Raw Normal View History

%global _empty_manifest_terminate_build 0
2020-02-14 17:29:59 +08:00
Name: python-PyMySQL
Version: 1.0.2
Release: 1
2020-02-14 17:29:59 +08:00
Summary: Pure Python MySQL Client
License: MIT
URL: https://github.com/PyMySQL/PyMySQL/
Source0: https://files.pythonhosted.org/packages/60/ea/33b8430115d9b617b713959b21dfd5db1df77425e38efea08d121e83b712/PyMySQL-1.0.2.tar.gz
2020-02-14 17:29:59 +08:00
BuildArch: noarch
%description
This package contains a pure-Python MySQL client library, based on PEP 249.
%package -n python3-PyMySQL
Summary: Pure Python MySQL Driver
Provides: python-PyMySQL
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: python3-cryptography
2020-02-14 17:29:59 +08:00
%description -n python3-PyMySQL
This package contains a pure-Python MySQL client library, based on PEP 249.
%package help
Summary: Pure Python MySQL Driver
Provides: python3-PyMySQL-doc
%description help
This package contains a pure-Python MySQL client library, based on PEP 249.
2020-02-14 17:29:59 +08:00
%prep
%autosetup -n PyMySQL-%{version} -p1
%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 .
%check
%{__python3} setup.py test
2020-02-14 17:29:59 +08:00
%files -n python3-PyMySQL -f filelist.lst
%dir %{python3_sitelib}/*
2020-02-14 17:29:59 +08:00
%files help -f doclist.lst
%{_docdir}/*
2020-02-14 17:29:59 +08:00
%changelog
* Mon Aug 09 2021 OpenStack_SIG <openstack@openeuler.org> - 1.0.2-1
- Update version to 1.0.2, because of the dependence of Openstack Wallaby
2020-10-30 14:22:19 +08:00
* Fri Oct 30 2020 yanglongkang <yanglongkang@huawei.com> - 0.9.3-2
- remove python2 dependency
* Jul Thu 16 2020 yanglongkang <yanglongkang@huawei.com> - 0.9.3-1
- update package to 0.9.3
2020-02-14 17:29:59 +08:00
* Fri Feb 14 2020 hy-euler <eulerstoragemt@huawei.com> - 0.9.2-3
- Package Initialization