1 |
commit: dddeca6e4409e2a8a0dedc907d208ce352a48b72 |
2 |
Author: Zac Medico <zmedico <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Nov 24 00:59:37 2015 +0000 |
4 |
Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Nov 24 01:05:54 2015 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=dddeca6e |
7 |
|
8 |
einstalldocs: use lazy docinto calls (bug 566654) |
9 |
|
10 |
This avoids unnecessary creation of an empty documentation directory. |
11 |
|
12 |
X-Gentoo-Bug: 566654 |
13 |
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=566654 |
14 |
|
15 |
bin/phase-helpers.sh | 14 +++++++------- |
16 |
1 file changed, 7 insertions(+), 7 deletions(-) |
17 |
|
18 |
diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh |
19 |
index f42f805..80f5946 100644 |
20 |
--- a/bin/phase-helpers.sh |
21 |
+++ b/bin/phase-helpers.sh |
22 |
@@ -954,26 +954,26 @@ fi |
23 |
if ___eapi_has_einstalldocs; then |
24 |
einstalldocs() { |
25 |
( |
26 |
- docinto . |
27 |
if ! declare -p DOCS &>/dev/null ; then |
28 |
local d |
29 |
for d in README* ChangeLog AUTHORS NEWS TODO CHANGES \ |
30 |
THANKS BUGS FAQ CREDITS CHANGELOG ; do |
31 |
- [[ -s ${d} ]] && dodoc "${d}" |
32 |
+ [[ -s ${d} ]] && docinto / && dodoc "${d}" |
33 |
done |
34 |
elif [[ $(declare -p DOCS) == "declare -a"* ]] ; then |
35 |
- [[ ${DOCS[@]} ]] && dodoc -r "${DOCS[@]}" |
36 |
+ [[ ${DOCS[@]} ]] && docinto / && dodoc -r "${DOCS[@]}" |
37 |
else |
38 |
- [[ ${DOCS} ]] && dodoc -r ${DOCS} |
39 |
+ [[ ${DOCS} ]] && docinto / && dodoc -r ${DOCS} |
40 |
fi |
41 |
) |
42 |
|
43 |
( |
44 |
- docinto html |
45 |
if [[ $(declare -p HTML_DOCS 2>/dev/null) == "declare -a"* ]] ; then |
46 |
- [[ ${HTML_DOCS[@]} ]] && dodoc -r "${HTML_DOCS[@]}" |
47 |
+ [[ ${HTML_DOCS[@]} ]] && \ |
48 |
+ docinto html && dodoc -r "${HTML_DOCS[@]}" |
49 |
else |
50 |
- [[ ${HTML_DOCS} ]] && dodoc -r ${HTML_DOCS} |
51 |
+ [[ ${HTML_DOCS} ]] && \ |
52 |
+ docinto html && dodoc -r ${HTML_DOCS} |
53 |
fi |
54 |
) |
55 |
} |