1 |
Author: zmedico |
2 |
Date: 2009-04-30 06:47:20 +0000 (Thu, 30 Apr 2009) |
3 |
New Revision: 13425 |
4 |
|
5 |
Modified: |
6 |
main/branches/2.1.6/man/emerge.1 |
7 |
main/branches/2.1.6/pym/_emerge/__init__.py |
8 |
Log: |
9 |
Add a --root option that sets $ROOT (complements the --config-root option). |
10 |
(trunk r13246) |
11 |
|
12 |
Modified: main/branches/2.1.6/man/emerge.1 |
13 |
=================================================================== |
14 |
--- main/branches/2.1.6/man/emerge.1 2009-04-30 06:47:03 UTC (rev 13424) |
15 |
+++ main/branches/2.1.6/man/emerge.1 2009-04-30 06:47:20 UTC (rev 13425) |
16 |
@@ -424,6 +424,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 |
@@ -485,7 +488,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/branches/2.1.6/pym/_emerge/__init__.py |
38 |
=================================================================== |
39 |
--- main/branches/2.1.6/pym/_emerge/__init__.py 2009-04-30 06:47:03 UTC (rev 13424) |
40 |
+++ main/branches/2.1.6/pym/_emerge/__init__.py 2009-04-30 06:47:20 UTC (rev 13425) |
41 |
@@ -14445,7 +14445,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 |
@@ -14838,6 +14842,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) |