| ## -*- Autoconf -*- | |
| # Copyright (C) 2009-2026 Free Software Foundation, Inc. | |
| # | |
| # This file is free software; the Free Software Foundation | |
| # gives unlimited permission to copy and/or distribute it, | |
| # with or without modifications, as long as this notice is preserved. | |
| # _AM_SILENT_RULES | |
| # ---------------- | |
| # Enable less verbose build rules support. | |
| AC_DEFUN([_AM_SILENT_RULES], | |
| [AM_DEFAULT_VERBOSITY=1 | |
| AC_ARG_ENABLE([silent-rules], [dnl | |
| AS_HELP_STRING( | |
| [--enable-silent-rules], | |
| [less verbose build output (undo: "make V=1")]) | |
| AS_HELP_STRING( | |
| [--disable-silent-rules], | |
| [verbose build output (undo: "make V=0")])dnl | |
| ]) | |
| dnl | |
| dnl A few 'make' implementations (e.g., NonStop OS and NextStep) | |
| dnl do not support nested variable expansions. | |
| dnl See automake bug#9928 and bug#10237. | |
| am_make=${MAKE-make} | |
| AC_CACHE_CHECK([whether $am_make supports nested variables], | |
| [am_cv_make_support_nested_variables], | |
| [if AS_ECHO([['TRUE=$(BAR$(V)) | |
| BAR0=false | |
| BAR1=true | |
| V=1 | |
| am__doit: | |
| @$(TRUE) | |
| .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then | |
| am_cv_make_support_nested_variables=yes | |
| else | |
| am_cv_make_support_nested_variables=no | |
| fi]) | |
| AC_SUBST([AM_V])dnl | |
| AM_SUBST_NOTMAKE([AM_V])dnl | |
| AC_SUBST([AM_DEFAULT_V])dnl | |
| AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl | |
| AC_SUBST([AM_DEFAULT_VERBOSITY])dnl | |
| AM_BACKSLASH='\' | |
| AC_SUBST([AM_BACKSLASH])dnl | |
| _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl | |
| dnl Delay evaluation of AM_DEFAULT_VERBOSITY to the end to allow multiple calls | |
| dnl to AM_SILENT_RULES to change the default value. | |
| AC_CONFIG_COMMANDS_PRE([dnl | |
| case $enable_silent_rules in @%:@ ((( | |
| yes) AM_DEFAULT_VERBOSITY=0;; | |
| no) AM_DEFAULT_VERBOSITY=1;; | |
| esac | |
| if test $am_cv_make_support_nested_variables = yes; then | |
| dnl Using '$V' instead of '$(V)' breaks IRIX make. | |
| AM_V='$(V)' | |
| AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' | |
| else | |
| AM_V=$AM_DEFAULT_VERBOSITY | |
| AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY | |
| fi | |
| ])dnl | |
| ]) | |
| # AM_SILENT_RULES([DEFAULT]) | |
| # -------------------------- | |
| # Set the default verbosity level to DEFAULT ("yes" being less verbose, "no" or | |
| # empty being verbose). | |
| AC_DEFUN([AM_SILENT_RULES], | |
| [AC_REQUIRE([_AM_SILENT_RULES]) | |
| AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1])m4_newline | |
| dnl We intentionally force a newline after the assignment, since a) nothing | |
| dnl good can come of more text following, and b) that was the behavior | |
| dnl before 1.17. See https://bugs.gnu.org/72267. | |
| ]) |