2

I am experiencing issues while compiling latest version of postfix from source code. At the moment I'm trying to compile version 3 because Debian 7 and latest Ubuntu 14,10 (version 2,9 and 2,11 for postfix) are buggy for configuring virtual mailboxes with Maildir protocol. I was thinking to make mysql tables to store local aliases and virtual mailboxes but I'd like to provide SMTP authentication access introducing SASL with dovecot as IMAP server. What is the difference between CCARGS and AUXLIBS?

I downloaded cyrus-sasl package to build and install and I'm pointing makefiles with these parameters: make CCARGS='-DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/tmp/cyrus-sasl/include' AUXLIBS='-lsasl2' where include is the folder with sasl sources.

In this way, I got error reported here. As Mohsen suggested, I appended

-ldb -lnsl -lresolv

to AUXLIBS but it throws another error and I haven't found any solution to continue from this point.

Here's the error:

gcc -I. -I../../include -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/tmp/cyrus-sasl/include -DHAS_PCRE -UUSE_DYNAMIC_LIBS -DDEF_SHLIB_DIR=\"no\" -UUSE_DYNAMIC_MAPS -Wmissing-prototypes -Wformat -Wno-comment -g -O -I. -I../../include -DLINUX3 -c smtpd.c
smtpd.c: In function ‘xclient_cmd’:
smtpd.c:4028:11: error: ‘SMTPD_STATE’ has no member named ‘tls_context’
  if (state->tls_context == 0)  /* TLS from XCLIENT proxy? */

What am I missing or doing wrong?

blurstream
  • 139
  • 3
  • Looks like an [XY problem](http://meta.stackexchange.com/questions/66377/what-is-the-xy-problem) to me. Your actual problem is **fixing virtual mailboxes with Maildir** and you try to solve it by compiling the most recent version of postfix – masegaloeh Mar 22 '15 at 06:58

1 Answers1

5

buggy for configuring virtual mailboxes with Maildir protocol

I'm using Dovecot LMTP for delivery to Maildir boxes and don't have any problems.

I'd like to provide SMTP authentication access introducing SASL with dovecot as IMAP server

The easier way is to authenticate SMTP users through Dovecot, so you don't need to configure SASL authentication in both.

Add

service auth {
    unix_listener auth-userdb {
        mode = 0666
    }
    unix_listener /var/spool/postfix/private/auth {
        mode = 0666
        user = postfix
        group = postfix
    }
}

service lmtp {
    unix_listener /var/spool/postfix/private/dovecot-lmtp {
        mode = 0660
        user = postfix
        group = postfix
    }
}

to your /etc/dovecot/conf.d/10-master.conf

Then

virtual_transport = lmtp:unix:private/dovecot-lmtp

smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth

to your /etc/postfix/main.cf and you are done.

Dopamine
  • 176
  • 1
  • 8