From: Bruno Haible Date: Mon, 27 Nov 2006 13:53:12 +0000 (+0000) Subject: Avoid using variable-size arrays if gcc doesn't provide them. X-Git-Tag: v0.17~624 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6d25c98cd7064a8992d1a77713e7bf18e9be915f;p=thirdparty%2Fgettext.git Avoid using variable-size arrays if gcc doesn't provide them. --- diff --git a/gnulib-local/ChangeLog b/gnulib-local/ChangeLog index 43014c99e..1473d392c 100644 --- a/gnulib-local/ChangeLog +++ b/gnulib-local/ChangeLog @@ -1,3 +1,9 @@ +2006-11-27 Paul Eggert + Bruno Haible + + * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0 + if compiling with "gcc -ansi". + 2006-11-26 Bruno Haible Build the imported libraries with a C compiler, even when CC=g++. diff --git a/gnulib-local/lib/gettext.h b/gnulib-local/lib/gettext.h index 352827417..94c76d024 100644 --- a/gnulib-local/lib/gettext.h +++ b/gnulib-local/lib/gettext.h @@ -170,7 +170,8 @@ npgettext_aux (const char *domain, #include #define _LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS \ - (__GNUC__ >= 3 || __GNUG__ >= 2 /* || __STDC_VERSION__ >= 199901L */ ) + (((__GNUC__ >= 3 || __GNUG__ >= 2) && !__STRICT_ANSI__) \ + /* || __STDC_VERSION__ >= 199901L */ ) #if !_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS #include