What is the difference between "dnl" and "dnl #" in a sendmail.mc file?
There's a subtle but important difference between dnl
and #
here.
dnl
means "delete through newline". When you process your sendmail.mc
into a sendmail.cf
using m4
(or possibly some frontend), the characters dnl
and everything following them, including the next newline, will be dropped. (And all of those lines end with dnl
to suppress extra blank lines in the sendmail.cf
output.)
Nothing beginning with dnl
through end of line will make it out of sendmail.mc
and into sendmail.cf
.
Anything that remains in the output, of course, will either be sendmail configuration, or a comment that begins with #
, which will be copied as-is into sendmail.cf
, where they will be ignored.
Anything beginning with #
and not deleted above will make it into sendmail.cf
unmolested as a comment.
In your example, someone meant for all of the commented features to be removed from sendmail.cf
, as well as the comments, since the comments would be meaningless without the features present.
DNL means "delete through newline" which really means "ignore everything after 'dnl' until the next line".
The "dnl #" is just artificial nomenclature. When the sendmail.mc file was first developed they wanted you to know that anything that was "dnl ..." was a command/setting that was commented out and anything that was "dnl #..." was really a descriptive comment that was not a command/setting that could be uncommented because '#' is often used at the beginning of a line to indicate "what follows until end of line" is a comment.