dev-util/ccache: fix ROOT=/ detection
authorSergei Trofimovich <slyfox@gentoo.org>
Sun, 28 Oct 2018 11:05:43 +0000 (11:05 +0000)
committerSergei Trofimovich <slyfox@gentoo.org>
Sun, 28 Oct 2018 11:19:42 +0000 (11:19 +0000)
At least on portage EAPI=7 lacks trailing slashes in absolute paths.
This makes ROOT="/" a ROOT="".

It's arguably not an absolute path anymore but it's what we get.
Make expansion work for both ROOT="/" and ROOT="",

Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
Package-Manager: Portage-2.3.51, Repoman-2.3.11

dev-util/ccache/ccache-3.5-r1.ebuild [moved from dev-util/ccache/ccache-3.5.ebuild with 95% similarity]

similarity index 95%
rename from dev-util/ccache/ccache-3.5.ebuild
rename to dev-util/ccache/ccache-3.5-r1.ebuild
index e2a525cad94a2cff289fe7a7fb549a99e775d1a8..d1a32f96e906d8b22266ceb1eab7f70f54e30595 100644 (file)
@@ -66,13 +66,13 @@ ccache now supports sys-devel/clang and dev-lang/icc, too!"
 }
 
 pkg_prerm() {
-       if [[ -z ${REPLACED_BY_VERSION} && ${ROOT} == / ]] ; then
+       if [[ -z ${REPLACED_BY_VERSION} && ${ROOT:-/} == / ]] ; then
                eselect compiler-shadow remove ccache
        fi
 }
 
 pkg_postinst() {
-       if [[ ${ROOT} == / ]]; then
+       if [[ ${ROOT:-/} == / ]]; then
                eselect compiler-shadow update ccache
        fi