summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIonen Wolkens <ionen@gentoo.org>2023-03-02 14:10:52 -0500
committerIonen Wolkens <ionen@gentoo.org>2023-03-03 00:21:02 -0500
commit86d3e174d2581952f280e073b474b2e2451ee72e (patch)
tree6f66fce04bac9385b764b12b4f8aa1731fd54c3b /app-eselect
parentnet-libs/nodejs: drop 14.21.2, 16.19.0, 18.13.0, 18.14.0 (diff)
downloadgentoo-86d3e174d2581952f280e073b474b2e2451ee72e.tar.gz
gentoo-86d3e174d2581952f280e073b474b2e2451ee72e.tar.bz2
gentoo-86d3e174d2581952f280e073b474b2e2451ee72e.zip
app-eselect/eselect-wine: don't fail if migration file exists
May have been left there if other preinst commands failed (like eselect wine unset --all which can be fickle). Alternatively could cp -f, but best avoid clobbering more files we don't own as much as possible. Guess a better approach would've been to put it in ${T} and tell eselect where to find it in postinst but at this point not going to worry about due-to-be-removed cruft. Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'app-eselect')
-rw-r--r--app-eselect/eselect-wine/eselect-wine-2.0.2.ebuild6
1 files changed, 4 insertions, 2 deletions
diff --git a/app-eselect/eselect-wine/eselect-wine-2.0.2.ebuild b/app-eselect/eselect-wine/eselect-wine-2.0.2.ebuild
index 953f7e1c910d..dc64574f7852 100644
--- a/app-eselect/eselect-wine/eselect-wine-2.0.2.ebuild
+++ b/app-eselect/eselect-wine/eselect-wine-2.0.2.ebuild
@@ -1,4 +1,4 @@
-# Copyright 2022 Gentoo Authors
+# Copyright 2022-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -43,8 +43,10 @@ src_install() {
pkg_preinst() {
if has_version '<app-eselect/eselect-wine-2'; then
# keep copy of still-set 'active' to auto-select same slots
- [[ ! -e ${EROOT}/etc/eselect/wine/active ]] ||
+ if [[ -e ${EROOT}/etc/eselect/wine/active &&
+ ! -e ${EROOT}/etc/eselect/wine/eselect-wine-migration ]]; then
cp "${EROOT}"/etc/eselect/wine/{active,eselect-wine-migration} || die
+ fi
# managed differently, need cleanup
eselect wine unset --all || die