public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] proj/portage:prefix commit in: bin/, pym/portage/
@ 2018-06-25  8:34 Fabian Groffen
  0 siblings, 0 replies; 2+ messages in thread
From: Fabian Groffen @ 2018-06-25  8:34 UTC (permalink / raw
  To: gentoo-commits

commit:     d34d38d399483c69d4a50aca3877277cc6a77e58
Author:     Fabian Groffen <grobian <AT> gentoo <DOT> org>
AuthorDate: Mon Jun 25 08:34:25 2018 +0000
Commit:     Fabian Groffen <grobian <AT> gentoo <DOT> org>
CommitDate: Mon Jun 25 08:34:25 2018 +0000
URL:        https://gitweb.gentoo.org/proj/portage.git/commit/?id=d34d38d3

stacked-prefix: flag as Prefix modification

 bin/phase-helpers.sh | 2 ++
 pym/portage/const.py | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh
index c5a818db7..3775022e1 100644
--- a/bin/phase-helpers.sh
+++ b/bin/phase-helpers.sh
@@ -927,6 +927,7 @@ ___best_version_and_has_version_common() {
 			fi ;;
 	esac
 
+	# PREFIX LOCAL: stacked-prefix feature
 	if ___eapi_has_prefix_variables         &&
 	   has "${root_arg}" '--host-root' '-b' &&
 	   has stacked-prefix ${FEATURES}       &&
@@ -940,6 +941,7 @@ ___best_version_and_has_version_common() {
 		# In a "stacked prefix" we explicitly utilize this situation.
 		"${FUNCNAME[1]}" "${atom}" && return 0
 	fi
+	# END PREFIX LOCAL
 
 	if [[ -n $PORTAGE_IPC_DAEMON ]] ; then
 		cmd+=("${PORTAGE_BIN_PATH}"/ebuild-ipc "${FUNCNAME[1]}" "${root}" "${atom}")

diff --git a/pym/portage/const.py b/pym/portage/const.py
index 342b09174..65bcf46f9 100644
--- a/pym/portage/const.py
+++ b/pym/portage/const.py
@@ -202,7 +202,7 @@ SUPPORTED_FEATURES       = frozenset([
 	"splitdebug",
 	"split-elog",
 	"split-log",
-	"stacked-prefix",
+	"stacked-prefix",  # PREFIX LOCAL
 	"strict",
 	"strict-keepdir",
 	"stricter",


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [gentoo-commits] proj/portage:prefix commit in: bin/, pym/portage/
@ 2018-06-25  8:34 Fabian Groffen
  0 siblings, 0 replies; 2+ messages in thread
From: Fabian Groffen @ 2018-06-25  8:34 UTC (permalink / raw
  To: gentoo-commits

commit:     ab0b90331a2a4810eedb5cec4f50d7777ac9d848
Author:     Michael Haubenwallner <haubi <AT> gentoo <DOT> org>
AuthorDate: Tue Jun 19 14:39:12 2018 +0000
Commit:     Fabian Groffen <grobian <AT> gentoo <DOT> org>
CommitDate: Mon Jun 25 08:32:29 2018 +0000
URL:        https://gitweb.gentoo.org/proj/portage.git/commit/?id=ab0b9033

introduce the 'stacked-prefix' FEATURE

When we merge into another EPREFIX, but not into some ROOT,
and CHOST is equal to CBUILD, build tools found in EPREFIX
perfectly work for the current build environment.
In a "stacked prefix" we explicitly utilize this situation.

This is useful during prefix bootstrap (#655414, #655326), but also to
build packages for targets unable to support the full portage toolchain
(native Windows, MinGW), but otherwise do not require a full cross
compilation setup.

Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org>

 bin/phase-helpers.sh | 14 ++++++++++++++
 pym/portage/const.py |  1 +
 2 files changed, 15 insertions(+)

diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh
index 75d92b407..c5a818db7 100644
--- a/bin/phase-helpers.sh
+++ b/bin/phase-helpers.sh
@@ -927,6 +927,20 @@ ___best_version_and_has_version_common() {
 			fi ;;
 	esac
 
+	if ___eapi_has_prefix_variables         &&
+	   has "${root_arg}" '--host-root' '-b' &&
+	   has stacked-prefix ${FEATURES}       &&
+	   [[ -z ${ROOT%/} ]]                   &&
+	   [[ ${CBUILD} == ${CHOST} ]]          &&
+	   [[ ${EPREFIX} != ${BROOT-${PORTAGE_OVERRIDE_EPREFIX}} ]] &&
+	:; then
+		# When we merge into another EPREFIX, but not into some ROOT,
+		# and CHOST is equal to CBUILD, build tools found in EPREFIX
+		# perfectly work for the current build environment.
+		# In a "stacked prefix" we explicitly utilize this situation.
+		"${FUNCNAME[1]}" "${atom}" && return 0
+	fi
+
 	if [[ -n $PORTAGE_IPC_DAEMON ]] ; then
 		cmd+=("${PORTAGE_BIN_PATH}"/ebuild-ipc "${FUNCNAME[1]}" "${root}" "${atom}")
 	else

diff --git a/pym/portage/const.py b/pym/portage/const.py
index 3c23c85ed..342b09174 100644
--- a/pym/portage/const.py
+++ b/pym/portage/const.py
@@ -202,6 +202,7 @@ SUPPORTED_FEATURES       = frozenset([
 	"splitdebug",
 	"split-elog",
 	"split-log",
+	"stacked-prefix",
 	"strict",
 	"strict-keepdir",
 	"stricter",


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-06-25  8:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-06-25  8:34 [gentoo-commits] proj/portage:prefix commit in: bin/, pym/portage/ Fabian Groffen
  -- strict thread matches above, loose matches on Subject: below --
2018-06-25  8:34 Fabian Groffen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox