diff options
-rw-r--r-- | meta-networking/recipes-daemons/postfix/postfix.inc | 25 |
1 files changed, 6 insertions, 19 deletions
diff --git a/meta-networking/recipes-daemons/postfix/postfix.inc b/meta-networking/recipes-daemons/postfix/postfix.inc index de45e080d0..64c20d0f5e 100644 --- a/meta-networking/recipes-daemons/postfix/postfix.inc +++ b/meta-networking/recipes-daemons/postfix/postfix.inc | |||
@@ -202,26 +202,13 @@ ALTERNATIVE_LINK_NAME[mailq.1] = "${mandir}/man1/mailq.1" | |||
202 | ALTERNATIVE_LINK_NAME[newaliases.1] = "${mandir}/man1/newaliases.1" | 202 | ALTERNATIVE_LINK_NAME[newaliases.1] = "${mandir}/man1/newaliases.1" |
203 | ALTERNATIVE_LINK_NAME[sendmail.1] = "${mandir}/man1/sendmail.1" | 203 | ALTERNATIVE_LINK_NAME[sendmail.1] = "${mandir}/man1/sendmail.1" |
204 | 204 | ||
205 | PACKAGE_WRITE_DEPS += "postfix-native" | 205 | pkg_postinst_ontarget_${PN}-cfg () { |
206 | pkg_postinst_${PN}-cfg () { | 206 | touch /etc/aliases |
207 | if [ "x$D" = "x" ]; then | 207 | newaliases |
208 | touch /etc/aliases | ||
209 | newaliases | ||
210 | |||
211 | # generate virtual_alias, default is hash | ||
212 | touch /etc/postfix/virtual_alias | ||
213 | postmap /etc/postfix/virtual_alias | ||
214 | else | ||
215 | touch $D/etc/aliases | ||
216 | # This can fail depending on host setup | ||
217 | if ! newaliases -C $D/etc/postfix/main.cf -oA$D/etc/aliases; then | ||
218 | $INTERCEPT_DIR/postinst_intercept delay_to_first_boot ${PKG} mlprefix=${MLPREFIX} | ||
219 | else | ||
220 | touch $D/etc/postfix/virtual_alias | ||
221 | postmap -c $D/etc/postfix $D/etc/postfix/virtual_alias | ||
222 | fi | ||
223 | 208 | ||
224 | fi | 209 | # generate virtual_alias, default is hash |
210 | touch /etc/postfix/virtual_alias | ||
211 | postmap /etc/postfix/virtual_alias | ||
225 | } | 212 | } |
226 | 213 | ||
227 | PACKAGES =+ "${PN}-cfg" | 214 | PACKAGES =+ "${PN}-cfg" |