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.
calculate-overlay/profiles/patches/net-nds/openldap-provide-ldap.sh

12 lines
341 B

if [[ ${EBUILD_PHASE} == postinst ]]
then
if [[ -f ${ROOT}/etc/init.d/slapd ]]
then
# find ldap service in depend section, and if it is absend then append 'provide ldap'
ebegin "Fix /etc/init.d/slapd"
sed -ri '/depend/ {:b;s/\bldap\b/&/;te;s/[}]/&/;tr;N;bb;:r;s/\}/\tprovide ldap\n\}/;:e}' ${ROOT}/etc/init.d/slapd
eend 0
fi
fi