As for this code snippet:
AM_MAINTAINER_MODE if test "x$enable_maintainer_mode" = xyes; then AC_PATH_PROG(PERL,perl) if test -z "$PERL"; then AC_MSG_ERROR([perl not found]) fi fi # This should be checked before AC_PROG_CC if test "x$CFLAGS" = x; then default_CFLAGS=yes fi if test "x$host_cpu" = xx86_64; then CFLAGS="-m32 $CFLAGS" fi
I can't find any information on the three variable that is being tested (x$enable_maintainer_mode, x$CFLAGS, x$host_cpu). Are these variable generated after executing the macro AM_MAINTAINER_MODE? If so, where can I find more information about them?
Also, what's the purpose of the AM_MAINTAINER_MODE mode?
From my understanding, it's disabled by default:
- If a user runs 'configure' and all dependencies are NOT met (Automake version, tools, libraries, etc.), it with terminate and will not proceed further.
- If a user runs 'configure' and all dependencies are met, it creates and runs the config.status script which generates the 'make' files
- A user can override this setting with the –enable-maintainer-mode option. This will allows them to modify different Autotool files (such as configure.ac, Makefile.am) and the build system will try to regenerate the files that need to be updated to reflect these changes (Autotools will look for any outdated files and update them accordingly).
I can see why disabling this mode may be preferable. Any reasons why'd you'd want to enable this feature?