From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1REbBh-0000Zz-Ll for garchives@archives.gentoo.org; Fri, 14 Oct 2011 06:24:09 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 40CE121C06C; Fri, 14 Oct 2011 06:24:02 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 039EC21C06C for ; Fri, 14 Oct 2011 06:24:01 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 6D2EF1B4026 for ; Fri, 14 Oct 2011 06:24:01 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 7223880042 for ; Fri, 14 Oct 2011 06:24:00 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: Subject: [gentoo-commits] proj/portage:master commit in: man/, pym/portage/package/ebuild/, bin/ X-VCS-Repository: proj/portage X-VCS-Files: bin/misc-functions.sh man/ebuild.5 pym/portage/package/ebuild/doebuild.py X-VCS-Directories: man/ pym/portage/package/ebuild/ bin/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: dcb42a417355510284a35c08a4bf849047122a5c Date: Fri, 14 Oct 2011 06:24:00 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: X-Archives-Hash: ad16db98b3171f84afeafd47afc71a79 commit: dcb42a417355510284a35c08a4bf849047122a5c Author: Zac Medico gentoo org> AuthorDate: Fri Oct 14 06:14:40 2011 +0000 Commit: Zac Medico gentoo org> CommitDate: Fri Oct 14 06:14:40 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/portage.git;a= =3Dcommit;h=3Ddcb42a41 Add QA_SONAME_NO_SYMLINK for bug #387053. --- bin/misc-functions.sh | 4 ++++ man/ebuild.5 | 6 ++++++ pym/portage/package/ebuild/doebuild.py | 28 ++++++++++++++++++++++++++= ++ 3 files changed, 38 insertions(+), 0 deletions(-) diff --git a/bin/misc-functions.sh b/bin/misc-functions.sh index 882d171..b3e62c5 100755 --- a/bin/misc-functions.sh +++ b/bin/misc-functions.sh @@ -372,6 +372,10 @@ install_qa_check() { fi done } =20 + [ -n "${QA_SONAME_NO_SYMLINK}" ] && \ + echo "${QA_SONAME_NO_SYMLINK}" > \ + "${PORTAGE_BUILDDIR}"/build-info/QA_SONAME_NO_SYMLINK + if [[ ${insecure_rpath} -eq 1 ]] ; then die "Aborting due to serious QA concerns with RUNPATH/RPATH" elif [[ -n ${die_msg} ]] && has stricter ${FEATURES} ; then diff --git a/man/ebuild.5 b/man/ebuild.5 index 0ad5da1..2d58c9e 100644 --- a/man/ebuild.5 +++ b/man/ebuild.5 @@ -620,6 +620,12 @@ This should contain a list of file paths, relative t= o the image directory, of shared libraries that lack SONAMEs. The paths may contain regular expres= sions with escape\-quoted special characters. .TP +\fBQA_SONAME_NO_SYMLINK\fR +This should contain a list of file paths, relative to the image director= y, of +shared libraries that have SONAMEs but should not have a corresponding S= ONAME +symlink in the same directory. The paths may contain regular expressions +with escape\-quoted special characters. +.TP \fBQA_DT_NEEDED\fR This should contain a list of file paths, relative to the image director= y, of shared libraries that lack NEEDED entries. The paths may contain regular diff --git a/pym/portage/package/ebuild/doebuild.py b/pym/portage/package= /ebuild/doebuild.py index 156da1a..6ebe133 100644 --- a/pym/portage/package/ebuild/doebuild.py +++ b/pym/portage/package/ebuild/doebuild.py @@ -1807,6 +1807,32 @@ def _post_src_install_soname_symlinks(mysettings, = out): if f is not None: f.close() =20 + qa_no_symlink =3D "" + f =3D None + try: + f =3D io.open(_unicode_encode(os.path.join( + mysettings["PORTAGE_BUILDDIR"], + "build-info", "QA_SONAME_NO_SYMLINK"), + encoding=3D_encodings['fs'], errors=3D'strict'), + mode=3D'r', encoding=3D_encodings['repo.content'], + errors=3D'replace') + qa_no_symlink =3D f.read() + except IOError as e: + if e.errno not in (errno.ENOENT, errno.ESTALE): + raise + finally: + if f is not None: + f.close() + + qa_no_symlink =3D qa_no_symlink.split() + if qa_no_symlink: + if len(qa_no_symlink) > 1: + qa_no_symlink =3D "|".join("(%s)" % x for x in qa_no_symlink) + qa_no_symlink =3D "^(%s)$" % qa_no_symlink + else: + qa_no_symlink =3D "^%s$" % qa_no_symlink[0] + qa_no_symlink =3D re.compile(qa_no_symlink) + libpaths =3D set(portage.util.getlibpaths( mysettings["ROOT"], env=3Dmysettings)) libpath_inodes =3D set() @@ -1863,6 +1889,8 @@ def _post_src_install_soname_symlinks(mysettings, o= ut): continue if not is_libdir(os.path.dirname(obj)): continue + if qa_no_symlink and qa_no_symlink.match(obj.strip(os.sep)) is None: + continue =20 obj_file_path =3D os.path.join(image_dir, obj.lstrip(os.sep)) sym_file_path =3D os.path.join(os.path.dirname(obj_file_path), soname)