rpms/pdns-recursor/devel pdns-recursor-fixsysconfdir.patch, 1.7, 1.8 pdns-recursor.spec, 1.17, 1.18

Ruben Kerkhof ruben at fedoraproject.org
Sun Mar 14 14:44:09 UTC 2010


Author: ruben

Update of /cvs/pkgs/rpms/pdns-recursor/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv25659

Modified Files:
	pdns-recursor-fixsysconfdir.patch pdns-recursor.spec 
Log Message:
* Sun Mar 14 2010 Ruben Kerkhof <ruben at rubenkerkhof.com> 3.2-1
- Upstream released new version
- Adjust scriptlets to packaging guidelines


pdns-recursor-fixsysconfdir.patch:
 config.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: pdns-recursor-fixsysconfdir.patch
===================================================================
RCS file: /cvs/pkgs/rpms/pdns-recursor/devel/pdns-recursor-fixsysconfdir.patch,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -p -r1.7 -r1.8
--- pdns-recursor-fixsysconfdir.patch	1 Mar 2010 16:15:25 -0000	1.7
+++ pdns-recursor-fixsysconfdir.patch	14 Mar 2010 14:44:09 -0000	1.8
@@ -5,5 +5,5 @@ diff -up pdns-recursor-3.2-rc2/config.h.
 -#define SYSCONFDIR "/etc/powerdns/" 
 +#define SYSCONFDIR "/etc/pdns-recursor/" 
  #define LOCALSTATEDIR "/var/run/" 
- #define VERSION "3.2-rc2"
+ #define VERSION "3.2"
  #define RECURSOR


Index: pdns-recursor.spec
===================================================================
RCS file: /cvs/pkgs/rpms/pdns-recursor/devel/pdns-recursor.spec,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -p -r1.17 -r1.18
--- pdns-recursor.spec	1 Mar 2010 16:15:25 -0000	1.17
+++ pdns-recursor.spec	14 Mar 2010 14:44:09 -0000	1.18
@@ -1,13 +1,11 @@
-%global alphatag rc2
-
 Summary:		Modern, advanced and high performance recursing/non authoritative nameserver
 Name:			pdns-recursor
 Version:		3.2
-Release:		0.1.%{alphatag}%{?dist}
+Release:		1%{?dist}
 Group:			System Environment/Daemons
 License:		GPLv2
 URL:			http://powerdns.com
-Source0:		http://svn.powerdns.com/snapshots/rc2/%{name}-%{version}-%{alphatag}.tar.bz2
+Source0:		http://downloads.powerdns.com/releases/%{name}-%{version}.tar.bz2
 Source1:		pdns-recursor.init	
 
 Patch0:			pdns-recursor-fixmakefile.patch
@@ -15,15 +13,16 @@ Patch1:			pdns-recursor-fixsysconfdir.pa
 
 Provides:		powerdns-recursor = %{version}-%{release}
 BuildRequires:		boost-devel, lua-devel
-Requires(post):		/sbin/chkconfig
-Requires(preun):	/sbin/chkconfig, /sbin/service
+Requires(pre):          shadow-utils
+Requires(post):		chkconfig
+Requires(preun):	chkconfig, initscripts 
 
 %description
 PowerDNS Recursor is a non authoritative/recursing DNS server. Use this
 package if you need a dns cache for your network.
 
 %prep
-%setup -q -n %{name}-%{version}-%{alphatag}
+%setup -q
 %patch0 -p1 -b .fixmakefile
 %patch1 -p1 -b .fixsysconfdir
 
@@ -42,23 +41,25 @@ make install DESTDIR=%{buildroot} CONFIG
 sed -i '1i\setuid=pdns-recursor' %{buildroot}%{_sysconfdir}/%{name}/recursor.conf
 sed -i '2i\setgid=pdns-recursor' %{buildroot}%{_sysconfdir}/%{name}/recursor.conf
 
+%pre
+getent group pdns-recursor > /dev/null || groupadd -r pdns-recursur
+getent passwd pdns-recursor > /dev/null || \
+    useradd -r -g pdns-recursor -d / -s /sbin/nologin \
+    -c "PwerDNS Recursor user" pdns-recursor
+exit 0
+
 %post
-if [ $1 -eq 1 ]; then
-	/sbin/chkconfig --add %{name}
-	userid=`id -u pdns-recursor 2>/dev/null`
-	if [ x"$userid" = x ]; then
-		%{_sbindir}/useradd -c "PowerDNS Recursor user" -s /sbin/nologin -r -d / pdns-recursor >/dev/null 2>&1 || :
-	fi
-fi
+chkconfig --add %{name}
+
 %preun
 if [ $1 -eq 0 ]; then
-	/sbin/service %{name} stop >/dev/null 2>&1 || :
-	/sbin/chkconfig --del %{name}
+    service %{name} stop >/dev/null 2>&1 || :
+    chkconfig --del %{name}
 fi
 
 %postun
 if [ $1 -ge 1 ]; then
-	/sbin/service %{name} condrestart >/dev/null 2>&1 || :
+    service %{name} condrestart >/dev/null 2>&1 || :
 fi
 
 %clean
@@ -77,6 +78,10 @@ fi
 
 
 %changelog
+* Sun Mar 14 2010 Ruben Kerkhof <ruben at rubenkerkhof.com> 3.2-1
+- Upstream released new version
+- Adjust scriptlets to packaging guidelines
+
 * Mon Mar 01 2010 Ruben Kerkhof <ruben at rubenkerkhof.com> 3.2-0.1.rc2
 - Upstream released new version
 



More information about the scm-commits mailing list