| Summary: | asterisk ebuild adds group & user during src_install() stage instead of pkg_preinst() | ||
|---|---|---|---|
| Product: | Gentoo Linux | Reporter: | Gabe <gwiebe> |
| Component: | New packages | Assignee: | voip herd (OBSOLETE) <voip+disabled> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | ||
| Priority: | High | ||
| Version: | unspecified | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Package list: | Runtime testing required: | --- | |
|
Description
Gabe
2005-07-18 14:56:11 UTC
by taking these line out of the src_compile stage, the problem is gone:
pkg_preinst() {
einfo "adding asterisk user and group"
if [[ -z "$(egetent passwd asterisk)" ]]; then
einfo "Adding asterisk user and group"
enewgroup asterisk
enewuser asterisk -1 /bin/false /var/lib/asterisk asterisk
fi
# fix permissions
for x in spool run lib log; do
chown -R asterisk:asterisk ${D}/var/${x}/asterisk
chmod -R u=rwX,g=rX,o= ${D}/var/${x}/asterisk
done
chown -R root:asterisk ${D}/etc/asterisk
chmod -R u=rwX,g=rX,o= ${D}/etc/asterisk
}
moved parts from src_install into pkg_preinst, thanks, fixed |