[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#684961: unblock: rpm/4.10.0-5



Package: release.debian.org
Severity: normal
User: release.debian.org@packages.debian.org
Usertags: unblock

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Please unblock package rpm, it includes single patch from Fedora to
allow setup of Fedora 17 (and future Fedora 18 and RHEL7) chroots. This
is really not a critical fix, but will improve compatibility with other
Linux vendors.

The only change in the package is adding this patch:

http://anonscm.debian.org/gitweb/?p=collab-maint/rpm.git;a=blob;f=debian/patches/rpm-4.9.1.2-rpmlib-filesystem-check.patch

Debdiff attached as well.

unblock rpm/4.10.0-5

Thanks
- -- 
	Michal Čihař | http://cihar.com | http://blog.cihar.com

- -- System Information:
Debian Release: wheezy/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'stable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 3.1.10-1.16-desktop (SMP w/2 CPU cores; PREEMPT)
Locale: LANG=cs_CZ.UTF-8, LC_CTYPE=cs_CZ.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iQIcBAEBCAAGBQJQK05dAAoJEGo39bHX+xdNQ3MP/i5fIRmrWfx1G6eb2Sje222G
spLNiFH3wmXBCBzAcKluy9cEUoPIa7DihjXzD9r/UjeFVWndEVt7ZCAWtxAB8GcW
jPfGboiOL/Bz4k/a5KSNusFWF+lsUjyFGKh72jaSpCtewZmjY2Cm+qVwgJo01dgl
KaxOKY4Hz4TFHs5XkLuDTY7gYTI0HZ/0ukaaQU/KVQ+AcYxhAY339sotDHsABQy6
AS3fnbq4v3suXglo8J/g1+0ejCk/J47KhoiKKK80YDHOUlIbFmpmUNaXnJ0JHU0D
lQN+T2PrAXSnQZ4gLfT/sKXgvykWBFIKZXUdmCzQCA4cU05MlLVhoapQfUIGZP8M
Wwk1v+2XxxDJB2bHEHPNCs99P4BfeG/GPSELtXFAnYFqs53BFzfdUOygNM3YgyDS
w3sAyQgAKtrNlFvOrWmyutlxYQo0qpmED8jTEjz/oWhhChrEB37Pq9LM/DfBfjEK
rvT6AeOiuO+tNhpU7YUakof9DOKxnx6v68OgPz6QLIg5K7K1WzdHe364OEoL67Ua
E1cKMyf0pN0AK4UlE/2nhHRODGNOoFdNsyjOuxmBQ3eMrll55SA9z490Ug3ZXktS
KkYJquPjFJLM7Yhk7L13I1Xuue161qG3VyR5C2wSEU4H1ZJpwDwN/4x33+D4DxtE
B9X0vRcBJdCY/TGx5FXW
=tcWN
-----END PGP SIGNATURE-----
diff -Nru rpm-4.10.0/debian/changelog rpm-4.10.0/debian/changelog
--- rpm-4.10.0/debian/changelog	2012-06-25 14:29:22.000000000 +0200
+++ rpm-4.10.0/debian/changelog	2012-08-15 09:05:37.000000000 +0200
@@ -1,3 +1,10 @@
+rpm (4.10.0-5) unstable; urgency=low
+
+  * Added patch from Fedora to support X-CheckUnifiedSystemdir 
+    (Closes: #683759).
+
+ -- Michal Čihař <nijel@debian.org>  Wed, 15 Aug 2012 09:05:26 +0200
+
 rpm (4.10.0-4) unstable; urgency=low
 
   * Lower librpm -> rpm-common dependency to recommends as there actually
diff -Nru rpm-4.10.0/debian/patches/rpm-4.9.1.2-rpmlib-filesystem-check.patch rpm-4.10.0/debian/patches/rpm-4.9.1.2-rpmlib-filesystem-check.patch
--- rpm-4.10.0/debian/patches/rpm-4.9.1.2-rpmlib-filesystem-check.patch	1970-01-01 01:00:00.000000000 +0100
+++ rpm-4.10.0/debian/patches/rpm-4.9.1.2-rpmlib-filesystem-check.patch	2012-08-15 09:05:37.000000000 +0200
@@ -0,0 +1,128 @@
+Description: Add Fedora compatible rpm builtin provides
+Origin: vendor, http://pkgs.fedoraproject.org/cgit/rpm.git/plain/rpm-4.9.1.2-rpmlib-filesystem-check.patch
+Forwarded: not-needed
+--- a/lib/depends.c
++++ b/lib/depends.c
+@@ -459,6 +459,108 @@
+     return rc;
+ }
+ 
++/*
++ * Temporary support for live-conversion of the filesystem hierarchy
++ *   mailto: kay@redhat.com, harald@redhat.com
++ *   https://fedoraproject.org/wiki/Features/UsrMove
++ *
++ *   X-CheckUnifiedSystemdir:
++ *     /bin, /sbin, /lib, /lib64 --> /usr
++ *
++ *   X-CheckUnifiedBindir:
++ *     /usr/sbin -> /usr/bin
++ *
++ *   X-CheckMultiArchLibdir:
++ *     /usr/lib64 /usr/lib/<platform tuple> (e.g. x86_64-linux-gnu)
++ *
++ * This code is not needed for new installations, it can be removed after
++ * updates from older systems are no longer supported: Fedora 19 / RHEL 8.
++ */
++
++static int CheckLink(const char *dir, const char *root)
++{
++    char *d = NULL;
++    struct stat sbuf;
++    int rc = 0;
++
++    if (!root)
++	root = "/";
++
++    rasprintf(&d, "%s%s", root, dir);
++    if (!d) {
++	rc = -1;
++	goto exit;
++    }
++
++    /* directory or symlink does not exist, all is fine */
++    if (lstat(d, &sbuf) < 0) {
++	rc = 1;
++	goto exit;
++    }
++
++    /* if it is a symlink, all is fine */
++    if (S_ISLNK(sbuf.st_mode))
++	rc = 1;
++
++exit:
++    free(d);
++    return rc;
++}
++
++static int CheckFilesystemHierarchy(rpmds * dsp, const char *root)
++{
++    static const char *dirs[] = { "bin", "sbin", "lib", "lib64" };
++    int check;
++    int i;
++    rpmds ds;
++    int rc = 0;
++
++    for (i = 0; i < sizeof(dirs) / sizeof(dirs[0]); i++) {
++	check = CheckLink(dirs[i], root);
++	if (check < 0) {
++	    rc = -1;
++	    goto exit;
++	}
++
++	if (check == 0)
++	    goto exit;
++    }
++    ds = rpmdsSingle(RPMTAG_PROVIDENAME,
++		     "rpmlib(X-CheckUnifiedSystemdir)", "1",
++		     RPMSENSE_EQUAL);
++    rpmdsMerge(dsp, ds);
++    rpmdsFree(ds);
++
++    check = CheckLink("usr/lib64", root);
++    if (check < 0) {
++        rc = -1;
++        goto exit;
++    }
++    if (check > 0) {
++	ds = rpmdsSingle(RPMTAG_PROVIDENAME,
++			 "rpmlib(X-CheckMultiArchLibdir)", "1",
++			 RPMSENSE_EQUAL);
++	rpmdsMerge(dsp, ds);
++	rpmdsFree(ds);
++    }
++
++    check = CheckLink("usr/sbin", root);
++    if (check < 0) {
++	rc = -1;
++	goto exit;
++    }
++    if (check > 0) {
++	ds = rpmdsSingle(RPMTAG_PROVIDENAME,
++			 "rpmlib(X-CheckUnifiedBindir)", "1",
++			 RPMSENSE_EQUAL);
++	rpmdsMerge(dsp, ds);
++	rpmdsFree(ds);
++    }
++
++exit:
++    return rc;
++}
++
+ /**
+  * Check dep for an unsatisfied dependency.
+  * @param ts		transaction set
+@@ -483,9 +585,11 @@
+      */
+     if (dsflags & RPMSENSE_RPMLIB) {
+ 	static int oneshot = -1;
+-	if (oneshot) 
++	if (oneshot) {
+ 	    oneshot = rpmdsRpmlib(&rpmlibP, NULL);
+-	
++	    CheckFilesystemHierarchy(&rpmlibP, rpmtsRootDir(ts));
++	}
++
+ 	if (rpmlibP != NULL && rpmdsSearch(rpmlibP, dep) >= 0) {
+ 	    rpmdsNotify(dep, "(rpmlib provides)", rc);
+ 	    goto exit;
diff -Nru rpm-4.10.0/debian/patches/series rpm-4.10.0/debian/patches/series
--- rpm-4.10.0/debian/patches/series	2012-06-25 14:29:22.000000000 +0200
+++ rpm-4.10.0/debian/patches/series	2012-08-15 09:05:37.000000000 +0200
@@ -9,3 +9,4 @@
 no-linux-gate.so-dependancy.patch
 autogen-cleanup.patch
 lua-libname.patch
+rpm-4.9.1.2-rpmlib-filesystem-check.patch

Reply to: