source: trunk/third/xml-i18n-tools/README @ 15545

Revision 15545, 1.9 KB checked in by ghudson, 24 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r15544, which included commits to RCS files with non-trunk default branches.
Line 
1How to use
2----------
3
4xml-i18n-tools has a script xml-i18n-toolize which copies the various
5scripts and does the other magic to your module, so users building
6from tarballs don't need xml-i18n-tools, only folks building from cvs.
7(This is modeled on gettextize.)
8
9xml-i18n-tools simple to use. To use it for your module you just do
10the following:
11
12  o Install xml-i18n-tools, and make sure that the macro it installs is
13    in aclocal's path, or do:
14
15        export ACLOCAL_FLAGS='-I /usr/local/share/aclocal'
16
17 o  Add these lines to autogen.sh, after the call to gettextize:
18  
19        echo "Running xml-i18n-toolize... Ignore non-fatal messages."
20        xml-i18n-toolize --copy --force --automake
21
22 o  Add this line to configure.in near the top
23 
24        AM_PROG_XML_I18N_TOOLS
25
26 o  Add xml-i18n-extract, xml-i18n-merge and xml-i18n-update to
27    EXTRA_DIST in your top-level Makefile.am and also to the top-level
28    .cvsignore.
29 
30 o  Add the .xml and .glade files you want translated to POTFILES.in
31 
32At this point, strings marked translatable will be automatically
33extracted to the .po files.
34
35To get oaf translation extraction and merging requires a few more steps:
36
37 o Rename your .oafinfo file to .oaf.in and put an underscore before
38   every value property for string attributes that should be
39   localized.
40
41 o Add the .oaf.in files to POTFILES.in
42
43 o Put lines like these in every Makefile.am that installs oafinfo
44   files:
45 
46        --- start ----
47 
48        oafdir = $(datadir)/oaf
49 
50        oaf_in_files = My_OAF_info_file.oaf.in
51        oaf_DATA = $(oaf_in_files:.oaf.in=.oaf)
52 
53        @XML_I18N_MERGE_OAF_RULE@
54 
55        EXTRA_DIST=$(oaf_in_files) $(oaf_DATA)
56 
57        --- end ----
58 
59At this point, your oaf translations will be extracted and
60merged. Also, so long as you are renaming the .oafinfo files to
61.oaf.in, you should take the opportunity to rename them to the new base
62naming convention, with namespacing, for example:
63
64        nautilus.oafinfo --> Nautilus_shell.oaf.in
65        nautilus-rpm-view.oafinfo --> Nautilus_View_rpm.oaf.in
Note: See TracBrowser for help on using the repository browser.