10Sstevel@tonic-gate /* 20Sstevel@tonic-gate * CDDL HEADER START 30Sstevel@tonic-gate * 40Sstevel@tonic-gate * The contents of this file are subject to the terms of the 5*6793Smuffin * Common Development and Distribution License (the "License"). 6*6793Smuffin * You may not use this file except in compliance with the License. 70Sstevel@tonic-gate * 80Sstevel@tonic-gate * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 90Sstevel@tonic-gate * or http://www.opensolaris.org/os/licensing. 100Sstevel@tonic-gate * See the License for the specific language governing permissions 110Sstevel@tonic-gate * and limitations under the License. 120Sstevel@tonic-gate * 130Sstevel@tonic-gate * When distributing Covered Code, include this CDDL HEADER in each 140Sstevel@tonic-gate * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 150Sstevel@tonic-gate * If applicable, add the following below this CDDL HEADER, with the 160Sstevel@tonic-gate * fields enclosed by brackets "[]" replaced with your own identifying 170Sstevel@tonic-gate * information: Portions Copyright [yyyy] [name of copyright owner] 180Sstevel@tonic-gate * 190Sstevel@tonic-gate * CDDL HEADER END 200Sstevel@tonic-gate */ 210Sstevel@tonic-gate /* 22*6793Smuffin * Copyright 2008 Sun Microsystems, Inc. All rights reserved. 230Sstevel@tonic-gate * Use is subject to license terms. 240Sstevel@tonic-gate */ 250Sstevel@tonic-gate 260Sstevel@tonic-gate 270Sstevel@tonic-gate #ifndef _LIBINTL_H 280Sstevel@tonic-gate #define _LIBINTL_H 290Sstevel@tonic-gate 300Sstevel@tonic-gate #pragma ident "%Z%%M% %I% %E% SMI" 310Sstevel@tonic-gate 320Sstevel@tonic-gate #include <sys/isa_defs.h> 330Sstevel@tonic-gate 340Sstevel@tonic-gate #ifdef __cplusplus 350Sstevel@tonic-gate extern "C" { 360Sstevel@tonic-gate #endif 370Sstevel@tonic-gate 380Sstevel@tonic-gate /* 390Sstevel@tonic-gate * wchar_t is a built-in type in standard C++ and as such is not 400Sstevel@tonic-gate * defined here when using standard C++. However, the GNU compiler 41376Swesolows * fixincludes utility nonetheless creates its own version of this 420Sstevel@tonic-gate * header for use by gcc and g++. In that version it adds a redundant 430Sstevel@tonic-gate * guard for __cplusplus. To avoid the creation of a gcc/g++ specific 440Sstevel@tonic-gate * header we need to include the following magic comment: 450Sstevel@tonic-gate * 460Sstevel@tonic-gate * we must use the C++ compiler's type 470Sstevel@tonic-gate * 480Sstevel@tonic-gate * The above comment should not be removed or changed until GNU 490Sstevel@tonic-gate * gcc/fixinc/inclhack.def is updated to bypass this header. 500Sstevel@tonic-gate */ 510Sstevel@tonic-gate #if !defined(__cplusplus) || (__cplusplus < 199711L && !defined(__GNUG__)) 520Sstevel@tonic-gate #ifndef _WCHAR_T 530Sstevel@tonic-gate #define _WCHAR_T 540Sstevel@tonic-gate #if defined(_LP64) 550Sstevel@tonic-gate typedef int wchar_t; 560Sstevel@tonic-gate #else 570Sstevel@tonic-gate typedef long wchar_t; 580Sstevel@tonic-gate #endif 590Sstevel@tonic-gate #endif /* !_WCHAR_T */ 600Sstevel@tonic-gate #endif /* !defined(__cplusplus) ... */ 610Sstevel@tonic-gate 620Sstevel@tonic-gate #define TEXTDOMAINMAX 256 630Sstevel@tonic-gate 64*6793Smuffin #define __GNU_GETTEXT_SUPPORTED_REVISION(m) \ 65*6793Smuffin ((((m) == 0) || ((m) == 1)) ? 1 : -1) 66*6793Smuffin 670Sstevel@tonic-gate #ifdef __STDC__ 680Sstevel@tonic-gate extern char *dcgettext(const char *, const char *, const int); 690Sstevel@tonic-gate extern char *dgettext(const char *, const char *); 700Sstevel@tonic-gate extern char *gettext(const char *); 710Sstevel@tonic-gate extern char *textdomain(const char *); 720Sstevel@tonic-gate extern char *bindtextdomain(const char *, const char *); 730Sstevel@tonic-gate 740Sstevel@tonic-gate /* 750Sstevel@tonic-gate * LI18NUX 2000 Globalization Specification Version 1.0 760Sstevel@tonic-gate * with Amendment 2 770Sstevel@tonic-gate */ 780Sstevel@tonic-gate extern char *dcngettext(const char *, const char *, 790Sstevel@tonic-gate const char *, unsigned long int, int); 800Sstevel@tonic-gate extern char *dngettext(const char *, const char *, 810Sstevel@tonic-gate const char *, unsigned long int); 820Sstevel@tonic-gate extern char *ngettext(const char *, const char *, unsigned long int); 830Sstevel@tonic-gate extern char *bind_textdomain_codeset(const char *, const char *); 840Sstevel@tonic-gate 850Sstevel@tonic-gate /* Word handling functions --- requires dynamic linking */ 860Sstevel@tonic-gate /* Warning: these are experimental and subject to change. */ 870Sstevel@tonic-gate extern int wdinit(void); 880Sstevel@tonic-gate extern int wdchkind(wchar_t); 890Sstevel@tonic-gate extern int wdbindf(wchar_t, wchar_t, int); 900Sstevel@tonic-gate extern wchar_t *wddelim(wchar_t, wchar_t, int); 910Sstevel@tonic-gate extern wchar_t mcfiller(void); 920Sstevel@tonic-gate extern int mcwrap(void); 930Sstevel@tonic-gate 940Sstevel@tonic-gate #else 950Sstevel@tonic-gate extern char *dcgettext(); 960Sstevel@tonic-gate extern char *dgettext(); 970Sstevel@tonic-gate extern char *gettext(); 980Sstevel@tonic-gate extern char *textdomain(); 990Sstevel@tonic-gate extern char *bindtextdomain(); 1000Sstevel@tonic-gate 1010Sstevel@tonic-gate /* 1020Sstevel@tonic-gate * LI18NUX 2000 Globalization Specification Version 1.0 1030Sstevel@tonic-gate * with Amendment 2 1040Sstevel@tonic-gate */ 1050Sstevel@tonic-gate extern char *dcngettext(); 1060Sstevel@tonic-gate extern char *dngettext(); 1070Sstevel@tonic-gate extern char *ngettext(); 1080Sstevel@tonic-gate extern char *bind_textdomain_codeset(); 1090Sstevel@tonic-gate 1100Sstevel@tonic-gate /* Word handling functions --- requires dynamic linking */ 1110Sstevel@tonic-gate /* Warning: these are experimental and subject to change. */ 1120Sstevel@tonic-gate extern int wdinit(); 1130Sstevel@tonic-gate extern int wdchkind(); 1140Sstevel@tonic-gate extern int wdbindf(); 1150Sstevel@tonic-gate extern wchar_t *wddelim(); 1160Sstevel@tonic-gate extern wchar_t mcfiller(); 1170Sstevel@tonic-gate extern int mcwrap(); 1180Sstevel@tonic-gate 1190Sstevel@tonic-gate #endif 1200Sstevel@tonic-gate 1210Sstevel@tonic-gate #ifdef __cplusplus 1220Sstevel@tonic-gate } 1230Sstevel@tonic-gate #endif 1240Sstevel@tonic-gate 1250Sstevel@tonic-gate #endif /* _LIBINTL_H */ 126