3 #%global mirror http://hakodate/mirrors/fedora/10/Fedora/x86_64/os/
5 Summary: Access and modify virtual machine disk images
10 Group: Development/Libraries
11 URL: http://et.redhat.com/~rjones/libguestfs/
12 Source0: http://et.redhat.com/~rjones/libguestfs/files/%{name}-%{version}.tar.gz
13 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
15 # Basic build requirements:
16 BuildRequires: /usr/bin/pod2man
17 BuildRequires: /usr/bin/pod2text
18 BuildRequires: febootstrap >= 1.5
19 BuildRequires: augeas-devel >= 0.5.0
22 # If you want to build the bindings for different languages:
24 BuildRequires: ocaml-findlib-devel
25 BuildRequires: perl-devel
26 BuildRequires: perl-Test-Pod
27 BuildRequires: perl-Test-Pod-Coverage
28 BuildRequires: perl-ExtUtils-MakeMaker
29 # BuildRequires: python-devel
36 Libguestfs is a library for accessing and modifying guest disk images.
37 Amongst the things this is good for: making batch configuration
38 changes to guests, getting disk used/free statistics (see also:
39 virt-df), migrating between virtualization systems (see also:
40 virt-p2v), performing partial backups, performing partial guest
41 clones, cloning guests and changing registry/UUID/hostname info, and
44 Libguestfs uses Linux kernel and qemu code, and can access any type of
45 guest filesystem that Linux and qemu can, including but not limited
46 to: ext2/3/4, btrfs, FAT and NTFS, LVM, many different disk partition
47 schemes, qcow, qcow2, vmdk.
49 Libguestfs provides ways to enumerate guest storage (eg. partitions,
50 LVs, what filesystem is in each LV, etc.). It can also run commands
51 in the context of the guest. Also you can access filesystems over FTP.
53 Libguestfs is a library that can be linked with C and C++ management
56 See also the 'guestfish' package for shell scripting and command line
61 Summary: Development tools and libraries for %{name}
62 Group: Development/Libraries
63 Requires: %{name} = %{version}-%{release}
67 %{name}-devel contains development tools and libraries
72 Summary: Shell for accessing and modifying virtual machine disk images
73 Group: Development/Tools
75 Requires: %{name} = %{version}-%{release}
76 Requires: /usr/bin/pod2text
79 %description -n guestfish
80 Guestfish is the Filesystem Interactive SHell, for accessing and
81 modifying virtual machine disk images from the command line and shell
86 Summary: OCaml bindings for %{name}
87 Group: Development/Libraries
88 Requires: %{name} = %{version}-%{release}
92 %{name}-ocaml contains OCaml bindings for %{name}.
94 This is for toplevel and scripting access only. To compile OCaml
95 programs which use %{name} you will also need %{name}-ocaml-devel.
99 Summary: OCaml bindings for %{name}
100 Group: Development/Libraries
101 Requires: %{name}-ocaml = %{version}-%{release}
104 %description ocaml-devel
105 %{name}-ocaml-devel contains development libraries
106 required to use the OCaml bindings for %{name}.
110 Summary: Perl bindings for %{name}
111 Group: Development/Libraries
112 Requires: %{name} = %{version}-%{release}
113 Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
117 %{name}-perl contains Perl bindings for %{name}.
121 # Summary: Python bindings for %{name}
122 # Group: Development/Libraries
123 # Requires: %{name} = %{version}-%{release}
126 # %description python
127 # %{name}-python contains Python bindings for %{name}.
135 #%configure --with-mirror=%{mirror}
138 # 'INSTALLDIRS' ensures that perl libs are installed in the vendor dir
140 make INSTALLDIRS=vendor
148 rm -rf $RPM_BUILD_ROOT
150 make DESTDIR=$RPM_BUILD_ROOT install
152 rm $RPM_BUILD_ROOT%{_libdir}/libguestfs.a
153 rm $RPM_BUILD_ROOT%{_libdir}/libguestfs.la
155 # Clean up the examples/ directory which will get installed in %doc.
156 # Note we can't delete the original examples/Makefile because that
157 # will be needed by the check section later in the RPM build.
165 # Same for ocaml/examples.
166 cp -a ocaml/examples ocaml/ex
172 find $RPM_BUILD_ROOT -name perllocal.pod -delete
173 find $RPM_BUILD_ROOT -name .packlist -delete
177 rm -rf $RPM_BUILD_ROOT
180 %post -p /sbin/ldconfig
182 %postun -p /sbin/ldconfig
186 %defattr(-,root,root,-)
189 %{_libdir}/libguestfs.so.*
193 %defattr(-,root,root,-)
194 %doc HACKING TODO README ex html/guestfs.3.html html/pod.css
195 %{_libdir}/libguestfs.so
196 %{_mandir}/man3/guestfs.3*
197 %{_includedir}/guestfs.h
198 %{_includedir}/guestfs-actions.h
199 %{_includedir}/guestfs-structs.h
203 %defattr(-,root,root,-)
204 %doc html/guestfish.1.html html/pod.css
206 %{_mandir}/man1/guestfish.1*
210 %defattr(-,root,root,-)
211 %{_libdir}/ocaml/guestfs
212 %exclude %{_libdir}/ocaml/guestfs/*.a
213 %exclude %{_libdir}/ocaml/guestfs/*.cmxa
214 %exclude %{_libdir}/ocaml/guestfs/*.cmx
215 %exclude %{_libdir}/ocaml/guestfs/*.mli
216 %{_libdir}/ocaml/stublibs/*.so
217 %{_libdir}/ocaml/stublibs/*.so.owner
221 %defattr(-,root,root,-)
223 %{_libdir}/ocaml/guestfs/*.a
224 %{_libdir}/ocaml/guestfs/*.cmxa
225 %{_libdir}/ocaml/guestfs/*.cmx
226 %{_libdir}/ocaml/guestfs/*.mli
230 %defattr(-,root,root,-)
233 %{_mandir}/man3/Sys::Guestfs.3pm*
237 # %defattr(-,root,root,-)
241 * Sat Apr 4 2009 Richard Jones <rjones@redhat.com> - @VERSION@-1