Hello Viktor!
Once again I would like to thank you for your comprehensive and detailed
explanation.
Since I use virtual mailboxes using MySQL, I would have to include the
support. And it is correct that I would use the system OpenSSL version.
Would my customisation for the bash script be correct in this case?
#! /bin/sh
PFIX=/opt/postfix
OSSL=/usr
OSSL_LDFLAGS="-lssl -lcrypto"
OSSL_CFLAGS=""
make -f Makefile.init dynamicmaps=yes shared=yes pie=yes
openssl_path=$OSSL/bin/openssl \
"CCARGS=$OSSL_CFLAGS "'-DNO_NIS -DUSE_SASL_AUTH -I/usr/include/sasl
-DHAS_PCRE=2 -DUSE_CYRUS_SASL -DUSE_TLS -DUSE_MYSQL -DHAS_CDB -DHAS_LMDB' \
"AUXLIBS=$OSSL_LDFLAGS "'-lsasl2 -ldb' \
'AUXLIBS_CDB=-lcdb' \
'AUXLIBS_PCRE=-lpcre2-8' \
'AUXLIBS_LMDB=-llmdb' \
AUXLIBS_MYSQL='-L/usr/lib/x86_64-linux-gnu -lmysqlclient -lz\
command_directory=$PFIX/sbin \
config_directory=$PFIX/etc \
daemon_directory=$PFIX/libexec \
data_directory=/var/lib/postfix \
mailq_path=$PFIX/sbin/mailq \
newaliases_path=$PFIX/sbin/newaliases \
queue_directory=/var/spool/postfix \
sendmail_path=$PFIX/sbin/sendmail \
shlib_directory=$PFIX/lib64/MAIL_VERSION \
html_directory=no \
manpage_directory=$PFIX/man \
readme_directory=no \
makefiles
Since I would install postfix on a freshly installed server, the
question is whether I should then install postfix under /opt/postfix or
whether the default paths are also okay? If so, I could use the paths
suggested by the installation script for the installation. Correct?
Do I have to back up the existing sendmail before an initial
installation as mentioned in the INSTALL document? In this manner:
# mv /usr/sbin/sendmail /usr/sbin/sendmail.OFF
# mv /usr/bin/newaliases /usr/bin/newaliases.OFF
# mv /usr/bin/mailq /usr/bin/mailq.OFF
# chmod 755 /usr/sbin/sendmail.OFF /usr/bin/newaliases.OFF \
/usr/bin/mailq.OFF
Oder benutzt du hierzu die von dir erwähnten Symlinks, die du setzt?
Am 09.03.2025 um 13:02 schrieb Viktor Dukhovni via Postfix-users:
On Sun, Mar 09, 2025 at 09:54:29AM +0100, Andreas Kuhlen via Postfix-users
wrote:
But before I get to that point, I guess I
need to make more detailed plans about which features I compile postfix
with. STARTTLS, MySQL and SASL authentication come to mind. I don't really
know what else is useful/required.
Less is more. Start with the basics, add only what you need.
Because I also use my own OpenSSL builds, I use:
#! /bin/sh
PFIX=/opt/postfix
OSSL=/opt/openssl/3.5
OSSL_LDFLAGS="-Wl,-R,$OSSL/lib64 -L$OSSL/lib64 -lssl -lcrypto"
OSSL_CFLAGS="-I$OSSL/include"
make -f Makefile.init dynamicmaps=yes shared=yes pie=yes
openssl_path=$OSSL/bin/openssl \
"CCARGS=$OSSL_CFLAGS "'-DNO_NIS -DUSE_SASL_AUTH -I/usr/include/sasl
-DHAS_PCRE=2 -DUSE_CYRUS_SASL -DUSE_TLS -DHAS_CDB -DHAS_LMDB' \
"AUXLIBS=$OSSL_LDFLAGS "'-lsasl2 -ldb' \
'AUXLIBS_CDB=-lcdb' \
'AUXLIBS_PCRE=-lpcre2-8' \
'AUXLIBS_LMDB=-llmdb' \
command_directory=$PFIX/sbin \
config_directory=$PFIX/etc \
daemon_directory=$PFIX/libexec \
data_directory=/var/lib/postfix \
mailq_path=$PFIX/sbin/mailq \
newaliases_path=$PFIX/sbin/newaliases \
queue_directory=/var/spool/postfix \
sendmail_path=$PFIX/sbin/sendmail \
shlib_directory=$PFIX/lib64/MAIL_VERSION \
html_directory=no \
manpage_directory=$PFIX/man \
readme_directory=no \
makefiles
This adds TLS, PCRE2, SASL, CDB and LMDB. You're likely content with
the system OpenSSL, and would then want something like:
OSSL=/usr
OSSL_LDFLAGS="-lssl -lcrypto"
OSSL_CFLAGS=""
_______________________________________________
Postfix-users mailing list -- postfix-users@postfix.org
To unsubscribe send an email to postfix-users-le...@postfix.org