Commit Graph

11 Commits

Author SHA1 Message Date
explorer c29ff9b310 a better method to truncate at // marks 2009-03-03 16:22:33 +00:00
explorer 31c448a301 Check for NULL return from strdup() 2009-03-03 15:42:43 +00:00
explorer 7c353a46b6 Ignore the magic // commands in iconv_open(). This was discussed on current-users about a month ago, and ignoring the options was the best suggestion. 2009-03-03 14:39:06 +00:00
christos 461a86f9bd merge christos-time_t 2009-01-11 02:45:45 +00:00
tnozaki 52ed7b035f Fixes PR lib/39662, shortcomings in LC_{MONETARY,NUMERIC,TIME,MESSAGES} db format.
ok'ed by core and releng.
(thanks for agc@, snj@ and i'm sorry for long time patience).

[libc]
- localeio.[ch] and lc*.[ch] in src/lib/libc/locale was replaced by
  new locale-db implementation using citrus_db backend,
  see src/lib/libc/citrus/citrus_lc_*.[ch].
- add citrus_bcs_strtou?l.c. don't use strtou?l locale implementation
  internally, because they're locale-aware function.
- add some stubs for multi-locale issue, see {current,global}_locale.c.
- remove some obsolete file, setrunelocale.c, ___runetype_mb.c.
- remove __savectype() from ctypeio.[ch].

[tools]
- mklocale(1): add new option ``-t'' that generates new style
  LC_{MONETARY,NUMERIC,TIME,MESSAGES} locale-db format.
- chrtbl(1): added ctypeio.[ch] for __savectype().

[locale-db]
- added en_US.US-ASCII locale.
- removed some shareable locale definition file:
    en_US.US-ASCII -> en_US.ISO8859-1, en_US.UTF-8
    zh_CN.eucCN -> zh_CN.GB18030
    and more...see src/share/locale/*/Makefile.
- remove obsoleted locale sr_YU, added new locale sr_ME, sr_RS.
- change locale name ja_JP.ISO2022-JP* -> ja_JP.ISO-2022-JP*
  for X11's locale.alias file alignments.
- fix regression test, wrong wcs?width(3), NAN/INF usage.

i tested release-build following arch:
  i386, amd64, hpc{mips,arm,sh}, sparc64, vax.

citrus_lc_*.[ch] also can read old-plain-text style locale-db.
so that backward compatibility is keeped, but lc*.[ch] can't read
new citrus_db'ed locale-db and localeio.c never check sanity,
so forward compatibility is broken ;-<

old mklocale(1) doesn't know -t option, so you have to rebuild toolchain.
2009-01-02 00:20:18 +00:00
christos 96b4176078 do the namespace protection properly; fixes the lint-library. 2006-11-03 20:16:28 +00:00
tshiozak 7204e681ae make sure to set errno to EINVAL if _citrus_iconv_open() returns ENOENT. 2005-04-25 13:42:04 +00:00
tshiozak f7d656a488 revert the last all changes related to iconv(3). 2004-08-02 13:38:21 +00:00
tshiozak ab8d4be7c6 make sure that the iconv(3) follows the POSIX specification;
change the 2nd argument from "const char ** restrict" to "char ** restrict".
2004-08-01 16:40:58 +00:00
tshiozak 58db2e99e2 add iconv_t cache.
- separate shared part and context part from iconv_t.
  - add cache of shared part.
and, bump shlib_version minor of i18n modules because iconv i/f is changed.
2003-07-01 09:42:15 +00:00
tshiozak ff5c3e6895 Citrus iconv support(4)
add iconv external I/F (iconv.h - iconv_open()/iconv()/iconv_close()) and
iconv(1) utility.
TODO:
  - bump libc minor.
  - add iconv data files.
  - create manpages: iconv_open(3)/iconv(3)/iconv_close(3)/iconv(1)/
    mkesdb(1)/mkcsmapper(1).
2003-06-27 05:21:49 +00:00