From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 2BE8B1382C5 for ; Sun, 4 Mar 2018 21:05:16 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 86124E09B6; Sun, 4 Mar 2018 21:05:13 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 4D20DE09B6 for ; Sun, 4 Mar 2018 21:05:13 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 41CF9335CEB for ; Sun, 4 Mar 2018 21:05:12 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 76C37242 for ; Sun, 4 Mar 2018 21:05:09 +0000 (UTC) From: "Michał Górny" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" Message-ID: <1520197433.04a8eba03539b6e401022aee3aacf1fde3a8eeca.mgorny@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: bin/, bin/ebuild-helpers/ X-VCS-Repository: proj/portage X-VCS-Files: bin/eapi.sh bin/ebuild-helpers/dolib bin/ebuild-helpers/dolib.a bin/ebuild-helpers/dolib.so bin/phase-helpers.sh X-VCS-Directories: bin/ebuild-helpers/ bin/ X-VCS-Committer: mgorny X-VCS-Committer-Name: Michał Górny X-VCS-Revision: 04a8eba03539b6e401022aee3aacf1fde3a8eeca X-VCS-Branch: master Date: Sun, 4 Mar 2018 21:05:09 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 6dc517d5-cfd8-49b0-8e52-c3abf19da000 X-Archives-Hash: 9475aeb6d4632e9935b308a4f017fd64 commit: 04a8eba03539b6e401022aee3aacf1fde3a8eeca Author: Michał Górny gentoo org> AuthorDate: Thu Sep 21 14:43:29 2017 +0000 Commit: Michał Górny gentoo org> CommitDate: Sun Mar 4 21:03:53 2018 +0000 URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=04a8eba0 Ban dolib/libopts for EAPI 7 Bug: https://bugs.gentoo.org/630416 bin/eapi.sh | 4 ++++ bin/ebuild-helpers/dolib | 7 ++++++- bin/ebuild-helpers/dolib.a | 4 ++-- bin/ebuild-helpers/dolib.so | 4 ++-- bin/phase-helpers.sh | 6 +++++- 5 files changed, 19 insertions(+), 6 deletions(-) diff --git a/bin/eapi.sh b/bin/eapi.sh index 38d91a17f..5a1a9aa40 100644 --- a/bin/eapi.sh +++ b/bin/eapi.sh @@ -60,6 +60,10 @@ ___eapi_has_dohtml_deprecated() { [[ ${1-${EAPI-0}} == 6 ]] } +___eapi_has_dolib_libopts() { + [[ ${1-${EAPI-0}} =~ ^(0|1|2|3|4|4-python|4-slot-abi|5|5-hdepend|5-progress|6)$ ]] +} + ___eapi_has_docompress() { [[ ! ${1-${EAPI-0}} =~ ^(0|1|2|3)$ ]] } diff --git a/bin/ebuild-helpers/dolib b/bin/ebuild-helpers/dolib index a11bad463..62e04b385 100755 --- a/bin/ebuild-helpers/dolib +++ b/bin/ebuild-helpers/dolib @@ -1,9 +1,14 @@ #!/bin/bash -# Copyright 1999-2012 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 source "${PORTAGE_BIN_PATH}"/isolated-functions.sh || exit 1 +if [[ -z ${PORTAGE_INTERNAL_DOLIB} ]] && ! ___eapi_has_dolib_libopts; then + die "'${0##*/}' has been banned for EAPI '$EAPI'" + exit 1 +fi + if ! ___eapi_has_prefix_variables; then ED=${D} fi diff --git a/bin/ebuild-helpers/dolib.a b/bin/ebuild-helpers/dolib.a index 61961e4ed..5ea126b5d 100755 --- a/bin/ebuild-helpers/dolib.a +++ b/bin/ebuild-helpers/dolib.a @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 1999-2006 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -LIBOPTIONS='-m0644' exec dolib "$@" +LIBOPTIONS='-m0644' PORTAGE_INTERNAL_DOLIB=1 exec dolib "$@" diff --git a/bin/ebuild-helpers/dolib.so b/bin/ebuild-helpers/dolib.so index eab8c9110..a3b579e5e 100755 --- a/bin/ebuild-helpers/dolib.so +++ b/bin/ebuild-helpers/dolib.so @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 1999-2006 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -LIBOPTIONS='-m0755' exec dolib "$@" +LIBOPTIONS='-m0755' PORTAGE_INTERNAL_DOLIB=1 exec dolib "$@" diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh index 49dad234d..12ccf6716 100644 --- a/bin/phase-helpers.sh +++ b/bin/phase-helpers.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 export DESTTREE=/usr @@ -111,6 +111,10 @@ exeopts() { } libopts() { + if ! ___eapi_has_dolib_libopts; then + die "'${FUNCNAME}' has been banned for EAPI '$EAPI'" + fi + export LIBOPTIONS="$@" # `install` should never be called with '-s' ...