From: Dave Hart Date: Tue, 23 Nov 2010 09:49:49 +0000 (+0000) Subject: correct m4 quoting to quiet autoreconf warnings X-Git-Tag: NTP_4_2_7P85~3^2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ba6f48a8a3431c27e7ecb9d35c9af56e240d1c67;p=thirdparty%2Fntp.git correct m4 quoting to quiet autoreconf warnings enable ./bootstrap --force bk: 4ceb8e3dwQ6Jci1z0Nc4--pPlpPeHQ --- diff --git a/bootstrap b/bootstrap index 18c503072..01e36d35c 100755 --- a/bootstrap +++ b/bootstrap @@ -3,6 +3,8 @@ # This "bootstrap" script performs various pre-autoreconf actions # that are required after pulling fresh sources from the repository. # +# --force is supported and will be passed to autoreconf +# # NOTE: THE NTP VERSION NUMBER COMES FROM packageinfo.sh # # all other instances of it anywhere in the source base have propagated @@ -120,7 +122,7 @@ touch ntpd/ntp_parser.[ch] ntpd/keyword-gen-utd ntpd/ntp_keyword.h cp bincheck.mf sntp/ cp depsver.mf sntp/ -${AUTORECONF} -i -v --no-recursive +${AUTORECONF} -i -v --no-recursive "$@" # DH: 20101120: We are back to a single copy of libopts, and # once again it seems we need to run autoreconf in sntp after @@ -134,4 +136,4 @@ ${AUTORECONF} -i -v --no-recursive ## we get the correct srcdir path in sntp/libopts/Makefile.in #rm -rf sntp/autom4te.cache # -(cd sntp && ${AUTORECONF} -i -v) +(cd sntp && ${AUTORECONF} -i -v "$@") diff --git a/configure.ac b/configure.ac index 27f59b9a6..3ed759e49 100644 --- a/configure.ac +++ b/configure.ac @@ -131,10 +131,10 @@ AC_FUNC_FORK AC_CACHE_CHECK( [if $CC can handle @%:@warning], - ac_cv_cpp_warning, + [ac_cv_cpp_warning], [ AC_COMPILE_IFELSE( - AC_LANG_PROGRAM([], [#warning foo]), + [AC_LANG_PROGRAM([[]], [[#warning foo]])], [ac_cv_cpp_warning=yes], [ac_cv_cpp_warning=no], ) @@ -1251,14 +1251,17 @@ AC_CACHE_VAL(ac_cv_func_getsockname_arg2,dnl [AC_CACHE_VAL(ac_cv_func_getsockname_socklen_type,dnl [for ac_cv_func_getsockname_arg2 in 'struct sockaddr *' 'void *'; do for ac_cv_func_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do - AC_TRY_COMPILE(dnl -[#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -extern getsockname (int, $ac_cv_func_getsockname_arg2, $ac_cv_func_getsockname_socklen_type *);],,dnl + AC_TRY_COMPILE( + [AC_LANG_PROGRAM([ + #ifdef HAVE_SYS_TYPES_H + #include + #endif + #ifdef HAVE_SYS_SOCKET_H + #include + #endif + ], [ + extern getsockname (int, $ac_cv_func_getsockname_arg2, $ac_cv_func_getsockname_socklen_type *); + ])], , [ac_not_found=no ; break 2], ac_not_found=yes) done done @@ -2167,8 +2170,8 @@ case "$ac_cv_var_tty_clk" in esac AC_CACHE_CHECK([for the ppsclock streams module], - ac_cv_var_ppsclock, - ac_cv_var_ppsclock=$ac_cv_struct_ppsclockev) + [ac_cv_var_ppsclock], + [ac_cv_var_ppsclock=$ac_cv_struct_ppsclockev]) case "$ac_cv_var_ppsclock" in yes) AC_DEFINE(PPS, 1, [Do we have the ppsclock streams module?]) ;; esac @@ -2182,7 +2185,7 @@ AC_CACHE_CHECK( i386-sequent-sysv4) ;; *) - AC_COMPILE_IFELSE( + AC_COMPILE_IFELSE([ AC_LANG_PROGRAM( [ #ifdef HAVE_NETINET_IN_H @@ -2193,7 +2196,7 @@ AC_CACHE_CHECK( struct ip_mreq ipmr; ipmr.imr_interface.s_addr = 0; ] - ), + )], [ntp_cv_multicast=yes], [] ) diff --git a/m4/ntp_openssl.m4 b/m4/ntp_openssl.m4 index e1df56088..1cbc052a3 100644 --- a/m4/ntp_openssl.m4 +++ b/m4/ntp_openssl.m4 @@ -7,7 +7,7 @@ AC_SUBST(OPENSSL_INC) AC_SUBST(OPENSSL_LIB) AC_MSG_CHECKING([for openssl library directory]) -AC_ARG_WITH(openssl-libdir, +AC_ARG_WITH([openssl-libdir], AC_HELP_STRING([--with-openssl-libdir], [+ =/something/reasonable]), [ans=$withval], [case "$build" in @@ -51,7 +51,7 @@ esac AC_MSG_RESULT([$ans]) AC_MSG_CHECKING([for openssl include directory]) -AC_ARG_WITH(openssl-incdir, +AC_ARG_WITH([openssl-incdir], AC_HELP_STRING([--with-openssl-incdir], [+ =/something/reasonable]), [ans=$withval], [case "$build" in @@ -87,7 +87,7 @@ esac AC_MSG_RESULT([$ans]) AC_MSG_CHECKING([if we will use crypto]) -AC_ARG_WITH(crypto, +AC_ARG_WITH([crypto], AC_HELP_STRING([--with-crypto], [+ =openssl]), [ans=$withval], [ans=yes]) case "$ans" in @@ -143,11 +143,11 @@ SAVED_CFLAGS="$CFLAGS" case "$GCC$ntp_openssl" in yesyes) CFLAGS="$CFLAGS -Werror" - AC_COMPILE_IFELSE( + AC_COMPILE_IFELSE([ AC_LANG_SOURCE([[ /* see if -Werror breaks gcc */ ]]), [gcc_handles_Werror=yes], [gcc_handles_Werror=no] - ) + ]) case "$gcc_handles_Werror" in no) # if this gcc doesn't do -Werror go ahead and use @@ -156,7 +156,7 @@ case "$GCC$ntp_openssl" in ;; yes) CFLAGS="$CFLAGS -Wstrict-prototypes" - AC_COMPILE_IFELSE( + AC_COMPILE_IFELSE([ AC_LANG_PROGRAM( [[ #include "openssl/asn1_mac.h" @@ -171,7 +171,7 @@ case "$GCC$ntp_openssl" in ), [openssl_triggers_warnings=no], [openssl_triggers_warnings=yes] - ) + ]) esac case "$openssl_triggers_warnings" in yes) diff --git a/sntp/configure.ac b/sntp/configure.ac index 6ff842f46..9ac384312 100644 --- a/sntp/configure.ac +++ b/sntp/configure.ac @@ -201,14 +201,17 @@ AC_CACHE_VAL(ac_cv_func_getsockname_arg2,dnl [AC_CACHE_VAL(ac_cv_func_getsockname_socklen_type,dnl [for ac_cv_func_getsockname_arg2 in 'struct sockaddr *' 'void *'; do for ac_cv_func_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do - AC_TRY_COMPILE(dnl -[#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -extern getsockname (int, $ac_cv_func_getsockname_arg2, $ac_cv_func_getsockname_socklen_type *);],,dnl + AC_TRY_COMPILE( + [AC_LANG_PROGRAM([ + #ifdef HAVE_SYS_TYPES_H + #include + #endif + #ifdef HAVE_SYS_SOCKET_H + #include + #endif + ], [ + extern getsockname (int, $ac_cv_func_getsockname_arg2, $ac_cv_func_getsockname_socklen_type *); + ])], , [ac_not_found=no ; break 2], ac_not_found=yes) done done