summaryrefslogtreecommitdiff
path: root/games-rpg/draci-historie/draci-historie-2012-r1.ebuild
diff options
context:
space:
mode:
Diffstat (limited to 'games-rpg/draci-historie/draci-historie-2012-r1.ebuild')
-rw-r--r--games-rpg/draci-historie/draci-historie-2012-r1.ebuild82
1 files changed, 27 insertions, 55 deletions
diff --git a/games-rpg/draci-historie/draci-historie-2012-r1.ebuild b/games-rpg/draci-historie/draci-historie-2012-r1.ebuild
index 3982a8538d15..262964dad79f 100644
--- a/games-rpg/draci-historie/draci-historie-2012-r1.ebuild
+++ b/games-rpg/draci-historie/draci-historie-2012-r1.ebuild
@@ -1,79 +1,51 @@
-# Copyright 1999-2018 Gentoo Foundation
+# 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="Bert the little dragon searches for his father"
-HOMEPAGE="http://www.ucw.cz/draci-historie/index-en.html"
-BASE_URL="http://www.ucw.cz/draci-historie/binary/dh"
+HOMEPAGE="https://www.ucw.cz/draci-historie/index-en.html"
+BASE_URL="https://www.ucw.cz/draci-historie/binary/dh"
SRC_URI="
l10n_cs? ( ${BASE_URL}-cz-${PV}.zip )
l10n_de? ( ${BASE_URL}-de-${PV}.zip )
l10n_en? ( ${BASE_URL}-en-${PV}.zip )
l10n_pl? ( ${BASE_URL}-pl-${PV}.zip )
!l10n_cs? ( !l10n_de? ( !l10n_en? ( !l10n_pl? ( ${BASE_URL}-en-${PV}.zip ) ) ) )
+ https://dev.gentoo.org/~ionen/distfiles/${PN}.png
"
+S="${WORKDIR}"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
-IUSE="l10n_cs l10n_de l10n_en l10n_pl"
+IUSE="l10n_cs l10n_de +l10n_en l10n_pl"
-RDEPEND=">=games-engines/scummvm-1.1"
-DEPEND="app-arch/unzip"
-
-S="${WORKDIR}"
+RDEPEND="games-engines/scummvm"
+BDEPEND="app-arch/unzip"
src_unpack() {
- if use l10n_en || ( ! use l10n_cs && ! use l10n_de && ! use l10n_en && ! use l10n_pl ) ; then
- mkdir en || die
- unpack dh-en-${PV}.zip
- mv *.{dfw,fon,mid,sam} en/ || die
- fi
- if use l10n_cs ; then
- mkdir cs || die
- unpack dh-cz-${PV}.zip
- mv *.{dfw,fon,mid,sam,zzz} cs/ || die
- fi
- if use l10n_de ; then
- mkdir de || die
- unpack dh-de-${PV}.zip
- mv *.{dfw,fon,mid,sam} de/ || die
- fi
- if use l10n_pl ; then
- mkdir pl || die
- unpack dh-pl-${PV}.zip
- mv *.{dfw,fon,mid,sam,zzz} pl/ || die
- fi
-}
-
-src_prepare() {
- default
- rm -f *.{bat,exe,ins} readme.* || die
+ MY_L10N=( $(usev l10n_{cs,cz}) $(usev l10n_de) $(usev l10n_en) $(usev l10n_pl) )
+ [[ ${MY_L10N} ]] || MY_L10N=( l10n_en )
+
+ local lang
+ for lang in "${MY_L10N[@]//l10n_/}"; do
+ mkdir ${lang} || die
+ unpack dh-${lang}-${PV}.zip
+ mv *.{dfw,fon,mid,sam} ${lang}/ || die
+ done
}
src_install() {
- newicon bert.ico draci-historie.ico
insinto /usr/share/${PN}
- for lingua in $(find * -type d); do
- doins -r ${lingua}
+ local lang
+ for lang in "${MY_L10N[@]//l10n_/}"; do
+ doins -r ${lang}
+ make_wrapper ${PN}-${lang} "scummvm -f -p \"${EPREFIX}/usr/share/${PN}/${lang}\" draci"
+ make_desktop_entry ${PN}-${lang} "Dračí Historie (${lang})"
done
- if use l10n_en || ( ! use l10n_cs && ! use l10n_de && ! use l10n_en && ! use l10n_pl ) ; then
- make_wrapper draci-historie-en "scummvm -f -p \"/usr/share/${PN}/en\" draci" .
- make_desktop_entry ${PN}-en "Dračí Historie (English)" /usr/share/pixmaps/draci-historie.ico
- fi
- if use l10n_cs ; then
- make_wrapper draci-historie-cs "scummvm -f -p \"/usr/share/${PN}/cs\" draci" .
- make_desktop_entry ${PN}-cs "Dračí Historie (Čeština)" /usr/share/pixmaps/draci-historie.ico
- fi
- if use l10n_de ; then
- make_wrapper draci-historie-de "scummvm -f -p \"/usr/share/${PN}/de\" draci" .
- make_desktop_entry ${PN}-de "Dračí Historie (Deutsch)" /usr/share/pixmaps/draci-historie.ico
- fi
- if use l10n_pl ; then
- make_wrapper draci-historie-pl "scummvm -f -p \"/usr/share/${PN}/pl\" draci" .
- make_desktop_entry ${PN}-pl "Dračí Historie (Polski)" /usr/share/pixmaps/draci-historie.ico
- fi
- einstalldocs
+
+ doicon "${DISTDIR}"/${PN}.png
}