1 |
Author: grobian |
2 |
Date: 2010-01-08 07:48:41 +0000 (Fri, 08 Jan 2010) |
3 |
New Revision: 15175 |
4 |
|
5 |
Modified: |
6 |
main/branches/prefix/bin/ebuild-helpers/doins |
7 |
main/branches/prefix/bin/repoman |
8 |
main/branches/prefix/man/repoman.1 |
9 |
main/branches/prefix/pym/portage/dbapi/vartree.py |
10 |
Log: |
11 |
Merged from trunk -r15169:15174 |
12 |
|
13 |
| 15172 | Fix it so an empty directory given to doins -r does not | |
14 |
| zmedico | trigger failure. | |
15 |
|
16 |
| 15173 | Add a TODO comment for improved handling of /lib/modules. | |
17 |
| zmedico | | |
18 |
|
19 |
| 15174 | Bug #269225 - Warn about virtuals with non-empty HOMEPAGE or | |
20 |
| zmedico | LICENSE. Thanks to Ulrich M?\195?\188ller <ulm@g.o> for this patch. | |
21 |
|
22 |
|
23 |
Modified: main/branches/prefix/bin/ebuild-helpers/doins |
24 |
=================================================================== |
25 |
--- main/branches/prefix/bin/ebuild-helpers/doins 2010-01-07 20:19:54 UTC (rev 15174) |
26 |
+++ main/branches/prefix/bin/ebuild-helpers/doins 2010-01-08 07:48:41 UTC (rev 15175) |
27 |
@@ -71,16 +71,12 @@ |
28 |
} |
29 |
|
30 |
_xdoins() { |
31 |
- local -i success=0 failed=0 |
32 |
+ local -i failed=0 |
33 |
while read -d $'\0' x ; do |
34 |
_doins "$x" "${x%/*}" |
35 |
- if [[ $? -eq 0 ]] ; then |
36 |
- ((success|=1)) |
37 |
- else |
38 |
- ((failed|=1)) |
39 |
- fi |
40 |
+ ((failed|=$?)) |
41 |
done |
42 |
- [[ $failed -ne 0 || $success -eq 0 ]] && return 1 || return 0 |
43 |
+ return $failed |
44 |
} |
45 |
|
46 |
success=0 |
47 |
@@ -117,6 +113,9 @@ |
48 |
find "$x_orig" -type d -exec dodir "${INSDESTTREE}/{}" \; |
49 |
find "$x_orig" \( -type f -or -type l \) -print0 | _xdoins |
50 |
if [[ ${PIPESTATUS[1]} -eq 0 ]] ; then |
51 |
+ # NOTE: Even if only an empty directory is installed here, it |
52 |
+ # still counts as success, since an empty directory given as |
53 |
+ # an argument to doins -r should not trigger failure. |
54 |
((success|=1)) |
55 |
else |
56 |
((failed|=1)) |
57 |
|
58 |
Modified: main/branches/prefix/bin/repoman |
59 |
=================================================================== |
60 |
--- main/branches/prefix/bin/repoman 2010-01-07 20:19:54 UTC (rev 15174) |
61 |
+++ main/branches/prefix/bin/repoman 2010-01-08 07:48:41 UTC (rev 15175) |
62 |
@@ -276,6 +276,7 @@ |
63 |
"KEYWORDS.stable":"Ebuilds that have been added directly with stable KEYWORDS", |
64 |
"KEYWORDS.stupid":"Ebuilds that use KEYWORDS=-* instead of package.mask", |
65 |
"LICENSE.missing":"Ebuilds that have a missing or empty LICENSE variable", |
66 |
+ "LICENSE.virtual":"Virtuals that have a non-empty LICENSE variable", |
67 |
"DESCRIPTION.missing":"Ebuilds that have a missing or empty DESCRIPTION variable", |
68 |
"DESCRIPTION.toolong":"DESCRIPTION is over %d characters" % max_desc_len, |
69 |
"EAPI.definition":"EAPI is defined after an inherit call (must be defined before)", |
70 |
@@ -283,6 +284,7 @@ |
71 |
"EAPI.unsupported":"Ebuilds that have an unsupported EAPI version (you must upgrade portage)", |
72 |
"SLOT.invalid":"Ebuilds that have a missing or invalid SLOT variable value", |
73 |
"HOMEPAGE.missing":"Ebuilds that have a missing or empty HOMEPAGE variable", |
74 |
+ "HOMEPAGE.virtual":"Virtuals that have a non-empty HOMEPAGE variable", |
75 |
"DEPEND.bad":"User-visible ebuilds with bad DEPEND settings (matched against *visible* ebuilds)", |
76 |
"RDEPEND.bad":"User-visible ebuilds with bad RDEPEND settings (matched against *visible* ebuilds)", |
77 |
"PDEPEND.bad":"User-visible ebuilds with bad PDEPEND settings (matched against *visible* ebuilds)", |
78 |
@@ -359,6 +361,8 @@ |
79 |
"DEPEND.badmaskedindev","RDEPEND.badmaskedindev","PDEPEND.badmaskedindev", |
80 |
"DEPEND.badtilde", "RDEPEND.badtilde", "PDEPEND.badtilde", |
81 |
"DESCRIPTION.toolong", |
82 |
+"HOMEPAGE.virtual", |
83 |
+"LICENSE.virtual", |
84 |
"KEYWORDS.dropped", |
85 |
"KEYWORDS.stupid", |
86 |
"KEYWORDS.missing", |
87 |
@@ -1381,6 +1385,13 @@ |
88 |
stats[myqakey]=stats[myqakey]+1 |
89 |
fails[myqakey].append(x+"/"+y+".ebuild") |
90 |
|
91 |
+ if catdir == "virtual": |
92 |
+ for var in ("HOMEPAGE", "LICENSE"): |
93 |
+ if myaux.get(var): |
94 |
+ myqakey = var + ".virtual" |
95 |
+ stats[myqakey] = stats[myqakey] + 1 |
96 |
+ fails[myqakey].append(relative_path) |
97 |
+ |
98 |
# 14 is the length of DESCRIPTION="" |
99 |
if len(myaux['DESCRIPTION']) > max_desc_len: |
100 |
stats['DESCRIPTION.toolong'] += 1 |
101 |
|
102 |
Modified: main/branches/prefix/man/repoman.1 |
103 |
=================================================================== |
104 |
--- main/branches/prefix/man/repoman.1 2010-01-07 20:19:54 UTC (rev 15174) |
105 |
+++ main/branches/prefix/man/repoman.1 2010-01-08 07:48:41 UTC (rev 15175) |
106 |
@@ -119,6 +119,9 @@ |
107 |
.B HOMEPAGE.missing |
108 |
Ebuilds that have a missing or empty HOMEPAGE variable |
109 |
.TP |
110 |
+.B HOMEPAGE.virtual |
111 |
+Virtuals that have a non-empty HOMEPAGE variable |
112 |
+.TP |
113 |
.B IUSE.invalid |
114 |
This ebuild has a variable in IUSE that is not in the use.desc or its metadata.xml file |
115 |
.TP |
116 |
@@ -149,6 +152,9 @@ |
117 |
.B LICENSE.syntax |
118 |
Syntax error in LICENSE (usually an extra/missing space/parenthesis) |
119 |
.TP |
120 |
+.B LICENSE.virtual |
121 |
+Virtuals that have a non-empty LICENSE variable |
122 |
+.TP |
123 |
.B LIVEVCS.stable |
124 |
Ebuild is a live ebuild (cvs, git, darcs, svn, etc) checkout with stable keywords. |
125 |
.TP |
126 |
|
127 |
Modified: main/branches/prefix/pym/portage/dbapi/vartree.py |
128 |
=================================================================== |
129 |
--- main/branches/prefix/pym/portage/dbapi/vartree.py 2010-01-07 20:19:54 UTC (rev 15174) |
130 |
+++ main/branches/prefix/pym/portage/dbapi/vartree.py 2010-01-08 07:48:41 UTC (rev 15175) |
131 |
@@ -3524,6 +3524,10 @@ |
132 |
# upgraded. We effectively only want one half of the config protection |
133 |
# functionality for /lib/modules. For portage-ng both capabilities |
134 |
# should be able to be independently specified. |
135 |
+ # TODO: For rebuilds, re-parent previous modules to the new |
136 |
+ # installed instance (so they are not orphans). For normal |
137 |
+ # uninstall (not rebuild/reinstall), remove the modules along |
138 |
+ # with all other files (leave no orphans). |
139 |
if obj.startswith(modprotect): |
140 |
show_unmerge("---", unmerge_desc["cfgpro"], file_type, obj) |
141 |
continue |