rpms/libvirt/FC-6 libvirt.spec,1.40,1.41 sources,1.18,1.19

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Mon Mar 19 09:33:44 UTC 2007


Author: veillard

Update of /cvs/dist/rpms/libvirt/FC-6
In directory cvs.devel.redhat.com:/tmp/cvs-serv15197

Modified Files:
	libvirt.spec sources 
Log Message:
Push 0.2.1, Daniel



Index: libvirt.spec
===================================================================
RCS file: /cvs/dist/rpms/libvirt/FC-6/libvirt.spec,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -r1.40 -r1.41
--- libvirt.spec	15 Feb 2007 16:57:19 -0000	1.40
+++ libvirt.spec	19 Mar 2007 09:33:41 -0000	1.41
@@ -1,9 +1,15 @@
 # -*- rpm-spec -*-
 
+# This macro is used for the continuous automated builds. It just
+# allows an extra fragment based on the timestamp to be appended
+# to the release. This distinguishes automated builds, from formal
+# Fedora RPM builds
+%define _extra_release %{?dist:%{dist}}%{!?dist:%{?extra_release:%{extra_release}}}
+
 Summary: Library providing an API to use the Xen virtualization
 Name: libvirt
-Version: 0.2.0
-Release: 2%{?dist}
+Version: 0.2.1
+Release: 1%{?_extra_release}
 License: LGPL
 Group: Development/Libraries
 Source: libvirt-%{version}.tar.gz
@@ -20,12 +26,9 @@
 BuildRequires: ncurses-devel
 BuildRequires: gettext
 BuildRequires: libsysfs-devel
-BuildRequires: gnutls-devel
+BuildRequires: /sbin/iptables
 Obsoletes: libvir
 ExclusiveArch: i386 x86_64 ia64
-Patch0: libvirt-0.2.0-Werror.patch
-Patch1: libvirt-0.2.0-pvfb-new-config.patch
-Patch2: libvirt-0.2.0-qemu-fixes.patch
 
 %description
 This C library provides an API to use the Xen virtualization framework,
@@ -55,12 +58,9 @@
 
 %prep
 %setup -q
-%patch0 -p1
-%patch1 -p1
-%patch2 -p1
 
 %build
-%configure
+%configure --with-init-script=redhat --with-qemud-pid-file=%{_localstatedir}/run/libvirt_qemud.pid
 make
 
 %install
@@ -72,8 +72,18 @@
 rm -f $RPM_BUILD_ROOT%{_libdir}/*.a
 rm -f $RPM_BUILD_ROOT%{_libdir}/python*/site-packages/*.la
 rm -f $RPM_BUILD_ROOT%{_libdir}/python*/site-packages/*.a
-install -d -m 0755 $RPM_BUILD_ROOT%{_sysconfdir}/libvirt/qemu/networks/
 install -d -m 0755 $RPM_BUILD_ROOT%{_localstatedir}/run/libvirt/
+
+# We don't want to install /etc/libvirt/qemu/networks in the main %files list
+# because if the admin wants to delete the default network completely, we don't
+# want to end up re-incarnating it on every RPM upgrade.
+install -d -m 0755 $RPM_BUILD_ROOT%{_datadir}/libvirt/networks/
+cp $RPM_BUILD_ROOT%{_sysconfdir}/libvirt/qemu/networks/default.xml \
+   $RPM_BUILD_ROOT%{_datadir}/libvirt/networks/default.xml
+rm -f $RPM_BUILD_ROOT%{_sysconfdir}/libvirt/qemu/networks/default.xml
+rm -f $RPM_BUILD_ROOT%{_sysconfdir}/libvirt/qemu/networks/autostart/default.xml
+# Strip auto-generated UUID - we need it generated per-install
+sed -i -e "/<uuid>/d" $RPM_BUILD_ROOT%{_datadir}/libvirt/networks/default.xml
 %find_lang %{name}
 
 %clean
@@ -82,6 +92,27 @@
 %post
 /sbin/ldconfig
 
+# We want to install the default network for initial RPM installs
+# or on the first upgrade from a non-network aware libvirt only.
+# We check this by looking to see if the daemon is already installed
+/sbin/chkconfig --list libvirtd 1>/dev/null 2>&1
+if [ $? != 0 ]
+then
+    UUID=`/usr/bin/uuidgen`
+    sed -e "s,</name>,</name>\n  <uuid>$UUID</uuid>," \
+         < %{_datadir}/libvirt/networks/default.xml \
+         > %{_sysconfdir}/libvirt/qemu/networks/default.xml
+    ln -s ../default.xml %{_sysconfdir}/libvirt/qemu/networks/autostart/default.xml
+fi
+
+/sbin/chkconfig --add libvirtd
+
+%preun
+if [ $1 = 0 ]; then
+    /sbin/service libvirtd stop 1>/dev/null 2>&1
+    /sbin/chkconfig --del libvirtd
+fi
+
 %postun
 /sbin/ldconfig
 
@@ -92,10 +123,17 @@
 %doc %{_mandir}/man1/virsh.1*
 %{_bindir}/virsh
 %{_libdir}/lib*.so.*
-%config %{_sysconfdir}/libvirt/qemu/networks/
-%{_localstatedir}/run/libvirt/
+%dir %attr(0700, root, root) %{_sysconfdir}/libvirt/
+%dir %attr(0700, root, root) %{_sysconfdir}/libvirt/qemu/
+%dir %attr(0700, root, root) %{_sysconfdir}/libvirt/qemu/networks/
+%{_sysconfdir}/rc.d/init.d/libvirtd
+%dir %{_datadir}/libvirt/
+%dir %{_datadir}/libvirt/networks/
+%{_datadir}/libvirt/networks/default.xml
+%dir %{_localstatedir}/run/libvirt/
+%dir %{_localstatedir}/lib/libvirt/
 %attr(4755, root, root) %{_libexecdir}/libvirt_proxy
-%attr(0755, root, root) %{_libexecdir}/libvirt_qemud
+%attr(0755, root, root) %{_sbindir}/libvirt_qemud
 %doc docs/libvirt.rng
 
 %files devel
@@ -125,6 +163,13 @@
 %doc docs/examples/python
 
 %changelog
+* Fri Mar 16 2007 Daniel Veillard <veillard at redhat.com> - 2.0.1-1.fc6
+- Release of 0.2.1
+- lot of bug and portability fixes
+- Add support for network autostart and init scripts
+- New API to detect the virtualization capabilities of a host
+- Documentation updates
+
 * Thu Feb 15 2007 Daniel P. Berrange <berrange at redhat.com> - 0.2.0-2.fc6
 - Force use of new PVFB config style
 - Fixed path to qemu daemon for autostart


Index: sources
===================================================================
RCS file: /cvs/dist/rpms/libvirt/FC-6/sources,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- sources	14 Feb 2007 19:14:32 -0000	1.18
+++ sources	19 Mar 2007 09:33:41 -0000	1.19
@@ -1 +1 @@
-65dd1d2da9bfb304a4e4a69b058cda9f  libvirt-0.2.0.tar.gz
+c5ff72800c3540d486489fec2df737b3  libvirt-0.2.1.tar.gz




More information about the fedora-cvs-commits mailing list