commit:     5ffc1fedd812317ebef44147b4b76a4ce7e65e4b
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Sun Jun  4 20:52:22 2017 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sun Jun  4 20:52:22 2017 +0000
URL:        https://gitweb.gentoo.org/proj/kde.git/commit/?id=5ffc1fed

media-sound/kaudiocreator: Add pkg_postinst log about optional RDEPENDs

Reported-by: David Zaslavsky <diazona <AT> ellipsix.net>
Gentoo-bug: 604368

Package-Manager: Portage-2.3.5, Repoman-2.3.1

 media-sound/kaudiocreator/kaudiocreator-9999.ebuild | 20 +++++++++++++++++++-
 1 file changed, 19 insertions(+), 1 deletion(-)

diff --git a/media-sound/kaudiocreator/kaudiocreator-9999.ebuild 
b/media-sound/kaudiocreator/kaudiocreator-9999.ebuild
index f43cf75925..44f63f1425 100644
--- a/media-sound/kaudiocreator/kaudiocreator-9999.ebuild
+++ b/media-sound/kaudiocreator/kaudiocreator-9999.ebuild
@@ -37,9 +37,27 @@ DEPEND="
        media-libs/phonon[qt5]
        >=media-libs/taglib-1.5
 "
-
 RDEPEND="${DEPEND}
        $(add_kdeapps_dep audiocd-kio)
 "
 
 DOCS=( Changelog TODO )
+
+pkg_postinst() {
+       local stcnt=0
+
+       has_version media-libs/flac && stcnt=$((stcnt+1))
+       has_version media-sound/lame && stcnt=$((stcnt+1))
+       has_version media-sound/vorbis-tools && stcnt=$((stcnt+1))
+
+       if [[ ${stcnt} -lt 1 ]] ; then
+               ewarn "You you should emerge at least one of the following 
packages"
+               ewarn "for ${PN} to do anything useful."
+       fi
+       elog "Optional runtime dependencies:"
+       elog "FLAC - media-libs/flac"
+       elog "MP3  - media-sound/lame"
+       elog "OGG  - media-sound/vorbis-tools"
+
+       kde5_pkg_postinst
+}

Reply via email to