Gentoo Archives: gentoo-commits

From: Zac Medico <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/portage:master commit in: bin/ebuild-helpers/
Date: Fri, 04 May 2018 15:56:42
Message-Id: 1525449359.256bcb665fcd37356c02a08a3e2a12d415a5d656.zmedico@gentoo
1 commit: 256bcb665fcd37356c02a08a3e2a12d415a5d656
2 Author: Zac Medico <zmedico <AT> gentoo <DOT> org>
3 AuthorDate: Fri May 4 15:55:59 2018 +0000
4 Commit: Zac Medico <zmedico <AT> gentoo <DOT> org>
5 CommitDate: Fri May 4 15:55:59 2018 +0000
6 URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=256bcb66
7
8 ecompressdir: fix slash normalization (bug 654838)
9
10 This solves the following error, for EAPI 7 ebuilds using newdoc as shown:
11
12 mv: cannot move '/var/tmp/portage/portage-test/foo-1/temp/ecompress-skip/usr/share/doc/foo-1/html' to
13 '/var/tmp/portage/portage-test/foo-1/imageusr/share/doc/foo-1/html/html': Directory not empty
14
15 EAPI=7
16 src_install() {
17 docinto html
18 newdoc /dev/null null.html
19 }
20
21 Fixes: 244a62a4f275 ("Fix uses of D/ED to account for no trailing slash")
22
23 bin/ebuild-helpers/ecompressdir | 4 ++--
24 1 file changed, 2 insertions(+), 2 deletions(-)
25
26 diff --git a/bin/ebuild-helpers/ecompressdir b/bin/ebuild-helpers/ecompressdir
27 index fb4c39f2b..dacb857be 100755
28 --- a/bin/ebuild-helpers/ecompressdir
29 +++ b/bin/ebuild-helpers/ecompressdir
30 @@ -139,7 +139,7 @@ funk_up_dir() {
31 # Move all files and directories we want to skip running compression
32 # on from srctree to dsttree.
33 _relocate_skip_dirs() {
34 - local srctree="$1" dsttree="$2"
35 + local srctree="${1%/}" dsttree="${2%/}"
36
37 [[ -d ${srctree} ]] || return 0
38
39 @@ -213,7 +213,7 @@ for dir in "$@" ; do
40
41 # now lets do our work
42 if [[ -n ${suffix} ]] ; then
43 - __vecho "${0##*/}: $(ecompress --bin) /${actual_dir#${ED%/}}"
44 + __vecho "${0##*/}: $(ecompress --bin) /${actual_dir#${ED%/}/}"
45 funk_up_dir "compress" "${suffix}" "ecompress" "${size_limit}"
46 : $(( ret |= $? ))
47 fi