Gentoo Archives: gentoo-commits

From: "Zac Medico (zmedico)" <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] portage r13246 - in main/trunk: man pym/_emerge
Date: Sun, 29 Mar 2009 19:26:53
Message-Id: E1Lo0eh-0003DB-5x@stork.gentoo.org
1 Author: zmedico
2 Date: 2009-03-29 19:26:50 +0000 (Sun, 29 Mar 2009)
3 New Revision: 13246
4
5 Modified:
6 main/trunk/man/emerge.1
7 main/trunk/pym/_emerge/__init__.py
8 Log:
9 Add a --root option that sets $ROOT (complements the --config-root option).
10
11
12 Modified: main/trunk/man/emerge.1
13 ===================================================================
14 --- main/trunk/man/emerge.1 2009-03-29 19:15:01 UTC (rev 13245)
15 +++ main/trunk/man/emerge.1 2009-03-29 19:26:50 UTC (rev 13246)
16 @@ -427,6 +427,9 @@
17 not trigger reinstallation when flags that the user has not
18 enabled are added or removed.
19 .TP
20 +.BR \-\-root=DIR
21 +Set the \fBROOT\fR environment variable.
22 +.TP
23 .BR "\-\-root\-deps"
24 Install build\-time dependencies to \fBROOT\fR instead of /. This option
25 should not be enabled under normal circumstances. For currently supported
26 @@ -488,7 +491,8 @@
27 .TP
28 \fBROOT\fR = \fI[path]\fR
29 Use \fBROOT\fR to specify the target root filesystem to be used for
30 -merging packages or ebuilds. This variable can be set in \fBmake.conf\fR(5).
31 +merging packages or ebuilds. This variable can be set via the \fB\-\-root\fR
32 +option or in \fBmake.conf\fR(5) (the command line overrides other settings).
33 .br
34 Defaults to /.
35 .TP
36
37 Modified: main/trunk/pym/_emerge/__init__.py
38 ===================================================================
39 --- main/trunk/pym/_emerge/__init__.py 2009-03-29 19:15:01 UTC (rev 13245)
40 +++ main/trunk/pym/_emerge/__init__.py 2009-03-29 19:26:50 UTC (rev 13246)
41 @@ -14800,7 +14800,11 @@
42 "help":"specify conditions to trigger package reinstallation",
43 "type":"choice",
44 "choices":["changed-use"]
45 - }
46 + },
47 + "--root": {
48 + "help" : "specify the target root filesystem for merging packages",
49 + "action" : "store"
50 + },
51 }
52
53 from optparse import OptionParser
54 @@ -15325,6 +15329,8 @@
55 os.environ["PORTAGE_DEBUG"] = "1"
56 if "--config-root" in myopts:
57 os.environ["PORTAGE_CONFIGROOT"] = myopts["--config-root"]
58 + if "--root" in myopts:
59 + os.environ["ROOT"] = myopts["--root"]
60
61 # Portage needs to ensure a sane umask for the files it creates.
62 os.umask(022)