Accepting request 506983 from home:jengelh:branches:network:ldap

- Remove all non-r libldap links so OBS has a clearer picture of
  rebuilds. [boo sr#501631]

OBS-URL: https://build.opensuse.org/request/show/506983
OBS-URL: https://build.opensuse.org/package/show/network:ldap/openldap2?expand=0&rev=179
This commit is contained in:
Howard Guo 2017-07-04 08:52:54 +00:00 committed by Git OBS Bridge
parent 39fedbb334
commit 90b761d030
2 changed files with 10 additions and 17 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Jun 29 08:27:17 UTC 2017 - jengelh@inai.de
- Remove all non-r libldap links so OBS has a clearer picture of
rebuilds. [boo sr#501631]
-------------------------------------------------------------------
Wed Jun 7 09:32:52 UTC 2017 - hguo@suse.com

View File

@ -211,11 +211,6 @@ for development.
Summary: OpenLDAP Client Libraries
Group: Productivity/Networking/LDAP/Clients
Recommends: libldap-data >= %{version_main}
%ifarch x86_64 sparc64 ppc64 s390x
Provides: libldap-2.4.so.2()(64bit)
%else
Provides: libldap-2.4.so.2
%endif
%description -n libldap-2_4-2
This package contains the OpenLDAP client libraries.
@ -358,7 +353,6 @@ install -m 644 %{SOURCE4} ${RPM_BUILD_ROOT}/%{_sysconfdir}/sasl2/slapd.conf
install -m 755 -d ${RPM_BUILD_ROOT}/var/lib/ldap
chmod a+x ${RPM_BUILD_ROOT}/%{_libdir}/liblber.so*
chmod a+x ${RPM_BUILD_ROOT}/%{_libdir}/libldap_r.so*
chmod a+x ${RPM_BUILD_ROOT}/%{_libdir}/libldap.so*
install -m 755 %{SOURCE6} ${RPM_BUILD_ROOT}/usr/sbin/schema2ldif
# Install ppolicy check module
@ -423,10 +417,12 @@ rm -f ${RPM_BUILD_ROOT}/usr/share/man/man5/slapd-tcl.5
# Remove *.la files, libtool does not handle this correct
rm -f ${RPM_BUILD_ROOT}%{_libdir}/lib*.la
# Make ldap_r the only copy in the system [rh#1370065]
# Make ldap_r the only copy in the system [rh#1370065],
# and provide only libldap.so for `gcc -lldap`, and otherwise
# not have any links [boo sr#501631]
rm -f "%{buildroot}/%{_libdir}"/libldap-2.4.so*
ln -fs libldap_r.so "%{buildroot}/%{_libdir}/libldap.so"
ln -s libldap_r-2.4.so.2 "%{buildroot}/%{_libdir}/libldap-2.4.so.2"
#ln -s libldap_r-2.4.so.2 "%{buildroot}/%{_libdir}/libldap-2.4.so.2"
%pre
getent group ldap >/dev/null || /usr/sbin/groupadd -g 70 -o -r ldap
@ -451,15 +447,6 @@ fi
%postun
%service_del_postun slapd.service
%triggerun -n libldap-2_4-2 -- libldap-2_4-2
if [ "$1" -eq 2 ]; then
# The %%postun from prior libldap versions calls ldconfig, which
# remembers libldap-2.4.so.2 as a symlink and will remove it, defeating
# rpm file tracking :-(
# Restore it.
ln -fs libldap_r-2.4.so.2 "%{_libdir}/libldap-2.4.so.2"
fi
%files
%defattr(-,root,root)
%config %{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/openldap