[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Fwd: Re: Broken Windows build.

From: Erik Huelsmann <e.huelsmann_at_gmx.net>
Date: 2004-04-16 22:00:37 CEST

> Nicolás Lichtmaier <nick@reloco.com.ar> writes:
>
> > Doing that would be wrong. The _() macro is used to mark string
> > literal so that xgettext can detect them and put them in the .pot
> > file. When you can't use _() on a literal you use N_() and a direct
> > gettext invocation. The right thing here is to #define gettext(x) (x)
> > is !ENABLE_NLS.
>
> I plead Ignorance! I was misinformed!

I plead guilty on all accounts.

Although I was actually waiting for Nicolas to react on my questions
concerning gettext vs dgettext, I think I'd like to know if the following
patch breaks the Windows build again, since its the minimal patch I'd have
to apply to resolve the issue raised by Nicolas.

bye,

Erik.

Log:
[[[
Revert 9375 and 9380; add missing gettext no-op macro to windows build.

]]]

Index: subversion/libsvn_subr/opt.c
===================================================================
--- subversion/libsvn_subr/opt.c (revision 9390)
+++ subversion/libsvn_subr/opt.c (working copy)
@@ -135,7 +135,7 @@
       const apr_getopt_option_t *option;
       svn_boolean_t have_options = FALSE;
  
- fprintf (stream, ": %s", _(cmd->help));
+ fprintf (stream, ": %s", gettext (cmd->help));
  
       /* Loop over all valid option codes attached to the subcommand */
       for (i = 0; i < SVN_OPT_MAX_OPTIONS; i++)
@@ -221,7 +221,7 @@
     opts = apr_pstrcat (pool, opts, " arg", NULL);
  
   if (doc)
- opts = apr_psprintf (pool, "%-24s : %s", opts, _(opt->description));
+ opts = apr_psprintf (pool, "%-24s : %s", opts, gettext
(opt->description));
   *string = opts;
 }
Index: subversion/clients/cmdline/help-cmd.c
===================================================================
--- subversion/clients/cmdline/help-cmd.c (revision 9390)
+++ subversion/clients/cmdline/help-cmd.c (working copy)
@@ -78,10 +78,10 @@
                                opt_state ? opt_state->version : FALSE,
                                opt_state ? opt_state->quiet : FALSE,
                                ra_desc_all->data,
- _(svn_cl__help_header),
+ gettext (svn_cl__help_header),
                                svn_cl__cmd_table,
                                svn_cl__options,
- _(svn_cl__help_footer),
+ gettext (svn_cl__help_footer),
                                pool));
  
   return SVN_NO_ERROR;
Index: svn_private_config.hw
===================================================================
--- svn_private_config.hw (revision 9390)
+++ svn_private_config.hw (working copy)
@@ -51,5 +51,6 @@
 /* Until Win32 gets gettext functionality, leave these disabled. */
 #define N_(x) (x)
 #define _(x) (x)
+#define gettext(x) (x)
  
 #endif /* CONFIG_HW */

-- 
NEU : GMX Internet.FreeDSL
Ab sofort DSL-Tarif ohne Grundgebühr: http://www.gmx.net/info
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Apr 16 22:01:30 2004

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.