Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 294719 | Differences between
and this patch

Collapse All | Expand All

(-)a/man/emerge.1 (+5 lines)
Lines 716-721 it possible for \fB\-\-deep\fR to be disabled by default. Link Here
716
Only merge (or pretend to merge) the dependencies of the packages
716
Only merge (or pretend to merge) the dependencies of the packages
717
specified, not the packages themselves.
717
specified, not the packages themselves.
718
.TP
718
.TP
719
.BR "\-\-onlydeps\-with\-rdeps < y | n >"
720
Include run time dependencies when \fB\-\-onlydeps\fR is specified.
721
When this is disabled only build time dependencies are included.  This
722
option is enabled by default.
723
.TP
719
.BR "\-\-package\-moves [ y | n ]"
724
.BR "\-\-package\-moves [ y | n ]"
720
Perform package moves when necessary. This option is enabled
725
Perform package moves when necessary. This option is enabled
721
by default. Package moves are typically applied immediately
726
by default. Package moves are typically applied immediately
(-)a/pym/_emerge/depgraph.py (+5 lines)
Lines 3000-3005 class depgraph(object): Link Here
3000
			edepend["RDEPEND"] = ""
3000
			edepend["RDEPEND"] = ""
3001
			edepend["PDEPEND"] = ""
3001
			edepend["PDEPEND"] = ""
3002
3002
3003
		if pkg.onlydeps and \
3004
			self._frozen_config.myopts.get("--onlydeps-with-rdeps") == 'n':
3005
			edepend["RDEPEND"] = ""
3006
			edepend["PDEPEND"] = ""
3007
3003
		ignore_build_time_deps = False
3008
		ignore_build_time_deps = False
3004
		if pkg.built and not removal_action:
3009
		if pkg.built and not removal_action:
3005
			if self._dynamic_config.myparams.get("bdeps") in ("y", "auto"):
3010
			if self._dynamic_config.myparams.get("bdeps") in ("y", "auto"):
(-)a/pym/_emerge/main.py (+6 lines)
Lines 147-152 def insert_optional_args(args): Link Here
147
		'--jobs'       : valid_integers,
147
		'--jobs'       : valid_integers,
148
		'--keep-going'           : y_or_n,
148
		'--keep-going'           : y_or_n,
149
		'--load-average'         : valid_floats,
149
		'--load-average'         : valid_floats,
150
		'--onlydeps-with-rdeps'  : y_or_n,
150
		'--package-moves'        : y_or_n,
151
		'--package-moves'        : y_or_n,
151
		'--quiet'                : y_or_n,
152
		'--quiet'                : y_or_n,
152
		'--quiet-build'          : y_or_n,
153
		'--quiet-build'          : y_or_n,
Lines 559-564 def parse_opts(tmpcmdline, silent=False): Link Here
559
			"action" : "append",
560
			"action" : "append",
560
		},
561
		},
561
562
563
		"--onlydeps-with-rdeps": {
564
			"help"    : "modify interpretation of depedencies",
565
			"choices" : true_y_or_n
566
		},
567
562
		"--rebuild-exclude": {
568
		"--rebuild-exclude": {
563
			"help"   :"A space separated list of package names or slot atoms. " + \
569
			"help"   :"A space separated list of package names or slot atoms. " + \
564
				"Emerge will not rebuild these packages due to the " + \
570
				"Emerge will not rebuild these packages due to the " + \
(-)a/pym/portage/tests/resolver/test_onlydeps_minimal.py (-1 / +47 lines)
Line 0 Link Here
0
- 
1
# Copyright 2017 Gentoo Foundation
2
# Distributed under the terms of the GNU General Public License v2
3
4
from portage.tests import TestCase
5
from portage.tests.resolver.ResolverPlayground import ResolverPlayground, ResolverPlaygroundTestCase
6
7
class OnlydepsMinimalTestCase(TestCase):
8
9
	def testOnlydepsMinimal(self):
10
		ebuilds = {
11
			"dev-libs/A-1": { "DEPEND": "dev-libs/B",
12
			                  "RDEPEND": "dev-libs/C",
13
			                  "PDEPEND": "dev-libs/D" },
14
			"dev-libs/B-1": { },
15
			"dev-libs/C-1": { },
16
			"dev-libs/D-1": { },
17
			}
18
		installed = {
19
		}
20
21
		test_cases = (
22
			ResolverPlaygroundTestCase(
23
				["dev-libs/A"],
24
				all_permutations = True,
25
				success = True,
26
				options = { "--onlydeps": True,
27
				            "--onlydeps-with-rdeps": "y" },
28
				mergelist = ["dev-libs/B-1",
29
				             "dev-libs/C-1",
30
				             "dev-libs/D-1"]),
31
			ResolverPlaygroundTestCase(
32
				["dev-libs/A"],
33
				all_permutations = True,
34
				success = True,
35
				options = { "--onlydeps": True,
36
				            "--onlydeps-with-rdeps": "n" },
37
				mergelist = ["dev-libs/B-1"]),
38
			)
39
40
		playground = ResolverPlayground(ebuilds=ebuilds,
41
			installed=installed, debug=False)
42
		try:
43
			for test_case in test_cases:
44
				playground.run_TestCase(test_case)
45
				self.assertEqual(test_case.test_success, True, test_case.fail_msg)
46
		finally:
47
			playground.cleanup()

Return to bug 294719