Blob Blame History Raw
%{!?python_sitelib: %define python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}

# 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}}}

%define appname virtinst

Summary: Python modules for starting Xen guest installations
Name: python-%{appname}
Version: 0.300.2
Release: 3%{_extra_release}
Source0: http://virt-manager.org/download/sources/%{appname}/%{appname}-%{version}.tar.gz

Patch1: %{appname}-%{version}-satellite-distro.patch
Patch2: %{appname}-%{version}-virt-clone-disk.patch
Patch3: %{appname}-%{version}-acpi.patch
Patch4: %{appname}-%{version}-noreboot.patch
Patch5: %{appname}-%{version}-satellite-distro-fix.patch
Patch6: %{appname}-%{version}-force-option.patch
Patch7: %{appname}-%{version}-remove-file-exist-check.patch
Patch8: %{appname}-%{version}-install-f9.patch

License: GPLv2+
Group: Development/Libraries
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
ExcludeArch: ppc ppc64 s390 s390x
Url: http://virt-manager.org/
Provides: virtinst
Requires: libvirt-python >= 0.2.1
# Disabled to allow minimal non-X installs
#Requires: virt-viewer
Requires: urlgrabber
Requires: libxml2-python
Requires: python-urlgrabber
BuildRequires: python-devel
BuildRequires: libxml2-python
BuildRequires: python-urlgrabber
BuildRequires: libvirt-python
BuildRequires: gettext
Obsoletes: python-xeninst < 0.97.0

%description
virtinst is a module to help in starting installations of Fedora/Red
Hat Enterprise Linux related distributions inside of virtual machines.  It
supports both paravirt guests (for which only FC and RHEL guests are
currently supported) as well as fully virtualized guests.  It uses
libvirt (http://www.libvirt.org) for starting things.

Also contained is a simple script virt-install which uses
virtinst in a command line mode.

%prep
%setup -q -n %{appname}-%{version}
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1
%patch7 -p1
%patch8 -p1

%build
python setup.py build

%install
rm -rf $RPM_BUILD_ROOT
python setup.py install -O1 --root=$RPM_BUILD_ROOT
# Back compat in case people hardcoded old /usr/sbin/virt-install location
mkdir -p $RPM_BUILD_ROOT/%{_sbindir}
ln -s ../bin/virt-install $RPM_BUILD_ROOT/%{_sbindir}/virt-install

%find_lang %{appname} || echo 0

%clean
rm -rf $RPM_BUILD_ROOT

%files -f %{appname}.lang
%defattr(-,root,root)
%doc README AUTHORS NEWS ChangeLog doc/image.rng doc/example1.xml
%dir %{python_sitelib}/%{appname}
%{python_sitelib}/%{appname}/*
%{_mandir}/man1/*
%{_mandir}/man5/*
%{_sbindir}/virt-install
%{_bindir}/virt-install
%{_bindir}/virt-clone
%{_bindir}/virt-image

%changelog
* Wed Mar 19 2008 Daniel P. Berrange <berrange@redhat.com> - 0.300.2-3.fc7
- Fix file check to allow installing rawhide/f9 guests
- Add --force option to cli utils to not prompt for input.
- Remove check for file existence in cli utils, breaks scripts.
- Bring satellite distro patch up to speed with current internal API
- Add --noreboot option accidentally lost
- Fix ACPI default value to be enabled
- Fix virt-clone disk validation from breaking all use of the tool.

* Thu Jan 31 2008 Daniel P. Berrange <berrange@redhat.com> - 0.300.2-2.fc7
- Disable virt-viewer dep to allow non-X installs (rhbz #387971)

* Thu Jan 10 2008 Daniel P. Berrange <berrange@redhat.com> - 0.300.2.1.fc7
- Update to 0.300.2 release

* Tue Nov 20 2007 Daniel P. Berrange <berrange@redhat.com> - 0.200.0-4.fc7
- Fixed install of F8 distros (rhbz 391211)
- Fixed validity checking of NFS locations (rhbz 370221)

* Thu Sep  6 2007 Daniel P. Berrange <berrange@redhat.com> - 0.200.0-3.fc7
- Fixed CDROM source post-install (rhbz #260981)
- Fixed kernel for post-install config with KVM guests

* Thu Jul 26 2007 Daniel P. Berrange <berrange@redhat.com> - 0.200.0-2.fc7
- Fixed default architecture

* Tue Jul 18 2007 Daniel P. Berrange <berrange@redhat.com> - 0.200.0-1.fc7
- Updated to 0.200.0
- Added virt-clone tool
- Added manual pages

* Tue May  1 2007 Daniel P. Berrange <berrange@redhat.com> - 0.103.0-3.fc7
- Fixed module import when using --accelerate
- Fixed detection of RHEL5 client distro
- Fixed default 'network's selection & default URI choice to
  not be Xen specific
- Fixed features XML when using initrd for fullvirt

* Tue Apr 17 2007 Mark McLoughlin <markmc@redhat.com> - 0.103.0-2.fc7
- Fix urlgrabber import error

* Mon Apr 16 2007 Daniel P. Berrange <berrange@redhat.com> - 0.103.0-1.fc7
- Updated to 0.103.0 release
- More validation of UUIDs
- Automatically reboot Windows guests with CDROM still attached
- Allow '-'  in guest names
- Adjust way distro detection is done

* Tue Mar 20 2007 Daniel P. Berrange <berrange@redhat.com> - 0.102.0-1.fc7
- Updated to 0.102.0 release

* Thu Mar  8 2007 Daniel P. Berrange <berrange@redhat.com> - 0.101.0-4.fc7
- Fixed install of paravirt Xen guests

* Fri Mar  2 2007 Daniel P. Berrange <berrange@redhat.com> - 0.101.0-3.fc7
- Fixed restart of guests after install completes

* Tue Feb 20 2007 Daniel P. Berrange <berrange@redhat.com> - 0.101.0-2.fc7
- Remove obsolete patches

* Tue Feb 20 2007 Daniel P. Berrange <berrange@redhat.com> - 0.101.0-1.fc7
- Updated to 0.101.0 to enable QEMU support

* Thu Jan 25 2007 Daniel P. Berrange <berrange@redhat.com> - 0.100.0-3.fc7
- Make back-compat with old APIs for Cobbler sanity

* Thu Jan 25 2007 Daniel P. Berrange <berrange@redhat.com> - 0.100.0-2.fc7
- Fix errors with NFS mount based installs

* Mon Jan 22 2007 Daniel P. Berrange <berrange@redhat.com> - 0.100.0-1.fc7
- Updated to 0.100.0 which now uses libvirt inactive domain support
  needed to operate correctly against xen 3.0.4

* Tue Dec 18 2006 Daniel P. Berrange <berrange@redhat.com> - 0.98.0-3.fc7
- don't traceback on invalid memory param (gcosta, #219270)
- let the console come back quicker to help with HVM installs (#212024)

* Thu Dec  7 2006 Jeremy Katz <katzj@redhat.com> - 0.98.0-2
- rebuild for python 2.5

* Thu Nov 30 2006 Jeremy Katz <katzj@redhat.com> - 0.98.0-1
- add support for creating nonsparse disk images (#217764)
- remove xeninst compat bits

* Mon Nov 20 2006 Jeremy Katz <katzj@redhat.com> - 0.97.0-1
- handle multiple nics/disks on virt-install command line (#215726)
- buildrequire python

* Wed Oct 18 2006 Jeremy Katz <katzj@redhat.com> - 0.96.0-1
- improve check for if a machine is hvm capable to catch when support isn't
  allowed by the bios (#211276)
- cleanup after nfs mount failure on pv install (#206196)
- support for setting vcpus (#210516)

* Thu Oct 12 2006 Jeremy Katz <katzj@redhat.com> - 0.95.0-1
- support for blktap (danpb)
- name change

* Tue Oct  3 2006 Jeremy Katz <katzj@redhat.com> - 0.94.0-1
- Fix using block device as backing (#209138)
- Fix error handling for invalid install locations (danpb)
- Write out vcpu config (danpb)

* Wed Sep 20 2006 Jeremy Katz <katzj@redhat.com> - 0.93.0-1
- Fix hvm network xm config (danpb)
- Enable PAE with pae hvm hosts (danpb)
- Fix hvm block backed cds (danpb)
- Fix handling of block devs backed by vbds (danpb)
- Ensure we're on a xen kernel (#205889)
- Default to vncunused

* Wed Sep  6 2006 Jeremy Katz <katzj@redhat.com> - 0.92.0-2
- add patch to fix memory parsing in interactive mode
- fix deps

* Wed Aug 30 2006 Jeremy Katz <katzj@redhat.com> - 0.92.0-1
- Fix silly loop when asking about graphics support (misa)
- Fix passing macaddr
- Add support so that we reboot into the guest after installation finishes 

* Tue Aug 29 2006 Jeremy Katz <katzj@redhat.com> - 0.91.0-1
- add support for paravirt guests with framebuffer. 

* Mon Aug 21 2006 Jeremy Katz <katzj@redhat.com> - 0.90.1-1
- fix tab/space whitespace inconsistency

* Wed Aug 16 2006 Jeremy Katz <katzj@redhat.com> - 0.90.0-2
- set ExcludeArch so that it doesn't get pulled into all trees

* Wed Aug 16 2006 Jeremy Katz <katzj@redhat.com> - 0.90.0-1
- update to version with fixed HVM domain creation

* Wed Aug 16 2006 Jeremy Katz <katzj@redhat.com> - 0.9-2
- add some missing requires

* Tue Aug 15 2006 Jeremy Katz <katzj@redhat.com> - 0.9-1
- Initial build