Gentoo Development Guide
pkg_postinst
| Function | pkg_postinst |
| Purpose | Called after image is installed to ${ROOT} |
| Sandbox | Disabled |
| Privilege | root |
| Called for | ebuild, binary |
Default pkg_postinst
pkg_postinst()
{
return
}
Sample pkg_postinst
pkg_postinst() {
if has_version '<x11-wm/fluxbox-0.9.10-r3' ; then
ewarn "You must restart fluxbox before using the [include] /directory/"
ewarn "feature if you are upgrading from an older fluxbox!"
ewarn " "
fi
elog "If you experience font problems, or if fluxbox takes a very"
elog "long time to start up, please try the 'disablexmb' USE flag."
elog "If that fails, please report bugs upstream."
}
Common pkg_postinst Tasks
The most common use for pkg_postinst is to display post-install
informational messages or warnings. Note that has_version will
operate on the version that was installed, which can be useful
for selective upgrade messages.