about summary refs log tree commit diff
path: root/iconvdata
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1997-11-26 04:23:08 +0000
committerUlrich Drepper <drepper@redhat.com>1997-11-26 04:23:08 +0000
commitf4017d205738b913f1002433cde5d4b4e93fbd81 (patch)
tree078a2f6aab0f3faf7355b41e12d8a06be81663a2 /iconvdata
parente34b0f2902588bbbfaf55829692e32c3c7134b74 (diff)
downloadglibc-f4017d205738b913f1002433cde5d4b4e93fbd81.tar.gz
glibc-f4017d205738b913f1002433cde5d4b4e93fbd81.tar.xz
glibc-f4017d205738b913f1002433cde5d4b4e93fbd81.zip
1997-11-26 04:28  Ulrich Drepper  <drepper@cygnus.com>

	* eld/dl-profile.c (_dl_start_profile): Avoid FP calculation when
	computing s_scale.  Patch by a sun <asun@zoology.washington.edu>.

	* iconv/gconv_close.c: Correct freeing of descriptor data.
	* iconv/gconv_simple.c: Return correct error values for illegal or
	incomplete characters.

	* Makefile (iconvdata/%): Special goal to simplify iconvdata
	development.
	* iconvdata/Makefile: New file.
	* iconvdata/configure: Likewise.
	* iconvdata/extra-module.mk: Likewise.
	* iconvdata/gconv-modules: Likewise.
	* iconvdata/iso6937.c: Likewise.
	* iconvdata/iso8859-1.c: Likewise.
	* iconvdata/iso8859-10.c: Likewise.
	* iconvdata/iso8859-10.h: Likewise.
	* iconvdata/iso8859-2.c: Likewise.
	* iconvdata/iso8859-2.h: Likewise.
	* iconvdata/iso8859-3.c: Likewise.
	* iconvdata/iso8859-3.h: Likewise.
	* iconvdata/iso8859-4.c: Likewise.
	* iconvdata/iso8859-4.h: Likewise.
	* iconvdata/iso8859-5.c: Likewise.
	* iconvdata/iso8859-5.h: Likewise.
	* iconvdata/iso8859-6.c: Likewise.
	* iconvdata/iso8859-6.h: Likewise.
	* iconvdata/iso8859-7.c: Likewise.
	* iconvdata/iso8859-7.h: Likewise.
	* iconvdata/iso8859-8.c: Likewise.
	* iconvdata/iso8859-8.h: Likewise.
	* iconvdata/iso8859-9.c: Likewise.
	* iconvdata/iso8859-9.h: Likewise.
	* iconvdata/iso8859-generic.c: Likewise.
	* iconvdata/t61.c: Likewise.

	* string/Makefile (routines): Add strcasestr.
	* string/string.h: Add prototype for strcasestr.
	* sysdeps/generic/strcasestr.c: New file.
	* wcsmbs/mbrtowc.c: Simplify special case a bit.
	* wcsmbs/wcrtomb.c: Likewise.
	* wcsmbs/mbsnrtowcs.c: Correctly handle incomplete characters.
	* wcsmbs/wcsnrtombs.c: Likewise.
	* wcsmbs/mbsrtowcs.c: Make sure SRC argument is correct when
	partial character is read.
	* wcsmbs/wcsrtombs.c: Likewise.
	* wcsmbs/wmemrtombs.c: Likewise.
	* wcsmbs/wmemrtowcs.c: Likewise.

	* io/ftw.h: Include <sys/stat.h> instead of <bits/stat.h>.
	* login/pty.h: Include <sys/ioctl.h> instead og <bits/ioctl-types.h>.
	* sysdeps/i386/__longjmp.S: Define _SETJMP_H.
	* sysdeps/i386/elf/setjmp.S: Likewise.
	* sysdeps/unix/sysv/linux/kernel_termios.h: Do include
	<bits/termios.h>.

	* sysdeps/posix/mk-stdiolim.c: Output file with comment.
	* sysdeps/unix/sysv/linux/stdio_lim.h.in: Add comment.

	* sysdeps/unix/sysv/linux/sys/mman.h: Pretty print.
	* sysvipc/sys/ipc.h: Likewise.
	* sysvipc/sys/msg.h: Likewise.
	* sysvipc/sys/sem.h: Likewise.
	* sysvipc/sys/shm.h: Likewise.

	* sysdeps/alpha/bits/endian.h: Issue error message if the header is
	used directly.
	* sysdeps/alpha/bits/setjmp.h: Likewise.
	* sysdeps/alpha/fpu/bits/fenv.h: Likewise.
	* sysdeps/arm/bits/endian.h: Likewise.
	* sysdeps/arm/bits/setjmp.h: Likewise.
	* sysdeps/generic/bits/byteswap.h: Likewise.
	* sysdeps/generic/bits/confname.h: Likewise.
	* sysdeps/generic/bits/dirent.h: Likewise.
	* sysdeps/generic/bits/dlfcn.h: Likewise.
	* sysdeps/generic/bits/endian.h: Likewise.
	* sysdeps/generic/bits/fenv.h: Likewise.
	* sysdeps/generic/bits/huge_val.h: Likewise.
	* sysdeps/generic/bits/in.h: Likewise.
	* sysdeps/generic/bits/ioctl-types.h: Likewise.
	* sysdeps/generic/bits/ioctls.h: Likewise.
	* sysdeps/generic/bits/ipc.h: Likewise.
	* sysdeps/generic/bits/msq.h: Likewise.
	* sysdeps/generic/bits/poll.h: Likewise.
	* sysdeps/generic/bits/resource.h: Likewise.
	* sysdeps/generic/bits/sched.h: Likewise.
	* sysdeps/generic/bits/sem.h: Likewise.
	* sysdeps/generic/bits/setjmp.h: Likewise.
	* sysdeps/generic/bits/shm.h: Likewise.
	* sysdeps/generic/bits/sigaction.h: Likewise.
	* sysdeps/generic/bits/sigcontext.h: Likewise.
	* sysdeps/generic/bits/socket.h: Likewise.
	* sysdeps/generic/bits/stat.h: Likewise.
	* sysdeps/generic/bits/statfs.h: Likewise.
	* sysdeps/generic/bits/stdio_lim.h: Likewise.
	* sysdeps/generic/bits/termios.h: Likewise.
	* sysdeps/generic/bits/time.h: Likewise.
	* sysdeps/generic/bits/uio.h: Likewise.
	* sysdeps/generic/bits/utmp.h: Likewise.
	* sysdeps/generic/bits/utmpx.h: Likewise.
	* sysdeps/generic/bits/utsname.h: Likewise.
	* sysdeps/generic/bits/waitflags.h: Likewise.
	* sysdeps/generic/bits/waitstatus.h: Likewise.
	* sysdeps/gnu/bits/utmp.h: Likewise.
	* sysdeps/gnu/bits/utmpx.h: Likewise.
	* sysdeps/i386/bits/byteswap.h: Likewise.
	* sysdeps/i386/bits/endian.h: Likewise.
	* sysdeps/i386/bits/huge_val.h: Likewise.
	* sysdeps/i386/bits/setjmp.h: Likewise.
	* sysdeps/i386/fpu/bits/fenv.h: Likewise.
	* sysdeps/ieee754/bits/huge_val.h: Likewise.
	* sysdeps/m68k/bits/byteswap.h: Likewise.
	* sysdeps/m68k/bits/endian.h: Likewise.
	* sysdeps/m68k/bits/setjmp.h: Likewise.
	* sysdeps/m68k/fpu/bits/fenv.h: Likewise.
	* sysdeps/mach/hurd/alpha/bits/sigcontext.h: Likewise.
	* sysdeps/mach/hurd/bits/ioctls.h: Likewise.
	* sysdeps/mach/hurd/bits/stat.h: Likewise.
	* sysdeps/mach/hurd/hppa/bits/sigcontext.h: Likewise.
	* sysdeps/mach/hurd/i386/bits/sigcontext.h: Likewise.
	* sysdeps/mach/hurd/mips/bits/sigcontext.h: Likewise.
	* sysdeps/mips/bits/dlfcn.h: Likewise.
	* sysdeps/mips/bits/endian.h: Likewise.
	* sysdeps/mips/bits/setjmp.h: Likewise.
	* sysdeps/mips/dec/bits/endian.h: Likewise.
	* sysdeps/mips/mips64/bits/setjmp.h: Likewise.
	* sysdeps/mips/mipsel/bits/endian.h: Likewise.
	* sysdeps/mips/p40/bits/endian.h: Likewise.
	* sysdeps/powerpc/bits/endian.h: Likewise.
	* sysdeps/powerpc/bits/fenv.h: Likewise.
	* sysdeps/powerpc/bits/setjmp.h: Likewise.
	* sysdeps/sparc/sparc32/bits/endian.h: Likewise.
	* sysdeps/sparc/sparc32/bits/setjmp.h: Likewise.
	* sysdeps/sparc/sparc32/fpu/bits/fenv.h: Likewise.
	* sysdeps/sparc/sparc64/bits/endian.h: Likewise.
	* sysdeps/sparc/sparc64/fpu/bits/fenv.h: Likewise.
	* sysdeps/unix/bsd/bits/dirent.h: Likewise.
	* sysdeps/unix/bsd/bits/stat.h: Likewise.
	* sysdeps/unix/bsd/bits/waitflags.h: Likewise.
	* sysdeps/unix/bsd/bsd4.4/bits/dirent.h: Likewise.
	* sysdeps/unix/bsd/osf/alpha/bits/stat.h: Likewise.
	* sysdeps/unix/bsd/osf/bits/sigaction.h: Likewise.
	* sysdeps/unix/bsd/sun/m68k/bits/sigcontext.h: Likewise.
	* sysdeps/unix/bsd/sun/sparc/bits/sigcontext.h: Likewise.
	* sysdeps/unix/bsd/sun/sunos4/bits/resource.h: Likewise.
	* sysdeps/unix/bsd/sun/sunos4/bits/termios.h: Likewise.
	* sysdeps/unix/bsd/sun/sunos4/bits/utsname.h: Likewise.
	* sysdeps/unix/bsd/ultrix4/bits/utsname.h: Likewise.
	* sysdeps/unix/bsd/ultrix4/mips/bits/sigcontext.h: Likewise.
	* sysdeps/unix/common/bits/dirent.h: Likewise.
	* sysdeps/unix/sysv/bits/dirent.h: Likewise.
	* sysdeps/unix/sysv/bits/stat.h: Likewise.
	* sysdeps/unix/sysv/bits/utmp.h: Likewise.
	* sysdeps/unix/sysv/bits/utsname.h: Likewise.
	* sysdeps/unix/sysv/irix4/bits/confname.h: Likewise.
	* sysdeps/unix/sysv/irix4/bits/stat.h: Likewise.
	* sysdeps/unix/sysv/linux/alpha/bits/ioctls.h: Likewise.
	* sysdeps/unix/sysv/linux/alpha/bits/ipc.h: Likewise.
	* sysdeps/unix/sysv/linux/alpha/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/alpha/bits/sigaction.h: Likewise.
	* sysdeps/unix/sysv/linux/alpha/bits/stat.h: Likewise.
	* sysdeps/unix/sysv/linux/alpha/bits/termios.h: Likewise.
	* sysdeps/unix/sysv/linux/alpha/bits/time.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/dirent.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/in.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/ioctl-types.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/ioctls.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/ipc.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/msq.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/poll.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/resource.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/sched.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/sem.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/shm.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/sigaction.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/sigcontext.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/socket.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/stat.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/statfs.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/termios.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/time.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/uio.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/utsname.h: Likewise.
	* sysdeps/unix/sysv/linux/bits/waitflags.h: Likewise.
	* sysdeps/unix/sysv/linux/i386/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/m68k/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/m68k/bits/poll.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/endian.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/ioctl-types.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/ipc.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/poll.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/shm.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/sigaction.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/socket.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/stat.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/statfs.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/termios.h: Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/time.h: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/bits/ioctl-types.h: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/bits/termios.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/bits/ioctls.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/bits/poll.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/bits/sigaction.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/bits/termios.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/sparc32/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/sparc64/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/sparc64/bits/setjmp.h: Likewise.
	* sysdeps/unix/sysv/minix/bits/sigaction.h: Likewise.
	* sysdeps/unix/sysv/sco3.2.4/bits/confname.h: Likewise.
	* sysdeps/unix/sysv/sco3.2.4/bits/sigaction.h: Likewise.
	* sysdeps/unix/sysv/sysv4/bits/sigaction.h: Likewise.
	* sysdeps/unix/sysv/sysv4/bits/utsname.h: Likewise.
	* sysdeps/unix/sysv/sysv4/bits/waitflags.h: Likewise.
	* sysdeps/unix/sysv/sysv4/i386/bits/stat.h: Likewise.
	* sysdeps/unix/sysv/sysv4/solaris2/bits/stat.h: Likewise.
	* sysdeps/unix/sysv/sysv4/solaris2/sparc/bits/sigcontext.h: Likewise.
	* sysdeps/vax/bits/huge_val.h: Likewise.
	* sysdeps/vax/bits/setjmp.h: Likewise.
	* sysdeps/wordsize-32/bits/elfclass.h: Likewise.
	* sysdeps/wordsize-64/bits/elfclass.h: Likewise.

1997-11-25  Andreas Jaeger  <aj@arthur.rhein-neckar.de>

	* libio/stdio.h: Correct comment of sys_nerr/sys_errlist

1997-11-25  Paul Eggert  <eggert@shade.twinsun.com>

	* strftime.c (strftime):
	No longer any need to undef or declare if emacs is defined.
	(my_strftime): When checking a -1 returned by mktime, don't blow up
	if localtime_r returns NULL.

1997-11-24  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>

	* README.template: Fix spelling.

1997-11-25  Andreas Jaeger  <aj@arthur.rhein-neckar.de>

	* configure.in: Enhance --enable-add-ons description a wee bit.

1997-11-24  Andreas Jaeger  <aj@arthur.rhein-neckar.de>

	* glibcbug.in: Add more information of build environment and flags.

1997-11-23  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>

	* sysdeps/posix/getcwd.c: Recognize EOF from readdir and translate
	it into ENOENT.
Diffstat (limited to 'iconvdata')
-rw-r--r--iconvdata/Makefile119
-rwxr-xr-xiconvdata/configure5
-rw-r--r--iconvdata/extra-module.mk16
-rw-r--r--iconvdata/gconv-modules145
-rw-r--r--iconvdata/iso6937.c681
-rw-r--r--iconvdata/iso8859-1.c219
-rw-r--r--iconvdata/iso8859-10.c24
-rw-r--r--iconvdata/iso8859-10.h516
-rw-r--r--iconvdata/iso8859-2.c24
-rw-r--r--iconvdata/iso8859-2.h516
-rw-r--r--iconvdata/iso8859-3.c24
-rw-r--r--iconvdata/iso8859-3.h502
-rw-r--r--iconvdata/iso8859-4.c24
-rw-r--r--iconvdata/iso8859-4.h516
-rw-r--r--iconvdata/iso8859-5.c24
-rw-r--r--iconvdata/iso8859-5.h516
-rw-r--r--iconvdata/iso8859-6.c24
-rw-r--r--iconvdata/iso8859-6.h426
-rw-r--r--iconvdata/iso8859-7.c24
-rw-r--r--iconvdata/iso8859-7.h504
-rw-r--r--iconvdata/iso8859-8.c24
-rw-r--r--iconvdata/iso8859-8.h440
-rw-r--r--iconvdata/iso8859-9.c24
-rw-r--r--iconvdata/iso8859-9.h516
-rw-r--r--iconvdata/iso8859-generic.c228
-rw-r--r--iconvdata/t61.c630
26 files changed, 6711 insertions, 0 deletions
diff --git a/iconvdata/Makefile b/iconvdata/Makefile
new file mode 100644
index 0000000000..a79e12a291
--- /dev/null
+++ b/iconvdata/Makefile
@@ -0,0 +1,119 @@
+# Copyright (C) 1997 Free Software Foundation, Inc.
+# This file is part of the GNU C Library.
+
+# The GNU C 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.
+
+# The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If
+# not, write to the Free Software Foundation, Inc.,
+# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+#
+#	Makefile for iconv data and code.
+#
+subdir	:= iconvdata
+
+# Names of all the shared objects which implement the transformations.
+modules	:= ISO8859-1 ISO8859-2 ISO8859-3 ISO8859-4 ISO8859-5	\
+	   ISO8859-6 ISO8859-7 ISO8859-8 ISO8859-9 ISO8859-10	\
+	   T.61 ISO_6937
+modules.so := $(addsuffix .so, $(modules))
+
+
+ISO8859-1-routines := iso8859-1
+ISO8859-2-routines := iso8859-2
+ISO8859-3-routines := iso8859-3
+ISO8859-4-routines := iso8859-4
+ISO8859-5-routines := iso8859-5
+ISO8859-6-routines := iso8859-6
+ISO8859-7-routines := iso8859-7
+ISO8859-8-routines := iso8859-8
+ISO8859-9-routines := iso8859-9
+ISO8859-10-routines := iso8859-10
+T.61-routines := t61
+ISO_6937-routines := iso6937
+
+distribute := iso8859-generic.c \
+	      iso8859-1.c iso8859-2.c iso8859-3.c iso8859-4.c iso8859-5.c \
+	      iso8859-6.c iso8859-7.c iso8859-8.c iso8859-9.c iso8859-10.c\
+	      iso8859-2.h iso8859-3.h iso8859-4.h iso8859-5.h iso8859-6.h \
+	      iso8859-7.h iso8859-8.h iso8859-9.h iso8859-10.h t61.c	  \
+	      iso6937.c
+
+include ../Makeconfig
+
+# We build the transformation modules only when we build shared libs.
+ifeq (yes,$(build-shared))
+
+# This macro is similar to build-shlib but it does not define a soname
+# and it does not depend on the destination name to start with `lib'.
+define build-module
+$(LINK.o) -shared -o $@ $(sysdep-LDFLAGS) $(config-LDFLAGS)  \
+	  -B$(csu-objpfx) $(load-map-file:%=-Wl,--version-script=%) \
+	  $(LDFLAGS.so) $(LDFLAGS-$(@F:%.so=%).so) \
+	  -L$(subst :, -L,$(rpath-link)) -Wl,-rpath-link=$(rpath-link) \
+	  -Wl,--whole-archive \
+	  $(filter-out $($(@F:.so=)-map) $(+preinit) $(+postinit),$^) \
+	  $(no-whole-archive) $(LDLIBS-$(@F:%.so=%).so)
+endef
+
+# Rule to generate the shared objects.
+extra-modules-left := $(modules)
+include extra-module.mk
+
+
+extra-objs	+= $(modules.so)
+install-others	= $(addprefix $(inst_gconvdir)/, $(modules.so))	\
+		  $(inst_gconvdir)/gconv-modules
+
+# If we have the localedata add-on available we can build the conversion
+# tables for numerous charsets.
+ifneq (,$(findstring localedata,$(add-ons)))
+define generate-8bit-table
+( echo "static const wchar_t to_ucs4[256] = {"; \
+  sed -e 's/^[^[:space:]]*[[:space:]]*.x\(..\)[[:space:]]*<U\(....\)>.*/  [0x\1] = 0x\2,/p' -e d $^ | sort -u; \
+  echo "};"; \
+  echo "static const char from_ucs4[] = {"; \
+  sed -e 's/^[^[:space:]]*[[:space:]]*.x\(..\)[[:space:]]*<U\(....\)>.*/  [0x\2] = 0x\1,/p' -e d $^ | sort -u; \
+  echo "};" ) > $@.new && rm -f $@ && mv $@.new $@
+endef
+
+iso8859-2.h: ../localedata/charmaps/ISO-8859-2
+	$(generate-8bit-table)
+iso8859-3.h: ../localedata/charmaps/ISO-8859-3
+	$(generate-8bit-table)
+iso8859-4.h: ../localedata/charmaps/ISO-8859-4
+	$(generate-8bit-table)
+iso8859-5.h: ../localedata/charmaps/ISO-8859-5
+	$(generate-8bit-table)
+iso8859-6.h: ../localedata/charmaps/ISO-8859-6
+	$(generate-8bit-table)
+iso8859-7.h: ../localedata/charmaps/ISO-8859-7
+	$(generate-8bit-table)
+iso8859-8.h: ../localedata/charmaps/ISO-8859-8
+	$(generate-8bit-table)
+iso8859-9.h: ../localedata/charmaps/ISO-8859-9
+	$(generate-8bit-table)
+iso8859-10.h: ../localedata/charmaps/ISO-8859-10
+	$(generate-8bit-table)
+
+headers: iso8859-2.h iso8859-3.h iso8859-4.h iso8859-5.h iso8859-6.h	\
+	 iso8859-7.h iso8859-8.h iso8859-9.h iso8859-10.h
+endif
+
+
+$(addprefix $(inst_gconvdir)/, $(modules.so)): $(inst_gconvdir)/%: $(objpfx)%
+	$(do-install-program)
+$(inst_gconvdir)/gconv_modules: gconv-modules
+	$(do-install)
+endif
+
+include ../Rules
diff --git a/iconvdata/configure b/iconvdata/configure
new file mode 100755
index 0000000000..3eafc93f5b
--- /dev/null
+++ b/iconvdata/configure
@@ -0,0 +1,5 @@
+# This is only to keep the GNU C library configure mechanism happy.
+#
+# Perhaps some day we need a real configuration script for different
+# kernel versions or so.
+exit 0
diff --git a/iconvdata/extra-module.mk b/iconvdata/extra-module.mk
new file mode 100644
index 0000000000..88c68041a8
--- /dev/null
+++ b/iconvdata/extra-module.mk
@@ -0,0 +1,16 @@
+mod := $(firstword $(extra-modules-left))
+extra-modules-left := $(strip $(filter-out $(mod),$(extra-modules-left)))
+
+extra-objs += $(patsubst %,%.os,$($(mod)-routines))
+
+$(objpfx)$(mod).so: $(addprefix $(objpfx),$(addsuffix .os,$($(mod)-routines)))
+	$(build-module)
+
+# Depend on libc.so so a DT_NEEDED is generated in the shared objects.
+# This ensures they will load libc.so for needed symbols if loaded by
+# a statically-linked program that hasn't already loaded it.
+$(objpfx)$(mod).so: $(common-objpfx)libc.so
+
+ifneq (,$(extra-modules-left))
+include extra-module.mk
+endif
diff --git a/iconvdata/gconv-modules b/iconvdata/gconv-modules
new file mode 100644
index 0000000000..270ac14f11
--- /dev/null
+++ b/iconvdata/gconv-modules
@@ -0,0 +1,145 @@
+# GNU libc iconv configuration.
+# Copyright (C) 1997 Free Software Foundation, Inc.
+# This file is part of the GNU C Library.
+# Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+#
+# The GNU C 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.
+#
+# The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+# write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+# Boston, MA 02111-1307, USA.  */
+
+# All lines contain the following information:
+
+# If the lines start with `module'
+#  fromset:	either a name triple or a regular expression triple.
+#  toset:	a name triple or an expression with \N to get regular
+#		expression matching results.
+#  filename:	filename of the module implementing the transformation.
+#		If it is not absolute the path is made absolute by prepending
+#		the directory the configuration file is found in.
+#  cost:	optional cost of the transformation.  Default is 1.
+
+# If the lines start with `alias'
+#  alias:	alias name which is not really recognized.
+#  name:	the real name of the character set
+
+#	from			  to			  module	cost
+alias	ISO-10646//		ISO-10646/UCS4/
+alias	10646-1:1993//		ISO-10646/UCS4/
+alias	10646-1:1993/UCS4/	ISO-10646/UCS4/
+
+#	from			  to			  module	cost
+alias	ISO-IR-100//		ISO-8859-1//
+alias	ISO_8859-1:1987//	ISO-8859-1//
+alias	ISO_8859-1//		ISO-8859-1//
+alias	LATIN1//		ISO-8859-1//
+alias	L1//			ISO-8859-1//
+alias	IBM819//		ISO-8859-1//
+alias	CP819//			ISO-8859-1//
+module	ISO-8859-1//		ISO-10646/UCS4/		ISO8859-1	1
+module	ISO-10646/UCS4/		ISO-8859-1//		ISO8859-1	1
+
+#	from			  to			  module	cost
+alias	ISO-IR-101//		ISO-8859-2//
+alias	ISO_8859-2:1987//	ISO-8859-2//
+alias	ISO_8859-2//		ISO-8859-2//
+alias	LATIN2//		ISO-8859-2//
+alias	L2//			ISO-8859-2//
+module	ISO-8859-2//		ISO-10646/UCS4/		ISO8859-2	1
+module	ISO-10646/UCS4/		ISO-8859-2//		ISO8859-2	1
+
+#	from			  to			  module	cost
+alias	ISO-IR-109//		ISO-8859-3//
+alias	ISO_8859-3:1988//	ISO-8859-3//
+alias	ISO_8859-3//		ISO-8859-3//
+alias	LATIN3//		ISO-8859-3//
+alias	L3//			ISO-8859-3//
+module	ISO-8859-3//		ISO-10646/UCS4/		ISO8859-3	1
+module	ISO-10646/UCS4/		ISO-8859-3//		ISO8859-3	1
+
+#	from			  to			  module	cost
+alias	ISO-IR-110//		ISO-8859-4//
+alias	ISO_8859-4:1988//	ISO-8859-4//
+alias	ISO_8859-4//		ISO-8859-4//
+alias	LATIN4//		ISO-8859-4//
+alias	L4//			ISO-8859-4//
+module	ISO-8859-4//		ISO-10646/UCS4/		ISO8859-4	1
+module	ISO-10646/UCS4/		ISO-8859-4//		ISO8859-4	1
+
+#	from			  to			  module	cost
+alias	ISO-IR-144//		ISO-8859-5//
+alias	ISO_8859-5:1988//	ISO-8859-5//
+alias	ISO_8859-5//		ISO-8859-5//
+alias	CYRILLIC//		ISO-8859-5//
+module	ISO-8859-5//		ISO-10646/UCS4/		ISO8859-5	1
+module	ISO-10646/UCS4/		ISO-8859-5//		ISO8859-5	1
+
+#	from			  to			  module	cost
+alias	ISO-IR-127//		ISO-8859-6//
+alias	ISO_8859-6:1987//	ISO-8859-6//
+alias	ISO_8859-6//		ISO-8859-6//
+alias	ECMA-114//		ISO-8859-6//
+alias	ASMO-708//		ISO-8859-6//
+alias	ARABIC//		ISO-8859-6//
+module	ISO-8859-6//		ISO-10646/UCS4/		ISO8859-6	1
+module	ISO-10646/UCS4/		ISO-8859-6//		ISO8859-6	1
+
+#	from			  to			  module	cost
+alias	ISO-IR-126//		ISO-8859-7//
+alias	ISO_8859-7:1987//	ISO-8859-7//
+alias	ISO_8859-7//		ISO-8859-7//
+alias	ELOT_928//		ISO-8859-7//
+alias	ECMA-118//		ISO-8859-7//
+alias	GREEK//			ISO-8859-7//
+alias	GREEK8//		ISO-8859-7//
+module	ISO-8859-7//		ISO-10646/UCS4/		ISO8859-7	1
+module	ISO-10646/UCS4/		ISO-8859-7//		ISO8859-7	1
+
+#	from			  to			  module	cost
+alias	ISO-IR-138//		ISO-8859-8//
+alias	ISO_8859-8:1988//	ISO-8859-8//
+alias	ISO_8859-8//		ISO-8859-8//
+alias	HEBREW//		ISO-8859-8//
+module	ISO-8859-8//		ISO-10646/UCS4/		ISO8859-8	1
+module	ISO-10646/UCS4/		ISO-8859-8//		ISO8859-8	1
+
+#	from			  to			  module	cost
+alias	ISO-IR-148//		ISO-8859-9//
+alias	ISO_8859-9:1989//	ISO-8859-9//
+alias	ISO_8859-9//		ISO-8859-9//
+alias	LATIN5//		ISO-8859-9//
+alias	L5//			ISO-8859-9//
+module	ISO-8859-9//		ISO-10646/UCS4/		ISO8859-9	1
+module	ISO-10646/UCS4/		ISO-8859-9//		ISO8859-9	1
+
+#	from			  to			  module	cost
+alias	ISO-IR-157//		ISO-8859-10//
+alias	ISO_8859-10:1993//	ISO-8859-10//
+alias	ISO_8859-10//		ISO-8859-10//
+alias	LATIN6//		ISO-8859-10//
+alias	L6//			ISO-8859-10//
+module	ISO-8859-10//		ISO-10646/UCS4/		ISO8859-10	1
+module	ISO-10646/UCS4/		ISO-8859-10//		ISO8859-10	1
+
+#	from			  to			  module	cost
+alias	T.61//			T.61-8BIT//
+alias	ISO-IR-103//		T.61-8BIT//
+module	T.61-8BIT//		ISO-10646/UCS4/		T.61		1
+module	ISO-10646/UCS4/		T.61-8BIT//		T.61		1
+
+#	from			  to			  module	cost
+alias	ISO-IR-156//		ISO_6937//
+alias	ISO_6937:1992//		ISO_6937//
+alias	ISO6937//		ISO_6937//
+module	ISO_6937//		ISO-10646/UCS4/		ISO_6937	1
+module	ISO-10646/UCS4/		ISO_6937//		ISO_6937	1
diff --git a/iconvdata/iso6937.c b/iconvdata/iso6937.c
new file mode 100644
index 0000000000..dc6da3b347
--- /dev/null
+++ b/iconvdata/iso6937.c
@@ -0,0 +1,681 @@
+/* Generic conversion to and from ISO 6937.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <gconv.h>
+#include <stdlib.h>
+#include <string.h>
+
+/* Data taken from the WG15 tables.  */
+static const wchar_t to_ucs4[256] =
+{
+  /* 0x00 */ 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007,
+  /* 0x08 */ 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f,
+  /* 0x10 */ 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017,
+  /* 0x18 */ 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f,
+  /* 0x20 */ 0x0020, 0x0021, 0x0022, 0x0023, 0x0034, 0x0025, 0x0026, 0x0027,
+  /* 0x28 */ 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f,
+  /* 0x30 */ 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037,
+  /* 0x38 */ 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f,
+  /* 0x40 */ 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047,
+  /* 0x48 */ 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f,
+  /* 0x50 */ 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057,
+  /* 0x58 */ 0x0058, 0x0059, 0x005a, 0x005b, 0x005c, 0x005d, 0x005e, 0x005f,
+  /* 0x60 */ 0x0060, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067,
+  /* 0x68 */ 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f,
+  /* 0x70 */ 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077,
+  /* 0x78 */ 0x0078, 0x0079, 0x007a, 0x007b, 0x007c, 0x007d, 0x007e, 0x007f,
+  /* 0x80 */ 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087,
+  /* 0x88 */ 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f,
+  /* 0x90 */ 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097,
+  /* 0x98 */ 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f,
+  /* 0xa0 */ 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x0000, 0x00a5, 0x0000, 0x00a7,
+  /* 0xa8 */ 0x00a4, 0x2018, 0x201c, 0x00ab, 0x2190, 0x2191, 0x2192, 0x2193,
+  /* 0xb0 */ 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7,
+  /* 0xb8 */ 0x00f7, 0x2019, 0x201d, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf,
+  /* 0xc0 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+  /* 0xc8 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+  /* 0xd0 */ 0x2014, 0x00b9, 0x00ae, 0x00a9, 0x2122, 0x266a, 0x00ac, 0x00a6,
+  /* 0xd8 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x215b, 0x215c, 0x215d, 0x215e,
+  /* 0xe0 */ 0x2126, 0x00c6, 0x00d0, 0x00aa, 0x0126, 0x0000, 0x0132, 0x013f,
+  /* 0xe8 */ 0x0141, 0x00d8, 0x0152, 0x00ba, 0x00de, 0x0166, 0x014a, 0x0149,
+  /* 0xf0 */ 0x0138, 0x00e6, 0x0111, 0x00f0, 0x0127, 0x0131, 0x0133, 0x0140,
+  /* 0xf8 */ 0x0142, 0x00f8, 0x0153, 0x00df, 0x00fe, 0x0167, 0x014b, 0x00ad
+};
+
+/* The outer array range runs from 0xc1 to 0xcf, the inner range from 0x20
+   to 0x7f.  */
+static const wchar_t to_ucs4_comb[15][96] =
+{
+  /* 0xc1 */
+  {
+    /* 0x20 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c0, 0x0000, 0x0000, 0x0000, 0x00c8, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x00cc, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d2,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d9, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e0, 0x0000, 0x0000, 0x0000, 0x00e8, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x00ec, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f2,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f9, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc2 */
+  {
+    /* 0x20 */ 0x00b4, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c1, 0x0000, 0x0106, 0x0000, 0x00c9, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x00cd, 0x0000, 0x0000, 0x0139, 0x0000, 0x0143, 0x00d3,
+    /* 0x50 */ 0x0000, 0x0000, 0x0154, 0x015a, 0x0000, 0x00da, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x00dd, 0x0179, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e1, 0x0000, 0x0107, 0x0000, 0x00e9, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x00ed, 0x0000, 0x0000, 0x013a, 0x0000, 0x0144, 0x00f3,
+    /* 0x70 */ 0x0000, 0x0000, 0x0155, 0x015b, 0x0000, 0x00fa, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x00fd, 0x017a, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc3 */
+  {
+    /* 0x20 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c2, 0x0000, 0x0108, 0x0000, 0x00ca, 0x0000, 0x011c,
+    /* 0x48 */ 0x0124, 0x00ce, 0x0134, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d4,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x015c, 0x0000, 0x00db, 0x0000, 0x0174,
+    /* 0x58 */ 0x0000, 0x0176, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e2, 0x0000, 0x0109, 0x0000, 0x00ea, 0x0000, 0x011d,
+    /* 0x68 */ 0x0125, 0x00ee, 0x0135, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f4,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x015d, 0x0000, 0x00fb, 0x0000, 0x0175,
+    /* 0x78 */ 0x0000, 0x0177, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc4 */
+  {
+    /* 0x20 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c3, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x0128, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d1, 0x00d5,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0168, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e3, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x0129, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f1, 0x00f5,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0169, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc5 */
+  {
+    /* 0x20 */ 0x00af, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0100, 0x0000, 0x0000, 0x0000, 0x0112, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x012a, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x014c,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016a, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0101, 0x0000, 0x0000, 0x0000, 0x0113, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x012b, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x014d,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016b, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc6 */
+  {
+    /* 0x20 */ 0x02d8, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0102, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x011e,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016c, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0103, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x011f,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016d, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc7 */
+  {
+    /* 0x20 */ 0x02d9, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0000, 0x0000, 0x010a, 0x0000, 0x0116, 0x0000, 0x0120,
+    /* 0x48 */ 0x0000, 0x0130, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x017b, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0000, 0x0000, 0x010b, 0x0000, 0x0117, 0x0000, 0x0121,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x017c, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc8 */
+  {
+    /* 0x20 */ 0x00a8, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c4, 0x0000, 0x0000, 0x0000, 0x00cb, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x00cf, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d6,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00dc, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0178, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e4, 0x0000, 0x0000, 0x0000, 0x00eb, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x00ef, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f6,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00fc, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x00ff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc9 */
+  {
+    0x0000,
+  },
+  /* 0xca */
+  {
+    /* 0x20 */ 0x02da, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c5, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016e, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e5, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016f, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xcb */
+  {
+    /* 0x20 */ 0x00b8, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0000, 0x0000, 0x00c7, 0x0000, 0x0000, 0x0000, 0x0122,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0136, 0x013b, 0x0000, 0x0145, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0156, 0x015e, 0x0162, 0x0000, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0000, 0x0000, 0x00e7, 0x0000, 0x0000, 0x0000, 0x0123,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0137, 0x013c, 0x0000, 0x0146, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0157, 0x015f, 0x0163, 0x0000, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xcc */
+  {
+    0x0000,
+  },
+  /* 0xcd */
+  {
+    /* 0x20 */ 0x02dd, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0150,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0170, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0151,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0171, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xce */
+  {
+    /* 0x20 */ 0x02db, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0104, 0x0000, 0x0000, 0x0000, 0x0118, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x012e, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0172, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0105, 0x0000, 0x0000, 0x0000, 0x0119, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x012f, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0173, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xcf */
+  {
+    /* 0x20 */ 0x02c7, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0000, 0x0000, 0x010c, 0x010e, 0x011a, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x013d, 0x0000, 0x0147, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0158, 0x0160, 0x0164, 0x0000, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x017d, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0000, 0x0000, 0x010d, 0x010f, 0x011b, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x013e, 0x0000, 0x0148, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0159, 0x0161, 0x0165, 0x0000, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x017e, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  }
+};
+
+
+static const char from_ucs4[][2] =
+{
+  /* 0x0000 */ "\x00\x00", "\x01\x00", "\x02\x00", "\x03\x00", "\x04\x00",
+  /* 0x0005 */ "\x05\x00", "\x06\x00", "\x07\x00", "\x08\x00", "\x09\x00",
+  /* 0x000a */ "\x0a\x00", "\x0b\x00", "\x0c\x00", "\x0d\x00", "\x0e\x00",
+  /* 0x000f */ "\x0f\x00", "\x10\x00", "\x11\x00", "\x12\x00", "\x13\x00",
+  /* 0x0014 */ "\x14\x00", "\x15\x00", "\x16\x00", "\x17\x00", "\x18\x00",
+  /* 0x0019 */ "\x19\x00", "\x1a\x00", "\x1b\x00", "\x1c\x00", "\x1d\x00",
+  /* 0x001e */ "\x1e\x00", "\x1f\x00", "\x20\x00", "\x21\x00", "\x22\x00",
+  /* 0x0023 */ "\x23\x00", "\x24\x00", "\x25\x00", "\x26\x00", "\x27\x00",
+  /* 0x0028 */ "\x28\x00", "\x29\x00", "\x2a\x00", "\x2b\x00", "\x2c\x00",
+  /* 0x002d */ "\x2d\x00", "\x2e\x00", "\x2f\x00", "\x30\x00", "\x31\x00",
+  /* 0x0032 */ "\x32\x00", "\x33\x00", "\x34\x00", "\x35\x00", "\x36\x00",
+  /* 0x0037 */ "\x37\x00", "\x38\x00", "\x39\x00", "\x3a\x00", "\x3b\x00",
+  /* 0x003c */ "\x3c\x00", "\x3d\x00", "\x3e\x00", "\x3f\x00", "\x40\x00",
+  /* 0x0041 */ "\x41\x00", "\x42\x00", "\x43\x00", "\x44\x00", "\x45\x00",
+  /* 0x0046 */ "\x46\x00", "\x47\x00", "\x48\x00", "\x49\x00", "\x4a\x00",
+  /* 0x004b */ "\x4b\x00", "\x4c\x00", "\x4d\x00", "\x4e\x00", "\x4f\x00",
+  /* 0x0050 */ "\x50\x00", "\x51\x00", "\x52\x00", "\x53\x00", "\x54\x00",
+  /* 0x0055 */ "\x55\x00", "\x56\x00", "\x57\x00", "\x58\x00", "\x59\x00",
+  /* 0x005a */ "\x5a\x00", "\x5b\x00", "\x5c\x00", "\x5d\x00", "\x5e\x00",
+  /* 0x005f */ "\x5f\x00", "\x60\x00", "\x61\x00", "\x62\x00", "\x63\x00",
+  /* 0x0064 */ "\x64\x00", "\x65\x00", "\x66\x00", "\x67\x00", "\x68\x00",
+  /* 0x0069 */ "\x69\x00", "\x6a\x00", "\x6b\x00", "\x6c\x00", "\x6d\x00",
+  /* 0x006e */ "\x6e\x00", "\x6f\x00", "\x70\x00", "\x71\x00", "\x72\x00",
+  /* 0x0073 */ "\x73\x00", "\x74\x00", "\x75\x00", "\x76\x00", "\x77\x00",
+  /* 0x0078 */ "\x78\x00", "\x79\x00", "\x7a\x00", "\x7b\x00", "\x7c\x00",
+  /* 0x007d */ "\x7d\x00", "\x7e\x00", "\x7f\x00", "\x00\x80", "\x00\x81",
+  /* 0x0082 */ "\x82\x00", "\x83\x00", "\x84\x00", "\x85\x00", "\x86\x00",
+  /* 0x0087 */ "\x87\x00", "\x88\x00", "\x89\x00", "\x8a\x00", "\x8b\x00",
+  /* 0x008c */ "\x8c\x00", "\x8d\x00", "\x8e\x00", "\x8f\x00", "\x90\x00",
+  /* 0x0091 */ "\x91\x00", "\x92\x00", "\x93\x00", "\x94\x00", "\x95\x00",
+  /* 0x0096 */ "\x96\x00", "\x97\x00", "\x98\x00", "\x99\x00", "\x9a\x00",
+  /* 0x009b */ "\x9b\x00", "\x9c\x00", "\x9d\x00", "\x9e\x00", "\x9f\x00",
+  /* 0x00a0 */ "\xa0\x00", "\xa1\x00", "\xa2\x00", "\xa3\x00", "\xa4\x00",
+  /* 0x00a5 */ "\xa5\x00", "\xd7\x00", "\xa7\x00", "\xc8\x20", "\xd3\x00",
+  /* 0x00aa */ "\xe3\x00", "\xab\x00", "\xd6\x00", "\xff\x00", "\xd2\x00",
+  /* 0x00af */ "\xc5\x20", "\xb0\x00", "\xb1\x00", "\xb2\x00", "\xb3\x00",
+  /* 0x00b4 */ "\xc2\x20", "\xb5\x00", "\xb6\x00", "\xb7\x00", "\xcb\x20",
+  /* 0x00b9 */ "\xc1\x00", "\xeb\x00", "\xbb\x00", "\xbc\x00", "\xbd\x00",
+  /* 0x00be */ "\xbe\x00", "\xbf\x00", "\xc1\x41", "\xc2\x41", "\xc3\x41",
+  /* 0x00c3 */ "\xc4\x41", "\xc8\x41", "\xca\x41", "\xe1\x00", "\xcb\x43",
+  /* 0x00c8 */ "\xc1\x45", "\xc2\x45", "\xc3\x45", "\xc8\x45", "\xc1\x49",
+  /* 0x00cd */ "\xc2\x49", "\xc3\x49", "\xc8\x49", "\xe2\x00", "\xc4\x4e",
+  /* 0x00d2 */ "\xc1\x4f", "\xc2\x4f", "\xc3\x4f", "\xc4\x4f", "\xc8\x4f",
+  /* 0x00d7 */ "\xb4\x00", "\xe9\x00", "\xc1\x55", "\xc2\x55", "\xc3\x55",
+  /* 0x00dc */ "\xc8\x55", "\xc2\x59", "\xec\x00", "\xfb\x00", "\xc1\x61",
+  /* 0x00e1 */ "\xc2\x61", "\xc3\x61", "\xc4\x61", "\xc8\x61", "\xca\x61",
+  /* 0x00e6 */ "\xf1\x00", "\xcb\x63", "\xc1\x65", "\xc2\x65", "\xc3\x65",
+  /* 0x00eb */ "\xc8\x65", "\xc1\x69", "\xc2\xe9", "\xc3\x69", "\xc8\x69",
+  /* 0x00f0 */ "\xf3\x00", "\xc4\x6e", "\xc1\x6f", "\xc2\x6f", "\xc3\x6f",
+  /* 0x00f5 */ "\xc4\x6f", "\xc8\x6f", "\xb8\x00", "\xf9\x00", "\xc1\x75",
+  /* 0x00fa */ "\xc2\x75", "\xc3\x75", "\xc8\x75", "\xc2\x79", "\xfc\x00",
+  /* 0x00ff */ "\xc8\x79", "\xc5\x41", "\xc5\x61", "\xc6\x41", "\xc6\x61",
+  /* 0x0104 */ "\xce\x41", "\xce\x61", "\xc2\x43", "\xc2\x63", "\xc3\x43",
+  /* 0x0109 */ "\xc3\x63", "\xc7\x43", "\xc7\x63", "\xcf\x43", "\xcf\x63",
+  /* 0x010e */ "\xcf\x44", "\xcf\x64", "\x00\x00", "\xf2\x00", "\xc5\x45",
+  /* 0x0113 */ "\xc5\x65", "\x00\x00", "\x00\x00", "\xc7\x45", "\xc7\x65",
+  /* 0x0118 */ "\xce\x45", "\xce\x65", "\xcf\x45", "\xcf\x65", "\xc3\x47",
+  /* 0x011d */ "\xc3\x67", "\xc6\x47", "\xc6\x67", "\xc7\x47", "\xc7\x67",
+  /* 0x0122 */ "\xcb\x47", "\xcb\x67", "\xc3\x48", "\xc3\x68", "\xe4\x00",
+  /* 0x0127 */ "\xf4\x00", "\xc4\x49", "\xc4\x69", "\xc5\x49", "\xc5\x69",
+  /* 0x012c */ "\x00\x00", "\x00\x00", "\xce\x49", "\xce\x69", "\xc7\x49",
+  /* 0x0131 */ "\xf5\x00", "\xe6\x00", "\xf6\x00", "\xc3\x4a", "\xc3\x6a",
+  /* 0x0136 */ "\xcb\x4b", "\xcb\x6b", "\xf0\x00", "\xc2\x4c", "\xc2\x6c",
+  /* 0x013b */ "\xcb\x4c", "\xcb\x6c", "\xcf\x4c", "\xcf\x6c", "\xe7\x00",
+  /* 0x0140 */ "\xf7\x00", "\xe8\x00", "\xf8\x00", "\xc2\x4e", "\xc2\x6e",
+  /* 0x0145 */ "\xcb\x4e", "\xcb\x6e", "\xcf\x4e", "\xcf\x6e", "\xef\x00",
+  /* 0x014a */ "\xee\x00", "\xfe\x00", "\xc5\x4f", "\xc5\x6f", "\x00\x00",
+  /* 0x014f */ "\x00\x00", "\xcd\x4f", "\xcd\x6f", "\xea\x00", "\xfa\x00",
+  /* 0x0154 */ "\xc2\x52", "\xc2\x72", "\xcb\x52", "\xcb\x72", "\xcf\x52",
+  /* 0x0159 */ "\xcf\x72", "\xc2\x53", "\xc2\x73", "\xc3\x53", "\xc3\x73",
+  /* 0x015e */ "\xcb\x53", "\xcb\x73", "\xcf\x53", "\xcf\x73", "\xcb\x54",
+  /* 0x0163 */ "\xcb\x74", "\xcf\x54", "\xcf\x74", "\xed\x00", "\xfd\x00",
+  /* 0x0168 */ "\xc4\x55", "\xc4\x75", "\xc5\x55", "\xc5\x75", "\xc6\x55",
+  /* 0x016d */ "\xc6\x75", "\xca\x55", "\xca\x75", "\xcd\x55", "\xcd\x75",
+  /* 0x0172 */ "\xce\x55", "\xce\x75", "\xc3\x57", "\xc3\x77", "\xc3\x59",
+  /* 0x0177 */ "\xc3\x79", "\xc8\x59", "\xc2\x5a", "\xc2\x7a", "\xc7\x5a",
+  /* 0x017c */ "\xc7\x7a", "\xcf\x5a", "\xcf\x7a"
+/*
+   This table does not cover the following positions:
+
+     0x02c7    "\xcf\x20",
+     ...
+     0x02d8    "\xc6\x20", "\xc7\x20", "\xca\x20", "\xce\x20", "\x00\x00",
+     0x02dd    "\xcd\x20",
+     ...
+     0x2014    "\xd0\x00", "\x00\x00", "\x00\x00", "\x00\x00", "\xa9\x00",
+     0x2019    "\xb9\x00", "\x00\x00", "\x00\x00", "\xaa\x00", "\xba\x00",
+     0x201e    "\x00\x00", "\x00\x00", "\x00\x00", "\x00\x00", "\xd4\x00",
+     0x2123    "\x00\x00", "\x00\x00", "\x00\x00", "\xe0\x00", "\x00\x00",
+     ...
+     0x215b    "\xdc\x00", "\xdd\x00", "\xde\x00"
+     ...
+     0x2190    "\xac\x00", "\xad\x00", "\xae\x00", "\xaf\x00",
+     ...
+     0x266a    "\xd5\x00"
+
+   These would blow up the table and are therefore handled specially in
+   the code.
+*/
+};
+
+/* Direction of the transformation.  */
+enum direction
+{
+  illegal,
+  to_iso6937,
+  from_iso6937
+};
+
+struct iso6937_data
+{
+  enum direction dir;
+};
+
+
+int
+gconv_init (struct gconv_step *step, struct gconv_step_data *data)
+{
+  /* Determine which direction.  */
+  struct iso6937_data *new_data;
+  enum direction dir;
+  int result;
+
+  if (__strcasestr (step->from_name, "ISO_6937") != NULL)
+    dir = from_iso6937;
+  else if (__strcasestr (step->to_name, "ISO_6937") != NULL)
+    dir = to_iso6937;
+  else
+    dir = illegal;
+
+  result = GCONV_NOCONV;
+  if (dir != illegal
+      && ((new_data
+	   = (struct iso6937_data *) malloc (sizeof (struct iso6937_data)))
+	  != NULL))
+    {
+      new_data->dir = dir;
+      data->data = new_data;
+      result = GCONV_OK;
+    }
+
+  return result;
+}
+
+
+void
+gconv_end (struct gconv_step_data *data)
+{
+  free (data->data);
+}
+
+
+int
+gconv (struct gconv_step *step, struct gconv_step_data *data,
+       const char *inbuf, size_t *inbufsize, size_t *written, int do_flush)
+{
+  struct gconv_step *next_step = step + 1;
+  struct gconv_step_data *next_data = data + 1;
+  gconv_fct fct = next_step->fct;
+  size_t do_write;
+  int result;
+
+  /* If the function is called with no input this means we have to reset
+     to the initial state.  The possibly partly converted input is
+     dropped.  */
+  if (do_flush)
+    {
+      do_write = 0;
+
+      /* Call the steps down the chain if there are any.  */
+      if (data->is_last)
+	result = GCONV_OK;
+      else
+	{
+	  struct gconv_step *next_step = step + 1;
+	  struct gconv_step_data *next_data = data + 1;
+
+	  result = (*fct) (next_step, next_data, NULL, 0, written, 1);
+
+	  /* Clear output buffer.  */
+	  data->outbufavail = 0;
+	}
+    }
+  else
+    {
+      enum direction dir = ((struct iso6937_data *) data->data)->dir;
+
+      do_write = 0;
+
+      do
+	{
+	  result = GCONV_OK;
+
+	  if (dir == from_iso6937)
+	    {
+	      size_t inchars = *inbufsize;
+	      size_t outwchars = data->outbufavail;
+	      char *outbuf = data->outbuf;
+	      size_t cnt = 0;
+
+	      while (cnt < inchars
+		     && (outwchars + sizeof (wchar_t) <= data->outbufsize))
+		{
+		  int inchar = inbuf[cnt];
+		  wchar_t ch;
+
+		  if (inchar >= '\xc1' && inchar <= '\xcf')
+		    {
+		      /* Composed character.  First test whether the next
+			 character is also available.  */
+		      int inchar2;
+
+		      if (cnt + 1 >= inchars)
+			{
+			  /* The second character is not available.  Store
+			     the intermediate result.  */
+			  result = GCONV_INCOMPLETE_INPUT;
+			  break;
+			}
+
+		      inchar2 = inbuf[++cnt];
+
+		      if (inchar2 < '\x20' || inchar2 >= '\x80')
+			/* This is illegal.  */
+			ch = L'\0';
+		      else
+			ch = to_ucs4_comb[inchar - 0xc1][inchar2 - 0x20];
+		    }
+		  else
+		    ch = to_ucs4[inchar];
+
+		  if (ch == L'\0' && inbuf[cnt] != '\0')
+		    {
+		      /* This is an illegal character.  */
+		      result = GCONV_ILLEGAL_INPUT;
+		      break;
+		    }
+
+		  *((wchar_t *) (outbuf + outwchars)) = ch;
+		  ++do_write;
+		  outwchars += sizeof (wchar_t);
+		  ++cnt;
+		}
+	      *inbufsize -= cnt;
+	      data->outbufavail = outwchars;
+	    }
+	  else
+	    {
+	      size_t inwchars = *inbufsize;
+	      size_t outchars = data->outbufavail;
+	      char *outbuf = data->outbuf;
+	      size_t cnt = 0;
+	      int extra = 0;
+
+	      while (inwchars >= cnt + sizeof (wchar_t)
+		     && outchars < data->outbufsize)
+		{
+		  char tmp[2];
+		  int ch = *((wchar_t *) (inbuf + cnt));
+		  const char *cp;
+
+		  if (ch >= sizeof (from_ucs4) / sizeof (from_ucs4[0]))
+		    {
+		      int fail = 0;
+		      switch (ch)
+			{
+			case 0x2c7:
+			  cp = "\xcf\x20";
+			  break;
+			case 0x2d8 ... 0x2dd:
+			  {
+			    static const char map[5] = "\xc6\xc7\xca\xce\xcd";
+
+			    tmp[0] = map[ch - 0x2d8];
+			    tmp[1] = ' ';
+			    cp = tmp;
+			  }
+			  break;
+			case 0x2014:
+			  cp = "\xd0";
+			  break;
+			case 0x2018:
+			  cp = "\xa9";
+			  break;
+			case 0x2019:
+			  cp = "\xb9";
+			  break;
+			case 0x201c:
+			  cp = "\xaa";
+			  break;
+			case 0x201d:
+			  cp = "\xba";
+			  break;
+			case 0x2122:
+			  cp = "\xd4";
+			  break;
+			case 0x2126:
+			  cp = "\xe0";
+			  break;
+			case 0x215b ... 0x215e:
+			  tmp[0] = 0xdc + (ch - 0x215b);
+			  tmp[1] = '\0';
+			  cp = tmp;
+			  break;
+			case 0x2190 ... 0x2193:
+			  tmp[0] = 0xac + (ch - 0x2190);
+			  tmp[1] = '\0';
+			  cp = tmp;
+			  break;
+			case 0x266a:
+			  cp = "\xd5";
+			  break;
+			default:
+			  cp = NULL;
+			  fail = 1;
+			}
+
+		      if (fail)
+			/* Illegal characters.  */
+			break;
+		    }
+		  else if (ch < 0 || (from_ucs4[ch][0] == '\0' && ch != 0))
+		    break;
+		  else
+		    cp = from_ucs4[ch];
+
+		  outbuf[outchars] = cp[0];
+		  /* Now test for a possible second byte and write this
+		     if possible.  */
+		  if (cp[1] != '\0')
+		    {
+		      if (outchars + 1 >= data->outbufsize)
+			{
+			  /* The result does not fit into the buffer.  */
+			  extra = 1;
+			  break;
+			}
+		      outbuf[++outchars] = cp[1];
+		    }
+
+		  ++do_write;
+		  ++outchars;
+		  cnt += sizeof (wchar_t);
+		}
+	      *inbufsize -= cnt;
+	      data->outbufavail = outchars;
+
+	      if (outchars + extra < data->outbufsize)
+		{
+		  /* If there is still room in the output buffer something
+		     is wrong with the input.  */
+		  if (inwchars >= cnt + sizeof (wchar_t))
+		    {
+		      /* An error occurred.  */
+		      result = GCONV_ILLEGAL_INPUT;
+		      break;
+		    }
+		  if (inwchars != cnt)
+		    {
+		      /* There are some unprocessed bytes at the end of the
+			 input buffer.  */
+		      result = GCONV_INCOMPLETE_INPUT;
+		      break;
+		    }
+		}
+	    }
+
+	  if (result != GCONV_OK)
+	    break;
+
+	  if (data->is_last)
+	    {
+	      /* This is the last step.  */
+	      result = (*inbufsize > (dir == from_iso6937
+				      ? 0 : sizeof (wchar_t) - 1)
+			? GCONV_FULL_OUTPUT : GCONV_EMPTY_INPUT);
+	      break;
+	    }
+
+	  /* Status so far.  */
+	  result = GCONV_EMPTY_INPUT;
+
+	  if (data->outbufavail > 0)
+	    {
+	      /* Call the functions below in the chain.  */
+	      size_t newavail = data->outbufavail;
+
+	      result = (*fct) (next_step, next_data, data->outbuf, &newavail,
+			       written, 0);
+
+	      /* Correct the output buffer.  */
+	      if (newavail != data->outbufavail && newavail > 0)
+		{
+		  memmove (data->outbuf,
+			   &data->outbuf[data->outbufavail - newavail],
+			   newavail);
+		  data->outbufavail = newavail;
+		}
+	    }
+	}
+      while (*inbufsize > 0 && result == GCONV_EMPTY_INPUT);
+    }
+
+  if (written != NULL && data->is_last)
+    *written = do_write;
+
+  return result;
+}
diff --git a/iconvdata/iso8859-1.c b/iconvdata/iso8859-1.c
new file mode 100644
index 0000000000..94128fe72c
--- /dev/null
+++ b/iconvdata/iso8859-1.c
@@ -0,0 +1,219 @@
+/* Conversion to and from ISO 8859-1.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <gconv.h>
+#include <stdlib.h>
+#include <string.h>
+
+/* Direction of the transformation.  */
+enum direction
+{
+  illegal,
+  to_iso88591,
+  from_iso88591
+};
+
+struct iso88591_data
+{
+  enum direction dir;
+};
+
+
+int
+gconv_init (struct gconv_step *step, struct gconv_step_data *data)
+{
+  /* Determine which direction.  */
+  struct iso88591_data *new_data;
+  enum direction dir;
+  int result;
+
+  if (__strcasestr (step->from_name, "ISO-8859-1") != NULL)
+    dir = from_iso88591;
+  else if (__strcasestr (step->to_name, "ISO-8859-1") != NULL)
+    dir = to_iso88591;
+  else
+    dir = illegal;
+
+  result = GCONV_NOCONV;
+  if (dir != illegal
+      && ((new_data
+	   = (struct iso88591_data *) malloc (sizeof (struct iso88591_data)))
+	  != NULL))
+    {
+      new_data->dir = dir;
+      data->data = new_data;
+      result = GCONV_OK;
+    }
+
+  return result;
+}
+
+
+void
+gconv_end (struct gconv_step_data *data)
+{
+  free (data->data);
+}
+
+
+int
+gconv (struct gconv_step *step, struct gconv_step_data *data,
+       const char *inbuf, size_t *inbufsize, size_t *written, int do_flush)
+{
+  struct gconv_step *next_step = step + 1;
+  struct gconv_step_data *next_data = data + 1;
+  gconv_fct fct = next_step->fct;
+  size_t do_write;
+  int result;
+
+  /* If the function is called with no input this means we have to reset
+     to the initial state.  The possibly partly converted input is
+     dropped.  */
+  if (do_flush)
+    {
+      do_write = 0;
+
+      /* Call the steps down the chain if there are any.  */
+      if (data->is_last)
+	result = GCONV_OK;
+      else
+	{
+	  struct gconv_step *next_step = step + 1;
+	  struct gconv_step_data *next_data = data + 1;
+
+	  result = (*fct) (next_step, next_data, NULL, 0, written, 1);
+
+	  /* Clear output buffer.  */
+	  data->outbufavail = 0;
+	}
+    }
+  else
+    {
+      enum direction dir = ((struct iso88591_data *) data->data)->dir;
+
+      do_write = 0;
+
+      do
+	{
+	  result = GCONV_OK;
+
+	  if (dir == from_iso88591)
+	    {
+	      size_t inchars = *inbufsize;
+	      size_t outwchars = data->outbufavail;
+	      char *outbuf = data->outbuf;
+	      size_t cnt = 0;
+
+	      while (cnt < inchars
+		     && (outwchars + sizeof (wchar_t) <= data->outbufsize))
+		{
+		  *((wchar_t *) (outbuf + outwchars)) = inbuf[cnt];
+		  ++do_write;
+		  outwchars += sizeof (wchar_t);
+		  ++cnt;
+		}
+	      *inbufsize -= cnt;
+	      data->outbufavail = outwchars;
+	    }
+	  else
+	    {
+	      size_t inwchars = *inbufsize;
+	      size_t outchars = data->outbufavail;
+	      char *outbuf = data->outbuf;
+	      size_t cnt = 0;
+
+	      while (inwchars >= cnt + sizeof (wchar_t)
+		     && outchars < data->outbufsize)
+		{
+		  if (*((wchar_t *) (inbuf + cnt)) <= L'\377')
+		    outbuf[outchars] = *((wchar_t *) (inbuf + cnt));
+		  else
+		    /* Here is where the transliteration would enter the
+		       scene.  */
+		    break;
+
+		  ++do_write;
+		  ++outchars;
+		  cnt += sizeof (wchar_t);
+		}
+	      *inbufsize -= cnt;
+	      data->outbufavail = outchars;
+
+	      if (outchars < data->outbufsize)
+		{
+		  /* If there is still room in the output buffer something
+		     is wrong with the input.  */
+		  if (inwchars >= cnt + sizeof (wchar_t))
+		    {
+		      /* An error occurred.  */
+		      result = GCONV_ILLEGAL_INPUT;
+		      break;
+		    }
+		  if (inwchars != cnt)
+		    {
+		      /* There are some unprocessed bytes at the end of the
+			 input buffer.  */
+		      result = GCONV_INCOMPLETE_INPUT;
+		      break;
+		    }
+		}
+	    }
+
+	  if (result != GCONV_OK)
+	    break;
+
+	  if (data->is_last)
+	    {
+	      /* This is the last step.  */
+	      result = (*inbufsize > (dir == from_iso88591
+				      ? 0 : sizeof (wchar_t) - 1)
+			? GCONV_FULL_OUTPUT : GCONV_EMPTY_INPUT);
+	      break;
+	    }
+
+	  /* Status so far.  */
+	  result = GCONV_EMPTY_INPUT;
+
+	  if (data->outbufavail > 0)
+	    {
+	      /* Call the functions below in the chain.  */
+	      size_t newavail = data->outbufavail;
+
+	      result = (*fct) (next_step, next_data, data->outbuf, &newavail,
+			       written, 0);
+
+	      /* Correct the output buffer.  */
+	      if (newavail != data->outbufavail && newavail > 0)
+		{
+		  memmove (data->outbuf,
+			   &data->outbuf[data->outbufavail - newavail],
+			   newavail);
+		  data->outbufavail = newavail;
+		}
+	    }
+	}
+      while (*inbufsize > 0 && result == GCONV_EMPTY_INPUT);
+    }
+
+  if (written != NULL && data->is_last)
+    *written = do_write;
+
+  return result;
+}
diff --git a/iconvdata/iso8859-10.c b/iconvdata/iso8859-10.c
new file mode 100644
index 0000000000..5c81214597
--- /dev/null
+++ b/iconvdata/iso8859-10.c
@@ -0,0 +1,24 @@
+/* Conversion from and to ISO 8859-10.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <wchar.h>
+#include <iso8859-10.h>
+#define NAME "ISO-8859-10"
+#include <iso8859-generic.c>
diff --git a/iconvdata/iso8859-10.h b/iconvdata/iso8859-10.h
new file mode 100644
index 0000000000..04711c3274
--- /dev/null
+++ b/iconvdata/iso8859-10.h
@@ -0,0 +1,516 @@
+static const wchar_t to_ucs4[256] = {
+  [0x00] = 0x0000,
+  [0x01] = 0x0001,
+  [0x02] = 0x0002,
+  [0x03] = 0x0003,
+  [0x04] = 0x0004,
+  [0x05] = 0x0005,
+  [0x06] = 0x0006,
+  [0x07] = 0x0007,
+  [0x08] = 0x0008,
+  [0x09] = 0x0009,
+  [0x0A] = 0x000A,
+  [0x0B] = 0x000B,
+  [0x0C] = 0x000C,
+  [0x0D] = 0x000D,
+  [0x0E] = 0x000E,
+  [0x0F] = 0x000F,
+  [0x10] = 0x0010,
+  [0x11] = 0x0011,
+  [0x12] = 0x0012,
+  [0x13] = 0x0013,
+  [0x14] = 0x0014,
+  [0x15] = 0x0015,
+  [0x16] = 0x0016,
+  [0x17] = 0x0017,
+  [0x18] = 0x0018,
+  [0x19] = 0x0019,
+  [0x1A] = 0x001A,
+  [0x1B] = 0x001B,
+  [0x1C] = 0x001C,
+  [0x1D] = 0x001D,
+  [0x1E] = 0x001E,
+  [0x1F] = 0x001F,
+  [0x20] = 0x0020,
+  [0x21] = 0x0021,
+  [0x22] = 0x0022,
+  [0x23] = 0x0023,
+  [0x24] = 0x0024,
+  [0x25] = 0x0025,
+  [0x26] = 0x0026,
+  [0x27] = 0x0027,
+  [0x28] = 0x0028,
+  [0x29] = 0x0029,
+  [0x2A] = 0x002A,
+  [0x2B] = 0x002B,
+  [0x2C] = 0x002C,
+  [0x2D] = 0x002D,
+  [0x2E] = 0x002E,
+  [0x2F] = 0x002F,
+  [0x30] = 0x0030,
+  [0x31] = 0x0031,
+  [0x32] = 0x0032,
+  [0x33] = 0x0033,
+  [0x34] = 0x0034,
+  [0x35] = 0x0035,
+  [0x36] = 0x0036,
+  [0x37] = 0x0037,
+  [0x38] = 0x0038,
+  [0x39] = 0x0039,
+  [0x3A] = 0x003A,
+  [0x3B] = 0x003B,
+  [0x3C] = 0x003C,
+  [0x3D] = 0x003D,
+  [0x3E] = 0x003E,
+  [0x3F] = 0x003F,
+  [0x40] = 0x0040,
+  [0x41] = 0x0041,
+  [0x42] = 0x0042,
+  [0x43] = 0x0043,
+  [0x44] = 0x0044,
+  [0x45] = 0x0045,
+  [0x46] = 0x0046,
+  [0x47] = 0x0047,
+  [0x48] = 0x0048,
+  [0x49] = 0x0049,
+  [0x4A] = 0x004A,
+  [0x4B] = 0x004B,
+  [0x4C] = 0x004C,
+  [0x4D] = 0x004D,
+  [0x4E] = 0x004E,
+  [0x4F] = 0x004F,
+  [0x50] = 0x0050,
+  [0x51] = 0x0051,
+  [0x52] = 0x0052,
+  [0x53] = 0x0053,
+  [0x54] = 0x0054,
+  [0x55] = 0x0055,
+  [0x56] = 0x0056,
+  [0x57] = 0x0057,
+  [0x58] = 0x0058,
+  [0x59] = 0x0059,
+  [0x5A] = 0x005A,
+  [0x5B] = 0x005B,
+  [0x5C] = 0x005C,
+  [0x5D] = 0x005D,
+  [0x5E] = 0x005E,
+  [0x5F] = 0x005F,
+  [0x60] = 0x0060,
+  [0x61] = 0x0061,
+  [0x62] = 0x0062,
+  [0x63] = 0x0063,
+  [0x64] = 0x0064,
+  [0x65] = 0x0065,
+  [0x66] = 0x0066,
+  [0x67] = 0x0067,
+  [0x68] = 0x0068,
+  [0x69] = 0x0069,
+  [0x6A] = 0x006A,
+  [0x6B] = 0x006B,
+  [0x6C] = 0x006C,
+  [0x6D] = 0x006D,
+  [0x6E] = 0x006E,
+  [0x6F] = 0x006F,
+  [0x70] = 0x0070,
+  [0x71] = 0x0071,
+  [0x72] = 0x0072,
+  [0x73] = 0x0073,
+  [0x74] = 0x0074,
+  [0x75] = 0x0075,
+  [0x76] = 0x0076,
+  [0x77] = 0x0077,
+  [0x78] = 0x0078,
+  [0x79] = 0x0079,
+  [0x7A] = 0x007A,
+  [0x7B] = 0x007B,
+  [0x7C] = 0x007C,
+  [0x7D] = 0x007D,
+  [0x7E] = 0x007E,
+  [0x7F] = 0x007F,
+  [0x80] = 0x0080,
+  [0x81] = 0x0081,
+  [0x82] = 0x0082,
+  [0x83] = 0x0083,
+  [0x84] = 0x0084,
+  [0x85] = 0x0085,
+  [0x86] = 0x0086,
+  [0x87] = 0x0087,
+  [0x88] = 0x0088,
+  [0x89] = 0x0089,
+  [0x8A] = 0x008A,
+  [0x8B] = 0x008B,
+  [0x8C] = 0x008C,
+  [0x8D] = 0x008D,
+  [0x8E] = 0x008E,
+  [0x8F] = 0x008F,
+  [0x90] = 0x0090,
+  [0x91] = 0x0091,
+  [0x92] = 0x0092,
+  [0x93] = 0x0093,
+  [0x94] = 0x0094,
+  [0x95] = 0x0095,
+  [0x96] = 0x0096,
+  [0x97] = 0x0097,
+  [0x98] = 0x0098,
+  [0x99] = 0x0099,
+  [0x9A] = 0x009A,
+  [0x9B] = 0x009B,
+  [0x9C] = 0x009C,
+  [0x9D] = 0x009D,
+  [0x9E] = 0x009E,
+  [0x9F] = 0x009F,
+  [0xA0] = 0x00A0,
+  [0xA1] = 0x0104,
+  [0xA2] = 0x0112,
+  [0xA3] = 0x0122,
+  [0xA4] = 0x012A,
+  [0xA5] = 0x0128,
+  [0xA6] = 0x0136,
+  [0xA7] = 0x00A7,
+  [0xA8] = 0x013B,
+  [0xA9] = 0x0110,
+  [0xAA] = 0x0160,
+  [0xAB] = 0x0166,
+  [0xAC] = 0x017D,
+  [0xAD] = 0x00AD,
+  [0xAE] = 0x016A,
+  [0xAF] = 0x014A,
+  [0xB0] = 0x00B0,
+  [0xB1] = 0x0105,
+  [0xB2] = 0x0113,
+  [0xB3] = 0x0123,
+  [0xB4] = 0x012B,
+  [0xB5] = 0x0129,
+  [0xB6] = 0x0137,
+  [0xB7] = 0x00B7,
+  [0xB8] = 0x013C,
+  [0xB9] = 0x0111,
+  [0xBA] = 0x0161,
+  [0xBB] = 0x0167,
+  [0xBC] = 0x017E,
+  [0xBD] = 0x2014,
+  [0xBE] = 0x016B,
+  [0xBF] = 0x014B,
+  [0xC0] = 0x0100,
+  [0xC1] = 0x00C1,
+  [0xC2] = 0x00C2,
+  [0xC3] = 0x00C3,
+  [0xC4] = 0x00C4,
+  [0xC5] = 0x00C5,
+  [0xC6] = 0x00C6,
+  [0xC7] = 0x012E,
+  [0xC8] = 0x010C,
+  [0xC9] = 0x00C9,
+  [0xCA] = 0x0118,
+  [0xCB] = 0x00CB,
+  [0xCC] = 0x0116,
+  [0xCD] = 0x00CD,
+  [0xCE] = 0x00CE,
+  [0xCF] = 0x00CF,
+  [0xD0] = 0x00D0,
+  [0xD1] = 0x0145,
+  [0xD2] = 0x014C,
+  [0xD3] = 0x00D3,
+  [0xD4] = 0x00D4,
+  [0xD5] = 0x00D5,
+  [0xD6] = 0x00D6,
+  [0xD7] = 0x0168,
+  [0xD8] = 0x00D8,
+  [0xD9] = 0x0172,
+  [0xDA] = 0x00DA,
+  [0xDB] = 0x00DB,
+  [0xDC] = 0x00DC,
+  [0xDD] = 0x00DD,
+  [0xDE] = 0x00DE,
+  [0xDF] = 0x00DF,
+  [0xE0] = 0x0101,
+  [0xE1] = 0x00E1,
+  [0xE2] = 0x00E2,
+  [0xE3] = 0x00E3,
+  [0xE4] = 0x00E4,
+  [0xE5] = 0x00E5,
+  [0xE6] = 0x00E6,
+  [0xE7] = 0x012F,
+  [0xE8] = 0x010D,
+  [0xE9] = 0x00E9,
+  [0xEA] = 0x0119,
+  [0xEB] = 0x00EB,
+  [0xEC] = 0x0117,
+  [0xED] = 0x00ED,
+  [0xEE] = 0x00EE,
+  [0xEF] = 0x00EF,
+  [0xF0] = 0x00F0,
+  [0xF1] = 0x0146,
+  [0xF2] = 0x014D,
+  [0xF3] = 0x00F3,
+  [0xF4] = 0x00F4,
+  [0xF5] = 0x00F5,
+  [0xF6] = 0x00F6,
+  [0xF7] = 0x0169,
+  [0xF8] = 0x00F8,
+  [0xF9] = 0x0173,
+  [0xFA] = 0x00FA,
+  [0xFB] = 0x00FB,
+  [0xFC] = 0x00FC,
+  [0xFD] = 0x00FD,
+  [0xFE] = 0x00FE,
+  [0xFF] = 0x0138,
+};
+static const char from_ucs4[] = {
+  [0x0000] = 0x00,
+  [0x0001] = 0x01,
+  [0x0002] = 0x02,
+  [0x0003] = 0x03,
+  [0x0004] = 0x04,
+  [0x0005] = 0x05,
+  [0x0006] = 0x06,
+  [0x0007] = 0x07,
+  [0x0008] = 0x08,
+  [0x0009] = 0x09,
+  [0x000A] = 0x0A,
+  [0x000B] = 0x0B,
+  [0x000C] = 0x0C,
+  [0x000D] = 0x0D,
+  [0x000E] = 0x0E,
+  [0x000F] = 0x0F,
+  [0x0010] = 0x10,
+  [0x0011] = 0x11,
+  [0x0012] = 0x12,
+  [0x0013] = 0x13,
+  [0x0014] = 0x14,
+  [0x0015] = 0x15,
+  [0x0016] = 0x16,
+  [0x0017] = 0x17,
+  [0x0018] = 0x18,
+  [0x0019] = 0x19,
+  [0x001A] = 0x1A,
+  [0x001B] = 0x1B,
+  [0x001C] = 0x1C,
+  [0x001D] = 0x1D,
+  [0x001E] = 0x1E,
+  [0x001F] = 0x1F,
+  [0x0020] = 0x20,
+  [0x0021] = 0x21,
+  [0x0022] = 0x22,
+  [0x0023] = 0x23,
+  [0x0024] = 0x24,
+  [0x0025] = 0x25,
+  [0x0026] = 0x26,
+  [0x0027] = 0x27,
+  [0x0028] = 0x28,
+  [0x0029] = 0x29,
+  [0x002A] = 0x2A,
+  [0x002B] = 0x2B,
+  [0x002C] = 0x2C,
+  [0x002D] = 0x2D,
+  [0x002E] = 0x2E,
+  [0x002F] = 0x2F,
+  [0x0030] = 0x30,
+  [0x0031] = 0x31,
+  [0x0032] = 0x32,
+  [0x0033] = 0x33,
+  [0x0034] = 0x34,
+  [0x0035] = 0x35,
+  [0x0036] = 0x36,
+  [0x0037] = 0x37,
+  [0x0038] = 0x38,
+  [0x0039] = 0x39,
+  [0x003A] = 0x3A,
+  [0x003B] = 0x3B,
+  [0x003C] = 0x3C,
+  [0x003D] = 0x3D,
+  [0x003E] = 0x3E,
+  [0x003F] = 0x3F,
+  [0x0040] = 0x40,
+  [0x0041] = 0x41,
+  [0x0042] = 0x42,
+  [0x0043] = 0x43,
+  [0x0044] = 0x44,
+  [0x0045] = 0x45,
+  [0x0046] = 0x46,
+  [0x0047] = 0x47,
+  [0x0048] = 0x48,
+  [0x0049] = 0x49,
+  [0x004A] = 0x4A,
+  [0x004B] = 0x4B,
+  [0x004C] = 0x4C,
+  [0x004D] = 0x4D,
+  [0x004E] = 0x4E,
+  [0x004F] = 0x4F,
+  [0x0050] = 0x50,
+  [0x0051] = 0x51,
+  [0x0052] = 0x52,
+  [0x0053] = 0x53,
+  [0x0054] = 0x54,
+  [0x0055] = 0x55,
+  [0x0056] = 0x56,
+  [0x0057] = 0x57,
+  [0x0058] = 0x58,
+  [0x0059] = 0x59,
+  [0x005A] = 0x5A,
+  [0x005B] = 0x5B,
+  [0x005C] = 0x5C,
+  [0x005D] = 0x5D,
+  [0x005E] = 0x5E,
+  [0x005F] = 0x5F,
+  [0x0060] = 0x60,
+  [0x0061] = 0x61,
+  [0x0062] = 0x62,
+  [0x0063] = 0x63,
+  [0x0064] = 0x64,
+  [0x0065] = 0x65,
+  [0x0066] = 0x66,
+  [0x0067] = 0x67,
+  [0x0068] = 0x68,
+  [0x0069] = 0x69,
+  [0x006A] = 0x6A,
+  [0x006B] = 0x6B,
+  [0x006C] = 0x6C,
+  [0x006D] = 0x6D,
+  [0x006E] = 0x6E,
+  [0x006F] = 0x6F,
+  [0x0070] = 0x70,
+  [0x0071] = 0x71,
+  [0x0072] = 0x72,
+  [0x0073] = 0x73,
+  [0x0074] = 0x74,
+  [0x0075] = 0x75,
+  [0x0076] = 0x76,
+  [0x0077] = 0x77,
+  [0x0078] = 0x78,
+  [0x0079] = 0x79,
+  [0x007A] = 0x7A,
+  [0x007B] = 0x7B,
+  [0x007C] = 0x7C,
+  [0x007D] = 0x7D,
+  [0x007E] = 0x7E,
+  [0x007F] = 0x7F,
+  [0x0080] = 0x80,
+  [0x0081] = 0x81,
+  [0x0082] = 0x82,
+  [0x0083] = 0x83,
+  [0x0084] = 0x84,
+  [0x0085] = 0x85,
+  [0x0086] = 0x86,
+  [0x0087] = 0x87,
+  [0x0088] = 0x88,
+  [0x0089] = 0x89,
+  [0x008A] = 0x8A,
+  [0x008B] = 0x8B,
+  [0x008C] = 0x8C,
+  [0x008D] = 0x8D,
+  [0x008E] = 0x8E,
+  [0x008F] = 0x8F,
+  [0x0090] = 0x90,
+  [0x0091] = 0x91,
+  [0x0092] = 0x92,
+  [0x0093] = 0x93,
+  [0x0094] = 0x94,
+  [0x0095] = 0x95,
+  [0x0096] = 0x96,
+  [0x0097] = 0x97,
+  [0x0098] = 0x98,
+  [0x0099] = 0x99,
+  [0x009A] = 0x9A,
+  [0x009B] = 0x9B,
+  [0x009C] = 0x9C,
+  [0x009D] = 0x9D,
+  [0x009E] = 0x9E,
+  [0x009F] = 0x9F,
+  [0x00A0] = 0xA0,
+  [0x00A7] = 0xA7,
+  [0x00AD] = 0xAD,
+  [0x00B0] = 0xB0,
+  [0x00B7] = 0xB7,
+  [0x00C1] = 0xC1,
+  [0x00C2] = 0xC2,
+  [0x00C3] = 0xC3,
+  [0x00C4] = 0xC4,
+  [0x00C5] = 0xC5,
+  [0x00C6] = 0xC6,
+  [0x00C9] = 0xC9,
+  [0x00CB] = 0xCB,
+  [0x00CD] = 0xCD,
+  [0x00CE] = 0xCE,
+  [0x00CF] = 0xCF,
+  [0x00D0] = 0xD0,
+  [0x00D3] = 0xD3,
+  [0x00D4] = 0xD4,
+  [0x00D5] = 0xD5,
+  [0x00D6] = 0xD6,
+  [0x00D8] = 0xD8,
+  [0x00DA] = 0xDA,
+  [0x00DB] = 0xDB,
+  [0x00DC] = 0xDC,
+  [0x00DD] = 0xDD,
+  [0x00DE] = 0xDE,
+  [0x00DF] = 0xDF,
+  [0x00E1] = 0xE1,
+  [0x00E2] = 0xE2,
+  [0x00E3] = 0xE3,
+  [0x00E4] = 0xE4,
+  [0x00E5] = 0xE5,
+  [0x00E6] = 0xE6,
+  [0x00E9] = 0xE9,
+  [0x00EB] = 0xEB,
+  [0x00ED] = 0xED,
+  [0x00EE] = 0xEE,
+  [0x00EF] = 0xEF,
+  [0x00F0] = 0xF0,
+  [0x00F3] = 0xF3,
+  [0x00F4] = 0xF4,
+  [0x00F5] = 0xF5,
+  [0x00F6] = 0xF6,
+  [0x00F8] = 0xF8,
+  [0x00FA] = 0xFA,
+  [0x00FB] = 0xFB,
+  [0x00FC] = 0xFC,
+  [0x00FD] = 0xFD,
+  [0x00FE] = 0xFE,
+  [0x0100] = 0xC0,
+  [0x0101] = 0xE0,
+  [0x0104] = 0xA1,
+  [0x0105] = 0xB1,
+  [0x010C] = 0xC8,
+  [0x010D] = 0xE8,
+  [0x0110] = 0xA9,
+  [0x0111] = 0xB9,
+  [0x0112] = 0xA2,
+  [0x0113] = 0xB2,
+  [0x0116] = 0xCC,
+  [0x0117] = 0xEC,
+  [0x0118] = 0xCA,
+  [0x0119] = 0xEA,
+  [0x0122] = 0xA3,
+  [0x0123] = 0xB3,
+  [0x0128] = 0xA5,
+  [0x0129] = 0xB5,
+  [0x012A] = 0xA4,
+  [0x012B] = 0xB4,
+  [0x012E] = 0xC7,
+  [0x012F] = 0xE7,
+  [0x0136] = 0xA6,
+  [0x0137] = 0xB6,
+  [0x0138] = 0xFF,
+  [0x013B] = 0xA8,
+  [0x013C] = 0xB8,
+  [0x0145] = 0xD1,
+  [0x0146] = 0xF1,
+  [0x014A] = 0xAF,
+  [0x014B] = 0xBF,
+  [0x014C] = 0xD2,
+  [0x014D] = 0xF2,
+  [0x0160] = 0xAA,
+  [0x0161] = 0xBA,
+  [0x0166] = 0xAB,
+  [0x0167] = 0xBB,
+  [0x0168] = 0xD7,
+  [0x0169] = 0xF7,
+  [0x016A] = 0xAE,
+  [0x016B] = 0xBE,
+  [0x0172] = 0xD9,
+  [0x0173] = 0xF9,
+  [0x017D] = 0xAC,
+  [0x017E] = 0xBC,
+  [0x2014] = 0xBD,
+};
diff --git a/iconvdata/iso8859-2.c b/iconvdata/iso8859-2.c
new file mode 100644
index 0000000000..3bfc77b894
--- /dev/null
+++ b/iconvdata/iso8859-2.c
@@ -0,0 +1,24 @@
+/* Conversion from and to ISO 8859-2.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <wchar.h>
+#include <iso8859-2.h>
+#define NAME "ISO-8859-2"
+#include <iso8859-generic.c>
diff --git a/iconvdata/iso8859-2.h b/iconvdata/iso8859-2.h
new file mode 100644
index 0000000000..515d8490d6
--- /dev/null
+++ b/iconvdata/iso8859-2.h
@@ -0,0 +1,516 @@
+static const wchar_t to_ucs4[256] = {
+  [0x00] = 0x0000,
+  [0x01] = 0x0001,
+  [0x02] = 0x0002,
+  [0x03] = 0x0003,
+  [0x04] = 0x0004,
+  [0x05] = 0x0005,
+  [0x06] = 0x0006,
+  [0x07] = 0x0007,
+  [0x08] = 0x0008,
+  [0x09] = 0x0009,
+  [0x0A] = 0x000A,
+  [0x0B] = 0x000B,
+  [0x0C] = 0x000C,
+  [0x0D] = 0x000D,
+  [0x0E] = 0x000E,
+  [0x0F] = 0x000F,
+  [0x10] = 0x0010,
+  [0x11] = 0x0011,
+  [0x12] = 0x0012,
+  [0x13] = 0x0013,
+  [0x14] = 0x0014,
+  [0x15] = 0x0015,
+  [0x16] = 0x0016,
+  [0x17] = 0x0017,
+  [0x18] = 0x0018,
+  [0x19] = 0x0019,
+  [0x1A] = 0x001A,
+  [0x1B] = 0x001B,
+  [0x1C] = 0x001C,
+  [0x1D] = 0x001D,
+  [0x1E] = 0x001E,
+  [0x1F] = 0x001F,
+  [0x20] = 0x0020,
+  [0x21] = 0x0021,
+  [0x22] = 0x0022,
+  [0x23] = 0x0023,
+  [0x24] = 0x0024,
+  [0x25] = 0x0025,
+  [0x26] = 0x0026,
+  [0x27] = 0x0027,
+  [0x28] = 0x0028,
+  [0x29] = 0x0029,
+  [0x2A] = 0x002A,
+  [0x2B] = 0x002B,
+  [0x2C] = 0x002C,
+  [0x2D] = 0x002D,
+  [0x2E] = 0x002E,
+  [0x2F] = 0x002F,
+  [0x30] = 0x0030,
+  [0x31] = 0x0031,
+  [0x32] = 0x0032,
+  [0x33] = 0x0033,
+  [0x34] = 0x0034,
+  [0x35] = 0x0035,
+  [0x36] = 0x0036,
+  [0x37] = 0x0037,
+  [0x38] = 0x0038,
+  [0x39] = 0x0039,
+  [0x3A] = 0x003A,
+  [0x3B] = 0x003B,
+  [0x3C] = 0x003C,
+  [0x3D] = 0x003D,
+  [0x3E] = 0x003E,
+  [0x3F] = 0x003F,
+  [0x40] = 0x0040,
+  [0x41] = 0x0041,
+  [0x42] = 0x0042,
+  [0x43] = 0x0043,
+  [0x44] = 0x0044,
+  [0x45] = 0x0045,
+  [0x46] = 0x0046,
+  [0x47] = 0x0047,
+  [0x48] = 0x0048,
+  [0x49] = 0x0049,
+  [0x4A] = 0x004A,
+  [0x4B] = 0x004B,
+  [0x4C] = 0x004C,
+  [0x4D] = 0x004D,
+  [0x4E] = 0x004E,
+  [0x4F] = 0x004F,
+  [0x50] = 0x0050,
+  [0x51] = 0x0051,
+  [0x52] = 0x0052,
+  [0x53] = 0x0053,
+  [0x54] = 0x0054,
+  [0x55] = 0x0055,
+  [0x56] = 0x0056,
+  [0x57] = 0x0057,
+  [0x58] = 0x0058,
+  [0x59] = 0x0059,
+  [0x5A] = 0x005A,
+  [0x5B] = 0x005B,
+  [0x5C] = 0x005C,
+  [0x5D] = 0x005D,
+  [0x5E] = 0x005E,
+  [0x5F] = 0x005F,
+  [0x60] = 0x0060,
+  [0x61] = 0x0061,
+  [0x62] = 0x0062,
+  [0x63] = 0x0063,
+  [0x64] = 0x0064,
+  [0x65] = 0x0065,
+  [0x66] = 0x0066,
+  [0x67] = 0x0067,
+  [0x68] = 0x0068,
+  [0x69] = 0x0069,
+  [0x6A] = 0x006A,
+  [0x6B] = 0x006B,
+  [0x6C] = 0x006C,
+  [0x6D] = 0x006D,
+  [0x6E] = 0x006E,
+  [0x6F] = 0x006F,
+  [0x70] = 0x0070,
+  [0x71] = 0x0071,
+  [0x72] = 0x0072,
+  [0x73] = 0x0073,
+  [0x74] = 0x0074,
+  [0x75] = 0x0075,
+  [0x76] = 0x0076,
+  [0x77] = 0x0077,
+  [0x78] = 0x0078,
+  [0x79] = 0x0079,
+  [0x7A] = 0x007A,
+  [0x7B] = 0x007B,
+  [0x7C] = 0x007C,
+  [0x7D] = 0x007D,
+  [0x7E] = 0x007E,
+  [0x7F] = 0x007F,
+  [0x80] = 0x0080,
+  [0x81] = 0x0081,
+  [0x82] = 0x0082,
+  [0x83] = 0x0083,
+  [0x84] = 0x0084,
+  [0x85] = 0x0085,
+  [0x86] = 0x0086,
+  [0x87] = 0x0087,
+  [0x88] = 0x0088,
+  [0x89] = 0x0089,
+  [0x8A] = 0x008A,
+  [0x8B] = 0x008B,
+  [0x8C] = 0x008C,
+  [0x8D] = 0x008D,
+  [0x8E] = 0x008E,
+  [0x8F] = 0x008F,
+  [0x90] = 0x0090,
+  [0x91] = 0x0091,
+  [0x92] = 0x0092,
+  [0x93] = 0x0093,
+  [0x94] = 0x0094,
+  [0x95] = 0x0095,
+  [0x96] = 0x0096,
+  [0x97] = 0x0097,
+  [0x98] = 0x0098,
+  [0x99] = 0x0099,
+  [0x9A] = 0x009A,
+  [0x9B] = 0x009B,
+  [0x9C] = 0x009C,
+  [0x9D] = 0x009D,
+  [0x9E] = 0x009E,
+  [0x9F] = 0x009F,
+  [0xA0] = 0x00A0,
+  [0xA1] = 0x0104,
+  [0xA2] = 0x02D8,
+  [0xA3] = 0x0141,
+  [0xA4] = 0x00A4,
+  [0xA5] = 0x013D,
+  [0xA6] = 0x015A,
+  [0xA7] = 0x00A7,
+  [0xA8] = 0x00A8,
+  [0xA9] = 0x0160,
+  [0xAA] = 0x015E,
+  [0xAB] = 0x0164,
+  [0xAC] = 0x0179,
+  [0xAD] = 0x00AD,
+  [0xAE] = 0x017D,
+  [0xAF] = 0x017B,
+  [0xB0] = 0x00B0,
+  [0xB1] = 0x0105,
+  [0xB2] = 0x02DB,
+  [0xB3] = 0x0142,
+  [0xB4] = 0x00B4,
+  [0xB5] = 0x013E,
+  [0xB6] = 0x015B,
+  [0xB7] = 0x02C7,
+  [0xB8] = 0x00B8,
+  [0xB9] = 0x0161,
+  [0xBA] = 0x015F,
+  [0xBB] = 0x0165,
+  [0xBC] = 0x017A,
+  [0xBD] = 0x02DD,
+  [0xBE] = 0x017E,
+  [0xBF] = 0x017C,
+  [0xC0] = 0x0154,
+  [0xC1] = 0x00C1,
+  [0xC2] = 0x00C2,
+  [0xC3] = 0x0102,
+  [0xC4] = 0x00C4,
+  [0xC5] = 0x0139,
+  [0xC6] = 0x0106,
+  [0xC7] = 0x00C7,
+  [0xC8] = 0x010C,
+  [0xC9] = 0x00C9,
+  [0xCA] = 0x0118,
+  [0xCB] = 0x00CB,
+  [0xCC] = 0x011A,
+  [0xCD] = 0x00CD,
+  [0xCE] = 0x00CE,
+  [0xCF] = 0x010E,
+  [0xD0] = 0x0110,
+  [0xD1] = 0x0143,
+  [0xD2] = 0x0147,
+  [0xD3] = 0x00D3,
+  [0xD4] = 0x00D4,
+  [0xD5] = 0x0150,
+  [0xD6] = 0x00D6,
+  [0xD7] = 0x00D7,
+  [0xD8] = 0x0158,
+  [0xD9] = 0x016E,
+  [0xDA] = 0x00DA,
+  [0xDB] = 0x0170,
+  [0xDC] = 0x00DC,
+  [0xDD] = 0x00DD,
+  [0xDE] = 0x0162,
+  [0xDF] = 0x00DF,
+  [0xE0] = 0x0155,
+  [0xE1] = 0x00E1,
+  [0xE2] = 0x00E2,
+  [0xE3] = 0x0103,
+  [0xE4] = 0x00E4,
+  [0xE5] = 0x013A,
+  [0xE6] = 0x0107,
+  [0xE7] = 0x00E7,
+  [0xE8] = 0x010D,
+  [0xE9] = 0x00E9,
+  [0xEA] = 0x0119,
+  [0xEB] = 0x00EB,
+  [0xEC] = 0x011B,
+  [0xED] = 0x00ED,
+  [0xEE] = 0x00EE,
+  [0xEF] = 0x010F,
+  [0xF0] = 0x0111,
+  [0xF1] = 0x0144,
+  [0xF2] = 0x0148,
+  [0xF3] = 0x00F3,
+  [0xF4] = 0x00F4,
+  [0xF5] = 0x0151,
+  [0xF6] = 0x00F6,
+  [0xF7] = 0x00F7,
+  [0xF8] = 0x0159,
+  [0xF9] = 0x016F,
+  [0xFA] = 0x00FA,
+  [0xFB] = 0x0171,
+  [0xFC] = 0x00FC,
+  [0xFD] = 0x00FD,
+  [0xFE] = 0x0163,
+  [0xFF] = 0x02D9,
+};
+static const char from_ucs4[] = {
+  [0x0000] = 0x00,
+  [0x0001] = 0x01,
+  [0x0002] = 0x02,
+  [0x0003] = 0x03,
+  [0x0004] = 0x04,
+  [0x0005] = 0x05,
+  [0x0006] = 0x06,
+  [0x0007] = 0x07,
+  [0x0008] = 0x08,
+  [0x0009] = 0x09,
+  [0x000A] = 0x0A,
+  [0x000B] = 0x0B,
+  [0x000C] = 0x0C,
+  [0x000D] = 0x0D,
+  [0x000E] = 0x0E,
+  [0x000F] = 0x0F,
+  [0x0010] = 0x10,
+  [0x0011] = 0x11,
+  [0x0012] = 0x12,
+  [0x0013] = 0x13,
+  [0x0014] = 0x14,
+  [0x0015] = 0x15,
+  [0x0016] = 0x16,
+  [0x0017] = 0x17,
+  [0x0018] = 0x18,
+  [0x0019] = 0x19,
+  [0x001A] = 0x1A,
+  [0x001B] = 0x1B,
+  [0x001C] = 0x1C,
+  [0x001D] = 0x1D,
+  [0x001E] = 0x1E,
+  [0x001F] = 0x1F,
+  [0x0020] = 0x20,
+  [0x0021] = 0x21,
+  [0x0022] = 0x22,
+  [0x0023] = 0x23,
+  [0x0024] = 0x24,
+  [0x0025] = 0x25,
+  [0x0026] = 0x26,
+  [0x0027] = 0x27,
+  [0x0028] = 0x28,
+  [0x0029] = 0x29,
+  [0x002A] = 0x2A,
+  [0x002B] = 0x2B,
+  [0x002C] = 0x2C,
+  [0x002D] = 0x2D,
+  [0x002E] = 0x2E,
+  [0x002F] = 0x2F,
+  [0x0030] = 0x30,
+  [0x0031] = 0x31,
+  [0x0032] = 0x32,
+  [0x0033] = 0x33,
+  [0x0034] = 0x34,
+  [0x0035] = 0x35,
+  [0x0036] = 0x36,
+  [0x0037] = 0x37,
+  [0x0038] = 0x38,
+  [0x0039] = 0x39,
+  [0x003A] = 0x3A,
+  [0x003B] = 0x3B,
+  [0x003C] = 0x3C,
+  [0x003D] = 0x3D,
+  [0x003E] = 0x3E,
+  [0x003F] = 0x3F,
+  [0x0040] = 0x40,
+  [0x0041] = 0x41,
+  [0x0042] = 0x42,
+  [0x0043] = 0x43,
+  [0x0044] = 0x44,
+  [0x0045] = 0x45,
+  [0x0046] = 0x46,
+  [0x0047] = 0x47,
+  [0x0048] = 0x48,
+  [0x0049] = 0x49,
+  [0x004A] = 0x4A,
+  [0x004B] = 0x4B,
+  [0x004C] = 0x4C,
+  [0x004D] = 0x4D,
+  [0x004E] = 0x4E,
+  [0x004F] = 0x4F,
+  [0x0050] = 0x50,
+  [0x0051] = 0x51,
+  [0x0052] = 0x52,
+  [0x0053] = 0x53,
+  [0x0054] = 0x54,
+  [0x0055] = 0x55,
+  [0x0056] = 0x56,
+  [0x0057] = 0x57,
+  [0x0058] = 0x58,
+  [0x0059] = 0x59,
+  [0x005A] = 0x5A,
+  [0x005B] = 0x5B,
+  [0x005C] = 0x5C,
+  [0x005D] = 0x5D,
+  [0x005E] = 0x5E,
+  [0x005F] = 0x5F,
+  [0x0060] = 0x60,
+  [0x0061] = 0x61,
+  [0x0062] = 0x62,
+  [0x0063] = 0x63,
+  [0x0064] = 0x64,
+  [0x0065] = 0x65,
+  [0x0066] = 0x66,
+  [0x0067] = 0x67,
+  [0x0068] = 0x68,
+  [0x0069] = 0x69,
+  [0x006A] = 0x6A,
+  [0x006B] = 0x6B,
+  [0x006C] = 0x6C,
+  [0x006D] = 0x6D,
+  [0x006E] = 0x6E,
+  [0x006F] = 0x6F,
+  [0x0070] = 0x70,
+  [0x0071] = 0x71,
+  [0x0072] = 0x72,
+  [0x0073] = 0x73,
+  [0x0074] = 0x74,
+  [0x0075] = 0x75,
+  [0x0076] = 0x76,
+  [0x0077] = 0x77,
+  [0x0078] = 0x78,
+  [0x0079] = 0x79,
+  [0x007A] = 0x7A,
+  [0x007B] = 0x7B,
+  [0x007C] = 0x7C,
+  [0x007D] = 0x7D,
+  [0x007E] = 0x7E,
+  [0x007F] = 0x7F,
+  [0x0080] = 0x80,
+  [0x0081] = 0x81,
+  [0x0082] = 0x82,
+  [0x0083] = 0x83,
+  [0x0084] = 0x84,
+  [0x0085] = 0x85,
+  [0x0086] = 0x86,
+  [0x0087] = 0x87,
+  [0x0088] = 0x88,
+  [0x0089] = 0x89,
+  [0x008A] = 0x8A,
+  [0x008B] = 0x8B,
+  [0x008C] = 0x8C,
+  [0x008D] = 0x8D,
+  [0x008E] = 0x8E,
+  [0x008F] = 0x8F,
+  [0x0090] = 0x90,
+  [0x0091] = 0x91,
+  [0x0092] = 0x92,
+  [0x0093] = 0x93,
+  [0x0094] = 0x94,
+  [0x0095] = 0x95,
+  [0x0096] = 0x96,
+  [0x0097] = 0x97,
+  [0x0098] = 0x98,
+  [0x0099] = 0x99,
+  [0x009A] = 0x9A,
+  [0x009B] = 0x9B,
+  [0x009C] = 0x9C,
+  [0x009D] = 0x9D,
+  [0x009E] = 0x9E,
+  [0x009F] = 0x9F,
+  [0x00A0] = 0xA0,
+  [0x00A4] = 0xA4,
+  [0x00A7] = 0xA7,
+  [0x00A8] = 0xA8,
+  [0x00AD] = 0xAD,
+  [0x00B0] = 0xB0,
+  [0x00B4] = 0xB4,
+  [0x00B8] = 0xB8,
+  [0x00C1] = 0xC1,
+  [0x00C2] = 0xC2,
+  [0x00C4] = 0xC4,
+  [0x00C7] = 0xC7,
+  [0x00C9] = 0xC9,
+  [0x00CB] = 0xCB,
+  [0x00CD] = 0xCD,
+  [0x00CE] = 0xCE,
+  [0x00D3] = 0xD3,
+  [0x00D4] = 0xD4,
+  [0x00D6] = 0xD6,
+  [0x00D7] = 0xD7,
+  [0x00DA] = 0xDA,
+  [0x00DC] = 0xDC,
+  [0x00DD] = 0xDD,
+  [0x00DF] = 0xDF,
+  [0x00E1] = 0xE1,
+  [0x00E2] = 0xE2,
+  [0x00E4] = 0xE4,
+  [0x00E7] = 0xE7,
+  [0x00E9] = 0xE9,
+  [0x00EB] = 0xEB,
+  [0x00ED] = 0xED,
+  [0x00EE] = 0xEE,
+  [0x00F3] = 0xF3,
+  [0x00F4] = 0xF4,
+  [0x00F6] = 0xF6,
+  [0x00F7] = 0xF7,
+  [0x00FA] = 0xFA,
+  [0x00FC] = 0xFC,
+  [0x00FD] = 0xFD,
+  [0x0102] = 0xC3,
+  [0x0103] = 0xE3,
+  [0x0104] = 0xA1,
+  [0x0105] = 0xB1,
+  [0x0106] = 0xC6,
+  [0x0107] = 0xE6,
+  [0x010C] = 0xC8,
+  [0x010D] = 0xE8,
+  [0x010E] = 0xCF,
+  [0x010F] = 0xEF,
+  [0x0110] = 0xD0,
+  [0x0111] = 0xF0,
+  [0x0118] = 0xCA,
+  [0x0119] = 0xEA,
+  [0x011A] = 0xCC,
+  [0x011B] = 0xEC,
+  [0x0139] = 0xC5,
+  [0x013A] = 0xE5,
+  [0x013D] = 0xA5,
+  [0x013E] = 0xB5,
+  [0x0141] = 0xA3,
+  [0x0142] = 0xB3,
+  [0x0143] = 0xD1,
+  [0x0144] = 0xF1,
+  [0x0147] = 0xD2,
+  [0x0148] = 0xF2,
+  [0x0150] = 0xD5,
+  [0x0151] = 0xF5,
+  [0x0154] = 0xC0,
+  [0x0155] = 0xE0,
+  [0x0158] = 0xD8,
+  [0x0159] = 0xF8,
+  [0x015A] = 0xA6,
+  [0x015B] = 0xB6,
+  [0x015E] = 0xAA,
+  [0x015F] = 0xBA,
+  [0x0160] = 0xA9,
+  [0x0161] = 0xB9,
+  [0x0162] = 0xDE,
+  [0x0163] = 0xFE,
+  [0x0164] = 0xAB,
+  [0x0165] = 0xBB,
+  [0x016E] = 0xD9,
+  [0x016F] = 0xF9,
+  [0x0170] = 0xDB,
+  [0x0171] = 0xFB,
+  [0x0179] = 0xAC,
+  [0x017A] = 0xBC,
+  [0x017B] = 0xAF,
+  [0x017C] = 0xBF,
+  [0x017D] = 0xAE,
+  [0x017E] = 0xBE,
+  [0x02C7] = 0xB7,
+  [0x02D8] = 0xA2,
+  [0x02D9] = 0xFF,
+  [0x02DB] = 0xB2,
+  [0x02DD] = 0xBD,
+};
diff --git a/iconvdata/iso8859-3.c b/iconvdata/iso8859-3.c
new file mode 100644
index 0000000000..a6b208dc81
--- /dev/null
+++ b/iconvdata/iso8859-3.c
@@ -0,0 +1,24 @@
+/* Conversion from and to ISO 8859-3.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <wchar.h>
+#include <iso8859-3.h>
+#define NAME "ISO-8859-3"
+#include <iso8859-generic.c>
diff --git a/iconvdata/iso8859-3.h b/iconvdata/iso8859-3.h
new file mode 100644
index 0000000000..f9e632504b
--- /dev/null
+++ b/iconvdata/iso8859-3.h
@@ -0,0 +1,502 @@
+static const wchar_t to_ucs4[256] = {
+  [0x00] = 0x0000,
+  [0x01] = 0x0001,
+  [0x02] = 0x0002,
+  [0x03] = 0x0003,
+  [0x04] = 0x0004,
+  [0x05] = 0x0005,
+  [0x06] = 0x0006,
+  [0x07] = 0x0007,
+  [0x08] = 0x0008,
+  [0x09] = 0x0009,
+  [0x0A] = 0x000A,
+  [0x0B] = 0x000B,
+  [0x0C] = 0x000C,
+  [0x0D] = 0x000D,
+  [0x0E] = 0x000E,
+  [0x0F] = 0x000F,
+  [0x10] = 0x0010,
+  [0x11] = 0x0011,
+  [0x12] = 0x0012,
+  [0x13] = 0x0013,
+  [0x14] = 0x0014,
+  [0x15] = 0x0015,
+  [0x16] = 0x0016,
+  [0x17] = 0x0017,
+  [0x18] = 0x0018,
+  [0x19] = 0x0019,
+  [0x1A] = 0x001A,
+  [0x1B] = 0x001B,
+  [0x1C] = 0x001C,
+  [0x1D] = 0x001D,
+  [0x1E] = 0x001E,
+  [0x1F] = 0x001F,
+  [0x20] = 0x0020,
+  [0x21] = 0x0021,
+  [0x22] = 0x0022,
+  [0x23] = 0x0023,
+  [0x24] = 0x0024,
+  [0x25] = 0x0025,
+  [0x26] = 0x0026,
+  [0x27] = 0x0027,
+  [0x28] = 0x0028,
+  [0x29] = 0x0029,
+  [0x2A] = 0x002A,
+  [0x2B] = 0x002B,
+  [0x2C] = 0x002C,
+  [0x2D] = 0x002D,
+  [0x2E] = 0x002E,
+  [0x2F] = 0x002F,
+  [0x30] = 0x0030,
+  [0x31] = 0x0031,
+  [0x32] = 0x0032,
+  [0x33] = 0x0033,
+  [0x34] = 0x0034,
+  [0x35] = 0x0035,
+  [0x36] = 0x0036,
+  [0x37] = 0x0037,
+  [0x38] = 0x0038,
+  [0x39] = 0x0039,
+  [0x3A] = 0x003A,
+  [0x3B] = 0x003B,
+  [0x3C] = 0x003C,
+  [0x3D] = 0x003D,
+  [0x3E] = 0x003E,
+  [0x3F] = 0x003F,
+  [0x40] = 0x0040,
+  [0x41] = 0x0041,
+  [0x42] = 0x0042,
+  [0x43] = 0x0043,
+  [0x44] = 0x0044,
+  [0x45] = 0x0045,
+  [0x46] = 0x0046,
+  [0x47] = 0x0047,
+  [0x48] = 0x0048,
+  [0x49] = 0x0049,
+  [0x4A] = 0x004A,
+  [0x4B] = 0x004B,
+  [0x4C] = 0x004C,
+  [0x4D] = 0x004D,
+  [0x4E] = 0x004E,
+  [0x4F] = 0x004F,
+  [0x50] = 0x0050,
+  [0x51] = 0x0051,
+  [0x52] = 0x0052,
+  [0x53] = 0x0053,
+  [0x54] = 0x0054,
+  [0x55] = 0x0055,
+  [0x56] = 0x0056,
+  [0x57] = 0x0057,
+  [0x58] = 0x0058,
+  [0x59] = 0x0059,
+  [0x5A] = 0x005A,
+  [0x5B] = 0x005B,
+  [0x5C] = 0x005C,
+  [0x5D] = 0x005D,
+  [0x5E] = 0x005E,
+  [0x5F] = 0x005F,
+  [0x60] = 0x0060,
+  [0x61] = 0x0061,
+  [0x62] = 0x0062,
+  [0x63] = 0x0063,
+  [0x64] = 0x0064,
+  [0x65] = 0x0065,
+  [0x66] = 0x0066,
+  [0x67] = 0x0067,
+  [0x68] = 0x0068,
+  [0x69] = 0x0069,
+  [0x6A] = 0x006A,
+  [0x6B] = 0x006B,
+  [0x6C] = 0x006C,
+  [0x6D] = 0x006D,
+  [0x6E] = 0x006E,
+  [0x6F] = 0x006F,
+  [0x70] = 0x0070,
+  [0x71] = 0x0071,
+  [0x72] = 0x0072,
+  [0x73] = 0x0073,
+  [0x74] = 0x0074,
+  [0x75] = 0x0075,
+  [0x76] = 0x0076,
+  [0x77] = 0x0077,
+  [0x78] = 0x0078,
+  [0x79] = 0x0079,
+  [0x7A] = 0x007A,
+  [0x7B] = 0x007B,
+  [0x7C] = 0x007C,
+  [0x7D] = 0x007D,
+  [0x7E] = 0x007E,
+  [0x7F] = 0x007F,
+  [0x80] = 0x0080,
+  [0x81] = 0x0081,
+  [0x82] = 0x0082,
+  [0x83] = 0x0083,
+  [0x84] = 0x0084,
+  [0x85] = 0x0085,
+  [0x86] = 0x0086,
+  [0x87] = 0x0087,
+  [0x88] = 0x0088,
+  [0x89] = 0x0089,
+  [0x8A] = 0x008A,
+  [0x8B] = 0x008B,
+  [0x8C] = 0x008C,
+  [0x8D] = 0x008D,
+  [0x8E] = 0x008E,
+  [0x8F] = 0x008F,
+  [0x90] = 0x0090,
+  [0x91] = 0x0091,
+  [0x92] = 0x0092,
+  [0x93] = 0x0093,
+  [0x94] = 0x0094,
+  [0x95] = 0x0095,
+  [0x96] = 0x0096,
+  [0x97] = 0x0097,
+  [0x98] = 0x0098,
+  [0x99] = 0x0099,
+  [0x9A] = 0x009A,
+  [0x9B] = 0x009B,
+  [0x9C] = 0x009C,
+  [0x9D] = 0x009D,
+  [0x9E] = 0x009E,
+  [0x9F] = 0x009F,
+  [0xA0] = 0x00A0,
+  [0xA1] = 0x0126,
+  [0xA2] = 0x02D8,
+  [0xA3] = 0x00A3,
+  [0xA4] = 0x00A4,
+  [0xA6] = 0x0124,
+  [0xA7] = 0x00A7,
+  [0xA8] = 0x00A8,
+  [0xA9] = 0x0130,
+  [0xAA] = 0x015E,
+  [0xAB] = 0x011E,
+  [0xAC] = 0x0134,
+  [0xAD] = 0x00AD,
+  [0xAF] = 0x017B,
+  [0xB0] = 0x00B0,
+  [0xB1] = 0x0127,
+  [0xB2] = 0x00B2,
+  [0xB3] = 0x00B3,
+  [0xB4] = 0x00B4,
+  [0xB5] = 0x00B5,
+  [0xB6] = 0x0125,
+  [0xB7] = 0x00B7,
+  [0xB8] = 0x00B8,
+  [0xB9] = 0x0131,
+  [0xBA] = 0x015F,
+  [0xBB] = 0x011F,
+  [0xBC] = 0x0135,
+  [0xBD] = 0x00BD,
+  [0xBF] = 0x017C,
+  [0xC0] = 0x00C0,
+  [0xC1] = 0x00C1,
+  [0xC2] = 0x00C2,
+  [0xC4] = 0x00C4,
+  [0xC5] = 0x010A,
+  [0xC6] = 0x0108,
+  [0xC7] = 0x00C7,
+  [0xC8] = 0x00C8,
+  [0xC9] = 0x00C9,
+  [0xCA] = 0x00CA,
+  [0xCB] = 0x00CB,
+  [0xCC] = 0x00CC,
+  [0xCD] = 0x00CD,
+  [0xCE] = 0x00CE,
+  [0xCF] = 0x00CF,
+  [0xD1] = 0x00D1,
+  [0xD2] = 0x00D2,
+  [0xD3] = 0x00D3,
+  [0xD4] = 0x00D4,
+  [0xD5] = 0x0120,
+  [0xD6] = 0x00D6,
+  [0xD7] = 0x00D7,
+  [0xD8] = 0x011C,
+  [0xD9] = 0x00D9,
+  [0xDA] = 0x00DA,
+  [0xDB] = 0x00DB,
+  [0xDC] = 0x00DC,
+  [0xDD] = 0x016C,
+  [0xDE] = 0x015C,
+  [0xDF] = 0x00DF,
+  [0xE0] = 0x00E0,
+  [0xE1] = 0x00E1,
+  [0xE2] = 0x00E2,
+  [0xE4] = 0x00E4,
+  [0xE5] = 0x010B,
+  [0xE6] = 0x0109,
+  [0xE7] = 0x00E7,
+  [0xE8] = 0x00E8,
+  [0xE9] = 0x00E9,
+  [0xEA] = 0x00EA,
+  [0xEB] = 0x00EB,
+  [0xEC] = 0x00EC,
+  [0xED] = 0x00ED,
+  [0xEE] = 0x00EE,
+  [0xEF] = 0x00EF,
+  [0xF1] = 0x00F1,
+  [0xF2] = 0x00F2,
+  [0xF3] = 0x00F3,
+  [0xF4] = 0x00F4,
+  [0xF5] = 0x0121,
+  [0xF6] = 0x00F6,
+  [0xF7] = 0x00F7,
+  [0xF8] = 0x011D,
+  [0xF9] = 0x00F9,
+  [0xFA] = 0x00FA,
+  [0xFB] = 0x00FB,
+  [0xFC] = 0x00FC,
+  [0xFD] = 0x016D,
+  [0xFE] = 0x015D,
+  [0xFF] = 0x02D9,
+};
+static const char from_ucs4[] = {
+  [0x0000] = 0x00,
+  [0x0001] = 0x01,
+  [0x0002] = 0x02,
+  [0x0003] = 0x03,
+  [0x0004] = 0x04,
+  [0x0005] = 0x05,
+  [0x0006] = 0x06,
+  [0x0007] = 0x07,
+  [0x0008] = 0x08,
+  [0x0009] = 0x09,
+  [0x000A] = 0x0A,
+  [0x000B] = 0x0B,
+  [0x000C] = 0x0C,
+  [0x000D] = 0x0D,
+  [0x000E] = 0x0E,
+  [0x000F] = 0x0F,
+  [0x0010] = 0x10,
+  [0x0011] = 0x11,
+  [0x0012] = 0x12,
+  [0x0013] = 0x13,
+  [0x0014] = 0x14,
+  [0x0015] = 0x15,
+  [0x0016] = 0x16,
+  [0x0017] = 0x17,
+  [0x0018] = 0x18,
+  [0x0019] = 0x19,
+  [0x001A] = 0x1A,
+  [0x001B] = 0x1B,
+  [0x001C] = 0x1C,
+  [0x001D] = 0x1D,
+  [0x001E] = 0x1E,
+  [0x001F] = 0x1F,
+  [0x0020] = 0x20,
+  [0x0021] = 0x21,
+  [0x0022] = 0x22,
+  [0x0023] = 0x23,
+  [0x0024] = 0x24,
+  [0x0025] = 0x25,
+  [0x0026] = 0x26,
+  [0x0027] = 0x27,
+  [0x0028] = 0x28,
+  [0x0029] = 0x29,
+  [0x002A] = 0x2A,
+  [0x002B] = 0x2B,
+  [0x002C] = 0x2C,
+  [0x002D] = 0x2D,
+  [0x002E] = 0x2E,
+  [0x002F] = 0x2F,
+  [0x0030] = 0x30,
+  [0x0031] = 0x31,
+  [0x0032] = 0x32,
+  [0x0033] = 0x33,
+  [0x0034] = 0x34,
+  [0x0035] = 0x35,
+  [0x0036] = 0x36,
+  [0x0037] = 0x37,
+  [0x0038] = 0x38,
+  [0x0039] = 0x39,
+  [0x003A] = 0x3A,
+  [0x003B] = 0x3B,
+  [0x003C] = 0x3C,
+  [0x003D] = 0x3D,
+  [0x003E] = 0x3E,
+  [0x003F] = 0x3F,
+  [0x0040] = 0x40,
+  [0x0041] = 0x41,
+  [0x0042] = 0x42,
+  [0x0043] = 0x43,
+  [0x0044] = 0x44,
+  [0x0045] = 0x45,
+  [0x0046] = 0x46,
+  [0x0047] = 0x47,
+  [0x0048] = 0x48,
+  [0x0049] = 0x49,
+  [0x004A] = 0x4A,
+  [0x004B] = 0x4B,
+  [0x004C] = 0x4C,
+  [0x004D] = 0x4D,
+  [0x004E] = 0x4E,
+  [0x004F] = 0x4F,
+  [0x0050] = 0x50,
+  [0x0051] = 0x51,
+  [0x0052] = 0x52,
+  [0x0053] = 0x53,
+  [0x0054] = 0x54,
+  [0x0055] = 0x55,
+  [0x0056] = 0x56,
+  [0x0057] = 0x57,
+  [0x0058] = 0x58,
+  [0x0059] = 0x59,
+  [0x005A] = 0x5A,
+  [0x005B] = 0x5B,
+  [0x005C] = 0x5C,
+  [0x005D] = 0x5D,
+  [0x005E] = 0x5E,
+  [0x005F] = 0x5F,
+  [0x0060] = 0x60,
+  [0x0061] = 0x61,
+  [0x0062] = 0x62,
+  [0x0063] = 0x63,
+  [0x0064] = 0x64,
+  [0x0065] = 0x65,
+  [0x0066] = 0x66,
+  [0x0067] = 0x67,
+  [0x0068] = 0x68,
+  [0x0069] = 0x69,
+  [0x006A] = 0x6A,
+  [0x006B] = 0x6B,
+  [0x006C] = 0x6C,
+  [0x006D] = 0x6D,
+  [0x006E] = 0x6E,
+  [0x006F] = 0x6F,
+  [0x0070] = 0x70,
+  [0x0071] = 0x71,
+  [0x0072] = 0x72,
+  [0x0073] = 0x73,
+  [0x0074] = 0x74,
+  [0x0075] = 0x75,
+  [0x0076] = 0x76,
+  [0x0077] = 0x77,
+  [0x0078] = 0x78,
+  [0x0079] = 0x79,
+  [0x007A] = 0x7A,
+  [0x007B] = 0x7B,
+  [0x007C] = 0x7C,
+  [0x007D] = 0x7D,
+  [0x007E] = 0x7E,
+  [0x007F] = 0x7F,
+  [0x0080] = 0x80,
+  [0x0081] = 0x81,
+  [0x0082] = 0x82,
+  [0x0083] = 0x83,
+  [0x0084] = 0x84,
+  [0x0085] = 0x85,
+  [0x0086] = 0x86,
+  [0x0087] = 0x87,
+  [0x0088] = 0x88,
+  [0x0089] = 0x89,
+  [0x008A] = 0x8A,
+  [0x008B] = 0x8B,
+  [0x008C] = 0x8C,
+  [0x008D] = 0x8D,
+  [0x008E] = 0x8E,
+  [0x008F] = 0x8F,
+  [0x0090] = 0x90,
+  [0x0091] = 0x91,
+  [0x0092] = 0x92,
+  [0x0093] = 0x93,
+  [0x0094] = 0x94,
+  [0x0095] = 0x95,
+  [0x0096] = 0x96,
+  [0x0097] = 0x97,
+  [0x0098] = 0x98,
+  [0x0099] = 0x99,
+  [0x009A] = 0x9A,
+  [0x009B] = 0x9B,
+  [0x009C] = 0x9C,
+  [0x009D] = 0x9D,
+  [0x009E] = 0x9E,
+  [0x009F] = 0x9F,
+  [0x00A0] = 0xA0,
+  [0x00A3] = 0xA3,
+  [0x00A4] = 0xA4,
+  [0x00A7] = 0xA7,
+  [0x00A8] = 0xA8,
+  [0x00AD] = 0xAD,
+  [0x00B0] = 0xB0,
+  [0x00B2] = 0xB2,
+  [0x00B3] = 0xB3,
+  [0x00B4] = 0xB4,
+  [0x00B5] = 0xB5,
+  [0x00B7] = 0xB7,
+  [0x00B8] = 0xB8,
+  [0x00BD] = 0xBD,
+  [0x00C0] = 0xC0,
+  [0x00C1] = 0xC1,
+  [0x00C2] = 0xC2,
+  [0x00C4] = 0xC4,
+  [0x00C7] = 0xC7,
+  [0x00C8] = 0xC8,
+  [0x00C9] = 0xC9,
+  [0x00CA] = 0xCA,
+  [0x00CB] = 0xCB,
+  [0x00CC] = 0xCC,
+  [0x00CD] = 0xCD,
+  [0x00CE] = 0xCE,
+  [0x00CF] = 0xCF,
+  [0x00D1] = 0xD1,
+  [0x00D2] = 0xD2,
+  [0x00D3] = 0xD3,
+  [0x00D4] = 0xD4,
+  [0x00D6] = 0xD6,
+  [0x00D7] = 0xD7,
+  [0x00D9] = 0xD9,
+  [0x00DA] = 0xDA,
+  [0x00DB] = 0xDB,
+  [0x00DC] = 0xDC,
+  [0x00DF] = 0xDF,
+  [0x00E0] = 0xE0,
+  [0x00E1] = 0xE1,
+  [0x00E2] = 0xE2,
+  [0x00E4] = 0xE4,
+  [0x00E7] = 0xE7,
+  [0x00E8] = 0xE8,
+  [0x00E9] = 0xE9,
+  [0x00EA] = 0xEA,
+  [0x00EB] = 0xEB,
+  [0x00EC] = 0xEC,
+  [0x00ED] = 0xED,
+  [0x00EE] = 0xEE,
+  [0x00EF] = 0xEF,
+  [0x00F1] = 0xF1,
+  [0x00F2] = 0xF2,
+  [0x00F3] = 0xF3,
+  [0x00F4] = 0xF4,
+  [0x00F6] = 0xF6,
+  [0x00F7] = 0xF7,
+  [0x00F9] = 0xF9,
+  [0x00FA] = 0xFA,
+  [0x00FB] = 0xFB,
+  [0x00FC] = 0xFC,
+  [0x0108] = 0xC6,
+  [0x0109] = 0xE6,
+  [0x010A] = 0xC5,
+  [0x010B] = 0xE5,
+  [0x011C] = 0xD8,
+  [0x011D] = 0xF8,
+  [0x011E] = 0xAB,
+  [0x011F] = 0xBB,
+  [0x0120] = 0xD5,
+  [0x0121] = 0xF5,
+  [0x0124] = 0xA6,
+  [0x0125] = 0xB6,
+  [0x0126] = 0xA1,
+  [0x0127] = 0xB1,
+  [0x0130] = 0xA9,
+  [0x0131] = 0xB9,
+  [0x0134] = 0xAC,
+  [0x0135] = 0xBC,
+  [0x015C] = 0xDE,
+  [0x015D] = 0xFE,
+  [0x015E] = 0xAA,
+  [0x015F] = 0xBA,
+  [0x016C] = 0xDD,
+  [0x016D] = 0xFD,
+  [0x017B] = 0xAF,
+  [0x017C] = 0xBF,
+  [0x02D8] = 0xA2,
+  [0x02D9] = 0xFF,
+};
diff --git a/iconvdata/iso8859-4.c b/iconvdata/iso8859-4.c
new file mode 100644
index 0000000000..b2b6ef0246
--- /dev/null
+++ b/iconvdata/iso8859-4.c
@@ -0,0 +1,24 @@
+/* Conversion from and to ISO 8859-4.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <wchar.h>
+#include <iso8859-4.h>
+#define NAME "ISO-8859-4"
+#include <iso8859-generic.c>
diff --git a/iconvdata/iso8859-4.h b/iconvdata/iso8859-4.h
new file mode 100644
index 0000000000..acf4aaad40
--- /dev/null
+++ b/iconvdata/iso8859-4.h
@@ -0,0 +1,516 @@
+static const wchar_t to_ucs4[256] = {
+  [0x00] = 0x0000,
+  [0x01] = 0x0001,
+  [0x02] = 0x0002,
+  [0x03] = 0x0003,
+  [0x04] = 0x0004,
+  [0x05] = 0x0005,
+  [0x06] = 0x0006,
+  [0x07] = 0x0007,
+  [0x08] = 0x0008,
+  [0x09] = 0x0009,
+  [0x0A] = 0x000A,
+  [0x0B] = 0x000B,
+  [0x0C] = 0x000C,
+  [0x0D] = 0x000D,
+  [0x0E] = 0x000E,
+  [0x0F] = 0x000F,
+  [0x10] = 0x0010,
+  [0x11] = 0x0011,
+  [0x12] = 0x0012,
+  [0x13] = 0x0013,
+  [0x14] = 0x0014,
+  [0x15] = 0x0015,
+  [0x16] = 0x0016,
+  [0x17] = 0x0017,
+  [0x18] = 0x0018,
+  [0x19] = 0x0019,
+  [0x1A] = 0x001A,
+  [0x1B] = 0x001B,
+  [0x1C] = 0x001C,
+  [0x1D] = 0x001D,
+  [0x1E] = 0x001E,
+  [0x1F] = 0x001F,
+  [0x20] = 0x0020,
+  [0x21] = 0x0021,
+  [0x22] = 0x0022,
+  [0x23] = 0x0023,
+  [0x24] = 0x0024,
+  [0x25] = 0x0025,
+  [0x26] = 0x0026,
+  [0x27] = 0x0027,
+  [0x28] = 0x0028,
+  [0x29] = 0x0029,
+  [0x2A] = 0x002A,
+  [0x2B] = 0x002B,
+  [0x2C] = 0x002C,
+  [0x2D] = 0x002D,
+  [0x2E] = 0x002E,
+  [0x2F] = 0x002F,
+  [0x30] = 0x0030,
+  [0x31] = 0x0031,
+  [0x32] = 0x0032,
+  [0x33] = 0x0033,
+  [0x34] = 0x0034,
+  [0x35] = 0x0035,
+  [0x36] = 0x0036,
+  [0x37] = 0x0037,
+  [0x38] = 0x0038,
+  [0x39] = 0x0039,
+  [0x3A] = 0x003A,
+  [0x3B] = 0x003B,
+  [0x3C] = 0x003C,
+  [0x3D] = 0x003D,
+  [0x3E] = 0x003E,
+  [0x3F] = 0x003F,
+  [0x40] = 0x0040,
+  [0x41] = 0x0041,
+  [0x42] = 0x0042,
+  [0x43] = 0x0043,
+  [0x44] = 0x0044,
+  [0x45] = 0x0045,
+  [0x46] = 0x0046,
+  [0x47] = 0x0047,
+  [0x48] = 0x0048,
+  [0x49] = 0x0049,
+  [0x4A] = 0x004A,
+  [0x4B] = 0x004B,
+  [0x4C] = 0x004C,
+  [0x4D] = 0x004D,
+  [0x4E] = 0x004E,
+  [0x4F] = 0x004F,
+  [0x50] = 0x0050,
+  [0x51] = 0x0051,
+  [0x52] = 0x0052,
+  [0x53] = 0x0053,
+  [0x54] = 0x0054,
+  [0x55] = 0x0055,
+  [0x56] = 0x0056,
+  [0x57] = 0x0057,
+  [0x58] = 0x0058,
+  [0x59] = 0x0059,
+  [0x5A] = 0x005A,
+  [0x5B] = 0x005B,
+  [0x5C] = 0x005C,
+  [0x5D] = 0x005D,
+  [0x5E] = 0x005E,
+  [0x5F] = 0x005F,
+  [0x60] = 0x0060,
+  [0x61] = 0x0061,
+  [0x62] = 0x0062,
+  [0x63] = 0x0063,
+  [0x64] = 0x0064,
+  [0x65] = 0x0065,
+  [0x66] = 0x0066,
+  [0x67] = 0x0067,
+  [0x68] = 0x0068,
+  [0x69] = 0x0069,
+  [0x6A] = 0x006A,
+  [0x6B] = 0x006B,
+  [0x6C] = 0x006C,
+  [0x6D] = 0x006D,
+  [0x6E] = 0x006E,
+  [0x6F] = 0x006F,
+  [0x70] = 0x0070,
+  [0x71] = 0x0071,
+  [0x72] = 0x0072,
+  [0x73] = 0x0073,
+  [0x74] = 0x0074,
+  [0x75] = 0x0075,
+  [0x76] = 0x0076,
+  [0x77] = 0x0077,
+  [0x78] = 0x0078,
+  [0x79] = 0x0079,
+  [0x7A] = 0x007A,
+  [0x7B] = 0x007B,
+  [0x7C] = 0x007C,
+  [0x7D] = 0x007D,
+  [0x7E] = 0x007E,
+  [0x7F] = 0x007F,
+  [0x80] = 0x0080,
+  [0x81] = 0x0081,
+  [0x82] = 0x0082,
+  [0x83] = 0x0083,
+  [0x84] = 0x0084,
+  [0x85] = 0x0085,
+  [0x86] = 0x0086,
+  [0x87] = 0x0087,
+  [0x88] = 0x0088,
+  [0x89] = 0x0089,
+  [0x8A] = 0x008A,
+  [0x8B] = 0x008B,
+  [0x8C] = 0x008C,
+  [0x8D] = 0x008D,
+  [0x8E] = 0x008E,
+  [0x8F] = 0x008F,
+  [0x90] = 0x0090,
+  [0x91] = 0x0091,
+  [0x92] = 0x0092,
+  [0x93] = 0x0093,
+  [0x94] = 0x0094,
+  [0x95] = 0x0095,
+  [0x96] = 0x0096,
+  [0x97] = 0x0097,
+  [0x98] = 0x0098,
+  [0x99] = 0x0099,
+  [0x9A] = 0x009A,
+  [0x9B] = 0x009B,
+  [0x9C] = 0x009C,
+  [0x9D] = 0x009D,
+  [0x9E] = 0x009E,
+  [0x9F] = 0x009F,
+  [0xA0] = 0x00A0,
+  [0xA1] = 0x0104,
+  [0xA2] = 0x0138,
+  [0xA3] = 0x0156,
+  [0xA4] = 0x00A4,
+  [0xA5] = 0x0128,
+  [0xA6] = 0x013B,
+  [0xA7] = 0x00A7,
+  [0xA8] = 0x00A8,
+  [0xA9] = 0x0160,
+  [0xAA] = 0x0112,
+  [0xAB] = 0x0122,
+  [0xAC] = 0x0166,
+  [0xAD] = 0x00AD,
+  [0xAE] = 0x017D,
+  [0xAF] = 0x00AF,
+  [0xB0] = 0x00B0,
+  [0xB1] = 0x0105,
+  [0xB2] = 0x02DB,
+  [0xB3] = 0x0157,
+  [0xB4] = 0x00B4,
+  [0xB5] = 0x0129,
+  [0xB6] = 0x013C,
+  [0xB7] = 0x02C7,
+  [0xB8] = 0x00B8,
+  [0xB9] = 0x0161,
+  [0xBA] = 0x0113,
+  [0xBB] = 0x0123,
+  [0xBC] = 0x0167,
+  [0xBD] = 0x014A,
+  [0xBE] = 0x017E,
+  [0xBF] = 0x014B,
+  [0xC0] = 0x0100,
+  [0xC1] = 0x00C1,
+  [0xC2] = 0x00C2,
+  [0xC3] = 0x00C3,
+  [0xC4] = 0x00C4,
+  [0xC5] = 0x00C5,
+  [0xC6] = 0x00C6,
+  [0xC7] = 0x012E,
+  [0xC8] = 0x010C,
+  [0xC9] = 0x00C9,
+  [0xCA] = 0x0118,
+  [0xCB] = 0x00CB,
+  [0xCC] = 0x0116,
+  [0xCD] = 0x00CD,
+  [0xCE] = 0x00CE,
+  [0xCF] = 0x012A,
+  [0xD0] = 0x0110,
+  [0xD1] = 0x0145,
+  [0xD2] = 0x014C,
+  [0xD3] = 0x0136,
+  [0xD4] = 0x00D4,
+  [0xD5] = 0x00D5,
+  [0xD6] = 0x00D6,
+  [0xD7] = 0x00D7,
+  [0xD8] = 0x00D8,
+  [0xD9] = 0x0172,
+  [0xDA] = 0x00DA,
+  [0xDB] = 0x00DB,
+  [0xDC] = 0x00DC,
+  [0xDD] = 0x0168,
+  [0xDE] = 0x016A,
+  [0xDF] = 0x00DF,
+  [0xE0] = 0x0101,
+  [0xE1] = 0x00E1,
+  [0xE2] = 0x00E2,
+  [0xE3] = 0x00E3,
+  [0xE4] = 0x00E4,
+  [0xE5] = 0x00E5,
+  [0xE6] = 0x00E6,
+  [0xE7] = 0x012F,
+  [0xE8] = 0x010D,
+  [0xE9] = 0x00E9,
+  [0xEA] = 0x0119,
+  [0xEB] = 0x00EB,
+  [0xEC] = 0x0117,
+  [0xED] = 0x00ED,
+  [0xEE] = 0x00EE,
+  [0xEF] = 0x012B,
+  [0xF0] = 0x0111,
+  [0xF1] = 0x0146,
+  [0xF2] = 0x014D,
+  [0xF3] = 0x0137,
+  [0xF4] = 0x00F4,
+  [0xF5] = 0x00F5,
+  [0xF6] = 0x00F6,
+  [0xF7] = 0x00F7,
+  [0xF8] = 0x00F8,
+  [0xF9] = 0x0173,
+  [0xFA] = 0x00FA,
+  [0xFB] = 0x00FB,
+  [0xFC] = 0x00FC,
+  [0xFD] = 0x0169,
+  [0xFE] = 0x016B,
+  [0xFF] = 0x02D9,
+};
+static const char from_ucs4[] = {
+  [0x0000] = 0x00,
+  [0x0001] = 0x01,
+  [0x0002] = 0x02,
+  [0x0003] = 0x03,
+  [0x0004] = 0x04,
+  [0x0005] = 0x05,
+  [0x0006] = 0x06,
+  [0x0007] = 0x07,
+  [0x0008] = 0x08,
+  [0x0009] = 0x09,
+  [0x000A] = 0x0A,
+  [0x000B] = 0x0B,
+  [0x000C] = 0x0C,
+  [0x000D] = 0x0D,
+  [0x000E] = 0x0E,
+  [0x000F] = 0x0F,
+  [0x0010] = 0x10,
+  [0x0011] = 0x11,
+  [0x0012] = 0x12,
+  [0x0013] = 0x13,
+  [0x0014] = 0x14,
+  [0x0015] = 0x15,
+  [0x0016] = 0x16,
+  [0x0017] = 0x17,
+  [0x0018] = 0x18,
+  [0x0019] = 0x19,
+  [0x001A] = 0x1A,
+  [0x001B] = 0x1B,
+  [0x001C] = 0x1C,
+  [0x001D] = 0x1D,
+  [0x001E] = 0x1E,
+  [0x001F] = 0x1F,
+  [0x0020] = 0x20,
+  [0x0021] = 0x21,
+  [0x0022] = 0x22,
+  [0x0023] = 0x23,
+  [0x0024] = 0x24,
+  [0x0025] = 0x25,
+  [0x0026] = 0x26,
+  [0x0027] = 0x27,
+  [0x0028] = 0x28,
+  [0x0029] = 0x29,
+  [0x002A] = 0x2A,
+  [0x002B] = 0x2B,
+  [0x002C] = 0x2C,
+  [0x002D] = 0x2D,
+  [0x002E] = 0x2E,
+  [0x002F] = 0x2F,
+  [0x0030] = 0x30,
+  [0x0031] = 0x31,
+  [0x0032] = 0x32,
+  [0x0033] = 0x33,
+  [0x0034] = 0x34,
+  [0x0035] = 0x35,
+  [0x0036] = 0x36,
+  [0x0037] = 0x37,
+  [0x0038] = 0x38,
+  [0x0039] = 0x39,
+  [0x003A] = 0x3A,
+  [0x003B] = 0x3B,
+  [0x003C] = 0x3C,
+  [0x003D] = 0x3D,
+  [0x003E] = 0x3E,
+  [0x003F] = 0x3F,
+  [0x0040] = 0x40,
+  [0x0041] = 0x41,
+  [0x0042] = 0x42,
+  [0x0043] = 0x43,
+  [0x0044] = 0x44,
+  [0x0045] = 0x45,
+  [0x0046] = 0x46,
+  [0x0047] = 0x47,
+  [0x0048] = 0x48,
+  [0x0049] = 0x49,
+  [0x004A] = 0x4A,
+  [0x004B] = 0x4B,
+  [0x004C] = 0x4C,
+  [0x004D] = 0x4D,
+  [0x004E] = 0x4E,
+  [0x004F] = 0x4F,
+  [0x0050] = 0x50,
+  [0x0051] = 0x51,
+  [0x0052] = 0x52,
+  [0x0053] = 0x53,
+  [0x0054] = 0x54,
+  [0x0055] = 0x55,
+  [0x0056] = 0x56,
+  [0x0057] = 0x57,
+  [0x0058] = 0x58,
+  [0x0059] = 0x59,
+  [0x005A] = 0x5A,
+  [0x005B] = 0x5B,
+  [0x005C] = 0x5C,
+  [0x005D] = 0x5D,
+  [0x005E] = 0x5E,
+  [0x005F] = 0x5F,
+  [0x0060] = 0x60,
+  [0x0061] = 0x61,
+  [0x0062] = 0x62,
+  [0x0063] = 0x63,
+  [0x0064] = 0x64,
+  [0x0065] = 0x65,
+  [0x0066] = 0x66,
+  [0x0067] = 0x67,
+  [0x0068] = 0x68,
+  [0x0069] = 0x69,
+  [0x006A] = 0x6A,
+  [0x006B] = 0x6B,
+  [0x006C] = 0x6C,
+  [0x006D] = 0x6D,
+  [0x006E] = 0x6E,
+  [0x006F] = 0x6F,
+  [0x0070] = 0x70,
+  [0x0071] = 0x71,
+  [0x0072] = 0x72,
+  [0x0073] = 0x73,
+  [0x0074] = 0x74,
+  [0x0075] = 0x75,
+  [0x0076] = 0x76,
+  [0x0077] = 0x77,
+  [0x0078] = 0x78,
+  [0x0079] = 0x79,
+  [0x007A] = 0x7A,
+  [0x007B] = 0x7B,
+  [0x007C] = 0x7C,
+  [0x007D] = 0x7D,
+  [0x007E] = 0x7E,
+  [0x007F] = 0x7F,
+  [0x0080] = 0x80,
+  [0x0081] = 0x81,
+  [0x0082] = 0x82,
+  [0x0083] = 0x83,
+  [0x0084] = 0x84,
+  [0x0085] = 0x85,
+  [0x0086] = 0x86,
+  [0x0087] = 0x87,
+  [0x0088] = 0x88,
+  [0x0089] = 0x89,
+  [0x008A] = 0x8A,
+  [0x008B] = 0x8B,
+  [0x008C] = 0x8C,
+  [0x008D] = 0x8D,
+  [0x008E] = 0x8E,
+  [0x008F] = 0x8F,
+  [0x0090] = 0x90,
+  [0x0091] = 0x91,
+  [0x0092] = 0x92,
+  [0x0093] = 0x93,
+  [0x0094] = 0x94,
+  [0x0095] = 0x95,
+  [0x0096] = 0x96,
+  [0x0097] = 0x97,
+  [0x0098] = 0x98,
+  [0x0099] = 0x99,
+  [0x009A] = 0x9A,
+  [0x009B] = 0x9B,
+  [0x009C] = 0x9C,
+  [0x009D] = 0x9D,
+  [0x009E] = 0x9E,
+  [0x009F] = 0x9F,
+  [0x00A0] = 0xA0,
+  [0x00A4] = 0xA4,
+  [0x00A7] = 0xA7,
+  [0x00A8] = 0xA8,
+  [0x00AD] = 0xAD,
+  [0x00AF] = 0xAF,
+  [0x00B0] = 0xB0,
+  [0x00B4] = 0xB4,
+  [0x00B8] = 0xB8,
+  [0x00C1] = 0xC1,
+  [0x00C2] = 0xC2,
+  [0x00C3] = 0xC3,
+  [0x00C4] = 0xC4,
+  [0x00C5] = 0xC5,
+  [0x00C6] = 0xC6,
+  [0x00C9] = 0xC9,
+  [0x00CB] = 0xCB,
+  [0x00CD] = 0xCD,
+  [0x00CE] = 0xCE,
+  [0x00D4] = 0xD4,
+  [0x00D5] = 0xD5,
+  [0x00D6] = 0xD6,
+  [0x00D7] = 0xD7,
+  [0x00D8] = 0xD8,
+  [0x00DA] = 0xDA,
+  [0x00DB] = 0xDB,
+  [0x00DC] = 0xDC,
+  [0x00DF] = 0xDF,
+  [0x00E1] = 0xE1,
+  [0x00E2] = 0xE2,
+  [0x00E3] = 0xE3,
+  [0x00E4] = 0xE4,
+  [0x00E5] = 0xE5,
+  [0x00E6] = 0xE6,
+  [0x00E9] = 0xE9,
+  [0x00EB] = 0xEB,
+  [0x00ED] = 0xED,
+  [0x00EE] = 0xEE,
+  [0x00F4] = 0xF4,
+  [0x00F5] = 0xF5,
+  [0x00F6] = 0xF6,
+  [0x00F7] = 0xF7,
+  [0x00F8] = 0xF8,
+  [0x00FA] = 0xFA,
+  [0x00FB] = 0xFB,
+  [0x00FC] = 0xFC,
+  [0x0100] = 0xC0,
+  [0x0101] = 0xE0,
+  [0x0104] = 0xA1,
+  [0x0105] = 0xB1,
+  [0x010C] = 0xC8,
+  [0x010D] = 0xE8,
+  [0x0110] = 0xD0,
+  [0x0111] = 0xF0,
+  [0x0112] = 0xAA,
+  [0x0113] = 0xBA,
+  [0x0116] = 0xCC,
+  [0x0117] = 0xEC,
+  [0x0118] = 0xCA,
+  [0x0119] = 0xEA,
+  [0x0122] = 0xAB,
+  [0x0123] = 0xBB,
+  [0x0128] = 0xA5,
+  [0x0129] = 0xB5,
+  [0x012A] = 0xCF,
+  [0x012B] = 0xEF,
+  [0x012E] = 0xC7,
+  [0x012F] = 0xE7,
+  [0x0136] = 0xD3,
+  [0x0137] = 0xF3,
+  [0x0138] = 0xA2,
+  [0x013B] = 0xA6,
+  [0x013C] = 0xB6,
+  [0x0145] = 0xD1,
+  [0x0146] = 0xF1,
+  [0x014A] = 0xBD,
+  [0x014B] = 0xBF,
+  [0x014C] = 0xD2,
+  [0x014D] = 0xF2,
+  [0x0156] = 0xA3,
+  [0x0157] = 0xB3,
+  [0x0160] = 0xA9,
+  [0x0161] = 0xB9,
+  [0x0166] = 0xAC,
+  [0x0167] = 0xBC,
+  [0x0168] = 0xDD,
+  [0x0169] = 0xFD,
+  [0x016A] = 0xDE,
+  [0x016B] = 0xFE,
+  [0x0172] = 0xD9,
+  [0x0173] = 0xF9,
+  [0x017D] = 0xAE,
+  [0x017E] = 0xBE,
+  [0x02C7] = 0xB7,
+  [0x02D9] = 0xFF,
+  [0x02DB] = 0xB2,
+};
diff --git a/iconvdata/iso8859-5.c b/iconvdata/iso8859-5.c
new file mode 100644
index 0000000000..b0ebd6f93b
--- /dev/null
+++ b/iconvdata/iso8859-5.c
@@ -0,0 +1,24 @@
+/* Conversion from and to ISO 8859-5.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <wchar.h>
+#include <iso8859-5.h>
+#define NAME "ISO-8859-5"
+#include <iso8859-generic.c>
diff --git a/iconvdata/iso8859-5.h b/iconvdata/iso8859-5.h
new file mode 100644
index 0000000000..f20ce11fe0
--- /dev/null
+++ b/iconvdata/iso8859-5.h
@@ -0,0 +1,516 @@
+static const wchar_t to_ucs4[256] = {
+  [0x00] = 0x0000,
+  [0x01] = 0x0001,
+  [0x02] = 0x0002,
+  [0x03] = 0x0003,
+  [0x04] = 0x0004,
+  [0x05] = 0x0005,
+  [0x06] = 0x0006,
+  [0x07] = 0x0007,
+  [0x08] = 0x0008,
+  [0x09] = 0x0009,
+  [0x0A] = 0x000A,
+  [0x0B] = 0x000B,
+  [0x0C] = 0x000C,
+  [0x0D] = 0x000D,
+  [0x0E] = 0x000E,
+  [0x0F] = 0x000F,
+  [0x10] = 0x0010,
+  [0x11] = 0x0011,
+  [0x12] = 0x0012,
+  [0x13] = 0x0013,
+  [0x14] = 0x0014,
+  [0x15] = 0x0015,
+  [0x16] = 0x0016,
+  [0x17] = 0x0017,
+  [0x18] = 0x0018,
+  [0x19] = 0x0019,
+  [0x1A] = 0x001A,
+  [0x1B] = 0x001B,
+  [0x1C] = 0x001C,
+  [0x1D] = 0x001D,
+  [0x1E] = 0x001E,
+  [0x1F] = 0x001F,
+  [0x20] = 0x0020,
+  [0x21] = 0x0021,
+  [0x22] = 0x0022,
+  [0x23] = 0x0023,
+  [0x24] = 0x0024,
+  [0x25] = 0x0025,
+  [0x26] = 0x0026,
+  [0x27] = 0x0027,
+  [0x28] = 0x0028,
+  [0x29] = 0x0029,
+  [0x2A] = 0x002A,
+  [0x2B] = 0x002B,
+  [0x2C] = 0x002C,
+  [0x2D] = 0x002D,
+  [0x2E] = 0x002E,
+  [0x2F] = 0x002F,
+  [0x30] = 0x0030,
+  [0x31] = 0x0031,
+  [0x32] = 0x0032,
+  [0x33] = 0x0033,
+  [0x34] = 0x0034,
+  [0x35] = 0x0035,
+  [0x36] = 0x0036,
+  [0x37] = 0x0037,
+  [0x38] = 0x0038,
+  [0x39] = 0x0039,
+  [0x3A] = 0x003A,
+  [0x3B] = 0x003B,
+  [0x3C] = 0x003C,
+  [0x3D] = 0x003D,
+  [0x3E] = 0x003E,
+  [0x3F] = 0x003F,
+  [0x40] = 0x0040,
+  [0x41] = 0x0041,
+  [0x42] = 0x0042,
+  [0x43] = 0x0043,
+  [0x44] = 0x0044,
+  [0x45] = 0x0045,
+  [0x46] = 0x0046,
+  [0x47] = 0x0047,
+  [0x48] = 0x0048,
+  [0x49] = 0x0049,
+  [0x4A] = 0x004A,
+  [0x4B] = 0x004B,
+  [0x4C] = 0x004C,
+  [0x4D] = 0x004D,
+  [0x4E] = 0x004E,
+  [0x4F] = 0x004F,
+  [0x50] = 0x0050,
+  [0x51] = 0x0051,
+  [0x52] = 0x0052,
+  [0x53] = 0x0053,
+  [0x54] = 0x0054,
+  [0x55] = 0x0055,
+  [0x56] = 0x0056,
+  [0x57] = 0x0057,
+  [0x58] = 0x0058,
+  [0x59] = 0x0059,
+  [0x5A] = 0x005A,
+  [0x5B] = 0x005B,
+  [0x5C] = 0x005C,
+  [0x5D] = 0x005D,
+  [0x5E] = 0x005E,
+  [0x5F] = 0x005F,
+  [0x60] = 0x0060,
+  [0x61] = 0x0061,
+  [0x62] = 0x0062,
+  [0x63] = 0x0063,
+  [0x64] = 0x0064,
+  [0x65] = 0x0065,
+  [0x66] = 0x0066,
+  [0x67] = 0x0067,
+  [0x68] = 0x0068,
+  [0x69] = 0x0069,
+  [0x6A] = 0x006A,
+  [0x6B] = 0x006B,
+  [0x6C] = 0x006C,
+  [0x6D] = 0x006D,
+  [0x6E] = 0x006E,
+  [0x6F] = 0x006F,
+  [0x70] = 0x0070,
+  [0x71] = 0x0071,
+  [0x72] = 0x0072,
+  [0x73] = 0x0073,
+  [0x74] = 0x0074,
+  [0x75] = 0x0075,
+  [0x76] = 0x0076,
+  [0x77] = 0x0077,
+  [0x78] = 0x0078,
+  [0x79] = 0x0079,
+  [0x7A] = 0x007A,
+  [0x7B] = 0x007B,
+  [0x7C] = 0x007C,
+  [0x7D] = 0x007D,
+  [0x7E] = 0x007E,
+  [0x7F] = 0x007F,
+  [0x80] = 0x0080,
+  [0x81] = 0x0081,
+  [0x82] = 0x0082,
+  [0x83] = 0x0083,
+  [0x84] = 0x0084,
+  [0x85] = 0x0085,
+  [0x86] = 0x0086,
+  [0x87] = 0x0087,
+  [0x88] = 0x0088,
+  [0x89] = 0x0089,
+  [0x8A] = 0x008A,
+  [0x8B] = 0x008B,
+  [0x8C] = 0x008C,
+  [0x8D] = 0x008D,
+  [0x8E] = 0x008E,
+  [0x8F] = 0x008F,
+  [0x90] = 0x0090,
+  [0x91] = 0x0091,
+  [0x92] = 0x0092,
+  [0x93] = 0x0093,
+  [0x94] = 0x0094,
+  [0x95] = 0x0095,
+  [0x96] = 0x0096,
+  [0x97] = 0x0097,
+  [0x98] = 0x0098,
+  [0x99] = 0x0099,
+  [0x9A] = 0x009A,
+  [0x9B] = 0x009B,
+  [0x9C] = 0x009C,
+  [0x9D] = 0x009D,
+  [0x9E] = 0x009E,
+  [0x9F] = 0x009F,
+  [0xA0] = 0x00A0,
+  [0xA1] = 0x0401,
+  [0xA2] = 0x0402,
+  [0xA3] = 0x0403,
+  [0xA4] = 0x0404,
+  [0xA5] = 0x0405,
+  [0xA6] = 0x0406,
+  [0xA7] = 0x0407,
+  [0xA8] = 0x0408,
+  [0xA9] = 0x0409,
+  [0xAA] = 0x040A,
+  [0xAB] = 0x040B,
+  [0xAC] = 0x040C,
+  [0xAD] = 0x00AD,
+  [0xAE] = 0x040E,
+  [0xAF] = 0x040F,
+  [0xB0] = 0x0410,
+  [0xB1] = 0x0411,
+  [0xB2] = 0x0412,
+  [0xB3] = 0x0413,
+  [0xB4] = 0x0414,
+  [0xB5] = 0x0415,
+  [0xB6] = 0x0416,
+  [0xB7] = 0x0417,
+  [0xB8] = 0x0418,
+  [0xB9] = 0x0419,
+  [0xBA] = 0x041A,
+  [0xBB] = 0x041B,
+  [0xBC] = 0x041C,
+  [0xBD] = 0x041D,
+  [0xBE] = 0x041E,
+  [0xBF] = 0x041F,
+  [0xC0] = 0x0420,
+  [0xC1] = 0x0421,
+  [0xC2] = 0x0422,
+  [0xC3] = 0x0423,
+  [0xC4] = 0x0424,
+  [0xC5] = 0x0425,
+  [0xC6] = 0x0426,
+  [0xC7] = 0x0427,
+  [0xC8] = 0x0428,
+  [0xC9] = 0x0429,
+  [0xCA] = 0x042A,
+  [0xCB] = 0x042B,
+  [0xCC] = 0x042C,
+  [0xCD] = 0x042D,
+  [0xCE] = 0x042E,
+  [0xCF] = 0x042F,
+  [0xD0] = 0x0430,
+  [0xD1] = 0x0431,
+  [0xD2] = 0x0432,
+  [0xD3] = 0x0433,
+  [0xD4] = 0x0434,
+  [0xD5] = 0x0435,
+  [0xD6] = 0x0436,
+  [0xD7] = 0x0437,
+  [0xD8] = 0x0438,
+  [0xD9] = 0x0439,
+  [0xDA] = 0x043A,
+  [0xDB] = 0x043B,
+  [0xDC] = 0x043C,
+  [0xDD] = 0x043D,
+  [0xDE] = 0x043E,
+  [0xDF] = 0x043F,
+  [0xE0] = 0x0440,
+  [0xE1] = 0x0441,
+  [0xE2] = 0x0442,
+  [0xE3] = 0x0443,
+  [0xE4] = 0x0444,
+  [0xE5] = 0x0445,
+  [0xE6] = 0x0446,
+  [0xE7] = 0x0447,
+  [0xE8] = 0x0448,
+  [0xE9] = 0x0449,
+  [0xEA] = 0x044A,
+  [0xEB] = 0x044B,
+  [0xEC] = 0x044C,
+  [0xED] = 0x044D,
+  [0xEE] = 0x044E,
+  [0xEF] = 0x044F,
+  [0xF0] = 0x2116,
+  [0xF1] = 0x0451,
+  [0xF2] = 0x0452,
+  [0xF3] = 0x0453,
+  [0xF4] = 0x0454,
+  [0xF5] = 0x0455,
+  [0xF6] = 0x0456,
+  [0xF7] = 0x0457,
+  [0xF8] = 0x0458,
+  [0xF9] = 0x0459,
+  [0xFA] = 0x045A,
+  [0xFB] = 0x045B,
+  [0xFC] = 0x045C,
+  [0xFD] = 0x00A7,
+  [0xFE] = 0x045E,
+  [0xFF] = 0x045F,
+};
+static const char from_ucs4[] = {
+  [0x0000] = 0x00,
+  [0x0001] = 0x01,
+  [0x0002] = 0x02,
+  [0x0003] = 0x03,
+  [0x0004] = 0x04,
+  [0x0005] = 0x05,
+  [0x0006] = 0x06,
+  [0x0007] = 0x07,
+  [0x0008] = 0x08,
+  [0x0009] = 0x09,
+  [0x000A] = 0x0A,
+  [0x000B] = 0x0B,
+  [0x000C] = 0x0C,
+  [0x000D] = 0x0D,
+  [0x000E] = 0x0E,
+  [0x000F] = 0x0F,
+  [0x0010] = 0x10,
+  [0x0011] = 0x11,
+  [0x0012] = 0x12,
+  [0x0013] = 0x13,
+  [0x0014] = 0x14,
+  [0x0015] = 0x15,
+  [0x0016] = 0x16,
+  [0x0017] = 0x17,
+  [0x0018] = 0x18,
+  [0x0019] = 0x19,
+  [0x001A] = 0x1A,
+  [0x001B] = 0x1B,
+  [0x001C] = 0x1C,
+  [0x001D] = 0x1D,
+  [0x001E] = 0x1E,
+  [0x001F] = 0x1F,
+  [0x0020] = 0x20,
+  [0x0021] = 0x21,
+  [0x0022] = 0x22,
+  [0x0023] = 0x23,
+  [0x0024] = 0x24,
+  [0x0025] = 0x25,
+  [0x0026] = 0x26,
+  [0x0027] = 0x27,
+  [0x0028] = 0x28,
+  [0x0029] = 0x29,
+  [0x002A] = 0x2A,
+  [0x002B] = 0x2B,
+  [0x002C] = 0x2C,
+  [0x002D] = 0x2D,
+  [0x002E] = 0x2E,
+  [0x002F] = 0x2F,
+  [0x0030] = 0x30,
+  [0x0031] = 0x31,
+  [0x0032] = 0x32,
+  [0x0033] = 0x33,
+  [0x0034] = 0x34,
+  [0x0035] = 0x35,
+  [0x0036] = 0x36,
+  [0x0037] = 0x37,
+  [0x0038] = 0x38,
+  [0x0039] = 0x39,
+  [0x003A] = 0x3A,
+  [0x003B] = 0x3B,
+  [0x003C] = 0x3C,
+  [0x003D] = 0x3D,
+  [0x003E] = 0x3E,
+  [0x003F] = 0x3F,
+  [0x0040] = 0x40,
+  [0x0041] = 0x41,
+  [0x0042] = 0x42,
+  [0x0043] = 0x43,
+  [0x0044] = 0x44,
+  [0x0045] = 0x45,
+  [0x0046] = 0x46,
+  [0x0047] = 0x47,
+  [0x0048] = 0x48,
+  [0x0049] = 0x49,
+  [0x004A] = 0x4A,
+  [0x004B] = 0x4B,
+  [0x004C] = 0x4C,
+  [0x004D] = 0x4D,
+  [0x004E] = 0x4E,
+  [0x004F] = 0x4F,
+  [0x0050] = 0x50,
+  [0x0051] = 0x51,
+  [0x0052] = 0x52,
+  [0x0053] = 0x53,
+  [0x0054] = 0x54,
+  [0x0055] = 0x55,
+  [0x0056] = 0x56,
+  [0x0057] = 0x57,
+  [0x0058] = 0x58,
+  [0x0059] = 0x59,
+  [0x005A] = 0x5A,
+  [0x005B] = 0x5B,
+  [0x005C] = 0x5C,
+  [0x005D] = 0x5D,
+  [0x005E] = 0x5E,
+  [0x005F] = 0x5F,
+  [0x0060] = 0x60,
+  [0x0061] = 0x61,
+  [0x0062] = 0x62,
+  [0x0063] = 0x63,
+  [0x0064] = 0x64,
+  [0x0065] = 0x65,
+  [0x0066] = 0x66,
+  [0x0067] = 0x67,
+  [0x0068] = 0x68,
+  [0x0069] = 0x69,
+  [0x006A] = 0x6A,
+  [0x006B] = 0x6B,
+  [0x006C] = 0x6C,
+  [0x006D] = 0x6D,
+  [0x006E] = 0x6E,
+  [0x006F] = 0x6F,
+  [0x0070] = 0x70,
+  [0x0071] = 0x71,
+  [0x0072] = 0x72,
+  [0x0073] = 0x73,
+  [0x0074] = 0x74,
+  [0x0075] = 0x75,
+  [0x0076] = 0x76,
+  [0x0077] = 0x77,
+  [0x0078] = 0x78,
+  [0x0079] = 0x79,
+  [0x007A] = 0x7A,
+  [0x007B] = 0x7B,
+  [0x007C] = 0x7C,
+  [0x007D] = 0x7D,
+  [0x007E] = 0x7E,
+  [0x007F] = 0x7F,
+  [0x0080] = 0x80,
+  [0x0081] = 0x81,
+  [0x0082] = 0x82,
+  [0x0083] = 0x83,
+  [0x0084] = 0x84,
+  [0x0085] = 0x85,
+  [0x0086] = 0x86,
+  [0x0087] = 0x87,
+  [0x0088] = 0x88,
+  [0x0089] = 0x89,
+  [0x008A] = 0x8A,
+  [0x008B] = 0x8B,
+  [0x008C] = 0x8C,
+  [0x008D] = 0x8D,
+  [0x008E] = 0x8E,
+  [0x008F] = 0x8F,
+  [0x0090] = 0x90,
+  [0x0091] = 0x91,
+  [0x0092] = 0x92,
+  [0x0093] = 0x93,
+  [0x0094] = 0x94,
+  [0x0095] = 0x95,
+  [0x0096] = 0x96,
+  [0x0097] = 0x97,
+  [0x0098] = 0x98,
+  [0x0099] = 0x99,
+  [0x009A] = 0x9A,
+  [0x009B] = 0x9B,
+  [0x009C] = 0x9C,
+  [0x009D] = 0x9D,
+  [0x009E] = 0x9E,
+  [0x009F] = 0x9F,
+  [0x00A0] = 0xA0,
+  [0x00A7] = 0xFD,
+  [0x00AD] = 0xAD,
+  [0x0401] = 0xA1,
+  [0x0402] = 0xA2,
+  [0x0403] = 0xA3,
+  [0x0404] = 0xA4,
+  [0x0405] = 0xA5,
+  [0x0406] = 0xA6,
+  [0x0407] = 0xA7,
+  [0x0408] = 0xA8,
+  [0x0409] = 0xA9,
+  [0x040A] = 0xAA,
+  [0x040B] = 0xAB,
+  [0x040C] = 0xAC,
+  [0x040E] = 0xAE,
+  [0x040F] = 0xAF,
+  [0x0410] = 0xB0,
+  [0x0411] = 0xB1,
+  [0x0412] = 0xB2,
+  [0x0413] = 0xB3,
+  [0x0414] = 0xB4,
+  [0x0415] = 0xB5,
+  [0x0416] = 0xB6,
+  [0x0417] = 0xB7,
+  [0x0418] = 0xB8,
+  [0x0419] = 0xB9,
+  [0x041A] = 0xBA,
+  [0x041B] = 0xBB,
+  [0x041C] = 0xBC,
+  [0x041D] = 0xBD,
+  [0x041E] = 0xBE,
+  [0x041F] = 0xBF,
+  [0x0420] = 0xC0,
+  [0x0421] = 0xC1,
+  [0x0422] = 0xC2,
+  [0x0423] = 0xC3,
+  [0x0424] = 0xC4,
+  [0x0425] = 0xC5,
+  [0x0426] = 0xC6,
+  [0x0427] = 0xC7,
+  [0x0428] = 0xC8,
+  [0x0429] = 0xC9,
+  [0x042A] = 0xCA,
+  [0x042B] = 0xCB,
+  [0x042C] = 0xCC,
+  [0x042D] = 0xCD,
+  [0x042E] = 0xCE,
+  [0x042F] = 0xCF,
+  [0x0430] = 0xD0,
+  [0x0431] = 0xD1,
+  [0x0432] = 0xD2,
+  [0x0433] = 0xD3,
+  [0x0434] = 0xD4,
+  [0x0435] = 0xD5,
+  [0x0436] = 0xD6,
+  [0x0437] = 0xD7,
+  [0x0438] = 0xD8,
+  [0x0439] = 0xD9,
+  [0x043A] = 0xDA,
+  [0x043B] = 0xDB,
+  [0x043C] = 0xDC,
+  [0x043D] = 0xDD,
+  [0x043E] = 0xDE,
+  [0x043F] = 0xDF,
+  [0x0440] = 0xE0,
+  [0x0441] = 0xE1,
+  [0x0442] = 0xE2,
+  [0x0443] = 0xE3,
+  [0x0444] = 0xE4,
+  [0x0445] = 0xE5,
+  [0x0446] = 0xE6,
+  [0x0447] = 0xE7,
+  [0x0448] = 0xE8,
+  [0x0449] = 0xE9,
+  [0x044A] = 0xEA,
+  [0x044B] = 0xEB,
+  [0x044C] = 0xEC,
+  [0x044D] = 0xED,
+  [0x044E] = 0xEE,
+  [0x044F] = 0xEF,
+  [0x0451] = 0xF1,
+  [0x0452] = 0xF2,
+  [0x0453] = 0xF3,
+  [0x0454] = 0xF4,
+  [0x0455] = 0xF5,
+  [0x0456] = 0xF6,
+  [0x0457] = 0xF7,
+  [0x0458] = 0xF8,
+  [0x0459] = 0xF9,
+  [0x045A] = 0xFA,
+  [0x045B] = 0xFB,
+  [0x045C] = 0xFC,
+  [0x045E] = 0xFE,
+  [0x045F] = 0xFF,
+  [0x2116] = 0xF0,
+};
diff --git a/iconvdata/iso8859-6.c b/iconvdata/iso8859-6.c
new file mode 100644
index 0000000000..f0f0a91004
--- /dev/null
+++ b/iconvdata/iso8859-6.c
@@ -0,0 +1,24 @@
+/* Conversion from and to ISO 8859-6.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <wchar.h>
+#include <iso8859-6.h>
+#define NAME "ISO-8859-6"
+#include <iso8859-generic.c>
diff --git a/iconvdata/iso8859-6.h b/iconvdata/iso8859-6.h
new file mode 100644
index 0000000000..f3b3480ff1
--- /dev/null
+++ b/iconvdata/iso8859-6.h
@@ -0,0 +1,426 @@
+static const wchar_t to_ucs4[256] = {
+  [0x00] = 0x0000,
+  [0x01] = 0x0001,
+  [0x02] = 0x0002,
+  [0x03] = 0x0003,
+  [0x04] = 0x0004,
+  [0x05] = 0x0005,
+  [0x06] = 0x0006,
+  [0x07] = 0x0007,
+  [0x08] = 0x0008,
+  [0x09] = 0x0009,
+  [0x0A] = 0x000A,
+  [0x0B] = 0x000B,
+  [0x0C] = 0x000C,
+  [0x0D] = 0x000D,
+  [0x0E] = 0x000E,
+  [0x0F] = 0x000F,
+  [0x10] = 0x0010,
+  [0x11] = 0x0011,
+  [0x12] = 0x0012,
+  [0x13] = 0x0013,
+  [0x14] = 0x0014,
+  [0x15] = 0x0015,
+  [0x16] = 0x0016,
+  [0x17] = 0x0017,
+  [0x18] = 0x0018,
+  [0x19] = 0x0019,
+  [0x1A] = 0x001A,
+  [0x1B] = 0x001B,
+  [0x1C] = 0x001C,
+  [0x1D] = 0x001D,
+  [0x1E] = 0x001E,
+  [0x1F] = 0x001F,
+  [0x20] = 0x0020,
+  [0x21] = 0x0021,
+  [0x22] = 0x0022,
+  [0x23] = 0x0023,
+  [0x24] = 0x0024,
+  [0x25] = 0x0025,
+  [0x26] = 0x0026,
+  [0x27] = 0x0027,
+  [0x28] = 0x0028,
+  [0x29] = 0x0029,
+  [0x2A] = 0x002A,
+  [0x2B] = 0x002B,
+  [0x2C] = 0x002C,
+  [0x2D] = 0x002D,
+  [0x2E] = 0x002E,
+  [0x2F] = 0x002F,
+  [0x30] = 0x0030,
+  [0x31] = 0x0031,
+  [0x32] = 0x0032,
+  [0x33] = 0x0033,
+  [0x34] = 0x0034,
+  [0x35] = 0x0035,
+  [0x36] = 0x0036,
+  [0x37] = 0x0037,
+  [0x38] = 0x0038,
+  [0x39] = 0x0039,
+  [0x3A] = 0x003A,
+  [0x3B] = 0x003B,
+  [0x3C] = 0x003C,
+  [0x3D] = 0x003D,
+  [0x3E] = 0x003E,
+  [0x3F] = 0x003F,
+  [0x40] = 0x0040,
+  [0x41] = 0x0041,
+  [0x42] = 0x0042,
+  [0x43] = 0x0043,
+  [0x44] = 0x0044,
+  [0x45] = 0x0045,
+  [0x46] = 0x0046,
+  [0x47] = 0x0047,
+  [0x48] = 0x0048,
+  [0x49] = 0x0049,
+  [0x4A] = 0x004A,
+  [0x4B] = 0x004B,
+  [0x4C] = 0x004C,
+  [0x4D] = 0x004D,
+  [0x4E] = 0x004E,
+  [0x4F] = 0x004F,
+  [0x50] = 0x0050,
+  [0x51] = 0x0051,
+  [0x52] = 0x0052,
+  [0x53] = 0x0053,
+  [0x54] = 0x0054,
+  [0x55] = 0x0055,
+  [0x56] = 0x0056,
+  [0x57] = 0x0057,
+  [0x58] = 0x0058,
+  [0x59] = 0x0059,
+  [0x5A] = 0x005A,
+  [0x5B] = 0x005B,
+  [0x5C] = 0x005C,
+  [0x5D] = 0x005D,
+  [0x5E] = 0x005E,
+  [0x5F] = 0x005F,
+  [0x60] = 0x0060,
+  [0x61] = 0x0061,
+  [0x62] = 0x0062,
+  [0x63] = 0x0063,
+  [0x64] = 0x0064,
+  [0x65] = 0x0065,
+  [0x66] = 0x0066,
+  [0x67] = 0x0067,
+  [0x68] = 0x0068,
+  [0x69] = 0x0069,
+  [0x6A] = 0x006A,
+  [0x6B] = 0x006B,
+  [0x6C] = 0x006C,
+  [0x6D] = 0x006D,
+  [0x6E] = 0x006E,
+  [0x6F] = 0x006F,
+  [0x70] = 0x0070,
+  [0x71] = 0x0071,
+  [0x72] = 0x0072,
+  [0x73] = 0x0073,
+  [0x74] = 0x0074,
+  [0x75] = 0x0075,
+  [0x76] = 0x0076,
+  [0x77] = 0x0077,
+  [0x78] = 0x0078,
+  [0x79] = 0x0079,
+  [0x7A] = 0x007A,
+  [0x7B] = 0x007B,
+  [0x7C] = 0x007C,
+  [0x7D] = 0x007D,
+  [0x7E] = 0x007E,
+  [0x7F] = 0x007F,
+  [0x80] = 0x0080,
+  [0x81] = 0x0081,
+  [0x82] = 0x0082,
+  [0x83] = 0x0083,
+  [0x84] = 0x0084,
+  [0x85] = 0x0085,
+  [0x86] = 0x0086,
+  [0x87] = 0x0087,
+  [0x88] = 0x0088,
+  [0x89] = 0x0089,
+  [0x8A] = 0x008A,
+  [0x8B] = 0x008B,
+  [0x8C] = 0x008C,
+  [0x8D] = 0x008D,
+  [0x8E] = 0x008E,
+  [0x8F] = 0x008F,
+  [0x90] = 0x0090,
+  [0x91] = 0x0091,
+  [0x92] = 0x0092,
+  [0x93] = 0x0093,
+  [0x94] = 0x0094,
+  [0x95] = 0x0095,
+  [0x96] = 0x0096,
+  [0x97] = 0x0097,
+  [0x98] = 0x0098,
+  [0x99] = 0x0099,
+  [0x9A] = 0x009A,
+  [0x9B] = 0x009B,
+  [0x9C] = 0x009C,
+  [0x9D] = 0x009D,
+  [0x9E] = 0x009E,
+  [0x9F] = 0x009F,
+  [0xA0] = 0x00A0,
+  [0xA4] = 0x00A4,
+  [0xAC] = 0x060C,
+  [0xAD] = 0x00AD,
+  [0xBB] = 0x061B,
+  [0xBF] = 0x061F,
+  [0xC1] = 0x0621,
+  [0xC2] = 0x0622,
+  [0xC3] = 0x0623,
+  [0xC4] = 0x0624,
+  [0xC5] = 0x0625,
+  [0xC6] = 0x0626,
+  [0xC7] = 0x0627,
+  [0xC8] = 0x0628,
+  [0xC9] = 0x0629,
+  [0xCA] = 0x062A,
+  [0xCB] = 0x062B,
+  [0xCC] = 0x062C,
+  [0xCD] = 0x062D,
+  [0xCE] = 0x062E,
+  [0xCF] = 0x062F,
+  [0xD0] = 0x0630,
+  [0xD1] = 0x0631,
+  [0xD2] = 0x0632,
+  [0xD3] = 0x0633,
+  [0xD4] = 0x0634,
+  [0xD5] = 0x0635,
+  [0xD6] = 0x0636,
+  [0xD7] = 0x0637,
+  [0xD8] = 0x0638,
+  [0xD9] = 0x0639,
+  [0xDA] = 0x063A,
+  [0xE0] = 0x0640,
+  [0xE1] = 0x0641,
+  [0xE2] = 0x0642,
+  [0xE3] = 0x0643,
+  [0xE4] = 0x0644,
+  [0xE5] = 0x0645,
+  [0xE6] = 0x0646,
+  [0xE7] = 0x0647,
+  [0xE8] = 0x0648,
+  [0xE9] = 0x0649,
+  [0xEA] = 0x064A,
+  [0xEB] = 0x064B,
+  [0xEC] = 0x064C,
+  [0xED] = 0x064D,
+  [0xEE] = 0x064E,
+  [0xEF] = 0x064F,
+  [0xF0] = 0x0650,
+  [0xF1] = 0x0651,
+  [0xF2] = 0x0652,
+};
+static const char from_ucs4[] = {
+  [0x0000] = 0x00,
+  [0x0001] = 0x01,
+  [0x0002] = 0x02,
+  [0x0003] = 0x03,
+  [0x0004] = 0x04,
+  [0x0005] = 0x05,
+  [0x0006] = 0x06,
+  [0x0007] = 0x07,
+  [0x0008] = 0x08,
+  [0x0009] = 0x09,
+  [0x000A] = 0x0A,
+  [0x000B] = 0x0B,
+  [0x000C] = 0x0C,
+  [0x000D] = 0x0D,
+  [0x000E] = 0x0E,
+  [0x000F] = 0x0F,
+  [0x0010] = 0x10,
+  [0x0011] = 0x11,
+  [0x0012] = 0x12,
+  [0x0013] = 0x13,
+  [0x0014] = 0x14,
+  [0x0015] = 0x15,
+  [0x0016] = 0x16,
+  [0x0017] = 0x17,
+  [0x0018] = 0x18,
+  [0x0019] = 0x19,
+  [0x001A] = 0x1A,
+  [0x001B] = 0x1B,
+  [0x001C] = 0x1C,
+  [0x001D] = 0x1D,
+  [0x001E] = 0x1E,
+  [0x001F] = 0x1F,
+  [0x0020] = 0x20,
+  [0x0021] = 0x21,
+  [0x0022] = 0x22,
+  [0x0023] = 0x23,
+  [0x0024] = 0x24,
+  [0x0025] = 0x25,
+  [0x0026] = 0x26,
+  [0x0027] = 0x27,
+  [0x0028] = 0x28,
+  [0x0029] = 0x29,
+  [0x002A] = 0x2A,
+  [0x002B] = 0x2B,
+  [0x002C] = 0x2C,
+  [0x002D] = 0x2D,
+  [0x002E] = 0x2E,
+  [0x002F] = 0x2F,
+  [0x0030] = 0x30,
+  [0x0031] = 0x31,
+  [0x0032] = 0x32,
+  [0x0033] = 0x33,
+  [0x0034] = 0x34,
+  [0x0035] = 0x35,
+  [0x0036] = 0x36,
+  [0x0037] = 0x37,
+  [0x0038] = 0x38,
+  [0x0039] = 0x39,
+  [0x003A] = 0x3A,
+  [0x003B] = 0x3B,
+  [0x003C] = 0x3C,
+  [0x003D] = 0x3D,
+  [0x003E] = 0x3E,
+  [0x003F] = 0x3F,
+  [0x0040] = 0x40,
+  [0x0041] = 0x41,
+  [0x0042] = 0x42,
+  [0x0043] = 0x43,
+  [0x0044] = 0x44,
+  [0x0045] = 0x45,
+  [0x0046] = 0x46,
+  [0x0047] = 0x47,
+  [0x0048] = 0x48,
+  [0x0049] = 0x49,
+  [0x004A] = 0x4A,
+  [0x004B] = 0x4B,
+  [0x004C] = 0x4C,
+  [0x004D] = 0x4D,
+  [0x004E] = 0x4E,
+  [0x004F] = 0x4F,
+  [0x0050] = 0x50,
+  [0x0051] = 0x51,
+  [0x0052] = 0x52,
+  [0x0053] = 0x53,
+  [0x0054] = 0x54,
+  [0x0055] = 0x55,
+  [0x0056] = 0x56,
+  [0x0057] = 0x57,
+  [0x0058] = 0x58,
+  [0x0059] = 0x59,
+  [0x005A] = 0x5A,
+  [0x005B] = 0x5B,
+  [0x005C] = 0x5C,
+  [0x005D] = 0x5D,
+  [0x005E] = 0x5E,
+  [0x005F] = 0x5F,
+  [0x0060] = 0x60,
+  [0x0061] = 0x61,
+  [0x0062] = 0x62,
+  [0x0063] = 0x63,
+  [0x0064] = 0x64,
+  [0x0065] = 0x65,
+  [0x0066] = 0x66,
+  [0x0067] = 0x67,
+  [0x0068] = 0x68,
+  [0x0069] = 0x69,
+  [0x006A] = 0x6A,
+  [0x006B] = 0x6B,
+  [0x006C] = 0x6C,
+  [0x006D] = 0x6D,
+  [0x006E] = 0x6E,
+  [0x006F] = 0x6F,
+  [0x0070] = 0x70,
+  [0x0071] = 0x71,
+  [0x0072] = 0x72,
+  [0x0073] = 0x73,
+  [0x0074] = 0x74,
+  [0x0075] = 0x75,
+  [0x0076] = 0x76,
+  [0x0077] = 0x77,
+  [0x0078] = 0x78,
+  [0x0079] = 0x79,
+  [0x007A] = 0x7A,
+  [0x007B] = 0x7B,
+  [0x007C] = 0x7C,
+  [0x007D] = 0x7D,
+  [0x007E] = 0x7E,
+  [0x007F] = 0x7F,
+  [0x0080] = 0x80,
+  [0x0081] = 0x81,
+  [0x0082] = 0x82,
+  [0x0083] = 0x83,
+  [0x0084] = 0x84,
+  [0x0085] = 0x85,
+  [0x0086] = 0x86,
+  [0x0087] = 0x87,
+  [0x0088] = 0x88,
+  [0x0089] = 0x89,
+  [0x008A] = 0x8A,
+  [0x008B] = 0x8B,
+  [0x008C] = 0x8C,
+  [0x008D] = 0x8D,
+  [0x008E] = 0x8E,
+  [0x008F] = 0x8F,
+  [0x0090] = 0x90,
+  [0x0091] = 0x91,
+  [0x0092] = 0x92,
+  [0x0093] = 0x93,
+  [0x0094] = 0x94,
+  [0x0095] = 0x95,
+  [0x0096] = 0x96,
+  [0x0097] = 0x97,
+  [0x0098] = 0x98,
+  [0x0099] = 0x99,
+  [0x009A] = 0x9A,
+  [0x009B] = 0x9B,
+  [0x009C] = 0x9C,
+  [0x009D] = 0x9D,
+  [0x009E] = 0x9E,
+  [0x009F] = 0x9F,
+  [0x00A0] = 0xA0,
+  [0x00A4] = 0xA4,
+  [0x00AD] = 0xAD,
+  [0x060C] = 0xAC,
+  [0x061B] = 0xBB,
+  [0x061F] = 0xBF,
+  [0x0621] = 0xC1,
+  [0x0622] = 0xC2,
+  [0x0623] = 0xC3,
+  [0x0624] = 0xC4,
+  [0x0625] = 0xC5,
+  [0x0626] = 0xC6,
+  [0x0627] = 0xC7,
+  [0x0628] = 0xC8,
+  [0x0629] = 0xC9,
+  [0x062A] = 0xCA,
+  [0x062B] = 0xCB,
+  [0x062C] = 0xCC,
+  [0x062D] = 0xCD,
+  [0x062E] = 0xCE,
+  [0x062F] = 0xCF,
+  [0x0630] = 0xD0,
+  [0x0631] = 0xD1,
+  [0x0632] = 0xD2,
+  [0x0633] = 0xD3,
+  [0x0634] = 0xD4,
+  [0x0635] = 0xD5,
+  [0x0636] = 0xD6,
+  [0x0637] = 0xD7,
+  [0x0638] = 0xD8,
+  [0x0639] = 0xD9,
+  [0x063A] = 0xDA,
+  [0x0640] = 0xE0,
+  [0x0641] = 0xE1,
+  [0x0642] = 0xE2,
+  [0x0643] = 0xE3,
+  [0x0644] = 0xE4,
+  [0x0645] = 0xE5,
+  [0x0646] = 0xE6,
+  [0x0647] = 0xE7,
+  [0x0648] = 0xE8,
+  [0x0649] = 0xE9,
+  [0x064A] = 0xEA,
+  [0x064B] = 0xEB,
+  [0x064C] = 0xEC,
+  [0x064D] = 0xED,
+  [0x064E] = 0xEE,
+  [0x064F] = 0xEF,
+  [0x0650] = 0xF0,
+  [0x0651] = 0xF1,
+  [0x0652] = 0xF2,
+};
diff --git a/iconvdata/iso8859-7.c b/iconvdata/iso8859-7.c
new file mode 100644
index 0000000000..87c2a2c06c
--- /dev/null
+++ b/iconvdata/iso8859-7.c
@@ -0,0 +1,24 @@
+/* Conversion from and to ISO 8859-7.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <wchar.h>
+#include <iso8859-7.h>
+#define NAME "ISO-8859-7"
+#include <iso8859-generic.c>
diff --git a/iconvdata/iso8859-7.h b/iconvdata/iso8859-7.h
new file mode 100644
index 0000000000..fe38788e20
--- /dev/null
+++ b/iconvdata/iso8859-7.h
@@ -0,0 +1,504 @@
+static const wchar_t to_ucs4[256] = {
+  [0x00] = 0x0000,
+  [0x01] = 0x0001,
+  [0x02] = 0x0002,
+  [0x03] = 0x0003,
+  [0x04] = 0x0004,
+  [0x05] = 0x0005,
+  [0x06] = 0x0006,
+  [0x07] = 0x0007,
+  [0x08] = 0x0008,
+  [0x09] = 0x0009,
+  [0x0A] = 0x000A,
+  [0x0B] = 0x000B,
+  [0x0C] = 0x000C,
+  [0x0D] = 0x000D,
+  [0x0E] = 0x000E,
+  [0x0F] = 0x000F,
+  [0x10] = 0x0010,
+  [0x11] = 0x0011,
+  [0x12] = 0x0012,
+  [0x13] = 0x0013,
+  [0x14] = 0x0014,
+  [0x15] = 0x0015,
+  [0x16] = 0x0016,
+  [0x17] = 0x0017,
+  [0x18] = 0x0018,
+  [0x19] = 0x0019,
+  [0x1A] = 0x001A,
+  [0x1B] = 0x001B,
+  [0x1C] = 0x001C,
+  [0x1D] = 0x001D,
+  [0x1E] = 0x001E,
+  [0x1F] = 0x001F,
+  [0x20] = 0x0020,
+  [0x21] = 0x0021,
+  [0x22] = 0x0022,
+  [0x23] = 0x0023,
+  [0x24] = 0x0024,
+  [0x25] = 0x0025,
+  [0x26] = 0x0026,
+  [0x27] = 0x0027,
+  [0x28] = 0x0028,
+  [0x29] = 0x0029,
+  [0x2A] = 0x002A,
+  [0x2B] = 0x002B,
+  [0x2C] = 0x002C,
+  [0x2D] = 0x002D,
+  [0x2E] = 0x002E,
+  [0x2F] = 0x002F,
+  [0x30] = 0x0030,
+  [0x31] = 0x0031,
+  [0x32] = 0x0032,
+  [0x33] = 0x0033,
+  [0x34] = 0x0034,
+  [0x35] = 0x0035,
+  [0x36] = 0x0036,
+  [0x37] = 0x0037,
+  [0x38] = 0x0038,
+  [0x39] = 0x0039,
+  [0x3A] = 0x003A,
+  [0x3B] = 0x003B,
+  [0x3C] = 0x003C,
+  [0x3D] = 0x003D,
+  [0x3E] = 0x003E,
+  [0x3F] = 0x003F,
+  [0x40] = 0x0040,
+  [0x41] = 0x0041,
+  [0x42] = 0x0042,
+  [0x43] = 0x0043,
+  [0x44] = 0x0044,
+  [0x45] = 0x0045,
+  [0x46] = 0x0046,
+  [0x47] = 0x0047,
+  [0x48] = 0x0048,
+  [0x49] = 0x0049,
+  [0x4A] = 0x004A,
+  [0x4B] = 0x004B,
+  [0x4C] = 0x004C,
+  [0x4D] = 0x004D,
+  [0x4E] = 0x004E,
+  [0x4F] = 0x004F,
+  [0x50] = 0x0050,
+  [0x51] = 0x0051,
+  [0x52] = 0x0052,
+  [0x53] = 0x0053,
+  [0x54] = 0x0054,
+  [0x55] = 0x0055,
+  [0x56] = 0x0056,
+  [0x57] = 0x0057,
+  [0x58] = 0x0058,
+  [0x59] = 0x0059,
+  [0x5A] = 0x005A,
+  [0x5B] = 0x005B,
+  [0x5C] = 0x005C,
+  [0x5D] = 0x005D,
+  [0x5E] = 0x005E,
+  [0x5F] = 0x005F,
+  [0x60] = 0x0060,
+  [0x61] = 0x0061,
+  [0x62] = 0x0062,
+  [0x63] = 0x0063,
+  [0x64] = 0x0064,
+  [0x65] = 0x0065,
+  [0x66] = 0x0066,
+  [0x67] = 0x0067,
+  [0x68] = 0x0068,
+  [0x69] = 0x0069,
+  [0x6A] = 0x006A,
+  [0x6B] = 0x006B,
+  [0x6C] = 0x006C,
+  [0x6D] = 0x006D,
+  [0x6E] = 0x006E,
+  [0x6F] = 0x006F,
+  [0x70] = 0x0070,
+  [0x71] = 0x0071,
+  [0x72] = 0x0072,
+  [0x73] = 0x0073,
+  [0x74] = 0x0074,
+  [0x75] = 0x0075,
+  [0x76] = 0x0076,
+  [0x77] = 0x0077,
+  [0x78] = 0x0078,
+  [0x79] = 0x0079,
+  [0x7A] = 0x007A,
+  [0x7B] = 0x007B,
+  [0x7C] = 0x007C,
+  [0x7D] = 0x007D,
+  [0x7E] = 0x007E,
+  [0x7F] = 0x007F,
+  [0x80] = 0x0080,
+  [0x81] = 0x0081,
+  [0x82] = 0x0082,
+  [0x83] = 0x0083,
+  [0x84] = 0x0084,
+  [0x85] = 0x0085,
+  [0x86] = 0x0086,
+  [0x87] = 0x0087,
+  [0x88] = 0x0088,
+  [0x89] = 0x0089,
+  [0x8A] = 0x008A,
+  [0x8B] = 0x008B,
+  [0x8C] = 0x008C,
+  [0x8D] = 0x008D,
+  [0x8E] = 0x008E,
+  [0x8F] = 0x008F,
+  [0x90] = 0x0090,
+  [0x91] = 0x0091,
+  [0x92] = 0x0092,
+  [0x93] = 0x0093,
+  [0x94] = 0x0094,
+  [0x95] = 0x0095,
+  [0x96] = 0x0096,
+  [0x97] = 0x0097,
+  [0x98] = 0x0098,
+  [0x99] = 0x0099,
+  [0x9A] = 0x009A,
+  [0x9B] = 0x009B,
+  [0x9C] = 0x009C,
+  [0x9D] = 0x009D,
+  [0x9E] = 0x009E,
+  [0x9F] = 0x009F,
+  [0xA0] = 0x00A0,
+  [0xA1] = 0x201B,
+  [0xA2] = 0x2019,
+  [0xA3] = 0x00A3,
+  [0xA6] = 0x00A6,
+  [0xA7] = 0x00A7,
+  [0xA8] = 0x00A8,
+  [0xA9] = 0x00A9,
+  [0xAB] = 0x00AB,
+  [0xAC] = 0x00AC,
+  [0xAD] = 0x00AD,
+  [0xAF] = 0x2014,
+  [0xB0] = 0x00B0,
+  [0xB1] = 0x00B1,
+  [0xB2] = 0x00B2,
+  [0xB3] = 0x00B3,
+  [0xB4] = 0x00B4,
+  [0xB5] = 0x0385,
+  [0xB6] = 0x0386,
+  [0xB7] = 0x00B7,
+  [0xB8] = 0x0388,
+  [0xB9] = 0x0389,
+  [0xBA] = 0x038A,
+  [0xBB] = 0x00BB,
+  [0xBC] = 0x038C,
+  [0xBD] = 0x00BD,
+  [0xBE] = 0x038E,
+  [0xBF] = 0x038F,
+  [0xC0] = 0x0390,
+  [0xC1] = 0x0391,
+  [0xC2] = 0x0392,
+  [0xC3] = 0x0393,
+  [0xC4] = 0x0394,
+  [0xC5] = 0x0395,
+  [0xC6] = 0x0396,
+  [0xC7] = 0x0397,
+  [0xC8] = 0x0398,
+  [0xC9] = 0x0399,
+  [0xCA] = 0x039A,
+  [0xCB] = 0x039B,
+  [0xCC] = 0x039C,
+  [0xCD] = 0x039D,
+  [0xCE] = 0x039E,
+  [0xCF] = 0x039F,
+  [0xD0] = 0x03A0,
+  [0xD1] = 0x03A1,
+  [0xD3] = 0x03A3,
+  [0xD4] = 0x03A4,
+  [0xD5] = 0x03A5,
+  [0xD6] = 0x03A6,
+  [0xD7] = 0x03A7,
+  [0xD8] = 0x03A8,
+  [0xD9] = 0x03A9,
+  [0xDA] = 0x03AA,
+  [0xDB] = 0x03AB,
+  [0xDC] = 0x03AC,
+  [0xDD] = 0x03AD,
+  [0xDE] = 0x03AE,
+  [0xDF] = 0x03AF,
+  [0xE0] = 0x03B0,
+  [0xE1] = 0x03B1,
+  [0xE2] = 0x03B2,
+  [0xE3] = 0x03B3,
+  [0xE4] = 0x03B4,
+  [0xE5] = 0x03B5,
+  [0xE6] = 0x03B6,
+  [0xE7] = 0x03B7,
+  [0xE8] = 0x03B8,
+  [0xE9] = 0x03B9,
+  [0xEA] = 0x03BA,
+  [0xEB] = 0x03BB,
+  [0xEC] = 0x03BC,
+  [0xED] = 0x03BD,
+  [0xEE] = 0x03BE,
+  [0xEF] = 0x03BF,
+  [0xF0] = 0x03C0,
+  [0xF1] = 0x03C1,
+  [0xF2] = 0x03C2,
+  [0xF3] = 0x03C3,
+  [0xF4] = 0x03C4,
+  [0xF5] = 0x03C5,
+  [0xF6] = 0x03C6,
+  [0xF7] = 0x03C7,
+  [0xF8] = 0x03C8,
+  [0xF9] = 0x03C9,
+  [0xFA] = 0x03CA,
+  [0xFB] = 0x03CB,
+  [0xFC] = 0x03CC,
+  [0xFD] = 0x03CD,
+  [0xFE] = 0x03CE,
+};
+static const char from_ucs4[] = {
+  [0x0000] = 0x00,
+  [0x0001] = 0x01,
+  [0x0002] = 0x02,
+  [0x0003] = 0x03,
+  [0x0004] = 0x04,
+  [0x0005] = 0x05,
+  [0x0006] = 0x06,
+  [0x0007] = 0x07,
+  [0x0008] = 0x08,
+  [0x0009] = 0x09,
+  [0x000A] = 0x0A,
+  [0x000B] = 0x0B,
+  [0x000C] = 0x0C,
+  [0x000D] = 0x0D,
+  [0x000E] = 0x0E,
+  [0x000F] = 0x0F,
+  [0x0010] = 0x10,
+  [0x0011] = 0x11,
+  [0x0012] = 0x12,
+  [0x0013] = 0x13,
+  [0x0014] = 0x14,
+  [0x0015] = 0x15,
+  [0x0016] = 0x16,
+  [0x0017] = 0x17,
+  [0x0018] = 0x18,
+  [0x0019] = 0x19,
+  [0x001A] = 0x1A,
+  [0x001B] = 0x1B,
+  [0x001C] = 0x1C,
+  [0x001D] = 0x1D,
+  [0x001E] = 0x1E,
+  [0x001F] = 0x1F,
+  [0x0020] = 0x20,
+  [0x0021] = 0x21,
+  [0x0022] = 0x22,
+  [0x0023] = 0x23,
+  [0x0024] = 0x24,
+  [0x0025] = 0x25,
+  [0x0026] = 0x26,
+  [0x0027] = 0x27,
+  [0x0028] = 0x28,
+  [0x0029] = 0x29,
+  [0x002A] = 0x2A,
+  [0x002B] = 0x2B,
+  [0x002C] = 0x2C,
+  [0x002D] = 0x2D,
+  [0x002E] = 0x2E,
+  [0x002F] = 0x2F,
+  [0x0030] = 0x30,
+  [0x0031] = 0x31,
+  [0x0032] = 0x32,
+  [0x0033] = 0x33,
+  [0x0034] = 0x34,
+  [0x0035] = 0x35,
+  [0x0036] = 0x36,
+  [0x0037] = 0x37,
+  [0x0038] = 0x38,
+  [0x0039] = 0x39,
+  [0x003A] = 0x3A,
+  [0x003B] = 0x3B,
+  [0x003C] = 0x3C,
+  [0x003D] = 0x3D,
+  [0x003E] = 0x3E,
+  [0x003F] = 0x3F,
+  [0x0040] = 0x40,
+  [0x0041] = 0x41,
+  [0x0042] = 0x42,
+  [0x0043] = 0x43,
+  [0x0044] = 0x44,
+  [0x0045] = 0x45,
+  [0x0046] = 0x46,
+  [0x0047] = 0x47,
+  [0x0048] = 0x48,
+  [0x0049] = 0x49,
+  [0x004A] = 0x4A,
+  [0x004B] = 0x4B,
+  [0x004C] = 0x4C,
+  [0x004D] = 0x4D,
+  [0x004E] = 0x4E,
+  [0x004F] = 0x4F,
+  [0x0050] = 0x50,
+  [0x0051] = 0x51,
+  [0x0052] = 0x52,
+  [0x0053] = 0x53,
+  [0x0054] = 0x54,
+  [0x0055] = 0x55,
+  [0x0056] = 0x56,
+  [0x0057] = 0x57,
+  [0x0058] = 0x58,
+  [0x0059] = 0x59,
+  [0x005A] = 0x5A,
+  [0x005B] = 0x5B,
+  [0x005C] = 0x5C,
+  [0x005D] = 0x5D,
+  [0x005E] = 0x5E,
+  [0x005F] = 0x5F,
+  [0x0060] = 0x60,
+  [0x0061] = 0x61,
+  [0x0062] = 0x62,
+  [0x0063] = 0x63,
+  [0x0064] = 0x64,
+  [0x0065] = 0x65,
+  [0x0066] = 0x66,
+  [0x0067] = 0x67,
+  [0x0068] = 0x68,
+  [0x0069] = 0x69,
+  [0x006A] = 0x6A,
+  [0x006B] = 0x6B,
+  [0x006C] = 0x6C,
+  [0x006D] = 0x6D,
+  [0x006E] = 0x6E,
+  [0x006F] = 0x6F,
+  [0x0070] = 0x70,
+  [0x0071] = 0x71,
+  [0x0072] = 0x72,
+  [0x0073] = 0x73,
+  [0x0074] = 0x74,
+  [0x0075] = 0x75,
+  [0x0076] = 0x76,
+  [0x0077] = 0x77,
+  [0x0078] = 0x78,
+  [0x0079] = 0x79,
+  [0x007A] = 0x7A,
+  [0x007B] = 0x7B,
+  [0x007C] = 0x7C,
+  [0x007D] = 0x7D,
+  [0x007E] = 0x7E,
+  [0x007F] = 0x7F,
+  [0x0080] = 0x80,
+  [0x0081] = 0x81,
+  [0x0082] = 0x82,
+  [0x0083] = 0x83,
+  [0x0084] = 0x84,
+  [0x0085] = 0x85,
+  [0x0086] = 0x86,
+  [0x0087] = 0x87,
+  [0x0088] = 0x88,
+  [0x0089] = 0x89,
+  [0x008A] = 0x8A,
+  [0x008B] = 0x8B,
+  [0x008C] = 0x8C,
+  [0x008D] = 0x8D,
+  [0x008E] = 0x8E,
+  [0x008F] = 0x8F,
+  [0x0090] = 0x90,
+  [0x0091] = 0x91,
+  [0x0092] = 0x92,
+  [0x0093] = 0x93,
+  [0x0094] = 0x94,
+  [0x0095] = 0x95,
+  [0x0096] = 0x96,
+  [0x0097] = 0x97,
+  [0x0098] = 0x98,
+  [0x0099] = 0x99,
+  [0x009A] = 0x9A,
+  [0x009B] = 0x9B,
+  [0x009C] = 0x9C,
+  [0x009D] = 0x9D,
+  [0x009E] = 0x9E,
+  [0x009F] = 0x9F,
+  [0x00A0] = 0xA0,
+  [0x00A3] = 0xA3,
+  [0x00A6] = 0xA6,
+  [0x00A7] = 0xA7,
+  [0x00A8] = 0xA8,
+  [0x00A9] = 0xA9,
+  [0x00AB] = 0xAB,
+  [0x00AC] = 0xAC,
+  [0x00AD] = 0xAD,
+  [0x00B0] = 0xB0,
+  [0x00B1] = 0xB1,
+  [0x00B2] = 0xB2,
+  [0x00B3] = 0xB3,
+  [0x00B4] = 0xB4,
+  [0x00B7] = 0xB7,
+  [0x00BB] = 0xBB,
+  [0x00BD] = 0xBD,
+  [0x0385] = 0xB5,
+  [0x0386] = 0xB6,
+  [0x0388] = 0xB8,
+  [0x0389] = 0xB9,
+  [0x038A] = 0xBA,
+  [0x038C] = 0xBC,
+  [0x038E] = 0xBE,
+  [0x038F] = 0xBF,
+  [0x0390] = 0xC0,
+  [0x0391] = 0xC1,
+  [0x0392] = 0xC2,
+  [0x0393] = 0xC3,
+  [0x0394] = 0xC4,
+  [0x0395] = 0xC5,
+  [0x0396] = 0xC6,
+  [0x0397] = 0xC7,
+  [0x0398] = 0xC8,
+  [0x0399] = 0xC9,
+  [0x039A] = 0xCA,
+  [0x039B] = 0xCB,
+  [0x039C] = 0xCC,
+  [0x039D] = 0xCD,
+  [0x039E] = 0xCE,
+  [0x039F] = 0xCF,
+  [0x03A0] = 0xD0,
+  [0x03A1] = 0xD1,
+  [0x03A3] = 0xD3,
+  [0x03A4] = 0xD4,
+  [0x03A5] = 0xD5,
+  [0x03A6] = 0xD6,
+  [0x03A7] = 0xD7,
+  [0x03A8] = 0xD8,
+  [0x03A9] = 0xD9,
+  [0x03AA] = 0xDA,
+  [0x03AB] = 0xDB,
+  [0x03AC] = 0xDC,
+  [0x03AD] = 0xDD,
+  [0x03AE] = 0xDE,
+  [0x03AF] = 0xDF,
+  [0x03B0] = 0xE0,
+  [0x03B1] = 0xE1,
+  [0x03B2] = 0xE2,
+  [0x03B3] = 0xE3,
+  [0x03B4] = 0xE4,
+  [0x03B5] = 0xE5,
+  [0x03B6] = 0xE6,
+  [0x03B7] = 0xE7,
+  [0x03B8] = 0xE8,
+  [0x03B9] = 0xE9,
+  [0x03BA] = 0xEA,
+  [0x03BB] = 0xEB,
+  [0x03BC] = 0xEC,
+  [0x03BD] = 0xED,
+  [0x03BE] = 0xEE,
+  [0x03BF] = 0xEF,
+  [0x03C0] = 0xF0,
+  [0x03C1] = 0xF1,
+  [0x03C2] = 0xF2,
+  [0x03C3] = 0xF3,
+  [0x03C4] = 0xF4,
+  [0x03C5] = 0xF5,
+  [0x03C6] = 0xF6,
+  [0x03C7] = 0xF7,
+  [0x03C8] = 0xF8,
+  [0x03C9] = 0xF9,
+  [0x03CA] = 0xFA,
+  [0x03CB] = 0xFB,
+  [0x03CC] = 0xFC,
+  [0x03CD] = 0xFD,
+  [0x03CE] = 0xFE,
+  [0x2014] = 0xAF,
+  [0x2019] = 0xA2,
+  [0x201B] = 0xA1,
+};
diff --git a/iconvdata/iso8859-8.c b/iconvdata/iso8859-8.c
new file mode 100644
index 0000000000..ee69754cea
--- /dev/null
+++ b/iconvdata/iso8859-8.c
@@ -0,0 +1,24 @@
+/* Conversion from and to ISO 8859-8.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <wchar.h>
+#include <iso8859-8.h>
+#define NAME "ISO-8859-8"
+#include <iso8859-generic.c>
diff --git a/iconvdata/iso8859-8.h b/iconvdata/iso8859-8.h
new file mode 100644
index 0000000000..bdccec689c
--- /dev/null
+++ b/iconvdata/iso8859-8.h
@@ -0,0 +1,440 @@
+static const wchar_t to_ucs4[256] = {
+  [0x00] = 0x0000,
+  [0x01] = 0x0001,
+  [0x02] = 0x0002,
+  [0x03] = 0x0003,
+  [0x04] = 0x0004,
+  [0x05] = 0x0005,
+  [0x06] = 0x0006,
+  [0x07] = 0x0007,
+  [0x08] = 0x0008,
+  [0x09] = 0x0009,
+  [0x0A] = 0x000A,
+  [0x0B] = 0x000B,
+  [0x0C] = 0x000C,
+  [0x0D] = 0x000D,
+  [0x0E] = 0x000E,
+  [0x0F] = 0x000F,
+  [0x10] = 0x0010,
+  [0x11] = 0x0011,
+  [0x12] = 0x0012,
+  [0x13] = 0x0013,
+  [0x14] = 0x0014,
+  [0x15] = 0x0015,
+  [0x16] = 0x0016,
+  [0x17] = 0x0017,
+  [0x18] = 0x0018,
+  [0x19] = 0x0019,
+  [0x1A] = 0x001A,
+  [0x1B] = 0x001B,
+  [0x1C] = 0x001C,
+  [0x1D] = 0x001D,
+  [0x1E] = 0x001E,
+  [0x1F] = 0x001F,
+  [0x20] = 0x0020,
+  [0x21] = 0x0021,
+  [0x22] = 0x0022,
+  [0x23] = 0x0023,
+  [0x24] = 0x0024,
+  [0x25] = 0x0025,
+  [0x26] = 0x0026,
+  [0x27] = 0x0027,
+  [0x28] = 0x0028,
+  [0x29] = 0x0029,
+  [0x2A] = 0x002A,
+  [0x2B] = 0x002B,
+  [0x2C] = 0x002C,
+  [0x2D] = 0x002D,
+  [0x2E] = 0x002E,
+  [0x2F] = 0x002F,
+  [0x30] = 0x0030,
+  [0x31] = 0x0031,
+  [0x32] = 0x0032,
+  [0x33] = 0x0033,
+  [0x34] = 0x0034,
+  [0x35] = 0x0035,
+  [0x36] = 0x0036,
+  [0x37] = 0x0037,
+  [0x38] = 0x0038,
+  [0x39] = 0x0039,
+  [0x3A] = 0x003A,
+  [0x3B] = 0x003B,
+  [0x3C] = 0x003C,
+  [0x3D] = 0x003D,
+  [0x3E] = 0x003E,
+  [0x3F] = 0x003F,
+  [0x40] = 0x0040,
+  [0x41] = 0x0041,
+  [0x42] = 0x0042,
+  [0x43] = 0x0043,
+  [0x44] = 0x0044,
+  [0x45] = 0x0045,
+  [0x46] = 0x0046,
+  [0x47] = 0x0047,
+  [0x48] = 0x0048,
+  [0x49] = 0x0049,
+  [0x4A] = 0x004A,
+  [0x4B] = 0x004B,
+  [0x4C] = 0x004C,
+  [0x4D] = 0x004D,
+  [0x4E] = 0x004E,
+  [0x4F] = 0x004F,
+  [0x50] = 0x0050,
+  [0x51] = 0x0051,
+  [0x52] = 0x0052,
+  [0x53] = 0x0053,
+  [0x54] = 0x0054,
+  [0x55] = 0x0055,
+  [0x56] = 0x0056,
+  [0x57] = 0x0057,
+  [0x58] = 0x0058,
+  [0x59] = 0x0059,
+  [0x5A] = 0x005A,
+  [0x5B] = 0x005B,
+  [0x5C] = 0x005C,
+  [0x5D] = 0x005D,
+  [0x5E] = 0x005E,
+  [0x5F] = 0x005F,
+  [0x60] = 0x0060,
+  [0x61] = 0x0061,
+  [0x62] = 0x0062,
+  [0x63] = 0x0063,
+  [0x64] = 0x0064,
+  [0x65] = 0x0065,
+  [0x66] = 0x0066,
+  [0x67] = 0x0067,
+  [0x68] = 0x0068,
+  [0x69] = 0x0069,
+  [0x6A] = 0x006A,
+  [0x6B] = 0x006B,
+  [0x6C] = 0x006C,
+  [0x6D] = 0x006D,
+  [0x6E] = 0x006E,
+  [0x6F] = 0x006F,
+  [0x70] = 0x0070,
+  [0x71] = 0x0071,
+  [0x72] = 0x0072,
+  [0x73] = 0x0073,
+  [0x74] = 0x0074,
+  [0x75] = 0x0075,
+  [0x76] = 0x0076,
+  [0x77] = 0x0077,
+  [0x78] = 0x0078,
+  [0x79] = 0x0079,
+  [0x7A] = 0x007A,
+  [0x7B] = 0x007B,
+  [0x7C] = 0x007C,
+  [0x7D] = 0x007D,
+  [0x7E] = 0x007E,
+  [0x7F] = 0x007F,
+  [0x80] = 0x0080,
+  [0x81] = 0x0081,
+  [0x82] = 0x0082,
+  [0x83] = 0x0083,
+  [0x84] = 0x0084,
+  [0x85] = 0x0085,
+  [0x86] = 0x0086,
+  [0x87] = 0x0087,
+  [0x88] = 0x0088,
+  [0x89] = 0x0089,
+  [0x8A] = 0x008A,
+  [0x8B] = 0x008B,
+  [0x8C] = 0x008C,
+  [0x8D] = 0x008D,
+  [0x8E] = 0x008E,
+  [0x8F] = 0x008F,
+  [0x90] = 0x0090,
+  [0x91] = 0x0091,
+  [0x92] = 0x0092,
+  [0x93] = 0x0093,
+  [0x94] = 0x0094,
+  [0x95] = 0x0095,
+  [0x96] = 0x0096,
+  [0x97] = 0x0097,
+  [0x98] = 0x0098,
+  [0x99] = 0x0099,
+  [0x9A] = 0x009A,
+  [0x9B] = 0x009B,
+  [0x9C] = 0x009C,
+  [0x9D] = 0x009D,
+  [0x9E] = 0x009E,
+  [0x9F] = 0x009F,
+  [0xA0] = 0x00A0,
+  [0xA2] = 0x00A2,
+  [0xA3] = 0x00A3,
+  [0xA4] = 0x00A4,
+  [0xA5] = 0x00A5,
+  [0xA6] = 0x00A6,
+  [0xA7] = 0x00A7,
+  [0xA8] = 0x00A8,
+  [0xA9] = 0x00A9,
+  [0xAA] = 0x00D7,
+  [0xAB] = 0x00AB,
+  [0xAC] = 0x00AC,
+  [0xAD] = 0x00AD,
+  [0xAE] = 0x00AE,
+  [0xAF] = 0x203E,
+  [0xB0] = 0x00B0,
+  [0xB1] = 0x00B1,
+  [0xB2] = 0x00B2,
+  [0xB3] = 0x00B3,
+  [0xB4] = 0x00B4,
+  [0xB5] = 0x00B5,
+  [0xB6] = 0x00B6,
+  [0xB7] = 0x00B7,
+  [0xB8] = 0x00B8,
+  [0xB9] = 0x00B9,
+  [0xBA] = 0x00F7,
+  [0xBB] = 0x00BB,
+  [0xBC] = 0x00BC,
+  [0xBD] = 0x00BD,
+  [0xBE] = 0x00BE,
+  [0xDF] = 0x2017,
+  [0xE0] = 0x05D0,
+  [0xE1] = 0x05D1,
+  [0xE2] = 0x05D2,
+  [0xE3] = 0x05D3,
+  [0xE4] = 0x05D4,
+  [0xE5] = 0x05D5,
+  [0xE6] = 0x05D6,
+  [0xE7] = 0x05D7,
+  [0xE8] = 0x05D8,
+  [0xE9] = 0x05D9,
+  [0xEA] = 0x05DA,
+  [0xEB] = 0x05DB,
+  [0xEC] = 0x05DC,
+  [0xED] = 0x05DD,
+  [0xEE] = 0x05DE,
+  [0xEF] = 0x05DF,
+  [0xF0] = 0x05E0,
+  [0xF1] = 0x05E1,
+  [0xF2] = 0x05E2,
+  [0xF3] = 0x05E3,
+  [0xF4] = 0x05E4,
+  [0xF5] = 0x05E5,
+  [0xF6] = 0x05E6,
+  [0xF7] = 0x05E7,
+  [0xF8] = 0x05E8,
+  [0xF9] = 0x05E9,
+  [0xFA] = 0x05EA,
+};
+static const char from_ucs4[] = {
+  [0x0000] = 0x00,
+  [0x0001] = 0x01,
+  [0x0002] = 0x02,
+  [0x0003] = 0x03,
+  [0x0004] = 0x04,
+  [0x0005] = 0x05,
+  [0x0006] = 0x06,
+  [0x0007] = 0x07,
+  [0x0008] = 0x08,
+  [0x0009] = 0x09,
+  [0x000A] = 0x0A,
+  [0x000B] = 0x0B,
+  [0x000C] = 0x0C,
+  [0x000D] = 0x0D,
+  [0x000E] = 0x0E,
+  [0x000F] = 0x0F,
+  [0x0010] = 0x10,
+  [0x0011] = 0x11,
+  [0x0012] = 0x12,
+  [0x0013] = 0x13,
+  [0x0014] = 0x14,
+  [0x0015] = 0x15,
+  [0x0016] = 0x16,
+  [0x0017] = 0x17,
+  [0x0018] = 0x18,
+  [0x0019] = 0x19,
+  [0x001A] = 0x1A,
+  [0x001B] = 0x1B,
+  [0x001C] = 0x1C,
+  [0x001D] = 0x1D,
+  [0x001E] = 0x1E,
+  [0x001F] = 0x1F,
+  [0x0020] = 0x20,
+  [0x0021] = 0x21,
+  [0x0022] = 0x22,
+  [0x0023] = 0x23,
+  [0x0024] = 0x24,
+  [0x0025] = 0x25,
+  [0x0026] = 0x26,
+  [0x0027] = 0x27,
+  [0x0028] = 0x28,
+  [0x0029] = 0x29,
+  [0x002A] = 0x2A,
+  [0x002B] = 0x2B,
+  [0x002C] = 0x2C,
+  [0x002D] = 0x2D,
+  [0x002E] = 0x2E,
+  [0x002F] = 0x2F,
+  [0x0030] = 0x30,
+  [0x0031] = 0x31,
+  [0x0032] = 0x32,
+  [0x0033] = 0x33,
+  [0x0034] = 0x34,
+  [0x0035] = 0x35,
+  [0x0036] = 0x36,
+  [0x0037] = 0x37,
+  [0x0038] = 0x38,
+  [0x0039] = 0x39,
+  [0x003A] = 0x3A,
+  [0x003B] = 0x3B,
+  [0x003C] = 0x3C,
+  [0x003D] = 0x3D,
+  [0x003E] = 0x3E,
+  [0x003F] = 0x3F,
+  [0x0040] = 0x40,
+  [0x0041] = 0x41,
+  [0x0042] = 0x42,
+  [0x0043] = 0x43,
+  [0x0044] = 0x44,
+  [0x0045] = 0x45,
+  [0x0046] = 0x46,
+  [0x0047] = 0x47,
+  [0x0048] = 0x48,
+  [0x0049] = 0x49,
+  [0x004A] = 0x4A,
+  [0x004B] = 0x4B,
+  [0x004C] = 0x4C,
+  [0x004D] = 0x4D,
+  [0x004E] = 0x4E,
+  [0x004F] = 0x4F,
+  [0x0050] = 0x50,
+  [0x0051] = 0x51,
+  [0x0052] = 0x52,
+  [0x0053] = 0x53,
+  [0x0054] = 0x54,
+  [0x0055] = 0x55,
+  [0x0056] = 0x56,
+  [0x0057] = 0x57,
+  [0x0058] = 0x58,
+  [0x0059] = 0x59,
+  [0x005A] = 0x5A,
+  [0x005B] = 0x5B,
+  [0x005C] = 0x5C,
+  [0x005D] = 0x5D,
+  [0x005E] = 0x5E,
+  [0x005F] = 0x5F,
+  [0x0060] = 0x60,
+  [0x0061] = 0x61,
+  [0x0062] = 0x62,
+  [0x0063] = 0x63,
+  [0x0064] = 0x64,
+  [0x0065] = 0x65,
+  [0x0066] = 0x66,
+  [0x0067] = 0x67,
+  [0x0068] = 0x68,
+  [0x0069] = 0x69,
+  [0x006A] = 0x6A,
+  [0x006B] = 0x6B,
+  [0x006C] = 0x6C,
+  [0x006D] = 0x6D,
+  [0x006E] = 0x6E,
+  [0x006F] = 0x6F,
+  [0x0070] = 0x70,
+  [0x0071] = 0x71,
+  [0x0072] = 0x72,
+  [0x0073] = 0x73,
+  [0x0074] = 0x74,
+  [0x0075] = 0x75,
+  [0x0076] = 0x76,
+  [0x0077] = 0x77,
+  [0x0078] = 0x78,
+  [0x0079] = 0x79,
+  [0x007A] = 0x7A,
+  [0x007B] = 0x7B,
+  [0x007C] = 0x7C,
+  [0x007D] = 0x7D,
+  [0x007E] = 0x7E,
+  [0x007F] = 0x7F,
+  [0x0080] = 0x80,
+  [0x0081] = 0x81,
+  [0x0082] = 0x82,
+  [0x0083] = 0x83,
+  [0x0084] = 0x84,
+  [0x0085] = 0x85,
+  [0x0086] = 0x86,
+  [0x0087] = 0x87,
+  [0x0088] = 0x88,
+  [0x0089] = 0x89,
+  [0x008A] = 0x8A,
+  [0x008B] = 0x8B,
+  [0x008C] = 0x8C,
+  [0x008D] = 0x8D,
+  [0x008E] = 0x8E,
+  [0x008F] = 0x8F,
+  [0x0090] = 0x90,
+  [0x0091] = 0x91,
+  [0x0092] = 0x92,
+  [0x0093] = 0x93,
+  [0x0094] = 0x94,
+  [0x0095] = 0x95,
+  [0x0096] = 0x96,
+  [0x0097] = 0x97,
+  [0x0098] = 0x98,
+  [0x0099] = 0x99,
+  [0x009A] = 0x9A,
+  [0x009B] = 0x9B,
+  [0x009C] = 0x9C,
+  [0x009D] = 0x9D,
+  [0x009E] = 0x9E,
+  [0x009F] = 0x9F,
+  [0x00A0] = 0xA0,
+  [0x00A2] = 0xA2,
+  [0x00A3] = 0xA3,
+  [0x00A4] = 0xA4,
+  [0x00A5] = 0xA5,
+  [0x00A6] = 0xA6,
+  [0x00A7] = 0xA7,
+  [0x00A8] = 0xA8,
+  [0x00A9] = 0xA9,
+  [0x00AB] = 0xAB,
+  [0x00AC] = 0xAC,
+  [0x00AD] = 0xAD,
+  [0x00AE] = 0xAE,
+  [0x00B0] = 0xB0,
+  [0x00B1] = 0xB1,
+  [0x00B2] = 0xB2,
+  [0x00B3] = 0xB3,
+  [0x00B4] = 0xB4,
+  [0x00B5] = 0xB5,
+  [0x00B6] = 0xB6,
+  [0x00B7] = 0xB7,
+  [0x00B8] = 0xB8,
+  [0x00B9] = 0xB9,
+  [0x00BB] = 0xBB,
+  [0x00BC] = 0xBC,
+  [0x00BD] = 0xBD,
+  [0x00BE] = 0xBE,
+  [0x00D7] = 0xAA,
+  [0x00F7] = 0xBA,
+  [0x05D0] = 0xE0,
+  [0x05D1] = 0xE1,
+  [0x05D2] = 0xE2,
+  [0x05D3] = 0xE3,
+  [0x05D4] = 0xE4,
+  [0x05D5] = 0xE5,
+  [0x05D6] = 0xE6,
+  [0x05D7] = 0xE7,
+  [0x05D8] = 0xE8,
+  [0x05D9] = 0xE9,
+  [0x05DA] = 0xEA,
+  [0x05DB] = 0xEB,
+  [0x05DC] = 0xEC,
+  [0x05DD] = 0xED,
+  [0x05DE] = 0xEE,
+  [0x05DF] = 0xEF,
+  [0x05E0] = 0xF0,
+  [0x05E1] = 0xF1,
+  [0x05E2] = 0xF2,
+  [0x05E3] = 0xF3,
+  [0x05E4] = 0xF4,
+  [0x05E5] = 0xF5,
+  [0x05E6] = 0xF6,
+  [0x05E7] = 0xF7,
+  [0x05E8] = 0xF8,
+  [0x05E9] = 0xF9,
+  [0x05EA] = 0xFA,
+  [0x2017] = 0xDF,
+  [0x203E] = 0xAF,
+};
diff --git a/iconvdata/iso8859-9.c b/iconvdata/iso8859-9.c
new file mode 100644
index 0000000000..5485de26f1
--- /dev/null
+++ b/iconvdata/iso8859-9.c
@@ -0,0 +1,24 @@
+/* Conversion from and to ISO 8859-9.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <wchar.h>
+#include <iso8859-9.h>
+#define NAME "ISO-8859-9"
+#include <iso8859-generic.c>
diff --git a/iconvdata/iso8859-9.h b/iconvdata/iso8859-9.h
new file mode 100644
index 0000000000..f5794231c0
--- /dev/null
+++ b/iconvdata/iso8859-9.h
@@ -0,0 +1,516 @@
+static const wchar_t to_ucs4[256] = {
+  [0x00] = 0x0000,
+  [0x01] = 0x0001,
+  [0x02] = 0x0002,
+  [0x03] = 0x0003,
+  [0x04] = 0x0004,
+  [0x05] = 0x0005,
+  [0x06] = 0x0006,
+  [0x07] = 0x0007,
+  [0x08] = 0x0008,
+  [0x09] = 0x0009,
+  [0x0A] = 0x000A,
+  [0x0B] = 0x000B,
+  [0x0C] = 0x000C,
+  [0x0D] = 0x000D,
+  [0x0E] = 0x000E,
+  [0x0F] = 0x000F,
+  [0x10] = 0x0010,
+  [0x11] = 0x0011,
+  [0x12] = 0x0012,
+  [0x13] = 0x0013,
+  [0x14] = 0x0014,
+  [0x15] = 0x0015,
+  [0x16] = 0x0016,
+  [0x17] = 0x0017,
+  [0x18] = 0x0018,
+  [0x19] = 0x0019,
+  [0x1A] = 0x001A,
+  [0x1B] = 0x001B,
+  [0x1C] = 0x001C,
+  [0x1D] = 0x001D,
+  [0x1E] = 0x001E,
+  [0x1F] = 0x001F,
+  [0x20] = 0x0020,
+  [0x21] = 0x0021,
+  [0x22] = 0x0022,
+  [0x23] = 0x0023,
+  [0x24] = 0x0024,
+  [0x25] = 0x0025,
+  [0x26] = 0x0026,
+  [0x27] = 0x0027,
+  [0x28] = 0x0028,
+  [0x29] = 0x0029,
+  [0x2A] = 0x002A,
+  [0x2B] = 0x002B,
+  [0x2C] = 0x002C,
+  [0x2D] = 0x002D,
+  [0x2E] = 0x002E,
+  [0x2F] = 0x002F,
+  [0x30] = 0x0030,
+  [0x31] = 0x0031,
+  [0x32] = 0x0032,
+  [0x33] = 0x0033,
+  [0x34] = 0x0034,
+  [0x35] = 0x0035,
+  [0x36] = 0x0036,
+  [0x37] = 0x0037,
+  [0x38] = 0x0038,
+  [0x39] = 0x0039,
+  [0x3A] = 0x003A,
+  [0x3B] = 0x003B,
+  [0x3C] = 0x003C,
+  [0x3D] = 0x003D,
+  [0x3E] = 0x003E,
+  [0x3F] = 0x003F,
+  [0x40] = 0x0040,
+  [0x41] = 0x0041,
+  [0x42] = 0x0042,
+  [0x43] = 0x0043,
+  [0x44] = 0x0044,
+  [0x45] = 0x0045,
+  [0x46] = 0x0046,
+  [0x47] = 0x0047,
+  [0x48] = 0x0048,
+  [0x49] = 0x0049,
+  [0x4A] = 0x004A,
+  [0x4B] = 0x004B,
+  [0x4C] = 0x004C,
+  [0x4D] = 0x004D,
+  [0x4E] = 0x004E,
+  [0x4F] = 0x004F,
+  [0x50] = 0x0050,
+  [0x51] = 0x0051,
+  [0x52] = 0x0052,
+  [0x53] = 0x0053,
+  [0x54] = 0x0054,
+  [0x55] = 0x0055,
+  [0x56] = 0x0056,
+  [0x57] = 0x0057,
+  [0x58] = 0x0058,
+  [0x59] = 0x0059,
+  [0x5A] = 0x005A,
+  [0x5B] = 0x005B,
+  [0x5C] = 0x005C,
+  [0x5D] = 0x005D,
+  [0x5E] = 0x005E,
+  [0x5F] = 0x005F,
+  [0x60] = 0x0060,
+  [0x61] = 0x0061,
+  [0x62] = 0x0062,
+  [0x63] = 0x0063,
+  [0x64] = 0x0064,
+  [0x65] = 0x0065,
+  [0x66] = 0x0066,
+  [0x67] = 0x0067,
+  [0x68] = 0x0068,
+  [0x69] = 0x0069,
+  [0x6A] = 0x006A,
+  [0x6B] = 0x006B,
+  [0x6C] = 0x006C,
+  [0x6D] = 0x006D,
+  [0x6E] = 0x006E,
+  [0x6F] = 0x006F,
+  [0x70] = 0x0070,
+  [0x71] = 0x0071,
+  [0x72] = 0x0072,
+  [0x73] = 0x0073,
+  [0x74] = 0x0074,
+  [0x75] = 0x0075,
+  [0x76] = 0x0076,
+  [0x77] = 0x0077,
+  [0x78] = 0x0078,
+  [0x79] = 0x0079,
+  [0x7A] = 0x007A,
+  [0x7B] = 0x007B,
+  [0x7C] = 0x007C,
+  [0x7D] = 0x007D,
+  [0x7E] = 0x007E,
+  [0x7F] = 0x007F,
+  [0x80] = 0x0080,
+  [0x81] = 0x0081,
+  [0x82] = 0x0082,
+  [0x83] = 0x0083,
+  [0x84] = 0x0084,
+  [0x85] = 0x0085,
+  [0x86] = 0x0086,
+  [0x87] = 0x0087,
+  [0x88] = 0x0088,
+  [0x89] = 0x0089,
+  [0x8A] = 0x008A,
+  [0x8B] = 0x008B,
+  [0x8C] = 0x008C,
+  [0x8D] = 0x008D,
+  [0x8E] = 0x008E,
+  [0x8F] = 0x008F,
+  [0x90] = 0x0090,
+  [0x91] = 0x0091,
+  [0x92] = 0x0092,
+  [0x93] = 0x0093,
+  [0x94] = 0x0094,
+  [0x95] = 0x0095,
+  [0x96] = 0x0096,
+  [0x97] = 0x0097,
+  [0x98] = 0x0098,
+  [0x99] = 0x0099,
+  [0x9A] = 0x009A,
+  [0x9B] = 0x009B,
+  [0x9C] = 0x009C,
+  [0x9D] = 0x009D,
+  [0x9E] = 0x009E,
+  [0x9F] = 0x009F,
+  [0xA0] = 0x00A0,
+  [0xA1] = 0x00A1,
+  [0xA2] = 0x00A2,
+  [0xA3] = 0x00A3,
+  [0xA4] = 0x00A4,
+  [0xA5] = 0x00A5,
+  [0xA6] = 0x00A6,
+  [0xA7] = 0x00A7,
+  [0xA8] = 0x00A8,
+  [0xA9] = 0x00A9,
+  [0xAA] = 0x00AA,
+  [0xAB] = 0x00AB,
+  [0xAC] = 0x00AC,
+  [0xAD] = 0x00AD,
+  [0xAE] = 0x00AE,
+  [0xAF] = 0x00AF,
+  [0xB0] = 0x00B0,
+  [0xB1] = 0x00B1,
+  [0xB2] = 0x00B2,
+  [0xB3] = 0x00B3,
+  [0xB4] = 0x00B4,
+  [0xB5] = 0x00B5,
+  [0xB6] = 0x00B6,
+  [0xB7] = 0x00B7,
+  [0xB8] = 0x00B8,
+  [0xB9] = 0x00B9,
+  [0xBA] = 0x00BA,
+  [0xBB] = 0x00BB,
+  [0xBC] = 0x00BC,
+  [0xBD] = 0x00BD,
+  [0xBE] = 0x00BE,
+  [0xBF] = 0x00BF,
+  [0xC0] = 0x00C0,
+  [0xC1] = 0x00C1,
+  [0xC2] = 0x00C2,
+  [0xC3] = 0x00C3,
+  [0xC4] = 0x00C4,
+  [0xC5] = 0x00C5,
+  [0xC6] = 0x00C6,
+  [0xC7] = 0x00C7,
+  [0xC8] = 0x00C8,
+  [0xC9] = 0x00C9,
+  [0xCA] = 0x00CA,
+  [0xCB] = 0x00CB,
+  [0xCC] = 0x00CC,
+  [0xCD] = 0x00CD,
+  [0xCE] = 0x00CE,
+  [0xCF] = 0x00CF,
+  [0xD0] = 0x011E,
+  [0xD1] = 0x00D1,
+  [0xD2] = 0x00D2,
+  [0xD3] = 0x00D3,
+  [0xD4] = 0x00D4,
+  [0xD5] = 0x00D5,
+  [0xD6] = 0x00D6,
+  [0xD7] = 0x00D7,
+  [0xD8] = 0x00D8,
+  [0xD9] = 0x00D9,
+  [0xDA] = 0x00DA,
+  [0xDB] = 0x00DB,
+  [0xDC] = 0x00DC,
+  [0xDD] = 0x0130,
+  [0xDE] = 0x015E,
+  [0xDF] = 0x00DF,
+  [0xE0] = 0x00E0,
+  [0xE1] = 0x00E1,
+  [0xE2] = 0x00E2,
+  [0xE3] = 0x00E3,
+  [0xE4] = 0x00E4,
+  [0xE5] = 0x00E5,
+  [0xE6] = 0x00E6,
+  [0xE7] = 0x00E7,
+  [0xE8] = 0x00E8,
+  [0xE9] = 0x00E9,
+  [0xEA] = 0x0119,
+  [0xEB] = 0x00EB,
+  [0xEC] = 0x0117,
+  [0xED] = 0x00ED,
+  [0xEE] = 0x00EE,
+  [0xEF] = 0x012B,
+  [0xF0] = 0x011F,
+  [0xF1] = 0x00F1,
+  [0xF2] = 0x00F2,
+  [0xF3] = 0x00F3,
+  [0xF4] = 0x00F4,
+  [0xF5] = 0x00F5,
+  [0xF6] = 0x00F6,
+  [0xF7] = 0x00F7,
+  [0xF8] = 0x00F8,
+  [0xF9] = 0x00F9,
+  [0xFA] = 0x00FA,
+  [0xFB] = 0x00FB,
+  [0xFC] = 0x00FC,
+  [0xFD] = 0x0131,
+  [0xFE] = 0x015F,
+  [0xFF] = 0x00FF,
+};
+static const char from_ucs4[] = {
+  [0x0000] = 0x00,
+  [0x0001] = 0x01,
+  [0x0002] = 0x02,
+  [0x0003] = 0x03,
+  [0x0004] = 0x04,
+  [0x0005] = 0x05,
+  [0x0006] = 0x06,
+  [0x0007] = 0x07,
+  [0x0008] = 0x08,
+  [0x0009] = 0x09,
+  [0x000A] = 0x0A,
+  [0x000B] = 0x0B,
+  [0x000C] = 0x0C,
+  [0x000D] = 0x0D,
+  [0x000E] = 0x0E,
+  [0x000F] = 0x0F,
+  [0x0010] = 0x10,
+  [0x0011] = 0x11,
+  [0x0012] = 0x12,
+  [0x0013] = 0x13,
+  [0x0014] = 0x14,
+  [0x0015] = 0x15,
+  [0x0016] = 0x16,
+  [0x0017] = 0x17,
+  [0x0018] = 0x18,
+  [0x0019] = 0x19,
+  [0x001A] = 0x1A,
+  [0x001B] = 0x1B,
+  [0x001C] = 0x1C,
+  [0x001D] = 0x1D,
+  [0x001E] = 0x1E,
+  [0x001F] = 0x1F,
+  [0x0020] = 0x20,
+  [0x0021] = 0x21,
+  [0x0022] = 0x22,
+  [0x0023] = 0x23,
+  [0x0024] = 0x24,
+  [0x0025] = 0x25,
+  [0x0026] = 0x26,
+  [0x0027] = 0x27,
+  [0x0028] = 0x28,
+  [0x0029] = 0x29,
+  [0x002A] = 0x2A,
+  [0x002B] = 0x2B,
+  [0x002C] = 0x2C,
+  [0x002D] = 0x2D,
+  [0x002E] = 0x2E,
+  [0x002F] = 0x2F,
+  [0x0030] = 0x30,
+  [0x0031] = 0x31,
+  [0x0032] = 0x32,
+  [0x0033] = 0x33,
+  [0x0034] = 0x34,
+  [0x0035] = 0x35,
+  [0x0036] = 0x36,
+  [0x0037] = 0x37,
+  [0x0038] = 0x38,
+  [0x0039] = 0x39,
+  [0x003A] = 0x3A,
+  [0x003B] = 0x3B,
+  [0x003C] = 0x3C,
+  [0x003D] = 0x3D,
+  [0x003E] = 0x3E,
+  [0x003F] = 0x3F,
+  [0x0040] = 0x40,
+  [0x0041] = 0x41,
+  [0x0042] = 0x42,
+  [0x0043] = 0x43,
+  [0x0044] = 0x44,
+  [0x0045] = 0x45,
+  [0x0046] = 0x46,
+  [0x0047] = 0x47,
+  [0x0048] = 0x48,
+  [0x0049] = 0x49,
+  [0x004A] = 0x4A,
+  [0x004B] = 0x4B,
+  [0x004C] = 0x4C,
+  [0x004D] = 0x4D,
+  [0x004E] = 0x4E,
+  [0x004F] = 0x4F,
+  [0x0050] = 0x50,
+  [0x0051] = 0x51,
+  [0x0052] = 0x52,
+  [0x0053] = 0x53,
+  [0x0054] = 0x54,
+  [0x0055] = 0x55,
+  [0x0056] = 0x56,
+  [0x0057] = 0x57,
+  [0x0058] = 0x58,
+  [0x0059] = 0x59,
+  [0x005A] = 0x5A,
+  [0x005B] = 0x5B,
+  [0x005C] = 0x5C,
+  [0x005D] = 0x5D,
+  [0x005E] = 0x5E,
+  [0x005F] = 0x5F,
+  [0x0060] = 0x60,
+  [0x0061] = 0x61,
+  [0x0062] = 0x62,
+  [0x0063] = 0x63,
+  [0x0064] = 0x64,
+  [0x0065] = 0x65,
+  [0x0066] = 0x66,
+  [0x0067] = 0x67,
+  [0x0068] = 0x68,
+  [0x0069] = 0x69,
+  [0x006A] = 0x6A,
+  [0x006B] = 0x6B,
+  [0x006C] = 0x6C,
+  [0x006D] = 0x6D,
+  [0x006E] = 0x6E,
+  [0x006F] = 0x6F,
+  [0x0070] = 0x70,
+  [0x0071] = 0x71,
+  [0x0072] = 0x72,
+  [0x0073] = 0x73,
+  [0x0074] = 0x74,
+  [0x0075] = 0x75,
+  [0x0076] = 0x76,
+  [0x0077] = 0x77,
+  [0x0078] = 0x78,
+  [0x0079] = 0x79,
+  [0x007A] = 0x7A,
+  [0x007B] = 0x7B,
+  [0x007C] = 0x7C,
+  [0x007D] = 0x7D,
+  [0x007E] = 0x7E,
+  [0x007F] = 0x7F,
+  [0x0080] = 0x80,
+  [0x0081] = 0x81,
+  [0x0082] = 0x82,
+  [0x0083] = 0x83,
+  [0x0084] = 0x84,
+  [0x0085] = 0x85,
+  [0x0086] = 0x86,
+  [0x0087] = 0x87,
+  [0x0088] = 0x88,
+  [0x0089] = 0x89,
+  [0x008A] = 0x8A,
+  [0x008B] = 0x8B,
+  [0x008C] = 0x8C,
+  [0x008D] = 0x8D,
+  [0x008E] = 0x8E,
+  [0x008F] = 0x8F,
+  [0x0090] = 0x90,
+  [0x0091] = 0x91,
+  [0x0092] = 0x92,
+  [0x0093] = 0x93,
+  [0x0094] = 0x94,
+  [0x0095] = 0x95,
+  [0x0096] = 0x96,
+  [0x0097] = 0x97,
+  [0x0098] = 0x98,
+  [0x0099] = 0x99,
+  [0x009A] = 0x9A,
+  [0x009B] = 0x9B,
+  [0x009C] = 0x9C,
+  [0x009D] = 0x9D,
+  [0x009E] = 0x9E,
+  [0x009F] = 0x9F,
+  [0x00A0] = 0xA0,
+  [0x00A1] = 0xA1,
+  [0x00A2] = 0xA2,
+  [0x00A3] = 0xA3,
+  [0x00A4] = 0xA4,
+  [0x00A5] = 0xA5,
+  [0x00A6] = 0xA6,
+  [0x00A7] = 0xA7,
+  [0x00A8] = 0xA8,
+  [0x00A9] = 0xA9,
+  [0x00AA] = 0xAA,
+  [0x00AB] = 0xAB,
+  [0x00AC] = 0xAC,
+  [0x00AD] = 0xAD,
+  [0x00AE] = 0xAE,
+  [0x00AF] = 0xAF,
+  [0x00B0] = 0xB0,
+  [0x00B1] = 0xB1,
+  [0x00B2] = 0xB2,
+  [0x00B3] = 0xB3,
+  [0x00B4] = 0xB4,
+  [0x00B5] = 0xB5,
+  [0x00B6] = 0xB6,
+  [0x00B7] = 0xB7,
+  [0x00B8] = 0xB8,
+  [0x00B9] = 0xB9,
+  [0x00BA] = 0xBA,
+  [0x00BB] = 0xBB,
+  [0x00BC] = 0xBC,
+  [0x00BD] = 0xBD,
+  [0x00BE] = 0xBE,
+  [0x00BF] = 0xBF,
+  [0x00C0] = 0xC0,
+  [0x00C1] = 0xC1,
+  [0x00C2] = 0xC2,
+  [0x00C3] = 0xC3,
+  [0x00C4] = 0xC4,
+  [0x00C5] = 0xC5,
+  [0x00C6] = 0xC6,
+  [0x00C7] = 0xC7,
+  [0x00C8] = 0xC8,
+  [0x00C9] = 0xC9,
+  [0x00CA] = 0xCA,
+  [0x00CB] = 0xCB,
+  [0x00CC] = 0xCC,
+  [0x00CD] = 0xCD,
+  [0x00CE] = 0xCE,
+  [0x00CF] = 0xCF,
+  [0x00D1] = 0xD1,
+  [0x00D2] = 0xD2,
+  [0x00D3] = 0xD3,
+  [0x00D4] = 0xD4,
+  [0x00D5] = 0xD5,
+  [0x00D6] = 0xD6,
+  [0x00D7] = 0xD7,
+  [0x00D8] = 0xD8,
+  [0x00D9] = 0xD9,
+  [0x00DA] = 0xDA,
+  [0x00DB] = 0xDB,
+  [0x00DC] = 0xDC,
+  [0x00DF] = 0xDF,
+  [0x00E0] = 0xE0,
+  [0x00E1] = 0xE1,
+  [0x00E2] = 0xE2,
+  [0x00E3] = 0xE3,
+  [0x00E4] = 0xE4,
+  [0x00E5] = 0xE5,
+  [0x00E6] = 0xE6,
+  [0x00E7] = 0xE7,
+  [0x00E8] = 0xE8,
+  [0x00E9] = 0xE9,
+  [0x00EB] = 0xEB,
+  [0x00ED] = 0xED,
+  [0x00EE] = 0xEE,
+  [0x00F1] = 0xF1,
+  [0x00F2] = 0xF2,
+  [0x00F3] = 0xF3,
+  [0x00F4] = 0xF4,
+  [0x00F5] = 0xF5,
+  [0x00F6] = 0xF6,
+  [0x00F7] = 0xF7,
+  [0x00F8] = 0xF8,
+  [0x00F9] = 0xF9,
+  [0x00FA] = 0xFA,
+  [0x00FB] = 0xFB,
+  [0x00FC] = 0xFC,
+  [0x00FF] = 0xFF,
+  [0x0117] = 0xEC,
+  [0x0119] = 0xEA,
+  [0x011E] = 0xD0,
+  [0x011F] = 0xF0,
+  [0x012B] = 0xEF,
+  [0x0130] = 0xDD,
+  [0x0131] = 0xFD,
+  [0x015E] = 0xDE,
+  [0x015F] = 0xFE,
+};
diff --git a/iconvdata/iso8859-generic.c b/iconvdata/iso8859-generic.c
new file mode 100644
index 0000000000..e33e1d0a87
--- /dev/null
+++ b/iconvdata/iso8859-generic.c
@@ -0,0 +1,228 @@
+/* Generic conversion to and from ISO 8859-XXX.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <gconv.h>
+#include <stdlib.h>
+#include <string.h>
+
+/* Direction of the transformation.  */
+enum direction
+{
+  illegal,
+  to_iso8859,
+  from_iso8859
+};
+
+struct iso8859_data
+{
+  enum direction dir;
+};
+
+
+int
+gconv_init (struct gconv_step *step, struct gconv_step_data *data)
+{
+  /* Determine which direction.  */
+  struct iso8859_data *new_data;
+  enum direction dir;
+  int result;
+
+  if (__strcasestr (step->from_name, NAME) != NULL)
+    dir = from_iso8859;
+  else if (__strcasestr (step->to_name, NAME) != NULL)
+    dir = to_iso8859;
+  else
+    dir = illegal;
+
+  result = GCONV_NOCONV;
+  if (dir != illegal
+      && ((new_data
+	   = (struct iso8859_data *) malloc (sizeof (struct iso8859_data)))
+	  != NULL))
+    {
+      new_data->dir = dir;
+      data->data = new_data;
+      result = GCONV_OK;
+    }
+
+  return result;
+}
+
+
+void
+gconv_end (struct gconv_step_data *data)
+{
+  free (data->data);
+}
+
+
+int
+gconv (struct gconv_step *step, struct gconv_step_data *data,
+       const char *inbuf, size_t *inbufsize, size_t *written, int do_flush)
+{
+  struct gconv_step *next_step = step + 1;
+  struct gconv_step_data *next_data = data + 1;
+  gconv_fct fct = next_step->fct;
+  size_t do_write;
+  int result;
+
+  /* If the function is called with no input this means we have to reset
+     to the initial state.  The possibly partly converted input is
+     dropped.  */
+  if (do_flush)
+    {
+      do_write = 0;
+
+      /* Call the steps down the chain if there are any.  */
+      if (data->is_last)
+	result = GCONV_OK;
+      else
+	{
+	  struct gconv_step *next_step = step + 1;
+	  struct gconv_step_data *next_data = data + 1;
+
+	  result = (*fct) (next_step, next_data, NULL, 0, written, 1);
+
+	  /* Clear output buffer.  */
+	  data->outbufavail = 0;
+	}
+    }
+  else
+    {
+      enum direction dir = ((struct iso8859_data *) data->data)->dir;
+
+      do_write = 0;
+
+      do
+	{
+	  result = GCONV_OK;
+
+	  if (dir == from_iso8859)
+	    {
+	      size_t inchars = *inbufsize;
+	      size_t outwchars = data->outbufavail;
+	      char *outbuf = data->outbuf;
+	      size_t cnt = 0;
+
+	      while (cnt < inchars
+		     && (outwchars + sizeof (wchar_t) <= data->outbufsize))
+		{
+		  wchar_t ch = to_ucs4[(int) inbuf[cnt]];
+
+		  if (ch == L'\0' && inbuf[cnt] != '\0')
+		    {
+		      /* This is an illegal character.  */
+		      result = GCONV_ILLEGAL_INPUT;
+		      break;
+		    }
+
+		  *((wchar_t *) (outbuf + outwchars)) = ch;
+		  ++do_write;
+		  outwchars += sizeof (wchar_t);
+		  ++cnt;
+		}
+	      *inbufsize -= cnt;
+	      data->outbufavail = outwchars;
+	    }
+	  else
+	    {
+	      size_t inwchars = *inbufsize;
+	      size_t outchars = data->outbufavail;
+	      char *outbuf = data->outbuf;
+	      size_t cnt = 0;
+
+	      while (inwchars >= cnt + sizeof (wchar_t)
+		     && outchars < data->outbufsize)
+		{
+		  int ch = *((wchar_t *) (inbuf + cnt));
+
+		  if (ch >= sizeof (from_ucs4) / sizeof (from_ucs4[0])
+		      || ch < 0 || (from_ucs4[ch] == '\0' && ch != 0))
+		    break;
+
+		  outbuf[outchars] = from_ucs4[ch];
+		  ++do_write;
+		  ++outchars;
+		  cnt += sizeof (wchar_t);
+		}
+	      *inbufsize -= cnt;
+	      data->outbufavail = outchars;
+
+	      if (outchars < data->outbufsize)
+		{
+		  /* If there is still room in the output buffer something
+		     is wrong with the input.  */
+		  if (inwchars >= cnt + sizeof (wchar_t))
+		    {
+		      /* An error occurred.  */
+		      result = GCONV_ILLEGAL_INPUT;
+		      break;
+		    }
+		  if (inwchars != cnt)
+		    {
+		      /* There are some unprocessed bytes at the end of the
+			 input buffer.  */
+		      result = GCONV_INCOMPLETE_INPUT;
+		      break;
+		    }
+		}
+	    }
+
+	  if (result != GCONV_OK)
+	    break;
+
+	  if (data->is_last)
+	    {
+	      /* This is the last step.  */
+	      result = (*inbufsize > (dir == from_iso8859
+				      ? 0 : sizeof (wchar_t) - 1)
+			? GCONV_FULL_OUTPUT : GCONV_EMPTY_INPUT);
+	      break;
+	    }
+
+	  /* Status so far.  */
+	  result = GCONV_EMPTY_INPUT;
+
+	  if (data->outbufavail > 0)
+	    {
+	      /* Call the functions below in the chain.  */
+	      size_t newavail = data->outbufavail;
+
+	      result = (*fct) (next_step, next_data, data->outbuf, &newavail,
+			       written, 0);
+
+	      /* Correct the output buffer.  */
+	      if (newavail != data->outbufavail && newavail > 0)
+		{
+		  memmove (data->outbuf,
+			   &data->outbuf[data->outbufavail - newavail],
+			   newavail);
+		  data->outbufavail = newavail;
+		}
+	    }
+	}
+      while (*inbufsize > 0 && result == GCONV_EMPTY_INPUT);
+    }
+
+  if (written != NULL && data->is_last)
+    *written = do_write;
+
+  return result;
+}
diff --git a/iconvdata/t61.c b/iconvdata/t61.c
new file mode 100644
index 0000000000..915b672d3e
--- /dev/null
+++ b/iconvdata/t61.c
@@ -0,0 +1,630 @@
+/* Generic conversion to and from T.61.
+   Copyright (C) 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
+
+   The GNU C 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.
+
+   The GNU C 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 the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <gconv.h>
+#include <stdlib.h>
+#include <string.h>
+
+/* Data taken from the WG15 tables.  */
+static const wchar_t to_ucs4[256] =
+{
+  /* 0x00 */ 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007,
+  /* 0x08 */ 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f,
+  /* 0x10 */ 0x0010, 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017,
+  /* 0x18 */ 0x0018, 0x0019, 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f,
+  /* 0x20 */ 0x0020, 0x0021, 0x0022, 0x0000, 0x0000, 0x0025, 0x0026, 0x0027,
+  /* 0x28 */ 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f,
+  /* 0x30 */ 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037,
+  /* 0x38 */ 0x0038, 0x0039, 0x003a, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f,
+  /* 0x40 */ 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047,
+  /* 0x48 */ 0x0048, 0x0049, 0x004a, 0x004b, 0x004c, 0x004d, 0x004e, 0x004f,
+  /* 0x50 */ 0x0050, 0x0051, 0x0052, 0x0053, 0x0054, 0x0055, 0x0056, 0x0057,
+  /* 0x58 */ 0x0058, 0x0059, 0x005a, 0x005b, 0x0000, 0x005d, 0x0000, 0x005f,
+  /* 0x60 */ 0x0000, 0x0061, 0x0062, 0x0063, 0x0064, 0x0065, 0x0066, 0x0067,
+  /* 0x68 */ 0x0068, 0x0069, 0x006a, 0x006b, 0x006c, 0x006d, 0x006e, 0x006f,
+  /* 0x70 */ 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077,
+  /* 0x78 */ 0x0078, 0x0079, 0x007a, 0x0000, 0x007c, 0x0000, 0x0000, 0x007f,
+  /* 0x80 */ 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087,
+  /* 0x88 */ 0x0088, 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f,
+  /* 0x90 */ 0x0090, 0x0091, 0x0092, 0x0093, 0x0094, 0x0095, 0x0096, 0x0097,
+  /* 0x98 */ 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, 0x009d, 0x009e, 0x009f,
+  /* 0xa0 */ 0x0000, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7,
+  /* 0xa8 */ 0x00a8, 0x0000, 0x0000, 0x00ab, 0x0000, 0x0000, 0x0000, 0x0000,
+  /* 0xb0 */ 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7,
+  /* 0xb8 */ 0x00b8, 0x0000, 0x0000, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf,
+  /* 0xc0 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+  /* 0xc8 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+  /* 0xd0 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+  /* 0xd8 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+  /* 0xe0 */ 0x2126, 0x00c6, 0x00d0, 0x00aa, 0x0126, 0x0000, 0x0132, 0x013f,
+  /* 0xe8 */ 0x0141, 0x00d8, 0x0152, 0x00ba, 0x00de, 0x0166, 0x014a, 0x0149,
+  /* 0xf0 */ 0x0138, 0x00e6, 0x0111, 0x00f0, 0x0127, 0x0131, 0x0133, 0x0140,
+  /* 0xf8 */ 0x0142, 0x00f8, 0x0153, 0x00df, 0x00fe, 0x0167, 0x014b, 0x0000
+};
+
+/* The outer array range runs from 0xc1 to 0xcf, the inner range from 0x20
+   to 0x7f.  */
+static const wchar_t to_ucs4_comb[15][96] =
+{
+  /* 0xc1 */
+  {
+    /* 0x20 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c0, 0x0000, 0x0000, 0x0000, 0x00c8, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x00cc, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d2,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d9, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e0, 0x0000, 0x0000, 0x0000, 0x00e8, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x00ec, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f2,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f9, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc2 */
+  {
+    /* 0x20 */ 0x00b4, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c1, 0x0000, 0x0106, 0x0000, 0x00c9, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x00cd, 0x0000, 0x0000, 0x0139, 0x0000, 0x0143, 0x00d3,
+    /* 0x50 */ 0x0000, 0x0000, 0x0154, 0x015a, 0x0000, 0x00da, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x00dd, 0x0179, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e1, 0x0000, 0x0107, 0x0000, 0x00e9, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x00ed, 0x0000, 0x0000, 0x013a, 0x0000, 0x0144, 0x00f3,
+    /* 0x70 */ 0x0000, 0x0000, 0x0155, 0x015b, 0x0000, 0x00fa, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x00fd, 0x017a, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc3 */
+  {
+    /* 0x20 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c2, 0x0000, 0x0108, 0x0000, 0x00ca, 0x0000, 0x011c,
+    /* 0x48 */ 0x0124, 0x00ce, 0x0134, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d4,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x015c, 0x0000, 0x00db, 0x0000, 0x0174,
+    /* 0x58 */ 0x0000, 0x0176, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e2, 0x0000, 0x0109, 0x0000, 0x00ea, 0x0000, 0x011d,
+    /* 0x68 */ 0x0125, 0x00ee, 0x0135, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f4,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x015d, 0x0000, 0x00fb, 0x0000, 0x0175,
+    /* 0x78 */ 0x0000, 0x0177, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc4 */
+  {
+    /* 0x20 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c3, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x0128, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d1, 0x00d5,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0168, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e3, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x0129, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f1, 0x00f5,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0169, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc5 */
+  {
+    /* 0x20 */ 0x00af, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0100, 0x0000, 0x0000, 0x0000, 0x0112, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x012a, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x014c,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016a, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0101, 0x0000, 0x0000, 0x0000, 0x0113, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x012b, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x014d,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016b, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc6 */
+  {
+    /* 0x20 */ 0x02d8, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0102, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x011e,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016c, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0103, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x011f,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016d, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc7 */
+  {
+    /* 0x20 */ 0x02d9, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0000, 0x0000, 0x010a, 0x0000, 0x0116, 0x0000, 0x0120,
+    /* 0x48 */ 0x0000, 0x0130, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x017b, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0000, 0x0000, 0x010b, 0x0000, 0x0117, 0x0000, 0x0121,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x017c, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc8 */
+  {
+    /* 0x20 */ 0x00a8, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c4, 0x0000, 0x0000, 0x0000, 0x00cb, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x00cf, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00d6,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00dc, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0178, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e4, 0x0000, 0x0000, 0x0000, 0x00eb, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x00ef, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00f6,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x00fc, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x00ff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xc9 */
+  {
+    0x0000,
+  },
+  /* 0xca */
+  {
+    /* 0x20 */ 0x02da, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x00c5, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016e, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x00e5, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x016f, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xcb */
+  {
+    /* 0x20 */ 0x00b8, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0000, 0x0000, 0x00c7, 0x0000, 0x0000, 0x0000, 0x0122,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0136, 0x013b, 0x0000, 0x0145, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0156, 0x015e, 0x0162, 0x0000, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0000, 0x0000, 0x00e7, 0x0000, 0x0000, 0x0000, 0x0123,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0137, 0x013c, 0x0000, 0x0146, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0157, 0x015f, 0x0163, 0x0000, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xcc */
+  {
+    0x0000,
+  },
+  /* 0xcd */
+  {
+    /* 0x20 */ 0x02dd, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0150,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0170, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0151,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0171, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xce */
+  {
+    /* 0x20 */ 0x02db, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0104, 0x0000, 0x0000, 0x0000, 0x0118, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x012e, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0172, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0105, 0x0000, 0x0000, 0x0000, 0x0119, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x012f, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0173, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  },
+  /* 0xcf */
+  {
+    /* 0x20 */ 0x02c7, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x28 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x30 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x38 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x40 */ 0x0000, 0x0000, 0x0000, 0x010c, 0x010e, 0x011a, 0x0000, 0x0000,
+    /* 0x48 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x013d, 0x0000, 0x0147, 0x0000,
+    /* 0x50 */ 0x0000, 0x0000, 0x0158, 0x0160, 0x0164, 0x0000, 0x0000, 0x0000,
+    /* 0x58 */ 0x0000, 0x0000, 0x017d, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
+    /* 0x60 */ 0x0000, 0x0000, 0x0000, 0x010d, 0x010f, 0x011b, 0x0000, 0x0000,
+    /* 0x68 */ 0x0000, 0x0000, 0x0000, 0x0000, 0x013e, 0x0000, 0x0148, 0x0000,
+    /* 0x70 */ 0x0000, 0x0000, 0x0159, 0x0161, 0x0165, 0x0000, 0x0000, 0x0000,
+    /* 0x78 */ 0x0000, 0x0000, 0x017e, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
+  }
+};
+
+
+static const char from_ucs4[][2] =
+{
+  /* 0x0000 */ "\x00\x00", "\x01\x00", "\x02\x00", "\x03\x00", "\x04\x00",
+  /* 0x0005 */ "\x05\x00", "\x06\x00", "\x07\x00", "\x08\x00", "\x09\x00",
+  /* 0x000a */ "\x0a\x00", "\x0b\x00", "\x0c\x00", "\x0d\x00", "\x0e\x00",
+  /* 0x000f */ "\x0f\x00", "\x10\x00", "\x11\x00", "\x12\x00", "\x13\x00",
+  /* 0x0014 */ "\x14\x00", "\x15\x00", "\x16\x00", "\x17\x00", "\x18\x00",
+  /* 0x0019 */ "\x19\x00", "\x1a\x00", "\x1b\x00", "\x1c\x00", "\x1d\x00",
+  /* 0x001e */ "\x1e\x00", "\x1f\x00", "\x20\x00", "\x21\x00", "\x22\x00",
+  /* 0x0023 */ "\x23\x00", "\x24\x00", "\x25\x00", "\x26\x00", "\x27\x00",
+  /* 0x0028 */ "\x28\x00", "\x29\x00", "\x2a\x00", "\x2b\x00", "\x2c\x00",
+  /* 0x002d */ "\x2d\x00", "\x2e\x00", "\x2f\x00", "\x30\x00", "\x31\x00",
+  /* 0x0032 */ "\x32\x00", "\x33\x00", "\x34\x00", "\x35\x00", "\x36\x00",
+  /* 0x0037 */ "\x37\x00", "\x38\x00", "\x39\x00", "\x3a\x00", "\x3b\x00",
+  /* 0x003c */ "\x3c\x00", "\x3d\x00", "\x3e\x00", "\x3f\x00", "\x40\x00",
+  /* 0x0041 */ "\x41\x00", "\x42\x00", "\x43\x00", "\x44\x00", "\x45\x00",
+  /* 0x0046 */ "\x46\x00", "\x47\x00", "\x48\x00", "\x49\x00", "\x4a\x00",
+  /* 0x004b */ "\x4b\x00", "\x4c\x00", "\x4d\x00", "\x4e\x00", "\x4f\x00",
+  /* 0x0050 */ "\x50\x00", "\x51\x00", "\x52\x00", "\x53\x00", "\x54\x00",
+  /* 0x0055 */ "\x55\x00", "\x56\x00", "\x57\x00", "\x58\x00", "\x59\x00",
+  /* 0x005a */ "\x5a\x00", "\x5b\x00", "\x00\x00", "\x5d\x00", "\x00\x00",
+  /* 0x005f */ "\x5f\x00", "\x00\x00", "\x61\x00", "\x62\x00", "\x63\x00",
+  /* 0x0064 */ "\x64\x00", "\x65\x00", "\x66\x00", "\x67\x00", "\x68\x00",
+  /* 0x0069 */ "\x69\x00", "\x6a\x00", "\x6b\x00", "\x6c\x00", "\x6d\x00",
+  /* 0x006e */ "\x6e\x00", "\x6f\x00", "\x70\x00", "\x71\x00", "\x72\x00",
+  /* 0x0073 */ "\x73\x00", "\x74\x00", "\x75\x00", "\x76\x00", "\x77\x00",
+  /* 0x0078 */ "\x78\x00", "\x79\x00", "\x7a\x00", "\x00\x00", "\x7c\x00",
+  /* 0x007d */ "\x00\x00", "\x00\x00", "\x7f\x00", "\x00\x80", "\x00\x81",
+  /* 0x0082 */ "\x82\x00", "\x83\x00", "\x84\x00", "\x85\x00", "\x86\x00",
+  /* 0x0087 */ "\x87\x00", "\x88\x00", "\x89\x00", "\x8a\x00", "\x8b\x00",
+  /* 0x008c */ "\x8c\x00", "\x8d\x00", "\x8e\x00", "\x8f\x00", "\x90\x00",
+  /* 0x0091 */ "\x91\x00", "\x92\x00", "\x93\x00", "\x94\x00", "\x95\x00",
+  /* 0x0096 */ "\x96\x00", "\x97\x00", "\x98\x00", "\x99\x00", "\x9a\x00",
+  /* 0x009b */ "\x9b\x00", "\x9c\x00", "\x9d\x00", "\x9e\x00", "\x9f\x00",
+  /* 0x00a0 */ "\x00\x00", "\xa1\x00", "\xa2\x00", "\xa3\x00", "\xa4\x00",
+  /* 0x00a5 */ "\xa5\x00", "\x00\x00", "\xa7\x00", "\xc8\x20", "\x00\x00",
+  /* 0x00aa */ "\xe3\x00", "\xab\x00", "\x00\x00", "\x00\x00", "\x00\x00",
+  /* 0x00af */ "\xc5\x20", "\xb0\x00", "\xb1\x00", "\xb2\x00", "\xb3\x00",
+  /* 0x00b4 */ "\xc2\x20", "\xb5\x00", "\xb6\x00", "\xb7\x00", "\xcb\x20",
+  /* 0x00b9 */ "\x00\x00", "\xeb\x00", "\x00\x00", "\xbc\x00", "\xbd\x00",
+  /* 0x00be */ "\xbe\x00", "\xbf\x00", "\xc1\x41", "\xc2\x41", "\xc3\x41",
+  /* 0x00c3 */ "\xc4\x41", "\xc8\x41", "\xca\x41", "\xe1\x00", "\xcb\x43",
+  /* 0x00c8 */ "\xc1\x45", "\xc2\x45", "\xc3\x45", "\xc8\x45", "\xc1\x49",
+  /* 0x00cd */ "\xc2\x49", "\xc3\x49", "\xc8\x49", "\xe2\x00", "\xc4\x4e",
+  /* 0x00d2 */ "\xc1\x4f", "\xc2\x4f", "\xc3\x4f", "\xc4\x4f", "\xc8\x4f",
+  /* 0x00d7 */ "\xb4\x00", "\xe9\x00", "\xc1\x55", "\xc2\x55", "\xc3\x55",
+  /* 0x00dc */ "\xc8\x55", "\xc2\x59", "\xec\x00", "\xfb\x00", "\xc1\x61",
+  /* 0x00e1 */ "\xc2\x61", "\xc3\x61", "\xc4\x61", "\xc8\x61", "\xca\x61",
+  /* 0x00e6 */ "\xf1\x00", "\xcb\x63", "\xc1\x65", "\xc2\x65", "\xc3\x65",
+  /* 0x00eb */ "\xc8\x65", "\xc1\x69", "\xc2\xe9", "\xc3\x69", "\xc8\x69",
+  /* 0x00f0 */ "\xf3\x00", "\xc4\x6e", "\xc1\x6f", "\xc2\x6f", "\xc3\x6f",
+  /* 0x00f5 */ "\xc4\x6f", "\xc8\x6f", "\xb8\x00", "\xf9\x00", "\xc1\x75",
+  /* 0x00fa */ "\xc2\x75", "\xc3\x75", "\xc8\x75", "\xc2\x79", "\xfc\x00",
+  /* 0x00ff */ "\xc8\x79", "\xc5\x41", "\xc5\x61", "\xc6\x41", "\xc6\x61",
+  /* 0x0104 */ "\xce\x41", "\xce\x61", "\xc2\x43", "\xc2\x63", "\xc3\x43",
+  /* 0x0109 */ "\xc3\x63", "\xc7\x43", "\xc7\x63", "\xcf\x43", "\xcf\x63",
+  /* 0x010e */ "\xcf\x44", "\xcf\x64", "\x00\x00", "\xf2\x00", "\xc5\x45",
+  /* 0x0113 */ "\xc5\x65", "\x00\x00", "\x00\x00", "\xc7\x45", "\xc7\x65",
+  /* 0x0118 */ "\xce\x45", "\xce\x65", "\xcf\x45", "\xcf\x65", "\xc3\x47",
+  /* 0x011d */ "\xc3\x67", "\xc6\x47", "\xc6\x67", "\xc7\x47", "\xc7\x67",
+  /* 0x0122 */ "\xcb\x47", "\xcb\x67", "\xc3\x48", "\xc3\x68", "\xe4\x00",
+  /* 0x0127 */ "\xf4\x00", "\xc4\x49", "\xc4\x69", "\xc5\x49", "\xc5\x69",
+  /* 0x012c */ "\x00\x00", "\x00\x00", "\xce\x49", "\xce\x69", "\xc7\x49",
+  /* 0x0131 */ "\xf5\x00", "\xe6\x00", "\xf6\x00", "\xc3\x4a", "\xc3\x6a",
+  /* 0x0136 */ "\xcb\x4b", "\xcb\x6b", "\xf0\x00", "\xc2\x4c", "\xc2\x6c",
+  /* 0x013b */ "\xcb\x4c", "\xcb\x6c", "\xcf\x4c", "\xcf\x6c", "\xe7\x00",
+  /* 0x0140 */ "\xf7\x00", "\xe8\x00", "\xf8\x00", "\xc2\x4e", "\xc2\x6e",
+  /* 0x0145 */ "\xcb\x4e", "\xcb\x6e", "\xcf\x4e", "\xcf\x6e", "\xef\x00",
+  /* 0x014a */ "\xee\x00", "\xfe\x00", "\xc5\x4f", "\xc5\x6f", "\x00\x00",
+  /* 0x014f */ "\x00\x00", "\xcd\x4f", "\xcd\x6f", "\xea\x00", "\xfa\x00",
+  /* 0x0154 */ "\xc2\x52", "\xc2\x72", "\xcb\x52", "\xcb\x72", "\xcf\x52",
+  /* 0x0159 */ "\xcf\x72", "\xc2\x53", "\xc2\x73", "\xc3\x53", "\xc3\x73",
+  /* 0x015e */ "\xcb\x53", "\xcb\x73", "\xcf\x53", "\xcf\x73", "\xcb\x54",
+  /* 0x0163 */ "\xcb\x74", "\xcf\x54", "\xcf\x74", "\xed\x00", "\xfd\x00",
+  /* 0x0168 */ "\xc4\x55", "\xc4\x75", "\xc5\x55", "\xc5\x75", "\xc6\x55",
+  /* 0x016d */ "\xc6\x75", "\xca\x55", "\xca\x75", "\xcd\x55", "\xcd\x75",
+  /* 0x0172 */ "\xce\x55", "\xce\x75", "\xc3\x57", "\xc3\x77", "\xc3\x59",
+  /* 0x0177 */ "\xc3\x79", "\xc8\x59", "\xc2\x5a", "\xc2\x7a", "\xc7\x5a",
+  /* 0x017c */ "\xc7\x7a", "\xcf\x5a", "\xcf\x7a"
+/*
+   This table does not cover the following positions:
+
+     0x02c7    "\xcf\x20",
+     ...
+     0x02d8    "\xc6\x20", "\xc7\x20", "\xca\x20", "\xce\x20", "\x00\x00",
+     0x02dd    "\xcd\x20",
+     ...
+     0x2126    "\xe0\x00"
+
+   These would blow up the table and are therefore handled specially in
+   the code.
+*/
+};
+
+/* Direction of the transformation.  */
+enum direction
+{
+  illegal,
+  to_t61,
+  from_t61
+};
+
+struct t61_data
+{
+  enum direction dir;
+};
+
+
+int
+gconv_init (struct gconv_step *step, struct gconv_step_data *data)
+{
+  /* Determine which direction.  */
+  struct t61_data *new_data;
+  enum direction dir;
+  int result;
+
+  if (__strcasestr (step->from_name, "T.61") != NULL)
+    dir = from_t61;
+  else if (__strcasestr (step->to_name, "T.61") != NULL)
+    dir = to_t61;
+  else
+    dir = illegal;
+
+  result = GCONV_NOCONV;
+  if (dir != illegal
+      && ((new_data
+	   = (struct t61_data *) malloc (sizeof (struct t61_data)))
+	  != NULL))
+    {
+      new_data->dir = dir;
+      data->data = new_data;
+      result = GCONV_OK;
+    }
+
+  return result;
+}
+
+
+void
+gconv_end (struct gconv_step_data *data)
+{
+  free (data->data);
+}
+
+
+int
+gconv (struct gconv_step *step, struct gconv_step_data *data,
+       const char *inbuf, size_t *inbufsize, size_t *written, int do_flush)
+{
+  struct gconv_step *next_step = step + 1;
+  struct gconv_step_data *next_data = data + 1;
+  gconv_fct fct = next_step->fct;
+  size_t do_write;
+  int result;
+
+  /* If the function is called with no input this means we have to reset
+     to the initial state.  The possibly partly converted input is
+     dropped.  */
+  if (do_flush)
+    {
+      do_write = 0;
+
+      /* Call the steps down the chain if there are any.  */
+      if (data->is_last)
+	result = GCONV_OK;
+      else
+	{
+	  struct gconv_step *next_step = step + 1;
+	  struct gconv_step_data *next_data = data + 1;
+
+	  result = (*fct) (next_step, next_data, NULL, 0, written, 1);
+
+	  /* Clear output buffer.  */
+	  data->outbufavail = 0;
+	}
+    }
+  else
+    {
+      enum direction dir = ((struct t61_data *) data->data)->dir;
+
+      do_write = 0;
+
+      do
+	{
+	  result = GCONV_OK;
+
+	  if (dir == from_t61)
+	    {
+	      size_t inchars = *inbufsize;
+	      size_t outwchars = data->outbufavail;
+	      char *outbuf = data->outbuf;
+	      size_t cnt = 0;
+
+	      while (cnt < inchars
+		     && (outwchars + sizeof (wchar_t) <= data->outbufsize))
+		{
+		  int inchar = inbuf[cnt];
+		  wchar_t ch;
+
+		  if (inchar >= '\xc1' && inchar <= '\xcf')
+		    {
+		      /* Composed character.  First test whether the next
+			 character is also available.  */
+		      int inchar2;
+
+		      if (cnt + 1 >= inchars)
+			{
+			  /* The second character is not available.  Store
+			     the intermediate result.  */
+			  result = GCONV_INCOMPLETE_INPUT;
+			  break;
+			}
+
+		      inchar2 = inbuf[++cnt];
+
+		      if (inchar2 < '\x20' || inchar2 >= '\x80')
+			/* This is illegal.  */
+			ch = L'\0';
+		      else
+			ch = to_ucs4_comb[inchar - 0xc1][inchar2 - 0x20];
+		    }
+		  else
+		    ch = to_ucs4[inchar];
+
+		  if (ch == L'\0' && inbuf[cnt] != '\0')
+		    {
+		      /* This is an illegal character.  */
+		      result = GCONV_ILLEGAL_INPUT;
+		      break;
+		    }
+
+		  *((wchar_t *) (outbuf + outwchars)) = ch;
+		  ++do_write;
+		  outwchars += sizeof (wchar_t);
+		  ++cnt;
+		}
+	      *inbufsize -= cnt;
+	      data->outbufavail = outwchars;
+	    }
+	  else
+	    {
+	      size_t inwchars = *inbufsize;
+	      size_t outchars = data->outbufavail;
+	      char *outbuf = data->outbuf;
+	      size_t cnt = 0;
+	      int extra = 0;
+
+	      while (inwchars >= cnt + sizeof (wchar_t)
+		     && outchars < data->outbufsize)
+		{
+		  char tmp[2];
+		  int ch = *((wchar_t *) (inbuf + cnt));
+		  const char *cp;
+
+		  if (ch >= sizeof (from_ucs4) / sizeof (from_ucs4[0]))
+		    {
+		      if (ch == 0x2126)
+			cp = "\xe0";
+		      else if (ch == 0x2c7)
+			cp = "\xcf\x20";
+		      else if (ch < 0x2d8 || ch > 0x2dd)
+			/* Illegal characters.  */
+			break;
+		      else
+			{
+			  static const char map[5] = "\xc6\xc7\xca\xce\xcd";
+
+			  tmp[0] = map[ch - 0x2d8];
+			  tmp[1] = ' ';
+			  cp = tmp;
+			}
+		    }
+		  else if (ch < 0 || (from_ucs4[ch][0] == '\0' && ch != 0))
+		    break;
+		  else
+		    cp = from_ucs4[ch];
+
+		  outbuf[outchars] = cp[0];
+		  /* Now test for a possible second byte and write this
+		     if possible.  */
+		  if (cp[1] != '\0')
+		    {
+		      if (outchars + 1 >= data->outbufsize)
+			{
+			  /* The result does not fit into the buffer.  */
+			  extra = 1;
+			  break;
+			}
+		      outbuf[++outchars] = cp[1];
+		    }
+
+		  ++do_write;
+		  ++outchars;
+		  cnt += sizeof (wchar_t);
+		}
+	      *inbufsize -= cnt;
+	      data->outbufavail = outchars;
+
+	      if (outchars + extra < data->outbufsize)
+		{
+		  /* If there is still room in the output buffer something
+		     is wrong with the input.  */
+		  if (inwchars >= cnt + sizeof (wchar_t))
+		    {
+		      /* An error occurred.  */
+		      result = GCONV_ILLEGAL_INPUT;
+		      break;
+		    }
+		  if (inwchars != cnt)
+		    {
+		      /* There are some unprocessed bytes at the end of the
+			 input buffer.  */
+		      result = GCONV_INCOMPLETE_INPUT;
+		      break;
+		    }
+		}
+	    }
+
+	  if (result != GCONV_OK)
+	    break;
+
+	  if (data->is_last)
+	    {
+	      /* This is the last step.  */
+	      result = (*inbufsize > (dir == from_t61
+				      ? 0 : sizeof (wchar_t) - 1)
+			? GCONV_FULL_OUTPUT : GCONV_EMPTY_INPUT);
+	      break;
+	    }
+
+	  /* Status so far.  */
+	  result = GCONV_EMPTY_INPUT;
+
+	  if (data->outbufavail > 0)
+	    {
+	      /* Call the functions below in the chain.  */
+	      size_t newavail = data->outbufavail;
+
+	      result = (*fct) (next_step, next_data, data->outbuf, &newavail,
+			       written, 0);
+
+	      /* Correct the output buffer.  */
+	      if (newavail != data->outbufavail && newavail > 0)
+		{
+		  memmove (data->outbuf,
+			   &data->outbuf[data->outbufavail - newavail],
+			   newavail);
+		  data->outbufavail = newavail;
+		}
+	    }
+	}
+      while (*inbufsize > 0 && result == GCONV_EMPTY_INPUT);
+    }
+
+  if (written != NULL && data->is_last)
+    *written = do_write;
+
+  return result;
+}