---
With respect to hints given in package review process:
https://bugzilla.redhat.com/show_bug.cgi?id=681558

 Makefile.am          |    9 +++++++--
 libvirt-snmp.spec.in |   14 ++++----------
 2 files changed, 11 insertions(+), 12 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index a38312e..ae1cd79 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -5,11 +5,16 @@ EXTRA_DIST = \
        autobuild.sh \
        autogen.sh
 
-rpm: clean gen-ChangeLog
+rpm: clean
                @(unset CDPATH ; $(MAKE) dist && rpmbuild -ta $(distdir).tar.gz)
 
 gen-ChangeLog:
                if [ -d .git ]; then \
-                       git log --oneline | sed 's/[0-9a-f]* \(.*\)/\1/' > 
ChangeLog; \
+                       git log --oneline | sed 's/[0-9a-f]* \(.*\)/\1/' > 
$(distdir)/ChangeLog; \
+               else \
+                       echo "Prevent non-empty ChangeLog" > 
$(distdir)/ChangeLog ;\
                fi
 
+.PHONY: gen-ChangeLog
+
+dist-hook: gen-ChangeLog
diff --git a/libvirt-snmp.spec.in b/libvirt-snmp.spec.in
index ed93e75..0591aa3 100644
--- a/libvirt-snmp.spec.in
+++ b/libvirt-snmp.spec.in
@@ -1,6 +1,6 @@
 Name:          libvirt-snmp
 Version:       @VERSION@
-Release:       1%{?dist}%{?extra_release}
+Release:       1%{?dist}
 Summary:       SNMP functionality for libvirt
 
 Group:         Development/Libraries
@@ -9,8 +9,7 @@ URL:            http://libvirt.org
 Source0:       
http://www.libvirt.org/sources/snmp/libvirt-snmp-%{version}.tar.gz
 BuildRoot:     %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
 
-BuildRequires: net-snmp-perl net-snmp net-snmp-utils net-snmp-devel 
libvirt-devel
-Requires:      net-snmp
+BuildRequires: net-snmp-perl net-snmp net-snmp-utils net-snmp-devel 
libvirt-devel
 
 %description
 Provides a way to control libvirt through SNMP protocol.
@@ -25,23 +24,18 @@ make %{?_smp_mflags}
 
 
 %install
-rm -rf $RPM_BUILD_ROOT
 make install DESTDIR=$RPM_BUILD_ROOT
 
 
-%clean
-rm -rf $RPM_BUILD_ROOT
-
-
 %files
 %defattr(-,root,root,-)
 %{_bindir}/libvirtMib_subagent
 %{_datadir}/snmp/mibs/LIBVIRT-MIB.txt
-%doc README NEWS ChangeLog AUTHORS
+%doc README NEWS ChangeLog AUTHORS src/LIBVIRT-MIB.txt
 %{_mandir}/man1/libvirtMib_subagent.1*
 
 
 %changelog
-* Thu Feb  2 2011 Michal Privoznik <mpriv...@redhat.com> 
0.0.1-1%{?dist}%{?extra_release}
+* Thu Feb  2 2011 Michal Privoznik <mpriv...@redhat.com> 0.0.1-1%{?dist}
 - initial revision
 
-- 
1.7.4

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list

Reply via email to