SPECS: nut.spec - better way of installing _confdata/*

sls sls at pld-linux.org
Thu Jul 26 12:46:47 CEST 2007


Author: sls                          Date: Thu Jul 26 10:46:47 2007 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- better way of installing _confdata/*

---- Files affected:
SPECS:
   nut.spec (1.130 -> 1.131) 

---- Diffs:

================================================================
Index: SPECS/nut.spec
diff -u SPECS/nut.spec:1.130 SPECS/nut.spec:1.131
--- SPECS/nut.spec:1.130	Wed Jul 25 22:27:07 2007
+++ SPECS/nut.spec	Thu Jul 26 12:46:42 2007
@@ -210,16 +210,9 @@
 install %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/upsmon
 install %{SOURCE4} $RPM_BUILD_ROOT/etc/sysconfig/upsmon
 
-rm -rf $RPM_BUILD_ROOT%{_sysconfdir}/*
-install conf/upsd.users.sample $RPM_BUILD_ROOT%{_sysconfdir}/upsd.users
-install conf/hosts.conf.sample $RPM_BUILD_ROOT%{_sysconfdir}/hosts.conf
-install conf/ups.conf.sample $RPM_BUILD_ROOT%{_sysconfdir}/ups.conf
-install conf/upsd.conf.sample $RPM_BUILD_ROOT%{_sysconfdir}/upsd.conf
-install conf/upsmon.conf.sample $RPM_BUILD_ROOT%{_sysconfdir}/upsmon.conf
-install conf/upssched.conf.sample $RPM_BUILD_ROOT%{_sysconfdir}/upssched.conf
-install conf/upsset.conf.sample $RPM_BUILD_ROOT%{_sysconfdir}/upsset.conf
-install conf/upsstats.html.sample $RPM_BUILD_ROOT%{_sysconfdir}/upsstats.html
-install conf/upsstats-single.html.sample $RPM_BUILD_ROOT%{_sysconfdir}/upsstats-single.html
+for i in $RPM_BUILD_ROOT%{_sysconfdir}/*.sample; do
+	mv -f $i ${i%.sample}
+done
 
 install clients/upsclient.o common/parseconf.o $RPM_BUILD_ROOT%{_libdir}
 install clients/upsclient.h include/parseconf.h $RPM_BUILD_ROOT%{_includedir}/nut
@@ -430,6 +423,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.131  2007/07/26 10:46:42  sls
+- better way of installing _confdata/*
+
 Revision 1.130  2007/07/25 20:27:07  sls
 - added bcond cgi
 - remove BR: libpng-devel and xorg-lib-libXpm-devel (both required by gd-devel)
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/nut.spec?r1=1.130&r2=1.131&f=u



More information about the pld-cvs-commit mailing list