[packages/bind] Use relative symlinks, remove %attr for symlinks

glen glen at pld-linux.org
Sat Feb 27 21:19:54 CET 2021


commit bf478371683c84f5ab0a5c76d8b93427e2c3992a
Author: Elan Ruusamäe <glen at pld-linux.org>
Date:   Sat Feb 27 22:04:20 2021 +0200

    Use relative symlinks, remove %attr for symlinks
    
    All for rpm 4.16 compatibility:
    
    - Explicit %attr() mode not applicable to symlink
    - Absolute symlink

 bind.spec | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)
---
diff --git a/bind.spec b/bind.spec
index 540b351..ee74609 100644
--- a/bind.spec
+++ b/bind.spec
@@ -477,10 +477,10 @@ cp -p %{SOURCE9}			$RPM_BUILD_ROOT%{_var}/lib/named/M/localhost.zone
 cp -p %{SOURCE10}			$RPM_BUILD_ROOT%{_var}/lib/named%{_sysconfdir}/named.conf
 %{__mv} $RPM_BUILD_ROOT/etc/bind.keys   $RPM_BUILD_ROOT%{_var}/lib/named%{_sysconfdir}/
 
-ln -sf %{_var}/lib/named%{_sysconfdir}/named.conf $RPM_BUILD_ROOT/etc/named.conf
-ln -sf %{_var}/lib/named%{_sysconfdir}/bind.keys $RPM_BUILD_ROOT/etc/bind.keys
-ln -sf %{_var}/lib/named/named.log	$RPM_BUILD_ROOT%{_var}/log/named
-ln -sf %{_var}/lib/named/named.stats	$RPM_BUILD_ROOT%{_var}/log/named.stats
+ln -sf --relative $RPM_BUILD_ROOT%{_var}/lib/named%{_sysconfdir}/named.conf $RPM_BUILD_ROOT/etc/named.conf
+ln -sf --relative $RPM_BUILD_ROOT%{_var}/lib/named%{_sysconfdir}/bind.keys $RPM_BUILD_ROOT/etc/bind.keys
+ln -sf --relative $RPM_BUILD_ROOT%{_var}/lib/named/named.log	$RPM_BUILD_ROOT%{_var}/log/named
+ln -sf --relative $RPM_BUILD_ROOT%{_var}/lib/named/named.stats	$RPM_BUILD_ROOT%{_var}/log/named.stats
 
 touch $RPM_BUILD_ROOT%{_var}/lib/named/named.{log,stats}
 
@@ -554,9 +554,9 @@ fi
 %{systemdunitdir}/named.service
 %attr(754,root,root) /etc/rc.d/init.d/named
 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/named
-%attr(640,root,named) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/named.conf
-%attr(640,root,named) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/bind.keys
 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/named
+%{_sysconfdir}/named.conf
+%{_sysconfdir}/bind.keys
 
 %attr(755,root,root) %{_sbindir}/ddns-confgen
 %attr(755,root,root) %{_sbindir}/dnssec-*
@@ -595,8 +595,8 @@ fi
 %attr(660,named,named) %ghost %{_var}/lib/named/named.log
 %attr(660,named,named) %ghost %{_var}/lib/named/named.stats
 
-%attr(660,named,named) %config(noreplace,missingok) %verify(not md5 mtime size) %{_var}/log/named
-%attr(660,named,named) %config(noreplace,missingok) %verify(not md5 mtime size) %{_var}/log/named.stats
+%config(noreplace,missingok) %{_var}/log/named
+%config(noreplace,missingok) %{_var}/log/named.stats
 
 %attr(770,root,named) %dir %{_var}/run/named
 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/bind.git/commitdiff/bf478371683c84f5ab0a5c76d8b93427e2c3992a



More information about the pld-cvs-commit mailing list