commit:     9d8fe0cbb0d96023f7ebd281fd71aacae74fbc69
Author:     Justin Lecher <jlec <AT> gentoo <DOT> org>
AuthorDate: Sun Feb 12 18:52:07 2017 +0000
Commit:     Justin Lecher <jlec <AT> gentoo <DOT> org>
CommitDate: Sun Feb 12 19:08:42 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9d8fe0cb

sys-apps/fakeroot: Backport patch for glibc-2.24

Package-Manager: Portage-2.3.3, Repoman-2.3.1
Signed-off-by: Justin Lecher <jlec <AT> gentoo.org>

 sys-apps/fakeroot/fakeroot-1.20.2-r1.ebuild        | 46 ++++++++++++++++++++++
 .../files/fakeroot-1.20.2-glibc-2.24.patch         | 32 +++++++++++++++
 sys-apps/fakeroot/metadata.xml                     |  8 ++--
 3 files changed, 82 insertions(+), 4 deletions(-)

diff --git a/sys-apps/fakeroot/fakeroot-1.20.2-r1.ebuild 
b/sys-apps/fakeroot/fakeroot-1.20.2-r1.ebuild
new file mode 100644
index 0000000000..a2ccf4890a
--- /dev/null
+++ b/sys-apps/fakeroot/fakeroot-1.20.2-r1.ebuild
@@ -0,0 +1,46 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit autotools eutils flag-o-matic
+
+DESCRIPTION="A fake root environment by means of LD_PRELOAD and SysV IPC (or 
TCP) trickery"
+HOMEPAGE="http://packages.qa.debian.org/f/fakeroot.html";
+SRC_URI="mirror://debian/pool/main/${PN:0:1}/${PN}/${P/-/_}.orig.tar.bz2"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux 
~x86-linux"
+IUSE="acl debug static-libs test"
+
+DEPEND="
+       sys-libs/libcap
+       acl? ( sys-apps/acl )
+       test? ( app-arch/sharutils )"
+
+DOCS="AUTHORS BUGS DEBUG README doc/README.saving"
+
+PATCHES=(
+       "${FILESDIR}"/${PN}-1.19-no-acl_h.patch
+       "${FILESDIR}"/${P}-glibc-2.24.patch
+)
+
+src_prepare() {
+       default
+       eautoreconf
+}
+
+src_configure() {
+       export ac_cv_header_sys_acl_h=$(usex acl)
+
+       use debug && append-cppflags "-DLIBFAKEROOT_DEBUGGING"
+       econf \
+               $(use_enable static-libs static)
+}
+
+src_install() {
+       default
+       prune_libtool_files
+}

diff --git a/sys-apps/fakeroot/files/fakeroot-1.20.2-glibc-2.24.patch 
b/sys-apps/fakeroot/files/fakeroot-1.20.2-glibc-2.24.patch
new file mode 100644
index 0000000000..3fd34c8778
--- /dev/null
+++ b/sys-apps/fakeroot/files/fakeroot-1.20.2-glibc-2.24.patch
@@ -0,0 +1,32 @@
+Description: Hide error from dlsym()
+ dlsym(), starting in glibc 2.24 actually reports errors. In our case,
+ we try to get ACL functions which are not in the glibc. This causes
+ failures in test suites, so hide those messages for non-debugging
+ purposes for now. It also makes the build logs annoying to read.
+Author: Julian Andres Klode <juli...@ubuntu.com>
+Origin: vendor
+Bug-Debian: https://bugs.debian.org/830912
+Forwarded: no
+Last-Update: 2016-08-12
+
+--- a/libfakeroot.c
++++ b/libfakeroot.c
+@@ -256,10 +256,16 @@ void load_library_symbols(void){
+  /* clear dlerror() just in case dlsym() legitimately returns NULL */
+     msg = dlerror();
+     *(next_wrap[i].doit)=dlsym(get_libc(), next_wrap[i].name);
++
+     if ( (msg = dlerror()) != NULL){
+-      fprintf (stderr, "dlsym(%s): %s\n", next_wrap[i].name, msg);
+-/*    abort ();*/
++#ifdef LIBFAKEROOT_DEBUGGING
++      if (fakeroot_debug) {
++        fprintf (stderr, "dlsym(%s): %s\n", next_wrap[i].name, msg);
++/*      abort ();*/
++      }
++#endif
+     }
++
+   }
+ }
+ 

diff --git a/sys-apps/fakeroot/metadata.xml b/sys-apps/fakeroot/metadata.xml
index 56c1244130..4eb20a048d 100644
--- a/sys-apps/fakeroot/metadata.xml
+++ b/sys-apps/fakeroot/metadata.xml
@@ -1,8 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd";>
 <pkgmetadata>
-<maintainer type="project">
-       <email>base-sys...@gentoo.org</email>
-       <name>Gentoo Base System</name>
-</maintainer>
+       <maintainer type="project">
+               <email>base-sys...@gentoo.org</email>
+               <name>Gentoo Base System</name>
+       </maintainer>
 </pkgmetadata>

Reply via email to