diff options
author | Martin Väth <martin@mvath.de> | 2014-02-01 15:54:37 +0100 |
---|---|---|
committer | Martin Väth <martin@mvath.de> | 2015-10-11 10:49:06 +0200 |
commit | 44f6650bce26caea43304324ca6643fe8a65ca12 (patch) | |
tree | d9c8f972fd879fd26750e08fa6116084bf363bcc /app-portage/eix/eix-99999999.ebuild | |
parent | Move eix to github (diff) | |
download | mv-44f6650bce26caea43304324ca6643fe8a65ca12.tar.gz mv-44f6650bce26caea43304324ca6643fe8a65ca12.tar.bz2 mv-44f6650bce26caea43304324ca6643fe8a65ca12.zip |
eix: Support /var/lib/tmpfiles.d
Diffstat (limited to 'app-portage/eix/eix-99999999.ebuild')
-rw-r--r-- | app-portage/eix/eix-99999999.ebuild | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/app-portage/eix/eix-99999999.ebuild b/app-portage/eix/eix-99999999.ebuild index 9a1592ec..b4137b26 100644 --- a/app-portage/eix/eix-99999999.ebuild +++ b/app-portage/eix/eix-99999999.ebuild @@ -35,6 +35,7 @@ pkg_setup() { } src_prepare() { + sed -i -e "s'/'${EPREFIX}/'" -- "${S}"/tmpfiles.d/eix.conf epatch_user eautopoint eautoreconf @@ -60,15 +61,19 @@ src_configure() { src_install() { default dobashcomp bash/eix - keepdir "/var/cache/${PN}" - fowners portage:portage "/var/cache/${PN}" - fperms 775 "/var/cache/${PN}" + insinto "/usr/lib/tmpfiles.d" + doins tmpfiles.d/eix.conf } pkg_postinst() { - # fowners in src_install doesn't work for owner/group portage: - # merging changes this owner/group back to root. - use prefix || chown portage:portage "${EROOT}var/cache/${PN}" + test -d "${EROOT}var/cache/${PN}" || { + mkdir "${EROOT}var/cache/${PN}" + use prefix || chown portage:portage "${EROOT}var/cache/${PN}" + } local obs="${EROOT}var/cache/eix.previous" ! test -f "${obs}" || ewarn "Found obsolete ${obs}, please remove it" } + +pkg_postrm() { + [ -n "${REPLACED_BY_VERSION}" ] || rm -rf -- "${EROOT}var/cache/${PN}" +} |