Re: Sendmail Compile-Time Configuration - Success



On 2006-04-30 02:55, Duane Whitty <duane@xxxxxxxxxxxxxx> wrote:
Giorgos Keramidas wrote:
No, you probably want something similar to the way SASL2 support is
compiled into the base-system version of Sendmail. In my `make.conf'
I have the following:

SENDMAIL_CFLAGS= -I/usr/local/include -DSASL=2
SENDMAIL_LDFLAGS= -L/usr/local/lib
SENDMAIL_LDADD= -lsasl2

While adding stuff to these variables please keep in mind that GCC on
FreeBSD has a major difference from the default GCC behavior: it does *not*
add /usr/local/include to the default include path or /usr/local/lib to the
default library search path. So you will have to add them yourself, as
shown above.

Hi,

Thank you Giorgos, this is the right direction. Your example was most
fortuitous, maybe even prescient. ;)

Heh! Sheer luck, sheer luck.

LDAP support in Sendmail requires that SASL support also be built in.

Great! I didn't know this, but SASL is one of the examples I could
easily find in /usr/src to copy/ into the reply :-)

SENDMAIL_CFLAGS= -I/usr/local/include -DSASL=2 -DLDAPMAP
SENDMAIL_LDFLAGS= -L/usr/local/lib
SENDMAIL_LDADD= -lsasl2 -lldap -llber

sendmail -d0.1 -bt now includes LDAPMAP and USE_LDAP_INIT

Cool! Just another useful bit, then, now that you got it all going.

Now you have to make sure you remember to rebuild Sendmail whenever
these libraries change version number. An easy way to do this is using
something like:

% gothmog:/home/build/src# cat -n ../rebuild-sendmail.sh
% 1 #!/bin/sh
% 2
% 3 DIRS=""
% 4 DIRS="${DIRS} ./bin/rmail"
% 5 DIRS="${DIRS} ./lib/libmilter"
% 6 DIRS="${DIRS} ./lib/libsm"
% 7 DIRS="${DIRS} ./lib/libsmdb"
% 8 DIRS="${DIRS} ./lib/libsmutil"
% 9 DIRS="${DIRS} ./libexec/mail.local"
% 10 DIRS="${DIRS} ./libexec/smrsh"
% 11 DIRS="${DIRS} ./usr.bin/vacation"
% 12 DIRS="${DIRS} ./usr.sbin/editmap"
% 13 DIRS="${DIRS} ./usr.sbin/mailstats"
% 14 DIRS="${DIRS} ./usr.sbin/makemap"
% 15 DIRS="${DIRS} ./usr.sbin/praliases"
% 16 DIRS="${DIRS} ./usr.sbin/sendmail"
% 17
% 18 export MAKEOBJDIRPREFIX=/home/build/obj
% 19
% 20 for dname in ${DIRS} ; do
% 21 ( cd "${dname}" && make clean && make && make install )
% 22 if test $? -ne 0 ; then
% 23 echo ""
% 24 echo ">>> FAILED while rebuilding ${dname}"
% 25 exit 1
% 26 fi
% 27 done
% gothmog:/home/build/src#

I keep this script just one folder upwards of my usual build tree, and
then run it inside `/home/build/src' to rebuild the Sendmail bits.

Have fun,

- Giorgos

_______________________________________________
freebsd-questions@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Sendmail 8.13.1 build problem on Solaris 8
    ... I have seen other sendmail related issues here, ... make: Fatal error: Command failed for target `sendmail' ... Your C compiler maybe issued a warning during compilation, ...
    (SunManagers)
  • Re: sendmail 8.13.5 compile problems on solaris 9
    ... No output written to sendmail ... your gcc may be looking elsewhere too). ... If you don't care about nbdm, make sure that you have Berkeley DB ... APPENDDEF which is normally used is not enough for this override - not ...
    (comp.mail.sendmail)
  • Re: Just how bad are the UNIX vendor Sendmail releases...?
    ... Seems that I'll have to replace an old HP-UX mail server running ... Apparently the newest Sendmail offered by HP is 8.13.3. ... various support libraries on my own with some newish version of GCC? ... the add-on compiler, it's probably best to use that instead of gcc. ...
    (comp.mail.sendmail)
  • Re: Build error for assert.c
    ... > When attempting to build Sendmail 8.13.4 with a default configuration ... > using gcc 3.3.2 on Solaris 10, ...
    (comp.mail.sendmail)
  • Re: Trouble rebuilding sendmail
    ... >>I just upgrade src with cvsup and want to rebuild sendmail. ... >>reason it stops and I would very much like some help from you about what ... but do you have sendmail installed from ports also? ...
    (freebsd-questions)