summaryrefslogtreecommitdiffstats
path: root/libintl
diff options
context:
space:
mode:
author"Steven J. Hill" <sjhill@realitydiluted.com>2006-02-25 04:03:33 +0000
committer"Steven J. Hill" <sjhill@realitydiluted.com>2006-02-25 04:03:33 +0000
commitcb6a88484ce0b5ffba2fe98a40e2d51f4af92eb8 (patch)
tree520f8e8d113184cfa7954ebd274564b8c255fa9a /libintl
parente4461be66e2655058aef358b00050bc70ac72861 (diff)
downloaduClibc-alpine-cb6a88484ce0b5ffba2fe98a40e2d51f4af92eb8.tar.bz2
uClibc-alpine-cb6a88484ce0b5ffba2fe98a40e2d51f4af92eb8.tar.xz
Merge from trunk. Going pretty good so far. Kind of. Okay, not really.
Diffstat (limited to 'libintl')
-rw-r--r--libintl/Makefile.in19
-rw-r--r--libintl/intl.c37
2 files changed, 23 insertions, 33 deletions
diff --git a/libintl/Makefile.in b/libintl/Makefile.in
index 0afd0504b..624fa0df8 100644
--- a/libintl/Makefile.in
+++ b/libintl/Makefile.in
@@ -1,7 +1,7 @@
# Makefile for uClibc
#
# Copyright (C) 2000 by Lineo, inc.
-# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+# Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
#
# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
#
@@ -25,7 +25,9 @@ libintl_OUT := $(top_builddir)libintl
libintl_MSRC := $(libintl_DIR)/intl.c
libintl_MOBJ := $(patsubst %.o,$(libintl_OUT)/%.o,$(MOBJ))
-libintl_DEF := $(patsubst %,-DL_%,$(subst .o,,$(notdir $(libintl_MOBJ))))
+ifneq ($(DOMULTI),n)
+CFLAGS-libintl += $(patsubst %,-DL_%,$(subst .o,,$(notdir $(libintl_MOBJ))))
+endif
ifeq ($(DOPIC),y)
libintl-a-y := $(libintl_MOBJ:.o=.os)
@@ -34,25 +36,32 @@ libintl-a-y := $(libintl_MOBJ)
endif
libintl-so-y := $(libintl_MOBJ:.o=.os)
-CFLAGS-multi-y := $(libintl_DEF)
-libintl-multi-y := $(libintl_MSRC)
-
lib-a-$(UCLIBC_HAS_GETTEXT_AWARENESS) += $(top_builddir)lib/libintl.a
lib-so-$(UCLIBC_HAS_GETTEXT_AWARENESS) += $(top_builddir)lib/libintl.so
objclean-y += libintl_clean
+ifeq ($(DOMULTI),n)
ifeq ($(DOPIC),y)
$(top_builddir)lib/libintl.so: $(top_builddir)lib/libintl.a $(libc)
else
$(top_builddir)lib/libintl.so: $(libintl_OUT)/libintl_so.a $(libc)
endif
$(call link.so,$(libintl_FULL_NAME),$(MAJOR_VERSION))
+else
+$(top_builddir)lib/libintl.so: $(libintl_OUT)/libintl.oS | $(libc)
+ $(call linkm.so,$(libintl_FULL_NAME),$(MAJOR_VERSION))
+endif
$(libintl_OUT)/libintl_so.a: $(libintl-so-y)
$(Q)$(RM) $@
$(do_strip)
$(do_ar)
+$(libintl_OUT)/libintl.oS: $(libintl_MSRC)
+ $(Q)$(RM) $@
+ $(compile-m)
+ $(do_t_strip)
+
$(top_builddir)lib/libintl.a: $(libintl-a-y)
$(Q)$(INSTALL) -d $(dir $@)
$(Q)$(RM) $@
diff --git a/libintl/intl.c b/libintl/intl.c
index 51765a99e..e42a999cb 100644
--- a/libintl/intl.c
+++ b/libintl/intl.c
@@ -1,18 +1,7 @@
-/* Copyright (C) 2003 Manuel Novoa III
+/* Copyright (C) 2003 Manuel Novoa III
+ * Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
*
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the Free
- * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
*/
/*
@@ -41,26 +30,22 @@ char *gettext(const char *msgid)
/**********************************************************************/
#ifdef L_dgettext
-char *__dgettext(const char *domainname,
+char *dgettext(const char *domainname,
const char *msgid)
{
return (char *) msgid;
}
-strong_alias(__dgettext, dgettext)
-
#endif
/**********************************************************************/
#ifdef L_dcgettext
-char *__dcgettext(const char *domainname,
+char *dcgettext(const char *domainname,
const char *msgid, int category)
{
return (char *) msgid;
}
-strong_alias(__dcgettext, dcgettext)
-
#endif
/**********************************************************************/
#ifdef L_ngettext
@@ -96,7 +81,7 @@ char *dcngettext(const char *domainname, const char *msgid1,
/**********************************************************************/
#ifdef L_textdomain
-char *__textdomain(const char *domainname)
+char *textdomain(const char *domainname)
{
static const char default_str[] = "messages";
@@ -107,13 +92,11 @@ char *__textdomain(const char *domainname)
return (char *) default_str;
}
-strong_alias(__textdomain, textdomain)
-
#endif
/**********************************************************************/
#ifdef L_bindtextdomain
-char *__bindtextdomain(const char *domainname, const char *dirname)
+char *bindtextdomain(const char *domainname, const char *dirname)
{
static const char dir[] = "/";
@@ -133,16 +116,13 @@ char *__bindtextdomain(const char *domainname, const char *dirname)
return (char *) dir;
}
-strong_alias(__bindtextdomain, bindtextdomain)
-
#endif
/**********************************************************************/
#ifdef L_bind_textdomain_codeset
/* Specify the character encoding in which the messages from the
DOMAINNAME message catalog will be returned. */
-char *bind_textdomain_codeset(const char *domainname,
- const char *codeset)
+char *bind_textdomain_codeset(const char *domainname, const char *codeset)
{
if (!domainname || !*domainname || codeset) {
__set_errno(EINVAL);
@@ -156,6 +136,7 @@ char *bind_textdomain_codeset(const char *domainname,
/* glibc-ism */
+const char *_nl_expand_alias(const char * name);
const char *_nl_expand_alias(const char * name)
{
return NULL; /* uClibc does not support locale aliases. */