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