Merged update from upstream sources

This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/libldb.git#69d51729c5354301bc1f5adc3ac9d11d8cd83a39
This commit is contained in:
DistroBaker 2020-10-27 17:45:20 +01:00 committed by Petr Šabata
parent 1b2b842ad9
commit 78fe76b6d4

View File

@ -1,16 +1,22 @@
%if ((0%{?fedora} || 0%{?rhel} > 7 || 0%{?epel} > 6))
# lmdb is not supported on 32 bit architectures # lmdb is not supported on 32 bit architectures
%if ((0%{?fedora} || 0%{?epel} > 6) && 0%{?__isa_bits} == 64) %ifarch aarch64 s390x x86_64
%ifarch ppc64le %bcond_without lmdb
%global without_lmdb_flags --without-ldb-lmdb
%else %else
%global with_lmdb 1 %bcond_with lmdb
#endif arch
%endif %endif
%else %else
%global without_lmdb_flags --without-ldb-lmdb %bcond_with lmdb
#endif fedora || rhel || epel
%endif %endif
%if 0%{?fedora} || 0%{?rhel} > 7 %if 0%{?fedora} || 0%{?rhel} > 7
%global with_python3 1 %bcond_without python3
%else
%bcond_with python3
%endif %endif
%global talloc_version 2.3.1 %global talloc_version 2.3.1
@ -19,7 +25,7 @@
Name: libldb Name: libldb
Version: 2.2.0 Version: 2.2.0
Release: 4%{?dist} Release: 6%{?dist}
Summary: A schema-less, ldap like, API and database Summary: A schema-less, ldap like, API and database
Requires: libtalloc%{?_isa} >= %{talloc_version} Requires: libtalloc%{?_isa} >= %{talloc_version}
Requires: libtdb%{?_isa} >= %{tdb_version} Requires: libtdb%{?_isa} >= %{tdb_version}
@ -38,17 +44,18 @@ BuildRequires: gcc
BuildRequires: libtalloc-devel >= %{talloc_version} BuildRequires: libtalloc-devel >= %{talloc_version}
BuildRequires: libtdb-devel >= %{tdb_version} BuildRequires: libtdb-devel >= %{tdb_version}
BuildRequires: libtevent-devel >= %{tevent_version} BuildRequires: libtevent-devel >= %{tevent_version}
%if 0%{?with_lmdb} %if %{with lmdb}
BuildRequires: lmdb-devel >= 0.9.16 BuildRequires: lmdb-devel >= 0.9.16
%endif %endif
BuildRequires: popt-devel BuildRequires: popt-devel
BuildRequires: libxslt BuildRequires: libxslt
BuildRequires: docbook-style-xsl BuildRequires: docbook-style-xsl
%if 0%{?with_python3} %if %{with python3}
BuildRequires: python3-devel BuildRequires: python3-devel
BuildRequires: python3-tdb BuildRequires: python3-tdb
BuildRequires: python3-talloc-devel BuildRequires: python3-talloc-devel
BuildRequires: python3-tevent BuildRequires: python3-tevent
#endif with python
%endif %endif
BuildRequires: doxygen BuildRequires: doxygen
BuildRequires: openldap-devel BuildRequires: openldap-devel
@ -92,7 +99,7 @@ Provides: pyldb-devel%{?_isa} = %{version}-%{release}
Development files for the Python bindings for the LDB library. Development files for the Python bindings for the LDB library.
This package includes files that aren't specific to a Python version. This package includes files that aren't specific to a Python version.
%if 0%{?with_python3} %if %{with python3}
%package -n python3-ldb %package -n python3-ldb
Summary: Python bindings for the LDB library Summary: Python bindings for the LDB library
Requires: libldb%{?_isa} = %{version}-%{release} Requires: libldb%{?_isa} = %{version}-%{release}
@ -112,6 +119,7 @@ Requires: python-ldb-devel-common%{?_isa} = %{version}-%{release}
%description -n python3-ldb-devel %description -n python3-ldb-devel
Development files for the Python bindings for the LDB library Development files for the Python bindings for the LDB library
#endif with python
%endif %endif
%prep %prep
@ -138,21 +146,20 @@ export python_LDFLAGS=""
--bundled-libraries=NONE \ --bundled-libraries=NONE \
--builtin-libraries=replace \ --builtin-libraries=replace \
--with-modulesdir=%{_libdir}/ldb/modules \ --with-modulesdir=%{_libdir}/ldb/modules \
%{?without_lmdb_flags} \ %if %{without lmdb}
--without-ldb-lmdb \
%endif
--with-privatelibdir=%{_libdir}/ldb --with-privatelibdir=%{_libdir}/ldb
%make_build %make_build
doxygen Doxyfile doxygen Doxyfile
%if %{with lmdb}
%check %check
%ifarch ppc64le make %{?_smp_mflags} check
echo disabling one assertion in tests/python/repack.py #endif with lmdb
sed -e '/test_guid_indexed_v1_db/,+18{/toggle_guidindex_check_pack/d}' -i tests/python/repack.py
%endif %endif
%make_build check
%install %install
%make_install %make_install
@ -171,7 +178,7 @@ rm -f $RPM_BUILD_ROOT/%{_mandir}/man3/_*
%{_libdir}/ldb/libldb-key-value.so %{_libdir}/ldb/libldb-key-value.so
%{_libdir}/ldb/libldb-tdb-err-map.so %{_libdir}/ldb/libldb-tdb-err-map.so
%{_libdir}/ldb/libldb-tdb-int.so %{_libdir}/ldb/libldb-tdb-int.so
%if 0%{?with_lmdb} %if %{with lmdb}
%{_libdir}/ldb/libldb-mdb-int.so %{_libdir}/ldb/libldb-mdb-int.so
%endif %endif
%dir %{_libdir}/ldb/modules %dir %{_libdir}/ldb/modules
@ -209,7 +216,7 @@ rm -f $RPM_BUILD_ROOT/%{_mandir}/man3/_*
%{_includedir}/pyldb.h %{_includedir}/pyldb.h
%{_mandir}/man*/Py*.gz %{_mandir}/man*/Py*.gz
%if 0%{?with_python3} %if %{with python3}
%files -n python3-ldb %files -n python3-ldb
%{python3_sitearch}/ldb.cpython-*.so %{python3_sitearch}/ldb.cpython-*.so
%{_libdir}/libpyldb-util.cpython-*.so.2* %{_libdir}/libpyldb-util.cpython-*.so.2*
@ -221,9 +228,16 @@ rm -f $RPM_BUILD_ROOT/%{_mandir}/man3/_*
%{_libdir}/pkgconfig/pyldb-util.cpython-*.pc %{_libdir}/pkgconfig/pyldb-util.cpython-*.pc
%ldconfig_scriptlets -n python3-ldb %ldconfig_scriptlets -n python3-ldb
#endif with python
%endif %endif
%changelog %changelog
* Tue Oct 27 2020 Andreas Schneider <asn@redhat.com> - 2.2.0-6
- Spec file cleanup and improvements
* Thu Oct 22 2020 Alexander Bokovoy <abokovoy@redhat.com> - 2.2.0-5
- Rebuild for Python 3.9
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.2.0-4 * Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.2.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild