[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug-gnulib] Re: getopt depending on gettext
From: |
Bruno Haible |
Subject: |
[bug-gnulib] Re: getopt depending on gettext |
Date: |
Tue, 31 May 2005 18:49:09 +0200 |
User-agent: |
KMail/1.5 |
Werner LEMBERG wrote:
> > E.g., you could do this:
> >
> > #if ENABLE_NLS
> > # include "gettext.h"
> > # define _(msgid) gettext (msgid)
> > #else
> > # define _(msgid) msgid
> > #endif
> ...
> I really prefer a `real' fix, this is, adding the above code to the
> affected source files. For me, it looks `more right'.
The starting point of gnulib was actually a world of source files containing
multiline idioms for this and that. Like the 60-line pattern for the stat
macros, the 20-line pattern for alloca(), the 8-line pattern for _(),
the 3-line pattern for EXIT_FAILURE, etc. And every time one such pattern
changed, every occurrence had to be changed.
One of the points of gnulib is that all these idioms are reduced to a
single #include line, that 1. normally doesn't change. 2. The guy who
maintains the include file and the guy who uses it are often different. This
reduces the amount of territorial conflicts, compared to the old technique
where the first guy had to submit a patch to the second guy.
I'm not in favour of reintroducing these multiline idioms.
Bruno