From: Bruno Haible Date: Wed, 23 May 2001 21:17:07 +0000 (+0000) Subject: Automatically generated. X-Git-Tag: v0.10.38~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ce97b018e2a0af83eec7fed77cd6d3fc16f6c897;p=thirdparty%2Fgettext.git Automatically generated. --- diff --git a/man/Makefile.in b/man/Makefile.in new file mode 100644 index 000000000..1fac528e7 --- /dev/null +++ b/man/Makefile.in @@ -0,0 +1,340 @@ +# Makefile.in generated automatically by automake 1.4 from Makefile.am + +# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc. +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + + +SHELL = @SHELL@ + +srcdir = @srcdir@ +top_srcdir = @top_srcdir@ +VPATH = @srcdir@ +prefix = @prefix@ +exec_prefix = @exec_prefix@ + +bindir = @bindir@ +sbindir = @sbindir@ +libexecdir = @libexecdir@ +datadir = @datadir@ +sysconfdir = @sysconfdir@ +sharedstatedir = @sharedstatedir@ +localstatedir = @localstatedir@ +libdir = @libdir@ +infodir = @infodir@ +includedir = @includedir@ +oldincludedir = /usr/include + +DESTDIR = + +pkgdatadir = $(datadir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ + +top_builddir = .. + +ACLOCAL = @ACLOCAL@ +AUTOCONF = @AUTOCONF@ +AUTOMAKE = @AUTOMAKE@ +AUTOHEADER = @AUTOHEADER@ + +INSTALL = @INSTALL@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS) +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +transform = @program_transform_name@ + +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +host_alias = @host_alias@ +host_triplet = @host@ +ACLOCAL_VERSION = @ACLOCAL_VERSION@ +AS = @AS@ +BUILD_INCLUDED_LIBINTL = @BUILD_INCLUDED_LIBINTL@ +CATALOGS = @CATALOGS@ +CATOBJEXT = @CATOBJEXT@ +CC = @CC@ +DATADIRNAME = @DATADIRNAME@ +DLLTOOL = @DLLTOOL@ +DVIPS = @DVIPS@ +EMACS = @EMACS@ +EXEEXT = @EXEEXT@ +GENCAT = @GENCAT@ +GLIBC21 = @GLIBC21@ +GMOFILES = @GMOFILES@ +GMSGFMT = @GMSGFMT@ +INSTOBJEXT = @INSTOBJEXT@ +INTLBISON = @INTLBISON@ +INTLLIBS = @INTLLIBS@ +INTLOBJS = @INTLOBJS@ +INTL_LIBTOOL_SUFFIX_PREFIX = @INTL_LIBTOOL_SUFFIX_PREFIX@ +LIBICONV = @LIBICONV@ +LIBOBJS = @LIBOBJS@ +LIBTOOL = @LIBTOOL@ +LN_S = @LN_S@ +MAKEINFO = @MAKEINFO@ +MKINSTALLDIRS = @MKINSTALLDIRS@ +MSGFMT = @MSGFMT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +PACKAGE = @PACKAGE@ +POFILES = @POFILES@ +POSUB = @POSUB@ +RANLIB = @RANLIB@ +TEXI2HTML = @TEXI2HTML@ +TEXI2PDF = @TEXI2PDF@ +USE_INCLUDED_LIBINTL = @USE_INCLUDED_LIBINTL@ +USE_NLS = @USE_NLS@ +YACC = @YACC@ +aclocaldir = @aclocaldir@ +lispdir = @lispdir@ + +VERSION = @VERSION@ +mandir = @mandir@ +docdir = $(prefix)/doc/@PACKAGE@ +htmldir = $(docdir) + +AUTOMAKE_OPTIONS = 1.2 gnits + +man_MAN3 = gettext.3 ngettext.3 textdomain.3 bindtextdomain.3 bind_textdomain_codeset.3 + +man_MAN3IN = gettext.3.in ngettext.3.in textdomain.3.in bindtextdomain.3.in bind_textdomain_codeset.3.in + +man_MANS = $(man_MAN3) dgettext.3 dcgettext.3 dngettext.3 dcngettext.3 + + +man_HTML = gettext.3.html ngettext.3.html textdomain.3.html bindtextdomain.3.html bind_textdomain_codeset.3.html + + +EXTRA_DIST = $(man_MANS) $(man_MAN3IN) $(man_HTML) +MAINTAINERCLEANFILES = $(man_MAN1) $(man_MAN3) $(man_HTML) + +RM = rm -f + +# groff 1.17 or newer. +MAN2HTML = groff -mandoc -Thtml +mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs +CONFIG_HEADER = ../config.h +CONFIG_CLEAN_FILES = +man3dir = $(mandir)/man3 +MANS = $(man_MANS) + +NROFF = nroff +DIST_COMMON = ChangeLog Makefile.am Makefile.in + + +DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) + +TAR = tar +GZIP_ENV = --best +all: all-redirect +.SUFFIXES: +$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) + cd $(top_srcdir) && $(AUTOMAKE) --gnits --include-deps man/Makefile + +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + cd $(top_builddir) \ + && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status + + +install-man3: + $(mkinstalldirs) $(DESTDIR)$(man3dir) + @list='$(man3_MANS)'; \ + l2='$(man_MANS)'; for i in $$l2; do \ + case "$$i" in \ + *.3*) list="$$list $$i" ;; \ + esac; \ + done; \ + for i in $$list; do \ + if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \ + else file=$$i; fi; \ + ext=`echo $$i | sed -e 's/^.*\\.//'`; \ + inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ + inst=`echo $$inst | sed '$(transform)'`.$$ext; \ + echo " $(INSTALL_DATA) $$file $(DESTDIR)$(man3dir)/$$inst"; \ + $(INSTALL_DATA) $$file $(DESTDIR)$(man3dir)/$$inst; \ + done + +uninstall-man3: + @list='$(man3_MANS)'; \ + l2='$(man_MANS)'; for i in $$l2; do \ + case "$$i" in \ + *.3*) list="$$list $$i" ;; \ + esac; \ + done; \ + for i in $$list; do \ + ext=`echo $$i | sed -e 's/^.*\\.//'`; \ + inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ + inst=`echo $$inst | sed '$(transform)'`.$$ext; \ + echo " rm -f $(DESTDIR)$(man3dir)/$$inst"; \ + rm -f $(DESTDIR)$(man3dir)/$$inst; \ + done +install-man: $(MANS) + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) install-man3 +uninstall-man: + @$(NORMAL_UNINSTALL) + $(MAKE) $(AM_MAKEFLAGS) uninstall-man3 +tags: TAGS +TAGS: + + +distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) + +subdir = man + +distdir: $(DISTFILES) + @for file in $(DISTFILES); do \ + d=$(srcdir); \ + if test -d $$d/$$file; then \ + cp -pr $$/$$file $(distdir)/$$file; \ + else \ + test -f $(distdir)/$$file \ + || ln $$d/$$file $(distdir)/$$file 2> /dev/null \ + || cp -p $$d/$$file $(distdir)/$$file || :; \ + fi; \ + done +info-am: +info: info-am +dvi-am: +dvi: dvi-am +check-am: all-am +check: check-am +installcheck-am: +installcheck: installcheck-am +install-exec-am: +install-exec: install-exec-am + +install-data-am: install-man install-data-local +install-data: install-data-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am +install: install-am +uninstall-am: uninstall-man uninstall-local +uninstall: uninstall-am +all-am: Makefile $(MANS) all-local +all-redirect: all-am +install-strip: + $(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install +installdirs: + $(mkinstalldirs) $(DESTDIR)$(mandir)/man3 + + +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -rm -f Makefile $(CONFIG_CLEAN_FILES) + -rm -f config.cache config.log stamp-h stamp-h[0-9]* + +maintainer-clean-generic: + -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) +mostlyclean-am: mostlyclean-generic + +mostlyclean: mostlyclean-am + +clean-am: clean-generic mostlyclean-am + +clean: clean-am + +distclean-am: distclean-generic clean-am + -rm -f libtool + +distclean: distclean-am + +maintainer-clean-am: maintainer-clean-generic distclean-am + @echo "This command is intended for maintainers to use;" + @echo "it deletes files that may require special tools to rebuild." + +maintainer-clean: maintainer-clean-am + +.PHONY: install-man3 uninstall-man3 install-man uninstall-man tags \ +distdir info-am info dvi-am dvi check check-am installcheck-am \ +installcheck install-exec-am install-exec install-data-local \ +install-data-am install-data install-am install uninstall-local \ +uninstall-am uninstall all-local all-redirect all-am all installdirs \ +mostlyclean-generic distclean-generic clean-generic \ +maintainer-clean-generic clean mostlyclean distclean maintainer-clean + + +# We distribute both the man pages and their HTML equivalent. +# The user can generate the parts, via +# make man +# make html + +all-local: html +install-data-local: install-html +installdirs-local: installdirs-html +uninstall-local: uninstall-html + +# Man pages. + +gettext.3: gettext.3.in $(top_srcdir)/configure.in + sed -e 's/@''VERSION''@/@VERSION@/g' < $(srcdir)/gettext.3.in > t-$@ + mv t-$@ $@ +ngettext.3: ngettext.3.in $(top_srcdir)/configure.in + sed -e 's/@''VERSION''@/@VERSION@/g' < $(srcdir)/ngettext.3.in > t-$@ + mv t-$@ $@ +textdomain.3: textdomain.3.in $(top_srcdir)/configure.in + sed -e 's/@''VERSION''@/@VERSION@/g' < $(srcdir)/textdomain.3.in > t-$@ + mv t-$@ $@ +bindtextdomain.3: bindtextdomain.3.in $(top_srcdir)/configure.in + sed -e 's/@''VERSION''@/@VERSION@/g' < $(srcdir)/bindtextdomain.3.in > t-$@ + mv t-$@ $@ +bind_textdomain_codeset.3: bind_textdomain_codeset.3.in $(top_srcdir)/configure.in + sed -e 's/@''VERSION''@/@VERSION@/g' < $(srcdir)/bind_textdomain_codeset.3.in > t-$@ + mv t-$@ $@ + +# Man pages in HTML format. + +html: $(man_HTML) + +gettext.3.html: gettext.3.in + $(MAN2HTML) $(srcdir)/gettext.3.in > t-$@ + mv t-$@ $@ +ngettext.3.html: ngettext.3.in + $(MAN2HTML) $(srcdir)/ngettext.3.in > t-$@ + mv t-$@ $@ +textdomain.3.html: textdomain.3.in + $(MAN2HTML) $(srcdir)/textdomain.3.in > t-$@ + mv t-$@ $@ +bindtextdomain.3.html: bindtextdomain.3.in + $(MAN2HTML) $(srcdir)/bindtextdomain.3.in > t-$@ + mv t-$@ $@ +bind_textdomain_codeset.3.html: bind_textdomain_codeset.3.in + $(MAN2HTML) $(srcdir)/bind_textdomain_codeset.3.in > t-$@ + mv t-$@ $@ + +install-html: + $(mkinstalldirs) $(DESTDIR)$(htmldir) + for file in $(man_HTML); do \ + if test -f $$file; then dir=.; else dir=$(srcdir); fi; \ + $(INSTALL_DATA) $$dir/$$file $(DESTDIR)$(htmldir)/$$file; \ + done + +installdirs-html: + $(mkinstalldirs) $(DESTDIR)$(htmldir) + +uninstall-html: + for file in $(man_HTML); do \ + $(RM) $(DESTDIR)$(htmldir)/$$file; \ + done + +# One more automake bug. +installdirs: installdirs-local + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/man/bind_textdomain_codeset.3 b/man/bind_textdomain_codeset.3 new file mode 100644 index 000000000..55f348475 --- /dev/null +++ b/man/bind_textdomain_codeset.3 @@ -0,0 +1,72 @@ +.\" Copyright (c) Bruno Haible +.\" +.\" This is free documentation; you can redistribute it and/or +.\" modify it under the terms of the GNU General Public License as +.\" published by the Free Software Foundation; either version 2 of +.\" the License, or (at your option) any later version. +.\" +.\" References consulted: +.\" GNU glibc-2 source code and manual +.\" GNU gettext source code and manual +.\" LI18NUX 2000 Globalization Specification +.\" +.TH BIND_TEXTDOMAIN_CODESET 3 "May 2001" "GNU gettext 0.10.38" +.SH NAME +bind_textdomain_codeset \- set encoding of message translations +.SH SYNOPSIS +.nf +.B #include +.sp +.BI "char * bind_textdomain_codeset (const char * " domainname , +.BI " const char * " codeset ); +.fi +.SH DESCRIPTION +The \fBbind_textdomain_codeset\fP function sets the output codeset for message +catalogs for domain \fIdomainname\fP. +.PP +A message domain is a set of translatable \fImsgid\fP messages. Usually, +every software package has its own message domain. +.PP +By default, the \fBgettext\fP family of functions returns translated messages +in the locale's character encoding, which can be retrieved as +\fBnl_langinfo(CODESET)\fP. The need for calling \fBbind_textdomain_codeset\fP +arises for programs which store strings in a locale independent way (e.g. +UTF-8) and want to avoid an extra character set conversion on the returned +translated messages. +.PP +\fIdomainname\fP must be a non-empty string. +.PP +If \fIcodeset\fP is not NULL, it must be a valid encoding name which can be +used for the \fBiconv_open\fP function. The \fBbind_textdomain_codeset\fP +function sets the output codeset for message catalogs belonging to domain +\fIdomainname\fP to \fIcodeset\fP. The function makes copies of the argument +strings as needed. +.PP +If \fIcodeset\fP is NULL, the function returns the previously set codeset for +domain \fIdomainname\fP. The default is NULL, denoting the locale's character +encoding. +.SH "RETURN VALUE" +If successful, the \fBbind_textdomain_codeset\fP function returns the current +codeset for domain \fIdomainname\fP, after possibly changing it. The resulting +string is valid until the next \fBbind_textdomain_codeset\fP call for the same +\fIdomainname\fP and must not be modified or freed. If a memory allocation +failure occurs, it sets \fBerrno\fP to \fBENOMEM\fP and returns NULL. If no +codeset has been set for domain \fIdomainname\fP, it returns NULL. +.SH ERRORS +The following error can occur, among others: +.TP +.B ENOMEM +Not enough memory available. +.SH BUGS +The return type ought to be \fBconst char *\fP, but is \fBchar *\fP to avoid +warnings in C code predating ANSI C. +.SH "SEE ALSO" +.BR gettext (3), +.BR dgettext (3), +.BR dcgettext (3), +.BR ngettext (3), +.BR dngettext (3), +.BR dcngettext (3), +.BR textdomain (3), +.BR nl_langinfo (3), +.BR iconv_open (3) diff --git a/man/bind_textdomain_codeset.3.html b/man/bind_textdomain_codeset.3.html new file mode 100644 index 000000000..beb9875c5 --- /dev/null +++ b/man/bind_textdomain_codeset.3.html @@ -0,0 +1,154 @@ + + + + +BIND_TEXTDOMAIN_CODESET + + + +

BIND_TEXTDOMAIN_CODESET

+NAME
+SYNOPSIS
+DESCRIPTION
+RETURN VALUE
+ERRORS
+BUGS
+SEE ALSO
+ +
+ + + +

NAME

+ + +
+bind_textdomain_codeset - set encoding of message translations
+ +

SYNOPSIS

+ + + +
+
#include <libintl.h>
+
+char * bind_textdomain_codeset (const char * domainname,
+                                const char * codeset);
+
+ +

DESCRIPTION

+ + + +
+The bind_textdomain_codeset function sets the output +codeset for message catalogs for domain +domainname.
+ + + +
+A message domain is a set of translatable msgid +messages. Usually, every software package has its own +message domain.
+ + + +
+By default, the gettext family of functions returns +translated messages in the locale's character encoding, +which can be retrieved as nl_langinfo(CODESET). The +need for calling bind_textdomain_codeset arises for +programs which store strings in a locale independent way +(e.g. UTF-8) and want to avoid an extra character set +conversion on the returned translated messages.
+ + + +
+domainname must be a non-empty string.
+ + + +
+If codeset is not NULL, it must be a valid encoding +name which can be used for the iconv_open function. +The bind_textdomain_codeset function sets the output +codeset for message catalogs belonging to domain +domainname to codeset. The function makes +copies of the argument strings as needed.
+ + + +
+If codeset is NULL, the function returns the +previously set codeset for domain domainname. The +default is NULL, denoting the locale's character +encoding.
+ +

RETURN VALUE

+ + + +
+If successful, the bind_textdomain_codeset function +returns the current codeset for domain domainname, +after possibly changing it. The resulting string is valid +until the next bind_textdomain_codeset call for the +same domainname and must not be modified or freed. If +a memory allocation failure occurs, it sets errno to +ENOMEM and returns NULL. If no codeset has been set +for domain domainname, it returns NULL.
+ +

ERRORS

+ + + +
+The following error can occur, among others:
+ + + +
+ENOMEM
+ + + +
+Not enough memory available.
+ +

BUGS

+ + + +
+The return type ought to be const char *, but is +char * to avoid warnings in C code predating ANSI +C.
+ +

SEE ALSO

+ + + +
+gettext(3), dgettext(3), dcgettext(3), +ngettext(3), dngettext(3), +dcngettext(3), textdomain(3), +nl_langinfo(3), iconv_open(3)
+
+ + diff --git a/man/bindtextdomain.3 b/man/bindtextdomain.3 new file mode 100644 index 000000000..a82b2b1b2 --- /dev/null +++ b/man/bindtextdomain.3 @@ -0,0 +1,69 @@ +.\" Copyright (c) Bruno Haible +.\" +.\" This is free documentation; you can redistribute it and/or +.\" modify it under the terms of the GNU General Public License as +.\" published by the Free Software Foundation; either version 2 of +.\" the License, or (at your option) any later version. +.\" +.\" References consulted: +.\" GNU glibc-2 source code and manual +.\" GNU gettext source code and manual +.\" LI18NUX 2000 Globalization Specification +.\" +.TH BINDTEXTDOMAIN 3 "May 2001" "GNU gettext 0.10.38" +.SH NAME +bindtextdomain \- set directory containing message catalogs +.SH SYNOPSIS +.nf +.B #include +.sp +.BI "char * bindtextdomain (const char * " domainname ", const char * " dirname ); +.fi +.SH DESCRIPTION +The \fBbindtextdomain\fP function sets the base directory of the hierarchy +containing message catalogs for a given message domain. +.PP +A message domain is a set of translatable \fImsgid\fP messages. Usually, +every software package has its own message domain. The need for calling +\fBbindtextdomain\fP arises because packages are not always installed with +the same prefix as the header and the libc/libintl libraries. +.PP +Message catalogs will be expected at the pathnames +\fIdirname\fP/\fIlocale\fP/\fIcategory\fP/\fIdomainname\fP.mo, +where \fIlocale\fP is a locale name and \fIcategory\fP is a locale facet such +as \fBLC_MESSAGES\fP. +.PP +\fIdomainname\fP must be a non-empty string. +.PP +If \fIdirname\fP is not NULL, the base directory for message catalogs belonging +to domain \fIdomainname\fP is set to \fIdirname\fP. The function makes copies +of the argument strings as needed. If the program wishes to call the +\fBchdir\fP function, it is important that \fIdirname\fP be an absolute +pathname; otherwise it cannot be guaranteed that the message catalogs will +be found. +.PP +If \fIdirname\fP is NULL, the function returns the previously set base +directory for domain \fIdomainname\fP. +.SH "RETURN VALUE" +If successful, the \fBbindtextdomain\fP function returns the current base +directory for domain \fIdomainname\fP, after possibly changing it. The +resulting string is valid until the next \fBbindtextdomain\fP call for the +same \fIdomainname\fP and must not be modified or freed. If a memory allocation +failure occurs, it sets \fBerrno\fP to \fBENOMEM\fP and returns NULL. +.SH ERRORS +The following error can occur, among others: +.TP +.B ENOMEM +Not enough memory available. +.SH BUGS +The return type ought to be \fBconst char *\fP, but is \fBchar *\fP to avoid +warnings in C code predating ANSI C. +.SH "SEE ALSO" +.BR gettext (3), +.BR dgettext (3), +.BR dcgettext (3), +.BR ngettext (3), +.BR dngettext (3), +.BR dcngettext (3), +.BR textdomain (3), +.BR realpath (3) diff --git a/man/bindtextdomain.3.html b/man/bindtextdomain.3.html new file mode 100644 index 000000000..01c0bc3ad --- /dev/null +++ b/man/bindtextdomain.3.html @@ -0,0 +1,153 @@ + + + + +BINDTEXTDOMAIN + + + +

BINDTEXTDOMAIN

+NAME
+SYNOPSIS
+DESCRIPTION
+RETURN VALUE
+ERRORS
+BUGS
+SEE ALSO
+ +
+ + + +

NAME

+ + +
+bindtextdomain - set directory containing message catalogs
+ +

SYNOPSIS

+ + + +
+
#include <libintl.h>
+
+char * bindtextdomain (const char * domainname, const char * dirname);
+
+ +

DESCRIPTION

+ + + +
+The bindtextdomain function sets the base directory +of the hierarchy containing message catalogs for a given +message domain.
+ + + +
+A message domain is a set of translatable msgid +messages. Usually, every software package has its own +message domain. The need for calling bindtextdomain +arises because packages are not always installed with the +same prefix as the <libintl.h> header and the +libc/libintl libraries.
+ + + +
+Message catalogs will be expected at the pathnames +dirname/locale/category/domainname.mo, +where locale is a locale name and category is +a locale facet such as LC_MESSAGES.
+ + + +
+domainname must be a non-empty string.
+ + + +
+If dirname is not NULL, the base directory for +message catalogs belonging to domain domainname is +set to dirname. The function makes copies of the +argument strings as needed. If the program wishes to call +the chdir function, it is important that +dirname be an absolute pathname; otherwise it cannot +be guaranteed that the message catalogs will be +found.
+ + + +
+If dirname is NULL, the function returns the +previously set base directory for domain +domainname.
+ +

RETURN VALUE

+ + + +
+If successful, the bindtextdomain function returns +the current base directory for domain domainname, +after possibly changing it. The resulting string is valid +until the next bindtextdomain call for the same +domainname and must not be modified or freed. If a +memory allocation failure occurs, it sets errno to +ENOMEM and returns NULL.
+ +

ERRORS

+ + + +
+The following error can occur, among others:
+ + + +
+ENOMEM
+ + + +
+Not enough memory available.
+ +

BUGS

+ + + +
+The return type ought to be const char *, but is +char * to avoid warnings in C code predating ANSI +C.
+ +

SEE ALSO

+ + + +
+gettext(3), dgettext(3), dcgettext(3), +ngettext(3), dngettext(3), +dcngettext(3), textdomain(3), +realpath(3)
+
+ + diff --git a/man/gettext.3 b/man/gettext.3 new file mode 100644 index 000000000..eb28df1b7 --- /dev/null +++ b/man/gettext.3 @@ -0,0 +1,99 @@ +.\" Copyright (c) Bruno Haible +.\" +.\" This is free documentation; you can redistribute it and/or +.\" modify it under the terms of the GNU General Public License as +.\" published by the Free Software Foundation; either version 2 of +.\" the License, or (at your option) any later version. +.\" +.\" References consulted: +.\" GNU glibc-2 source code and manual +.\" GNU gettext source code and manual +.\" LI18NUX 2000 Globalization Specification +.\" +.TH GETTEXT 3 "May 2001" "GNU gettext 0.10.38" +.SH NAME +gettext, dgettext, dcgettext \- translate message +.SH SYNOPSIS +.nf +.B #include +.sp +.BI "char * gettext (const char * " msgid ); +.BI "char * dgettext (const char * " domainname ", const char * " msgid ); +.BI "char * dcgettext (const char * " domainname ", const char * " msgid , +.BI " int " category ); +.fi +.SH DESCRIPTION +The \fBgettext\fP, \fBdgettext\fP and \fBdcgettext\fP functions attempt to +translate a text string into the user's native language, by looking up the +translation in a message catalog. +.PP +The \fImsgid\fP argument identifies the message to be translated. By +convention, it is the English version of the message, with non-ASCII +characters replaced by ASCII approximations. This choice allows the +translators to work with message catalogs, called PO files, that contain +both the English and the translated versions of each message, and can be +installed using the \fBmsgfmt\fP utility. +.PP +A message domain is a set of translatable \fImsgid\fP messages. Usually, +every software package has its own message domain. The domain name is used +to determine the message catalog where the translation is looked up; it must +be a non-empty string. For the \fBgettext\fP function, it is specified through +a preceding \fBtextdomain\fP call. For the \fBdgettext\fP and \fBdcgettext\fP +functions, it is passed as the \fIdomainname\fP argument; if this argument is +NULL, the domain name specified through a preceding \fBtextdomain\fP call is +used instead. +.PP +Translation lookup operates in the context of the current locale. For the +\fBgettext\fP and \fBdgettext\fP functions, the \fBLC_MESSAGES\fP locale +facet is used. It is determined by a preceding call to the \fBsetlocale\fP +function. \fBsetlocale(LC_ALL,"")\fP initializes the \fBLC_MESSAGES\fP locale +based on the first nonempty value of the three environment variables +\fBLC_ALL\fP, \fBLC_MESSAGES\fP, \fBLANG\fP; see \fBsetlocale\fP(3). For the +\fBdcgettext\fP function, the locale facet is determined by the \fIcategory\fP +argument, which should be one of the \fBLC_xxx\fP constants defined in the + header, excluding \fBLC_ALL\fP. In both cases, the functions also +use the \fBLC_CTYPE\fP locale facet in order to convert the translated message +from the translator's codeset to the current locale's codeset, unless +overridden by a prior call to the \fBbind_textdomain_codeset\fP function. +.PP +The message catalog used by the functions is at the pathname +\fIdirname\fP/\fIlocale\fP/\fIcategory\fP/\fIdomainname\fP.mo. Here +\fIdirname\fP is the directory specified through \fBbindtextdomain\fP. Its +default is system and configuration dependent; typically it is +\fIprefix\fP/share/locale, where \fIprefix\fP is the installation prefix of the +package. \fIlocale\fP is the name of the current locale facet; the GNU +implementation also tries generalizations, such as the language name without +the territory name. \fIcategory\fP is \fBLC_MESSAGES\fP for the \fBgettext\fP +and \fBdgettext\fP functions, or the argument passed to the \fBdcgettext\fP +function. +.PP +If the \fBLANGUAGE\fP environment variable is set to a nonempty value, and the +locale is not the "C" locale, the value of \fBLANGUAGE\fP is assumed to contain +a colon separated list of locale names. The functions will attempt to look up +a translation of \fImsgid\fP in each of the locales in turn. This is a GNU +extension. +.PP +In the "C" locale, or if none of the used catalogs contain a translation for +\fImsgid\fP, the \fBgettext\fP, \fBdgettext\fP and \fBdcgettext\fP functions +return \fImsgid\fP. +.SH "RETURN VALUE" +If a translation was found in one of the specified catalogs, it is converted +to the locale's codeset and returned. The resulting string is statically +allocated and must not be modified or freed. Otherwise \fImsgid\fP is returned. +.SH ERRORS +\fBerrno\fP is not modified. +.SH BUGS +The return type ought to be \fBconst char *\fP, but is \fBchar *\fP to avoid +warnings in C code predating ANSI C. +.PP +When an empty string is used for \fImsgid\fP, the functions may return a +nonempty string. +.SH "SEE ALSO" +.BR ngettext (3), +.BR dngettext (3), +.BR dcngettext (3), +.BR setlocale (3), +.BR textdomain (3), +.BR bindtextdomain (3), +.BR bind_textdomain_codeset (3), +.BR msgfmt (1) diff --git a/man/gettext.3.html b/man/gettext.3.html new file mode 100644 index 000000000..bc22bab99 --- /dev/null +++ b/man/gettext.3.html @@ -0,0 +1,192 @@ + + + + +GETTEXT + + + +

GETTEXT

+NAME
+SYNOPSIS
+DESCRIPTION
+RETURN VALUE
+ERRORS
+BUGS
+SEE ALSO
+ +
+ + + +

NAME

+ + +
+gettext, dgettext, dcgettext - translate message
+ +

SYNOPSIS

+ + + +
+
#include <libintl.h>
+
+char * gettext (const char * msgid);
+char * dgettext (const char * domainname, const char * msgid);
+char * dcgettext (const char * domainname, const char * msgid,
+                  int category);
+
+ +

DESCRIPTION

+ + + +
+The gettext, dgettext and dcgettext +functions attempt to translate a text string into the user's +native language, by looking up the translation in a message +catalog.
+ + + +
+The msgid argument identifies the message to be +translated. By convention, it is the English version of the +message, with non-ASCII characters replaced by ASCII +approximations. This choice allows the translators to work +with message catalogs, called PO files, that contain both +the English and the translated versions of each message, and +can be installed using the msgfmt +utility.
+ + + +
+A message domain is a set of translatable msgid +messages. Usually, every software package has its own +message domain. The domain name is used to determine the +message catalog where the translation is looked up; it must +be a non-empty string. For the gettext function, it +is specified through a preceding textdomain call. For +the dgettext and dcgettext functions, it is +passed as the domainname argument; if this argument +is NULL, the domain name specified through a preceding +textdomain call is used instead.
+ + + +
+Translation lookup operates in the context of the current +locale. For the gettext and dgettext +functions, the LC_MESSAGES locale facet is used. It +is determined by a preceding call to the setlocale +function. setlocale(LC_ALL,"") initializes +the LC_MESSAGES locale based on the first nonempty +value of the three environment variables LC_ALL, +LC_MESSAGES, LANG; see setlocale(3). +For the dcgettext function, the locale facet is +determined by the category argument, which should be +one of the LC_xxx constants defined in the +<locale.h> header, excluding LC_ALL. In both +cases, the functions also use the LC_CTYPE locale +facet in order to convert the translated message from the +translator's codeset to the current locale's codeset, unless +overridden by a prior call to the +bind_textdomain_codeset function.
+ + + +
+The message catalog used by the functions is at the pathname +dirname/locale/category/domainname.mo. +Here dirname is the directory specified through +bindtextdomain. Its default is system and +configuration dependent; typically it is +prefix/share/locale, where prefix is the +installation prefix of the package. locale is the +name of the current locale facet; the GNU implementation +also tries generalizations, such as the language name +without the territory name. category is +LC_MESSAGES for the gettext and +dgettext functions, or the argument passed to the +dcgettext function.
+ + + +
+If the LANGUAGE environment variable is set to a +nonempty value, and the locale is not the "C" +locale, the value of LANGUAGE is assumed to contain a +colon separated list of locale names. The functions will +attempt to look up a translation of msgid in each of +the locales in turn. This is a GNU extension.
+ + + +
+In the "C" locale, or if none of the used catalogs +contain a translation for msgid, the gettext, +dgettext and dcgettext functions return +msgid.
+ +

RETURN VALUE

+ + + +
+If a translation was found in one of the specified catalogs, +it is converted to the locale's codeset and returned. The +resulting string is statically allocated and must not be +modified or freed. Otherwise msgid is +returned.
+ +

ERRORS

+ + + +
+errno is not modified.
+ +

BUGS

+ + + +
+The return type ought to be const char *, but is +char * to avoid warnings in C code predating ANSI +C.
+ + + +
+When an empty string is used for msgid, the functions +may return a nonempty string.
+ +

SEE ALSO

+ + + +
+ngettext(3), dngettext(3), +dcngettext(3), setlocale(3), +textdomain(3), bindtextdomain(3), +bind_textdomain_codeset(3), +msgfmt(1)
+
+ + diff --git a/man/ngettext.3 b/man/ngettext.3 new file mode 100644 index 000000000..d82cc0dc1 --- /dev/null +++ b/man/ngettext.3 @@ -0,0 +1,60 @@ +.\" Copyright (c) Bruno Haible +.\" +.\" This is free documentation; you can redistribute it and/or +.\" modify it under the terms of the GNU General Public License as +.\" published by the Free Software Foundation; either version 2 of +.\" the License, or (at your option) any later version. +.\" +.\" References consulted: +.\" GNU glibc-2 source code and manual +.\" GNU gettext source code and manual +.\" LI18NUX 2000 Globalization Specification +.\" +.TH NGETTEXT 3 "May 2001" "GNU gettext 0.10.38" +.SH NAME +ngettext, dngettext, dcngettext \- translate message and choose plural form +.SH SYNOPSIS +.nf +.B #include +.sp +.BI "char * ngettext (const char * " msgid ", const char * " msgid_plural , +.BI " unsigned long int " n ); +.BI "char * dngettext (const char * " domainname , +.BI " const char * " msgid ", const char * " msgid_plural , +.BI " unsigned long int " n ); +.BI "char * dcngettext (const char * " domainname , +.BI " const char * " msgid ", const char * " msgid_plural , +.BI " unsigned long int " n ", int " category ); +.fi +.SH DESCRIPTION +The \fBngettext\fP, \fBdngettext\fP and \fBdcngettext\fP functions attempt to +translate a text string into the user's native language, by looking up the +appropriate plural form of the translation in a message catalog. +.PP +Plural forms are grammatical variants depending on the a number. Some languages +have two forms, called singular and plural. Other languages have three forms, +called singular, dual and plural. There are also languages with four forms. +.PP +The \fBngettext\fP, \fBdngettext\fP and \fBdcngettext\fP functions work like +the \fBgettext\fP, \fBdgettext\fP and \fBdcgettext\fP functions, respectively. +Additionally, they choose the appropriate plural form, which depends on the +number \fIn\fP and the language of the message catalog where the translation +was found. +.PP +In the "C" locale, or if none of the used catalogs contain a translation for +\fImsgid\fP, the \fBngettext\fP, \fBdngettext\fP and \fBdcngettext\fP functions +return \fImsgid\fP if \fIn\fP == 1, or \fImsgid_plural\fP if \fIn\fP != 1. +.SH "RETURN VALUE" +If a translation was found in one of the specified catalogs, the appropriate +plural form is converted to the locale's codeset and returned. The resulting +string is statically allocated and must not be modified or freed. Otherwise +\fImsgid\fP or \fImsgid_plural\fP is returned, as described above. +.SH ERRORS +\fBerrno\fP is not modified. +.SH BUGS +The return type ought to be \fBconst char *\fP, but is \fBchar *\fP to avoid +warnings in C code predating ANSI C. +.SH "SEE ALSO" +.BR gettext (3), +.BR dgettext (3), +.BR dcgettext (3) diff --git a/man/ngettext.3.html b/man/ngettext.3.html new file mode 100644 index 000000000..11633f182 --- /dev/null +++ b/man/ngettext.3.html @@ -0,0 +1,130 @@ + + + + +NGETTEXT + + + +

NGETTEXT

+NAME
+SYNOPSIS
+DESCRIPTION
+RETURN VALUE
+ERRORS
+BUGS
+SEE ALSO
+ +
+ + + +

NAME

+ + +
+ngettext, dngettext, dcngettext - translate message and choose plural form
+ +

SYNOPSIS

+ + + +
+
#include <libintl.h>
+
+char * ngettext (const char * msgid, const char * msgid_plural,
+                 unsigned long int n);
+char * dngettext (const char * domainname,
+                  const char * msgid, const char * msgid_plural,
+                  unsigned long int n);
+char * dcngettext (const char * domainname,
+                   const char * msgid, const char * msgid_plural,
+                   unsigned long int n, int category);
+
+ +

DESCRIPTION

+ + + +
+The ngettext, dngettext and dcngettext +functions attempt to translate a text string into the user's +native language, by looking up the appropriate plural form +of the translation in a message catalog.
+ + + +
+Plural forms are grammatical variants depending on the a +number. Some languages have two forms, called singular and +plural. Other languages have three forms, called singular, +dual and plural. There are also languages with four +forms.
+ + + +
+The ngettext, dngettext and dcngettext +functions work like the gettext, dgettext and +dcgettext functions, respectively. Additionally, they +choose the appropriate plural form, which depends on the +number n and the language of the message catalog +where the translation was found.
+ + + +
+In the "C" locale, or if none of the used catalogs +contain a translation for msgid, the ngettext, +dngettext and dcngettext functions return +msgid if n == 1, or msgid_plural if +n != 1.
+ +

RETURN VALUE

+ + + +
+If a translation was found in one of the specified catalogs, +the appropriate plural form is converted to the locale's +codeset and returned. The resulting string is statically +allocated and must not be modified or freed. Otherwise +msgid or msgid_plural is returned, as +described above.
+ +

ERRORS

+ + + +
+errno is not modified.
+ +

BUGS

+ + + +
+The return type ought to be const char *, but is +char * to avoid warnings in C code predating ANSI +C.
+ +

SEE ALSO

+ + + +
+gettext(3), dgettext(3), +dcgettext(3)
+
+ + diff --git a/man/textdomain.3 b/man/textdomain.3 new file mode 100644 index 000000000..b87b50a16 --- /dev/null +++ b/man/textdomain.3 @@ -0,0 +1,57 @@ +.\" Copyright (c) Bruno Haible +.\" +.\" This is free documentation; you can redistribute it and/or +.\" modify it under the terms of the GNU General Public License as +.\" published by the Free Software Foundation; either version 2 of +.\" the License, or (at your option) any later version. +.\" +.\" References consulted: +.\" GNU glibc-2 source code and manual +.\" GNU gettext source code and manual +.\" LI18NUX 2000 Globalization Specification +.\" +.TH TEXTDOMAIN 3 "May 2001" "GNU gettext 0.10.38" +.SH NAME +textdomain \- set domain for future gettext() calls +.SH SYNOPSIS +.nf +.B #include +.sp +.BI "char * textdomain (const char * " domainname ); +.fi +.SH DESCRIPTION +The \fBtextdomain\fP function sets or retrieves the current message domain. +.PP +A message domain is a set of translatable \fImsgid\fP messages. Usually, +every software package has its own message domain. The domain name is used +to determine the message catalog where a translation is looked up; it must +be a non-empty string. +.PP +The current message domain is used by the \fBgettext\fP, \fBngettext\fP +functions, and by the \fBdgettext\fP, \fBdcgettext\fP, \fBdngettext\fP and +\fBdcngettext\fP functions when called with a NULL domainname argument. +.PP +If \fIdomainname\fP is not NULL, the current message domain is set to +\fIdomainname\fP. The string the function stores internally is a copy of the +\fIdomainname\fP argument. +.PP +If \fIdomainname\fP is NULL, the function returns the current message domain. +.SH "RETURN VALUE" +If successful, the \fBtextdomain\fP function returns the current message +domain, after possibly changing it. The resulting string is valid until the +next \fBtextdomain\fP call and must not be modified or freed. If a memory +allocation failure occurs, it sets \fBerrno\fP to \fBENOMEM\fP and returns +NULL. +.SH ERRORS +The following error can occur, among others: +.TP +.B ENOMEM +Not enough memory available. +.SH BUGS +The return type ought to be \fBconst char *\fP, but is \fBchar *\fP to avoid +warnings in C code predating ANSI C. +.SH "SEE ALSO" +.BR gettext (3), +.BR ngettext (3), +.BR bindtextdomain (3), +.BR bind_textdomain_codeset (3) diff --git a/man/textdomain.3.html b/man/textdomain.3.html new file mode 100644 index 000000000..47410becf --- /dev/null +++ b/man/textdomain.3.html @@ -0,0 +1,139 @@ + + + + +TEXTDOMAIN + + + +

TEXTDOMAIN

+NAME
+SYNOPSIS
+DESCRIPTION
+RETURN VALUE
+ERRORS
+BUGS
+SEE ALSO
+ +
+ + + +

NAME

+ + +
+textdomain - set domain for future gettext() calls
+ +

SYNOPSIS

+ + + +
+
#include <libintl.h>
+
+char * textdomain (const char * domainname);
+
+ +

DESCRIPTION

+ + + +
+The textdomain function sets or retrieves the current +message domain.
+ + + +
+A message domain is a set of translatable msgid +messages. Usually, every software package has its own +message domain. The domain name is used to determine the +message catalog where a translation is looked up; it must be +a non-empty string.
+ + + +
+The current message domain is used by the gettext, +ngettext functions, and by the dgettext, +dcgettext, dngettext and dcngettext +functions when called with a NULL domainname +argument.
+ + + +
+If domainname is not NULL, the current message domain +is set to domainname. The string the function stores +internally is a copy of the domainname +argument.
+ + + +
+If domainname is NULL, the function returns the +current message domain.
+ +

RETURN VALUE

+ + + +
+If successful, the textdomain function returns the +current message domain, after possibly changing it. The +resulting string is valid until the next textdomain +call and must not be modified or freed. If a memory +allocation failure occurs, it sets errno to +ENOMEM and returns NULL.
+ +

ERRORS

+ + + +
+The following error can occur, among others:
+ + + +
+ENOMEM
+ + + +
+Not enough memory available.
+ +

BUGS

+ + + +
+The return type ought to be const char *, but is +char * to avoid warnings in C code predating ANSI +C.
+ +

SEE ALSO

+ + + +
+gettext(3), ngettext(3), +bindtextdomain(3), +bind_textdomain_codeset(3)
+
+ + diff --git a/po/cs.gmo b/po/cs.gmo new file mode 100644 index 000000000..b1af555d6 Binary files /dev/null and b/po/cs.gmo differ diff --git a/po/et.gmo b/po/et.gmo new file mode 100644 index 000000000..dddea694b Binary files /dev/null and b/po/et.gmo differ diff --git a/po/gl.gmo b/po/gl.gmo new file mode 100644 index 000000000..4b7fa6d40 Binary files /dev/null and b/po/gl.gmo differ diff --git a/po/id.gmo b/po/id.gmo new file mode 100644 index 000000000..450f19b04 Binary files /dev/null and b/po/id.gmo differ diff --git a/po/it.gmo b/po/it.gmo new file mode 100644 index 000000000..7a91bf858 Binary files /dev/null and b/po/it.gmo differ diff --git a/po/ru.gmo b/po/ru.gmo new file mode 100644 index 000000000..f696a61fb Binary files /dev/null and b/po/ru.gmo differ diff --git a/po/zh.gmo b/po/zh.gmo new file mode 100644 index 000000000..176e8ee40 Binary files /dev/null and b/po/zh.gmo differ