From: Tilghman Lesher Date: Mon, 28 Feb 2011 11:07:52 +0000 (+0000) Subject: Clarify meaning, removing double negative (stupid!) X-Git-Tag: 1.6.2.19-rc1~3^2~101 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6579261f5cb7b0525f08a8f52f6201c869a07687;p=thirdparty%2Fasterisk.git Clarify meaning, removing double negative (stupid!) git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.2@309034 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/configure b/configure index 4e928057f1..aa7d3ffcf8 100755 --- a/configure +++ b/configure @@ -1,5 +1,5 @@ #! /bin/sh -# From configure.ac Revision: 304465 . +# From configure.ac Revision: 309033 . # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.65 for asterisk 1.6.2. # @@ -7803,9 +7803,9 @@ __EOL__ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_BISON2" >&5 $as_echo "$ac_cv_path_BISON2" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for flex that does not ignore fwrite return value" >&5 -$as_echo_n "checking for flex that does not ignore fwrite return value... " >&6; } -if test "${ac_cv_path_FLEX+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for flex that ignores fwrite return value" >&5 +$as_echo_n "checking for flex that ignores fwrite return value... " >&6; } +if test "${ac_cv_FLEX_WORKAROUND+set}" = set; then : $as_echo_n "(cached) " >&6 else @@ -7824,24 +7824,31 @@ else (umask 077 && mkdir "$tmp") } || exit $? cat >$tmp/test.fl <<__EOL__ +%{ #include #include +static void yyunput (int c,char *buf_ptr ) __attribute__((unused)); +static int input(void) __attribute__((unused)); +%} + %% - username printf( "%s", getlogin() ); +username printf( "%s", getlogin() ); __EOL__ ${FLEX} -o ${tmp}/test.c ${tmp}/test.fl - ${CC} -o ${tmp}/test.o ${tmp}/test.c -Wall -Werror >/dev/null 2>&1 - if test -e "${tmp}/test.o"; then :; else - need_flex_fwrite_workaround=1 + ${CC} -o ${tmp}/test.o -c ${tmp}/test.c -Wall -Werror >/dev/null 2>&1 + if test -e "${tmp}/test.o"; then + ac_cv_FLEX_WORKAROUND=no + else + ac_cv_FLEX_WORKAROUND=yes fi rm -rf ${tmp} fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FLEX" >&5 -$as_echo "$ac_cv_path_FLEX" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_FLEX_WORKAROUND" >&5 +$as_echo "$ac_cv_FLEX_WORKAROUND" >&6; } -if test "x${need_flex_fwrite_workaround}" = "x1"; then +if test "x${ac_cv_FLEX_WORKAROUND}" = "xyes"; then $as_echo "#define NEED_FLEX_FWRITE_WORKAROUND 1" >>confdefs.h diff --git a/configure.ac b/configure.ac index a88b60911b..9ff9512b72 100644 --- a/configure.ac +++ b/configure.ac @@ -245,7 +245,7 @@ __EOL__ rm -rf ${tmp} fi ]) -AC_CACHE_CHECK([for flex that does not ignore fwrite return value], [ac_cv_path_FLEX], [ +AC_CACHE_CHECK([for flex that ignores fwrite return value], [ac_cv_FLEX_WORKAROUND], [ if test "x$FLEX" != "x:" ; then # Create a temporary directory $tmp in $TMPDIR (default /tmp). # Use mktemp if possible; otherwise fall back on mkdir, @@ -261,21 +261,28 @@ AC_CACHE_CHECK([for flex that does not ignore fwrite return value], [ac_cv_path_ (umask 077 && mkdir "$tmp") } || exit $? cat >$tmp/test.fl <<__EOL__ +%{ #include #include +static void yyunput (int c,char *buf_ptr ) __attribute__((unused)); +static int input(void) __attribute__((unused)); +%} + %% - username printf( "%s", getlogin() ); +username printf( "%s", getlogin() ); __EOL__ ${FLEX} -o ${tmp}/test.c ${tmp}/test.fl - ${CC} -o ${tmp}/test.o ${tmp}/test.c -Wall -Werror >/dev/null 2>&1 - if test -e "${tmp}/test.o"; then :; else - need_flex_fwrite_workaround=1 + ${CC} -o ${tmp}/test.o -c ${tmp}/test.c -Wall -Werror >/dev/null 2>&1 + if test -e "${tmp}/test.o"; then + ac_cv_FLEX_WORKAROUND=no + else + ac_cv_FLEX_WORKAROUND=yes fi rm -rf ${tmp} fi ]) -if test "x${need_flex_fwrite_workaround}" = "x1"; then +if test "x${ac_cv_FLEX_WORKAROUND}" = "xyes"; then AC_DEFINE([NEED_FLEX_FWRITE_WORKAROUND], 1, [Define to 1 if your system has a version of flex that does not check the return value of fwrite.]) fi