The Autoconfig manual states that comment lines can start with either dnl or #.
Is there any difference between them, any reason to use one rather than the other in any circumstance? Or is it purely a matter of taste?
The Autoconfig manual states that comment lines can start with either dnl or #.
Is there any difference between them, any reason to use one rather than the other in any circumstance? Or is it purely a matter of taste?
As noted by others: use dnl for everything in configure.ac that is a "comment" for the configure.ac file and # for everything that you intend to go into the resulting configure script.
One important thing here: dnl prevents all parsing (with the sole exception of dnl(, which can be seen in the following example:
# CHECKME: possibly drop AM_PROG_AR + build_aux/ar-lib
AM_PROG_AR
LT_INIT([dlopen win32-dll])
processed by autoconf leads to
possibly undefined macro: AM_PROG_AR If this token and others are legitimate, please use m4_pattern_allow. See the Autoconf documentation.
While
dnl CHECKME: possibly drop AM_PROG_AR + build_aux/ar-lib
AM_PROG_AR
LT_INIT([dlopen win32-dll])
works fine...
Lesson learned: never use a macro after # (wouldn't make sense to the user of the final configure script in any case) and in most cases use dnl in configure.ac.
Also see Comments in m4 input.