!1 Package init

Merge pull request !1 from huzunhao/master
This commit is contained in:
openeuler-ci-bot 2020-02-19 10:08:30 +08:00 committed by Gitee
commit fca4a8b81d
2 changed files with 62 additions and 0 deletions

BIN
python-ldap-3.1.0.tar.gz Normal file

Binary file not shown.

62
python-ldap.spec Normal file
View File

@ -0,0 +1,62 @@
%define debug_package %{nil}
Name: python-ldap
Version: 3.1.0
Release: 1
Summary: An object-oriented API to access LDAP directory servers
License: Python
URL: http://python-ldap.org/
Source0: https://files.pythonhosted.org/packages/source/p/%{name}/%{name}-%{version}.tar.gz
BuildRequires: gcc openldap-devel >= 2.4.45-4 openssl-devel cyrus-sasl-devel
BuildRequires: python3-devel python3-setuptools openldap-servers >= 2.4.45-4
BuildRequires: python3-coverage openldap-clients >= 2.4.45-4 /usr/bin/tox
BuildRequires: python3-pyasn1 >= 0.3.7 python3-pyasn1-modules >= 0.1.5
%description
python-ldap provides an object-oriented API for working with LDAP within\
Python programs. It allows access to LDAP directory servers by wrapping the\
OpenLDAP 2.x libraries, and contains modules for other LDAP-related tasks\
(including processing LDIF, LDAPURLs, LDAPv3 schema, etc.).
%package -n python3-ldap
Summary: An object-oriented API to access LDAP directory servers
Requires: openldap >= 2.4.45-4 python3-pyasn1 >= 0.3.7
Requires: python3-pyasn1-modules >= 0.1.5 python3-setuptools
%{?python_provide:%python_provide python3-ldap}
Obsoletes: python3-pyldap < 3
Provides: python3-pyldap = %{version}-%{release}
Provides: python3-pyldap%{?_isa} = %{version}-%{release}
%description -n python3-ldap
python-ldap provides an object-oriented API for working with LDAP within\
Python programs. It allows access to LDAP directory servers by wrapping the\
OpenLDAP 2.x libraries, and contains modules for other LDAP-related tasks\
(including processing LDIF, LDAPURLs, LDAPv3 schema, etc.).
%package_help
%prep
%autosetup -n %{name}-%{version}
find . -name '*.py' | xargs sed -i '1s|^#!/usr/bin/env python|#!%{__python3}|'
sed -i 's,-Werror,-Wignore,g' tox.ini
%build
%_bindir/python3 setup.py build '--executable=%_bindir/python3 -s'
%install
%_bindir/python3 setup.py install -O1 --skip-build --root %buildroot
%check
%files -n python3-ldap
%defattr(-,root,root)
%license LICENCE
%{_libdir}/python3.7/site-packages/*
%files help
%defattr(-,root,root)
%doc CHANGES README TODO Demo
%changelog
* Tue Feb 11 2020 huzunhao<huzunhao2@huawei.com> - 3.1.0-1
- Package init