diff --git a/0001-Workaround-for-usrmove-in-Fedora.patch b/0001-Workaround-for-usrmove-in-Fedora.patch new file mode 100644 index 0000000..f098b30 --- /dev/null +++ b/0001-Workaround-for-usrmove-in-Fedora.patch @@ -0,0 +1,40 @@ +From 3ddd9e33fd2c6c75b10d1734d8cdd821ea356863 Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sun, 5 Feb 2012 22:53:07 +0000 +Subject: [PATCH] Workaround for usrmove in Fedora. + +--- + .gnulib | 2 +- + appliance/Makefile.am | 9 +++++---- + 2 files changed, 6 insertions(+), 5 deletions(-) + +diff --git a/.gnulib b/.gnulib +index b643182..eec8a69 160000 +--- a/.gnulib ++++ b/.gnulib +@@ -1 +1 @@ +-Subproject commit b64318247b74481e02caacf4c46d83f07be2b88d ++Subproject commit eec8a6915839cfe54a520732da01250cea844314 +diff --git a/appliance/Makefile.am b/appliance/Makefile.am +index 99896be..0d6b871 100644 +--- a/appliance/Makefile.am ++++ b/appliance/Makefile.am +@@ -67,10 +67,11 @@ stamp-supermin: make.sh packagelist excludelist + supermin.d/daemon.img: ../daemon/guestfsd + mkdir -p supermin.d + rm -f $@ $@-t +- mkdir sbin +- cd sbin && ln ../../daemon/guestfsd +- echo -e "sbin\nsbin/guestfsd" | cpio --quiet -o -H newc > $@-t +- rm -r sbin ++ mkdir -p usr/sbin ++ cd usr/sbin && ln ../../../daemon/guestfsd ++ echo -e "usr\nusr/sbin\nusr/sbin/guestfsd" | \ ++ cpio --quiet -o -H newc > $@-t ++ rm -r usr + mv $@-t $@ + + supermin.d/init.img: init +-- +1.7.9 + diff --git a/libguestfs.spec b/libguestfs.spec index d1763be..056f65c 100644 --- a/libguestfs.spec +++ b/libguestfs.spec @@ -30,13 +30,17 @@ Summary: Access and modify virtual machine disk images Name: libguestfs Epoch: 1 Version: 1.17.4 -Release: 2%{?dist} +Release: 3%{?dist} License: LGPLv2+ Group: Development/Libraries URL: http://libguestfs.org/ Source0: http://libguestfs.org/download/1.17-development/%{name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root +%if 0%{?fedora} >= 17 +Patch0: 0001-Workaround-for-usrmove-in-Fedora.patch +%endif + %if 0%{?rhel} >= 7 ExclusiveArch: x86_64 %endif @@ -623,6 +627,10 @@ for %{name}. %prep %setup -q +%if 0%{?fedora} >= 17 +%patch0 -p1 +%endif + mkdir -p daemon/m4 # Replace developer-specific README that ships with libguestfs, with @@ -1021,8 +1029,8 @@ rm -rf $RPM_BUILD_ROOT %changelog -* Sat Feb 04 2012 Richard W.M. Jones - 1:1.17.4-2 -- Bump and rebuild. +* Sun Feb 04 2012 Richard W.M. Jones - 1:1.17.4-3 +- Add workaround for usrmove in Fedora. * Wed Feb 1 2012 Richard W.M. Jones - 1:1.17.4-1 - New upstream version 1.17.4.