remove nscd
This commit is contained in:
parent
f33e41c1f9
commit
82785a936c
@ -1,38 +0,0 @@
|
|||||||
Short description: Add syslog.target dependency.
|
|
||||||
Author(s): Fedora glibc team <glibc@lists.fedoraproject.org>
|
|
||||||
Origin: PATCH
|
|
||||||
Bug-Fedora: #1070416
|
|
||||||
Upstream status: not-needed
|
|
||||||
|
|
||||||
Fedora-specific changes to the nscd.service file.
|
|
||||||
See also: glibc-nscd-sysconfig.patch.
|
|
||||||
|
|
||||||
--- a/nscd/nscd.service
|
|
||||||
+++ b/nscd/nscd.service
|
|
||||||
@@ -2,6 +2,7 @@
|
|
||||||
|
|
||||||
[Unit]
|
|
||||||
Description=Name Service Cache Daemon
|
|
||||||
+After=syslog.target
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=forking
|
|
||||||
@@ -17,3 +18,4 @@
|
|
||||||
|
|
||||||
[Install]
|
|
||||||
WantedBy=multi-user.target
|
|
||||||
+Also=nscd.socket
|
|
||||||
diff --git a/nscd/nscd.socket b/nscd/nscd.socket
|
|
||||||
new file mode 100644
|
|
||||||
index 0000000..7e512d5
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/nscd/nscd.socket
|
|
||||||
@@ -0,0 +1,8 @@
|
|
||||||
+[Unit]
|
|
||||||
+Description=Name Service Cache Daemon Socket
|
|
||||||
+
|
|
||||||
+[Socket]
|
|
||||||
+ListenDatagram=/var/run/nscd/socket
|
|
||||||
+
|
|
||||||
+[Install]
|
|
||||||
+WantedBy=sockets.target
|
|
||||||
92
glibc.spec
92
glibc.spec
@ -65,13 +65,12 @@
|
|||||||
##############################################################################
|
##############################################################################
|
||||||
Name: glibc
|
Name: glibc
|
||||||
Version: 2.35
|
Version: 2.35
|
||||||
Release: 1
|
Release: 2
|
||||||
Summary: The GNU libc libraries
|
Summary: The GNU libc libraries
|
||||||
License: %{all_license}
|
License: %{all_license}
|
||||||
URL: http://www.gnu.org/software/glibc/
|
URL: http://www.gnu.org/software/glibc/
|
||||||
|
|
||||||
Source0: https://ftp.gnu.org/gnu/glibc/%{name}-%{version}.tar.xz
|
Source0: https://ftp.gnu.org/gnu/glibc/%{name}-%{version}.tar.xz
|
||||||
Source1: nscd.conf
|
|
||||||
Source2: nsswitch.conf
|
Source2: nsswitch.conf
|
||||||
Source3: bench.mk
|
Source3: bench.mk
|
||||||
Source4: glibc-bench-compare
|
Source4: glibc-bench-compare
|
||||||
@ -83,8 +82,6 @@ Source7: replace_same_file_to_hard_link.py
|
|||||||
Source8: testsuite_whitelist.%{_target_cpu}
|
Source8: testsuite_whitelist.%{_target_cpu}
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
Patch0: glibc-1070416.patch
|
|
||||||
|
|
||||||
#Patch9000: turn-default-value-of-x86_rep_stosb_threshold_form_2K_to_1M.patch
|
#Patch9000: turn-default-value-of-x86_rep_stosb_threshold_form_2K_to_1M.patch
|
||||||
#Patch9001: delete-no-hard-link-to-avoid-all_language-package-to.patch
|
#Patch9001: delete-no-hard-link-to-avoid-all_language-package-to.patch
|
||||||
#Patch9002: 0001-add-base-files-for-libphtread-condition-family.patch
|
#Patch9002: 0001-add-base-files-for-libphtread-condition-family.patch
|
||||||
@ -97,6 +94,7 @@ Patch0: glibc-1070416.patch
|
|||||||
#Patch9009: 0008-add-pause_nocancel_2_17.patch
|
#Patch9009: 0008-add-pause_nocancel_2_17.patch
|
||||||
#Patch9010: 0009-add-unwind-with-longjmp.patch
|
#Patch9010: 0009-add-unwind-with-longjmp.patch
|
||||||
|
|
||||||
|
Obsoletes: nscd < 2.35
|
||||||
Provides: ldconfig rtld(GNU_HASH) bundled(gnulib)
|
Provides: ldconfig rtld(GNU_HASH) bundled(gnulib)
|
||||||
|
|
||||||
BuildRequires: audit-libs-devel >= 1.1.3, sed >= 3.95, libcap-devel, gettext
|
BuildRequires: audit-libs-devel >= 1.1.3, sed >= 3.95, libcap-devel, gettext
|
||||||
@ -255,24 +253,6 @@ The glibc-devel package contains the object files necessary for developing
|
|||||||
programs which use the standard C libraries. Besides, it contains the
|
programs which use the standard C libraries. Besides, it contains the
|
||||||
headers. Thus, it is necessory to install glibc-devel if you ned develop programs.
|
headers. Thus, it is necessory to install glibc-devel if you ned develop programs.
|
||||||
|
|
||||||
##############################################################################
|
|
||||||
# glibc "nscd" sub-package
|
|
||||||
##############################################################################
|
|
||||||
%package -n nscd
|
|
||||||
Summary: Name caching service daemon.
|
|
||||||
Requires: %{name} = %{version}-%{release}
|
|
||||||
%if %{without bootstrap}
|
|
||||||
Requires: libselinux >= 1.17.10-1
|
|
||||||
%endif
|
|
||||||
Requires: audit-libs >= 1.1.3
|
|
||||||
Requires(pre): shadow-utils, coreutils
|
|
||||||
Requires: systemd
|
|
||||||
Requires(postun): shadow-utils
|
|
||||||
|
|
||||||
%description -n nscd
|
|
||||||
The nscd package is able to daemon caches name service lookups and improve
|
|
||||||
the performance with LDAP.
|
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
# nss modules sub-package
|
# nss modules sub-package
|
||||||
##############################################################################
|
##############################################################################
|
||||||
@ -457,7 +437,8 @@ pushd $builddir
|
|||||||
%if 0%{rpm_version_ge_412}
|
%if 0%{rpm_version_ge_412}
|
||||||
--disable-crypt \
|
--disable-crypt \
|
||||||
%endif
|
%endif
|
||||||
||
|
--disable-build-nscd \
|
||||||
|
--disable-nscd ||
|
||||||
{ cat config.log; false; }
|
{ cat config.log; false; }
|
||||||
|
|
||||||
make %{?_smp_mflags} -O -r %{glibc_make_flags}
|
make %{?_smp_mflags} -O -r %{glibc_make_flags}
|
||||||
@ -549,20 +530,11 @@ install -p -m 644 %{SOURCE2} $RPM_BUILD_ROOT/etc/nsswitch.conf
|
|||||||
install -p -m 755 build-%{target}/nptl/libpthread-2.17.so $RPM_BUILD_ROOT%{_libdir}
|
install -p -m 755 build-%{target}/nptl/libpthread-2.17.so $RPM_BUILD_ROOT%{_libdir}
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# This is for ncsd - in glibc 2.2
|
|
||||||
install -m 644 nscd/nscd.conf $RPM_BUILD_ROOT/etc
|
|
||||||
mkdir -p $RPM_BUILD_ROOT%{_tmpfilesdir}
|
|
||||||
install -m 644 %{SOURCE1} %{buildroot}%{_tmpfilesdir}
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/lib/systemd/system
|
|
||||||
install -m 644 nscd/nscd.service nscd/nscd.socket $RPM_BUILD_ROOT/lib/systemd/system
|
|
||||||
|
|
||||||
# Include ld.so.conf
|
# Include ld.so.conf
|
||||||
echo 'include ld.so.conf.d/*.conf' > $RPM_BUILD_ROOT/etc/ld.so.conf
|
echo 'include ld.so.conf.d/*.conf' > $RPM_BUILD_ROOT/etc/ld.so.conf
|
||||||
truncate -s 0 $RPM_BUILD_ROOT/etc/ld.so.cache
|
truncate -s 0 $RPM_BUILD_ROOT/etc/ld.so.cache
|
||||||
chmod 644 $RPM_BUILD_ROOT/etc/ld.so.conf
|
chmod 644 $RPM_BUILD_ROOT/etc/ld.so.conf
|
||||||
mkdir -p $RPM_BUILD_ROOT/etc/ld.so.conf.d
|
mkdir -p $RPM_BUILD_ROOT/etc/ld.so.conf.d
|
||||||
mkdir -p $RPM_BUILD_ROOT/etc/sysconfig
|
|
||||||
truncate -s 0 $RPM_BUILD_ROOT/etc/sysconfig/nscd
|
|
||||||
truncate -s 0 $RPM_BUILD_ROOT/etc/gai.conf
|
truncate -s 0 $RPM_BUILD_ROOT/etc/gai.conf
|
||||||
|
|
||||||
# Include %{_libdir}/gconv/gconv-modules.cache
|
# Include %{_libdir}/gconv/gconv-modules.cache
|
||||||
@ -614,10 +586,6 @@ popd
|
|||||||
rm -f $RPM_BUILD_ROOT%{_infodir}/dir
|
rm -f $RPM_BUILD_ROOT%{_infodir}/dir
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/var/{db,run}/nscd
|
|
||||||
touch $RPM_BUILD_ROOT/var/{db,run}/nscd/{passwd,group,hosts,services}
|
|
||||||
touch $RPM_BUILD_ROOT/var/run/nscd/{socket,nscd.pid}
|
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT%{_libdir}
|
mkdir -p $RPM_BUILD_ROOT%{_libdir}
|
||||||
mv -f $RPM_BUILD_ROOT/%{_lib}/lib{pcprofile,memusage}.so \
|
mv -f $RPM_BUILD_ROOT/%{_lib}/lib{pcprofile,memusage}.so \
|
||||||
$RPM_BUILD_ROOT%{_libdir}
|
$RPM_BUILD_ROOT%{_libdir}
|
||||||
@ -646,7 +614,6 @@ touch master.filelist
|
|||||||
touch glibc.filelist
|
touch glibc.filelist
|
||||||
touch common.filelist
|
touch common.filelist
|
||||||
touch devel.filelist
|
touch devel.filelist
|
||||||
touch nscd.filelist
|
|
||||||
touch nss_modules.filelist
|
touch nss_modules.filelist
|
||||||
touch nss-devel.filelist
|
touch nss-devel.filelist
|
||||||
touch libnsl.filelist
|
touch libnsl.filelist
|
||||||
@ -700,7 +667,6 @@ cat master.filelist \
|
|||||||
-e '%{_libdir}/lib.*\.a' \
|
-e '%{_libdir}/lib.*\.a' \
|
||||||
-e '%{_libdir}/.*\.o' \
|
-e '%{_libdir}/.*\.o' \
|
||||||
-e '%{_libdir}/lib.*\.so' \
|
-e '%{_libdir}/lib.*\.so' \
|
||||||
-e 'nscd' \
|
|
||||||
-e '%{_prefix}/bin' \
|
-e '%{_prefix}/bin' \
|
||||||
-e '%{_prefix}/lib/locale' \
|
-e '%{_prefix}/lib/locale' \
|
||||||
-e '%{_prefix}/sbin/[^i]' \
|
-e '%{_prefix}/sbin/[^i]' \
|
||||||
@ -727,8 +693,7 @@ echo '%{_libdir}/libpcprofile.so' >> glibc.filelist
|
|||||||
##############################################################################
|
##############################################################################
|
||||||
grep '%{_prefix}/bin' master.filelist > common.filelist
|
grep '%{_prefix}/bin' master.filelist > common.filelist
|
||||||
grep '%{_prefix}/sbin' master.filelist \
|
grep '%{_prefix}/sbin' master.filelist \
|
||||||
| grep -v '%{_prefix}/sbin/iconvconfig' \
|
| grep -v '%{_prefix}/sbin/iconvconfig' >> common.filelist
|
||||||
| grep -v 'nscd' >> common.filelist
|
|
||||||
|
|
||||||
grep '%{_prefix}/share' master.filelist \
|
grep '%{_prefix}/share' master.filelist \
|
||||||
| grep -v \
|
| grep -v \
|
||||||
@ -760,11 +725,6 @@ grep '%{_libdir}/lib.*\.a' < master.filelist \
|
|||||||
>> devel.filelist
|
>> devel.filelist
|
||||||
|
|
||||||
|
|
||||||
##############################################################################
|
|
||||||
# glibc "nscd" sub-package
|
|
||||||
##############################################################################
|
|
||||||
echo '%{_prefix}/sbin/nscd' > nscd.filelist
|
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
# nss modules sub-package
|
# nss modules sub-package
|
||||||
##############################################################################
|
##############################################################################
|
||||||
@ -1070,24 +1030,6 @@ if [ -L %{_prefix}/include/scsi ] ; then
|
|||||||
rm -f %{_prefix}/include/scsi
|
rm -f %{_prefix}/include/scsi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
%pre -n nscd
|
|
||||||
getent group nscd >/dev/null || /usr/sbin/groupadd -g 28 -r nscd
|
|
||||||
getent passwd nscd >/dev/null ||
|
|
||||||
/usr/sbin/useradd -M -o -r -d / -s /sbin/nologin \
|
|
||||||
-c "NSCD Daemon" -u 28 -g nscd nscd
|
|
||||||
|
|
||||||
%post -n nscd
|
|
||||||
%systemd_post nscd.service
|
|
||||||
|
|
||||||
%preun -n nscd
|
|
||||||
%systemd_preun nscd.service
|
|
||||||
|
|
||||||
%postun -n nscd
|
|
||||||
if test $1 = 0; then
|
|
||||||
/usr/sbin/userdel nscd > /dev/null 2>&1 || :
|
|
||||||
fi
|
|
||||||
%systemd_postun_with_restart nscd.service
|
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
# Files list
|
# Files list
|
||||||
##############################################################################
|
##############################################################################
|
||||||
@ -1137,25 +1079,6 @@ fi
|
|||||||
|
|
||||||
%files -f devel.filelist devel
|
%files -f devel.filelist devel
|
||||||
|
|
||||||
%files -f nscd.filelist -n nscd
|
|
||||||
%config(noreplace) /etc/nscd.conf
|
|
||||||
%dir %attr(0755,root,root) /var/run/nscd
|
|
||||||
%dir %attr(0755,root,root) /var/db/nscd
|
|
||||||
/lib/systemd/system/nscd.service
|
|
||||||
/lib/systemd/system/nscd.socket
|
|
||||||
%{_tmpfilesdir}/nscd.conf
|
|
||||||
%attr(0644,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/run/nscd/nscd.pid
|
|
||||||
%attr(0666,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/run/nscd/socket
|
|
||||||
%attr(0600,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/run/nscd/passwd
|
|
||||||
%attr(0600,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/run/nscd/group
|
|
||||||
%attr(0600,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/run/nscd/hosts
|
|
||||||
%attr(0600,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/run/nscd/services
|
|
||||||
%attr(0600,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/db/nscd/passwd
|
|
||||||
%attr(0600,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/db/nscd/group
|
|
||||||
%attr(0600,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/db/nscd/hosts
|
|
||||||
%attr(0600,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) /var/db/nscd/services
|
|
||||||
%ghost %config(missingok,noreplace) /etc/sysconfig/nscd
|
|
||||||
|
|
||||||
%files -f nss_modules.filelist -n nss_modules
|
%files -f nss_modules.filelist -n nss_modules
|
||||||
/var/db/Makefile
|
/var/db/Makefile
|
||||||
|
|
||||||
@ -1183,6 +1106,11 @@ fi
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Feb 10 2022 jiangheng12 <jiangheng12@huawei.com> - 2.35-2
|
||||||
|
- remove nscd; The functionality nscd currently provides can be
|
||||||
|
achieved by using systemd-resolved for DNS caching and the sssd
|
||||||
|
daemon for everything else
|
||||||
|
|
||||||
* Tue Feb 8 2022 Qingqing Li <liqingqing3@huawei.com> - 2.35-1
|
* Tue Feb 8 2022 Qingqing Li <liqingqing3@huawei.com> - 2.35-1
|
||||||
- upgrade to 2.35
|
- upgrade to 2.35
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user