From 79cce30abd02567f8465f879a91b273544126c84 Mon Sep 17 00:00:00 2001 From: Ionen Wolkens Date: Sat, 3 Dec 2022 08:43:06 -0500 Subject: app-eselect/eselect-wine: optionally rdepend on xdg-utils Being optional makes some sense for headless system, albeit most desktop ones will typically want xdg-open from this around. Closes: https://bugs.gentoo.org/884077 Signed-off-by: Ionen Wolkens --- .../eselect-wine/eselect-wine-2.0.1-r1.ebuild | 92 -------------------- .../eselect-wine/eselect-wine-2.0.1-r2.ebuild | 97 ++++++++++++++++++++++ app-eselect/eselect-wine/metadata.xml | 3 + 3 files changed, 100 insertions(+), 92 deletions(-) delete mode 100644 app-eselect/eselect-wine/eselect-wine-2.0.1-r1.ebuild create mode 100644 app-eselect/eselect-wine/eselect-wine-2.0.1-r2.ebuild (limited to 'app-eselect/eselect-wine') diff --git a/app-eselect/eselect-wine/eselect-wine-2.0.1-r1.ebuild b/app-eselect/eselect-wine/eselect-wine-2.0.1-r1.ebuild deleted file mode 100644 index 9970fb76df07..000000000000 --- a/app-eselect/eselect-wine/eselect-wine-2.0.1-r1.ebuild +++ /dev/null @@ -1,92 +0,0 @@ -# Copyright 2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Manage active Wine slots and variants" -HOMEPAGE="https://wiki.gentoo.org/wiki/Project:Wine" -SRC_URI="https://gitweb.gentoo.org/proj/eselect-wine.git/snapshot/${P}.tar.bz2" - -LICENSE="GPL-2+" -SLOT="0" -KEYWORDS="amd64 x86" - -RDEPEND="app-admin/eselect" - -pkg_pretend() { - # /usr/bin/wine and /usr/include/wine are removed by pkg_preinst's unset, - # but portage currently checks collisions and errors out /before/ preinst - if has_version '/dev/null - - # some rare man dirs were created by old eselect, cleanup if now empty - rmdir "${EROOT}"/usr/share/man/{de,fr,pl}.UTF-8{/man1,} 2>/dev/null - fi - - # lacking QA_BROKEN_SYMLINK, and rather avoid live /usr changes wrt - # bug #632576, nor create "owned" placeholders that will be clobbered - [[ -e ${EROOT}/etc/eselect/wine/bin/wine ]] || - eqawarn "QA Note: broken symlinks QA is normal on first merge, targets created after" -} - -pkg_postinst() { - eselect wine update --if-unset || die - - rm -f "${EROOT}"/etc/eselect/wine/eselect-wine-migration || die # see preinst - - if [[ ! ${REPLACING_VERSIONS##* } ]] || - ver_test ${REPLACING_VERSIONS##* } -lt 2; then - elog - if [[ ${REPLACING_VERSIONS} ]]; then - elog "${PN} changed a bit, suggest reviewing 'eselect wine help' (and list)." - elog "Note: if seen bin/wine or include/wine merge collisions, they are harmless." - fi - elog "Please run '. ${EROOT}/etc/profile' to update PATH in current shells." - fi -} - -pkg_prerm() { - [[ ${REPLACED_BY_VERSION} ]] || eselect wine update --reset # no die -} diff --git a/app-eselect/eselect-wine/eselect-wine-2.0.1-r2.ebuild b/app-eselect/eselect-wine/eselect-wine-2.0.1-r2.ebuild new file mode 100644 index 000000000000..6c0f23f8bccb --- /dev/null +++ b/app-eselect/eselect-wine/eselect-wine-2.0.1-r2.ebuild @@ -0,0 +1,97 @@ +# Copyright 2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DESCRIPTION="Manage active Wine slots and variants" +HOMEPAGE="https://wiki.gentoo.org/wiki/Project:Wine" +SRC_URI="https://gitweb.gentoo.org/proj/eselect-wine.git/snapshot/${P}.tar.bz2" + +LICENSE="GPL-2+" +SLOT="0" +KEYWORDS="amd64 x86" +IUSE="+xdg" + +# xdg-utils needed for bug #884077 +RDEPEND=" + app-admin/eselect + xdg? ( x11-misc/xdg-utils )" + +pkg_pretend() { + # /usr/bin/wine and /usr/include/wine are removed by pkg_preinst's unset, + # but portage currently checks collisions and errors out /before/ preinst + if has_version '/dev/null + + # some rare man dirs were created by old eselect, cleanup if now empty + rmdir "${EROOT}"/usr/share/man/{de,fr,pl}.UTF-8{/man1,} 2>/dev/null + fi + + # lacking QA_BROKEN_SYMLINK, and rather avoid live /usr changes wrt + # bug #632576, nor create "owned" placeholders that will be clobbered + [[ -e ${EROOT}/etc/eselect/wine/bin/wine ]] || + eqawarn "QA Note: broken symlinks QA is normal on first merge, targets created after" +} + +pkg_postinst() { + eselect wine update --if-unset || die + + rm -f "${EROOT}"/etc/eselect/wine/eselect-wine-migration || die # see preinst + + if [[ ! ${REPLACING_VERSIONS##* } ]] || + ver_test ${REPLACING_VERSIONS##* } -lt 2; then + elog + if [[ ${REPLACING_VERSIONS} ]]; then + elog "${PN} changed a bit, suggest reviewing 'eselect wine help' (and list)." + elog "Note: if seen bin/wine or include/wine merge collisions, they are harmless." + fi + elog "Please run '. ${EROOT}/etc/profile' to update PATH in current shells." + fi +} + +pkg_prerm() { + [[ ${REPLACED_BY_VERSION} ]] || eselect wine update --reset # no die +} diff --git a/app-eselect/eselect-wine/metadata.xml b/app-eselect/eselect-wine/metadata.xml index 5db33c7f62f9..c4441da93cdc 100644 --- a/app-eselect/eselect-wine/metadata.xml +++ b/app-eselect/eselect-wine/metadata.xml @@ -6,6 +6,9 @@ Wine + + Make use of XDG_DATA_DIRS to provide desktop entries + proj/eselect-wine -- cgit v1.2.3-65-gdbad