You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
root 417ad4a5c9
Sync with portage [Sun Aug 23 21:41:43 MSK 2020].
4 years ago
..
tests Sync with portage [Thu Jul 2 17:15:36 MSK 2020]. 4 years ago
Manifest.gz Sync with portage [Sun Aug 23 21:41:43 MSK 2020]. 4 years ago
acct-group.eclass Sync with portage [Fri Mar 27 00:58:11 MSK 2020]. 5 years ago
acct-user.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
ada.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
alternatives.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
ant-tasks.eclass Sync with portage [Fri Feb 14 14:01:35 MSK 2020]. 5 years ago
apache-2.eclass Sync with portage [Sat Apr 20 19:43:20 MSK 2019]. 6 years ago
apache-module.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
aspell-dict-r1.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
autotools-multilib.eclass Sync with portage [Sun Feb 16 00:29:04 MSK 2020]. 5 years ago
autotools-utils.eclass Sync with portage [Mon Sep 16 15:50:54 MSK 2019]. 5 years ago
autotools.eclass Sync with portage [Mon Mar 16 08:52:46 MSK 2020]. 5 years ago
base.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
bash-completion-r1.eclass Sync with portage [Tue Mar 31 23:47:05 MSK 2020]. 5 years ago
bazel.eclass Sync with portage [Wed Feb 12 18:19:49 MSK 2020]. 5 years ago
cannadic.eclass Sync with portage [Thu Jul 13 17:04:07 MSK 2017]. 7 years ago
cargo.eclass Sync with portage [Sun Jun 14 00:18:46 MSK 2020]. 4 years ago
cdrom.eclass Sync with portage [Mon Jul 29 11:04:18 MSK 2019]. 5 years ago
check-reqs.eclass Sync with portage [Mon Mar 23 14:16:26 MSK 2020]. 5 years ago
chromium-2.eclass Sync with portage [Wed Oct 3 11:36:37 MSK 2018]. 6 years ago
cmake-multilib.eclass Sync with portage [Sun Dec 29 18:17:49 MSK 2019]. 5 years ago
cmake-utils.eclass Sync with portage [Mon Jul 27 13:14:50 MSK 2020]. 4 years ago
cmake.eclass Sync with portage [Mon Jul 27 13:14:50 MSK 2020]. 4 years ago
common-lisp-3.eclass Sync with portage [Thu Sep 19 08:23:44 MSK 2019]. 5 years ago
cron.eclass Sync with portage [Fri Oct 11 00:11:51 MSK 2019]. 5 years ago
cuda.eclass Sync with portage [Thu Aug 6 08:46:04 MSK 2020]. 4 years ago
cvs.eclass Sync with portage [Mon Jul 29 11:04:18 MSK 2019]. 5 years ago
darcs.eclass Sync with portage [Mon Jul 29 11:04:18 MSK 2019]. 5 years ago
db-use.eclass Sync with portage [Fri Aug 31 09:26:48 MSK 2018]. 6 years ago
db.eclass Sync with portage [Fri Jul 19 08:57:17 MSK 2019]. 5 years ago
depend.apache.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
desktop.eclass Sync with portage [Tue Mar 31 23:47:05 MSK 2020]. 5 years ago
distutils-r1.eclass Sync with portage [Mon Aug 10 09:33:08 MSK 2020]. 4 years ago
dotnet.eclass Sync with portage [Tue Dec 24 09:42:30 MSK 2019]. 5 years ago
dune.eclass Sync with portage [Wed Jun 24 23:16:31 MSK 2020]. 4 years ago
eapi7-ver.eclass Sync with portage [Sun Feb 23 01:15:16 MSK 2020]. 5 years ago
ecm.eclass Sync with portage [Mon Aug 10 09:33:08 MSK 2020]. 4 years ago
elisp-common.eclass Sync with portage [Wed Aug 5 09:12:52 MSK 2020]. 4 years ago
elisp.eclass Sync with portage [Sun Feb 23 01:15:16 MSK 2020]. 5 years ago
emboss-r2.eclass Sync with portage [Wed Aug 5 12:44:46 MSK 2020]. 4 years ago
epatch.eclass Sync with portage [Fri Feb 14 14:01:35 MSK 2020]. 5 years ago
estack.eclass Sync with portage [Thu Nov 28 10:07:22 MSK 2019]. 5 years ago
eutils.eclass Sync with portage [Thu Nov 28 10:07:22 MSK 2019]. 5 years ago
fcaps.eclass Sync with portage [Thu Apr 16 09:15:10 MSK 2020]. 5 years ago
fdo-mime.eclass Sync with portage [Sun Sep 10 23:42:04 MSK 2017]. 7 years ago
findlib.eclass Sync with portage [Sat Dec 14 12:25:16 MSK 2019]. 5 years ago
fixheadtails.eclass Sync with portage [Thu Mar 26 09:24:48 MSK 2020]. 5 years ago
flag-o-matic.eclass Sync with portage [Mon Aug 10 17:52:35 MSK 2020]. 4 years ago
font-ebdftopcf.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
font.eclass Sync with portage [Sun Apr 19 01:04:47 MSK 2020]. 5 years ago
fortran-2.eclass Sync with portage [Wed Aug 5 12:44:46 MSK 2020]. 4 years ago
freedict.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
games.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
ghc-package.eclass Sync with portage [Mon May 25 01:13:37 MSK 2020]. 5 years ago
git-r3.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
gkrellm-plugin.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
gnome.org.eclass Sync with portage [Tue Feb 12 08:41:31 MSK 2019]. 6 years ago
gnome2-utils.eclass Sync with portage [Wed Apr 8 09:28:47 MSK 2020]. 5 years ago
gnome2.eclass Sync with portage [Sun Feb 16 00:29:04 MSK 2020]. 5 years ago
gnuconfig.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
gnustep-2.eclass Sync with portage [Wed Dec 11 07:27:30 MSK 2019]. 5 years ago
gnustep-base.eclass Sync with portage [Tue Aug 21 09:18:45 MSK 2018]. 6 years ago
go-module.eclass Sync with portage [Sun Jun 14 00:18:46 MSK 2020]. 4 years ago
golang-base.eclass Sync with portage [Sat Feb 9 21:58:25 MSK 2019]. 6 years ago
golang-build.eclass Sync with portage [Sat Feb 9 21:58:25 MSK 2019]. 6 years ago
golang-vcs-snapshot.eclass Sync with portage [Sat Feb 9 21:58:25 MSK 2019]. 6 years ago
golang-vcs.eclass Sync with portage [Fri Feb 14 14:01:35 MSK 2020]. 5 years ago
gstreamer.eclass Sync with portage [Sun Jun 14 00:18:46 MSK 2020]. 4 years ago
haskell-cabal.eclass Sync with portage [Thu Dec 12 01:03:07 MSK 2019]. 5 years ago
java-ant-2.eclass Sync with portage [Thu Oct 31 08:56:34 MSK 2019]. 5 years ago
java-osgi.eclass Sync with portage [Mon Mar 20 00:52:52 MSK 2017]. 8 years ago
java-pkg-2.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
java-pkg-opt-2.eclass Sync with portage [Thu Aug 10 10:30:31 MSK 2017]. 7 years ago
java-pkg-simple.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
java-utils-2.eclass Sync with portage [Tue Mar 31 23:47:05 MSK 2020]. 5 years ago
java-virtuals-2.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
java-vm-2.eclass Sync with portage [Wed Feb 6 08:52:01 MSK 2019]. 6 years ago
kde.org.eclass Sync with portage [Mon Aug 10 09:33:08 MSK 2020]. 4 years ago
kernel-2.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
kernel-build.eclass Sync with portage [Sun Aug 23 21:41:43 MSK 2020]. 4 years ago
kernel-install.eclass Sync with portage [Fri Aug 14 09:39:39 MSK 2020]. 4 years ago
kodi-addon.eclass Sync with portage [Wed Feb 12 18:19:49 MSK 2020]. 5 years ago
l10n.eclass Sync with portage [Sun Jan 21 22:29:36 MSK 2018]. 7 years ago
latex-package.eclass Sync with portage [Sun Feb 16 00:29:04 MSK 2020]. 5 years ago
leechcraft.eclass Sync with portage [Mon Apr 6 09:47:37 MSK 2020]. 5 years ago
libretro-core.eclass Sync with portage [Mon Mar 2 09:17:19 MSK 2020]. 5 years ago
libtool.eclass Sync with portage [Tue Sep 11 10:31:09 MSK 2018]. 6 years ago
linux-info.eclass Sync with portage [Sun Jun 28 21:29:51 MSK 2020]. 4 years ago
linux-mod.eclass Sync with portage [Sat Aug 8 21:03:25 MSK 2020]. 4 years ago
llvm.eclass Sync with portage [Thu Jul 16 13:35:55 MSK 2020]. 4 years ago
llvm.org.eclass Sync with portage [Thu Jul 16 13:35:55 MSK 2020]. 4 years ago
ltprune.eclass Sync with portage [Tue Feb 26 08:46:17 MSK 2019]. 6 years ago
mate-desktop.org.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
mate.eclass Sync with portage [Fri Aug 21 08:58:13 MSK 2020]. 4 years ago
mercurial.eclass Sync with portage [Mon Jul 29 11:04:18 MSK 2019]. 5 years ago
meson.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
mono-env.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
mono.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
mount-boot.eclass Sync with portage [Fri Feb 14 14:01:35 MSK 2020]. 5 years ago
mozconfig-v6.52.eclass Sync with portage [Mon Apr 27 11:20:04 MSK 2020]. 5 years ago
mozcoreconf-v4.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
mozcoreconf-v5.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
mozcoreconf-v6.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
mozextension.eclass Sync with portage [Wed Apr 15 09:11:45 MSK 2020]. 5 years ago
mozlinguas-v2.eclass Sync with portage [Sat Sep 8 20:58:36 MSK 2018]. 6 years ago
multibuild.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
multilib-build.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
multilib-minimal.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
multilib.eclass Sync with portage [Sun Jun 14 21:17:57 MSK 2020]. 4 years ago
multiprocessing.eclass Sync with portage [Fri Jan 5 17:04:46 MSK 2018]. 7 years ago
myspell-r2.eclass Sync with portage [Wed May 2 16:04:02 MSK 2018]. 7 years ago
netsurf.eclass Sync with portage [Mon Aug 17 09:25:27 MSK 2020]. 4 years ago
ninja-utils.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
nsplugins.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
nvidia-driver.eclass Sync with portage [Wed Jul 29 20:30:32 MSK 2020]. 4 years ago
oasis.eclass Sync with portage [Sat Dec 14 12:25:16 MSK 2019]. 5 years ago
office-ext-r1.eclass Sync with portage [Thu Apr 2 09:07:50 MSK 2020]. 5 years ago
opam.eclass Sync with portage [Sat Dec 14 12:25:16 MSK 2019]. 5 years ago
openib.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
out-of-source.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
pam.eclass Sync with portage [Tue Dec 3 09:04:34 MSK 2019]. 5 years ago
pax-utils.eclass Sync with portage [Fri Oct 11 00:11:51 MSK 2019]. 5 years ago
perl-functions.eclass Sync with portage [Tue Aug 13 13:22:51 MSK 2019]. 5 years ago
perl-module.eclass Sync with portage [Thu Oct 17 08:47:13 MSK 2019]. 5 years ago
php-ext-pecl-r3.eclass Sync with portage [Tue Nov 28 13:05:58 MSK 2017]. 7 years ago
php-ext-source-r3.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
php-pear-r2.eclass Sync with portage [Fri Nov 2 09:37:43 MSK 2018]. 6 years ago
portability.eclass Sync with portage [Tue Feb 18 18:18:49 MSK 2020]. 5 years ago
postgres-multi.eclass Sync with portage [Thu Feb 20 08:54:55 MSK 2020]. 5 years ago
postgres.eclass Sync with portage [Fri May 15 18:50:27 MSK 2020]. 5 years ago
prefix.eclass Sync with portage [Wed Sep 11 16:47:42 MSK 2019]. 5 years ago
preserve-libs.eclass Sync with portage [Tue Jan 9 23:16:56 MSK 2018]. 7 years ago
python-any-r1.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
python-r1.eclass Sync with portage [Fri Aug 7 16:03:13 MSK 2020]. 4 years ago
python-single-r1.eclass Sync with portage [Fri Aug 7 16:03:13 MSK 2020]. 4 years ago
python-utils-r1.eclass Sync with portage [Fri Aug 7 16:03:13 MSK 2020]. 4 years ago
qmail.eclass Sync with portage [Fri Jun 26 15:33:51 MSK 2020]. 4 years ago
qmake-utils.eclass Sync with portage [Tue Dec 3 09:04:34 MSK 2019]. 5 years ago
qt5-build.eclass Sync with portage [Mon Jun 1 14:18:07 MSK 2020]. 5 years ago
readme.gentoo-r1.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
readme.gentoo.eclass Sync with portage [Fri Feb 14 14:01:35 MSK 2020]. 5 years ago
rebar.eclass Sync with portage [Tue May 12 23:38:17 MSK 2020]. 5 years ago
ros-catkin.eclass Sync with portage [Wed Jul 29 20:30:32 MSK 2020]. 4 years ago
rpm.eclass Sync with portage [Tue Apr 21 09:11:06 MSK 2020]. 5 years ago
ruby-fakegem.eclass Sync with portage [Tue Jul 7 12:41:09 MSK 2020]. 4 years ago
ruby-ng-gnome2.eclass Sync with portage [Thu Jul 30 23:31:06 MSK 2020]. 4 years ago
ruby-ng.eclass Sync with portage [Fri Aug 7 11:07:57 MSK 2020]. 4 years ago
ruby-single.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
ruby-utils.eclass Sync with portage [Fri Aug 7 11:07:57 MSK 2020]. 4 years ago
rust-toolchain.eclass Sync with portage [Sat Apr 25 22:42:29 MSK 2020]. 5 years ago
s6.eclass Sync with portage [Wed Sep 11 16:47:42 MSK 2019]. 5 years ago
savedconfig.eclass Sync with portage [Sun Feb 23 01:15:16 MSK 2020]. 5 years ago
scons-utils.eclass Sync with portage [Mon Jul 6 00:03:10 MSK 2020]. 4 years ago
selinux-policy-2.eclass Sync with portage [Sat Apr 20 19:43:20 MSK 2019]. 6 years ago
sgml-catalog-r1.eclass Sync with portage [Mon Nov 25 12:33:10 MSK 2019]. 5 years ago
ssl-cert.eclass Sync with portage [Sun Aug 18 23:11:04 MSK 2019]. 5 years ago
stardict.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
subversion.eclass Sync with portage [Fri May 29 21:35:56 MSK 2020]. 5 years ago
sword-module.eclass Sync with portage [Wed Jul 29 20:30:32 MSK 2020]. 4 years ago
systemd.eclass Sync with portage [Fri Dec 28 18:46:33 MSK 2018]. 6 years ago
texlive-common.eclass Sync with portage [Thu Aug 13 08:56:12 MSK 2020]. 4 years ago
texlive-module.eclass Sync with portage [Fri Jun 26 15:33:51 MSK 2020]. 4 years ago
tmpfiles.eclass Sync with portage [Wed Sep 11 16:47:42 MSK 2019]. 5 years ago
toolchain-autoconf.eclass Sync with portage [Thu Nov 28 21:43:46 MSK 2019]. 5 years ago
toolchain-funcs.eclass Sync with portage [Sun Jun 14 21:17:57 MSK 2020]. 4 years ago
toolchain-glibc.eclass Sync with portage [Mon Oct 21 08:45:33 MSK 2019]. 5 years ago
toolchain.eclass Sync with portage [Fri Aug 21 08:58:13 MSK 2020]. 4 years ago
udev.eclass Sync with portage [Wed Sep 11 16:47:42 MSK 2019]. 5 years ago
unpacker.eclass Sync with portage [Mon Jun 29 08:56:30 MSK 2020]. 4 years ago
user-info.eclass Sync with portage [Mon Feb 10 00:29:28 MSK 2020]. 5 years ago
user.eclass Sync with portage [Thu Feb 27 11:11:55 MSK 2020]. 5 years ago
usr-ldscript.eclass Sync with portage [Tue Jun 9 08:41:47 MSK 2020]. 5 years ago
vala.eclass Sync with portage [Mon Aug 17 09:25:27 MSK 2020]. 4 years ago
vcs-clean.eclass Sync with portage [Fri Mar 2 16:05:42 MSK 2018]. 7 years ago
vcs-snapshot.eclass Sync with portage [Mon Jul 29 11:04:18 MSK 2019]. 5 years ago
vdr-plugin-2.eclass Sync with portage [Sun Feb 23 22:57:37 MSK 2020]. 5 years ago
versionator.eclass Sync with portage [Thu Aug 16 14:11:29 MSK 2018]. 6 years ago
vim-doc.eclass Sync with portage [Wed Mar 1 14:58:51 MSK 2017]. 8 years ago
vim-plugin.eclass Sync with portage [Tue Nov 7 22:38:01 MSK 2017]. 7 years ago
vim-spell.eclass Sync with portage [Wed Sep 13 12:19:40 MSK 2017]. 7 years ago
virtualx.eclass Sync with portage [Thu Dec 12 01:03:07 MSK 2019]. 5 years ago
waf-utils.eclass Sync with portage [Wed Apr 1 14:47:35 MSK 2020]. 5 years ago
webapp.eclass Sync with portage [Fri Feb 22 09:55:41 MSK 2019]. 6 years ago
wxwidgets.eclass Sync with portage [Mon Jul 15 21:23:45 MSK 2019]. 5 years ago
xdg-utils.eclass Sync with portage [Sun Aug 18 23:11:04 MSK 2019]. 5 years ago
xdg.eclass Sync with portage [Tue Feb 12 08:41:31 MSK 2019]. 6 years ago
xemacs-packages.eclass Sync with portage [Tue Apr 4 09:17:23 MSK 2017]. 8 years ago
xorg-2.eclass Sync with portage [Sun Jun 14 00:18:46 MSK 2020]. 4 years ago
xorg-3.eclass Sync with portage [Mon Aug 17 09:25:27 MSK 2020]. 4 years ago

readme.gentoo.eclass

# Copyright 1999-2020 Gentoo Authors

# Distributed under the terms of the GNU General Public License v2

# @ECLASS: readme.gentoo.eclass
# @MAINTAINER:
# Pacho Ramos <pacho@gentoo.org>
# @AUTHOR:
# Author: Pacho Ramos <pacho@gentoo.org>
# @SUPPORTED_EAPIS: 4 5
# @BLURB: install a doc file shown via elog messages
# @DESCRIPTION:
# An eclass for installing a README.gentoo doc file recording tips
# shown via elog messages. With this eclass, those elog messages will only be
# shown at first package installation and a file for later reviewing will be
# installed under /usr/share/doc/${PF}
#
# This eclass is DEPRECATED. Please use readme.gentoo-r1 instead.

if [[ -z ${_README_GENTOO_ECLASS} ]]; then
_README_GENTOO_ECLASS=1

inherit estack eutils

case "${EAPI:-0}" in
0|1|2|3)
die "Unsupported EAPI=${EAPI:-0} (too old) for ${ECLASS}"
;;
4|5)
# EAPI>=4 is required for REPLACING_VERSIONS preventing us
# from needing to export another pkg_preinst phase to save has_version
# result. Also relies on EAPI >=4 default src_install phase.
EXPORT_FUNCTIONS src_install pkg_postinst
;;
6)
die "Unsupported EAPI=${EAPI} for ${ECLASS}"
die "Please migrate to readme.gentoo-r1.eclass and note that"
die "it stops to export any ebuild phases and, then, you will"
die "need to ensure readme.gentoo_create_doc is called in"
die "src_install and readme.gentoo_print_elog in pkg_postinst"
;;
*)
die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}"
;;
esac

# @ECLASS-VARIABLE: DISABLE_AUTOFORMATTING
# @DEFAULT_UNSET
# @DESCRIPTION:
# If non-empty, DOC_CONTENTS information will be strictly respected,
# not getting it automatically formatted by fmt. If empty, it will
# rely on fmt for formatting and 'echo -e' options to tweak lines a bit.

# @ECLASS-VARIABLE: FORCE_PRINT_ELOG
# @DEFAULT_UNSET
# @DESCRIPTION:
# If non-empty this variable forces elog messages to be printed.

# @ECLASS-VARIABLE: README_GENTOO_SUFFIX
# @DESCRIPTION:
# If you want to specify a suffix for README.gentoo file please export it.
: ${README_GENTOO_SUFFIX:=""}

# @FUNCTION: readme.gentoo_create_doc
# @DESCRIPTION:
# Create doc file with ${DOC_CONTENTS} variable (preferred) and, if not set,
# look for "${FILESDIR}/README.gentoo" contents. You can use
# ${FILESDIR}/README.gentoo-${SLOT} also.
# Usually called at src_install phase.
readme.gentoo_create_doc() {
debug-print-function ${FUNCNAME} "${@}"

if [[ -n "${DOC_CONTENTS}" ]]; then
eshopts_push
set -f
if [[ -n "${DISABLE_AUTOFORMATTING}" ]]; then
echo "${DOC_CONTENTS}" > "${T}"/README.gentoo
else
echo -e ${DOC_CONTENTS} | fold -s -w 70 \
| sed 's/[[:space:]]*$//' > "${T}"/README.gentoo
fi
eshopts_pop
elif [[ -f "${FILESDIR}/README.gentoo-${SLOT%/*}" ]]; then
cp "${FILESDIR}/README.gentoo-${SLOT%/*}" "${T}"/README.gentoo || die
elif [[ -f "${FILESDIR}/README.gentoo${README_GENTOO_SUFFIX}" ]]; then
cp "${FILESDIR}/README.gentoo${README_GENTOO_SUFFIX}" "${T}"/README.gentoo || die
else
die "You are not specifying README.gentoo contents!"
fi

dodoc "${T}"/README.gentoo
README_GENTOO_DOC_VALUE=$(< "${T}/README.gentoo")
}

# @FUNCTION: readme.gentoo_print_elog
# @DESCRIPTION:
# Print elog messages with "${T}"/README.gentoo contents. They will be
# shown only when package is installed at first time.
# Usually called at pkg_postinst phase.
#
# If you want to show them always, please set FORCE_PRINT_ELOG to a non empty
# value in your ebuild before this function is called.
# This can be useful when, for example, DOC_CONTENTS is modified, then, you can
# rely on specific REPLACING_VERSIONS handling in your ebuild to print messages
# when people update from versions still providing old message.
readme.gentoo_print_elog() {
debug-print-function ${FUNCNAME} "${@}"

eqawarn "${CATEGORY}/${PN} is using the deprecated readme.gentoo.eclass."
eqawarn "Please use readme.gentoo-r1 instead."

if [[ -z "${README_GENTOO_DOC_VALUE}" ]]; then
die "readme.gentoo_print_elog invoked without matching readme.gentoo_create_doc call!"
elif ! [[ -n "${REPLACING_VERSIONS}" ]] || [[ -n "${FORCE_PRINT_ELOG}" ]]; then
echo -e "${README_GENTOO_DOC_VALUE}" | while read -r ELINE; do elog "${ELINE}"; done
elog ""
elog "(Note: Above message is only printed the first time package is"
elog "installed. Please look at ${EPREFIX}/usr/share/doc/${PF}/README.gentoo*"
elog "for future reference)"
fi
}


# @FUNCTION: readme.gentoo_src_install
# @DESCRIPTION:
# Install generated doc file automatically.
readme.gentoo_src_install() {
debug-print-function ${FUNCNAME} "${@}"
default
readme.gentoo_create_doc
}

# @FUNCTION: readme.gentoo_pkg_postinst
# @DESCRIPTION:
# Show elog messages from from just generated doc file.
readme.gentoo_pkg_postinst() {
debug-print-function ${FUNCNAME} "${@}"
readme.gentoo_print_elog
}

fi