dev-lang/rust: fix completion file removal
authorGeorgy Yakovlev <gyakovlev@gentoo.org>
Fri, 13 Dec 2019 19:56:47 +0000 (11:56 -0800)
committerGeorgy Yakovlev <gyakovlev@gentoo.org>
Fri, 13 Dec 2019 23:05:45 +0000 (15:05 -0800)
Bug: https://bugs.gentoo.org/689562
Package-Manager: Portage-2.3.79, Repoman-2.3.17
Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
dev-lang/rust/rust-1.39.0.ebuild

index f918098e20cf1245ac92b2e8112dd12413c1b29d..6f66984bd72b33602699d04a08ffc8eb544fd225 100644 (file)
@@ -236,7 +236,9 @@ src_install() {
 
        # bug #689562, #689160
        rm "${D}/etc/bash_completion.d/cargo" || die
-       rmdir -p "${D}/etc" || die
+       pushd "${D}" > /dev/null || die
+       rmdir -p etc/bash_completion.d || die
+       popd > /dev/null || die
        dobashcomp build/tmp/dist/cargo-image/etc/bash_completion.d/cargo
 
        mv "${ED}/usr/bin/rustc" "${ED}/usr/bin/rustc-${PV}" || die