From f7b7cd91712cce51a1da5608d4ce9921436c2378 Mon Sep 17 00:00:00 2001 From: Chris Bagwell Date: Tue, 27 Jan 2009 01:10:24 +0000 Subject: [PATCH] Add AM_MAINTAINER_MODE to prevent regenerating configure script with possibly broken user autotools. --- ChangeLog | 5 ++++ Makefile.in | 9 +++--- aclocal.m4 | 29 +++++++++++++++++++ configure | 81 +++++++++++++++++++++++++++++++++++++--------------- configure.in | 4 +++ 5 files changed, 101 insertions(+), 27 deletions(-) diff --git a/ChangeLog b/ChangeLog index dd9cff25e..90e6540a9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2009-01-26 Chris Bagwell + * configure.in: Add AM_MAINTAINER_MODE to disable regenerating + configure files. This was behavior of Makefiles before automake + and works around various timestamp issues. + 2009-01-25 Pierre Willenbrock * backend/genesys_gl841.c: Change status code for locked head to SANE_STATUS_HW_LOCKED diff --git a/Makefile.in b/Makefile.in index 2be784238..1aaf43a50 100644 --- a/Makefile.in +++ b/Makefile.in @@ -147,6 +147,7 @@ LINKER_RPATH = @LINKER_RPATH@ LN_S = @LN_S@ LOCKPATH_GROUP = @LOCKPATH_GROUP@ LTLIBOBJS = @LTLIBOBJS@ +MAINT = @MAINT@ MAKEDEPEND = @MAKEDEPEND@ MAKEINDEX = @MAKEINDEX@ MAKEINFO = @MAKEINFO@ @@ -259,7 +260,7 @@ all: all-recursive .SUFFIXES: am--refresh: @: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -286,9 +287,9 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck -$(top_srcdir)/configure: $(am__configure_deps) +$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(srcdir) && $(AUTOCONF) -$(ACLOCAL_M4): $(am__aclocal_m4_deps) +$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) include/sane/config.h: include/sane/stamp-h1 @@ -300,7 +301,7 @@ include/sane/config.h: include/sane/stamp-h1 include/sane/stamp-h1: $(top_srcdir)/include/sane/config.h.in $(top_builddir)/config.status @rm -f include/sane/stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status include/sane/config.h -$(top_srcdir)/include/sane/config.h.in: $(am__configure_deps) +$(top_srcdir)/include/sane/config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) cd $(top_srcdir) && $(AUTOHEADER) rm -f include/sane/stamp-h1 touch $@ diff --git a/aclocal.m4 b/aclocal.m4 index 8fe6e66af..0faa8ceb5 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -687,6 +687,35 @@ fi rmdir .tst 2>/dev/null AC_SUBST([am__leading_dot])]) +# Add --enable-maintainer-mode option to configure. -*- Autoconf -*- +# From Jim Meyering + +# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005 +# 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. + +# serial 4 + +AC_DEFUN([AM_MAINTAINER_MODE], +[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles]) + dnl maintainer-mode is disabled by default + AC_ARG_ENABLE(maintainer-mode, +[ --enable-maintainer-mode enable make rules and dependencies not useful + (and sometimes confusing) to the casual installer], + USE_MAINTAINER_MODE=$enableval, + USE_MAINTAINER_MODE=no) + AC_MSG_RESULT([$USE_MAINTAINER_MODE]) + AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes]) + MAINT=$MAINTAINER_MODE_TRUE + AC_SUBST(MAINT)dnl +] +) + +AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE]) + # Check to see how 'make' treats includes. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. diff --git a/configure b/configure index db5630492..f692c6ded 100755 --- a/configure +++ b/configure @@ -879,6 +879,9 @@ NUMBER_VERSION V_REV V_MINOR V_MAJOR +MAINT +MAINTAINER_MODE_FALSE +MAINTAINER_MODE_TRUE am__untar am__tar AMTAR @@ -942,6 +945,7 @@ SHELL' ac_subst_files='' ac_user_opts=' enable_option_checking +enable_maintainer_mode with_docdir enable_dependency_tracking enable_warnings @@ -1617,6 +1621,8 @@ Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --enable-maintainer-mode enable make rules and dependencies not useful + (and sometimes confusing) to the casual installer --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors --enable-warnings turn on tons of compiler warnings (GCC only) @@ -2626,6 +2632,28 @@ am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' +{ $as_echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5 +$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } + # Check whether --enable-maintainer-mode was given. +if test "${enable_maintainer_mode+set}" = set; then + enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval +else + USE_MAINTAINER_MODE=no +fi + + { $as_echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5 +$as_echo "$USE_MAINTAINER_MODE" >&6; } + if test $USE_MAINTAINER_MODE = yes; then + MAINTAINER_MODE_TRUE= + MAINTAINER_MODE_FALSE='#' +else + MAINTAINER_MODE_TRUE='#' + MAINTAINER_MODE_FALSE= +fi + + MAINT=$MAINTAINER_MODE_TRUE + + ac_config_headers="$ac_config_headers include/sane/config.h" @@ -14922,7 +14950,7 @@ ia64-*-hpux*) ;; *-*-irix6*) # Find out which ABI we are using. - echo '#line 14925 "configure"' > conftest.$ac_ext + echo '#line 14953 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? @@ -17479,11 +17507,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:17482: $lt_compile\"" >&5) + (eval echo "\"\$as_me:17510: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:17486: \$? = $ac_status" >&5 + echo "$as_me:17514: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -17747,11 +17775,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:17750: $lt_compile\"" >&5) + (eval echo "\"\$as_me:17778: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:17754: \$? = $ac_status" >&5 + echo "$as_me:17782: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -17851,11 +17879,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:17854: $lt_compile\"" >&5) + (eval echo "\"\$as_me:17882: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:17858: \$? = $ac_status" >&5 + echo "$as_me:17886: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -20195,7 +20223,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < conftest.$ac_ext <&5) + (eval echo "\"\$as_me:22674: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:22650: \$? = $ac_status" >&5 + echo "$as_me:22678: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -22747,11 +22775,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:22750: $lt_compile\"" >&5) + (eval echo "\"\$as_me:22778: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:22754: \$? = $ac_status" >&5 + echo "$as_me:22782: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -24317,11 +24345,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:24320: $lt_compile\"" >&5) + (eval echo "\"\$as_me:24348: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:24324: \$? = $ac_status" >&5 + echo "$as_me:24352: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -24421,11 +24449,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:24424: $lt_compile\"" >&5) + (eval echo "\"\$as_me:24452: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:24428: \$? = $ac_status" >&5 + echo "$as_me:24456: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -26631,11 +26659,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:26634: $lt_compile\"" >&5) + (eval echo "\"\$as_me:26662: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:26638: \$? = $ac_status" >&5 + echo "$as_me:26666: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -26899,11 +26927,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:26902: $lt_compile\"" >&5) + (eval echo "\"\$as_me:26930: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:26906: \$? = $ac_status" >&5 + echo "$as_me:26934: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -27003,11 +27031,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:27006: $lt_compile\"" >&5) + (eval echo "\"\$as_me:27034: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:27010: \$? = $ac_status" >&5 + echo "$as_me:27038: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -30019,6 +30047,13 @@ LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs +if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then { { $as_echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." >&5 diff --git a/configure.in b/configure.in index 1f37dadc0..b323477a3 100644 --- a/configure.in +++ b/configure.in @@ -13,6 +13,10 @@ dnl *********************************************************************** m4_ifdef([AC_CONFIG_MACRO_DIR], [AC_CONFIG_MACRO_DIR([m4])]) AM_INIT_AUTOMAKE +dnl Turn off feature were automake will automatically run autoreconf. +dnl This is because we check in generated files into CVS which has +dnl known timestamp issues. +AM_MAINTAINER_MODE AC_CONFIG_HEADERS([include/sane/config.h]) AC_PREREQ(2.54)dnl dnl Minimum Autoconf version required.