--- /dev/null
+diff -ur rpm-4.5.orig/build/parsePrep.c rpm-4.5/build/parsePrep.c
+--- rpm-4.5.orig/build/parsePrep.c 2014-07-29 17:12:39.000000000 +0000
++++ rpm-4.5/build/parsePrep.c 2014-07-29 17:14:38.749000000 +0000
+@@ -148,6 +148,9 @@
+ case COMPRESSED_LZMA:
+ zipper = "%{__lzma}";
+ break;
++ case COMPRESSED_XZ:
++ zipper = "%{__xz}";
++ break;
+ }
+ zipper = rpmGetPath(zipper, NULL);
+
+@@ -251,6 +254,9 @@
+ case COMPRESSED_LZMA:
+ t = "%{__lzma} -dc";
+ break;
++ case COMPRESSED_XZ:
++ t = "%{__xz} -dc";
++ break;
+ case COMPRESSED_ZIP:
+ if (rpmIsVerbose() && !quietly)
+ t = "%{__unzip}";
+diff -ur rpm-4.5.orig/rpmio/macro.c rpm-4.5/rpmio/macro.c
+--- rpm-4.5.orig/rpmio/macro.c 2014-07-29 17:12:39.000000000 +0000
++++ rpm-4.5/rpmio/macro.c 2014-07-29 17:13:17.613000000 +0000
+@@ -1241,10 +1241,13 @@
+ sprintf(be, "%%__unzip -qq %s", b);
+ break;
+ case 4: /* COMPRESSED_LZOP */
+- sprintf(be, "%%__lzop %s", b);
++ sprintf(be, "%%__lzop -dc %s", b);
+ break;
+ case 5: /* COMPRESSED_LZMA */
+- sprintf(be, "%%__lzma %s", b);
++ sprintf(be, "%%__lzma -dc %s", b);
++ break;
++ case 6: /* COMPRESSED_XZ */
++ sprintf(be, "%%__xz -dc %s", b);
+ break;
+ }
+ b = be;
+@@ -2257,6 +2260,13 @@
+ magic[11] == 0x00 && magic[12] == 0x00) /* lzmash */
+ *compressed = COMPRESSED_LZMA;
+ else
++ if (magic[0] == 0135 && magic[1] == 0 && magic[2] == 0) /* lzma */
++ *compressed = COMPRESSED_LZMA;
++ else
++ if (magic[0] == 0xFD && magic[1] == 0x37 && magic[2] == 0x7A
++ && magic[3] == 0x58 && magic[4] == 0x5A && magic[5] == 0x00) /* xz */
++ *compressed = COMPRESSED_XZ;
++ else
+ if ((magic[0] == 0037 && magic[1] == 0213) /* gzip */
+ || (magic[0] == 0037 && magic[1] == 0236) /* old gzip */
+ || (magic[0] == 0037 && magic[1] == 0036) /* pack */
+diff -ur rpm-4.5.orig/rpmio/rpmmacro.h rpm-4.5/rpmio/rpmmacro.h
+--- rpm-4.5.orig/rpmio/rpmmacro.h 2014-07-29 17:12:39.000000000 +0000
++++ rpm-4.5/rpmio/rpmmacro.h 2014-07-29 17:13:17.613000000 +0000
+@@ -170,7 +170,8 @@
+ COMPRESSED_BZIP2 = 2, /*!< bzip2 can handle */
+ COMPRESSED_ZIP = 3, /*!< unzip can handle */
+ COMPRESSED_LZOP = 4, /*!< lzop can handle */
+- COMPRESSED_LZMA = 5 /*!< lzma can handle */
++ COMPRESSED_LZMA = 5, /*!< lzma can handle */
++ COMPRESSED_XZ = 6 /*!< xz can handle */
+ } rpmCompressedMagic;
+
+ /**
Summary(uk.UTF-8): Менеджер пакетів від RPM
Name: rpm
Version: 4.5
-Release: 74
+Release: 75
License: LGPL
Group: Base
Source0: %{name}-%{version}.tar.gz
Patch107: %{name}-debugedit-dwarf4.patch
Patch108: %{name}-changelog_order_check_nonfatal.patch
Patch109: %{name}-installplatform.patch
+Patch110: %{name}-xz.patch
URL: http://rpm5.org/
BuildRequires: autoconf >= 2.57
BuildRequires: automake >= 1.4
%patch107 -p1
%patch108 -p1
%patch109 -p1
+%patch110 -p1
mv -f po/{sr,sr@Latn}.po
rm -rf sqlite zlib popt