From 44777951800d1fbd9df3cb15c20ca4d70e24bc8c Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Nov 03 2016 05:44:34 +0000 Subject: import python-idna-2.0-1.el7 --- diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..43bafbc --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/idna-2.0.tar.gz diff --git a/.python-idna.metadata b/.python-idna.metadata new file mode 100644 index 0000000..4bf5736 --- /dev/null +++ b/.python-idna.metadata @@ -0,0 +1 @@ +e48d607370b11e02512bac0985c902112c4dac40 SOURCES/idna-2.0.tar.gz diff --git a/README.md b/README.md deleted file mode 100644 index 98f42b4..0000000 --- a/README.md +++ /dev/null @@ -1,4 +0,0 @@ -The master branch has no content - -Look at the c7 branch if you are working with CentOS-7, or the c4/c5/c6 branch for CentOS-4, 5 or 6 -If you find this file in a distro specific branch, it means that no content has been checked in yet diff --git a/SPECS/python-idna.spec b/SPECS/python-idna.spec new file mode 100644 index 0000000..29bbdb4 --- /dev/null +++ b/SPECS/python-idna.spec @@ -0,0 +1,109 @@ +%if 0%{?fedora} +%global with_python3 1 +%endif + +%global srcname idna + +Name: python-%{srcname} +Version: 2.0 +Release: 1%{?dist} +Summary: Internationalized Domain Names in Applications (IDNA) + +License: BSD and Python and Unicode +URL: https://github.com/kjd/idna +Source0: https://pypi.python.org/packages/source/i/%{srcname}/%{srcname}-%{version}.tar.gz +BuildArch: noarch + +BuildRequires: python2-devel +BuildRequires: python-setuptools +%if 0%{?with_python3} +BuildRequires: python3-devel +BuildRequires: python3-setuptools +%endif # with_python3 + +%description +A library to support the Internationalised Domain Names in Applications (IDNA) +protocol as specified in RFC 5891 . This +version of the protocol is often referred to as "IDNA2008" and can produce +different results from the earlier standard from 2003. + +The library is also intended to act as a suitable drop-in replacement for the +"encodings.idna" module that comes with the Python standard library but +currently only supports the older 2003 specification. + +%if 0%{?with_python3} +%package -n python3-%{srcname} +Summary: Internationalized Domain Names in Applications (IDNA) + +%description -n python3-%{srcname} +A library to support the Internationalised Domain Names in Applications (IDNA) +protocol as specified in RFC 5891 . This +version of the protocol is often referred to as "IDNA2008" and can produce +different results from the earlier standard from 2003. + +The library is also intended to act as a suitable drop-in replacement for the +"encodings.idna" module that comes with the Python standard library but +currently only supports the older 2003 specification. +%endif # with_python3 + +%prep +%setup -q -n %{srcname}-%{version} +# Remove bundled egg-info +rm -rf %{srcname}.egg-info + +%if 0%{?with_python3} +rm -rf %{py3dir} +cp -a . %{py3dir} +%endif # with_python3 + + + +%build +%{__python2} setup.py build + +%if 0%{?with_python3} +pushd %{py3dir} +# Set LANG when building with python 3 due to +# https://github.com/kjd/idna/pull/4 +LANG=en_US.UTF-8 %{__python3} setup.py build +popd +%endif # with_python3 + +%install +%if 0%{?with_python3} +pushd %{py3dir} +# Set LANG when building with python 3 due to +# https://github.com/kjd/idna/pull/4 +LANG=en_US.UTF-8 %{__python3} setup.py install --skip-build --root %{buildroot} +popd +%endif # with_python3 + +%{__python2} setup.py install --skip-build --root %{buildroot} + +%check +%{__python2} setup.py test + +%if 0%{?with_python3} +pushd %{py3dir} +# Set LANG when building with python 3 due to +# https://github.com/kjd/idna/pull/4 +LANG=en_US.UTF-8 %{__python3} setup.py test +popd +%endif # with_python3 + + +%files +%doc README.rst HISTORY.rst LICENSE.rst +%{python2_sitelib}/%{srcname} +%{python2_sitelib}/%{srcname}-%{version}-py%{python2_version}.egg-info + +%if 0%{?with_python3} +%files -n python3-%{srcname} +%doc README.rst HISTORY.rst LICENSE.rst +%{python3_sitelib}/%{srcname} +%{python3_sitelib}/%{srcname}-%{version}-py%{python3_version}.egg-info +%endif # with_python3 + +%changelog +* Thu Apr 07 2016 Paul Wouters - 2.0-1 +- Resolves: rhbz#1297583 New package: python-idna