mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
42 lines
1.4 KiB
Text
Executable file
42 lines
1.4 KiB
Text
Executable file
post_install() {
|
|
post_upgrade
|
|
|
|
cat << MES
|
|
>>> To use the ESounD wrapper while using a system-wide daemon, you also need
|
|
to enable auth-anonymous for the esound-unix module, or to copy
|
|
/var/run/pulse/.esd_auth into each home directory.
|
|
>>> To use the system-wide daemon, add your user to the pulse-access group and
|
|
run /etc/rc.d/pulseaudio start or add pulseaudio to your DAEMONS array in
|
|
your /etc/rc.conf. The daemon configuration is in /etc/pulse/system.pa.
|
|
MES
|
|
}
|
|
|
|
post_upgrade() {
|
|
# Delete old group
|
|
getent group realtime &>/dev/null && /usr/sbin/groupdel realtime &>/dev/null
|
|
|
|
# Add groups
|
|
getent group pulse &>/dev/null || /usr/sbin/groupadd -g 130 pulse &>/dev/null
|
|
getent group pulse-access &>/dev/null || /usr/sbin/groupadd -g 131 pulse-access &>/dev/null
|
|
getent group pulse-rt &>/dev/null || /usr/sbin/groupadd -g 132 pulse-rt &>/dev/null
|
|
|
|
# Add user
|
|
getent passwd pulse &>/dev/null || {
|
|
/usr/sbin/useradd -u 130 -d /var/run/pulse -g pulse -G audio -s /bin/false pulse
|
|
passwd -l pulse &>/dev/null
|
|
}
|
|
chown pulse:pulse /var/pulse
|
|
}
|
|
|
|
post_remove() {
|
|
getent group pulse &>/dev/null && /usr/sbin/groupdel pulse &>/dev/null
|
|
getent group pulse-access &>/dev/null && /usr/sbin/groupdel pulse-access &>/dev/null
|
|
getent group pulse-rt &>/dev/null && /usr/sbin/groupdel pulse-rt &>/dev/null
|
|
getent passwd pulse &>/dev/null && /usr/sbin/userdel -f pulse &>/dev/null
|
|
}
|
|
|
|
op=$1
|
|
shift
|
|
$op $*
|
|
|
|
# vim:set ts=2 sw=2 et:
|