bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Bug in __GNU_GETTEXT_SUPPORTED_REVISION macro definition in gettext.m4


From: Martin Jacobs
Subject: Bug in __GNU_GETTEXT_SUPPORTED_REVISION macro definition in gettext.m4
Date: Sat, 16 Jan 2010 17:57:58 +0100 (MET)

Hi,

file m4/gettext.m4 defines

#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
#endif
changequote(,)dnl
typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
changequote([,])dnl

This makes test compilation fail on systems that are lacking
__GNU_GETTEXT_SUPPORTED_REVISION in libintl.h because test
code calls this macro with argument value 0 which is expanded
to 0 and makes array declaration fail with negative array
dimension.

Changing that macro definition to

#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 1 : -1)

makes configure and compilation happy and work fine.

Martin





reply via email to

[Prev in Thread] Current Thread [Next in Thread]