[Top] [Contents] [Index] [ ? ]

GNU gettext��������������

1. ������������������  
2. PO����������PO������������  
3. ����������������������  
4. ������PO��������������  
5. ������PO��������������  
6. MO��������������  
7. ������������������  
8. ����������������������  
9. ������������������  
10. ����������������������  
11. ����  

A. ����������  ISO 639����������

 -- The Detailed Node Listing ---

������������������

1.1 GNU gettext������  
1.2 ������, ������, ����������������������  
1.3 ������������������������������������  
1.4 ��������������������  
1.5 GNU gettext������  

PO����������PO������������

2.1 GNU gettext������������������������  
2.2 PO����������������������  
2.3 PO����������������������  
2.4 ��������������  
2.5 ��������������������������  

����������������������

3.1 gettext������������������  
3.2 ����������������������������  
3.3 ��������������������������  
3.4 ����������������������������������  
3.5 ��������������������  

������PO��������������

4.1 xgettext����������������  
4.2 C������������  
4.3 ������������������  

������PO��������������

5.1 msgmerge����������������  
5.2 ����������������  
5.3 ������������������  
5.4 ��������������  
5.5 ������������  
5.6 ����������  
5.7 ��������������  
5.8 ����PO��������������������  

MO��������������

6.1 msgfmt����������������  
6.2 GNU MO����������������������  

������������������

7.1 ������`ABOUT-NLS'��  
7.2 ��������������������  
7.3 ��������������������  

����������������������

8.1 catgets��������  
8.2 gettext��������  
8.3 ����������������������������  
8.4 ������������������libintl.a������  
8.5 Being a gettext grok  
8.6 ������������������������������������  

catgets ��������

8.1.1 ����������������  catgets������������������
8.1.2 catgets����������������������������������?!  

gettext ��������

8.2.1 ����������������  
8.2.2 ������������  
8.2.3 ��������������������������������  
8.2.4 gettext��������������  

����������������������������������

8.6.1 ������������ - ����������  
8.6.2 ������������ - catgets��������  
8.6.3 ������������ - ��������������������  
8.6.4 ������������ - ������  

������������������

9.1 ������������������0  
9.2 ������������������1  
9.3 ����  
9.4 ����  
9.5 ����������  

������

9.4.1 ��������������  
9.4.2 ����������  
9.4.3 ����������������  

National Teams

9.4.2.1 ��������������  
9.4.2.2 ��������������������  

����������������������

10.1 ��������������������������������������������  
10.2 ����������������  
10.3 gettextize����������������  
10.4 ����������������������������������������  

������������������������������������

10.4.1 `po/'������`POTFILES.in'  
10.4.2 ����������������������`configure.in'  
10.4.3 ����������������������`aclocal.m4'  
10.4.4 ����������������������`acconfig.h'  
10.4.5 ����������������������`Makefile.in'  
10.4.6 `src/'������`Makefile.in'  

����

11.1 GNU gettext������  
11.2 ��������  


1. ������������������

������������������������������������������������������������������ �������������������������������������������������������������������������� (������������������������)������������������������������������������������ ������

���������������������������������������������������������������� �������������������������������������������������������������� ������������������������������������������������������������������ ���������������������������������������������������������������� ������������������������������������������������������������������������ ��������������������������������GNU gettext�������������������� ��������������������������������������������������������������������

���������� GNU gettext���������������������������������� (Translation Project)�������������������������������������������������� ����������������(Native Language)�������������������������������������� ����������������������(����������������������������������)�������������� ������������������������������������������������������������������������ ������������������������������������������������������������������������ ������������������������������������������

��������������������������������������������

 
Internet address:
    bug-gnu-utils@prep.ai.mit.edu

����������������������������������������������������������������

1.1 GNU gettext������  
1.2 ������, ������, ����������������������  
1.3 ������������������������������������  
1.4 ��������������������  
1.5 GNU gettext������  


1.1 GNU gettext������

�������������������������������������������������������������������������� �������������������������������������������� GNU ������������������������ �������������������������������������������������������������������������� (common language)����������(developer)������������(maintainer)������������ ���������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������������(The Translation Project)������������������������������������������������������ ������������������������(multi-lingual set)��������������������������������

GNU gettext�������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������GNU gettext��������������������GNU������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������������ GNU Emacs����������������������������������������

GNU gettext���������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������

������������������������������������������������������������������GNU gettext���������������������������������������������� gettext������������������������������������������������������������ �������������������������������������������������������������������������� ������������������������������GNU gettext�������������������������� ������������������������������������������������������������������ ������������������������������������������������������������������ ��������������������


1.2 ������, ������, ����������������������

������������������������������������������������������������������������ ������������������������������������������internationalization�� localization���������������������������������������������������� ������������������������������������������������������������������������ ������������������������������������������������������������������������ ����������������������������������������������������i18n�� l10n ������������������������������������������������������������ ��������������������������������������������������...

������(internationalization)���������������������������������������� ���������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������ ������������������������������������������������ �������������������������������������������������������������������������� ��������������gettext���������������������������������������� See section 8. ���������������������� ��

������(localization)���������������������������������������������� ������������������������������(����������������)�������������������������� �������������������������������������������������������������������������� ����������������������(cultual habits)������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ���� ��������(locale)���������������������������������������������� ���������������������������������������������������������������������������� ��������������������������������������������

�������������������������������������������������������������������������� ��������������������(cultural data)�������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������ (complete suite)������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������� ��������NLS�������������������������������������������������������������� ������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������


1.3 ������������������������������������

�������������������������������������������������������������������������� ������������������������������

�������������������������������������������������������������������������� ����������������������GNU gettext���������������������������������� �������������������������������������������������������������������������� ������(cultual conventions)���������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������ ��������������������������������������(native attributes)���������������� ��������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������GNU gettext�������������������������������������������� ��������������������

������������������

�������������������������������������������������������������������� ASCII��������������������������������ASCII�������������������������������� ����������������������������������������������������8��������ISO 8859-1������������������������������������������������������������������ ������������������������������������������������ISO 8859-1���������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������(character handling routines)��������������������������

����

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������

����������

������������������������������������������������������1994���������������� ��������12/25/94��������������������������������25/12/94������������������ ������������������ISO 8061��������������������������������������������

������hh:mm��hh.mm������������������������������ ������������ / ����������������������24������������������������������������ ����������������������������������������������������������������������������

����

�������������������������������������������������������������������������� ����������������������������������������������������

 
12,345.67       ������
12.345,67       ��������
1,2345.67       ������

����������������������������������������������������������������(English units)�������������������������������������������������������������������� ��������������������������������

����������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������GNU gettext��������������������

������������������������������������������������������������������������ ������������������������������������������������������������������������ ������������������������������������������������������������������������ ������������������������������������������������������������������GNU libc��Linux���������������������������������������������������� ������������������������������������������������������������������


1.4 ��������������������

`.po'������������PO��������Portable Object���������������������� `.mo'������������������������������������MO������Machine Object�� ��������������������������PO������������������������������Uniforum�������� ����NLS������������Solaris��������Sun������������������������������

PO������������������������������������������������������������������������ �������������������������������������������������������������������������� ��������������������������������PO���������������������������������������� ����������������������������������������������������������������������PO���� ������������������������PO����������xgettext���������������������� ��������������������������msgmerge�������������������������������� xgettext������������C���������������������������������������������� ����������������������������������������PO���������������������� msgmerge��������������PO������������������������������������������ �������������������������������������������������������������������������� ������������������������������������`.pot'������������������PO������ ����������������������������������������������������`.pox'������������ ������������������������������PO��������������������������

MO������������������������������������������������������������������������ �������������������������������������������������������������������������� ����������������MO����������������������������������������������������MO���� ���������������������������������������������������������������������������� ��������������������������������������������������`.mo'�������������� �������������������������������������������������������������������������� ������������������������������������������������������GNU gettext�� ������������������������������������������������������������������������ MO�������������������������������������������������������������������������� ���������������������������������������������������������������������� GNU gettext����������������������MO��������������������������MO���� ������������������������������`.gmo'�������������������������������� ��MO������������������������������GNU������������������������������������ ��������


1.5 GNU gettext������

����������������������GNU gettext���������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������

 
������������C������ ---> PO������ ---> ������������C������ ---.
                                                              |
              .---------<--- GNU gettext����������            |
.--- make <---+                                               |
|             `---------<--------------------+----------------'
|                                            |
|   .-----<--- PACKAGE.pot <--- xgettext <---'   .---<----- ����PO 
|   |                                            |             ^
|   |                                            `---.         |
|   `---.                                            +---> PO������ ----.
|       +----> msgmerge -------> LANG.pox --->-------'                  |
|   .---'                                                               |
|   |                                                                   |
|   `-------------<---------------.                                     |
|                                 +--- LANG.po <--- ������LANG.pox <----'
|   .--- LANG.gmo <--- msgfmt <---'
|   |
|   `---> install ---> /.../LANG/PACKAGE.mo ---.
|                                              +---> "����������������!"
`-------> install ---> /.../bin/PROGRAM -------'

`PO������'������������������������������PO���������������������������� ����������������������������������������������������GNU Emacs������������ ������������PO������������������������������������������������������PO���� ������������������������PO��������������������������PO��������PO���������� ����������������C�������������������������������������������������������� PO��������(auxiliary PO file)������PO��������(compendium PO file)�������� �������������������������������������������������������������������������� ��������������������������������PO���������������������������������������� ��PO������������������������������������������������������������

����������������GNU gettext����������������������C���������������� �������������������������������������������������������������������������� ����������������������Emacs��PO������������������������������������������ ��������������������C���������������������������������������������������� ������������(translation library)���������������������������������������� ������������������������������������������ @xref{sources}������������������

�������������������������������������������������������������������������� ������������������������������������������������������gettext������ �������������������������������������������������������������������������� ��������������������������������������

 
#define _(String) (String)
#define N_(String) (String)
#define textdomain(Domain)
#define bindtextdomain(Package, Directory)

��������������������������������������������gettext���������������� ������������������������������������������������������`libintl.h'�� ����������������`libintl.a'���������������������������������������� ������������

C������������������xgettext���������������������������������������� ����������������������������PO���������������������������� `package.pot'�������������������������������������������������� ����������������������������������C�������������������������������������� ����������������������������������������������������������`.pot'�� t������������������PO���������������������������������������������� ������������������������������������������������(xgettext���������� ����������������������������������See section 4.1 xgettext����������������)������������ ������������������������������������������������������������������ �������������������������������������������������������������� (see section 10. ����������������������)��������������������������make���������������� ����������������������������������������������gettext�������������� ��������������������������!

������������������`lang.po'������������������������ msgmerge���������������������������������� `package.pot'��`lang.pox'���������������������������� ������������lang������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����(see section 9. ������������������)������������������������������������������������ �������������������������������������������������������������������������� ����������������������������������������������������������������������������

����������������PO��������`lang.pox'�������������������������� ������GNU Emacs��������������������������������������������PO�������������� ����������������������(quoting conventions)(see section 2.2 PO����������������������)������������ �������������������������������������������������������������������� Uniforum��Solaris������������PO������������������������������������������ ����GNU Emacs��PO������������������������PO������������������������������ ������������(Emacs��)����������������������������������PO���������������� ������������������������������������PO��������������(see section 2.3 PO����������������������)��������������������������������(see section 2.4 ��������������)���� ��������������������(see section 5.4 ��������������)������������������������ ����������

������������������(common translations)����������PO��������(compendium PO file)������������������������������������PO���������������������������� �������������������������������������������������������������������������� ����������������������������(see section 4.3 ������������������)�������������������������� ������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������������������

���������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������(������������������������������������)���������������������� �������������������������������������������������������������������������� ��������������������xgettext��������`package.pot'������ ����������������������`lang.po'�������������������������������� ������������������������������������

���������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������(��������������)������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������

msgmerge��������������������xgettext������������������C���� ����������������������������������������������`package.pot'���� ����������������������������`lang.po'���������������������������� ��������������C���������������������������������������������������������� ������������������������������������������������������������ msgmerge��`lang.pox'������������������������������������ �������������������������������������������������������������������������� ����������������������(see section 5.5 ������������)�������������������������� ������������������������������������PO������������������������������������ ����(see section 5.4 ��������������)��msgmerge���������������������� ��������������See section 5.1 msgmerge������������������

������������������������������������������������������(������������������) `lang.pox'���������������������������������������������������� ����`lang.pox'��������`lang.po'�������������������� ��������������������

PO��������������������(temporal mobility)������������(time fluidity)���� ������������������������������������������������������������������������ ������������������������������������������������������������������������ ��(participants)����������������������������������������! �������������� ������������������������������������������������PO���������������������� ������������������������������������������������������������������������ ������������������������������������������������������������������������ ������������������������������������������������������������������������ ������������������������������������������������(pretest)�������������� ������������PO��������������������������

PO������������������������������������������������������������������������ PO�������������������������������������������������������������������������� ������������������������msgfmt��������������������(see section 6.2 GNU MO����������������������)��msgfmt�������������������������������������������� See section 6.1 msgfmt����������������������������������

��������������������������������C��������������������������������GNU gettext������������������������������������������������������������ ������������������`Makefile'��������make���������������������� �������������������������������������������������������������������������� ������������������MO������������������������������������������������������ ��������������������������������(see section 7.3 ��������������������)���������������������� ������������������������������������������

������������������������������������������������������������������������ ����������������������������


2. PO����������PO������������

GNU gettext����������������������������������������(������������ ��������������)PO������������������������������������������������������ ����������������������������������������������������PO������������������ PO��������������(PO mode starter)��������������������PO������������������ ������������������������������������������������������������������������ ��PO������������������������������������

2.1 GNU gettext������������������������  
2.2 PO����������������������  
2.3 PO����������������������  ��������������
2.4 ��������������  
2.5 ��������������������������  


2.1 GNU gettext������������������������

GNU gettext�������������������������������������������������������� ������������`make install'����������������������xgettext�� msgfmt��gettext��msgmerge���������������������������� ���������������������������������������������������������������������������� ������������������������������������������������������GNU Emacs���������� ��PO������������������������������������������

PO��������������������������������������`.emacs'�������������������� ������������������������������

 
(setq auto-mode-alist
      (cons '("\\.po[tx]?\\'\\|\\.po\\." . po-mode) auto-mode-alist))
(autoload 'po-mode "po-mode")

������������`.po'����������`.pot'����������`.pox'���������� ��������`.po.'������������������������������������������������������ ������������Emacs��`po-mode.elc'(��������`po-mode.el')���������� ��������������������������`.po'�������������������������������������� PO����������������������������������PO�������������������������������������� PO������������������������������������������������Emacs������������ ������������PO������������������������������������������������������������ ������

������������������������Emacs��������������20�������������������������� ������������������������������������������������������������������������ ��������������������������������������������Emacs���������������������� ��������������������������������������`.emacs'������������������ ����������������

 
(autoload 'po-find-file-coding-system "po-mode")
(modify-coding-system-alist 'file "\\.po[tx]?\\'\\|\\.po\\."
                            'po-find-file-coding-system)


2.2 PO����������������������

PO������������������������������������������������������������������������ ��������������������������������������������������������������������PO���� �������������������������������������������������������������������������� ����������������(��������)��������������������������PO�������������������� ��������������������������

 
white-space
#  translator-comments
#. automatic-comments
#: reference...
#, flag...
msgid untranslated-string
msgstr translated-string

PO������������������������������������������������������������������������ ��������PO������������������������PO���������������������������������������� �������������������������������������������������������������������������� ����������������������

������������������(����������)������������������������GNU gettext���� ���������������������������������������������������������������������������� ��������#���������������������������������������������������������� ������������#������������������������������������������������������ ����������������������������������������������������������������#�� ������������������������������������������������������GNU gettext���� �������������������������������������������������������������������������� ����������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������msgid�������������������������������� ����������������msgstr������������������������������������(������ /������)��PO������������"��\���������������������������������� PO������������������������������������������������������������������������ ����������������������������

msgid����������������������������������������GNU gettext���� ��������������������������������������������������PO��������msgid�� ����/��������������������������������������������(������)���������������� �������������������������������������������������������������������������� ����������msgstr�������������������������������������������������� ��������������������������(������)������������������������PO�������������� ��������������

����������������������������������������������������������������#,�� ����������������������������������flag������������������������ ���� ������������������������������������������������������msgfmt������ ��������������������������������������������������������������������

����(fuzzy)
������������msgmerge���������������������������������������������� ����������������������������������������msgstr�������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������� ������������������������msgmerge��������������������(fuzzy search)������msgid��msgstr�������������������������������� ����������See section 5.3 ��������������������

c-format
no-c-format
������������������������������������������������������xgettext���� ������������������������������������������������������PO������������������ ������������xgettext���������������������������������������������� ����������������������������������������������

c-format��������������������������������msgfmt�������������� ����������������������������������������������������See section 6.1 msgfmt������������������

������������������������PO������������������������������������������������ ��������������������������������������������������PO���������������������� ����������������������������������PO������������M-x po-normalize������������������������������������������������������������ ������������See section 2.5 ��������������������������.

������������������������������PO������������������������������������������ ����������������������PO������������������������������������������������������ �������������������������������������������������������������������������� ��������GNU Emacs����������������������������������������������������

untranslated-string��translated-string���������������������� ��(����������)������������������������������������������������������������ ������������������C������������������������������������������������������ ���������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������

 
msgid ""
"Here is an example of how one might continue a very long string\n"
"for the common case the string represents multi-line output.\n"

(����: ��������������������������������������������������������������������������)

������������`Here'������������H��`for'��f���������� ������������������������������������������������������������msgid�� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������msgid������������������������ �������������������������������������������������������������������������� ��������������������������`Here'��������������msgid���������� ��������������������(1)������������ ������������������������`\n'������������������������������������������ �������������������������������������������������������������������������� ����������������������������������

����������������������������������������������������`\n'������ �������������������������������������������������������������������������� PO������������������������������������������������������������������������

�������������������������������������������������������������������������� ������`#'������������������������������������������������������������ ��������������������������#���������������������������������������������� ����������������������������������������������������������GNU������������ ������������������������������������������������������PO���������� msgmerge���������������������������������������������������������� ��������������������������


2.3 PO����������������������

2.1 GNU gettext����������������������������������������Emacs��������������������Emacs��PO������ ����������������������������������������PO���������������������������������� ����������������������������po-mode-map���������������� po-mode-hook������������������������������������������������������

PO����������������������������������������������������`PO'���������� ��������������������������������������������������������������PO���������� �������������������������������������������������������� `132t+3f+10u+2o'������������������������������������PO����������132�� ������������(see section 5.2 ����������������)��������3������������������ (see section 5.3 ������������������)��������10����������������(see section 5.4 ��������������������)��2����������������������(see section 5.5 ������������)�������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������`145t'������������������ ��������

����PO�������������������������������������������������������������������� ����PO��������������������������������������������������������������������

U
PO������������������������������������������

Q
��������������PO����������������������

q
��������������������������������������������

O
PO������������������������������������������

?
h
PO����������������������������������

=
PO������������������������������������

V
PO������������������������������������������������

U(po-undo)����������GNU Emacs��undo�������������������� ��������������See section `Undoing Changes' in The Emacs Editor. U����������������������������PO������������������������������������ ������������������������������PO������������������������������������������ ����������������������RET������������������������������������ ������������������������������������������������������������������ RET���������������������������������������������������������� ����������������������������������������������������������������������������

Q��������(po-quit)��q�������� (po-confirm-and-quit)������������PO�������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������PO������������������������������������ ��������������������������������������������������PO���������������������� ������������������������������������������Emacs ��PO���������������������� ��������������������������������������������C-x k (kill-buffer)������������������������������������

O(po-other-window)������������PO���������������������������� ����������������������(����������������)������������������������������ Emacs�������������������������������������������������������������������� ����������������������������PO�������������������������������������������� �������������������������������������������������������������������������� ������������������������������������(����������������������������)�������� �������������������������������������������������������������������������� ������PO������������������������������Emacs������������������������������ ������������������������PO��������������������

h��������(po-help)����������������������PO�������������������� ����������������������������������������������������������������������PO ����������������������������������?����������h������������������ ����

=��������(po-statistics)��PO�������������������������������� ������������������(1��������������������)�������������������������������� ������������������������������������������������������

V��������(po-validate) ����������PO���������������� msgfmt������������(verbose mode)���������������������������������� ������PO����������������������������������������������GNU gettext�� msgfmt��������MO����������PO�������������������������������������� ����������������PO���������������������������������������������������������� ����������PO����������������������������������������������������������

msgfmt������������Emacs��������������������������������������PO���� ��������������������������������������GNU Emacs��`*compilation*'���� ����������������������������������������������������GNU Emacs�������� C-x`(next-error)����������������������������������������PO���� �������������������������������������������������������������������������� ����������������������������������������������������������������PO�������� ������������������������������


2.4 ��������������

PO������������������������������������������������������������������������ ��������������������������������������������������������PO���������������� ��������������������������������PO���������������������������������������� ����������������PO�������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������

������������PO������������������������������������������������������������ �������������������������������������������������������������������������� ����������������������

.
������������������������������

n
n
������������������������������������������

p
p
������������������������������������������

<
PO������������������������������������������

>
PO��������������������������������������

m
������������������������������������������������������������

l
��������������������������������

x
����������������������������������������������������������������

��������GNU Emacs����������PO�������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������������ PO������������������������������������������������������������������������ ������������������������������������������GNU Emacs��������������.�� ������(po-current-entry)�������������������������������������� Emacs�������������������������������������������������������������������� ��������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ����������������������Emacs���������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������PO������������������������ �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ������������������������������������������������������������ ������������������������������������������������������������������������ ��������������

n(po-next-entry)����������p (po-previous-entry)������������������������������������������������ ��������������������������n������������������������������������������ p��������������������������������������������������������������������

<(po-first-entry)��>(po-last-entry)������������ ������������������������PO������������������������������������������������ ����������������PO������������������������������������������������PO������ ����������`After last entry'������������������������������������ <��>������������PO������������������������������������������ �������������������������������������������������������������������������� ��������������������������������������������PO���������������������������� ����������������PO��������������������������������PO���������������������� ����������������������������See section 3.3 ��������������������������.

�������������������������������������������������������������������������� ��������������������PO���������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� Emacs����������������������������������������location ring���������������� ������

PO������������������������������������������������������������������������ ������������������m��������(po-push-location)���������������� �������������������������������������������������������������������������� ������������r��������(po-pop-location)���������������������� �������������������������������������������������������������������������� ����������������������������������������������������������r�������� �������������������������������������������������������������������������� ����������

�������������������������������������������������������������������������� ���������������������������������������������������������������������������� ��������������r��������m�������������������������������������� ������������������������

x(po-exchange-location)���������������������������������������� �������������������������������������������������������������������� (reposition)�������������������������������������������������������������� ������������������������������x������������������������������������ �������������������������������������������������������������������������� ��������������������������m���������������������������������������� ����������������������������������������x������������


2.5 ��������������������������

PO������������������������������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������PO�������������� ��������������������������PO������������msgid������������������������ ������������������������������PO������������������������������������������ ��������������������PO���������������������������������������������������� �������������������������������������������������������������������������� ����������������������������(canonical)������������������������������

PO������������������������(conventional)���������������������������������� ������������PO������������������������������������������������������������ ����������������������������xgettext��PO�������������������������� ������������GNU gettext��xgettext����������������PO�������� ����������������������������������������������������������������PO�������� ������������������������������������������PO������������������������������ ������������������������������������������������������������

PO������������������������������������������������������������������������ ������������PO����������������������������

M-x po-normalize
PO������������������������������������������������������������������

������������M-x po-normalize(������������������������������������)�� �������������������������������������������������������������������������� ������������PO������������������������������������������������������������ �������������������������������������������������������������������������� ����PO�������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������PO�������������������������������������� ����PO������������������������������������������������������������������

M-x po-normalize���������������������������������������������������� ��GNU gettext 0.6����������������������PO���������������������������� ��������msgid��msgstr����������������������������K&R������ ����C�������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������PO���������������������� �������������������������������������������������������������� msgid�� msgstr������������������������������������������ XView�� msgfmt���������������������������������������������������� ��������������������������

����������������������PO������������������������������������������������������ ������������������������������������������������������������������������ ������������������������������������������������������������������������ ���������� GNU gettext������������������������������������������ ��������������������������������������������������������������GNU Emacs ������������������������PO������������������������������������������������

PO������������������������������������������������������ `[^\n]\n+[^\n]'���������������������������������������������� ����������������������������������������������������������

 
msgstr "\n\nHello, world!\n\n\n"

��������������������������������������������������������

 
msgstr ""
"\n"
"\n"
"Hello,\n"
"world!\n"
"\n"
"\n"

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������������(������ n > 1����������������n - 1 ������������������������������ ��������)����������������������������������������

 
msgstr "\n\n"
"Hello,\n"
"world!\n"
"\n\n"

������������������������������������������������������������������������ ��������������������������������������������������������


3. ����������������������

C������������������������������3������������������������������������������ �������������������������������������������������������������������������� ����������������������������������GNU gettext�������������������� ����������������������main������������������������������������������������ ������������������������������������������������

��������������������������������������������GNU gettext������������ ������������������������������������`Makefile'���������������������� (see section 10. ����������������������) ��������������������������������C������������������ ��������������������������������

 
#include <libintl.h>

C������������������������������������������������������������������������ ��������������

3.1 gettext������������������  
3.2 ����������������������������  
3.3 ��������������������������  
3.4 ����������������������������������  
3.5 ��������������������  


3.1 gettext������������������

�������������������������������������������������������������������������� ������������������������

 
int
main (argc, argv)
     int argc;
     char argv;
{
  ...
  setlocale (LC_ALL, "");
  bindtextdomain (PACKAGE, LOCALEDIR);
  textdomain (PACKAGE);
  ...
}

PACKAGE��LOCALEDIR��������`config.h'����Makefile���� ��������������������������������������������������������gettext�� ������������������������

LC_ALL������������������������������������LC_ALL�������������� ����������������LC_CTYPE����������������LC_CTYPE���� `ctype.h'��������������isalnum�������������������������������� �������������������������������������������������������������������������� ��������������������������������������c + (����: ���������� ��������������������������)���������������������������������������������� ������������������������������������

������������������������LC_ALL�������������������������������������� scanf������������������������������������������������������������ "C"���������������������������������������������������������������� ����������������������������������������������"C"�������������������� ������������������������������������������������������������"C"������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������"C"�������������������� ����������������������'.'������������������������������������������ ��������������

��������������������������������������LC_ALL������ setlocale����������������������������������������������

 
{
  ...
  setlocale (LC_TIME, "");
  setlocale (LC_MESSAGES, "");
  ...
}

������������������������POSIX��������������������LC_CTYPE�� LC_COLLATE��LC_MONETARY��LC_NUMERIC�������� LC_TIME������������������������������������������������������������ ����������XPG2��������������������LC_RESPONSES���������������� LC_MESSAGES����������������������������


3.2 ����������������������������

C��������������������������������������������������(marking)���������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������������(marking keyword)������������������������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������`%s'�������������������������� ������������������������������������������������������������������������ `error_string_out()'������������������������������������������������ ����������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������See section 3.5 ��������������������������������������

������������������������������xgettext���������������������������� ��������������������������������������PO���������������������������������� ����������������������

����������������������������������������������������������`gettext' ������������GNU gettext�������������������������������������������� `gettext'���������������������������������������������������������� ��������������������������gettext���������������������������������� ������������������������������������������������������������������������ ������������������������������������������������������������������������ ������������������������������������������������������������������������ ������������������������������������������������������������������������ 79������80�������������������������������������������������������������� ��������������

��������������������������������������`_'(��������������������)������ ��������`gettext("Translatable string")'���������� `_("Translatable string")'������������������������GNU���������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������������GNU gettext�������������������������������������������������������������� ��������������������������������������`gettext'���������� `gettext'����������`_'������������������������������������������ ��������������������������

 
#include <libintl.h>
#define _(String) gettext (String)

������`#include <libintl.h>'����������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������`_()'������������������`"%s: %d"'�������� ����������������������������


3.3 ��������������������������

PO������������������������������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������PO�������������� ������������������������������PO������������������������������������������ �������������������������������������������������������������������������� ������������������������������������������������������������

��������������PO������������������������������������������������������������ ��������������������Emacs������������������������������������������������ �������������������������������������������������������������������������� ��������������������������������������

 
etags src/*.[hc] lib/*.[hc]

��������`src/'��`lib/'�������������������������������� `.h'��`.c'������������������������������������������������������ ����������������������������������������������������������`TAGS'���� ������������������������������Emacs���������������������������������������� ������������������������������

GNU���������������������������������������������������������������������� ������������������������������(tags��TAGS)������������������ ��������������������������������

`TAGS'�������������������������������������������������������������� �������������������������������������������������������������������������� ����������������PO�������������������������������������������������������� ��PO���������������������������������������������������������������������� �������������������������������������������������������������������������� PO������������������������������������������������������������������������ ��������������������������������PO����������������������������������������

,
��������������������������������������������������������������������

M-,
������������������������`_()'��������������������

M-.
�������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������

,(po-tags-search)�������������������������������������������� ������������������������Emacs�������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������PO�������������������������������������������������� ��������������������������������������������������M-,��M-.������ ������������������������������������������������������������,������ ������������������������������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ��������������������������������PO����������������������������(����)������ ��������������������������������������������������

��������Emacs������������`TAGS'���������������������������������������� ������������������������������������������������������������������ `TAGS'��������������������������������Emacs��M-x visit-tags-table����������������������������`TAGS'���������������� ������������������������@xref{Tags, , Tag Tables, The Emacs Editor}.

,������������������������������������������������������������������ ����������`TAGS'���������������������������������������������������� ��������������������������������(C-u ,)������������������������ �������������������������������������������������������������������������� (��������������)����������������������������������������������������

,����������������������������������Emacs���������������������������� ����������������������������������������tags-search�� tags-query-replace��������������������,���������������������� ���������������������������������������������������������������� ,��������(�������� ����������������,��������)���������������� ��������������������������Emacs������������������������������������������ ����������������������������������������������������������������

M-,(po-mark-translatable)������������������������������������ ��`_'������������������������������M-. (po-select-mark-and-mark)������������������������������������������ �������������������������������������������������������������������������� ������������������������������������������PO������������������������������ ����������������������(�������������������������������������������������� ����������������������������������)��M-,��M-.�������������� ����������������������80�������������������������������������������������� ������������������������������������������������������������PO���������� O��������������������GNU Emacs�������������������������������������� �������������������������������������������������������������������������� ��������������������������������������M-,����������������������PO���� ������������������������������������������Emacs�������������������������� ��������

M-.���������������������������������������������������������������� ���������������������������������������������������������������������������� ������������������������������������������������������������������ ��������RET���������������������������������������������������� �������������������������������������������������������������������������� ������������������������PO mode������������������������������������ ������������������������������������������������������������������

������������������������������?������������������������������������ �������������������������������������������������������������������������� ������������������(C-u M-.)��������������������PO�������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ��������������������������������M-.���������������������������������� ������������������������������������������������������������������ ����C-u M-.���������������������������������������������������� ��������������������������������������������������

M-.�������������������������������������������������������������� ,�������������������������������������������������������������������� ����������������������������������������������������������������������PO���� �������������������������������������������������������������������������� ��������������PO���������������������������������������������������������� ������������������������������������������������(q������������������ ������)��������������������������������PO����������Emacs������������������ ��������������������`gettext'��`_'������������������������������ `gettext'��M-.������������������������������������`_'���� ������������������������������������M-,���������������������������� ������������������������


3.4 ����������������������������������

C��������������������������������printf���������������������������� ������������������������������������(format strings)������������%�� ��������������������������(format specifiers)���������������������������� ������������������������������������������������������������

 
printf (gettext ("String `%s' has %d characters\n"), s, strlen (s));

����������������������������������������������������������������

 
"%d Zeichen lang ist die Zeichenkette `%s'"

��������������������������������������C���������������������������������� ������������������������������������������������������������������������ printf������������������������������������������������������������ ����������������������������������������������������������������������������

����������������������������������������������������msgfmt�������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������

�������������������������������������������������������������������������� ������

 
"%2$d Zeichen lang ist die Zeichenkette `%1$s'"

msgfmt����������������������������������������

�������������������������������������������������������������������� `.po'������������������������������������������������msgfmt�� ��������������������������printf���������������������������������� �������������������������������������������������������������������������� ����������������������������

��������xgettext�������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������`.po'���������������������������� c-format������#,������������������������������(see section 2.2 PO����������������������)��

�������������������������������������������������������������������������� ���������������������������������������������������������� xgettext���������������������������������������������������������� ����������������������gettext�������������������������������������� ����������xgettext������������xgettext:c-format�������������� �������������������������������������������������������������� c-format������������������������������������������������������������ ����������������������������������������������������xgettext������ ������������������������������������������������������������������������ gettext������������������������������������������������������������ ����������������������������������������������

����������������������������printf�������������������������������� ������������������������������������������������������fputs�������� ����������������������������������������xgettext�������������������� �������������������������������������������������������������������������� ��������������������������������printf���������������������������� �������������������������������������������������������������������������� ����������������������

��������xgettext���������������������������������������������������� �������������������������������������������������������������������������� ������������������������msgfmt��������������������`.po'������ �������������������������������������������������������������������������� ����������������������������������xgettext:no-c-format�������������� ����������������������������������������

c-format�������������������������������������������������������������� ������������������������������������������������������������ See section 4.1 xgettext������������������������������--debug�������������������� ����������������������������������������


3.5 ��������������������

����������������������gettext�������������������������������������� �������������������������������������������������������������������������� ��������������������������������

 
{
  static const char *messages[] = {
    "some very meaningful message",
    "and another one"
  };
  const char *string;
  ...
  string
    = index > 1 ? "a default message" : messages[index];

  fputs (string);
  ...
}

"a default message"������������������������������������������������ ����messages������������������������������������������������������ ��������������������������? ���������������������������������������������� ��������������xgettext����������(see section 4.1 xgettext����������������)������ �������������������������������������������������������������������������� ����������������������������������������������������������������������������

��������������no-op������������������������������������������������������ �������������������������������������������������������������������������� ����������������������������������������������������������������������

 
#define gettext_noop(String) (String)

{
  static const char *messages[] = {
    gettext_noop ("some very meaningful message"),
    gettext_noop ("and another one")
  };
  const char *string;
  ...
  string
    = index > 1 ? gettext ("a default message") : gettext (messages[index]);

  fputs (string);
  ...
}

fputs�������������������������������������������������������������� ��������������������������������gettext_noop��xgettext������ ��������������������4.1 xgettext������������������������������������

�������������������������������������������������������������������������� ��������

 
#define gettext_noop(String) (String)

{
  static const char *messages[] = {
    gettext_noop ("some very meaningful message",
    gettext_noop ("and another one")
  };
  const char *string;
  ...
  string
    = index > 1 ? gettext_noop ("a default message") : messages[index];

  fputs (gettext (string));
  ...
}

����������������������������������������������������������������"a default message"��������������������gettext_noop������������������ ������������������������������������������gettext������������������ ����������������������������������������������GNU gettext���������� ��������������������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������


4. ������PO��������������

4.1 xgettext����������������  
4.2 C������������  
4.3 ������������������  


4.1 xgettext����������������

 
xgettext [option] inputfile ...

`-a'
`--extract-all'
����������������������������

`-c [tag]'
`--add-comments[=tag]'
tag(����������������������������������)���������������������������� ������������������

`-C'
`--c++'
C++����������������������������

`--debug'
�������������������������������������������������������������������� c-format��������possible-c-format���������������������������� ��������������������xgettext������������������������������������������ ����������������������������������������������������������

��������������c-format�������������������������������������������� ��������������������������������

`-d name'
`--default-domain=name'
��������`messages.po'����������`name.po'����������

����������������������`-'������`/dev/stdout'����`��������' ����������������������������

`-D directory'
`--directory=directory'
����������������������������������������������directory�������������� ��������`.po'����������������������������������������������

`-f file'
`--files-from=file'
������������������������������������������������file����������������

`--force'
�������������������������������������������������������������������������� ����

`-h'
`--help'
��������������������������������

`-I list'
`--input-path=list'
��������������������������������������������������������

`-j'
`--join-existing'
����������������������������������������

`-k word'
`--keyword[=word]'
������������������������������(word���������������������������������� ������������������������������������)��

���������������������������������������� gettext��dgettext��dcgettext��gettext_noop�� ����������������������������������

`-m [string]'
`--msgstr-prefix[=string]'
msgstr������������������������string��""��������������

`-M [string]'
`--msgstr-suffix[=string]'
msgstr������������������������string��""��������������

`--no-location'
`#: filename:line'������������������������

`-n'
`--add-location'
`#: filename:line'��������������������(����������)��

`--omit-header'
`msgid ""'������������������������������������

.gmo�������������������������������������������������������������� ����������������������������������GNU gettext���������������������� msgfmt��������������������������������������������������

`-p dir'
`--output-dir=dir'
dir������������������������������������������

`-s'
`--sort-output'
������������������������������������������������������

`--strict'
Uniforum������PO����������������������������������������������������

`-v'
`--version'
������������������������������������

`-x file'
`--exclude-file=file'
file������������������������������

������PO����������������������`/usr/local/share/nls/src/'������������

inputfile������`-'����������������������������������������������

xgettext��������������������������������������������ANSI���������� �������������������������������������������������������������������������� ��������������������������������������


4.2 C������������

PO����������GNU gettext������������������������������PO������������ ������������������������GNU gettext������������������������PO������ ����������������������������������������������������������������PO�������� ��������������������������������������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ����C�������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������������(�������� ������������������������)������������������������������������������������ ����������������������������������������������������������������������

����������������������������PO�������������������������������������������� ����������������������������������������������

s
������������������������(��������)������������

M-s
����������������������������������������������������������������������

S
��������������������������������������������������������

M-S
����������������������������������������������������������

��������s(po-cycle-reference)���������� M-s(po-select-source-reference)������������������������������������ ���������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������

s(����M-s)������������������������������������������PO������ �������������������������������������������������������������������������� ��������������������������������������������������������������O���� ��������������������������

������s������������������������������������������������������������ ����������������������������PO�������������������������������������������� s��������������������������������������������������������PO�������� �������������������������������������������������������������������������� ����������������s�������������������������������������������������� �������������������������������������������������������������������������� ��s���������������������������������������������������������������� ��������������������s���������������������������������������������� ����������������������PO�������������������������������������������������� ������������������������������������

��������M-s�������������������������������������������������������� �������������������������������������������������������������������������� ������������������������(completion)���������������������������������� M-s��������TAB����������������������������(������������������ ����)�������������������������������������������������������������������� ������������������������������������������������������������������������

��������������������������������PO������������������������������������������ �������������������������������������������������������������������������� PO������������������������������������������������������������������PO���� ����������������������2���������������������������������������������������� PO������������������������������������������������������������������������ ������������������������������������������������������������������������ PO����������������������������������PO������������������������������������ �������������������������������������������������������������������������� ���������������������������������������� S(po-consider-source-path)������������������������������������ ������������������������������������������������M-S (po-ignore-source-path)�������������������������������������������� ��������������������������������������������(��������������)��


4.3 ������������������

����������������������������������

PO������������������������������������������������������������������������ �������������������������������������������������������������������� ������������PO������������������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������� See section 2.5 ����������������������������


5. ������PO��������������

5.1 msgmerge����������������  
5.2 ����������������  
5.3 ������������������  
5.4 ��������������  
5.5 ������������  
5.6 ����������  
5.7 ��������������  
5.8 ����PO��������������������  


5.1 msgmerge����������������


5.2 ����������������

����������PO��������������������������msgstr���������������������� ����(see section 5.3 ������������������)���������������������������������������������� ������������������������������������������������������GNU msgfmt������������������������������������������������������������ �������������������������������������������������������������������������� ����������������

��������������������������������������������������������������������

t
������������������������������

M-t
������������������������������

��������t(po-next-translated-entry)��M-t (po-previous-transted-entry)�������������������������������������� ������������������������������PO������������������������������������������ ����

������������������������������������������������������������ 5.6 ���������������������������� po-auto-fuzzy-on-edit��nil���������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������� See section 5.3 ��������������������


5.3 ������������������

����������PO�������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������ �������������������������������������������������������������������������� ��������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ����msgid������PO����������������msgid���������������������� �������������������������������������������������������������������������� ��������������������������msgmerge�������������������������� msgmerge������������������PO�������������������������������������� PO������������������������������������������������������������������������ ����(msgid������������)�������������������������������������������� ����������������������������������������������������msgmerge������ ������������������������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������

f
������������������������������

M-f
������������������������������

TAB
������������������������������������

��������f(po-next-fuzzy) ��M-f (po-previous-fuzzy)������������������������������������������������ ��������������������PO����������������������������������������������

��������TAB(po-unfuzzy)�������������������������������������� ��������������������������������������po-auto-select-on-unfuzzy�� nil������������TAB������������������������������������������ ����������������������po-auto-select-on-unfuzzy���������� nil������

po-auto-fuzzy-on-edit����������nil������������������ po-auto-select-on-unfuzzy��t�������������������� RET�� �������������������������������������������������������������������������� ����������������������������������������(������������������)�������������� �������������������������������������������������������������������������� ��������������������������������������������������TAB�������������� �������������������������������������������������������������������������� ��������������������������������������������������������������SPC�� ��������������

�������������������������������������������������������������������������� ��������������������������������������������DEL�������� (po-fade-out-entry)����������������������

��������q����������������PO���������������������������������������� ������������������������������������PO������������������������������������ ����������������������


5.4 ��������������

xgettext��������PO������������������������msgid������������ ����������������msgstr�������������������������������������������� �������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������PO��������������������������������������������������������

�������������������������������������������������������������������������� ��������������������������������������������������������`msgstr ""'��������������������������������������������������������

�������������������������������������������������������������������������� ��������������������������������������������(������������)���������������� ������������������������������������������������������������������

u
����������������������������������

M-u
��������������������������������������

k
��������������������������������������

u(po-next-untranslated-entry)����������M-u (po-previous-untransted-entry)������������������������������������ ��������������������������������������������������������������������PO���� ������������������������������������

�������������������������������������������������������������������������� ����������������������k��������(po-kill-msgstr)������������ See section 5.6 ����������.

q������������������PO���������������������������������������������� ������������������������PO������������������������������������������������ ����������


5.5 ������������

������������������������������������������������������������������������ msgmerge���������������������������������������������������������� ��������������������������������������������

�������������������������������������������������������������������������� ����������������������������������������������������msgid���� msgstr����������������#�������������������������������������� ��������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������

������������������������������������������������������������

o
������������������������������

M-o
��������������������������������

DEL
����������������������������������������������������������������������������

o(po-next-obsolete-entry)����������M-o (po-previous-obsolete-entry) �������������������������������������� �������������������������������������������������������������������������� PO����������������������������������������������

PO������������������������������������������������������������������������ ���������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������msgid����������������������������������������

�������������������������������������������������������������������������� ������������������������������������GNU gettext���������������������� ��������������������������������������������������������������DEL�� ������(po-fade-out-entry) ���������������������������������������� ��������������������������������������������������(����������������)������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������PO����������������������������������������������PO���������������� (��������������)���������������������������������������������������������� ����See section 5.6 ����������.

��������������������������PO���������������������������������������������� ������������������������������������������������PO�������������������������� ����������������������������������������������������PO�������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����PO��������������������������������������������������������PO���������� ���������������������������������������������������������������������������� ������������������������������


5.6 ����������

PO������������PO����������������������Emacs������������������������������ �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ������������������������������������������������������������������ V������������������������������������������������������������������ �������������������������������������������������������������������������� ����(������������������������)������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������

RET
��������������������������

LFD
��������������������������������������������������������

k
����������������������������������������������������

w
����������������������������������������������������

y
��������������������������������������������������������

RET(po-edit-msgstr)������������������PO���������������������� ����������������������������������������Emacs������������������������������ ����������������������������������GNU Emacs������������������������������ ������������������������������(����������������)�������������������������� �������������������������������������������������������������������������� ������������������������������������������������Emacs��������M-C-c (exit-recursive-edit)������������PO�������������������������������� ����������������������������������������������������������C-c C-c������������M-C-c��������������������������������������������

����������������������������������������������RET������������������ �������������������������������������������������������������������������� Emacs��������������C-](abort-recursive-edit)���������������� ��������������������������C-c C-k��C-]�������������������� ��������������������������������������������C-c C-c������������ ����U����������������������������������������������������������

po-subedit-mode-hook������������������������������������������������ �������������������������������������������������������������������������� ������

���������������������������������������������������������������� RET(����)���������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� RET����������<������������������������������������������ ��������������<������������������������������C-c C-c������ ����������������������������������PO����������������(������������) <������������������������������������������<������������������ ����������<����������������������������<���������������������� ������������������������<������������������������������������������ ������������������������������������������������������������������ ����������������������������������������������������������������<�� ��������������������������<���������������������������������������� ��������������<��������������������������������������������������

����������(����������������)����������������������������������������PO���� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������PO������������������������������������������������������������ ������������������������������������������������������������PO������������ �������������������������������������������������������������������������� ����������������������������������

LFD(po-msgid-to-msgstr) ������������������������������������ ���������������������������������������������������������������������������� ������������������������������������������������������������������

����������������������������������������LFD������������������������ ����������������������������������po-auto-edit-with-msgid�� t�������������������������������������������������������������������� ������������������po-auto-edit-with-msgid����������nil������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������������������

��������k(po-kill-msgstr)������������������������������������ �������������������������������������������������������������������������� ���������������������������������������������������������������������� w(po-kill-ring-save-msgstr)���������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������ ��������������������������������������������GNU Emacs�������������������� ��������������������������

��������������������������������������������������������k������ w�������������������������������������������������������������������� ��Emacs������������������������������������������������������������PO���� �������������������������������������������������������������������������� ��������������������������������������PO���������������������������������� ��������������������������������

PO������������������������������������������������������������������ k������������������������������������������������������������������ �������������������������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� ������

��������y(po-yank-msgstr)������������������������������������ ������������������������������������GNU Emacs���������������������������� ��������PO����������������������������������������See section `Yanking' in The Emacs Editor��������y���������������������������������� ���������������������������������������������������� y�������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������y���������������������������������������� �������������������������������������������������������������������������� ��������������������

PO����������������������������������������������������PO�������������������� �������������������������������������������������������������������������� ������������������������PO�������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������

k������w������������������������������������������������������ ������������������������������������(��������������������)���������������� ������PO������������������������������������������������������������������ ��������������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������������ PO������������������������������������������������������������������������ �������������������������������������������������������������������������� ����������������������msgstr���������������������������������������� �������������������������������������������������������������������������� ��������

�������������������������������������������������������������������������� ��������������������������������������������������m���������������� ��������������������������������������������������o���������������� ��������������������������������������������������������DEL�� �������������������������������������������������������������������������� ������r��������������������������������������������y���������� ������������msgstr������������������������������������ RET����������������������������������������u�������� m����������������������������������������������

�������������������������������������������������������������������������� ��������������������������������Emacs������������������������������������ ����������������������������See section `Keyboard Macros' in The Emacs Editor��


5.7 ��������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������PO������ ����������������������������������������������������������PO�������������� ������������������������������������

������`#'��������������������������������������`#.'��`#:'�� ��������������������������������������������������gettext���� �������������������������������������������������������������������������� ��������������������������������������������������������������See section 2.2 PO������������������������

�������������������������������������������������������������������������� ��������������������See section 5.6 ����������

#
������������������������������������

K
��������������������������������������������������

W
��������������������������������������������������������

Y
����������������������������������������������������������

��������������������������������������������PO���������������������������� ����������������������������������������������������������������PO�������� �������������������������������������������������������������������������� ������������������������������������������������������See section 5.6 ����������

#(po-edit-comment)������������������PO���������������������� ����������������������������������Emacs���������������������������������� ������������������PO������������������������������������������������������ ��������������������������������������������������������������(#)�� �������������������������������������������������������������������������� ��������������������������������������������������������(uncommenting)���� ����������(recommenting)�������������������������������������������������� ��C-c C-c����������������������������������������������

po-subedit-mode-hook���������������������������������������������� ����������������������������������������������������������������������

K(po-kill-comment)������������������������������������������ ������������������������������W(po-kill-ring-save-comment)�� �������������������������������������������������������������������������� ��������������������������M-Y(po-yank-comment)�������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������������

�������������������������������������������������������������� �������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����#������M-w������������������������������������������������ ������������������������

�������������������������������������������������������������������������� ������������������������������������������������������#������������ ������������������������������������������������������������GNU Emacs���� ������������C-y(yank)������������������������������������ M-y(yank-pop)����������������������


5.8 ����PO��������������������

PO������������������������������������������������������������������������ �������������������������������������������������������������������������� ��������PO���������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������������������

����PO�������������������������������������������������������������� ������������������������������������������PO������������������PO���������� �������������������������������������������������������������������������� ����������������������

PO������������������������������������������������������������������������ ����

a
����������������������������������������������������������

M-a
����������PO��������������������������

A
PO����������������������������������������

M-A
��������PO����������������������������������������������

��������A(po-consider-as-auxiliary)������������ M-A(po-ignore-as-auxiliary������������������������������PO���� ������������������������������������������

��������a(po-cycle-auxiliary)������������������������ msgid����������������������������������������������������PO�������� ����������������������������PO������������������������������������������ PO��������������(������������������)�������������������������������������� ������������������������PO������������������������������������������������ ��������PO����������a����������������������PO���������������������� ������������������������������a��������������PO������������yield back��������������������

��������M-a(po-select-auxiliary)���������������������������� ������������������������������������PO������������������������������������ ������������������������������������������������msgid���������������� �������������������������������������������������������������������������� ����������������������������������������������������

����������������������������������PO�������������������������� msgid������������������������������������������������������ ��������������msgid������������������������������������������������ ��������������������PO���������������������������������������������������� ������������������������������PO��������������GNU gettext���������� ����������������msgid���������������������������������������������� ����������������������������

����������������������������������������������������������PO�������������� ��������PO��������������������������������������������������`M-x normalize'����������������������PO��������������PO����������������GNU gettext������������������������������������������������������������ ��������������������������������������������


6. MO��������������

6.1 msgfmt����������������  
6.2 GNU MO����������������������  


6.1 msgfmt����������������

 
Usage: msgfmt [option] filename.po ...

`-a number'
`--alignment=number'
����������������������number������(��������������1)����������

`-h'
`--help'
��������������������������������

`-I list'
`--input-path=list'
��������������������������������������������������������

`--no-hash'
����������������������������������������������������������

`-o file'
`--output-file=file'
������������������������file����������

`--strict'
Uniforum/Sun�������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������ Uniforum������������������������������������������������������������������ ��������`.mo'����������������

������Sun�������������������������������������������������������� ������������������������������������������������������������������

`-v'
`--verbose'
������������������������������������������������������������������ msgid��msgstr���������������������������������������������� �������������������������������������������������������������������������� ��������������������������������

����������������printf�������������������������������������������� ��������������������������������������������������������`%'���������� ����������������������������c-format������ possible-c-format����������������#,�������������������������� ����������������������������������������������������������`%.*s'���� ����`%s'����`%d'��������`%s'��`%d'�������� `%x'�� ������������������������������������(positional parameter)���������������� ������

������xgettext���������������������������������������������������� �������������������������������������������������������������������� printf������������������������������������������������������������ ����������������������������������msgfmt���������������������������� ������������������������������printf������������������������������ ������������������������������������������������������������

������������������������������������xgettext���������������������� ���������������������������������� (see section 3.4 ����������������������������������)����������#,�� �������������������������������������������������������������������������� ��msgmerge��������������������������������������������

`-V'
`--version'
������������������������������������

��������������`-'������������������������������������������������ `-'������������������������������������������


6.2 GNU MO����������������������

����������MO�������������������������������������������������������������� ������������������������

������2��������������������������������������������������������GNU MO���� ��������������������������������������������MO���������������������������� ������������������������������������������������������������������ 0x950412de��0xde120495�������������������������������������� �������������������������������������������������������������������������� ������������0����������������������������������������������������MO������ �������������������������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������� `/etc/magic'�������������������������������������������������������� ����������������������������������������������������������������������������

����������������������������������������������������������MO�������������� ��������������������������������������MO���������������������������������� ���������������������������������������������������������������������������� ������������������������������������������������������

��������������������������������O������������T���������������� �������������������������������������������������������������������������� ����32�������������������������������������������������������������������� ��������MO���������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������

������������������������������������������MO�������������������������������� ����������������MO�������������������������������������������������������� �������������������������������������������������������������������������� ����GNU gettext��PO��������������������������������������MO�������� ������������������������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����

������������������������S��0���������������������������������������� ��������������MO���������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������MO�������������������������������������������������� ����������������������������������������(double hasing)�������������������� ��������������������������������������������GNU gettext������������ ����������������������������������������

���������������������������������������������������������������� NUL��������������������������NUL������������������������������ ����������������������������������������msgfmt������������MO������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����RISC��������������������������������������������������������������������

MO����������NUL������������������������������������������������������ ������������������������������������������������NUL���������������� ��������������������������NUL�������������������������������������� ����������������MO�������������������������������������������������������� ����������������������������MO������������(NUL���������������������� ��������)���������������������������������������������������������������� ������

������������������GNU gettext�������������������������������������� ������MO������������������������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����MO�������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������

 
        ������
             +------------------------------------------+
          0  | ���������������� = 0x950412de            |
             |                                          |
          4  | �������������������������������� = 0     |
             |                                          |
          8  | ����������������                         |  == N
             |                                          |
         12  | ��������������������������������������   |  == O
             |                                          |
         16  | ��������������������������������         |  == T
             |                                          |
         20  | ������������������������                 |  == S
             |                                          |
         24  | ����������������������������             |  == H
             |                                          |
             .                                          .
             .  (������������������������������������)  .
             .                                          .
             .                                          .
             |                                          |
          O  | 0������������������������������   ----------.
      O + 8  | 1������������������������������   ------------.
              ...                                    ...   | |
O + ((N-1)*8)| (N-1)������������������������������      |  | |
             |                                          |  | |
          T  | 0����������������������������  -----------------.
      T + 8  | 1����������������������������    -----------------.
              ...                                    ...   | | | |
T + ((N-1)*8)| (N-1)1����������������������������       |  | | | |
             |                                          |  | | | |
          H  | ����������������������                   |  | | | |
              ...                                    ...   | | | |
  H + S * 4  | ������������������������                 |  | | | |
             |                                          |  | | | |
             | NUL������������0������������  <-------------' | | |
             |                                          |    | | |
             | NUL������������1������������  <---------------' | |
             |                                          |      | |
              ...                                    ...       | |
             |                                          |      | |
             | NUL������������0����������      <---------------' |
             |                                          |        |
             | NUL������������1����������      <-----------------'
             |                                          |
              ...                                    ...
             |                                          |
             +------------------------------------------+


7. ������������������

GNU gettext�������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������ ������������������������������������������������������������������

���������������������������������������������������������������������� GNU gettext���������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������������������

������������������������������������������������������������������������ ������������������������������������������������������������������������ ������������������������������������������������������������������ ����������������������������������������������GNU gettext�� ����������������������������������������������������������

7.1 ������`ABOUT-NLS'��  
7.2 ��������������������  
7.3 ��������������������  


7.1 ������`ABOUT-NLS'��

GNU gettext�������������������������������������������������������� ��������������������������������������������GNU������������GNU gettext����������������������������������`NLS'���������������� ������������`ll.po'������������������������`intl/'�������� �������������������������������������������������������������������������� ����������������������������`ll.po'���������������������������� ��������ll����������������������7.3 ������������������������ll���������� ������������������������������������

������������������������������������������������������������������������ ����������������������(multilingual messages)�������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������GNU gettext����������������������������������������������GNU���������� ������������`ABOUT-NLS'�������������������������������������������� ������������������������������������������������������������ `ABOUT-NLS'���������������������������������������������������������� ������������������������������GNU�������������������������������������� ����


7.2 ��������������������

GNU gettext�������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������catgets��gettext���������������������������� ����������������������������������GNU gettext���������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������`./configure --with-included-gettext'������������������ ��catgets��gettext������������������������GNU gettext��������������`./configure --disable-nls'�������������� ������������������������������������������������������

����������������������������������������`ll.po'���������������� ���������������������������������������������������������������������������� ������������������������������������������LINGUAS������������������ �������������������������������������������������������������������������� LINGUAS������������������������������������������������������������ ��2��������������������������


7.3 ��������������������

��������GNU gettext������������������������������������������������ ����configure�������������������������������������������������������� ������������������������������������������������������������������ LANG��������`ll'������������������See section 7.1 ������`ABOUT-NLS'���������� ���������������������������������������������������������������������� `setenv LANG de'(csh������)��������`export LANG; LANG=de'(sh������)������������������������������������������ `.login'��`.profile'��������������������������


8. ����������������������

GNU gettext�������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������POSIX���������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������UNIX���������������������������������������������������������� ������X/Opens��catgets����Uniforum��gettext������������������������������ �������������������������������������������������������������������������� ����������

8.1 catgets��������  
8.2 gettext��������  
8.3 ����������������������������  
8.4 ������������������libintl.a������  
8.5 Being a gettext grok  
8.6 ������������������������������������  


8.1 catgets��������

catgets��������X/Open��X/Open Protability Guide, Volume 3, XSI Supplementary Definitions, Chapter 5. ������������������������������������ ��������������������������������UNIX�������������������������������������� �������������������������������������������������������������������������� ��catgets���������������������������������������������������������� ������������������������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������(������������������������������������...)��

��������������UNIX(tm)���������������������������������������������������� ����X/Open���������������������������������������������������������������� ������������������������������������������������������������������������ UNIX����(��������Spec1170)������������������������UNIX������(������������ ��������������������������)������������������������������

8.1.1 ����������������  catgets������������������
8.1.2 catgets����������������������������������?!  


8.1.1 ����������������

catgets������������������������������������������������������������ ������������������������������������������������������������������ catopen��������������������������������������������catgets�� ��������������������������������������������catclose�������������� ��������������������(����������������)������<nl_types.h>���������� ����������������������

catopen������������������������

 
nl_catd catd = catopen ("catalog_name", 0);

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������0������������������ ������������������������������������������������������������������������ open��������������������������������������������������

��������������������������������������catgets���������������������� ����������

 
char *translation = catgets (catd, set_no, msg_id, "original string");

����������������������������������������������������������2�������������� ������������������������������������������msg_id�������������������� ������������������catgets����������3����������������(three-stage adressing)��������������

 
���������� => ������������ => ����������ID => ����

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������catgets��������������char *������������������ �������������������������������������������������������� const char *������������������������������������ANSI C���������� 1988������������������������

��������������������������������������������������������

 
catclose (catd);

������������������������������������������catgets������������������ ��������������������������


8.1.2 catgets����������������������������������?!

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������catgests���������������������������������� ID������������������������������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ������������������������������������������������


8.2 gettext��������

gettext��������������������������Uniform�������������������������� ������������������������UNIX������(Sun)���������������������������������� ������������������������������(official standard)������������������������ ������������������

����������������������������������������������������������(�������� - ���� - ��������)�������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������(������������������ ����������)������������������������������������������������������ See section 8.3 ������������������������������

�������������������������������������������������������������������������� ����������GNU gettext���������������������������������������������� �������������������������������������������������������������������������� ����������������������������������

8.2.1 ����������������  
8.2.2 ������������  
8.2.3 ��������������������������������  
8.2.4 gettext��������������  


8.2.1 ����������������

��������������������������������������a) �������������������������� (domain)������(���������������������������������������������������������� ����������������������������������������������������������)��b) ���������� ����������������������������������������������������������

��������������gettext������������������������������������������������ �������������������������������������������������������������������������� ������������

 
char *textdomain (const char *domain_name);

����������������LC_MESSAGE������������������������������������������ ����������������������������������������������������������NUL������������ �������������������������������������������������������������������������� ����������domain_name��NULL���������������������������������� �������������������������������������������������������������������������� ��������messages����������������������textdomain������������ ��char *���������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������

textdomain��������������������������������������

 
char *gettext (const char *msgid);

�������������������������������������������������������������������������� ����������������������msgid���������������������������������������� ��������������������������������������������NULL������������������ ��������������

�������������������������������������������������������������������������� LC_MESSAGES�������������������������������������������������������� ��������gettext��������������LC_MESSAGES�������������������� ������������������������������(������)������������������������������������ ������

�������������������������������������������������������������� textdomain�������������������������������������������������������� �������������������������������������������������������������������������� ����������������������gettext�������������������������������������������� ��������������������������������������������������


8.2.2 ������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������textdomain������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������������error������ ���������������������������������������������������������������������������� ����������������������������������������

��������������������������������������������������������

 
char *dgettext (const char *domain_name, const char *msgid);
char *dcgettext (const char *domain_name, const char *msgid,
                 int category);

������������������������������������������������������������ textdomain��������������������������dcgettext�������������� LC_MESSAGES�������������������������������������������������������� ��������������������������������������domain_name��NULL������ ������category������������������������������������������������������ ������������������������������������������������(Solaris������������)���� ����������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������

 
char *bindtextdomain (const char *domain_name,
                      const char *dir_name);

�������������������������������������������������������������������������� ������������(����������������������������������������������)�������������� ������������������������������������������������������������������������ (����textdomain��������������������������)��dir_name�� NULL��������������domain_name�������������������������������� ��������domain_name����������NULL���������������������������� NULL�������������������������������������������������������������� ����������������!

dir_name�������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������chdir�������������������� �������������������������������������������������������������������������� ��������������������


8.2.3 ��������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������UNIX�������������������������������������������������� ���������������������������������������������������������� bindtextdomain����������(��������������������������������)�������� �������������������������������������������������������������������������� ����������������������

 
dir_name/locale/LC_category/domain_name.mo

dir_name��������������������������������GNU������������������GNU���� ����������������������������������������

 
/usr/local/share/locale

������

locale����LC_category���������������������������������� gettext��dgettext���������������������������� LC_MESSAGES������dcgettext���������������������������������� ��������(2)�� (3)


8.2.4 gettext��������������

������������GNU gettext�������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������

 
{
  while (...)
    {
      puts (gettext ("Hello world"));
    }
}

�������������������������������������������������������������������������� ��������������������������������������������������������������������������

 
{
  str = gettext ("Hello world");
  while (...)
    {
      puts (str);
    }
}

����������������������������������������������������������(�������������� ������������������������)��������������������������������

GNU C����������������������2.7�������������������������������������������� �������������������������������� intl/libgettext.h ���������������������� ��������������������������������(expression command block)���������������� ��������section `Statements and Declarations in Expressions' in The GNU CC Manual������������������

 
#  if defined __GNUC__ && __GNUC__ == 2 && __GNUC_MINOR__ >= 7
extern int _nl_msg_cat_cntr;
#   define	dcgettext(domainname, msgid, category)           \
  (__extension__                                                 \
   ({                                                            \
     char *result;                                               \
     if (__builtin_constant_p (msgid))                           \
       {                                                         \
         extern int _nl_msg_cat_cntr;                            \
         static char *__translation__;                           \
         static int __catalog_counter__;                         \
         if (! __translation__                                   \
             || __catalog_counter__ != _nl_msg_cat_cntr)         \
           {                                                     \
             __translation__ =                                   \
               dcgettext__ ((domainname), (msgid), (category));  \
             __catalog_counter__ = _nl_msg_cat_cntr;             \
           }                                                     \
         result = __translation__;                               \
       }                                                         \
     else                                                        \
       result = dcgettext__ ((domainname), (msgid), (category)); \
     result;                                                     \
    }))
#  endif

������������������__builtin_constant_p���������������������������� �������������������������������������������������������������� gettext������������������������������dcgettext__�������������� dcgettext��������������������������������

������������������������������������������������������������������ ���������������������������������������������������������������������� _nl_msg_cat_cntr��������`libintl.a'�������������� `loadmsgcat.c'������������������������������������������������������ ��������������������������������


8.3 ����������������������������

������������������������������������������������(a little bit colored)������ ������������������������GNU gettext��Uniforum���������������������� �������������������������������������������������������������������������� ������������������������������������������������

������������������������������������������gettext���������������� NLS���������������������������������������������������������������������� ���������������������������������������������������������������������������� "..."����������gettext("...")������������������������ ����(������������������������������)����������������������������������

 
#define gettext(String) (String)

��������������������������������C������������������gettext�������� �������������������������������������������������������������������������� ��������������������NLS������������������������������������������GNU gettext������������������������������gettext("...")���� ����_("...")�������������������������������������������������� ������������������������������������������������������������

������������������������������������

 
#define _(String) (String)

����

 
#include <libintl.h>
#define _(String) gettext (String)

������������������������������������������������������������������ `xgettext'���������������������������������������������������������� ����������������������������������������������������������������������

gettext_noop��������������������������������(see section 3.5 ��������������������)����������gettext_noop��no-op�������������������������� `libintl.h'��������������������������������Sun������ `libintl.h'���������������������������������������������������������� ������������������������������������������

 
#ifdef gettext_noop
# define N_(String) gettext_noop (String)
#else
# define N_(String) (String)
#endif

N_��_����������������������GNU gettext��`po/'���������� ������`Makefile'���������������������������������������������������� �������������������������������������������������������������������������� ������

������catgets������������������������������������������������������ ����������������������������������������������������������������������(�� ��������������������: symbolic constant)���������������������������������� ����������������������ID��������������������������������GNU gettext������������������������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������: ������������������������������

��������catgets���������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������

 
printf ("%s: %d", gettext ("number"), number_of_errors)

printf ("you should see %d %s", number_count,
        number_count == 1 ? gettext ("number") : gettext ("numbers"))

������������������"number"���������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������������"Anzahl"���� ����������������"Zahl"����������������

������������������������������(esoteric)���������������������������������� ��������! ���������������������������������������������������������������� ������������������������������������������

 
printf ("%s %d", gettext ("number:"), number_of_errors)

printf (number_count == 1 ? gettext ("you should see %d number")
                          : gettext ("you should see %d numbers"),
        number_count)

�������������������������������������������������������������������������� ���������������������������������������������������������������������������� ����������������������������������������������

������������: ������'s'�������������������������������������������������� ���������������������������������������������������������������������������� ������������������������������������������������Rafal Maszkowski <rzm@mat.uni.torun.pl>���������������������������������������������������� ������������������������������

������������������������������plik(��������)����������������������
 
1 plik
2,3,4 pliki
5-21 pliko'w
22-24 pliki
25-31 pliko'w
(o'��8859-2 oachte��������������������������������aogonek������okreska����)

����������������������������POSIX.2������������LC_TIME������������ ������������������������������������������alt_digits������1���� 100����������100���������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������

 
void
print_month_info (int month)
{
  const char *month_pos[12] =
  { N_("first"), N_("second"), N_("third"),    N_("fourth"),
    N_("fifth"), N_("sixth"),  N_("seventh"),  N_("eighth"),
    N_("ninth"), N_("tenth"),  N_("eleventh"), N_("twelfth") };
  printf (_("%s is the %s month\n"), nl_langinfo (MON_1 + month),
          _(month_pos[month]));
}

��������������������������������������������������������������������������


8.4 ������������������libintl.a������

����������0.9.4������libintl.h����������(self-contained)���������� �������������������������������������������������������������������������� ������������������������������`Makefile'������������������������ $(prefix)��������������������������������������

HP-UX��������������������������������������������������������C������������ alloca������������������������(������HP���������������������������� ��������������������)���������������������������������������������������� ������������������������������������������������������libintl.a���� ������������������������alloca��������������������������


8.5 Being a gettext grok

��������������������������GNU gettext������������������������������ ��������������������������(������������������������)���������������������� ����������������������������������������������������������������������


8.6 ������������������������������������

8.6.1 ������������ - ����������  
8.6.2 ������������ - catgets��������  
8.6.3 ������������ - ��������������������  
8.6.4 ������������ - ������  


8.6.1 ������������ - ����������

������������������������������������������������������������X/Open�� catgets����������������������������Uniforum��gettext�������� ��������catgets���������������������������������������������������� gettext������������������������������������������������������ catgets������������������������������������������������������������ gettext��������������Sun����������������������COSE���������������� ����������(COSE multivendor initiative)�������������������������������� POSIX��������������������������POSIX.1 ���������������������������������� ����������������������

��������������������POSIX��������������������gettext�� catgets(XPG)������������������������������������������������ POSIX.1 ������������������������������������������������������������������ ���������������������������������������������������������������������������� ����XPG3������������������������������������������������������������������ ����������������������"...������������������������������������������ ������������..."

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������FAQ(Programming for Internationalization FAQ)������������������


8.6.2 ������������ - catgets��������

catgets������������������������������������������������������������ �������������������������������������������������������������������������� ����������������������������������������������������������������������

catgets������������������������������������������������������������ ��������������������������������������������������������

�������������������������������������������������� ������������������ UNIX���������������������������������������� ����������UNIX���������������������������������������������������������� UNIX���������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������

��������������UNIX���������������������������������������������������� Spec1170������������������������������UNIX�������������������������������� ��������������������������UNIX���������������������������������������������� ���������������������������������������������������������������� (autoconf��������������)�������������������������������������������������� ��������������

����������������������������Spec1170��X/Open Portability Guidelines������ ������4(XPG4)��������������������catgets������������XPG4���������� ����������������catgets��Spec1170����������������������������UNIX�� ��������������������������������������������������������


8.6.3 ������������ - ��������������������

�������������������������������������������������������������������������� ��������������������������������������������catgets���������������� ���������������������������������������������������������������������� catgets��(������������������)������������������������������? ������ �������������������������������������������������������������������������� ������������������������������������������������������������������GNU���� �������������������������������������������������������������������������� ����������(catgets)��������������������?

�������������������������������������������������������������������������� ������������������������������? ����������Linux�������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������catgets�������������������������������������� glocale��������GNU libc������������������������GNU libc�������������������������������������������������������������� ��������������������������������������������? ��������glocale���� catgets������������������������������������������������������������ ��? ���������������������������������������������������������������������� ��������������������������������glocale���������������������������� ������(glocale)����������������������(��catgets������������ ����)������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������(glocale������������������������������������������ ������������������)?

UNIX���������������������������������������������������������������������� ������������������������������������������������������������


8.6.4 ������������ - ������

����������������������������������������������������X/Open���������������� ����������������������������������������������������������(����Linux catgets��Ultrix-4)������������������������������������

��������������������������GNU/Linux libc��gettext���������� ��������������������������������������������������������������Solaris�� gettext������������������������������������������������������


9. ������������������

9.1 ������������������0  
9.2 ������������������1  
9.3 ����  
9.4 ����  
9.5 ����������  


9.1 ������������������0

GNU����������������������! ������������������������������������������������ ����������������������������������GNU������������������������������������ ����������������������������

GNU gettext�������������������������������������������������������� ������������������������������������������������������������������ �������������������������������������������������������������������������� ������������

�������������������������������������������������������������������������� �������������������������������������������������������������������� (synergize)�������������������������������������������������������������� ������������������������������������������������������������������ ������������������

����������Linux International�������������������������������������������� ������`ll@li.org'����������������ll�������������������� ����ISO 639���������������������������������������������������������� ������������������������������ISO 3166�������������������������� ������������������������������������������������������������

�������������� ga�� ���������� it�� �������������� in�� �������������� eo�� ���������� nl�� ���������� el�� �������������� sv�� ���������� es�� �������� cs�� ������ zh�� ������������ da�� �������� de�� �������� tr�� ������ ja�� ������������ no�� �������������� fi�� ���������� fr�� ������������ pl�� ������������ pt�� �������� ru

��������������������������������������������`zh@li.org'������������ �������������������������������������������������������������������������� ������������������������������������������������������������������ `sv-request@li.org'��������������������

 
subscribe

�������������������������������������������������������������������������� ���������������������������������������������������������������������������� ���������������������������������������������������������� `gnu-translation@prep.ai.mit.edu'������������������������������ ��������������������������������������������

��������GNU�������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������`gnu-translation@prep.ai.mit.edu'������������ ����������������������������������������������


9.2 ������������������1

������������GNU����������������������! ������1995��1���� GNU Bulletin���� ������������������

��������GNU�������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������`gnu-translation@prep.ai.mit.edu'������������ ����������������������������������������������

�������������������������������������������������������������������������� ����������������������������������������������GNU������������������������ ������������������������������������������������������������������

������������������������������������������������������������������������ ��������������������������������GNU������������������������������������ ������������������������������������������������������������������������ ����������������������������������������������������������������

�������������������������������������������������������������������������� ����������������������������������������������GNU������������������������ �������������������������������������������������������������������������� ��������������������������������������������������GNU�������������������� ��������������

������������������������������������������������������������������������ `gnu-translation@prep.ai.mit.edu'��������������������������


9.3 ����

�������������������������������������������������������������������������� ����������������������������������������������������������������������


9.4 ����

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������Richard Stallman������������������ ���������������������������������������������������������������������������� ������������������Linux International������������������������������������ ���������������������������������������������������������������������������� ������������������!

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������(������������ ����������������������������������������������������������)�������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������

���������������������������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ���� GNU gettext�������������������������������������������������� ���������������������������������������������� `translation@iro.umontreal.ca'�������������������������������������� ���������������������������������������������������������������������������� ��������������������������������������������

9.4.1 ��������������  
9.4.2 ����������  
9.4.3 ����������������  


9.4.1 ��������������

��������������������������������������GNU�������������������������������� �������������������������������������������������������������������������� ������������GNU���������������������������������������������������������� ������������������������������������������������������ ������������������ ����������������������������`gnu.announce'������������������������

��������������������������������������Ulrich������������������������������ ���������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��(������������(����������)��������1������������������������������������) �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������


9.4.2 ����������

��������������������������������������������������/���������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������������������/�������� ����������������������������������������������������

�������������������������������������������������������������������������� ��������������������������������������������---������������������������������ �������������������������������������������������������������������������� ��������������������������������������������������������

����������������������20������30������������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������?

�������������������������������������������������������������������������� ���������������������������������������������������������������������������� ��������������PO���������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������Ulrich Drepper���������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������

���������������������������������������������������������������������������� ����������������������������������������������

9.4.2.1 ��������������  
9.4.2.2 ��������������������  


9.4.2.1 ��������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������

�������������������������������������������������������������������������� ����������������(������������������)���������������������������������� (:-)���������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������gettext���������������������������� ��������������������������������������������


9.4.2.2 ��������������������

�������������������������������������������������������������������������� GPL���������������������������������������������������������������������� ����������������������������������������������������������������2��3������ ����������������������������������������������������������������������������


9.4.3 ����������������

GNU gettext��������������������������������������������������������

 
`translation@iro.umontreal.ca'

`*-pretest'���������������������������������������������������������� ������GNU����������GNU���������������������������������������������������� ��������/����������!

François�������������������������������������������������������������� ��������������������������`gnu.ai.mit.edu'�������������������������� ���������������������������������������������������������� �������������� ��������������������������������������������������������������

��������������������! 2��3������Daniel Fekete������GNU�������������������� ����(FSF������������)���������������������������������������������������� �������������������������������������������������������������������������� ����������������majordomo������������������������������������ iro.umontreal.ca���������������������������������������������������� ��������������...

�������������������������������������������������������������������������� ������������������������������������������������������FSF������������������ �������������������������������������������������������������������������� ������������������������������������������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������ �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ������������������������������������������������


9.5 ����������

�������������������������������������������������������������������������� ���������������������������������������������������������������������������� ��������������������? ������������������1�������������������������������� �������������������������������������������������������������������������� ����������������������������������

��������������������������������������������Ulrich������������������������ �������������������������������������������������������������������� ������������������������������������������������������������������������ �������������������������������������������������������������������������� ���������������������������������������������������������������������� Ulrich(��������������������������)����������������������(Jim���������� Len������)������������������������������������������������������������

����������GNU������������������������������������������������������������ ����������������������������������������12����1������������GNU������������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������---������������������������

�������������������������������������������������������������������������� ��:- )�������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������

����������������PO�������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������GNU�������������������������������������������������������������� ����������������������������������������������������������������������


10. ����������������������

�������������������������������������������������������������������������� ������������������������������������������������������������������������ (see section 7. ������������������)������������������������������������������������������������

����������GNU gettext������������������������������������������������ �������������������������������������������������������������������������� ������GNU������������������������������Gnits������������������������������ ��������������������������������������������������������������(���������� GNU gettext��������GNU�������������������������������������������� ��������������������������������������������������������������������)���� �������������������������������������������������������������������������� ����������������`configure.in'������������������������������ Autoconf��������������������������������������

��������������GNU gettext��GNU������GNU������������������������������ �������������������������������������������������������������������������� ����������gettext���������������������������������������������������� ����������������������������������������������������������������������

������gettext��������������������������������������gettext�� �������������������������������������������������������������������������� ����������������������������������������������

10.1 ��������������������������������������������  
10.2 ����������������  
10.3 gettextize����������������  
10.4 ����������������������������������������  


10.1 ��������������������������������������������

���������������������������������������������������������������������� tar���������������������������������������������������������� ������������������������������������������������1������������������������ ����������������������`doc/'��������������������������Texinfo�������� ����man������������������`lib/'����������������������C�������������� ������������������������������������`src/'�������������������������� �������������������������������������������������������������������� ����������������������

�������������������������������������������������������������������������� ������������GNU gettext�������������������������������������������� ������������������������������PO������������������������������������������ ������������������������������������GNU gettext�������������������� `misc/'����������������`combine-sh'���������������������������� ����������������������������������`intl/'������������������C�������� ��C��������������(������`.c'����������������`.h'��������)������ �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������

����������GNU gettext���������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������������GNU gettext������������������������������������������������������������ ��������������������������������������������������������������


10.2 ����������������

������������GNU gettext�������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������������������

������������PO������������������������������������������������������������ �������������������������������������������������������������������������� ��������������������������(������������������������ `translation@iro.umontreal.ca'������������)������������������������ ����������PO�������������������������������������������������������������� ������������������������������������������������PO������������������ `po/'������������������������������

�������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ������������������������������������������������������������������ �������������������������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� ��������`ABOUT-NLS'����������������������������

��������������������������������������PO�������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ���������������������������������������������������������������������������� �������������������������������������������������������������������������� ����������������������������������������������������


10.3 gettextize����������������

GNU gettext�������������������������������������������������������� ����������������������������������������������������gettextize���� �������������������������������������������������������������������������� ��������������������

 
gettextize [ option... ] [ directory ]

��������������������������������

`-c'
`--copy'
�������������������������������������������������������������������������� ������������������������������������������������������������������ gettext������������������������������������������������������������ ������������������������������������gettextize�������������������� ������������������������������������������������������������������������

`-f'
`--force'
��������������������������������������������

`-h'
`--help'
����������������������������

`--version'
������������������������������������

directory��������������������������GNU gettext�������������� �������������������������������������������������������������������������� ������������������������������������������������������������������

gettextize����������������������������������������--force (-f)�������������������������������������������������������������� ����������������������

  1. `ABOUT-NLS'���������������������������������������������������������� �������������������������������������������������������������������������� �������������������������������������������������������������������������� ��������������gettextize����������`ABOUT-NLS'���������������� ���������������������������������������������������������������� `ABOUT-NLS'������������������GNU������������������������������������ ����������

  2. `po/'���������������������������������������������������������������� ��������������GNU gettext������������������ `po/Makefile.in.in'��������������������������������(���������������� ��.in��������������������������������)������`po/'�������������������� ������������������po�������������������������������������������������������� `Makefile.in.in'����������������������

  3. `intl/'����������������GNU gettext���������������������� `intl/'���������������������������������������������������������������� ��������������--force(-f)������������������`intl/'���� ����������������������������������������

�������������������������������������������������������� gettextize�������������������������������������������������������� �������������������������������������������������������������������������� ��������������������������������������������������tar�������������� ��������������`-h'�������������������������������������������������� ���������������������������������������������������������������������� `Makefile.in'������������tar������`-h'������������������ ��������������������������

1����������������������GNU gettext�������������������������������� ������������`intl/'�������� `po/'������������������������������ ��������������������������������������������2����������������������1������ ������`intl/'��GNU gettext������������������������������������ ��������������������������������������������������(���������������������� ����)��`po/'����������������������`po/'������������������������ ��`Makefile'������������������`po/'������������ `Makefile.in.in'��������������������`Makefile.in.in'������������ ����������������������������������������������������


10.4 ����������������������������������������

gettextize�������������������������������������������� GNU gettext������������������������������������������������������������ ��������������������Makefile���������������������������������� (auto-configuration)��GNU������������������������������������������������ �������������������������������������������������������������������������� ��������������

�������������������������������������������������������������������������� ��������������������������������������������GNU gettext 0.10������������������������������gettext���������������� ����������������������������������GNU gettext���������������������������� ��������������������������������������������������������������

10.4.1 `po/'������`POTFILES.in'  
10.4.2 ����������������������`configure.in'  
10.4.3 ����������������������`aclocal.m4'  
10.4.4 ����������������������`acconfig.h'  
10.4.5 ����������������������`Makefile.in'  
10.4.6 `src/'������`Makefile.in'  


10.4.1 `po/'������`POTFILES.in'

`po/'����������������`POTFILES.in'������������������������������ �������������������������������������������������������������������������� ��������������������������������������

 
# List of source files containing translatable strings.
# Copyright (C) 1995 Free Software Foundation, Inc.

# Common library files
lib/error.c
lib/getopt.c
lib/xmalloc.c

# Package source files
src/gettextp.c
src/msgfmt.c
src/xgettext.c

�������������������������������������������������������������������������� ������������������������������(see section 3.2 ����������������������������)�������������������� ����������`POTFILES.in'���������������������������������������������� ��������������������������������������������


10.4.2 ����������������������`configure.in'

  1. ����������������������������

    ����������������������������

     
    PACKAGE=gettext
    VERSION=0.10
    AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
    AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
    AC_SUBST(PACKAGE)
    AC_SUBST(VERSION)
    

    ����������`gettext'������������������������������ `0.10'���������������������������������������������������� ����������������������tar������������������������������������������ ��������(��������`gettext-0.10.tar.gz'����������)��

  2. ��������������������

    ��������������������������������������������������ALL_LINGUAS������ ��������������������������������

     
    ALL_LINGUAS="de fr"
    

    �������������������������������������������������������������������������� ������PO������������������������������������������������������������������ �������������������������������������������������������� `configure.in'����ALL_LINGUAS�������������������������������� ����������������������������������LINGUAS������������ (see section 7.2 ��������������������)��

  3. ������������������������

    ����������������������������������������������m4������������ `configure.in'��������������������������

     
    AM_GNU_GETTEXT
    

    ����������������������������������������configure������������������������ ��������������������������������������������

  4. ������������������

    `configure.in'������������AC_OUTPUT�������������������������� ������������������������������

     
    AC_OUTPUT([existing configuration files intl/Makefile po/Makefile.in],
    existing additional actions])
    

    AC_OUTPUT����������������������������`intl/'��`po/'������ ��������������������������`.in'��������������`po/'�������������� ���������������������������������������������������������� `po/Makefile.in.in'����������������


10.4.3 ����������������������`aclocal.m4'

��������������`aclocal.m4'�������������������������������������������� GNU gettext����`aclocal.m4'���������������������������������� ������������������������AM_LC_MESSAGES��AM_WITH_NLS�� AM_GNU_GETTEXT��AM_PATH_PROG_WITH_TEST(AM_WITH_NLS�� ������������������)������������������������������������������������������ ������������������������������������������

����`aclocal.m4'������������������������������������������������ `aclocal.m4'�������������������������������������������������������� gettext������������������������������������������GNU gettext������������������������������������������������������������ ������������������������������������������������������������������ �������������������������������������������������������������������������� ������

�������������������������������������������������������������������������� ��������������������������������������������Autoconf���������������������� ����������������������������m4��������gettext�������������� ��������������������������������������������������


10.4.4 ����������������������`acconfig.h'

����������`acconfig.h'�������������������������������������������� GNU gettext����`acconfig.h'���������������������������������� ������������������ENABLE_NLS��HAVE_CATGETS�� HAVE_GETTEXT��HAVE_LC_MESSAGES��HAVE_STPCPY�� PACKAGE��VERSION���������������������������������������������� ���������������������������������������������������������������������������� ����`acconfig.h'�������������������������������������������� `acconfig.h'����������������������������


10.4.5 ����������������������`Makefile.in'

������������������������`Makefile.in'�������������������������������� ����������������

  1. `dist:'����������������������������(����������������������)�� `Makefile.in'��������������������������������������

     
    PACKAGE = @PACKAGE@
    VERSION = @VERSION@
    

  2. DISTFILES������`ABOUT-NLS'�������������������������� ����������������������������������������������

  3. `Makefile.in'������������������������������������������������ `intl'��`po'�������������������������������������� `Makefiles'���������������������������������������������������������� ������

    automake������������������������GNU�������������������������������������� ��Makefile���������������������������������������������������������������� ����������`installdirs'��`install'��`uninstall'�� `clean'��`distclean'����������������������

    ������������������������������������������������������`dist:'�������� ��������������Makefile.in��SUBDIRS������������������������

     
    SUBDIRS = doc lib @INTLSUB@ src @POSUB@
    

    ������������������������������������������������������������������

  4. `dist:'��������������������������������������`intl/Makefile'�� `po/Makefile'���������������������������������������� `Makefile'�������������������������������������������������������� `dist:'����������������������������������������

     
    distdir = $(PACKAGE)-$(VERSION)
    dist: Makefile
    	rm -fr $(distdir)
    	mkdir $(distdir)
    	chmod 777 $(distdir)
    	for file in $(DISTFILES); do \
    	  ln $$file $(distdir) 2>/dev/null || cp -p $$file $(distdir); \
    	done
    	for subdir in $(SUBDIRS); do \
    	  mkdir $(distdir)/$$subdir || exit 1; \
    	  chmod 777 $(distdir)/$$subdir; \
    	  (cd $$subdir && $(MAKE) $@) || exit 1; \
    	done
    	tar chozf $(distdir).tar.gz $(distdir)
    	rm -fr $(distdir)
    


10.4.6 `src/'������`Makefile.in'

��������`Makefile.in'������������������������������������������������ ��������(��������`src/'������������������������������������������)�� `Makefile.in'������������������������������`src/Makefile.in'���� ������������������������������

  1. `dist:'������������������������`src/Makefile.in'���������������� ������������������

     
    PACKAGE = @PACKAGE@
    VERSION = @VERSION@
    

  2. ������������������������������top_srcdir�������������������������� ������������������������cpp���������������������������������������� ��������������������������

     
    top_srcdir = @top_srcdir@
    

  3. ������`Makefile.in'��������������`dist:'�������������������������� subdir������`src'�������������������������������������������� ��`dist:'����������������������������������������������������������

     
    subdir = src
    

  4. ������������������������������������@INTLLIBS@������������������ ����������������������������LIBS���������������������������������� ��������������

     
    LIBS = @INTLLIBS@ @LIBS@
    

    GNU gettext�������������������������������������������������������� ��������������������������������������`lib/'������������������������ ��(������������GNU gettext���������������������������������������� ��������������)��������`lib/'���������������������������������������� �������������������������������������������������������������������������� ����(`libsupport.a'������������)������������������ @INTLLIBS@��@LIBS@�������������������������������������� ����������������������

     
    LIBS = ../lib/libsupport.a @INTLLIBS@ ../lib/libsupport.a @LIBS@
    

  5. `intl/'���������������������������������������������������������������� ������C�������������������������������������������������������������������� `-I../intl'��`-I$(top_srcdir)/intl'��������C�������������������� ����������������������������

  6. `dist:'�������������������������������������������������������������� ����������������������

     
    distdir = ../$(PACKAGE)-$(VERSION)/$(subdir)
    dist: Makefile $(DISTFILES)
    	for file in $(DISTFILES); do \
    	  ln $$file $(distdir) 2>/dev/null || cp -p $$file $(distdir); \
    	done
    


11. ����

����������GNU gettext������������������������������������������ ������������������������������������������������������������������������ ��������������������������������������������������������

11.1 GNU gettext������  
11.2 ��������  


11.1 GNU gettext������

�������������������������������������������������������������������������� ��������GNU������������������������������GNU lib������������������ ����Hurd����������������������������������������������(������������ ������������������)�������������������������������������������������������� ��������������������������������

��������Patrick D'Cruze��GNU fileutils����������3.9.2�������������� ����������������������������������������������1994����7������������������ ����������������������������Jim Meyering���������������������������������� ���������������������������������������������������������������� #ifdef������������������������������������Jim���������������������� ������������Patrick��Jim�������������������������������������������������� ������������������������������GNU���������������������������������������� Jim��������������������������������������������������������Richard Stallman��������������������������Richard��������������glocale���� ������������������������������������������������������������������

Jim��glocale����������Patrick��Richard���������������������������� ��������������������Mitchum DSouza(catgets������������������������ ����)��Roland McGrath, ����David MacKenzie�� Pinard�� Paul Eggert�������������������������������������������������������������� ���������������������������������������������������������������������������� ��������glocale������������������

Jim������������������������������������������������������������Roland�� GNU libc��������������������������������Ulrich Drepper�������������� ��������������������glocale��������������������������Ulrich�������� ��������������������������������glocale���������������������������� ������������������������������������������������Ulrich�������������������� ��������������������������������������glocale������ msgutils��������������������������nlsutils������������������ ������gettext������������������������������1995��5������Richard������ ������������������������

Ulrich Drepper��1995����������GNU gettext�������������������������� ������������������������PO���������������������������������������������� 1995����7��������������������������������0.7���������������������� Ulrich�������������������������������������������������������������������� ������������������������������������������������GNU gettext�������� ��THANKS��������������������������

������������������������François������������������GNU������������ glocale����������gettext������������������������������������ �������������������������������������������������������������������������� �������������������������������������������������������������������� Patrick D'Cruze������������������������������������20�������������������� ������������������������������������������������(������������������������ �������������������������������������������������������������������������� ������������������������������)������������������������������������������ ��������������������������������������������������������������1995��5���� ��������������

������Greg McGary��������������1995����������PO���������� ����������������������Ulrich��������������������������������������GNU gettext��Texinfo����������������������������


11.2 ��������

Eugene H. Dorr(`dorre@well.com')��Internationalization Reference List���������������������������������������������������������� ������������������������������
 
ftp://ftp.ora.com/pub/examples/nutshell/ujip/doc/i18n-books.txt

Michael Gschwind(`mike@vlsivie.tuwien.ac.at')��Programming for Internationalisation��������������������������������(Frequently Asked Questions (FAQ))������������������������������FAQ������������������ ���������������������������������������������������������������������������� ������������������ISO 8859-1������������������������������������������ ����������������������������������

`comp.unix.questions', `comp.std.internat', `comp.software.international', `comp.lang.c', `comp.windows.x', `comp.std.c', `comp.answers'�� `news.answers'��������Usenet������������������������������ ������������������������������������������

 
ftp://ftp.vlsivie.tuwien.ac.at/pub/8bit/ISO-programming

Patrick D'Cruze(`pdcruze@li.org')��NLS������������������������������ ������������Jochen Hein(`Hein@student.tu-clausthal.de')������������ ����������������������������������������������������������

 
ftp://sunsite.unc.edu/pub/Linux/utils/nls/catalogs/Incoming/...
     ...locale-tutorial-0.8.txt.gz
����������������������������������������������������
 
ftp://ftp.ibp.fr/pub/linux/sunsite/

��������������������������������������������������
 
ftp://ftp.ibp.fr/pub/linux/french/docs/
������������������������������Linux������������������������������


A. ����������

ISO 639��������������������2������������������������������������������ ����������������������������������������������������������������������������


[Top] [Contents] [Index] [ ? ]

Footnotes

(1)

����������GNU gettext���������������� ����������������Solaris��msgfmt����������������������

(2)

Ultrix������������������������LC_MESSAGES�������� ��������������������������������������������(arbitrary value)������������

(3)

����������setlocale�������������������������������������� ������������������������������������������������������������������


[Top] [Contents] [Index] [ ? ]

Table of Contents


[Top] [Contents] [Index] [ ? ]

Short Table of Contents

1. ������������������
2. PO����������PO������������
3. ����������������������
4. ������PO��������������
5. ������PO��������������
6. MO��������������
7. ������������������
8. ����������������������
9. ������������������
10. ����������������������
11. ����
A. ����������

[Top] [Contents] [Index] [ ? ]

About this document

This document was generated by & Yosiaki on November, 13 2000 using texi2html

The buttons in the navigation panels have the following meaning:

Button Name Go to From 1.2.3 go to
[ < ] Back previous section in reading order 1.2.2
[ > ] Forward next section in reading order 1.2.4
[ << ] FastBack previous or up-and-previous section 1.1
[ Up ] Up up section 1.2
[ >> ] FastForward next or up-and-next section 1.3
[Top] Top cover (top) of document  
[Contents] Contents table of contents  
[Index] Index concept index  
[ ? ] About this page  

where the Example assumes that the current position is at Subsubsection One-Two-Three of a document of the following structure:

This document was generated by & Yosiaki on November, 13 2000 using texi2html