diff --git a/libarchive-ppc64.patch b/libarchive-ppc64.patch new file mode 100644 index 0000000..fe811d8 --- /dev/null +++ b/libarchive-ppc64.patch @@ -0,0 +1,26 @@ +Index: libarchive-3.0.4/libarchive/archive_read_disk_entry_from_file.c +=================================================================== +--- libarchive-3.0.4.orig/libarchive/archive_read_disk_entry_from_file.c ++++ libarchive-3.0.4/libarchive/archive_read_disk_entry_from_file.c +@@ -197,7 +197,7 @@ archive_read_disk_entry_from_file(struct + fd = open(path, O_RDONLY | O_NONBLOCK); + } + if (fd >= 0) { +- unsigned long stflags; ++ int stflags; + r = ioctl(fd, EXT2_IOC_GETFLAGS, &stflags); + if (r == 0 && stflags != 0) + archive_entry_set_fflags(entry, stflags, 0); +Index: libarchive-3.0.4/libarchive/archive_read_disk_posix.c +=================================================================== +--- libarchive-3.0.4.orig/libarchive/archive_read_disk_posix.c ++++ libarchive-3.0.4/libarchive/archive_read_disk_posix.c +@@ -984,7 +984,7 @@ next_entry(struct archive_read_disk *a, + #elif defined(EXT2_IOC_GETFLAGS) && defined(EXT2_NODUMP_FL) &&\ + defined(HAVE_WORKING_EXT2_IOC_GETFLAGS) + if (S_ISREG(st->st_mode) || S_ISDIR(st->st_mode)) { +- unsigned long stflags; ++ int stflags; + + t->entry_fd = open_on_current_dir(t, + tree_current_access_path(t), O_RDONLY | O_NONBLOCK); diff --git a/libarchive.changes b/libarchive.changes index 10c9b9a..f291ca6 100644 --- a/libarchive.changes +++ b/libarchive.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Aug 23 08:30:05 UTC 2012 - dvaleev@suse.com + +- fix http://code.google.com/p/libarchive/issues/detail?id=277 + test_option_b and test_option_nodump are failing on ppc64 + ------------------------------------------------------------------- Thu Aug 9 09:05:01 UTC 2012 - cfarrell@suse.com diff --git a/libarchive.spec b/libarchive.spec index 72ef874..07a08b2 100644 --- a/libarchive.spec +++ b/libarchive.spec @@ -36,6 +36,8 @@ Source0: http://libarchive.googlecode.com/files/libarchive-%{version}.tar Source1: baselibs.conf # PATCH-FIX-UPSTREAM libarchive-fix-checks.patch dimstar@opensuse.org -- Fix GCC 4.7 side effects. Taken from upstream. Patch0: libarchive-fix-checks.patch +# PATCH-FIX-UPSTREAM libarchive-ppc64.patch dvaleev@suse.com -- fix tests failing on ppc64 +Patch1: libarchive-ppc64.patch %description Libarchive is a programming library that can create and read several @@ -134,6 +136,7 @@ This package contains the development files. %prep %setup -q %patch0 -p1 +%patch1 -p1 %build %global optflags %{optflags} -D_REENTRANT -pipe