commit:     ad66a3fe06a3fc02c8f76bcdd63f38400f602b0f
Author:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
AuthorDate: Mon Jun 14 15:28:49 2021 +0000
Commit:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Mon Jun 14 15:47:49 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ad66a3fe

games-action/armagetronad: restore -j1, fix dedicated, tidy

j1 was removed for bug #588104, but turns out still needed for
install until proper fix (bug #698020).

No longer attempt to remove desktop/ when USE=dedicated (bug #716442).

Bug: https://bugs.gentoo.org/588104
Closes: https://bugs.gentoo.org/698020
Closes: https://bugs.gentoo.org/716442
Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>

 .../armagetronad/armagetronad-0.2.9.1.0.ebuild     | 47 +++++++++++-----------
 1 file changed, 24 insertions(+), 23 deletions(-)

diff --git a/games-action/armagetronad/armagetronad-0.2.9.1.0.ebuild 
b/games-action/armagetronad/armagetronad-0.2.9.1.0.ebuild
index 53ba592280d..93180672cd3 100644
--- a/games-action/armagetronad/armagetronad-0.2.9.1.0.ebuild
+++ b/games-action/armagetronad/armagetronad-0.2.9.1.0.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=7
 
-inherit autotools desktop xdg-utils
+inherit autotools desktop
 
 DESCRIPTION="Fast-paced 3D lightcycle game based on Tron"
 HOMEPAGE="http://armagetronad.org/";
@@ -24,9 +24,11 @@ RDEPEND="
                virtual/opengl
                sound? ( media-libs/sdl-mixer )
        )"
-DEPEND=${RDEPEND}
+DEPEND="${RDEPEND}"
 
-PATCHES=("${FILESDIR}"/${P}-AR.patch)
+PATCHES=(
+       "${FILESDIR}"/${P}-AR.patch
+)
 
 src_prepare() {
        default
@@ -35,29 +37,28 @@ src_prepare() {
 }
 
 src_configure() {
-       # --enable-games just messes up paths
-       econf \
-               $(use_enable dedicated) \
-               $(use_enable sound music) \
-               --disable-sysinstall \
-               --disable-useradd \
-               --disable-uninstall \
+       local econfargs=(
+               $(use_enable dedicated)
+               $(use_enable sound music)
+               # following options only mess with paths and users
                --disable-games
+               --disable-sysinstall
+               --disable-uninstall
+               --disable-useradd
+       )
+       econf ${econfargs[@]}
 }
 
 src_install() {
-       default
-
-       # misplaced desktop-file/icons
-       rm -r "${ED}"/usr/share/${PN}/desktop || die
-       doicon -s 48 desktop/icons/48x48/armagetronad.png
-       make_desktop_entry ${PN}
-}
-
-pkg_postinst() {
-       xdg_icon_cache_update
-}
+       # long history of being broken without -j1 (bug #330705,698020)
+       # do not remove (again) without a proper fix or extensive tests
+       emake -j1 DESTDIR="${D}" install
+       einstalldocs
 
-pkg_postrm() {
-       xdg_icon_cache_update
+       # handle misplaced .desktop / icons
+       if ! use dedicated; then
+               rm -r "${ED}"/usr/share/${PN}/desktop || die
+               doicon desktop/icons/48x48/armagetronad.png
+               make_desktop_entry ${PN}
+       fi
 }

Reply via email to