Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 323962 Details for
Bug 317337
[Future EAPI]: BDEPEND (DEPEND) for classifying build time dependencies as CBUILD or CHOST ones + SYSROOT for CHOST deps
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
HDEPEND for Portage 2.1.11.17
portage-2.1.11.17-hdepend-1.patch (text/plain), 11.33 KB, created by
Ambroz Bizjak
on 2012-09-16 03:15:49 UTC
(
hide
)
Description:
HDEPEND for Portage 2.1.11.17
Filename:
MIME Type:
Creator:
Ambroz Bizjak
Created:
2012-09-16 03:15:49 UTC
Size:
11.33 KB
patch
obsolete
>diff -urN portage-2.1.11.17/bin/ebuild.sh portage-2.1.11.17.new/bin/ebuild.sh >--- portage-2.1.11.17/bin/ebuild.sh 2012-09-14 04:39:24.000000000 +0200 >+++ portage-2.1.11.17.new/bin/ebuild.sh 2012-09-16 05:01:12.553157691 +0200 >@@ -221,6 +221,7 @@ > local B_DEPEND > local B_RDEPEND > local B_PDEPEND >+ local B_HDEPEND > while [ "$1" ]; do > location="${ECLASSDIR}/${1}.eclass" > olocation="" >@@ -263,20 +264,21 @@ > EBUILD_OVERLAY_ECLASSES="${EBUILD_OVERLAY_ECLASSES} ${location}" > fi > >- #We need to back up the value of DEPEND and RDEPEND to B_DEPEND and B_RDEPEND >+ #We need to back up the values of *DEPEND to B_*DEPEND > #(if set).. and then restore them after the inherit call. > > #turn off glob expansion > set -f > > # Retain the old data and restore it later. >- unset B_IUSE B_REQUIRED_USE B_DEPEND B_RDEPEND B_PDEPEND >+ unset B_IUSE B_REQUIRED_USE B_DEPEND B_RDEPEND B_PDEPEND B_HDEPEND > [ "${IUSE+set}" = set ] && B_IUSE="${IUSE}" > [ "${REQUIRED_USE+set}" = set ] && B_REQUIRED_USE="${REQUIRED_USE}" > [ "${DEPEND+set}" = set ] && B_DEPEND="${DEPEND}" > [ "${RDEPEND+set}" = set ] && B_RDEPEND="${RDEPEND}" > [ "${PDEPEND+set}" = set ] && B_PDEPEND="${PDEPEND}" >- unset IUSE REQUIRED_USE DEPEND RDEPEND PDEPEND >+ [ "${HDEPEND+set}" = set ] && B_HDEPEND="${HDEPEND}" >+ unset IUSE REQUIRED_USE DEPEND RDEPEND PDEPEND HDEPEND > #turn on glob expansion > set +f > >@@ -292,6 +294,7 @@ > [ "${DEPEND+set}" = set ] && E_DEPEND+="${E_DEPEND:+ }${DEPEND}" > [ "${RDEPEND+set}" = set ] && E_RDEPEND+="${E_RDEPEND:+ }${RDEPEND}" > [ "${PDEPEND+set}" = set ] && E_PDEPEND+="${E_PDEPEND:+ }${PDEPEND}" >+ [ "${HDEPEND+set}" = set ] && E_HDEPEND+="${E_HDEPEND:+ }${HDEPEND}" > > [ "${B_IUSE+set}" = set ] && IUSE="${B_IUSE}" > [ "${B_IUSE+set}" = set ] || unset IUSE >@@ -308,6 +311,9 @@ > [ "${B_PDEPEND+set}" = set ] && PDEPEND="${B_PDEPEND}" > [ "${B_PDEPEND+set}" = set ] || unset PDEPEND > >+ [ "${B_HDEPEND+set}" = set ] && HDEPEND="${B_HDEPEND}" >+ [ "${B_HDEPEND+set}" = set ] || unset HDEPEND >+ > #turn on glob expansion > set +f > >@@ -534,8 +540,8 @@ > # In order to ensure correct interaction between ebuilds and > # eclasses, they need to be unset before this process of > # interaction begins. >- unset EAPI DEPEND RDEPEND PDEPEND INHERITED IUSE REQUIRED_USE \ >- ECLASS E_IUSE E_REQUIRED_USE E_DEPEND E_RDEPEND E_PDEPEND >+ unset EAPI DEPEND RDEPEND PDEPEND HDEPEND INHERITED IUSE REQUIRED_USE \ >+ ECLASS E_IUSE E_REQUIRED_USE E_DEPEND E_RDEPEND E_PDEPEND E_HDEPEND > > if [[ $PORTAGE_DEBUG != 1 || ${-/x/} != $- ]] ; then > source "$EBUILD" || die "error sourcing ebuild" >@@ -566,9 +572,10 @@ > DEPEND+="${DEPEND:+ }${E_DEPEND}" > RDEPEND+="${RDEPEND:+ }${E_RDEPEND}" > PDEPEND+="${PDEPEND:+ }${E_PDEPEND}" >+ HDEPEND+="${HDEPEND:+ }${E_HDEPEND}" > REQUIRED_USE+="${REQUIRED_USE:+ }${E_REQUIRED_USE}" > >- unset ECLASS E_IUSE E_REQUIRED_USE E_DEPEND E_RDEPEND E_PDEPEND \ >+ unset ECLASS E_IUSE E_REQUIRED_USE E_DEPEND E_RDEPEND E_PDEPEND E_HDEPEND \ > __INHERITED_QA_CACHE > > # alphabetically ordered by $EBUILD_PHASE value >@@ -670,9 +677,15 @@ > > auxdbkeys="DEPEND RDEPEND SLOT SRC_URI RESTRICT HOMEPAGE LICENSE > DESCRIPTION KEYWORDS INHERITED IUSE REQUIRED_USE PDEPEND PROVIDE EAPI >- PROPERTIES DEFINED_PHASES UNUSED_05 UNUSED_04 >+ PROPERTIES DEFINED_PHASES HDEPEND UNUSED_04 > UNUSED_03 UNUSED_02 UNUSED_01" > >+ case "$EAPI" in >+ 0|1|2|3|4) >+ unset HDEPEND >+ ;; >+ esac >+ > # The extra $(echo) commands remove newlines. > if [ -n "${dbkey}" ] ; then > > "${dbkey}" >diff -urN portage-2.1.11.17/pym/_emerge/depgraph.py portage-2.1.11.17.new/pym/_emerge/depgraph.py >--- portage-2.1.11.17/pym/_emerge/depgraph.py 2012-09-14 04:39:24.000000000 +0200 >+++ portage-2.1.11.17.new/pym/_emerge/depgraph.py 2012-09-16 04:24:57.753212191 +0200 >@@ -503,7 +503,7 @@ > > pkg_tree_map = RootConfig.pkg_tree_map > >- _dep_keys = ["DEPEND", "RDEPEND", "PDEPEND"] >+ _dep_keys = ["DEPEND", "RDEPEND", "PDEPEND", "HDEPEND"] > > def __init__(self, settings, trees, myopts, myparams, spinner, > frozen_config=None, backtrack_parameters=BacktrackParameter(), allow_backtracking=False): >@@ -1682,7 +1682,7 @@ > removal_action = "remove" in self._dynamic_config.myparams > > edepend={} >- depkeys = ["DEPEND","RDEPEND","PDEPEND"] >+ depkeys = ["DEPEND","RDEPEND","PDEPEND","HDEPEND"] > for k in depkeys: > edepend[k] = metadata[k] > >@@ -1710,18 +1710,26 @@ > # Removal actions never traverse ignored buildtime > # dependencies, so it's safe to discard them early. > edepend["DEPEND"] = "" >+ edepend["HDEPEND"] = "" > ignore_build_time_deps = True > > if removal_action: > depend_root = myroot > else: >- depend_root = self._frozen_config._running_root.root >- root_deps = self._frozen_config.myopts.get("--root-deps") >- if root_deps is not None: >- if root_deps is True: >- depend_root = myroot >- elif root_deps == "rdeps": >- ignore_build_time_deps = True >+ if pkg.metadata['EAPI'] not in ('0', '1', '2', '3', '4'): >+ # For ebuilds that have EAPI 5 or later, --root-deps >+ # has no effect, since DEPEND has been divided into two parts: >+ # DEPEND for build-time target dependencies, and HDEPEND for >+ # build-time host dependencies. >+ depend_root = myroot >+ else: >+ depend_root = self._frozen_config._running_root.root >+ root_deps = self._frozen_config.myopts.get("--root-deps") >+ if root_deps is not None: >+ if root_deps is True: >+ depend_root = myroot >+ elif root_deps == "rdeps": >+ ignore_build_time_deps = True > > # If rebuild mode is not enabled, it's safe to discard ignored > # build-time dependencies. If you want these deps to be traversed >@@ -1729,6 +1737,7 @@ > if ignore_build_time_deps and \ > not self._rebuild.rebuild: > edepend["DEPEND"] = "" >+ edepend["HDEPEND"] = "" > > deps = ( > (depend_root, edepend["DEPEND"], >@@ -1738,7 +1747,11 @@ > (myroot, edepend["RDEPEND"], > self._priority(runtime=True)), > (myroot, edepend["PDEPEND"], >- self._priority(runtime_post=True)) >+ self._priority(runtime_post=True)), >+ (self._frozen_config._running_root.root, edepend["HDEPEND"], >+ self._priority(buildtime=True, >+ optional=(pkg.built or ignore_build_time_deps), >+ ignored=ignore_build_time_deps)) > ) > > debug = "--debug" in self._frozen_config.myopts >@@ -2835,7 +2848,7 @@ > return [pkg.slot_atom for pkg in greedy_pkgs] > > blockers = {} >- blocker_dep_keys = ["DEPEND", "PDEPEND", "RDEPEND"] >+ blocker_dep_keys = ["DEPEND", "PDEPEND", "RDEPEND", "HDEPEND"] > for pkg in greedy_pkgs + [highest_pkg]: > dep_str = " ".join(pkg.metadata[k] for k in blocker_dep_keys) > try: >@@ -3096,7 +3109,7 @@ > > if target_atom is not None and isinstance(node, Package): > affecting_use = set() >- for dep_str in "DEPEND", "RDEPEND", "PDEPEND": >+ for dep_str in "DEPEND", "RDEPEND", "PDEPEND", "HDEPEND": > try: > affecting_use.update(extract_affecting_use( > node.metadata[dep_str], target_atom, >@@ -3180,10 +3193,12 @@ > dep_strings.add(node.metadata["DEPEND"]) > dep_strings.add(node.metadata["RDEPEND"]) > dep_strings.add(node.metadata["PDEPEND"]) >+ dep_strings.add(node.metadata["HDEPEND"]) > else: > for priority in priorities: > if priority.buildtime: > dep_strings.add(node.metadata["DEPEND"]) >+ dep_strings.add(node.metadata["HDEPEND"]) > if priority.runtime: > dep_strings.add(node.metadata["RDEPEND"]) > if priority.runtime_post: >@@ -4126,7 +4141,7 @@ > if pkg not in self._dynamic_config.digraph.nodes: > return False > >- for key in "DEPEND", "RDEPEND", "PDEPEND", "LICENSE": >+ for key in "DEPEND", "RDEPEND", "PDEPEND", "HDEPEND", "LICENSE": > dep = pkg.metadata[key] > old_val = set(portage.dep.use_reduce(dep, pkg.use.enabled, is_valid_flag=pkg.iuse.is_valid_flag, flat=True)) > new_val = set(portage.dep.use_reduce(dep, new_use, is_valid_flag=pkg.iuse.is_valid_flag, flat=True)) >diff -urN portage-2.1.11.17/pym/portage/dbapi/bintree.py portage-2.1.11.17.new/pym/portage/dbapi/bintree.py >--- portage-2.1.11.17/pym/portage/dbapi/bintree.py 2012-09-14 04:39:24.000000000 +0200 >+++ portage-2.1.11.17.new/pym/portage/dbapi/bintree.py 2012-09-16 04:08:19.876237196 +0200 >@@ -75,6 +75,7 @@ > ["BUILD_TIME", "CHOST", "DEPEND", "EAPI", "IUSE", "KEYWORDS", > "LICENSE", "PDEPEND", "PROPERTIES", "PROVIDE", > "RDEPEND", "repository", "RESTRICT", "SLOT", "USE", "DEFINED_PHASES", >+ "HDEPEND", > ]) > self._aux_cache_slot_dict = slot_dict_class(self._aux_cache_keys) > self._aux_cache = {} >@@ -304,11 +305,11 @@ > ["BUILD_TIME", "CHOST", "DEPEND", "DESCRIPTION", "EAPI", > "IUSE", "KEYWORDS", "LICENSE", "PDEPEND", "PROPERTIES", > "PROVIDE", "RDEPEND", "repository", "SLOT", "USE", "DEFINED_PHASES", >- "BASE_URI"] >+ "BASE_URI", "HDEPEND"] > self._pkgindex_aux_keys = list(self._pkgindex_aux_keys) > self._pkgindex_use_evaluated_keys = \ > ("LICENSE", "RDEPEND", "DEPEND", >- "PDEPEND", "PROPERTIES", "PROVIDE") >+ "PDEPEND", "PROPERTIES", "PROVIDE", "HDEPEND") > self._pkgindex_header_keys = set([ > "ACCEPT_KEYWORDS", "ACCEPT_LICENSE", > "ACCEPT_PROPERTIES", "CBUILD", >@@ -330,6 +331,7 @@ > "SLOT" : "0", > "USE" : "", > "DEFINED_PHASES" : "", >+ "HDEPEND" : "", > } > self._pkgindex_inherited_keys = ["CHOST", "repository"] > >diff -urN portage-2.1.11.17/pym/portage/dbapi/porttree.py portage-2.1.11.17.new/pym/portage/dbapi/porttree.py >--- portage-2.1.11.17/pym/portage/dbapi/porttree.py 2012-09-14 04:39:24.000000000 +0200 >+++ portage-2.1.11.17.new/pym/portage/dbapi/porttree.py 2012-09-16 04:09:09.627235949 +0200 >@@ -189,7 +189,7 @@ > self._aux_cache_keys = set( > ["DEPEND", "EAPI", "INHERITED", "IUSE", "KEYWORDS", "LICENSE", > "PDEPEND", "PROPERTIES", "PROVIDE", "RDEPEND", "repository", >- "RESTRICT", "SLOT", "DEFINED_PHASES", "REQUIRED_USE"]) >+ "RESTRICT", "SLOT", "DEFINED_PHASES", "REQUIRED_USE", "HDEPEND"]) > > self._aux_cache = {} > self._broken_ebuilds = set() >diff -urN portage-2.1.11.17/pym/portage/dbapi/vartree.py portage-2.1.11.17.new/pym/portage/dbapi/vartree.py >--- portage-2.1.11.17/pym/portage/dbapi/vartree.py 2012-09-14 04:39:24.000000000 +0200 >+++ portage-2.1.11.17.new/pym/portage/dbapi/vartree.py 2012-09-16 04:09:33.983235339 +0200 >@@ -165,6 +165,7 @@ > "EAPI", "HOMEPAGE", "IUSE", "KEYWORDS", > "LICENSE", "PDEPEND", "PROPERTIES", "PROVIDE", "RDEPEND", > "repository", "RESTRICT" , "SLOT", "USE", "DEFINED_PHASES", >+ "HDEPEND", > ]) > self._aux_cache_obj = None > self._aux_cache_filename = os.path.join(self._eroot, >diff -urN portage-2.1.11.17/pym/portage/__init__.py portage-2.1.11.17.new/pym/portage/__init__.py >--- portage-2.1.11.17/pym/portage/__init__.py 2012-09-14 04:40:15.000000000 +0200 >+++ portage-2.1.11.17.new/pym/portage/__init__.py 2012-09-16 04:51:51.133171760 +0200 >@@ -414,7 +414,7 @@ > > _doebuild_manifest_exempt_depend = 0 > >-_testing_eapis = frozenset(["4-python", "4-slot-abi", "5_pre2"]) >+_testing_eapis = frozenset(["4-python", "4-slot-abi", "4-hdepend", "5_pre2"]) > _deprecated_eapis = frozenset(["4_pre1", "3_pre2", "3_pre1", "5_pre1"]) > > def _eapi_is_deprecated(eapi): >@@ -472,7 +472,7 @@ > 'RESTRICT', 'HOMEPAGE', 'LICENSE', 'DESCRIPTION', > 'KEYWORDS', 'INHERITED', 'IUSE', 'REQUIRED_USE', > 'PDEPEND', 'PROVIDE', 'EAPI', >- 'PROPERTIES', 'DEFINED_PHASES', 'UNUSED_05', 'UNUSED_04', >+ 'PROPERTIES', 'DEFINED_PHASES', 'HDEPEND', 'UNUSED_04', > 'UNUSED_03', 'UNUSED_02', 'UNUSED_01', > ) > auxdbkeylen=len(auxdbkeys)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 317337
:
229283
|
242403
|
242691
|
323962
|
323992
|
323994
|
324000
|
324002
|
324038
|
324142