mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-15 15:23:02 +00:00
* bootstrap: Get runtime translations into runtime-po.
Create runtime-po files automatically, if possible. * configure.ac: Invoke BISON_I18N, so that we eat our own dog food. * data/yacc.c: Rewrite inclusion of <libintl.h> so that ENABLE_NLS does not infringe on the user's name space. (YYENABLE_NLS): Renamed from ENABLE_BISON_NLS. * doc/bison.texinfo (Internationalization): Revamp the English and Texinfo syntax a bit, to try to make it clearer. (Bison Options, Option Cross Key): Mention --print-localedir. * m4/bison-i18n.m4 (BISON_I18N): Rename ENABLE_BISON_NLS to YYENABLE_NLS. Quote a bit more. * runtime-po/.cvsignore: New file. * runtime-po/Makefile.in.in (mostlyclean): Remove *.old.pot. * runtime-po/Rules-quot: Remove; now created by bootstrap. * runtime-po/quot.sed: Likewise. * runtime-po/boldquot.sed: Likewise. * runtime-po/en@quot.header: Likewise. * runtime-po/en@boldquot.header: Likewise. * runtime-po/insert-header.sin: Likewise. * runtime-po/remove-potcdate.sin: Likewise. * runtime-po/Makevars: Likewise. * runtime-po/LINGUAS: Likewise. * runtime-po/de.po: Likewise; we will rely on the translation project to maintain this, so "bootstrap" should get it. * src/getarg.s (PRINT_LOCALEDIR_OPTION): Let the C compiler determine its value. * src/main.c (main): Bind the bison-runtime domain, too. * data/yacc.c: Include <libintl.h> when NLS is enabled. (YYI18N): Renamed from _. Use dgettext when NLS is enabled. * po/POTFILES.in: Remove autogenerated file src/parse-gram.c. * runtime-po: New directory. * runtime-po/Makefile.in.in: New file, copied from po/, with modified $(DOMAIN).pot-update rule, so that old messages are never dropped. * runtime-po/Rules-quot: New file, copied from po/. * runtime-po/quot.sed: Likewise. * runtime-po/boldquot.sed: Likewise. * runtime-po/en@quot.header: Likewise. * runtime-po/en@boldquot.header: Likewise. * runtime-po/insert-header.sin: Likewise. * runtime-po/remove-potcdate.sin: Likewise. * runtime-po/Makevars: New file. * runtime-po/POTFILES.in: New file. * runtime-po/LINGUAS: New file. * runtime-po/bison-runtime.pot: New file. * runtime-po/de.po: New file. * m4/bison.m4: New file. * Makefile.am (SUBDIRS): Add runtime-po. (aclocaldir, aclocal_DATA): New variables. * configure.ac: Add AC_CONFIG_FILES of runtime-po/Makefile.in. Define aclocaldir. * src/getargs.c (usage): Document --print-localedir option. (PRINT_LOCALEDIR_OPTION): New enum item. (long_options): Add --print-localedir option. (getargs): Handle --print-localedir option. * doc/bison.texinfo (Bison Parser): Remove paragraph about _(). (Internationalization): New section.
This commit is contained in:
22
bootstrap
22
bootstrap
@@ -170,7 +170,18 @@ case $SKIP_PO in
|
||||
wget -nv -nd -r -l 1 -A .po -C off \
|
||||
http://www.iro.umontreal.ca/translation/maint/$package/ &&
|
||||
ls *.po | sed 's/\.po$//' >LINGUAS
|
||||
) || exit;;
|
||||
) || exit
|
||||
|
||||
case $package in
|
||||
bison)
|
||||
echo "$0: getting translations into po (please ignore the robots.txt ERROR 404)..."
|
||||
(cd runtime-po &&
|
||||
rm -f dummy `ls | sed -n '/\.gmo$/p; /\.po$/p'` &&
|
||||
wget -nv -nd -r -l 1 -A .po -C off \
|
||||
http://www.iro.umontreal.ca/translation/maint/$package-runtime/ &&
|
||||
ls *.po | sed 's/\.po$//' >LINGUAS
|
||||
) || exit
|
||||
esac;;
|
||||
esac
|
||||
|
||||
|
||||
@@ -231,6 +242,15 @@ rm -fr $intl_files_to_remove || exit
|
||||
echo "$0: sed '/^MSGID_BUGS_ADDRESS *=/s/=.*/= bug-bison@gnu.org/' po/Makevars.template >po/Makevars ..."
|
||||
sed '/^MSGID_BUGS_ADDRESS *=/s/=.*/= bug-bison@gnu.org/' po/Makevars.template >po/Makevars
|
||||
|
||||
# Likewise for runtime-po/Makevars, except also change a few other parameters.
|
||||
sed '
|
||||
s/^\(DOMAIN\) *=.*/\1 = bison-runtime/
|
||||
s/^\(subdir\) *=.*/\1 = runtime-po/
|
||||
s/^\(XGETTEXT_OPTIONS\) *=.*/\1 = --keyword=YYI18N/
|
||||
' <po/Makevars >runtime-po/Makevars
|
||||
|
||||
# Copy identical files from po to runtime-po.
|
||||
(cd po && cp -p *-quot *.header *.sed *.sin ../runtime-po)
|
||||
|
||||
# if src/parse-gram.[ch] are out of date, rebuild them.
|
||||
parse_gram_y=`find src/parse-gram.y \
|
||||
|
||||
Reference in New Issue
Block a user