1*36ac495dSmrg /* Implementation of the dcgettext(3) function.
2*36ac495dSmrg Copyright (C) 1995-1999, 2000, 2001, 2002 Free Software Foundation, Inc.
3*36ac495dSmrg
4*36ac495dSmrg This program is free software; you can redistribute it and/or modify it
5*36ac495dSmrg under the terms of the GNU Library General Public License as published
6*36ac495dSmrg by the Free Software Foundation; either version 2, or (at your option)
7*36ac495dSmrg any later version.
8*36ac495dSmrg
9*36ac495dSmrg This program is distributed in the hope that it will be useful,
10*36ac495dSmrg but WITHOUT ANY WARRANTY; without even the implied warranty of
11*36ac495dSmrg MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12*36ac495dSmrg Library General Public License for more details.
13*36ac495dSmrg
14*36ac495dSmrg You should have received a copy of the GNU Library General Public
15*36ac495dSmrg License along with this program; if not, write to the Free Software
16*36ac495dSmrg Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301,
17*36ac495dSmrg USA. */
18*36ac495dSmrg
19*36ac495dSmrg #ifdef HAVE_CONFIG_H
20*36ac495dSmrg # include <config.h>
21*36ac495dSmrg #endif
22*36ac495dSmrg
23*36ac495dSmrg #include "gettextP.h"
24*36ac495dSmrg #ifdef _LIBC
25*36ac495dSmrg # include <libintl.h>
26*36ac495dSmrg #else
27*36ac495dSmrg # include "libgnuintl.h"
28*36ac495dSmrg #endif
29*36ac495dSmrg
30*36ac495dSmrg /* @@ end of prolog @@ */
31*36ac495dSmrg
32*36ac495dSmrg /* Names for the libintl functions are a problem. They must not clash
33*36ac495dSmrg with existing names and they should follow ANSI C. But this source
34*36ac495dSmrg code is also used in GNU C Library where the names have a __
35*36ac495dSmrg prefix. So we have to make a difference here. */
36*36ac495dSmrg #ifdef _LIBC
37*36ac495dSmrg # define DCGETTEXT __dcgettext
38*36ac495dSmrg # define DCIGETTEXT __dcigettext
39*36ac495dSmrg #else
40*36ac495dSmrg # define DCGETTEXT libintl_dcgettext
41*36ac495dSmrg # define DCIGETTEXT libintl_dcigettext
42*36ac495dSmrg #endif
43*36ac495dSmrg
44*36ac495dSmrg /* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
45*36ac495dSmrg locale. */
46*36ac495dSmrg char *
DCGETTEXT(domainname,msgid,category)47*36ac495dSmrg DCGETTEXT (domainname, msgid, category)
48*36ac495dSmrg const char *domainname;
49*36ac495dSmrg const char *msgid;
50*36ac495dSmrg int category;
51*36ac495dSmrg {
52*36ac495dSmrg return DCIGETTEXT (domainname, msgid, NULL, 0, 0, category);
53*36ac495dSmrg }
54*36ac495dSmrg
55*36ac495dSmrg #ifdef _LIBC
56*36ac495dSmrg /* Alias for function name in GNU C Library. */
57*36ac495dSmrg INTDEF(__dcgettext)
58*36ac495dSmrg weak_alias (__dcgettext, dcgettext);
59*36ac495dSmrg #endif
60