autoconf-patches
[Top][All Lists]
Advanced

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

Re: proposed Autoconf patch to help fix gettext compatibility problem


From: Paul Eggert
Subject: Re: proposed Autoconf patch to help fix gettext compatibility problem
Date: Mon, 12 Nov 2001 10:51:44 -0800 (PST)

> From: Akim Demaille <address@hidden>
> Date: 12 Nov 2001 11:30:25 +0100
> 
> | I had a problem when compiling a test version of Bash.  It uses
> | gettext, and the problem was that gettext headers contained code like this:
> | 
> | #ifndef PARAMS
> | # if __STDC__ || defined __cplusplus
> | #  define PARAMS(args) args
> | # else
> | #  define PARAMS(args) ()
> | # endif
> | #endif
> | 
> | and this doesn't work as desired on Solaris, where __STDC__ is 0.
> 
> Why not.

Since __STDC__ is 0, and __cplusplus is not defined, PARAMS(args) is
defined to be ().  But on 64-bit Solaris, Bash relies on the
prototypes automatically converting arguments from narrower types to
wider ones.  It's OK for Bash to rely on this, since the unprototyped
code is meant to be run only on 32-bit hosts anyway.  However, it does
mean that PARAMS must be defined properly on non-32-bit hosts.

> Actually Gettext could AC_SUBST the result itself

I'm not sure what you're referring to.  Gettext can't AC_SUBST
__STDC__, since the Solaris system headers rely on __STDC__ being zero
(in the usual case, anyway).

Perhaps you mean that Gettext could AC_SUBST PARAMS?  I guess that
should work.  But then shouldn't this be done by AC_C_PROTOTYPES?
Lots of other programs have this problem; it's not just
Gettext-related programs.

> Please, install!

Done.



reply via email to

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