examples: bistromathic: demonstrate internationalization

Currently it was only using stubs.  Let's actually translate the
strings using gettext.

* examples/c/bistromathic/local.mk: Define LOCALEDIR, BISON_LOCALEDIR
and link with libintl.
* examples/c/bistromathic/parse.y: Use them.
Remove useless includes.
Take ENABLE_NLS into account.
(error_format_string): New.
(yyreport_syntax_error): Rewrite to rely on a format string, which is
more appropriate for internationalization.
* examples/c/bistromathic/Makefile: We no longer use Flex.
We need readline and intl.

* doc/bison.texi: Point to bistromathic for a better option for
internationalization.
* po/POTFILES.in: Add bistromathic.
This commit is contained in:
Akim Demaille
2020-04-19 09:13:47 +02:00
parent 401e7c5c36
commit b42702d738
7 changed files with 122 additions and 41 deletions

View File

@@ -1,3 +1,4 @@
examples/c/bistromathic/parse.y
src/complain.c
src/conflicts.c
src/files.c