summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Mair-Keimberger <mmk@levelnine.at>2021-06-26 19:43:10 +0200
committerIonen Wolkens <ionen@gentoo.org>2021-07-05 18:51:54 -0400
commit4d9aa3476285e1caa3930da9acbeb7d45b1c1846 (patch)
tree705197bd6a22bd0696a93279f0749bd84c5ab4cb /games-rpg/dreamweb
parentgames-rpg/draci-historie: EAPI8, ebuild improvements (diff)
downloadgentoo-4d9aa3476285e1caa3930da9acbeb7d45b1c1846.tar.gz
gentoo-4d9aa3476285e1caa3930da9acbeb7d45b1c1846.tar.bz2
gentoo-4d9aa3476285e1caa3930da9acbeb7d45b1c1846.zip
games-rpg/dreamweb: EAPI8, ebuild improvements
Package-Manager: Portage-3.0.20, Repoman-3.0.3 Signed-off-by: Michael Mair-Keimberger <mmk@levelnine.at> Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'games-rpg/dreamweb')
-rw-r--r--games-rpg/dreamweb/dreamweb-1.1-r1.ebuild106
1 files changed, 31 insertions, 75 deletions
diff --git a/games-rpg/dreamweb/dreamweb-1.1-r1.ebuild b/games-rpg/dreamweb/dreamweb-1.1-r1.ebuild
index b041a158412f..8e0173c49eac 100644
--- a/games-rpg/dreamweb/dreamweb-1.1-r1.ebuild
+++ b/games-rpg/dreamweb/dreamweb-1.1-r1.ebuild
@@ -1,8 +1,9 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=6
-inherit eutils
+EAPI=8
+
+inherit desktop wrapper
DESCRIPTION="Top-down adventure game set in a gritty futuristic/dystopian city"
HOMEPAGE="https://wiki.scummvm.org/index.php/Dreamweb"
@@ -16,51 +17,30 @@ SRC_URI="doc? ( mirror://sourceforge/scummvm/${PN}-manuals-en-highres.zip )
!l10n_de? ( !l10n_en? ( !l10n_en-GB? ( !l10n_es? ( !l10n_fr? ( !l10n_it? \
( mirror://sourceforge/scummvm/${PN}-cd-us-${PV}.zip ) ) ) ) ) )
http://www.scummvm.org/images/cat-dreamweb.png"
+S="${WORKDIR}"
LICENSE="Dreamweb"
SLOT="0"
KEYWORDS="~amd64 ~x86"
-IUSE="doc l10n_de l10n_en l10n_en-GB l10n_es l10n_fr l10n_it"
+IUSE="doc l10n_de +l10n_en l10n_en-GB l10n_es l10n_fr l10n_it"
-RDEPEND=">=games-engines/scummvm-1.7[flac]"
-DEPEND="app-arch/unzip"
-
-S="${WORKDIR}"
+RDEPEND="games-engines/scummvm[flac]"
+BDEPEND="app-arch/unzip"
src_unpack() {
- if use l10n_de ; then
- mkdir -p "${S}"/de || die
- cd "${S}"/de || die
- unpack ${PN}-cd-de-${PV}.zip
- fi
- if use l10n_en || ( ! use l10n_de && ! use l10n_en && ! use l10n_en-GB && \
- ! use l10n_es && ! use l10n_fr && ! use l10n_it ) ; then
- mkdir -p "${S}"/en_US || die
- cd "${S}"/en_US || die
- unpack ${PN}-cd-us-${PV}.zip
- fi
- if use l10n_en-GB ; then
- mkdir -p "${S}"/en_GB || die
- cd "${S}"/en_GB || die
- unpack ${PN}-cd-uk-${PV}.zip
- fi
- if use l10n_es ; then
- mkdir -p "${S}"/es || die
- cd "${S}"/es || die
- unpack ${PN}-cd-es-${PV}.zip
- fi
- if use l10n_fr ; then
- mkdir -p "${S}"/fr || die
- cd "${S}"/fr || die
- unpack ${PN}-cd-fr-${PV}.zip
- fi
- if use l10n_it ; then
- mkdir -p "${S}"/it || die
- cd "${S}"/it || die
- unpack ${PN}-cd-it-${PV}.zip
- fi
- if use doc ; then
- mkdir -p "${S}"/doc || die
+ MY_L10N=( $(usev l10n_de) $(usev l10n_es) $(usev l10n_fr) $(usev l10n_it) )
+ MY_L10N+=( $(usev l10n_{en,us}) $(usev l10n_{en-GB,uk}) )
+ [[ ${MY_L10N} ]] || MY_L10N=( l10n_us )
+
+ local lang
+ for lang in "${MY_L10N[@]//l10n_/}"; do
+ mkdir "${S}"/${lang} || die
+ cd "${S}"/${lang} || die
+ unpack ${PN}-cd-${lang}-${PV}.zip
+ done
+
+ if use doc; then
+ mkdir "${S}"/doc || die
cd "${S}"/doc || die
unpack ${PN}-manuals-en-highres.zip
fi
@@ -68,42 +48,18 @@ src_unpack() {
src_prepare() {
default
- rm -rf */license.txt */*.EXE || die
+ rm -f */license.txt */*.EXE || die
}
src_install() {
insinto /usr/share/${PN}
- newicon "${DISTDIR}"/cat-dreamweb.png dreamweb.png
- if use l10n_de ; then
- doins -r de
- make_wrapper dreamweb-de "scummvm -f -p \"/usr/share/${PN}/de\" dreamweb" .
- make_desktop_entry ${PN}-de "Dreamweb (Deutsch)" dreamweb
- fi
- if use l10n_en || ( ! use l10n_de && ! use l10n_en && ! use l10n_en-GB && \
- ! use l10n_es && ! use l10n_fr && ! use l10n_it ) ; then
- doins -r en_US
- make_wrapper dreamweb-en_US "scummvm -f -p \"/usr/share/${PN}/en_US\" dreamweb" .
- make_desktop_entry ${PN}-en_US "Dreamweb (US English)" dreamweb
- fi
- if use l10n_en-GB ; then
- doins -r en_GB
- make_wrapper dreamweb-en_GB "scummvm -f -p \"/usr/share/${PN}/en_GB\" dreamweb" .
- make_desktop_entry ${PN}-en_GB "Dreamweb (UK English)" dreamweb
- fi
- if use l10n_es ; then
- doins -r es
- make_wrapper dreamweb-es "scummvm -f -p \"/usr/share/${PN}/es\" dreamweb" .
- make_desktop_entry ${PN}-es "Dreamweb (Español)" dreamweb
- fi
- if use l10n_fr ; then
- doins -r fr
- make_wrapper dreamweb-fr "scummvm -f -p \"/usr/share/${PN}/fr\" dreamweb" .
- make_desktop_entry ${PN}-fr "Dreamweb (Français)" dreamweb
- fi
- if use l10n_it ; then
- doins -r it
- make_wrapper dreamweb-it "scummvm -f -p \"/usr/share/${PN}/it\" dreamweb" .
- make_desktop_entry ${PN}-it "Dreamweb (Italiano)" dreamweb
- fi
- use doc && dodoc -r doc/*
+ local lang
+ for lang in "${MY_L10N[@]//l10n_/}"; do
+ doins -r ${lang}
+ make_wrapper ${PN}-${lang} "scummvm -f -p \"${EPREFIX}/usr/share/${PN}/${lang}\" ${PN}"
+ make_desktop_entry ${PN}-${lang} "Dreamweb (${lang})"
+ done
+
+ newicon "${DISTDIR}"/cat-${PN}.png ${PN}.png
+ use doc && dodoc -r doc/.
}