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.
This commit is contained in:
Ulrich Drepper 1997-11-26 04:23:08 +00:00
parent e34b0f2902
commit f4017d2057
248 changed files with 8918 additions and 1425 deletions

253
ChangeLog
View File

@ -1,3 +1,256 @@
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.
1997-11-24 03:01 Ulrich Drepper <drepper@cygnus.com>
* elf/dl-support.c: Call __libc_init_secure to make sure

78
FAQ
View File

@ -109,6 +109,10 @@ please let me know.
I get
XXX: Symbol `_sys_errlist' has different size in shared object, consider re-linking
Why? What to do?''
[Q31] ``What's the problem with configure --enable-omitfp?''
[Q32] ``Why don't signals interrupt system calls anymore?''
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
[Q1] ``What systems does the GNU C Library run on?''
@ -351,9 +355,8 @@ incompatibilities:
* the `signal' function's behaviour corresponds to the BSD semantic and
not the SysV semantic as it was in libc-5. The interface on all GNU
systems shall be the same and BSD is the semantic of choice. To use
the SysV behaviour simply use `sysv_signal'. The major difference is
that the SysV implementation sets the SA_ONESHOT flag and so the handler
gets removed after the first call.
the SysV behaviour simply use `sysv_signal', or define _XOPEN_SOURCE.
See question 32 for details.
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
@ -533,13 +536,15 @@ In this file you have to change a few things:
- remove all expression `%{...:-lgmon}'; there is no libgmon in glibc
- fix a minor bug by changing %{pipe:-} to %|
Things are getting a bit more complicated if you have GNU libc
installed in some other place than /usr, i.e., if you do not want to
use it instead of the old libc. In this case the needed startup files
and libraries are not found in the regular places. So the specs file
must tell the compiler and linker exactly what to use. Here is for
example the gcc-2.7.2 specs file when GNU libc is installed at
must tell the compiler and linker exactly what to use. Here is what
the gcc-2.7.2 specs file should look like when GNU libc is installed at
/usr:
-----------------------------------------------------------------------
@ -547,7 +552,7 @@ example the gcc-2.7.2 specs file when GNU libc is installed at
%{V} %{v:%{!V:-V}} %{Qy:} %{!Qn:-Qy} %{n} %{T} %{Ym,*} %{Yd,*} %{Wa,*:%*}
*asm_final:
%{pipe:-}
%|
*cpp:
%{fPIC:-D__PIC__ -D__pic__} %{fpic:-D__PIC__ -D__pic__} %{!m386:-D__i486__} %{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}
@ -804,6 +809,66 @@ be possible that such a symbol size change slipped in though it must not
happen. So in case of doubt report such a warning message as a problem.
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
[Q31] ``What's the problem with configure --enable-omitfp?''
{AJ} When configuring with --enable-omitfp the libraries are build
without frame pointers. Some compilers produce in this situation buggy
code and therefore we don't advise using it at the moment.
If you use --enable-omitfp, you're on your own. If you encounter
problems with a library that was build this way, I'll advise you to
rebuild the library without --enable-omitfp. If the problem vanishes
consider tracking the problem down and report it as compiler failure.
Since a library build with --enable-omitfp is undebuggable, a
debuggable library is also build - you can recognize it by the suffix
"_g" to the library names.
The compilation of this extra libraries and the compiler optimizations
slow down the build process and need more disk space.
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
[Q32] ``Why don't signals interrupt system calls anymore?''
[A32] {ZW} By default GNU libc uses the BSD semantics for signal(),
unlike Linux libc 5 which used System V semantics. This is partially
for compatibility with other systems and partially because the BSD
semantics tend to make programming with signals easier.
There are three differences:
* BSD-style signals that occur in the middle of a system call do not
affect the system call; System V signals cause the system call to
fail and set errno to EINTR.
* BSD signal handlers remain installed once triggered. System V signal
handlers work only once, so one must reinstall them each time.
* A BSD signal is blocked during the execution of its handler. In other
words, a handler for SIGCHLD (for example) does not need to worry about
being interrupted by another SIGCHLD. It may, however, be interrrupted
by other signals.
There is general consensus that for `casual' programming with signals, the
BSD semantics are preferable. You don't need to worry about system calls
returning EINTR, and you don't need to worry about the race conditions
associated with one-shot signal handlers.
If you are porting an old program that relies on the old semantics, you can
quickly fix the problem by changing signal() to sysv_signal() throughout.
Alternatively, define _XOPEN_SOURCE before including <signal.h>.
For new programs, the sigaction() function allows you to specify precisely
how you want your signals to behave. All three differences listed above are
individually switchable on a per-signal basis with this function.
If all you want is for one specific signal to cause system calls to fail
and return EINTR (for example, to implement a timeout) you can do this with
siginterrupt().
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
Answers were given by:
@ -815,6 +880,7 @@ Answers were given by:
{EY} Eric Youngdale, <eric@andante.jic.com>
{PB} Phil Blundell, <Philip.Blundell@pobox.com>
{MK} Mark Kettenis, <kettenis@phys.uva.nl>
{ZW} Zack Weinberg, <zack@rabi.phys.columbia.edu>
Local Variables:
mode:text

View File

@ -334,6 +334,9 @@ FORCE:
rpm/%: subdir_distinfo
$(MAKE) $(PARALLELMFLAGS) -C $(@D) subdirs='$(subdirs)' $(@F)
iconvdata/%:
$(MAKE) $(PARALLELMFLAGS) -C $(@D) $(@F)
# This is a special goal for people making binary distributions. Normally
# everybody uses the DES based crypt library but for the distribution we
# need the only-MD5 based one as well.

View File

@ -80,7 +80,7 @@ in the GNU C library, explaining how you can tell the library what
facilities you want it to make available.
We prefer to get bug reports sent using the `glibcbug' shell script which
is install together with the rest of the GNU libc to <bugs@gnu.org>.
is installed together with the rest of the GNU libc to <bugs@gnu.org>.
Simply run this shell script and fill in the information. Nevertheless
you can still send bug reports to <bug-glibc@prep.ai.mit.edu> as normal
electronic mails.

View File

@ -17,8 +17,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _BITS_BYTESWAP_H
#define _BITS_BYTESWAP_H 1
#if !defined _BYTESWAP_H && !defined _NETINET_IN_H
# error "Never use <bits/byteswap.h> directly; include <byteswap.h> instead."
#endif
/* Swap bytes in 16 bit value. */
#define __bswap_16(x) \
@ -39,5 +40,3 @@
__r.__l[1] = __bswap_32 (__v.__l[0]); \
__r.__ll; })
#endif
#endif /* bits/byteswap.h */

View File

@ -17,6 +17,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _UNISTD_H
# error "Never use <bits/confname.h> directly; include <unistd.h> instead."
#endif
/* Values for the NAME argument to `pathconf' and `fpathconf'. */
enum
{

View File

@ -1,5 +1,5 @@
/* Directory entry structure `struct dirent'. Stub version.
Copyright (C) 1996 Free Software Foundation, Inc.
Copyright (C) 1996, 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
@ -17,6 +17,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _DIRENT_H
# error "Never use <bits/dirent.h> directly; include <dirent.h> instead."
#endif
struct dirent
{
char d_name[1]; /* Variable length. */

View File

@ -17,8 +17,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _BITS_DLFCN_H
#define _BITS_DLFCN_H 1
#ifndef _DLFCN_H
# error "Never use <bits/dlfcn.h> directly; include <dlfcn.h> instead."
#endif
/* The MODE argument to `dlopen' contains one of the following: */
#define RTLD_LAZY 0x001 /* Lazy function call binding. */
@ -29,5 +30,3 @@
the symbols of the loaded object and its dependencies are made
visible as if the object were linked directly into the program. */
#define RTLD_GLOBAL 0x100
#endif /* bits/dlfcn.h */

View File

@ -6,4 +6,8 @@
So if cross-compiling to a machine with a different byte order,
the bits/endian.h file for that machine must exist. */
#ifndef _ENDIAN_H
# error "Never use <bits/endian.h> directly; include <endian.h> instead."
#endif
#error Machine byte order unknown.

View File

@ -17,7 +17,7 @@
Boston, MA 02111-1307, USA. */
#ifndef _FENV_H
#error "Never use <bits/fenv.h> directly; include <fenv.h> instead."
# error "Never use <bits/fenv.h> directly; include <fenv.h> instead."
#endif

View File

@ -1,6 +1,6 @@
/* Stub `HUGE_VAL' constant.
Used by <stdlib.h> and <math.h> functions for overflow.
Copyright (C) 1992, 1996 Free Software Foundation, Inc.
Copyright (C) 1992, 1996, 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
@ -19,7 +19,7 @@
Boston, MA 02111-1307, USA. */
#ifndef _MATH_H
#error "Never use <bits/huge_val.h> directly; include <math.h> instead."
# error "Never use <bits/huge_val.h> directly; include <math.h> instead."
#endif

View File

@ -18,8 +18,9 @@
/* Generic version. */
#ifndef _NETINET_INBITS_H
#define _NETINET_INBITS_H 1
#ifndef _NETINET_IN_H
# error "Never use <bits/in.h> directly; include <netinet/in.h> instead."
#endif
/* Link numbers. */
#define IMPLINK_IP 155
@ -55,10 +56,10 @@ struct ip_opts
/* Structure used for IP_ADD_MEMBERSHIP and IP_DROP_MEMBERSHIP. */
struct ip_mreq
{
{
struct in_addr imr_multiaddr; /* IP multicast address of group */
struct in_addr imr_interface; /* local IP address of interface */
};
};
/* IPV6 socket options. */
#define IPV6_ADDRFORM 1
@ -80,5 +81,3 @@ struct ip_mreq
#define IPV6_MULTICAST_LOOP 19
#define IPV6_ADD_MEMBERSHIP 20
#define IPV6_DROP_MEMBERSHIP 21
#endif /* netinet/inbits.h */

View File

@ -1,5 +1,5 @@
/* Structure types for pre-termios terminal ioctls. Generic Unix version.
Copyright (C) 1996 Free Software Foundation, Inc.
Copyright (C) 1996, 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
@ -17,15 +17,11 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/*
* Never include this file directly; use <sys/ioctl.h> instead.
*/
#ifndef _SYS_IOCTL_H
# error "Never use <bits/ioctl-types.h> directly; include <sys/ioctl.h> instead."
#endif
#ifndef _BITS_IOCTL_TYPES_H
#define _BITS_IOCTL_TYPES_H 1
#if defined(TIOCGETC) || defined(TIOCSETC)
#if defined TIOCGETC || defined TIOCSETC
/* Type of ARG for TIOCGETC and TIOCSETC requests. */
struct tchars
{
@ -41,7 +37,7 @@ struct tchars
_IOT (_IOTS (char), 6, 0, 0, 0, 0)
#endif
#if defined(TIOCGLTC) || defined(TIOCSLTC)
#if defined TIOCGLTC || defined TIOCSLTC
/* Type of ARG for TIOCGLTC and TIOCSLTC requests. */
struct ltchars
{
@ -70,7 +66,7 @@ struct sgttyb
#define _IOT_sgttyb /* Hurd ioctl type field. */ \
_IOT (_IOTS (char), 6, _IOTS (short int), 1, 0, 0)
#if defined(TIOCGWINSZ) || defined(TIOCSWINSZ)
#if defined TIOCGWINSZ || defined TIOCSWINSZ
/* Type of ARG for TIOCGWINSZ and TIOCSWINSZ requests. */
struct winsize
{
@ -86,13 +82,13 @@ struct winsize
_IOT (_IOTS (unsigned short int), 4, 0, 0, 0, 0)
#endif
#if defined (TIOCGSIZE) || defined (TIOCSSIZE)
#if defined TIOCGSIZE || defined TIOCSSIZE
/* The BSD-style ioctl constructor macros use `sizeof', which can't be used
in a preprocessor conditional. Since the commands are always unique
regardless of the size bits, we can safely define away `sizeof' for the
purpose of the conditional. */
# define sizeof(type) 0
# if defined (TIOCGWINSZ) && TIOCGSIZE == TIOCGWINSZ
# if defined TIOCGWINSZ && TIOCGSIZE == TIOCGWINSZ
/* Many systems that have TIOCGWINSZ define TIOCGSIZE for source
compatibility with Sun; they define `struct ttysize' to have identical
layout as `struct winsize' and #define TIOCGSIZE to be TIOCGWINSZ
@ -116,6 +112,3 @@ struct ttysize
# endif
# undef sizeof /* See above. */
#endif
#endif /* bits/ioctl-types.h */

View File

@ -1 +1,5 @@
#ifndef _SYS_IOCTL_H
# error "Never use <bits/ioctls.h> directly; include <sys/ioctl.h> instead."
#endif
/* This space intentionally left blank. */

View File

@ -1,4 +1,4 @@
/* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
/* Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
@ -17,10 +17,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SYS_IPC_BUF_H
#define _SYS_IPC_BUF_H 1
#include <features.h>
#ifndef _SYS_IPC_H
# error "Never use <bits/ipc.h> directly; include <sys/ipc.h> instead."
#endif
#include <sys/types.h>
@ -34,23 +33,16 @@
#define IPC_SET 1 /* set `ipc_perm' options */
#define IPC_STAT 2 /* get `ipc_perm' options */
__BEGIN_DECLS
/* Special key values. */
#define IPC_PRIVATE ((key_t) 0) /* private key */
/* Data structure used to pass permission information to IPC operations. */
struct ipc_perm
{
{
__uid_t uid; /* owner's user ID */
__gid_t gid; /* owner's group ID */
__uid_t cuid; /* creator's user ID */
__gid_t cgid; /* creator's group ID */
__mode_t mode; /* read/write permission */
};
__END_DECLS
#endif /* _SYS_IPC_BUF_H */
};

View File

@ -1,6 +1,5 @@
/* Copyright (C) 1995, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
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
@ -21,14 +20,11 @@
#error "Never use <bits/msq.h> directly; include <sys/msg.h> instead."
#endif
#include <features.h>
#include <sys/types.h>
/* Define options for message queue functions. */
#define MSG_NOERROR 010000 /* no error if message is too big */
__BEGIN_DECLS
/* Structure of record for one message inside the kernel.
The type `struct __msg' is opaque. */
@ -43,5 +39,3 @@ struct msqid_ds
__pid_t msg_lspid; /* pid of last msgsnd() */
__pid_t msg_lrpid; /* pid of last msgrcv() */
};
__END_DECLS

View File

@ -16,6 +16,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SYS_POLL_H
# error "Never use <bits/poll.h> directly; include <sys/poll.h> instead."
#endif
/* Event types that can be polled for. These bits may be set in `events'
to indicate the interesting event types; they will appear in `revents'

View File

@ -17,6 +17,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SYS_RESOURCE_H
# error "Never use <bits/resource.h> directly; include <sys/resource.h> instead."
#endif
/* These are the values for 4.4 BSD and GNU. Earlier BSD systems have a
subset of these kinds of resource limit. In systems where `getrlimit'
and `setrlimit' are not system calls, these are the values used by the C
@ -107,7 +111,8 @@ enum __rusage_who
#define RUSAGE_CHILDREN RUSAGE_CHILDREN
};
#include <sys/time.h> /* For `struct timeval'. */
#define __need_timeval
#include <bits/time.h> /* For `struct timeval'. */
/* Structure which says how much of each resource has been used. */
struct rusage

View File

@ -1,6 +1,6 @@
/* Definitions of constants and data structure for POSIX 1003.1b-1993
scheduling interface.
Copyright (C) 1996 Free Software Foundation, Inc.
Copyright (C) 1996, 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
@ -19,7 +19,7 @@
Suite 330, Boston, MA 02111-1307, USA. */
#ifndef _SCHED_H
#error "Never use <bits/sched.h> directly; include <sched.h> instead."
# error "Never include <bits/sched.h> directly; use <sched.h> instead."
#endif

View File

@ -1,6 +1,5 @@
/* Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
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
@ -18,11 +17,9 @@
Boston, MA 02111-1307, USA. */
#ifndef _SYS_SEM_H
#error "Never use <bits/sem.h> directly; include <sys/sem.h> instead."
# error "Never include <bits/sem.h> directly; use <sys/sem.h> instead."
#endif
#include <features.h>
#include <sys/types.h>
/* Flags for `semop'. */
@ -38,8 +35,6 @@
#define SETALL 17 /* set all semval's */
__BEGIN_DECLS
/* Data structure describing a set of semaphores. */
struct semid_ds
{
@ -57,5 +52,3 @@ union semun
unsigned short int *array; /* array for GETALL & SETALL */
struct seminfo *__buf; /* buffer for IPC_INFO */
};
__END_DECLS

View File

@ -1,3 +1,7 @@
/* Define the machine-dependent type `jmp_buf'. Stub version. */
#ifndef _SETJMP_H
# error "Never include <bits/setjmp.h> directly; use <setjmp.h> instead."
#endif
typedef int __jmp_buf[1];

View File

@ -1,6 +1,5 @@
/* Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
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
@ -18,11 +17,9 @@
Boston, MA 02111-1307, USA. */
#ifndef _SYS_SHM_H
#error "Never use <bits/shm.h> directly; include <sys/shm.h> instead."
# error "Never include <bits/shm.h> directly; use <sys/shm.h> instead."
#endif
#include <features.h>
#include <sys/types.h>
/* Flags for `shmat'. */
@ -35,11 +32,9 @@
#define SHM_UNLOCK 12 /* unlock segment (root only) */
__BEGIN_DECLS
/* Data structure describing a set of semaphores. */
struct shmid_ds
{
{
struct ipc_perm sem_perm; /* operation permission struct */
int shm_segsz; /* size of segment in bytes */
__time_t sem_atime; /* time of last shmat() */
@ -48,6 +43,4 @@ struct shmid_ds
__pid_t shm_cpid; /* pid of creator */
__pid_t shm_lpid; /* pid of last shmop */
unsigned short int shm_nattch; /* number of current attaches */
};
__END_DECLS
};

View File

@ -16,6 +16,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SIGNAL_H
# error "Never include <bits/sigaction.h> directly; use <signal.h> instead."
#endif
/* These definitions match those used by the 4.4 BSD kernel.
If the operating system has a `sigaction' system call that correctly
implements the POSIX.1 behavior, there should be a system-dependent

View File

@ -17,6 +17,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SIGNAL_H
# error "Never use <bits/sigcontext.h> directly; include <signal.h> instead."
#endif
/* State of this thread when the signal was taken. */
struct sigcontext
{

View File

@ -18,17 +18,12 @@
Boston, MA 02111-1307, USA. */
#ifndef _SYS_SOCKET_H
#error "Never include <bits/socket.h> directly; use <sys/socket.h> instead."
# error "Never include <bits/socket.h> directly; use <sys/socket.h> instead."
#endif
#include <features.h>
#define __need_size_t
#include <stddef.h>
__BEGIN_DECLS
/* Type for length arguments in socket calls. */
typedef unsigned int socklen_t;
@ -201,5 +196,3 @@ struct linger
int l_onoff; /* Nonzero to linger on close. */
int l_linger; /* Time to linger. */
};
__END_DECLS

View File

@ -16,16 +16,13 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/*
* Never include this file directly; use <sys/stat.h> instead.
*/
#ifndef _SYS_STAT_H
# error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
#endif
/* This structure needs to be defined in accordance with the
implementation of __stat, __fstat, and __lstat. */
#ifndef _BITS_STAT_H
#define _BITS_STAT_H 1
#include <bits/types.h>
/* Structure describing file characteristics. */
@ -87,6 +84,3 @@ struct stat64
__time_t st_ctime; /* Time of last status change. */
};
#endif
#endif /* bits/stat.h */

View File

@ -17,12 +17,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/*
* Never include this file directly; use <sys/statfs.h> instead.
*/
#ifndef _BITS_STATFS_H
#define _BITS_STATFS_H 1
#ifndef _SYS_STATFS_H
# error "Never include <bits/statfs.h> directly; use <sys/statfs.h> instead."
#endif
#include <bits/types.h>
@ -47,6 +44,3 @@ struct statfs
unsigned int f_namelen;
unsigned int f_spare[6];
};
#endif /* bits/statfs.h */

View File

@ -1,5 +1,5 @@
/* termios type and macro definitions. 4.4 BSD/generic GNU version.
Copyright (C) 1993, 1994, 1996 Free Software Foundation, Inc.
Copyright (C) 1993, 1994, 1996, 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
@ -17,31 +17,35 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _TERMIOS_H
# error "Never include <bits/termios.h> directly; use <termios.h> instead."
#endif
/* These macros are also defined in some <bits/ioctls.h> files (with
numerically identical values), but this serves to shut up cpp's
complaining. */
#ifdef __USE_BSD
#ifdef MDMBUF
#undef MDMBUF
#endif
#ifdef FLUSHO
#undef FLUSHO
#endif
#ifdef PENDIN
#undef PENDIN
#endif
# ifdef MDMBUF
# undef MDMBUF
# endif
# ifdef FLUSHO
# undef FLUSHO
# endif
# ifdef PENDIN
# undef PENDIN
# endif
#endif /* __USE_BSD */
#ifdef ECHO
#undef ECHO
# undef ECHO
#endif
#ifdef TOSTOP
#undef TOSTOP
# undef TOSTOP
#endif
#ifdef NOFLSH
#undef NOFLSH
# undef NOFLSH
#endif
@ -85,15 +89,15 @@ struct termios
tcflag_t c_oflag;
#define OPOST (1 << 0) /* Perform output processing. */
#ifdef __USE_BSD
#define ONLCR (1 << 1) /* Map NL to CR-NL on output. */
#define OXTABS (1 << 2) /* Expand tabs to spaces. */
#define ONOEOT (1 << 8) /* Discard EOT (^D) on output. */
# define ONLCR (1 << 1) /* Map NL to CR-NL on output. */
# define OXTABS (1 << 2) /* Expand tabs to spaces. */
# define ONOEOT (1 << 8) /* Discard EOT (^D) on output. */
#endif
/* Control modes. */
tcflag_t c_cflag;
#ifdef __USE_BSD
#define CIGNORE (1 << 0) /* Ignore these control flags. */
# define CIGNORE (1 << 0) /* Ignore these control flags. */
#endif
#define CSIZE (CS5|CS6|CS7|CS8) /* Number of bits per byte (mask). */
#define CS5 0 /* 5 bits per byte. */
@ -107,15 +111,15 @@ struct termios
#define HUPCL (1 << 14) /* Hang up on last close. */
#define CLOCAL (1 << 15) /* Ignore modem status lines. */
#ifdef __USE_BSD
#define CCTS_OFLOW (1 << 16) /* CTS flow control of output. */
#define CRTS_IFLOW (1 << 17) /* RTS flow control of input. */
#define MDMBUF (1 << 20) /* Carrier flow control of output. */
# define CCTS_OFLOW (1 << 16) /* CTS flow control of output. */
# define CRTS_IFLOW (1 << 17) /* RTS flow control of input. */
# define MDMBUF (1 << 20) /* Carrier flow control of output. */
#endif
/* Local modes. */
tcflag_t c_lflag;
#ifdef __USE_BSD
#define ECHOKE (1 << 0) /* Visual erase for KILL. */
# define ECHOKE (1 << 0) /* Visual erase for KILL. */
#endif
#define _ECHOE (1 << 1) /* Visual erase for ERASE. */
#define ECHOE _ECHOE
@ -126,15 +130,15 @@ struct termios
#define _ECHONL (1 << 4) /* Echo NL even if ECHO is off. */
#define ECHONL _ECHONL
#ifdef __USE_BSD
#define ECHOPRT (1 << 5) /* Hardcopy visual erase. */
#define ECHOCTL (1 << 6) /* Echo control characters as ^X. */
# define ECHOPRT (1 << 5) /* Hardcopy visual erase. */
# define ECHOCTL (1 << 6) /* Echo control characters as ^X. */
#endif
#define _ISIG (1 << 7) /* Enable signals. */
#define ISIG _ISIG
#define _ICANON (1 << 8) /* Do erase and kill processing. */
#define ICANON _ICANON
#ifdef __USE_BSD
#define ALTWERASE (1 << 9) /* Alternate WERASE algorithm. */
# define ALTWERASE (1 << 9) /* Alternate WERASE algorithm. */
#endif
#define _IEXTEN (1 << 10) /* Enable DISCARD and LNEXT. */
#define IEXTEN _IEXTEN
@ -142,9 +146,9 @@ struct termios
#define _TOSTOP (1 << 22) /* Send SIGTTOU for background output. */
#define TOSTOP _TOSTOP
#ifdef __USE_BSD
#define FLUSHO (1 << 23) /* Output being flushed (state). */
#define NOKERNINFO (1 << 25) /* Disable VSTATUS. */
#define PENDIN (1 << 29) /* Retype pending input (state). */
# define FLUSHO (1 << 23) /* Output being flushed (state). */
# define NOKERNINFO (1 << 25) /* Disable VSTATUS. */
# define PENDIN (1 << 29) /* Retype pending input (state). */
#endif
#define _NOFLSH (1 << 31) /* Disable flush after interrupt. */
#define NOFLSH _NOFLSH
@ -153,32 +157,32 @@ struct termios
#define VEOF 0 /* End-of-file character [ICANON]. */
#define VEOL 1 /* End-of-line character [ICANON]. */
#ifdef __USE_BSD
#define VEOL2 2 /* Second EOL character [ICANON]. */
# define VEOL2 2 /* Second EOL character [ICANON]. */
#endif
#define VERASE 3 /* Erase character [ICANON]. */
#ifdef __USE_BSD
#define VWERASE 4 /* Word-erase character [ICANON]. */
# define VWERASE 4 /* Word-erase character [ICANON]. */
#endif
#define VKILL 5 /* Kill-line character [ICANON]. */
#ifdef __USE_BSD
#define VREPRINT 6 /* Reprint-line character [ICANON]. */
# define VREPRINT 6 /* Reprint-line character [ICANON]. */
#endif
#define VINTR 8 /* Interrupt character [ISIG]. */
#define VQUIT 9 /* Quit character [ISIG]. */
#define VSUSP 10 /* Suspend character [ISIG]. */
#ifdef __USE_BSD
#define VDSUSP 11 /* Delayed suspend character [ISIG]. */
# define VDSUSP 11 /* Delayed suspend character [ISIG]. */
#endif
#define VSTART 12 /* Start (X-ON) character [IXON, IXOFF]. */
#define VSTOP 13 /* Stop (X-OFF) character [IXON, IXOFF]. */
#ifdef __USE_BSD
#define VLNEXT 14 /* Literal-next character [IEXTEN]. */
#define VDISCARD 15 /* Discard character [IEXTEN]. */
# define VLNEXT 14 /* Literal-next character [IEXTEN]. */
# define VDISCARD 15 /* Discard character [IEXTEN]. */
#endif
#define VMIN 16 /* Minimum number of bytes read at once [!ICANON]. */
#define VTIME 17 /* Time-out value (tenths of a second) [!ICANON]. */
#ifdef __USE_BSD
#define VSTATUS 18 /* Status character [ICANON]. */
# define VSTATUS 18 /* Status character [ICANON]. */
#endif
#define NCCS 20 /* Value duplicated in <hurd/tioctl.defs>. */
cc_t c_cc[NCCS];
@ -202,8 +206,8 @@ struct termios
#define B19200 19200 /* 19200 baud. */
#define B38400 38400 /* 38400 baud. */
#ifdef __USE_BSD
#define EXTA 19200
#define EXTB 38400
# define EXTA 19200
# define EXTB 38400
#endif
};
@ -215,7 +219,7 @@ struct termios
#define TCSADRAIN 1 /* Change when pending output is written. */
#define TCSAFLUSH 2 /* Flush pending input before changing. */
#ifdef __USE_BSD
#define TCSASOFT 0x10 /* Flag: Don't alter hardware state. */
# define TCSASOFT 0x10 /* Flag: Don't alter hardware state. */
#endif
/* Values for the QUEUE_SELECTOR argument to `tcflush'. */

View File

@ -21,6 +21,16 @@
* Never include this file directly; use <time.h> instead.
*/
#ifndef __need_timeval
# ifndef _BITS_TIME_H
# define _BITS_TIME_H 1
# define CLOCKS_PER_SEC 60
# endif /* bits/time.h */
#endif
#ifdef __need_timeval
# undef __need_timeval
# ifndef _STRUCT_TIMEVAL
@ -34,11 +44,3 @@ struct timeval
};
# endif /* struct timeval */
#endif /* need timeval */
#ifndef _BITS_TIME_H
#define _BITS_TIME_H 1
#define CLOCKS_PER_SEC 60
#endif /* bits/time.h */

View File

@ -17,7 +17,7 @@
Boston, MA 02111-1307, USA. */
#ifndef _SYS_UIO_H
#error "Never use <bits/uio.h> directly; include <sys/uio.h> instead."
# error "Never include <bits/uio.h> directly; use <sys/uio.h> instead."
#endif

View File

@ -17,12 +17,9 @@
Boston, MA 02111-1307, USA. */
#ifndef _UTMP_H
# error "Never use <bits/utmp.h> directly; include <utmp.h> instead."
# error "Never include <bits/utmp.h> directly; use <utmp.h> instead."
#endif
#include <features.h>
#include <paths.h>
#include <time.h>
@ -31,7 +28,6 @@
#define UT_LINESIZE 8
#define UT_HOSTSIZE 16
__BEGIN_DECLS
struct lastlog
{
@ -51,5 +47,3 @@ struct utmp
#define _HAVE_UT_HOST 1 /* We have the ut_host field. */
__END_DECLS

View File

@ -1,3 +1,25 @@
/* 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. */
#ifndef _UTSNAME_H
# error "Never include <bits/utsname.h> directly; use <sys/utsname.h> instead."
#endif
/* The size of the character arrays used to hold the information
in a `struct utsname'. Enlarge this as necessary. */
#define _UTSNAME_LENGTH 1024

View File

@ -18,7 +18,7 @@
Boston, MA 02111-1307, USA. */
#ifndef _SYS_WAIT_H
#error "Never use <bits/waitflags.h> directly; include <sys/wait.h> instead."
# error "Never include <bits/waitflags.h> directly; use <sys/wait.h> instead."
#endif

View File

@ -18,7 +18,7 @@
Boston, MA 02111-1307, USA. */
#ifndef _SYS_WAIT_H
#error "Never use <bits/waitstatus.h> directly; include <sys/wait.h> instead."
# error "Never include <bits/waitstatus.h> directly; use <sys/wait.h> instead."
#endif
@ -39,11 +39,11 @@
/* Nonzero if STATUS indicates termination by a signal. */
#ifdef __GNUC__
#define __WIFSIGNALED(status) \
# define __WIFSIGNALED(status) \
(__extension__ ({ int __status = (status); \
!__WIFSTOPPED(__status) && !__WIFEXITED(__status); }))
#else /* Not GCC. */
#define __WIFSIGNALED(status) (!__WIFSTOPPED(status) && !__WIFEXITED(status))
# define __WIFSIGNALED(status) (!__WIFSTOPPED(status) && !__WIFEXITED(status))
#endif /* GCC. */
/* Nonzero if STATUS indicates the child is stopped. */
@ -60,45 +60,45 @@
#ifdef __USE_BSD
#include <endian.h>
# include <endian.h>
union wait
{
int w_status;
struct
{
#if __BYTE_ORDER == __LITTLE_ENDIAN
# if __BYTE_ORDER == __LITTLE_ENDIAN
unsigned int __w_termsig:7; /* Terminating signal. */
unsigned int __w_coredump:1; /* Set if dumped core. */
unsigned int __w_retcode:8; /* Return code if exited normally. */
unsigned int:16;
#endif /* Little endian. */
#if __BYTE_ORDER == __BIG_ENDIAN
# endif /* Little endian. */
# if __BYTE_ORDER == __BIG_ENDIAN
unsigned int:16;
unsigned int __w_retcode:8;
unsigned int __w_coredump:1;
unsigned int __w_termsig:7;
#endif /* Big endian. */
# endif /* Big endian. */
} __wait_terminated;
struct
{
#if __BYTE_ORDER == __LITTLE_ENDIAN
# if __BYTE_ORDER == __LITTLE_ENDIAN
unsigned int __w_stopval:8; /* W_STOPPED if stopped. */
unsigned int __w_stopsig:8; /* Stopping signal. */
unsigned int:16;
#endif /* Little endian. */
#if __BYTE_ORDER == __BIG_ENDIAN
# endif /* Little endian. */
# if __BYTE_ORDER == __BIG_ENDIAN
unsigned int:16;
unsigned int __w_stopsig:8; /* Stopping signal. */
unsigned int __w_stopval:8; /* W_STOPPED if stopped. */
#endif /* Big endian. */
# endif /* Big endian. */
} __wait_stopped;
};
#define w_termsig __wait_terminated.__w_termsig
#define w_coredump __wait_terminated.__w_coredump
#define w_retcode __wait_terminated.__w_retcode
#define w_stopsig __wait_stopped.__w_stopsig
#define w_stopval __wait_stopped.__w_stopval
# define w_termsig __wait_terminated.__w_termsig
# define w_coredump __wait_terminated.__w_coredump
# define w_retcode __wait_terminated.__w_retcode
# define w_stopsig __wait_stopped.__w_stopsig
# define w_stopval __wait_stopped.__w_stopval
#endif /* Use BSD. */

2
configure vendored
View File

@ -49,7 +49,7 @@ ac_help="$ac_help
--disable-versioning do not include versioning information in the
library objects [default=yes if supported]"
ac_help="$ac_help
--enable-add-ons=DIR... configure and build named extra directories"
--enable-add-ons=DIR1,DIR2... configure and build named extra directories"
ac_help="$ac_help
--enable-static-nss build static NSS modules [default=no]"

View File

@ -1,4 +1,4 @@
Dnl Process this file with autoconf to produce a configure script.
dnl Process this file with autoconf to produce a configure script.
AC_REVISION([$CVSid$])
AC_PREREQ(2.11)dnl dnl Minimum Autoconf version required.
AC_INIT(include/features.h)
@ -81,7 +81,7 @@ AC_ARG_ENABLE(versioning, dnl
dnl Generic infrastructure for drop-in additions to libc.
AC_ARG_ENABLE(add-ons, dnl
[ --enable-add-ons=DIR... configure and build named extra directories],
[ --enable-add-ons=DIR1,DIR2... configure and build named extra directories],
[add_ons=`echo "$enableval" | sed 's/,/ /g'`],
[add_ons=])
AC_CONFIG_SUBDIRS($add_ons)

View File

@ -402,7 +402,16 @@ _dl_start_profile (struct link_map *map, const char *output_dir)
/* Setup counting data. */
if (kcountsize < highpc - lowpc)
{
/* XXX I've not yet verified that the second expression is really
well suited but something like this is in any case necessary
for targets without hardware FP support. --drepper */
#if 0
s_scale = ((double) kcountsize / (highpc - lowpc)) * SCALE_1_TO_1;
#else
s_scale = (kcountsize * SCALE_1_TO_1) / (highpc - lowpc);
#endif
}
else
s_scale = SCALE_1_TO_1;

View File

@ -9,6 +9,17 @@ VERSION="@VERSION@"
BUGGLIBC="bugs@gnu.org"
ADDONS="@subdirs@"
HOST="@host@"
CC='@CC@'
CFLAGS="@CFLAGS@"
VERSIONING="@VERSIONING@"
BUILD_STATIC="@static@"
BUILD_SHARED="@shared@"
BUILD_PIC_DEFAULT="@pic_default@"
BUILD_PROFILE="@profile@"
BUILD_OMITFP="@omitfp@"
BUILD_BOUNDED="@bounded@"
BUILD_STATIC_NSS="@static_nss@"
STDIO="@stdio@"
PATH=/bin:/usr/bin:/usr/local/bin:$PATH
export PATH
@ -125,6 +136,17 @@ ${ORGANIZATION- $ORGANIZATION_C}
`[ -n "$ARCH" ] && echo Architecture: $ARCH`
`[ -n "$MACHINE" ] && echo Machine: $MACHINE`
`[ -n "$ADDONS" ] && echo Addons: $ADDONS`
`[ -n "$CFLAGS" ] && echo Build CFLAGS: $CFLAGS`
`[ -n "$CC" ] && echo Build CC: $CC`
`[ -n "$VERSIONING" ] && echo Versioning: $VERSIONING`
`[ -n "$BUILD_STATIC" ] && echo Build static: $BUILD_STATIC`
`[ -n "$BUILD_SHARED" ] && echo Build shared: $BUILD_SHARED`
`[ -n "$BUILD_PIC_DEFAULT" ] && echo Build pic-default: $BUILD_PIC_DEFAULT`
`[ -n "$BUILD_PROFILE" ] && echo Build profile: $BUILD_PROFILE`
`[ -n "$BUILD_OMITFP" ] && echo Build omitfp: $BUILD_OMITFP`
`[ -n "$BUILD_BOUNDED" ] && echo Build bounded: $BUILD_BOUNDED`
`[ -n "$BUILD_STATIC_NSS" ] && echo Build static-nss: $BUILD_STATIC_NSS`
`[ -n "$STDIO" ] && echo Stdio: $STDIO`
>Description:
$DESCRIPTION_C

View File

@ -40,11 +40,11 @@ __gconv_close (gconv_t cd)
if (srunp->end_fct != NULL)
(*srunp->end_fct) (drunp);
else
{
free (drunp->outbuf);
if (drunp->data != NULL)
free (drunp->data);
}
if (!drunp->is_last && drunp->outbuf != NULL)
free (drunp->outbuf);
/* Next step. */
++srunp;

View File

@ -18,6 +18,7 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include <errno.h>
#include <gconv.h>
#include <stdlib.h>
#include <string.h>
@ -112,12 +113,16 @@ __gconv_transform_ucs4_utf8 (struct gconv_step *step,
}
else
{
int save_errno = errno;
do_write = 0;
do
{
const char *newinbuf = inbuf;
size_t actually = __wmemrtombs (&data->outbuf[data->outbufavail],
size_t actually;
errno = 0;
actually = __wmemrtombs (&data->outbuf[data->outbufavail],
(const wchar_t **) &newinbuf,
*inlen / sizeof (wchar_t),
data->outbufsize - data->outbufavail,
@ -129,6 +134,13 @@ __gconv_transform_ucs4_utf8 (struct gconv_step *step,
data->outbufavail += actually;
/* Check whether an illegal character appeared. */
if (errno != 0)
{
result = GCONV_ILLEGAL_INPUT;
break;
}
if (data->is_last)
{
/* This is the last step. */
@ -159,6 +171,8 @@ __gconv_transform_ucs4_utf8 (struct gconv_step *step,
}
}
while (*inlen > 0 && result == GCONV_EMPTY_INPUT);
__set_errno (save_errno);
}
if (written != NULL && data->is_last)
@ -201,16 +215,19 @@ __gconv_transform_utf8_ucs4 (struct gconv_step *step,
}
else
{
int save_errno = errno;
do_write = 0;
do
{
const char *newinbuf = inbuf;
size_t actually = __wmemrtowcs ((wchar_t *) &data->outbuf[data->outbufavail],
size_t actually;
errno = 0;
actually = __wmemrtowcs ((wchar_t *) &data->outbuf[data->outbufavail],
&newinbuf, *inlen,
((data->outbufsize
- data->outbufavail)
/ sizeof (wchar_t)),
- data->outbufavail) / sizeof (wchar_t)),
(mbstate_t *) data->data);
/* Remember how much we converted. */
@ -219,6 +236,20 @@ __gconv_transform_utf8_ucs4 (struct gconv_step *step,
data->outbufavail += actually * sizeof (wchar_t);
/* Check whether an illegal character appeared. */
if (errno != 0)
{
result = GCONV_ILLEGAL_INPUT;
break;
}
if (*inlen == 0 && !mbsinit ((mbstate_t *) data->data))
{
/* We have an incomplete character at the end. */
result = GCONV_INCOMPLETE_INPUT;
break;
}
if (data->is_last)
{
/* This is the last step. */
@ -249,6 +280,8 @@ __gconv_transform_utf8_ucs4 (struct gconv_step *step,
}
}
while (*inlen > 0 && result == GCONV_EMPTY_INPUT);
__set_errno (save_errno);
}
if (written != NULL && data->is_last)

119
iconvdata/Makefile Normal file
View File

@ -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

5
iconvdata/configure vendored Executable file
View File

@ -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

16
iconvdata/extra-module.mk Normal file
View File

@ -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

145
iconvdata/gconv-modules Normal file
View File

@ -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

681
iconvdata/iso6937.c Normal file
View File

@ -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;
}

219
iconvdata/iso8859-1.c Normal file
View File

@ -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;
}

24
iconvdata/iso8859-10.c Normal file
View File

@ -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>

516
iconvdata/iso8859-10.h Normal file
View File

@ -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,
};

24
iconvdata/iso8859-2.c Normal file
View File

@ -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>

516
iconvdata/iso8859-2.h Normal file
View File

@ -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,
};

24
iconvdata/iso8859-3.c Normal file
View File

@ -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>

502
iconvdata/iso8859-3.h Normal file
View File

@ -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,
};

24
iconvdata/iso8859-4.c Normal file
View File

@ -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>

516
iconvdata/iso8859-4.h Normal file
View File

@ -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,
};

24
iconvdata/iso8859-5.c Normal file
View File

@ -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>

516
iconvdata/iso8859-5.h Normal file
View File

@ -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,
};

24
iconvdata/iso8859-6.c Normal file
View File

@ -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>

426
iconvdata/iso8859-6.h Normal file
View File

@ -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,
};

24
iconvdata/iso8859-7.c Normal file
View File

@ -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>

504
iconvdata/iso8859-7.h Normal file
View File

@ -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,
};

24
iconvdata/iso8859-8.c Normal file
View File

@ -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>

440
iconvdata/iso8859-8.h Normal file
View File

@ -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,
};

24
iconvdata/iso8859-9.c Normal file
View File

@ -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>

516
iconvdata/iso8859-9.h Normal file
View File

@ -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,
};

228
iconvdata/iso8859-generic.c Normal file
View File

@ -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;
}

630
iconvdata/t61.c Normal file
View File

@ -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;
}

View File

@ -26,7 +26,7 @@
#include <features.h>
#include <sys/types.h>
#include <bits/stat.h>
#include <sys/stat.h>
__BEGIN_DECLS

View File

@ -1,4 +1,4 @@
/* pty.h - Functions for pseudo TTY handling.
/* Functions for pseudo TTY handling.
Copyright (C) 1996, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
@ -22,8 +22,8 @@
#include <features.h>
#include <bits/ioctl-types.h>
#include <termios.h>
#include <sys/ioctl.h>
__BEGIN_DECLS

View File

@ -163,11 +163,11 @@ One can use it to easily construct complex number like in
@smallexample
3.0 - _Imaginary_I * 4.0
@end smallexample
@end deftypevr
@noindent
which results in the complex number with a real part of 3.0 and a
imaginary part -4.0.
@end deftypevr
@noindent
A more intuitive approach is to use the following macro.

View File

@ -33,7 +33,7 @@ routines := strcat strchr strcmp strcoll strcpy strcspn \
strtok_r strxfrm memchr memcmp memmove memset \
mempcpy bcopy bzero ffs stpcpy stpncpy \
strcasecmp strncase strcasecmp_l strncase_l \
memccpy memcpy wordcopy strsep \
memccpy memcpy wordcopy strsep strcasestr \
swab strfry memfrob memmem \
$(addprefix argz-,append count create ctsep next \
delete extract insert stringify \

View File

@ -154,6 +154,15 @@ extern size_t strspn __P ((__const char *__s, __const char *__accept));
extern char *strpbrk __P ((__const char *__s, __const char *__accept));
/* Find the first occurrence of NEEDLE in HAYSTACK. */
extern char *strstr __P ((__const char *__haystack, __const char *__needle));
#ifdef __USE_GNU
/* Similar to `strstr' but this function ignores the case of both strings. */
extern char *__strcasestr __P ((__const char *__haystack,
__const char *__needle));
extern char *strcasestr __P ((__const char *__haystack,
__const char *__needle));
#endif
/* Divide S into tokens separated by characters in DELIM. */
extern char *strtok __P ((char *__restrict __s,
__const char *__restrict __delim));

View File

@ -1,3 +1,7 @@
/* Alpha is little-endian. */
#ifndef _ENDIAN_H
# error "Never use <bits/endian.h> directly; include <endian.h> instead."
#endif
#define __BYTE_ORDER __LITTLE_ENDIAN

View File

@ -17,6 +17,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SETJMP_H
# error "Never include <bits/setjmp.h> directly; use <setjmp.h> instead."
#endif
/* The previous bits/setjmp.h had __jmp_buf defined as a structure.
We use an array of 'long int' instead, to make writing the
assembler easier. Naturally, user code should not depend on
@ -48,24 +52,24 @@
* registers.
*/
#if defined(__USE_MISC) || defined(__ASSEMBLY__)
#define JB_S0 0
#define JB_S1 1
#define JB_S2 2
#define JB_S3 3
#define JB_S4 4
#define JB_S5 5
#define JB_PC 6
#define JB_FP 7
#define JB_SP 8
#define JB_F2 9
#define JB_F3 10
#define JB_F4 11
#define JB_F5 12
#define JB_F6 13
#define JB_F7 14
#define JB_F8 15
#define JB_F9 16
#if defined __USE_MISC || defined __ASSEMBLY__
# define JB_S0 0
# define JB_S1 1
# define JB_S2 2
# define JB_S3 3
# define JB_S4 4
# define JB_S5 5
# define JB_PC 6
# define JB_FP 7
# define JB_SP 8
# define JB_F2 9
# define JB_F3 10
# define JB_F4 11
# define JB_F5 12
# define JB_F6 13
# define JB_F7 14
# define JB_F8 15
# define JB_F9 16
#endif
#ifndef __ASSEMBLY__

View File

@ -1,6 +1,5 @@
/* Copyright (C) 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Richard Henderson <rth@tamu.edu>, 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
@ -18,7 +17,7 @@
Boston, MA 02111-1307, USA. */
#ifndef _FENV_H
#error "Never use <bits/fenv.h> directly; include <fenv.h> instead."
# error "Never use <bits/fenv.h> directly; include <fenv.h> instead."
#endif
@ -100,5 +99,5 @@ typedef unsigned long fenv_t;
#endif
/* The system calls to talk to the kernel's FP code. */
extern unsigned long __ieee_get_fp_control(void);
extern void __ieee_set_fp_control(unsigned long);
extern unsigned long int __ieee_get_fp_control __P ((void));
extern void __ieee_set_fp_control __P ((unsigned long int __value));

View File

@ -1,3 +1,7 @@
/* ARM is little-endian. */
#ifndef _ENDIAN_H
# error "Never use <bits/endian.h> directly; include <endian.h> instead."
#endif
#define __BYTE_ORDER __LITTLE_ENDIAN

View File

@ -1,10 +1,14 @@
/* Define the machine-dependent type `jmp_buf'. ARM version. */
#ifndef _SETJMP_H
# error "Never include <bits/setjmp.h> directly; use <setjmp.h> instead."
#endif
#ifndef _ASM
/* Jump buffer contains v1-v6, sl, fp, sp, pc and (f4-f7) if we do FP. */
#if __ARM_USES_FP
# if __ARM_USES_FP
typedef int __jmp_buf[22];
#else
# else
typedef int __jmp_buf[10];
#endif
# endif
#endif

View File

@ -17,8 +17,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _BITS_BYTESWAP_H
#define _BITS_BYTESWAP_H 1
#if !defined _BYTESWAP_H && !defined _NETINET_IN_H
# error "Never use <bits/byteswap.h> directly; include <byteswap.h> instead."
#endif
/* Swap bytes in 16 bit value. */
#define __bswap_16(x) \
@ -39,5 +40,3 @@
__r.__l[1] = __bswap_32 (__v.__l[0]); \
__r.__ll; })
#endif
#endif /* bits/byteswap.h */

View File

@ -17,6 +17,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _UNISTD_H
# error "Never use <bits/confname.h> directly; include <unistd.h> instead."
#endif
/* Values for the NAME argument to `pathconf' and `fpathconf'. */
enum
{

View File

@ -1,5 +1,5 @@
/* Directory entry structure `struct dirent'. Stub version.
Copyright (C) 1996 Free Software Foundation, Inc.
Copyright (C) 1996, 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
@ -17,6 +17,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _DIRENT_H
# error "Never use <bits/dirent.h> directly; include <dirent.h> instead."
#endif
struct dirent
{
char d_name[1]; /* Variable length. */

View File

@ -17,8 +17,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _BITS_DLFCN_H
#define _BITS_DLFCN_H 1
#ifndef _DLFCN_H
# error "Never use <bits/dlfcn.h> directly; include <dlfcn.h> instead."
#endif
/* The MODE argument to `dlopen' contains one of the following: */
#define RTLD_LAZY 0x001 /* Lazy function call binding. */
@ -29,5 +30,3 @@
the symbols of the loaded object and its dependencies are made
visible as if the object were linked directly into the program. */
#define RTLD_GLOBAL 0x100
#endif /* bits/dlfcn.h */

View File

@ -6,4 +6,8 @@
So if cross-compiling to a machine with a different byte order,
the bits/endian.h file for that machine must exist. */
#ifndef _ENDIAN_H
# error "Never use <bits/endian.h> directly; include <endian.h> instead."
#endif
#error Machine byte order unknown.

View File

@ -17,7 +17,7 @@
Boston, MA 02111-1307, USA. */
#ifndef _FENV_H
#error "Never use <bits/fenv.h> directly; include <fenv.h> instead."
# error "Never use <bits/fenv.h> directly; include <fenv.h> instead."
#endif

View File

@ -1,6 +1,6 @@
/* Stub `HUGE_VAL' constant.
Used by <stdlib.h> and <math.h> functions for overflow.
Copyright (C) 1992, 1996 Free Software Foundation, Inc.
Copyright (C) 1992, 1996, 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
@ -19,7 +19,7 @@
Boston, MA 02111-1307, USA. */
#ifndef _MATH_H
#error "Never use <bits/huge_val.h> directly; include <math.h> instead."
# error "Never use <bits/huge_val.h> directly; include <math.h> instead."
#endif

View File

@ -18,8 +18,9 @@
/* Generic version. */
#ifndef _NETINET_INBITS_H
#define _NETINET_INBITS_H 1
#ifndef _NETINET_IN_H
# error "Never use <bits/in.h> directly; include <netinet/in.h> instead."
#endif
/* Link numbers. */
#define IMPLINK_IP 155
@ -55,10 +56,10 @@ struct ip_opts
/* Structure used for IP_ADD_MEMBERSHIP and IP_DROP_MEMBERSHIP. */
struct ip_mreq
{
{
struct in_addr imr_multiaddr; /* IP multicast address of group */
struct in_addr imr_interface; /* local IP address of interface */
};
};
/* IPV6 socket options. */
#define IPV6_ADDRFORM 1
@ -80,5 +81,3 @@ struct ip_mreq
#define IPV6_MULTICAST_LOOP 19
#define IPV6_ADD_MEMBERSHIP 20
#define IPV6_DROP_MEMBERSHIP 21
#endif /* netinet/inbits.h */

View File

@ -1,5 +1,5 @@
/* Structure types for pre-termios terminal ioctls. Generic Unix version.
Copyright (C) 1996 Free Software Foundation, Inc.
Copyright (C) 1996, 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
@ -17,15 +17,11 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/*
* Never include this file directly; use <sys/ioctl.h> instead.
*/
#ifndef _SYS_IOCTL_H
# error "Never use <bits/ioctl-types.h> directly; include <sys/ioctl.h> instead."
#endif
#ifndef _BITS_IOCTL_TYPES_H
#define _BITS_IOCTL_TYPES_H 1
#if defined(TIOCGETC) || defined(TIOCSETC)
#if defined TIOCGETC || defined TIOCSETC
/* Type of ARG for TIOCGETC and TIOCSETC requests. */
struct tchars
{
@ -41,7 +37,7 @@ struct tchars
_IOT (_IOTS (char), 6, 0, 0, 0, 0)
#endif
#if defined(TIOCGLTC) || defined(TIOCSLTC)
#if defined TIOCGLTC || defined TIOCSLTC
/* Type of ARG for TIOCGLTC and TIOCSLTC requests. */
struct ltchars
{
@ -70,7 +66,7 @@ struct sgttyb
#define _IOT_sgttyb /* Hurd ioctl type field. */ \
_IOT (_IOTS (char), 6, _IOTS (short int), 1, 0, 0)
#if defined(TIOCGWINSZ) || defined(TIOCSWINSZ)
#if defined TIOCGWINSZ || defined TIOCSWINSZ
/* Type of ARG for TIOCGWINSZ and TIOCSWINSZ requests. */
struct winsize
{
@ -86,13 +82,13 @@ struct winsize
_IOT (_IOTS (unsigned short int), 4, 0, 0, 0, 0)
#endif
#if defined (TIOCGSIZE) || defined (TIOCSSIZE)
#if defined TIOCGSIZE || defined TIOCSSIZE
/* The BSD-style ioctl constructor macros use `sizeof', which can't be used
in a preprocessor conditional. Since the commands are always unique
regardless of the size bits, we can safely define away `sizeof' for the
purpose of the conditional. */
# define sizeof(type) 0
# if defined (TIOCGWINSZ) && TIOCGSIZE == TIOCGWINSZ
# if defined TIOCGWINSZ && TIOCGSIZE == TIOCGWINSZ
/* Many systems that have TIOCGWINSZ define TIOCGSIZE for source
compatibility with Sun; they define `struct ttysize' to have identical
layout as `struct winsize' and #define TIOCGSIZE to be TIOCGWINSZ
@ -116,6 +112,3 @@ struct ttysize
# endif
# undef sizeof /* See above. */
#endif
#endif /* bits/ioctl-types.h */

View File

@ -1 +1,5 @@
#ifndef _SYS_IOCTL_H
# error "Never use <bits/ioctls.h> directly; include <sys/ioctl.h> instead."
#endif
/* This space intentionally left blank. */

View File

@ -1,4 +1,4 @@
/* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
/* Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
@ -17,10 +17,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SYS_IPC_BUF_H
#define _SYS_IPC_BUF_H 1
#include <features.h>
#ifndef _SYS_IPC_H
# error "Never use <bits/ipc.h> directly; include <sys/ipc.h> instead."
#endif
#include <sys/types.h>
@ -34,23 +33,16 @@
#define IPC_SET 1 /* set `ipc_perm' options */
#define IPC_STAT 2 /* get `ipc_perm' options */
__BEGIN_DECLS
/* Special key values. */
#define IPC_PRIVATE ((key_t) 0) /* private key */
/* Data structure used to pass permission information to IPC operations. */
struct ipc_perm
{
{
__uid_t uid; /* owner's user ID */
__gid_t gid; /* owner's group ID */
__uid_t cuid; /* creator's user ID */
__gid_t cgid; /* creator's group ID */
__mode_t mode; /* read/write permission */
};
__END_DECLS
#endif /* _SYS_IPC_BUF_H */
};

View File

@ -1,6 +1,5 @@
/* Copyright (C) 1995, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
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
@ -21,14 +20,11 @@
#error "Never use <bits/msq.h> directly; include <sys/msg.h> instead."
#endif
#include <features.h>
#include <sys/types.h>
/* Define options for message queue functions. */
#define MSG_NOERROR 010000 /* no error if message is too big */
__BEGIN_DECLS
/* Structure of record for one message inside the kernel.
The type `struct __msg' is opaque. */
@ -43,5 +39,3 @@ struct msqid_ds
__pid_t msg_lspid; /* pid of last msgsnd() */
__pid_t msg_lrpid; /* pid of last msgrcv() */
};
__END_DECLS

View File

@ -16,6 +16,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SYS_POLL_H
# error "Never use <bits/poll.h> directly; include <sys/poll.h> instead."
#endif
/* Event types that can be polled for. These bits may be set in `events'
to indicate the interesting event types; they will appear in `revents'

View File

@ -17,6 +17,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SYS_RESOURCE_H
# error "Never use <bits/resource.h> directly; include <sys/resource.h> instead."
#endif
/* These are the values for 4.4 BSD and GNU. Earlier BSD systems have a
subset of these kinds of resource limit. In systems where `getrlimit'
and `setrlimit' are not system calls, these are the values used by the C
@ -107,7 +111,8 @@ enum __rusage_who
#define RUSAGE_CHILDREN RUSAGE_CHILDREN
};
#include <sys/time.h> /* For `struct timeval'. */
#define __need_timeval
#include <bits/time.h> /* For `struct timeval'. */
/* Structure which says how much of each resource has been used. */
struct rusage

View File

@ -1,6 +1,6 @@
/* Definitions of constants and data structure for POSIX 1003.1b-1993
scheduling interface.
Copyright (C) 1996 Free Software Foundation, Inc.
Copyright (C) 1996, 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
@ -19,7 +19,7 @@
Suite 330, Boston, MA 02111-1307, USA. */
#ifndef _SCHED_H
#error "Never use <bits/sched.h> directly; include <sched.h> instead."
# error "Never include <bits/sched.h> directly; use <sched.h> instead."
#endif

View File

@ -1,6 +1,5 @@
/* Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
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
@ -18,11 +17,9 @@
Boston, MA 02111-1307, USA. */
#ifndef _SYS_SEM_H
#error "Never use <bits/sem.h> directly; include <sys/sem.h> instead."
# error "Never include <bits/sem.h> directly; use <sys/sem.h> instead."
#endif
#include <features.h>
#include <sys/types.h>
/* Flags for `semop'. */
@ -38,8 +35,6 @@
#define SETALL 17 /* set all semval's */
__BEGIN_DECLS
/* Data structure describing a set of semaphores. */
struct semid_ds
{
@ -57,5 +52,3 @@ union semun
unsigned short int *array; /* array for GETALL & SETALL */
struct seminfo *__buf; /* buffer for IPC_INFO */
};
__END_DECLS

View File

@ -1,3 +1,7 @@
/* Define the machine-dependent type `jmp_buf'. Stub version. */
#ifndef _SETJMP_H
# error "Never include <bits/setjmp.h> directly; use <setjmp.h> instead."
#endif
typedef int __jmp_buf[1];

View File

@ -1,6 +1,5 @@
/* Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
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
@ -18,11 +17,9 @@
Boston, MA 02111-1307, USA. */
#ifndef _SYS_SHM_H
#error "Never use <bits/shm.h> directly; include <sys/shm.h> instead."
# error "Never include <bits/shm.h> directly; use <sys/shm.h> instead."
#endif
#include <features.h>
#include <sys/types.h>
/* Flags for `shmat'. */
@ -35,11 +32,9 @@
#define SHM_UNLOCK 12 /* unlock segment (root only) */
__BEGIN_DECLS
/* Data structure describing a set of semaphores. */
struct shmid_ds
{
{
struct ipc_perm sem_perm; /* operation permission struct */
int shm_segsz; /* size of segment in bytes */
__time_t sem_atime; /* time of last shmat() */
@ -48,6 +43,4 @@ struct shmid_ds
__pid_t shm_cpid; /* pid of creator */
__pid_t shm_lpid; /* pid of last shmop */
unsigned short int shm_nattch; /* number of current attaches */
};
__END_DECLS
};

View File

@ -16,6 +16,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SIGNAL_H
# error "Never include <bits/sigaction.h> directly; use <signal.h> instead."
#endif
/* These definitions match those used by the 4.4 BSD kernel.
If the operating system has a `sigaction' system call that correctly
implements the POSIX.1 behavior, there should be a system-dependent

View File

@ -17,6 +17,10 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef _SIGNAL_H
# error "Never use <bits/sigcontext.h> directly; include <signal.h> instead."
#endif
/* State of this thread when the signal was taken. */
struct sigcontext
{

View File

@ -18,17 +18,12 @@
Boston, MA 02111-1307, USA. */
#ifndef _SYS_SOCKET_H
#error "Never include <bits/socket.h> directly; use <sys/socket.h> instead."
# error "Never include <bits/socket.h> directly; use <sys/socket.h> instead."
#endif
#include <features.h>
#define __need_size_t
#include <stddef.h>
__BEGIN_DECLS
/* Type for length arguments in socket calls. */
typedef unsigned int socklen_t;
@ -201,5 +196,3 @@ struct linger
int l_onoff; /* Nonzero to linger on close. */
int l_linger; /* Time to linger. */
};
__END_DECLS

View File

@ -16,16 +16,13 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/*
* Never include this file directly; use <sys/stat.h> instead.
*/
#ifndef _SYS_STAT_H
# error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
#endif
/* This structure needs to be defined in accordance with the
implementation of __stat, __fstat, and __lstat. */
#ifndef _BITS_STAT_H
#define _BITS_STAT_H 1
#include <bits/types.h>
/* Structure describing file characteristics. */
@ -87,6 +84,3 @@ struct stat64
__time_t st_ctime; /* Time of last status change. */
};
#endif
#endif /* bits/stat.h */

View File

@ -17,12 +17,9 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/*
* Never include this file directly; use <sys/statfs.h> instead.
*/
#ifndef _BITS_STATFS_H
#define _BITS_STATFS_H 1
#ifndef _SYS_STATFS_H
# error "Never include <bits/statfs.h> directly; use <sys/statfs.h> instead."
#endif
#include <bits/types.h>
@ -47,6 +44,3 @@ struct statfs
unsigned int f_namelen;
unsigned int f_spare[6];
};
#endif /* bits/statfs.h */

View File

@ -1,4 +1,5 @@
/* Copyright (C) 1994, 1997 Free Software Foundation, Inc.
/* Stdio limits for non-POSIX systems.
Copyright (C) 1994, 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
@ -16,22 +17,17 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* <bits/stdio_lim.h>: stdio limits for non-POSIX systems.
* Never include this file directly; use <stdio.h> instead.
*/
#ifndef _BITS_STDIO_LIM_H
#define _BITS_STDIO_LIM_H
#ifndef _STDIO_H
# error "Never include <bits/stdio_lim.h> directly; use <stdio.h> instead."
#endif
#define L_tmpnam 1
#define TMP_MAX 0
#ifdef __USE_POSIX
#define L_ctermid 1
#define L_cuserid 1
# define L_ctermid 1
# define L_cuserid 1
#endif
#define FOPEN_MAX 16
#define FILENAME_MAX 14
#endif

Some files were not shown because too many files have changed in this diff Show More