forked from pool/libguestfs
Accepting request 528077 from home:jengelh:branches:Virtualization
- Update summaries and RPM groups. Trim description for size. - Replace old $RPM_ shell vars by macros. Remove redundant %clean section. OBS-URL: https://build.opensuse.org/request/show/528077 OBS-URL: https://build.opensuse.org/package/show/Virtualization/libguestfs?expand=0&rev=406
This commit is contained in:
parent
77da480dd9
commit
2a8db46d2a
@ -1,3 +1,10 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Sep 21 13:25:16 UTC 2017 - jengelh@inai.de
|
||||||
|
|
||||||
|
- Update summaries and RPM groups. Trim description for size.
|
||||||
|
- Replace old $RPM_ shell vars by macros.
|
||||||
|
Remove redundant %clean section.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Sep 20 17:18:24 UTC 2017 - cbosdonnat@suse.com
|
Wed Sep 20 17:18:24 UTC 2017 - cbosdonnat@suse.com
|
||||||
|
|
||||||
|
109
libguestfs.spec
109
libguestfs.spec
@ -169,16 +169,6 @@ disk images. You can use this for viewing and editing files inside guests,
|
|||||||
scripting changes to VMs, monitoring disk used/free statistics, P2V, V2V,
|
scripting changes to VMs, monitoring disk used/free statistics, P2V, V2V,
|
||||||
performing partial backups, cloning VMs, and much else besides.
|
performing partial backups, cloning VMs, and much else besides.
|
||||||
|
|
||||||
libguestfs can access nearly any type of filesystem including: all known types
|
|
||||||
of Linux filesystem (ext2/3/4, XFS, btrfs etc), any Windows filesystem (VFAT
|
|
||||||
and NTFS), any Mac OS X and BSD filesystems, LVM2 volume management, MBR and
|
|
||||||
GPT disk partitions, raw disks, qcow2, VirtualBox VDI, VMWare VMDK, CD and DVD
|
|
||||||
ISOs, SD cards, and dozens more. libguestfs doesn't need root permissions.
|
|
||||||
|
|
||||||
All this functionality is available through a convenient shell called
|
|
||||||
guestfish, or use virt-rescue to get a rescue shell for fixing unbootable
|
|
||||||
virtual machines.
|
|
||||||
|
|
||||||
%package -n guestfs-tools
|
%package -n guestfs-tools
|
||||||
Summary: Tools for accessing and modifying virtual machine disk images
|
Summary: Tools for accessing and modifying virtual machine disk images
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
@ -247,18 +237,18 @@ This package is only required for building the appliance.
|
|||||||
#
|
#
|
||||||
%if %{with ocaml_bindings}
|
%if %{with ocaml_bindings}
|
||||||
%package -n ocaml-libguestfs
|
%package -n ocaml-libguestfs
|
||||||
Summary: Provides OCaml support for libguestfs
|
Summary: OCaml bindings for libguestfs
|
||||||
#
|
#
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
Group: System/Filesystems
|
Group: Development/Languages/Ocaml
|
||||||
|
|
||||||
%description -n ocaml-libguestfs
|
%description -n ocaml-libguestfs
|
||||||
Allows OCaml scripts to directly use libguestfs.
|
Allows OCaml scripts to directly use libguestfs.
|
||||||
|
|
||||||
%package -n ocaml-libguestfs-devel
|
%package -n ocaml-libguestfs-devel
|
||||||
Summary: Provides OCaml support for libguestfs
|
Summary: Development files for libguesfs OCaml bindings
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
Group: Development/Libraries/Other
|
Group: Development/Languages/Ocaml
|
||||||
|
|
||||||
%description -n ocaml-libguestfs-devel
|
%description -n ocaml-libguestfs-devel
|
||||||
Allows OCaml scripts to directly use libguestfs.
|
Allows OCaml scripts to directly use libguestfs.
|
||||||
@ -266,9 +256,9 @@ Allows OCaml scripts to directly use libguestfs.
|
|||||||
#
|
#
|
||||||
%if %{with perl_bindings}
|
%if %{with perl_bindings}
|
||||||
%package -n perl-Sys-Guestfs
|
%package -n perl-Sys-Guestfs
|
||||||
Summary: Provides Perl support for libguestfs
|
Summary: Perl bindings for libguestfs
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
Group: System/Filesystems
|
Group: Development/Languages/Perl
|
||||||
BuildRequires: perl
|
BuildRequires: perl
|
||||||
BuildRequires: perl(Data::Dumper)
|
BuildRequires: perl(Data::Dumper)
|
||||||
BuildRequires: perl(Getopt::Long)
|
BuildRequires: perl(Getopt::Long)
|
||||||
@ -295,9 +285,9 @@ Allows Perl scripts to directly use libguestfs.
|
|||||||
#
|
#
|
||||||
%if %{with lua_bindings}
|
%if %{with lua_bindings}
|
||||||
%package -n lua-libguestfs
|
%package -n lua-libguestfs
|
||||||
Summary: Provides Lua support for libguestfs
|
Summary: Lua bindings for libguestfs
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
Group: System/Filesystems
|
Group: Development/Languages/Lua
|
||||||
BuildRequires: lua-devel
|
BuildRequires: lua-devel
|
||||||
Requires: guestfs-data >= %{version}
|
Requires: guestfs-data >= %{version}
|
||||||
%define _configure_lua --enable-lua
|
%define _configure_lua --enable-lua
|
||||||
@ -311,9 +301,9 @@ Allows lua scripts to directly use libguestfs.
|
|||||||
%if %{with python_bindings}
|
%if %{with python_bindings}
|
||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
%package -n python2-libguestfs
|
%package -n python2-libguestfs
|
||||||
Summary: Provides Python 2 support for libguestfs
|
Summary: Python 2 bindings for libguestfs
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
Group: System/Filesystems
|
Group: Development/Languages/Python
|
||||||
BuildRequires: %{python_module devel}
|
BuildRequires: %{python_module devel}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: python
|
BuildRequires: python
|
||||||
@ -329,9 +319,9 @@ Requires: guestfs-data >= %{version}
|
|||||||
Allows Python 2 scripts to directly use libguestfs.
|
Allows Python 2 scripts to directly use libguestfs.
|
||||||
|
|
||||||
%package -n python3-libguestfs
|
%package -n python3-libguestfs
|
||||||
Summary: Provides Python 3 support for libguestfs
|
Summary: Python 3 bindings for libguestfs
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
Group: System/Filesystems
|
Group: Development/Languages/Python
|
||||||
%define _configure_python --enable-python
|
%define _configure_python --enable-python
|
||||||
#
|
#
|
||||||
Obsoletes: libguestfs-python < %{version}
|
Obsoletes: libguestfs-python < %{version}
|
||||||
@ -347,7 +337,7 @@ Allows Python 3 scripts to directly use libguestfs.
|
|||||||
%package -n rubygem-libguestfs
|
%package -n rubygem-libguestfs
|
||||||
Summary: Ruby bindings for libguestfs
|
Summary: Ruby bindings for libguestfs
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
Group: System/Filesystems
|
Group: Development/Languages/Ruby
|
||||||
BuildRequires: ruby
|
BuildRequires: ruby
|
||||||
BuildRequires: ruby-devel
|
BuildRequires: ruby-devel
|
||||||
BuildRequires: rubygem-rake
|
BuildRequires: rubygem-rake
|
||||||
@ -362,7 +352,7 @@ Allows Ruby scripts to directly use libguestfs.
|
|||||||
%package test
|
%package test
|
||||||
Summary: Testcases for libguestfs
|
Summary: Testcases for libguestfs
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
Group: System/Filesystems
|
Group: Development/Tools/Other
|
||||||
Requires: %{name}
|
Requires: %{name}
|
||||||
|
|
||||||
%description test
|
%description test
|
||||||
@ -473,7 +463,7 @@ This package provides such an image, an initrd and a kernel.
|
|||||||
|
|
||||||
%if 0%{?is_opensuse} == 0
|
%if 0%{?is_opensuse} == 0
|
||||||
%package -n guestfs-winsupport
|
%package -n guestfs-winsupport
|
||||||
Summary: Windows guests support in libguestfs
|
Summary: Windows guest support in libguestfs
|
||||||
License: GPL-2.0+
|
License: GPL-2.0+
|
||||||
Group: System/Filesystems
|
Group: System/Filesystems
|
||||||
Requires: libguestfs >= 1.32
|
Requires: libguestfs >= 1.32
|
||||||
@ -489,7 +479,7 @@ Provides the needed pieces for libguestfs to handle Windows guests.
|
|||||||
%package devel
|
%package devel
|
||||||
Summary: Development files for libguestfs
|
Summary: Development files for libguestfs
|
||||||
License: GPL-2.0
|
License: GPL-2.0
|
||||||
Group: Development/Libraries/Other
|
Group: Development/Libraries/C and C++
|
||||||
Requires: libguestfs0 = %{version}
|
Requires: libguestfs0 = %{version}
|
||||||
|
|
||||||
%description devel
|
%description devel
|
||||||
@ -500,20 +490,10 @@ disk images. You can use this for viewing and editing files inside guests,
|
|||||||
scripting changes to VMs, monitoring disk used/free statistics, P2V, V2V,
|
scripting changes to VMs, monitoring disk used/free statistics, P2V, V2V,
|
||||||
performing partial backups, cloning VMs, and much else besides.
|
performing partial backups, cloning VMs, and much else besides.
|
||||||
|
|
||||||
libguestfs can access nearly any type of filesystem including: all known types
|
|
||||||
of Linux filesystem (ext2/3/4, XFS, btrfs etc), any Windows filesystem (VFAT
|
|
||||||
and NTFS), any Mac OS X and BSD filesystems, LVM2 volume management, MBR and
|
|
||||||
GPT disk partitions, raw disks, qcow2, VirtualBox VDI, VMWare VMDK, CD and DVD
|
|
||||||
ISOs, SD cards, and dozens more. libguestfs doesn't need root permissions.
|
|
||||||
|
|
||||||
All this functionality is available through a convenient shell called
|
|
||||||
guestfish, or use virt-rescue to get a rescue shell for fixing unbootable
|
|
||||||
virtual machines.
|
|
||||||
|
|
||||||
%package -n libguestfs0
|
%package -n libguestfs0
|
||||||
Summary: Runtime library of libguestfs
|
Summary: Runtime library of libguestfs
|
||||||
License: LGPL-2.1
|
License: LGPL-2.1
|
||||||
Group: System/Filesystems
|
Group: System/Libraries
|
||||||
Requires: %{kvm_binary}
|
Requires: %{kvm_binary}
|
||||||
Requires: qemu >= 2.0
|
Requires: qemu >= 2.0
|
||||||
Requires: qemu-tools
|
Requires: qemu-tools
|
||||||
@ -587,8 +567,8 @@ export QEMU="%{kvm_binary}"
|
|||||||
export SUPERMIN=supermin
|
export SUPERMIN=supermin
|
||||||
export SUPERMIN_HELPER=supermin-helper
|
export SUPERMIN_HELPER=supermin-helper
|
||||||
# for configure macro below
|
# for configure macro below
|
||||||
CFLAGS="$RPM_OPT_FLAGS -Wno-unused"
|
export CFLAGS="%{optflags} -Wno-unused"
|
||||||
CXXFLAGS="$RPM_OPT_FLAGS -Wno-unused"
|
export CXXFLAGS="%{optflags} -Wno-unused"
|
||||||
autoreconf -fi
|
autoreconf -fi
|
||||||
|
|
||||||
#
|
#
|
||||||
@ -632,28 +612,28 @@ make \
|
|||||||
%makeinstall \
|
%makeinstall \
|
||||||
INSTALLDIRS=vendor \
|
INSTALLDIRS=vendor \
|
||||||
udevrulesdir=%{udevrulesdir}
|
udevrulesdir=%{udevrulesdir}
|
||||||
find $RPM_BUILD_ROOT -ls
|
find %{buildroot} -ls
|
||||||
mkdir -p $RPM_BUILD_ROOT%{_datadir}/guestfs
|
mkdir -p %{buildroot}/%{_datadir}/guestfs
|
||||||
cp -avLt $RPM_BUILD_ROOT%{_datadir}/guestfs \
|
cp -avLt %{buildroot}/%{_datadir}/guestfs \
|
||||||
%{S:10005} \
|
%{S:10005} \
|
||||||
%{S:10004} \
|
%{S:10004} \
|
||||||
%{S:10003} \
|
%{S:10003} \
|
||||||
%{S:10002} \
|
%{S:10002} \
|
||||||
%{S:10001}
|
%{S:10001}
|
||||||
chmod 0755 $RPM_BUILD_ROOT%{_datadir}/guestfs/*
|
chmod 0755 %{buildroot}/%{_datadir}/guestfs/*
|
||||||
#remove ocaml bindings files if they are disable via rpm macro
|
#remove ocaml bindings files if they are disable via rpm macro
|
||||||
%if !%{with ocaml_bindings}
|
%if !%{with ocaml_bindings}
|
||||||
rm -rfv $RPM_BUILD_ROOT%{_libdir}/ocaml
|
rm -rfv %{buildroot}/%{_libdir}/ocaml
|
||||||
%endif
|
%endif
|
||||||
rm -rfv $RPM_BUILD_ROOT%{guestfs_docdir}
|
rm -rfv %{buildroot}/%{guestfs_docdir}
|
||||||
find $RPM_BUILD_ROOT -type f \( \
|
find %{buildroot}/ -type f \( \
|
||||||
-name "virt-list-filesystems" -o -name "virt-list-filesystems.*" -o \
|
-name "virt-list-filesystems" -o -name "virt-list-filesystems.*" -o \
|
||||||
-name "virt-list-partitions" -o -name "virt-list-partitions.*" -o \
|
-name "virt-list-partitions" -o -name "virt-list-partitions.*" -o \
|
||||||
-name "virt-tar" -o -name "virt-tar.*" \
|
-name "virt-tar" -o -name "virt-tar.*" \
|
||||||
\) -print -delete
|
\) -print -delete
|
||||||
%if %{with perl_bindings}
|
%if %{with perl_bindings}
|
||||||
# Delete empty perl bootstrap files
|
# Delete empty perl bootstrap files
|
||||||
find $RPM_BUILD_ROOT -name "*.bs" -size 0c -print -delete
|
find %{buildroot}/ -name "*.bs" -size 0c -print -delete
|
||||||
%perl_process_packlist
|
%perl_process_packlist
|
||||||
%perl_gen_filelist
|
%perl_gen_filelist
|
||||||
# the macro above packages everything, here only the perl files are desrired
|
# the macro above packages everything, here only the perl files are desrired
|
||||||
@ -663,7 +643,7 @@ mv t %{name}.files
|
|||||||
|
|
||||||
%if %{with python_bindings}
|
%if %{with python_bindings}
|
||||||
pushd python
|
pushd python
|
||||||
sed -i -e "s:libraries=:library_dirs=['$RPM_BUILD_ROOT/%{_libdir}'], libraries=:" setup.py
|
sed -i -e "s:libraries=:library_dirs=['%{buildroot}/%{_libdir}'], libraries=:" setup.py
|
||||||
make stamp-extra-files
|
make stamp-extra-files
|
||||||
# Build needs libguestfs library to be installed
|
# Build needs libguestfs library to be installed
|
||||||
|
|
||||||
@ -680,23 +660,23 @@ popd
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
#
|
#
|
||||||
find $RPM_BUILD_ROOT -name "*.la" -print -delete
|
find %{buildroot}/ -name "*.la" -print -delete
|
||||||
rm -fv $RPM_BUILD_ROOT/%{_libdir}/*.a
|
rm -fv %{buildroot}/%{_libdir}/*.a
|
||||||
#
|
#
|
||||||
touch %{name}.lang
|
touch %{name}.lang
|
||||||
%find_lang %{name}
|
%find_lang %{name}
|
||||||
%fdupes -s $RPM_BUILD_ROOT
|
%fdupes -s %{buildroot}/
|
||||||
|
|
||||||
# Appliance NTFS files
|
# Appliance NTFS files
|
||||||
%if %{?is_opensuse}
|
%if %{?is_opensuse}
|
||||||
mkdir -p $RPM_BUILD_ROOT/tmp/etc/alternatives
|
mkdir -p %{buildroot}/tmp/etc/alternatives
|
||||||
pushd $RPM_BUILD_ROOT/tmp/etc/alternatives
|
pushd %{buildroot}/tmp/etc/alternatives
|
||||||
ln -s /sbin/mount.ntfs-3g mount.ntfs
|
ln -s /sbin/mount.ntfs-3g mount.ntfs
|
||||||
popd
|
popd
|
||||||
pushd $RPM_BUILD_ROOT/tmp
|
pushd %{buildroot}/tmp
|
||||||
tar czf $RPM_BUILD_ROOT/%{_libdir}/guestfs/supermin.d/zz-ntfs-symlink.tar.gz etc
|
tar -czf %{buildroot}/%{_libdir}/guestfs/supermin.d/zz-ntfs-symlink.tar.gz etc
|
||||||
popd
|
popd
|
||||||
rm -rf $RPM_BUILD_ROOT/tmp
|
rm -rf %{buildroot}/tmp
|
||||||
%else
|
%else
|
||||||
# Just copy the content of the ntfs packages
|
# Just copy the content of the ntfs packages
|
||||||
mkdir winsupport
|
mkdir winsupport
|
||||||
@ -714,22 +694,19 @@ popd
|
|||||||
echo "libfuse2" > %{buildroot}%{_libdir}/guestfs/supermin.d/zz-packages-winsupport
|
echo "libfuse2" > %{buildroot}%{_libdir}/guestfs/supermin.d/zz-packages-winsupport
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/tmp/usr/bin
|
mkdir -p %{buildroot}/tmp/usr/bin
|
||||||
cp %{S:100} $RPM_BUILD_ROOT/tmp/usr/bin
|
cp %{S:100} %{buildroot}/tmp/usr/bin
|
||||||
chmod a+x $RPM_BUILD_ROOT/tmp/usr/bin/*
|
chmod a+x %{buildroot}/tmp/usr/bin/*
|
||||||
pushd $RPM_BUILD_ROOT/tmp
|
pushd %{buildroot}/tmp
|
||||||
tar czf $RPM_BUILD_ROOT/%{_libdir}/guestfs/supermin.d/zz-scripts.tar.gz usr
|
tar -czf %{buildroot}/%{_libdir}/guestfs/supermin.d/zz-scripts.tar.gz usr
|
||||||
popd
|
popd
|
||||||
rm -rf $RPM_BUILD_ROOT/tmp
|
rm -rf %{buildroot}/tmp
|
||||||
|
|
||||||
%if %{with p2v}
|
%if %{with p2v}
|
||||||
# Remove the kickstart files from p2v package
|
# Remove the kickstart files from p2v package
|
||||||
rm $RPM_BUILD_ROOT/%{_datadir}/virt-p2v/p2v.ks.in
|
rm %{buildroot}/%{_datadir}/virt-p2v/p2v.ks.in
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%clean
|
|
||||||
rm -rf $RPM_BUILD_ROOT
|
|
||||||
|
|
||||||
%post -n libguestfs0 -p /sbin/ldconfig
|
%post -n libguestfs0 -p /sbin/ldconfig
|
||||||
%postun -n libguestfs0 -p /sbin/ldconfig
|
%postun -n libguestfs0 -p /sbin/ldconfig
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user