summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoreberlein <eberlein@7b3dc134-2b1b-0410-93df-9e9f96275f8d>2008-08-19 18:22:04 +0000
committereberlein <eberlein@7b3dc134-2b1b-0410-93df-9e9f96275f8d>2008-08-19 18:22:04 +0000
commit743290adb85f9ec3b0c785af4c1d2055fe9013c1 (patch)
tree7c6b7a4386e7b0c45297fb8bda203f3b359858cc
parent764716dacf71f48190b99d1bd638a91a5cc3012b (diff)
Merged EGLIBC trunk (-r 5766:6785) and regenerated libc/configure.
git-svn-id: svn://svn.eglibc.org/branches/libdfp@6786 7b3dc134-2b1b-0410-93df-9e9f96275f8d
-rw-r--r--libc/ChangeLog1462
-rw-r--r--libc/ChangeLog.eglibc44
-rw-r--r--libc/Makeconfig7
-rw-r--r--libc/Makefile11
-rw-r--r--libc/NEWS67
-rw-r--r--libc/Versions.def3
-rw-r--r--libc/bits/byteswap.h4
-rw-r--r--libc/bits/termios.h98
-rw-r--r--libc/config.make.in2
-rwxr-xr-xlibc/configure6512
-rw-r--r--libc/configure.in27
-rw-r--r--libc/debug/wctomb_chk.c6
-rw-r--r--libc/dfp/Makefile1
-rw-r--r--libc/dfp/test/README11
-rw-r--r--libc/elf/Makefile28
-rw-r--r--libc/elf/dl-conflict.c9
-rw-r--r--libc/elf/dl-load.c11
-rw-r--r--libc/elf/dl-object.c10
-rw-r--r--libc/elf/dl-reloc.c42
-rw-r--r--libc/elf/dl-support.c2
-rw-r--r--libc/elf/dl-sysdep.c1
-rw-r--r--libc/elf/dl-tls.c99
-rw-r--r--libc/elf/dynamic-link.h27
-rw-r--r--libc/elf/elf.h24
-rw-r--r--libc/elf/soinit.c4
-rw-r--r--libc/elf/tls-macros.h9
-rw-r--r--libc/elf/tlsdeschtab.h157
-rw-r--r--libc/hurd/fd-read.c8
-rw-r--r--libc/hurd/get-host.c1
-rw-r--r--libc/hurd/hurd/fd.h13
-rw-r--r--libc/hurd/hurd/signal.h9
-rw-r--r--libc/iconv/gconv_simple.c18
-rw-r--r--libc/iconvdata/Depend1
-rw-r--r--libc/iconvdata/Makefile3
-rw-r--r--libc/iconvdata/bug-iconv6.c2
-rwxr-xr-xlibc/iconvdata/run-iconv-test.sh4
-rw-r--r--libc/include/arpa/nameser.h37
-rw-r--r--libc/include/arpa/nameser_compat.h7
-rw-r--r--libc/include/features.h2
-rw-r--r--libc/include/fenv.h1
-rw-r--r--libc/include/inline-hashtab.h301
-rw-r--r--libc/include/resolv.h14
-rw-r--r--libc/include/rpc/clnt.h12
-rw-r--r--libc/include/sys/socket.h8
-rw-r--r--libc/include/unistd.h7
-rw-r--r--libc/inet/netinet/in.h6
-rw-r--r--libc/io/Makefile4
-rw-r--r--libc/io/Versions3
-rw-r--r--libc/io/dup3.c48
-rw-r--r--libc/io/ftw.c4
-rw-r--r--libc/io/openat.c2
-rw-r--r--libc/io/openat64.c2
-rw-r--r--libc/io/pipe2.c (renamed from ports/sysdeps/unix/sysv/linux/mips/xmknod.c)39
-rw-r--r--libc/libio/Makefile4
-rw-r--r--libc/libio/fileops.c4
-rw-r--r--libc/libio/fmemopen.c11
-rw-r--r--libc/libio/freopen.c5
-rw-r--r--libc/libio/freopen64.c5
-rw-r--r--libc/libio/iofwrite.c8
-rw-r--r--libc/libio/iofwrite_u.c8
-rw-r--r--libc/libio/iopopen.c120
-rw-r--r--libc/libio/iosetvbuf.c2
-rw-r--r--libc/libio/stdio.h2
-rw-r--r--libc/libio/tst-popen1.c49
-rw-r--r--libc/locale/programs/ld-collate.c22
-rw-r--r--libc/locale/setlocale.c43
-rw-r--r--libc/localedata/ChangeLog75
-rw-r--r--libc/localedata/Makefile2
-rw-r--r--libc/localedata/charmaps/UTF-8135
-rw-r--r--libc/localedata/locales/be_BY2
-rw-r--r--libc/localedata/locales/es_CR2
-rw-r--r--libc/localedata/locales/es_ES2068
-rw-r--r--libc/localedata/locales/fi_FI8
-rw-r--r--libc/localedata/locales/fr_FR59
-rw-r--r--libc/localedata/locales/hu_HU4
-rw-r--r--libc/localedata/locales/i18n412
-rw-r--r--libc/localedata/locales/iso14651_t1_common1613
-rwxr-xr-xlibc/localedata/tst-langinfo.sh40
-rw-r--r--libc/localedata/tst-strptime.c35
-rw-r--r--libc/login/utmp_file.c34
-rw-r--r--libc/malloc/hooks.c4
-rw-r--r--libc/malloc/mtrace.c18
-rw-r--r--libc/malloc/mtrace.pl2
-rw-r--r--libc/manual/arith.texi6
-rw-r--r--libc/manual/creature.texi2
-rw-r--r--libc/manual/filesys.texi2
-rw-r--r--libc/manual/math.texi2
-rw-r--r--libc/manual/memory.texi2
-rw-r--r--libc/manual/resource.texi4
-rw-r--r--libc/manual/syslog.texi2
-rw-r--r--libc/manual/time.texi2
-rw-r--r--libc/math/libm-test.inc47
-rw-r--r--libc/math/s_significandl.c2
-rw-r--r--libc/misc/fstab.c6
-rw-r--r--libc/misc/regexp.h16
-rw-r--r--libc/misc/syslog.c31
-rw-r--r--libc/misc/truncate64.c2
-rw-r--r--libc/nis/Versions3
-rw-r--r--libc/nis/nss_nis/nis-hosts.c118
-rw-r--r--libc/nis/nss_nisplus/nisplus-hosts.c222
-rw-r--r--libc/nis/ypclnt.c17
-rw-r--r--libc/nptl/ChangeLog108
-rw-r--r--libc/nptl/Makefile6
-rw-r--r--libc/nptl/allocatestack.c22
-rw-r--r--libc/nptl/pthread_create.c4
-rw-r--r--libc/nptl/sysdeps/powerpc/tcb-offsets.sym2
-rw-r--r--libc/nptl/sysdeps/pthread/createthread.c4
-rw-r--r--libc/nptl/sysdeps/pthread/pthread.h6
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S19
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S37
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S23
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S21
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S33
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S33
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S20
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S21
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/i386/i486/sem_post.S16
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/mq_notify.c29
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/sparc/lowlevellock.h4
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c2
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc64/Makefile4
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S21
-rw-r--r--libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S21
-rw-r--r--libc/nptl/sysdeps/x86_64/pthreaddef.h10
-rw-r--r--libc/nptl/tst-align2.c2
-rw-r--r--libc/nptl/tst-rwlock2.c28
-rw-r--r--libc/nptl/tst-rwlock2a.c2
-rw-r--r--libc/nptl/tst-typesizes.c29
-rw-r--r--libc/nscd/Makefile4
-rw-r--r--libc/nscd/aicache.c500
-rw-r--r--libc/nscd/cache.c59
-rw-r--r--libc/nscd/connections.c424
-rw-r--r--libc/nscd/grpcache.c49
-rw-r--r--libc/nscd/hstcache.c66
-rw-r--r--libc/nscd/initgrcache.c30
-rw-r--r--libc/nscd/mem.c69
-rw-r--r--libc/nscd/nscd.h35
-rw-r--r--libc/nscd/nscd_getserv_r.c2
-rw-r--r--libc/nscd/nscd_helper.c31
-rw-r--r--libc/nscd/pwdcache.c65
-rw-r--r--libc/nscd/servicescache.c26
-rw-r--r--libc/nss/Versions1
-rw-r--r--libc/nss/getent.c16
-rw-r--r--libc/nss/nss.h14
-rw-r--r--libc/nss/nss_files/files-XXX.c2
-rw-r--r--libc/nss/nss_files/files-hosts.c133
-rw-r--r--libc/po/libc.pot497
-rw-r--r--libc/po/lt.po7082
-rw-r--r--libc/po/nl.po55
-rw-r--r--libc/posix/glob.c5
-rwxr-xr-xlibc/posix/globtest.sh5
-rw-r--r--libc/posix/regcomp.c48
-rw-r--r--libc/posix/regex_internal.c6
-rw-r--r--libc/posix/tst-regex.c20
-rw-r--r--libc/posix/tst-rfc3484-2.c11
-rw-r--r--libc/posix/tst-rfc3484-3.c11
-rw-r--r--libc/posix/tst-rfc3484.c11
-rw-r--r--libc/posix/unistd.h14
-rw-r--r--libc/posix/wordexp.c58
-rw-r--r--libc/resolv/Makefile5
-rw-r--r--libc/resolv/Versions14
-rw-r--r--libc/resolv/arpa/nameser.h397
-rw-r--r--libc/resolv/arpa/nameser_compat.h64
-rw-r--r--libc/resolv/gethnamaddr.c6
-rw-r--r--libc/resolv/ns_date.c121
-rw-r--r--libc/resolv/ns_name.c589
-rw-r--r--libc/resolv/ns_netint.c22
-rw-r--r--libc/resolv/ns_parse.c94
-rw-r--r--libc/resolv/ns_print.c203
-rw-r--r--libc/resolv/ns_samedomain.c65
-rw-r--r--libc/resolv/ns_ttl.c9
-rw-r--r--libc/resolv/nss_dns/dns-canon.c9
-rw-r--r--libc/resolv/nss_dns/dns-host.c389
-rw-r--r--libc/resolv/nss_dns/dns-network.c6
-rw-r--r--libc/resolv/res_debug.c3
-rw-r--r--libc/resolv/res_init.c46
-rw-r--r--libc/resolv/res_mkquery.c21
-rw-r--r--libc/resolv/res_query.c188
-rw-r--r--libc/resolv/res_send.c372
-rw-r--r--libc/scripts/abi-versions.awk3
-rw-r--r--libc/scripts/data/localplt-powerpc64-linux-gnu.data6
-rw-r--r--libc/scripts/data/localplt-sparc-linux-gnu.data18
-rw-r--r--libc/scripts/data/localplt-sparc64-linux-gnu.data20
-rw-r--r--libc/scripts/gen-as-const.awk16
-rw-r--r--libc/scripts/soversions.awk13
-rw-r--r--libc/shlib-versions5
-rw-r--r--libc/socket/Makefile6
-rw-r--r--libc/socket/Versions3
-rw-r--r--libc/socket/have_sock_cloexec.c24
-rw-r--r--libc/socket/paccept.c43
-rw-r--r--libc/socket/sys/socket.h18
-rw-r--r--libc/stdio-common/Makefile13
-rw-r--r--libc/stdio-common/_i18n_number.h24
-rw-r--r--libc/stdio-common/printf_fp.c51
-rw-r--r--libc/stdio-common/scanf14.c53
-rw-r--r--libc/stdio-common/scanf15.c43
-rw-r--r--libc/stdio-common/scanf16.c147
-rw-r--r--libc/stdio-common/scanf17.c128
-rw-r--r--libc/stdio-common/tst-setvbuf1.c19
-rw-r--r--libc/stdio-common/tst-setvbuf1.expect2
-rw-r--r--libc/stdio-common/vfprintf.c15
-rw-r--r--libc/stdlib/canonicalize.c4
-rw-r--r--libc/stdlib/mbtowc.c11
-rw-r--r--libc/stdlib/tst-makecontext.c9
-rw-r--r--libc/stdlib/tst-setcontext.c8
-rw-r--r--libc/stdlib/wctomb.c10
-rw-r--r--libc/string/Makefile9
-rw-r--r--libc/string/endian.h40
-rw-r--r--libc/string/memmem.c58
-rw-r--r--libc/string/str-two-way.h430
-rw-r--r--libc/string/strcasestr.c152
-rw-r--r--libc/string/strstr.c142
-rw-r--r--libc/string/test-memmem.c185
-rw-r--r--libc/string/test-string.h12
-rw-r--r--libc/string/tester.c34
-rw-r--r--libc/string/tst-endian.c112
-rw-r--r--libc/sunrpc/Makefile24
-rw-r--r--libc/sunrpc/Versions3
-rw-r--r--libc/sunrpc/clnt_udp.c60
-rw-r--r--libc/sunrpc/key_call.c2
-rw-r--r--libc/sunrpc/proto.h21
-rw-r--r--libc/sysdeps/generic/ldsodefs.h1
-rw-r--r--libc/sysdeps/i386/Makefile10
-rw-r--r--libc/sysdeps/i386/bits/byteswap.h4
-rw-r--r--libc/sysdeps/i386/bits/linkmap.h1
-rw-r--r--libc/sysdeps/i386/dl-lookupcfg.h28
-rw-r--r--libc/sysdeps/i386/dl-machine.h131
-rw-r--r--libc/sysdeps/i386/dl-tls.h2
-rw-r--r--libc/sysdeps/i386/dl-tlsdesc.S290
-rw-r--r--libc/sysdeps/i386/dl-tlsdesc.h61
-rw-r--r--libc/sysdeps/i386/fpu/s_expm1l.S7
-rw-r--r--libc/sysdeps/i386/i686/memcmp.S5
-rw-r--r--libc/sysdeps/i386/i686/memcpy.S57
-rw-r--r--libc/sysdeps/i386/tlsdesc.c269
-rw-r--r--libc/sysdeps/i386/tlsdesc.sym17
-rw-r--r--libc/sysdeps/ia64/bits/byteswap.h4
-rw-r--r--libc/sysdeps/ieee754/ldbl-128/e_j0l.c20
-rw-r--r--libc/sysdeps/ieee754/ldbl-128/e_j1l.c20
-rw-r--r--libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c6
-rw-r--r--libc/sysdeps/ieee754/ldbl-128/s_expm1l.c2
-rw-r--r--libc/sysdeps/ieee754/ldbl-128/s_log1pl.c9
-rw-r--r--libc/sysdeps/ieee754/ldbl-128ibm/e_expl.c8
-rw-r--r--libc/sysdeps/ieee754/ldbl-128ibm/s_expm1l.c2
-rw-r--r--libc/sysdeps/ieee754/ldbl-128ibm/s_log1pl.c8
-rw-r--r--libc/sysdeps/ieee754/ldbl-128ibm/s_nearbyintl.c8
-rw-r--r--libc/sysdeps/mach/hurd/bits/fcntl.h2
-rw-r--r--libc/sysdeps/mach/hurd/bits/ioctls.h56
-rw-r--r--libc/sysdeps/mach/hurd/dl-sysdep.c1
-rw-r--r--libc/sysdeps/mach/hurd/open.c13
-rw-r--r--libc/sysdeps/mach/hurd/openat.c14
-rw-r--r--libc/sysdeps/mach/hurd/recv.c4
-rw-r--r--libc/sysdeps/mach/hurd/recvfrom.c6
-rw-r--r--libc/sysdeps/mach/hurd/recvmsg.c6
-rw-r--r--libc/sysdeps/mach/hurd/send.c2
-rw-r--r--libc/sysdeps/mach/hurd/sendmsg.c2
-rw-r--r--libc/sysdeps/mach/hurd/sendto.c2
-rw-r--r--libc/sysdeps/mach/i386/machine-lock.h8
-rw-r--r--libc/sysdeps/posix/clock_getres.c4
-rw-r--r--libc/sysdeps/posix/getaddrinfo.c293
-rw-r--r--libc/sysdeps/powerpc/bits/fenv.h7
-rw-r--r--libc/sysdeps/powerpc/dl-procinfo.c10
-rw-r--r--libc/sysdeps/powerpc/dl-procinfo.h10
-rw-r--r--libc/sysdeps/powerpc/fpu/Makefile1
-rw-r--r--libc/sysdeps/powerpc/fpu/bits/mathinline.h10
-rw-r--r--libc/sysdeps/powerpc/fpu/e_sqrt.c8
-rw-r--r--libc/sysdeps/powerpc/fpu/e_sqrtf.c8
-rw-r--r--libc/sysdeps/powerpc/fpu/fe_nomask.c5
-rw-r--r--libc/sysdeps/powerpc/fpu/fedisblxcpt.c6
-rw-r--r--libc/sysdeps/powerpc/fpu/feenablxcpt.c6
-rw-r--r--libc/sysdeps/powerpc/fpu/fegetexcept.c7
-rw-r--r--libc/sysdeps/powerpc/fpu/fenv_libc.h6
-rw-r--r--libc/sysdeps/powerpc/fpu/fraiseexcpt.c11
-rw-r--r--libc/sysdeps/powerpc/fpu/test-powerpc-snan.c385
-rw-r--r--libc/sysdeps/powerpc/powerpc32/dl-machine.c5
-rw-r--r--libc/sysdeps/powerpc/powerpc32/fpu/s_isnan.S56
-rw-r--r--libc/sysdeps/powerpc/powerpc32/fpu/s_isnan.c7
-rw-r--r--libc/sysdeps/powerpc/powerpc32/fpu/s_lround.S52
-rw-r--r--libc/sysdeps/powerpc/powerpc32/fpu/s_lroundf.S1
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power4/fpu/s_llround.S71
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.S119
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.c62
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.S111
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.c60
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power4/hp-timing.c25
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power4/hp-timing.h152
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power5+/fpu/s_llroundf.S1
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power5/fpu/s_isnan.S62
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power5/fpu/s_isnanf.S46
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power5/fpu/w_sqrt.S117
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power5/fpu/w_sqrtf.S109
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power6/fpu/s_isnan.S62
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power6/fpu/s_isnanf.S46
-rw-r--r--libc/sysdeps/powerpc/powerpc32/power6/fpu/s_llroundf.S1
-rw-r--r--libc/sysdeps/powerpc/powerpc64/dl-machine.h65
-rw-r--r--libc/sysdeps/powerpc/powerpc64/fpu/s_isnan.S57
-rw-r--r--libc/sysdeps/powerpc/powerpc64/fpu/s_isnan.c7
-rw-r--r--libc/sysdeps/powerpc/powerpc64/fpu/s_llround.S57
-rw-r--r--libc/sysdeps/powerpc/powerpc64/fpu/s_llroundf.S53
-rw-r--r--libc/sysdeps/powerpc/powerpc64/fpu/s_lrint.S1
-rw-r--r--libc/sysdeps/powerpc/powerpc64/fpu/s_lround.S1
-rw-r--r--libc/sysdeps/powerpc/powerpc64/fpu/s_lroundf.S1
-rw-r--r--libc/sysdeps/powerpc/powerpc64/hp-timing.h6
-rw-r--r--libc/sysdeps/powerpc/powerpc64/power5/fpu/s_isnan.S61
-rw-r--r--libc/sysdeps/powerpc/powerpc64/power6/fpu/s_isnan.S60
-rw-r--r--libc/sysdeps/powerpc/powerpc64/power6x/fpu/s_isnan.S59
-rw-r--r--libc/sysdeps/powerpc/sysdep.h2
-rw-r--r--libc/sysdeps/s390/bits/byteswap.h4
-rw-r--r--libc/sysdeps/sparc/Makefile6
-rw-r--r--libc/sysdeps/sparc/machine-gmon.h33
-rw-r--r--libc/sysdeps/sparc/sparc-mcount.S29
-rw-r--r--libc/sysdeps/sparc/sparc32/Makefile4
-rw-r--r--libc/sysdeps/sparc/sparc64/Makefile4
-rw-r--r--libc/sysdeps/sparc/sparc64/backtrace.c58
-rw-r--r--libc/sysdeps/sparc/sparc64/elf/configure63
-rw-r--r--libc/sysdeps/sparc/sparc64/elf/configure.in89
-rw-r--r--libc/sysdeps/unix/bsd/bsd4.4/bits/socket.h4
-rw-r--r--libc/sysdeps/unix/syscalls.list1
-rw-r--r--libc/sysdeps/unix/sysv/linux/Makefile2
-rw-r--r--libc/sysdeps/unix/sysv/linux/Versions3
-rw-r--r--libc/sysdeps/unix/sysv/linux/alpha/bits/resource.h10
-rw-r--r--libc/sysdeps/unix/sysv/linux/alpha/sys/epoll.h143
-rw-r--r--libc/sysdeps/unix/sysv/linux/alpha/sys/eventfd.h52
-rw-r--r--libc/sysdeps/unix/sysv/linux/alpha/sys/inotify.h105
-rw-r--r--libc/sysdeps/unix/sysv/linux/alpha/sys/signalfd.h66
-rw-r--r--libc/sysdeps/unix/sysv/linux/alpha/sys/timerfd.h60
-rw-r--r--libc/sysdeps/unix/sysv/linux/bits/in.h2
-rw-r--r--libc/sysdeps/unix/sysv/linux/bits/resource.h10
-rw-r--r--libc/sysdeps/unix/sysv/linux/bits/socket.h20
-rw-r--r--libc/sysdeps/unix/sysv/linux/clock_getres.c6
-rw-r--r--libc/sysdeps/unix/sysv/linux/configure2
-rw-r--r--libc/sysdeps/unix/sysv/linux/configure.in2
-rw-r--r--libc/sysdeps/unix/sysv/linux/dl-osinfo.h1
-rw-r--r--libc/sysdeps/unix/sysv/linux/dl-sysdep.h4
-rw-r--r--libc/sysdeps/unix/sysv/linux/eventfd.c12
-rw-r--r--libc/sysdeps/unix/sysv/linux/i386/bits/mman.h1
-rw-r--r--libc/sysdeps/unix/sysv/linux/i386/paccept.S135
-rw-r--r--libc/sysdeps/unix/sysv/linux/i386/vfork.S3
-rw-r--r--libc/sysdeps/unix/sysv/linux/ifaddrs.c22
-rw-r--r--libc/sysdeps/unix/sysv/linux/kernel-features.h21
-rw-r--r--libc/sysdeps/unix/sysv/linux/net/ethernet.h10
-rw-r--r--libc/sysdeps/unix/sysv/linux/opensock.c41
-rw-r--r--libc/sysdeps/unix/sysv/linux/paccept.c54
-rw-r--r--libc/sysdeps/unix/sysv/linux/powerpc/bits/mman.h3
-rw-r--r--libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/fe_nomask.c5
-rw-r--r--libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_nomask.c5
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/bits/utmp.h125
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/bits/utmpx.h104
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/Makefile5
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/Versions23
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutent.c29
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutent_r.c35
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutid.c29
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutid_r.c32
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutline.c29
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutline_r.c31
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutmp.c38
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxent.c31
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxid.c31
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxline.c31
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/login.c36
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/login32.c37
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/pututxline.c31
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/updwtmp.c29
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/updwtmpx.c31
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp-compat.h22
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp-convert.h17
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c185
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.h53
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx-convert.h86
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c140
-rw-r--r--libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h52
-rw-r--r--libc/sysdeps/unix/sysv/linux/signalfd.c12
-rw-r--r--libc/sysdeps/unix/sysv/linux/socketcall.h6
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/bits/resource.h10
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/bits/socket.h393
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc32/Makefile4
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc32/getcontext.S85
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc32/makecontext.c93
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc32/setcontext.S119
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc32/sigcontextinfo.h3
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc32/swapcontext.S119
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc32/syscall.S1
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h16
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc32/ucontext_i.sym61
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S6
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc64/semctl.c2
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S1
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h15
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sys/epoll.h143
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sys/eventfd.h52
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sys/inotify.h105
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sys/signalfd.h66
-rw-r--r--libc/sysdeps/unix/sysv/linux/sparc/sys/timerfd.h60
-rw-r--r--libc/sysdeps/unix/sysv/linux/sys/epoll.h22
-rw-r--r--libc/sysdeps/unix/sysv/linux/sys/eventfd.h11
-rw-r--r--libc/sysdeps/unix/sysv/linux/sys/inotify.h15
-rw-r--r--libc/sysdeps/unix/sysv/linux/sys/signalfd.h8
-rw-r--r--libc/sysdeps/unix/sysv/linux/sys/timerfd.h10
-rw-r--r--libc/sysdeps/unix/sysv/linux/sys/user.h2
-rw-r--r--libc/sysdeps/unix/sysv/linux/syscalls.list3
-rw-r--r--libc/sysdeps/unix/sysv/linux/times.c59
-rw-r--r--libc/sysdeps/unix/sysv/linux/x86_64/bits/mman.h1
-rw-r--r--libc/sysdeps/unix/sysv/linux/x86_64/makecontext.c26
-rw-r--r--libc/sysdeps/unix/sysv/linux/x86_64/sys/epoll.h14
-rw-r--r--libc/sysdeps/unix/sysv/linux/x86_64/vfork.S3
-rw-r--r--libc/sysdeps/unix/sysv/syscalls.list2
-rw-r--r--libc/sysdeps/x86_64/Makefile10
-rw-r--r--libc/sysdeps/x86_64/bits/byteswap.h4
-rw-r--r--libc/sysdeps/x86_64/bits/linkmap.h2
-rw-r--r--libc/sysdeps/x86_64/dl-lookupcfg.h28
-rw-r--r--libc/sysdeps/x86_64/dl-machine.h53
-rw-r--r--libc/sysdeps/x86_64/dl-tls.h4
-rw-r--r--libc/sysdeps/x86_64/dl-tlsdesc.S245
-rw-r--r--libc/sysdeps/x86_64/dl-tlsdesc.h64
-rw-r--r--libc/sysdeps/x86_64/fpu/s_expm1l.S7
-rw-r--r--libc/sysdeps/x86_64/memset.S868
-rw-r--r--libc/sysdeps/x86_64/tlsdesc.c151
-rw-r--r--libc/sysdeps/x86_64/tlsdesc.sym17
-rw-r--r--libc/time/alt_digit.c16
-rw-r--r--libc/time/era.c8
-rw-r--r--libc/time/mktime.c6
-rw-r--r--libc/time/strftime_l.c43
-rw-r--r--libc/time/strptime_l.c14
-rw-r--r--libc/timezone/Makefile60
-rw-r--r--libc/timezone/asia104
-rw-r--r--libc/timezone/backward5
-rw-r--r--libc/timezone/europe3
-rw-r--r--libc/timezone/iso3166.tab6
-rw-r--r--libc/timezone/leapseconds19
-rw-r--r--libc/timezone/northamerica75
-rw-r--r--libc/timezone/private.h96
-rw-r--r--libc/timezone/southamerica178
-rw-r--r--libc/timezone/zdump.c35
-rw-r--r--libc/timezone/zic.c149
-rw-r--r--libc/timezone/zone.tab14
-rw-r--r--libc/version.h2
-rw-r--r--libc/wcsmbs/wcsmbsload.c8
-rw-r--r--ports/ChangeLog.arm78
-rw-r--r--ports/ChangeLog.eglibc107
-rw-r--r--ports/ChangeLog.hppa41
-rw-r--r--ports/ChangeLog.m68k26
-rw-r--r--ports/ChangeLog.mips52
-rw-r--r--ports/ChangeLog.powerpc8
-rw-r--r--ports/data/c++-types-arm-linux-gnueabi.data67
-rw-r--r--ports/data/c++-types-powerpce500v1-linux-gnu.data67
-rw-r--r--ports/data/c++-types-powerpce500v2-linux-gnu.data67
-rw-r--r--ports/data/c++-types-powerpcsoft-linux-gnu.data67
-rw-r--r--ports/data/localplt-arm-linux-gnueabi.data13
-rw-r--r--ports/data/localplt-powerpce500v1-linux-gnu.data31
-rw-r--r--ports/data/localplt-powerpce500v2-linux-gnu.data13
-rw-r--r--ports/data/localplt-powerpcsoft-linux-gnu.data41
-rw-r--r--ports/sysdeps/arm/bsd-_setjmp.S4
-rw-r--r--ports/sysdeps/arm/bsd-setjmp.S4
-rw-r--r--ports/sysdeps/arm/eabi/Versions3
-rw-r--r--ports/sysdeps/arm/eabi/aeabi_localeconv.c4
-rw-r--r--ports/sysdeps/arm/eabi/feupdateenv.c59
-rw-r--r--ports/sysdeps/arm/eabi/fgetexcptflg.c54
-rw-r--r--ports/sysdeps/arm/eabi/find_exidx.c4
-rw-r--r--ports/sysdeps/arm/eabi/fsetexcptflg.c6
-rw-r--r--ports/sysdeps/arm/eabi/machine-gmon.h1
-rw-r--r--ports/sysdeps/arm/eabi/setjmp.S3
-rw-r--r--ports/sysdeps/arm/libm-test-ulps374
-rw-r--r--ports/sysdeps/arm/memmove.S6
-rw-r--r--ports/sysdeps/arm/nptl/pthread_spin_lock.c4
-rw-r--r--ports/sysdeps/arm/nptl/pthread_spin_trylock.c4
-rw-r--r--ports/sysdeps/arm/setjmp.S4
-rw-r--r--ports/sysdeps/hppa/fpu/fesetenv.c4
-rw-r--r--ports/sysdeps/m68k/bits/byteswap.h52
-rw-r--r--ports/sysdeps/m68k/bits/setjmp.h4
-rw-r--r--ports/sysdeps/m68k/m680x0/fpu/bits/mathinline.h22
-rw-r--r--ports/sysdeps/mips/bits/setjmp.h2
-rw-r--r--ports/sysdeps/mips/fpu_control.h7
-rw-r--r--ports/sysdeps/powerpc/nofpu/feholdexcpt.c4
-rw-r--r--ports/sysdeps/powerpc/nofpu/shlib-versions1
-rw-r--r--ports/sysdeps/powerpc/powerpc32/e500/fpu/spe.h12
-rw-r--r--ports/sysdeps/powerpc/powerpc32/e500/fpu/strtofix.c6
-rw-r--r--ports/sysdeps/powerpc/powerpc32/e500/soft-fp/fraiseexcept-soft.c7
-rw-r--r--ports/sysdeps/powerpc/powerpc32/e500/soft-fp/sfp-machine.h4
-rw-r--r--ports/sysdeps/unix/sysv/linux/arm/bits/shm.h104
-rw-r--r--ports/sysdeps/unix/sysv/linux/arm/check_pf.c126
-rw-r--r--ports/sysdeps/unix/sysv/linux/arm/clone.S4
-rw-r--r--ports/sysdeps/unix/sysv/linux/arm/eabi/configure2
-rw-r--r--ports/sysdeps/unix/sysv/linux/arm/eabi/configure.in2
-rw-r--r--ports/sysdeps/unix/sysv/linux/arm/ioperm.c15
-rw-r--r--ports/sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h3
-rw-r--r--ports/sysdeps/unix/sysv/linux/hppa/Makefile5
-rw-r--r--ports/sysdeps/unix/sysv/linux/hppa/bits/atomic.h41
-rw-r--r--ports/sysdeps/unix/sysv/linux/hppa/bits/shm.h2
-rw-r--r--ports/sysdeps/unix/sysv/linux/hppa/getcontext.S163
-rw-r--r--ports/sysdeps/unix/sysv/linux/hppa/makecontext.c79
-rw-r--r--ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h12
-rw-r--r--ports/sysdeps/unix/sysv/linux/hppa/setcontext.S154
-rw-r--r--ports/sysdeps/unix/sysv/linux/hppa/swapcontext.c43
-rw-r--r--ports/sysdeps/unix/sysv/linux/hppa/ucontext_i.sym59
-rw-r--r--ports/sysdeps/unix/sysv/linux/m68k/bits/fcntl.h53
-rw-r--r--ports/sysdeps/unix/sysv/linux/m68k/bits/mman.h3
-rw-r--r--ports/sysdeps/unix/sysv/linux/m68k/bits/poll.h9
-rw-r--r--ports/sysdeps/unix/sysv/linux/m68k/bits/stat.h8
-rw-r--r--ports/sysdeps/unix/sysv/linux/m68k/kernel-features.h41
-rw-r--r--ports/sysdeps/unix/sysv/linux/m68k/sys/user.h61
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/bits/resource.h10
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/bits/shm.h2
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/bits/socket.h88
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c29
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list2
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c31
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/sys/epoll.h144
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/sys/eventfd.h52
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/sys/inotify.h105
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/sys/signalfd.h66
-rw-r--r--ports/sysdeps/unix/sysv/linux/mips/sys/timerfd.h60
-rw-r--r--ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/shlib-versions1
-rw-r--r--ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/single/shlib-versions1
513 files changed, 31981 insertions, 9634 deletions
diff --git a/libc/ChangeLog b/libc/ChangeLog
index 2cf9f3c5c..203349fde 100644
--- a/libc/ChangeLog
+++ b/libc/ChangeLog
@@ -1,3 +1,1465 @@
+2008-07-18 Daniel Jacobowitz <dan@codesourcery.com>
+
+ * Makefile (check-data): Check data directory in add-ons.
+ * elf/Makefile (check-data): Likewise.
+
+2008-08-18 Roland McGrath <roland@redhat.com>
+
+ * configure.in (--with-cpu): Check compiler support for -march/-mcpu.
+ * configure: Regenerated.
+ * config.make.in (cflags-cpu): New substituted variable.
+ (with-cpu): Variable removed.
+ * Makeconfig (+cflags): Use $(cflags-cpu), not $(with-cpu).
+
+2008-08-14 Ryan S. Arnold <rsa@us.ibm.com>
+
+ [BZ #6845]
+ * sysdeps/powerpc/fpu/bits/mathinline.h (__signbitl): Copy new
+ __signbitl definition and __LONG_DOUBLE_128__ guard from:
+ * sysdeps/unix/sysv/linux/powerpc/bits/mathinline.h: Remove as
+ redundant. Functions which call floating point assembler operations
+ should go into a sysdeps powerpc/fpu directory.
+
+2008-08-15 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/unix/sysv/linux/x86_64/bits/mman.h: Define MAP_STACK.
+ * sysdeps/unix/sysv/linux/i386/bits/mman.h: Likewise.
+
+2008-08-14 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/x86_64/memset.S: Reduce size of tables for PIC.
+
+ * sysdeps/unix/sysv/linux/dl-origin.c (_dl_get_origin): Undo all
+ change related to AT_EXECFN. We cannot use that string.
+ * sysdeps/generic/ldsodefs.h (struct rtld_global_ro): Remove
+ _dl_execfn member.
+ * elf/dl-support.c: Remove _dl_execfn variable.
+ (_dl_aux_init): Remove handling of AT_EXECFN.
+ * elf/dl-sysdep.c (_dl_sysdep_start): Remove handling of AT_EXECFN.
+ * elf/rtld.c (process_envvars): Remove use of __ASSUME_AT_EXECFN.
+
+2008-08-13 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6544]
+ * libio/fmemopen.c: Implement binary mode. In this mode no NUL
+ byte gets added to writes and seeks from the end use the length of
+ the buffer and not the currently terminating NUL byte.
+
+ [BZ #6634]
+ * login/utmp_file.c (getutent_r_file): Take additional parameter.
+ Set to true if locking failed.
+ (getutid_r_file): Adjust caller.
+ (pututline_file): Likewise. Return NULL in this case.
+ Patch mostly by halesh.s@gmail.com.
+
+2008-08-12 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6589]
+ * sysdeps/unix/sysv/linux/ifaddrs.c (struct sockaddr_ll_max):
+ Define.
+ (struct ifaddrs_storage): Use it instead of sockaddr_ll.
+
+2008-08-12 Ryan S. Arnold <rsa@us.ibm.com>
+
+ [BZ #6839]
+ * sysdeps/powerpc/powerpc32/dl-machine.c (CHECK_STATIC_TLS): Remove
+ macro since it is now available in elf/dynamic-link.h.
+
+2008-08-12 Roland McGrath <roland@frob.com>
+
+ * hurd/hurd/signal.h (HURD_MSGPORT_RPC): Avoid -Wparenthesis triggers,
+ in case used outside of libc.
+ Reported by Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+2008-08-11 Ulrich Drepper <drepper@redhat.com>
+
+ * resolv/res_mkquery.c (res_nmkquery): Call ns_name_compress
+ directly instead of going through dn_comp.
+
+2008-08-11 Aurelien Jarno <aurel32@debian.org>
+
+ * sysdeps/mach/i386/machine-lock.h (__spin_unlock, __spin_try_lock):
+ Fix asm constraints.
+
+2008-08-07 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6790]
+ * sysdeps/unix/sysv/linux/bits/in.h (IP_PMTUDISC_PROBE): Define.
+ (IPV6_PMTUDISC_PROBE): Likewise.
+
+2008-08-07 Pete Eberlein <eberlein@us.ibm.com>
+
+ [BZ #6791]
+ * sysdeps/unix/sysv/linux/powerpc/bits/mman.h (PROT_SAO): Define.
+
+2008-08-01 Steven Munroe <sjmunroe@us.ibm.com>
+ Carlos Eduardo Seo <cseo@linux.vnet.ibm.com>
+
+ [BZ #6817]
+ * sysdeps/powerpc/dl-procinfo.c (_dl_powerpc_cap_flags):
+ Added the members 'vsx' and 'arch_2_06'.
+ (_dl_powerpc_platforms): Add the member 'power7'.
+ * sysdeps/powerpc/dl-procinfo.h: Modify _DL_HWCAP_FIRST
+ to reflect the changes required by VSX and ISA 2.06.
+ Modify _DL_PLATFORMS_COUNT to reflect the addition of
+ 'power7'.
+ Defined PPC_PLATFORM_POWER7.
+ (_dl_string_platform): Add support for POWER7.
+ * sysdeps/powerpc/sysdep.h: Define bit masks for VSX
+ capability and ISA 2.06.
+
+2008-08-07 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6824]
+ * sysdeps/unix/sysv/linux/powerpc/bits/mathinline.h: Use correct
+ macro to detect use of 128 bit long double.
+ Patch by Ryan S. Arnold <rsa@us.ibm.com>.
+
+2008-08-05 Ulrich Drepper <drepper@redhat.com>
+
+ * scripts/gen-as-const.awk: Use 32-bit values on 32-bit platforms.
+
+ [BZ #5794]
+ * sysdeps/i386/fpu/s_expm1l.S: Simply use exp implementation for large
+ parameters.
+ * sysdeps/x86_64/fpu/s_expm1l.S: Likewise.
+ Patch by Denys Vlasenko <dvlasenk@redhat.com>.
+
+2008-08-03 Ulrich Drepper <drepper@redhat.com>
+
+ * nscd/connections.c (main_loop_poll): Pass a buffer which is
+ guaranteed to be large enough to read inotify event. Ignore
+ EAGAIN error. Better error message. Add branch predicition.
+ (main_loop_epoll): Likewise.
+
+2008-08-02 Roland McGrath <roland@frob.com>
+
+ * sysdeps/mach/i386/machine-lock.h (__spin_unlock, __spin_try_lock):
+ Add memory clobbers.
+
+2008-08-02 Ulrich Drepper <drepper@redhat.com>
+
+ * manual/arith.texi: Avoid @strong{Note:}.
+ * manual/creature.texi: Likewise.
+ * manual/filesys.texi: Likewise.
+ * manual/math.texi: Likewise.
+ * manual/memory.texi: Likewise.
+ * manual/resource.texi: Likewise.
+ * manual/syslog.texi: Likewise.
+ * manual/time.texi: Likewise.
+
+ * sysdeps/posix/clock_getres.c (hp_timing_getres): Remove inline
+ to prevent warning.
+
+2008-08-01 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/unix/sysv/linux/Versions: Fix changes due to old patch for
+ new epoll_create1 interface.
+ * sysdeps/unix/sysv/linux/syscalls.list: Likewise.
+ * sysdeps/unix/sysv/linux/sys/epoll.h: Likewise.
+ * sysdeps/unix/sysv/linux/x86_64/sys/epoll.h: Likewise.
+
+ * include/arpa/nameser.h (NS_GET16): Use const pointer.
+ (NS_GET32): Likewise.
+
+ * sysdeps/unix/sysv/linux/kernel-features.h: s390 has the new
+ syscalls, too.
+
+ * sysdeps/unix/sysv/linux/dl-origin.c (_dl_get_origin): We cannot
+ use the AT_EXECFN value if it is no absolute path.
+ * sysdeps/unix/sysv/linux/kernel-features.h: Never define
+ __ASSUME_AT_EXECFN.
+
+ * Versions.def: Add GLIBC_2.9 to libresolv.
+ * include/resolv.h: Remove hidden proto declarations for __ns_*
+ functions. Add them for __dn_count_labels and __p_secstodate.
+ * include/arpa/nameser.h: Add a number of hidden proto declarations.
+ Define ns_msg_getflags macro here.
+ * resolv/res_debug.c: Add hidden definition for __dn_count_labels
+ and __p_secstodate.
+ * resolv/Versions: Export functions from <arpa/nameser.h> from
+ libresolv in version GLIBC_2.9.
+ * resolv/ns_name.c: Integrate changes from bind 9.5.0. Add necessary
+ hidden definitions.
+ * resolv/ns_netint.c: Likewise.
+ * resolv/ns_parse.c: Likewise.
+ * resolv/ns_print.c: Likewise.
+ * resolv/ns_samedomain.c: Likewise.
+ * resolv/ns_ttl.c: Likewise.
+ * resolv/arpa/nameser_compat.h: Likewise.
+ * resolv/arpa/nameser.h: Likewise. Remove macros which redirect
+ function calls.
+ * resolv/nss_dns/dns-canon.c (_nss_dns_getcanonname_r): Use __ns_get16
+ instead of ns_get16.
+ * resolv/nss_dns/dns-host.c (getanswer_r): Use __ns_get16 and
+ __ns_get32 instead of ns_get16 and ns_get32 respectively.
+ (gaih_getanswer_slice): Likewise.
+ * resolv/Makefile (libresolv-routines): Add ns_date.
+ * resolv/ns_date.c: New file.
+
+ * elf/Makefile (check-localplt.out): Also check libresolv and
+ libcrypt.
+
+2008-07-31 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/unix/sysv/linux/kernel-features.h: Define
+ __ASSUME_O_CLOEXEC.
+
+2008-07-30 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/posix/getaddrinfo.c (gaih_inet): Raise size of initial
+ buffer passed to NSS functions.
+
+ * nscd/connections.c (nscd_init): Typo in preprocessor directive.
+
+ * sysdeps/unix/sysv/linux/kernel-features.h (__ASSUME_PACCEPT):
+ Define.
+
+ * misc/syslog.c (openlog_internal): Fix compile problem.
+
+2008-07-28 Roland McGrath <roland@redhat.com>
+
+ * elf/dl-sysdep.c (_dl_show_auxv): Add AT_EXECFN to the table.
+
+2008-07-28 Ulrich Drepper <drepper@redhat.com>
+
+ * io/ftw.c (add_object): Remove inline to avoid warning.
+
+ * sysdeps/unix/sysv/linux/paccept.c: Fix compile problem.
+
+ * resolv/res_send.c (__libc_res_nsend): Take additional parameter.
+ Use it instead of locally defined resplen2 variable.
+ (res_nsend): Adjust for __libc_res_nsend interface change.
+ (send_vc): Initialize *resplen2 if necessary. Read length of
+ package into an appropriately aligned variable. Store converted length
+ in new variable and use it appropriately.
+ Add branch prediction help.
+ * resolv/res_query.c (__libc_res_nquery): Take additional parameter
+ and pass it on to __libc_res_nsend. Adjust all callers.
+ (__libc_res_nsearch): Likewise.
+ (__libc_res_nqeurydomain): Likewise.
+ * resolv/nss_dns/dns-host.c: Adjust for __libc_res_nsearch interface
+ change.
+ (_nss_dns_gethostbyname4): Don't unconditionally allocate tmp array.
+ Define resplen2 variable and pass it to __libc_res_nsearch and then
+ to gaih_getanswer.
+ (getanswer_r): In case of incorrect DNS data don't overread buffer.
+ Add branch prediction.
+ (gaih_getanswer_slice): Likewise. Check for invalid data types.
+ (gaih_getanswer): Don't decode second slice if first one failed due
+ to a too small buffer. Don't let not found status of second
+ decoder shadow results of the first.
+ * resolv/gethnamaddr.c (gethostbyname2): Adjust for __libc_res_nsearch
+ and __libc_res_nquery interface changes
+ (gethostbyaddr): Adjust for __libc_res_nquery interface change.
+ * include/resolv.h: Adjust prototypes for __libc_res_nquery,
+ __libc_res_nsearch, and __libc_res_nsend.
+ * resolv/nss_dns/dns-canon.c: Adjust for __libc_res_nquery interface
+ change.
+ * resolv/nss_dns/dns-network.c: Adjust for __libc_res_nquery and
+ __libc_res_nsearch interface changes.
+
+2008-07-27 Ulrich Drepper <drepper@redhat.com>
+
+ * libio/iopopen.c (_IO_new_proc_open): Remove unnecessary volatile.
+
+ * posix/wordexp.c (exec_comm): Use pipe2 if possible to create
+ file descriptors with close-on-exec set.
+ (exec_comm_child): Fix the case where the write end of the pipe is
+ STDOUT_FILENO already. In case it is, clear close-on-exec.
+
+ * sysdeps/unix/sysv/linux/syscalls.list: Add __pipe2 alias.
+ * io/pipe2.c: Likewise.
+ * sysdeps/unix/sysv/linux/kernel-features.h: Define __ASSUME_PIPE2
+ instead of __ASSUME_PACCEPT.
+ * include/unistd.h: Declare __have_pipe2.
+ * libio/iopopen.c: Implement "e" flag.
+ * libio/Makefile (tests): Add tst-popen1.
+ * libio/tst-popen1.c: New file.
+
+ * sysdeps/unix/sysv/linux/bits/socket.h: Define PF_ISDN and AF_ISDN.
+ * sysdeps/unix/sysv/linux/sparc/bits/socket.h: Likewise.
+
+2008-07-26 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6771]
+ * libio/fileops.c (_IO_new_file_attach): Preserve errno around
+ success call of _IO_SEEKOFF or calls which failed because the
+ descriptor is for a pipe.
+
+ * sunrpc/key_call.c (getkeyserv_handle): Use FD_CLOEXEC instead of
+ magic number.
+
+ * misc/syslog.c (openlog_internal): Use SOCK_CLOEXEC if possible.
+
+ * malloc/mtrace.c (mtrace): Use 'e' flag in fopen call. Drop
+ F_SETFD use if we know fopen set the flag.
+
+ * login/utmp_file.c (setutent_file): Minor optimization in case
+ O_CLOEXEC is available.
+
+2008-07-24 Tom "spot" Callaway <tcallawa@redhat.com>
+
+ * Makeconfig: Define pie-ccflag and PIE-ccflag variables.
+ * elf/Makefile: Use pie-ccflag variable.
+ * nscd/Makefile: Likewise.
+ * sysdeps/sparc/Makefile: Set $(pie-ccflag) to -fPIE.
+
+2008-07-21 Andreas Krebbel <krebbel1@de.ibm.com>
+
+ [BZ #6724]
+ * Versions.def: Add GLIBC_2.9 version tag for libutil.
+ * sysdeps/unix/sysv/linux/s390/bits/utmp.h: Copy of
+ gnu/bits/utmp.h. Check for __WORDSIZE_COMPAT32 removed.
+ * sysdeps/unix/sysv/linux/s390/bits/utmpx.h: Copy of
+ gnu/bits/utmpx.h. Check for __WORDSIZE_COMPAT32 removed.
+ * sysdeps/unix/sysv/linux/s390/s390-32/Makefile: Add new files
+ utmp32, utmpx32 and login32.
+ * sysdeps/unix/sysv/linux/s390/s390-32/Versions: Add 2.9
+ versions of struct utmp functions to libc and libutil.
+ * sysdeps/unix/sysv/linux/s390/s390-32/utmp-compat.h: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutent.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutent_r.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutid.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutid_r.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutline.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutline_r.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutmp.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutxent.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutxid.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/getutxline.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/login.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/login32.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/pututxline.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/updwtmp.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/updwtmpx.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/utmp-convert.h: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/utmp32.h: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/utmpx-convert.h: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c: New file.
+ * sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h: New file.
+
+2008-07-26 Ulrich Drepper <drepper@redhat.com>
+
+ * scripts/gen-as-const.awk: Generate more widely usable code by
+ using 64-bit arithmetic.
+
+ * stdio-common/printf_fp.c (___printf_fp): Give wide outout code
+ the same treatment as narrow output code in last patch.
+
+ * sunrpc/clnt_udp.c (__libc_clntudp_bufcreate): Namespace cleanup.
+
+ [BZ #6763]
+ * elf/dl-load.c (local_strdup): Remove inline.
+ (_dl_map_object_from_fd): Don't allocate l_symbolic_searchlist.r_list.
+ * elf/dl-object.c (_dl_new_object): Allocate symbolic searchlist as
+ part of the object.
+
+ * sysdeps/unix/sysv/linux/dl-origin.c: Add const to avoid warning.
+
+2008-07-25 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/unix/sysv/linux/kernel-features.h: IA-64 and SPARC have
+ the new syscalls, too.
+
+ * sysdeps/i386/i686/memcmp.S: Fix unwind information.
+ Reported by Paul Pluzhnikov <ppluzhnikov@google.com>.
+
+ [BZ #6698]
+ * stdio-common/_i18n_number.h (_i18n_number_rewrite): Take additional
+ parameter for end of buffer. If temporary copy is too large use
+ malloc.
+ * stdio-common/vfprintf.c: Adjust for _i18n_number_rewrite
+ interface change.
+ * stdio-common/printf_fp.c (__printf_fp): Likewise.. Account for
+ string rewrite when allocating buffer.
+
+ * sysdeps/unix/sysv/linux/kernel-features.h: PPC has the new
+ syscalls, too.
+
+ * nscd/connections.c (nscd_init): Clean up fcntl call.
+
+ * nscd/nscd_helper.c (open_socket): Use SOCK_CLOEXEC and
+ SOCK_NONBLOCK if possible.
+
+ * sysdeps/unix/sysv/linux/opensock.c (__opensock): Use
+ SOCK_CLOEXEC if available.
+
+ * include/rpc/clnt.h: Declare __libc_clntudp_bufcreate and
+ __libc_clntudp_bufcreate_internal.
+ * include/sys/socket.h: Declare __have_sock_cloexec.
+ * socket/Makefile (aux): Add have_sock_cloexec.
+ * socket/have_sock_cloexec.c: New file.
+ * sunrpc/clnt_udp.h (clntudp_bufcreate): Now a wrapper around
+ __libc_clntudp_bufcreate.
+ (__libc_clntudp_bufcreate): Former implementation of clntudp_bufcreate
+ which takes an additional parameter. Create socket with non-blocking
+ mode and close-on-exec flag set, if wanted.
+ * sunrpc/Versions: Export __libc_clntudp_bufcreate@GLIBC_PRIVATE.
+ * nis/ypclnt.c (yp_bind_client_create): Use __libc_clntpudp_bufcreate
+ instead of clntudp_create. The socket has already the close-on-exec
+ flag set if SOCK_CLOEXEC is defined.
+
+2008-07-24 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/unix/sysv/linux/kernel-features.h: Define
+ __ASSUME_PACCEPT, __ASSUME_IN_NONBLOCK, and __ASSUME_PACCEPT if
+ appropriate.
+ * nscd/connections.c: Avoid fcntl calls to set close-on-exec flag and
+ non-blocking mode by using socket, paccept, and inotify_init1.
+
+ * Versions.def (glibc): Add GLIBC_2.9.
+ * io/Makefile (routines): Add dup3 and pipe2.
+ * io/Versions [glibc] (GLIBC_2.9): Add dup3 and pipe2.
+ * io/dup3.c: New file.
+ * io/pipe2.c: New file.
+ * posix/unistd.h: Declare dup3 and pipe2.
+ * socket/Makefile (routines): Add paccept.
+ * socket/Versions [glibc] (GLIBC_2.9): Add paccept.
+ * socket/paccept.c: New file.
+ * socket/sys/socket.h: Declare paccept.
+ * sysdeps/unix/syscalls.list: Add entry for dup3.
+ * sysdeps/unix/sysv/linux/Versions [glibc] (GLIBC_2.9): Add
+ epoll_create2 and inotify_init1.
+ * sysdeps/unix/sysv/linux/eventfd.c: Use eventfd1 syscall if possible.
+ * sysdeps/unix/sysv/linux/paccept.c: New file.
+ * sysdeps/unix/sysv/linux/signalfd.c: Use signalfd4 syscall if
+ possible.
+ * sysdeps/unix/sysv/linux/socketcall.h: Add SOCKOP_paccept.
+ * sysdeps/unix/sysv/linux/syscalls.list: Add epoll_create2,
+ inotify_init1, and pipe2 entries.
+ * sysdeps/unix/sysv/linux/alpha/sys/epoll.h: New file.
+ * sysdeps/unix/sysv/linux/alpha/sys/eventfd.h: New file.
+ * sysdeps/unix/sysv/linux/alpha/sys/inotify.h: New file.
+ * sysdeps/unix/sysv/linux/alpha/sys/signalfd.h: New file.
+ * sysdeps/unix/sysv/linux/alpha/sys/timerfd.h: New file.
+ * sysdeps/unix/sysv/linux/bits/socket.h: Define SOCK_CLOEXEC and
+ SOCK_NONBLOCK.
+ * sysdeps/unix/sysv/linux/i386/paccept.S: New file.
+ * sysdeps/unix/sysv/linux/sparc/sys/epoll.h: New file.
+ * sysdeps/unix/sysv/linux/sparc/sys/eventfd.h: New file.
+ * sysdeps/unix/sysv/linux/sparc/sys/inotify.h: New file.
+ * sysdeps/unix/sysv/linux/sparc/sys/signalfd.h: New file.
+ * sysdeps/unix/sysv/linux/sparc/sys/timerfd.h: New file.
+ * sysdeps/unix/sysv/linux/sparc/bits/socket.h: New file.
+ * sysdeps/unix/sysv/linux/sys/epoll.h: Define EPOLL_CLOEXEC and
+ EPOLL_NONBLOCK. Declare epoll_create2.
+ * sysdeps/unix/sysv/linux/sys/eventfd.h: Define EFD_CLOEXEC and
+ EFD_NONBLOCK.
+ * sysdeps/unix/sysv/linux/sys/inotify.h: Define IN_CLOEXEC and
+ IN_NONBLOCK. Declare inotify_init1.
+ * sysdeps/unix/sysv/linux/sys/signalfd.h: Define SFD_CLOEXEC and
+ SFD_NONBLOCK.
+ * sysdeps/unix/sysv/linux/sys/timerfd.h: Define TFD_CLOEXEC and
+ TFD_NONBLOCK.
+
+ * elf/elf.h: Define AT_EXECFN.
+ * elf/rtld.c [!__ASSUME_AT_EXECFN] (process_envvars): Don't handle
+ LD_ORIGIN_PATH.
+ * elf/dl-sysdep.c (_dl_sysdep_start): Handle AT_EXECFN.
+ * elf/dl-support.c: Define _dl_execfn. Don't define _dl_origin_path
+ if __ASSUME_AT_EXECFN is defined.
+ (_dl_aux_init): Handle AT_EXECFN.
+ * sysdeps/unix/sysv/linux/kernel-features.h: Define __ASSUME_AT_EXECFN
+ for 2.6.27 and up.
+ * sysdeps/generic/ldsodefs.h (rtld_global_ro): Add _dl_execfn.
+ Don't define _dl_origin_path if __ASSUME_AT_EXECFN is defined.
+ * sysdeps/unix/sysv/linux/dl-origin.c (_dl_get_origin): Use
+ _dl_execfn if available and avoid compatibility code if
+ __ASSUME_AT_EXECFN is defined.
+
+ * sysdeps/unix/sysv/linux/dl-sysdep.h: Don't declare
+ _dl_discover_osversion only for older kernels.
+
+2008-07-22 Roland McGrath <roland@frob.com>
+
+ * hurd/fd-read.c (_hurd_fd_read): Fix last change.
+
+2008-07-21 Roland McGrath <roland@frob.com>
+
+ * hurd/fd-read.c (_hurd_fd_read): Return EGRATUITOUS if the server
+ returned too much data out of line.
+
+2008-07-20 Ulrich Drepper <drepper@redhat.com>
+
+ * locale/setlocale.c (setname): Remove inline to avoid compiler
+ warning.
+
+ [BZ #6712]
+ * locale/setlocale.c (setlocale): Take the setlocale lock earlier.
+
+2008-07-15 Ulrich Drepper <drepper@redhat.com>
+
+ * stdio-common/vfprintf.c (_IO_helper_overflow): In case _IO_sputn
+ doesn't manage to write anything, fail.
+
+ * malloc/hooks.c (__malloc_check_init): Remove printf.
+
+2008-07-14 Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+ * sysdeps/mach/hurd/bits/fcntl.h: Include <sys/types.h>.
+
+2008-07-12 Ulrich Drepper <drepper@redhat.com>
+
+ * nscd/connections.c (main_loop_poll): Fix handling of read errors
+ from inotify.
+ (main_loop_epoll): Likewise.
+
+2008-07-09 Ulrich Drepper <drepper@redhat.com>
+
+ * resolv/res_send.c: Remove unnecessary res_pquery prototype.
+
+ * resolv/res_query.c (__libc_res_nquery): Issue debug message only
+ if DEBUG is defined.
+
+ * resolv/res_query.c (__libc_res_nquery): Align buffer for T_AAAA
+ query. Adjust buffer size computation for padding.
+
+2008-07-08 Ulrich Drepper <drepper@redhat.com>
+
+ * stdio-common/Makefile: Add rules to build and run tst-setvbuf1.
+ * stdio-common/tst-setvbuf1.c: New file.
+ * stdio-common/tst-setvbuf1.expect: New file.
+
+ [BZ #6719]
+ * libio/iosetvbuf.c (_IO_setvbuf): Correctly clear buffering flags
+ when selecting fully-buffered stream.
+ Patch by Wang Xin <wxinee@gmail.com>.
+
+2008-07-06 Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+ * sysdeps/mach/hurd/open.c: Include <stdio.h>.
+ (__open_2): New function.
+ (__open64_2): New alias to __open_2.
+ * sysdeps/mach/hurd/openat.c: Include <stdio.h>.
+ (__openat_2): New function.
+ (__openat64_2): New alias to __openat_2.
+
+2008-07-06 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6723]
+ * time/mktime.c (__mktime_internal): Normalize tp->tm_isdst value.
+
+2008-07-01 Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+ * sysdeps/unix/bsd/bsd4.4/bits/socket.h: Define MSG_NOSIGNAL.
+ * hurd/hurd/fd.h (__hurd_sockfail): Add extern inline function.
+ * sysdeps/mach/hurd/recv.c (__recv): Use __hurd_sockfail instead of
+ __hurd_dfail.
+ * sysdeps/mach/hurd/recvfrom.c (__recvfrom): Likewise.
+ * sysdeps/mach/hurd/recvmsg.c (__recvmsg): Likewise.
+ * sysdeps/mach/hurd/send.c (__send): Likewise.
+ * sysdeps/mach/hurd/sendto.c (__sendfrom): Likewise.
+ * sysdeps/mach/hurd/sendmsg.c (__sendmsg): Likewise.
+
+2008-03-04 Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+ * sysdeps/mach/hurd/recv.c (__recv): Initialize NPORTS.
+ * sysdeps/mach/hurd/recvfrom.c (__recvfrom): Likewise.
+ * sysdeps/mach/hurd/recvmsg.c (__recvmsg): Likewise.
+ * hurd/fd-read.c (_hurd_fd_read): Initialize NREAD.
+ * hurd/get-host.c (_hurd_get_host_config): Likewise.
+ * sysdeps/mach/hurd/dl-sysdep.c (__libc_read): Likewise.
+
+2008-06-27 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6657]
+ * time/strptime_l.c: Don't clear s.era_cnt after successful match
+ of %EY.
+ Patch by Petr Baudis.
+
+2008-06-26 Ulrich Drepper <drepper@redhat.com>
+
+ * resolv/res_debug.c (__p_type_syms): Add ns_t_dname entry.
+ Patch by Peter Jones <pjones@redhat.com>.
+
+2008-06-25 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6654]
+ * stdlib/canonicalize.c (__realpath): readlink can write too much
+ into the buffer on platforms without PATH_MAX.
+
+2008-06-17 Carlos O'Donell <carlos@codesourcery.com>
+
+ [BZ #6653]
+ * posix/tst-regex.c (main): Rename to...
+ (do_test): ... this. Remove cmdline option processing.
+ (TIMEOUT): Define.
+ (TEST_FUNCTION): Define.
+ (CMDLINE_OPTIONS): Define.
+
+2008-06-25 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #5210]
+ * configure.in: Add -Werror to -fstack-protector test to catch
+ unsupported architectures.
+ Patch by Gilles Esponasse <g.esp@free.fr>.
+
+2008-06-17 Joseph Myers <joseph@codesourcery.com>
+
+ * stdlib/tst-setcontext.c: Set back_in_main before exit if
+ getcontext returns ENOSYS.
+
+2008-06-18 Ulrich Drepper <drepper@redhat.com>
+
+ * nscd/connections.c (main_loop_poll): Fix test for read error.
+ (main_loop_epoll): Likewise.
+
+2008-06-13 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/posix/getaddrinfo.c: Move _res_hconf_init call to a
+ better place so it is not called when nscd is used.
+
+ * nscd/connections.c: Also recognize and handle changes to the
+ resolver configuration file.
+
+2008-06-12 Ulrich Drepper <drepper@redhat.com>
+
+ * time/strftime.c: Pass reference to tzset_called around to handle
+ recursive calls.
+
+ [BZ #6612]
+ * time/strftime.c (__strftime_internal): Call tzset() only
+ when printing timezone-dependent values.
+ Based on a patch by Petr Baudis <pasky@suse.cz>.
+
+ * resolv/nss_dns/dns-host.c (gaih_getanswer): Don't
+ unconditionally use second gaih_getanswer_slice result.
+
+ * sysdeps/posix/getaddrinfo.c (gai_inet): Remove unnecessary test.
+ (getaddrinfo): RES must always be non-NULL.
+
+2008-06-12 Jakub Jelinek <jakub@redhat.com>
+
+ * sysdeps/powerpc/powerpc64/fpu/s_llround.S (__llround): Avoid using
+ cr[34] registers.
+ * sysdeps/powerpc/powerpc64/fpu/s_llroundf.S (__llroundf): Likewise.
+ * sysdeps/powerpc/powerpc32/power4/fpu/s_llround.S (__llround):
+ Likewise.
+ * sysdeps/powerpc/powerpc32/fpu/s_lround.S (__lround): Avoid using cr3
+ register.
+
+2008-06-12 Ulrich Drepper <drepper@redhat.com>
+
+ * nscd/nscd.h (struct database_dyn): Add inotify_descr and clear_cache
+ fields.
+ * nscd/connections.c (inotify_fd): New variable.
+ (nscd_init): Try to open an inotify descriptor.
+ If successful, watch files for databases using inotify instead of
+ having prune threads stat the files.
+ (nscd_run_prune): Recognize clear_cache flag being set and call
+ prune_cache appropriately.
+ (main_loop_poll): Add inotify descriptor to wait set and handle the
+ reported changes.
+ (main_loop_epoll): Likewise.
+ * nscd/cache.c (prune_cache): Don't stat files for databases if
+ inotify is used.
+ * sysdeps/unix/sysv/linux/Makefile [subdir=nscd]
+ (CFLAGS-connections.c): Add -DHAVE_INOTIFY.
+
+ * nscd/grpcache.c (cache_addgr): Correctly compute size of
+ fixed-size portion of the record.
+ * nscd/servicescache.c (cache_addserv): Likewise.
+ * nscd/pwdcache.c (cache_addpw): Likewise.
+ * nscd/initgrcache.c (addinitgroupsX): Likewise.
+
+2008-06-11 Ulrich Drepper <drepper@redhat.com>
+
+ * nscd/mem.c (gc): Initialize obstack earlier so that if we jump
+ out we don't use uninitialized memory.
+
+ * nscd/hstcache.c (cache_addhst): Send correct number of bytes to
+ the client.
+
+2008-06-10 Ulrich Drepper <drepper@redhat.com>
+
+ * resolv/nss_dns/dns-host.c (gaih_getanswer_slice): Also log and
+ ignore T_DNAME messages.
+ * resolv/arpa/nameser_compat.h (T_DNAME): Define.
+
+2008-06-05 Jakub Jelinek <jakub@redhat.com>
+
+ * misc/regexp.h (compile): Use __REPB_PREFIX macro.
+ Avoid segfault if first GETC returns eof/'\0'/'\n'.
+
+2008-06-03 Jakub Jelinek <jakub@redhat.com>
+
+ * nscd/nscd_getserv_r.c (__nscd_getservbyport_r): Pass cp
+ instead of portstr to nscd_getserv_r. Patch by
+ Roman Kagan <rkagan@mail.ru>.
+
+2008-05-26 Jim Meyering <meyering@redhat.com>
+
+ Remove more useless "if" tests before "free".
+ * include/inline-hashtab.h (htab_delete): Likewise.
+ * libio/freopen.c (freopen): Likewise.
+ * libio/freopen64.c (freopen64): Likewise.
+ * locale/programs/ld-collate.c (collate_read): Likewise.
+ * misc/fstab.c (libc_freeres_fn): Likewise.
+ * posix/glob.c (globfree): Likewise.
+
+2008-05-24 Ulrich Drepper <drepper@redhat.com>
+
+ * string/Makefile (strop-tests): Add memmem.
+ * string/test-memmem.c: New file.
+ * string/test-string.h (BUF1PAGES): Define to 1 if undefined.
+ (test_init): Size buf1 according to BUF1PAGES.
+
+2008-05-24 Jakub Jelinek <jakub@redhat.com>
+
+ * libio/stdio.h (vscanf): Fix -std=c99 redirect.
+ * stdio-common/Makefile (tests): Add scanf16 and scanf17.
+ (CFLAGS-scanf17.c): New.
+ * stdio-common/scanf14.c (main): Add fscanf and scanf tests.
+ * stdio-common/scanf15.c (main): Likewise.
+ * stdio-common/scanf16.c: New file.
+ * stdio-common/scanf17.c: New file.
+
+2008-05-24 Ulrich Drepper <drepper@redhat.com>
+
+ * resolv/res_send.c (send_dg): If we already have one of two
+ answers and the server reports SERVFAIL, NOTIMP, or REFUSED, then
+ use the one answer insted of failing.
+
+2008-02-20 Ryan S. Arnold <rsa@us.ibm.com>
+
+ * math/libm-test.inc (exp_test): Exclude expl(1000.0L) from
+ being executed on PowerPC as the expected result exceeds IBM
+ long double 128 __LDBL_MAX__.
+
+2008-05-21 Roland McGrath <roland@redhat.com>
+
+ * shlib-versions (sparc.*-.*-.*, sparc64.*-.*-.*): Add ABI lines.
+
+ * Makefile (check-data): Use $(abi-name) before other guesses.
+ Look in $(add-ons) dirs before scripts/data/.
+ * elf/Makefile (check-data): Likewise.
+
+ * scripts/soversions.awk: Grok ABI line.
+ * Makeconfig ($(common-objpfx)soversions.mk): Likewise.
+ Emit definition for abi-name variable.
+
+2008-05-21 Ulrich Drepper <drepper@redhat.com>
+
+ * string/endian.h: Define new fixed-size hto* and *toh macros only
+ if [__USE_BSD].
+
+ * iconvdata/Depend: Add localedata.
+
+2008-05-21 Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+ * bits/termios.h (ONLCR): Define under [__USE_XOPEN] too.
+
+2008-05-08 David S. Miller <davem@davemloft.net>
+
+ * sysdeps/unix/sysv/linux/sparc/sparc32/setcontext.S: Use
+ HIDDEN_JUMPTARGET.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h
+ (__SYSCALL_CLOBBERS): Remove %g* registers.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h
+ (__SYSCALL_CLOBBERS): Likewise.
+ * scripts/data/localplt-sparc-linux-gnu.data: New file.
+ * scripts/data/localplt-sparc64-linux-gnu.data: New file.
+
+2008-05-21 Jakub Jelinek <jakub@redhat.com>
+
+ * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h
+ (CALL_ERRNO_LOCATION): Define.
+ (__SYSCALL_STRING, __CLONE_SYSCALL_STRING): Use it.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h
+ (CALL_ERRNO_LOCATION): Define.
+ (__SYSCALL_STRING, __CLONE_SYSCALL_STRING): Use it.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/brk.S (__brk): Use
+ HIDDEN_JUMPTARGET for __errno_location call in libc.so.
+
+2008-05-20 Ulrich Drepper <drepper@redhat.com>
+
+ * include/inline-hashtab.h (higher_prime_number): Fix type of mid
+ variable.
+
+2008-05-20 Jakub Jelinek <jakub@redhat.com>
+
+ * sysdeps/unix/sysv/linux/sparc/sparc32/sigcontextinfo.h
+ (FIRST_FRAME_POINTER): Define.
+
+2008-05-09 David S. Miller <davem@davemloft.net>
+
+ * sysdeps/sparc/sparc64/backtrace.c: New file.
+
+2008-05-14 David S. Miller <davem@davemloft.net>
+
+ * sysdeps/sparc/machine-gmon.h: New file.
+ * sysdeps/sparc/sparc-mcount.S: Likewise.
+ * sysdeps/sparc/Makefile: Add sparc-mcount target to
+ sysdep_routines in gmon directory.
+
+2008-05-19 Jakub Jelinek <jakub@redhat.com>
+
+ * elf/soinit.c (__EH_FRAME_BEGIN__): Remove.
+
+2008-05-19 Ulrich Drepper <drepper@redhat.com>
+
+ * resolv/res_query.c (__libc_res_nquery): In case one of two
+ answer was too short don't try to read that answer's header.
+
+ * resolv/res_send.c (send_dg): In case of timeout and there are
+ two queries and one has been answered, return value indicating
+ success.
+
+2008-05-18 Ulrich Drepper <drepper@redhat.com>
+
+ * nscd/cache.c (cache_add): Take additional parameter specifying
+ whether this is in response of a cache refill. Check alignment
+ of package data. Revamp waking of pruning thread.
+ (prune_cache): Small optimization.
+ * nscd/nscd.h: Adjust cache_add prototypes.
+ * nscd/aicache.c: Adjust cache_add calls.
+ * nscd/grpcache.c: Likewise.
+ * nscd/hstcache.c: Likewise.
+ * nscd/initgrcache.c: Likewise.
+ * nscd/pwdcache.c: Likewise.
+ * nscd/servicescache.c: Likewise.
+ * nscd/connections.c (restart): Really disable cache use before
+ exec attempt. If it fails, reenable cache.
+ (nscd_run_prune): Initialize wakeup_time. After wakeup, set wakeup
+ time to max to be able to notice concurrent cache additions. Unlock
+ prune_lock while performing gc. Afterwards compute wakeup time with
+ current wakeup_time value in mind.
+
+2008-05-17 Ulrich Drepper <drepper@redhat.com>
+
+ * nscd/mem.c (gc): Avoid stack overflow when allocating move list.
+
+ * nscd/mem.c (gc): Correctly determine highest used array element
+ in mark.
+
+ * nscd/mem.c (markrange): Add assert to check entries are all
+ aligned. Small cleanup in bitmap use.
+
+ * nscd/nscd.h (mem_in_flight): Replace blockaddr field with
+ blockoff of type nscd_ssize_t.
+ * nscd/mem.c (gc): Simplify markrange call for on-flight blocks.
+ (mempoll_alloc): Record block offset and not address.
+
+ * nscd/mem.c (gc): Fix test for stack overuse.
+
+ * nscd/aicache.c (addhstaiX): Fix a few small problems, cleanups,
+ more asserts.
+
+ * sysdeps/posix/getaddrinfo.c (gaih_inet): If nscd reports no
+ entry is available, believe it.
+
+ * resolv/nss_dns/dns-host.c (gaih_getanswer_slice): If there are
+ no answers return NSS_STATUS_NOTFOUND.
+ (gaih_getanswer): Don't call gaih_getanswer_slice if the answer
+ buffer does not have any content.
+
+2008-05-16 Ulrich Drepper <drepper@redhat.com>
+
+ * string/strcasestr.c (CMP_FUNC): Use __strncasecmp, not strncasecmp.
+
+ * sysdeps/posix/getaddrinfo.c (gaih_inet): After gethostbyname4_r
+ lookup, don't assign canon unconditionally.
+
+2008-05-14 Ulrich Drepper <drepper@redhat.com>
+
+ * string/Makefile (distribute): Add str-two-way.h.
+
+2008-03-29 Eric Blake <ebb9@byu.net>
+
+ Rewrite string searches to O(n) rather than O(n^2).
+ * string/str-two-way.h: New file. For linear fixed-allocation
+ string searching.
+ * string/memmem.c: New implementation.
+ * string/strstr.c: New implementation.
+ * string/strcasestr.c: New implementation.
+
+2008-04-11 Paolo Bonzini <bonzini@gnu.org>
+
+ * posix/regcomp.c (optimize_utf8): Add a note on why we test
+ opr.ctx_type.
+ (calc_first): Initialize constraint field.
+ (duplicate_node_closure): Use it instead of special casing ANCHORS.
+ Use search_duplicated_node to avoid loops. Fix grammar.
+ (duplicate_node): Merge constraint field for all node types.
+ (calc_eclosure_iter): Look at constraint field for all node types.
+ * posix/regex_internal.c (create_cd_newstate): Don't look at
+ create_cd_newstate.
+
+2008-05-14 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6428]
+ * configure.in: Don't use $CFLAGS when assembling, use $ASFLAGS.
+
+ [BZ #6442]
+ * string/endian.h: Add macros for fixed-size endian conversion.
+ * bits/byteswap.h: Allow inclusion from <endian.h>.
+ * sysdeps/i386/bits/byteswap.h: Likewise.
+ * sysdeps/ia64/bits/byteswap.h: Likewise.
+ * sysdeps/s390/bits/byteswap.h: Likewise.
+ * sysdeps/x86_64/bits/byteswap.h: Likewise.
+ * string/Makefile (tests): Add tst-endian.
+ * string/tst-endian.c: New file.
+
+ * iconvdata/run-iconv-test.sh: Use = instead of == in test.
+ Patch by Reuben Thomas.
+
+2008-05-14 Joseph Myers <joseph@codesourcery.com>
+
+ * iconvdata/Makefile (bug-iconv6-ENV, tst-iconv7-ENV): Define.
+
+2008-05-14 Ulrich Drepper <drepper@redhat.com>
+
+ * iconvdata/bug-iconv6.c (do_test): Use de_DE.UTF-8 locale.
+
+ [BZ #6461]
+ * iconv/gconv_simple.c (BODY for __gconv_transform_ascii_internal):
+ Add missing braces.
+ (BODY for __gconv_transform_internal_ascii): Likewise.
+
+ [BZ #6472]
+ * sysdeps/posix/getaddrinfo.c (get_scope): Loopback addresses have
+ to be treated like link-local addresses.
+ (match_prefix): Don't treat IPv4 loopback address special when
+ converting to v4 mapped addressed.
+
+ * sysdeps/posix/getaddrinfo.c (getaddrinfo): Call _res_hconf_init
+ if necessary.
+ * posix/tst-rfc3484.c: Add dummy definition of _res_hconf_init.
+ * posix/tst-rfc3484-2.c: Likewise.
+ * posix/tst-rfc3484-3.c: Likewise.
+
+ * sysdeps/posix/getaddrinfo.c: Implement handling of DCCP, UDPlite,
+ and SCTP.
+
+ * nss/getent.c (ahosts_keys_int): Handle all known socket types.
+
+ * inet/netinet/in.h (IPPIPPROTO_DCCP, IPPROTO_UDPLITE): Define.
+
+ * sysdeps/unix/sysv/linux/bits/socket.h (SOCK_DCCP): Define.
+
+2008-05-13 Ulrich Drepper <drepper@redhat.com>
+
+ * po/lt.po: New file. From Lituanian translation team.
+
+2008-01-30 Alexandre Oliva <aoliva@redhat.com>
+
+ Introduce TLS descriptors for i386 and x86_64.
+ * include/inline-hashtab.h: New file, copied from 2005's
+ libiberty, with fix for memory leak imported afterwards by
+ Glauber de Oliveira Costa.
+ * elf/tlsdeschtab.h: New file.
+ * elf/dl-reloc.c (_dl_try_allocate_static_tls): Extract from...
+ (_dl_allocate_static_tls): ... here. Rearrange failure path.
+ (CHECK_STATIC_TLS): Move to...
+ * elf/dynamic-link.h: ... this file.
+ (TRY_STATIC_TLS): New macro.
+ * elf/dl-conflict.c (CHECK_STATIC_TLS, TRY_STATIC_TLS): Override.
+ * elf/elf.h (R_386_TLS_GOTDESC, R_386_TLS_DESC_CALL,
+ R_386_TLS_DESC): Define.
+ (R_X86_64_PC64, R_X86_GOTOFF64, R_X86_64_GOTPC32): Merge from
+ binutils.
+ (R_X86_64_GOTPC32_TLSDESC, R_X86_64_TLSDESC_CALL,
+ R_X86_64_TLSDESC): Define.
+ (R_386_NUM, R_X86_64_NUM): Adjust.
+ * sysdeps/i386/Makefile (sysdep-dl-routines, sysdep_routines,
+ sysdep-rtld-routines): Add tlsdesc and dl-tlsdesc for elf subdir.
+ (gen-as-const-headers): Add tlsdesc.sym to csu subdir.
+ * sysdeps/i386/dl-lookupcfg.h: New file. Introduce _dl_unmap to
+ release tlsdesc_table.
+ * sysdeps/i386/dl-machine.h: Include dl-tlsdesc.h.
+ (elf_machine_type_class): Mark R_386_TLS_DESC as PLT class.
+ (elf_machine_rel): Handle R_386_TLS_DESC.
+ (elf_machine_rela): Likewise.
+ (elf_machine_lazy_rel): Likewise.
+ (elf_machine_lazy_rela): Likewise.
+ * sysdeps/i386/dl-tls.h (struct dl_tls_index): Name it.
+ * sysdeps/i386/dl-tlsdesc.S: New file.
+ * sysdeps/i386/dl-tlsdesc.h: New file.
+ * sysdeps/i386/tlsdesc.c: New file.
+ * sysdeps/i386/tlsdesc.sym: New file.
+ * sysdeps/i386/bits/linkmap.h (struct link_map_machine): Add
+ tlsdesc_table.
+ * sysdeps/x86_64/Makefile (sysdep-dl-routines, sysdep_routines,
+ sysdep-rtld-routines): Add tlsdesc and dl-tlsdesc for elf subdir.
+ (gen-as-const-headers): Add tlsdesc.sym to csu subdir.
+ * sysdeps/x86_64/dl-lookupcfg.h: New file. Introduce _dl_unmap to
+ release tlsdesc_table.
+ * sysdeps/x86_64/dl-machine.h: Include dl-tlsdesc.h.
+ (elf_machine_runtime_setup): Set up lazy TLSDESC GOT entry.
+ (elf_machine_type_class): Mark R_X86_64_TLSDESC as PLT class.
+ (elf_machine_rel): Handle R_X86_64_TLSDESC.
+ (elf_machine_rela): Likewise.
+ (elf_machine_lazy_rel): Likewise.
+ * sysdeps/x86_64/dl-tls.h (struct dl_tls_index): Name it.
+ (__tls_get_addr): Do not declare for non-shared compiles.
+ * sysdeps/x86_64/dl-tlsdesc.S: New file.
+ * sysdeps/x86_64/dl-tlsdesc.h: New file.
+ * sysdeps/x86_64/tlsdesc.c: New file.
+ * sysdeps/x86_64/tlsdesc.sym: New file.
+ * sysdeps/x86_64/bits/linkmap.h (struct link_map_machine): Add
+ tlsdesc_table for both 32- and 64-bit structs.
+
+2008-05-11 Ulrich Drepper <drepper@redhat.com>
+
+ * elf/dl-tls.c (__tls_get_addr): Optimize by moving slow path in
+ its own function. This reduces the frame setup costs and more.
+
+2008-02-11 Joseph Myers <joseph@codesourcery.com>
+
+ [BZ #3406]
+ * sysdeps/ieee754/flt-32/w_expf.c (o_threshold): Correct value.
+ * math/libm-test.inc (exp_test): Test 88.72269439697265625.
+
+2008-05-11 Ulrich Drepper <drepper@redhat.com>
+
+ * io/openat.c (__openat_2): Also pass fd to __openat.
+ * io/openat64.c (__openat64_2): Also pass fd to __openat64.
+ Patch by Kristian Van Der Vliet <vanders@liqwyd.com>.
+
+ * string/tester.c (test_memcmp): Add a few more tests.
+ Patch by Mats Erik Andersson <ynglingatal@comhem.se>.
+
+2008-05-10 Ulrich Drepper <drepper@redhat.com>
+
+ * nscd/cache.c (cache_add): Before returning with failure and this
+ is the first use of the record, mark it as unusable.
+ * nscd/aicache.c: Don't touch the dataset after cache_add returns
+ reporting a failure.
+ * nscd/grpcache.c: Likewise
+ * nscd/hstcache.c: Likewise.
+ * nscd/initgrcache.c: Likewise.
+ * nscd/pwdcache.c: Likewise.
+ * nscd/servicescache.c: Likewise.
+
+2008-05-10 Roland McGrath <roland@redhat.com>
+
+ [BZ #6505]
+ * sysdeps/unix/sysv/linux/sys/user.h: Replace with #error stub.
+
+2008-05-08 David S. Miller <davem@davemloft.net>
+
+ * misc/truncate64.c (truncate64): Use __truncate not truncate.
+
+ * sysdeps/ieee754/ldbl-128/e_j0l.c (__ieee751_j0l): Use __finitel.
+ (__ieee754_y0l): Likewise.
+ * sysdeps/ieee754/ldbl-128/e_j1l.c (__ieee754_j1l): Likewise.
+ (__ieee754_y1l): Likewise.
+ * sysdeps/ieee754/ldbl-128/s_expm1l.c (__expm1l): Use __ldexpl.
+ * sysdeps/ieee754/ldbl-128/s_log1pl.c: Kill bogus prototypes for
+ frexpl and ldexpl. math_private.h provides them and the latter
+ is not even used.
+ (__log1pl): Use __frexpl.
+
+2008-05-10 Ulrich Drepper <drepper@redhat.com>
+
+ * include/resolv.h: Adjust __libc_res_nquery and __libc_res_nsend
+ prototypes.
+ * include/arpa/nameser_compat.h: Define T_UNSPEC.
+ * nis/Versions (libnss_nis): Export _nss_nis_gethostbyname4_r.
+ (libnss_nisplus): Export _nss_nisplus_gethostbyname4_r.
+ * nis/nss_nis/nis-hosts.c (LINE_PARSER): Change to also handle
+ af==AF_UNSPEC.
+ (_nss_nis_gethostbyname4_r): New function.
+ * nis/nss_nisplus/nisplus-hosts.c (_nss_nisplus_parse_hostent):
+ Change to also handle af==AF_UNSPEC.
+ (get_tablename): New function. Use it to avoid duplication.
+ (_nss_nisplus_gethostbyname4_r): New function.
+ * nscd/aicache.c (addhstaiX): Use gethostbyname4_r function is
+ available.
+ * nss/Versions (libnss_files): Export _nss_files_gethostbyname4_r.
+ * nss/nss.h: Define struct gaih_addrtuple.
+ * nss/nss_files/files-hosts.c (LINE_PARSER): Change to also handle
+ af==AF_UNSPEC.
+ (_nss_files_gethostbyname4_r): New function.
+ * resolv/Versions (libnss_dns): Export _nss_dns_gethostbyname4_r.
+ * resolv/gethnmaddr.c: Adjust __libc_res_nsearch and __libc_res_nquery
+ calls.
+ * resolv/res_query.c (__libc_res_nquery): Take two additional
+ parameters for second answer buffer. Handle type=T_UNSPEC to mean
+ look up IPv4 and IPv6.
+ Change all callers.
+ * resolv/res_send.c (__libc_res_nsend): Take five aditional parameters
+ for an additional query and answer buffer. Pass to send_vc and
+ send_dg.
+ (send_vc): Send possibly two requests and receive two answers.
+ (send_dg): Likewise.
+ * resolv/nss_dns/dns-host.c: Adjust calls to __libc_res_nsearch and
+ __libc_res_nquery.
+ (_nss_dns_gethostbyname4_r): New function.
+ (gaih_getanswer_slice): Likewise.
+ (gaih_getanswer): Likewise.
+ * resolv/nss_dns/dns-canon.c (_nss_dns_getcanonname_r): Adjust
+ __libc_res_nquery call.
+ * resolv/nss_dns/dns-network.c (_nss_dns_getnetbyaddr_r): Likewise.
+ (_nss_dns_getnetbyname_r): Adjust __libc_res_nsearch call.
+ * sysdeps/posix/getaddrinfo.c: Use gethostbyname4_r function is
+ available.
+
+2008-05-05 David S. Miller <davem@davemloft.net>
+
+ * sysdeps/sparc/sparc32/Makefile: Use -mcpu=v7 for initfini.s build.
+ * sysdeps/sparc/sparc64/Makefile: Use -mcpu=v9 for initfini.s build.
+
+2007-09-14 Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+ Fix termios bit macros.
+ Move *DLY definitions where they belong, in termios.h.
+ Add *[0-3] definitions.
+ Fixes confusion between VT and FF.
+ * sysdeps/mach/hurd/bits/ioctls.h (NL0, NL1, TAB0, TAB1, TAB2, CR0,
+ CR1, CR2, CR3, FF0, FF1, BS0, BS1): Undefine these at start if they
+ are already defined to avoid collision with termios.h.
+ (NLDLY, TABDLY, TAB3, CRDLY, VTDLY, BSDLY): Remove macros.
+ * bits/termios.h [__USE_MISC || __USE_XOPEN] (NL0, NL1, TAB0,
+ TAB1, TAB2, CR0, CR1, CR2, CR3, FF0, FF1, BS0, BS1): Likewise.
+ [__USE_BSD || __USE_XOPEN] (OCRNL, ONOCR, ONLRET): New macros.
+ [__USE_MISC || __USE_XOPEN] (NLDLY, NL0, NL1, TABDLY, TAB0, TAB1, TAB2,
+ TAB3, CRDLY, CR0, CR1, CR2, CR3, FFDLY, FF0, FF1, BSDLY, BS0, BS1,
+ VTDLY, VT0, VT1): New macros.
+ [__USE_GNU] (OLCUC): Change value of macro.
+ [__USE_XOPEN] (OFILL): New macro.
+ [__USE_BSD] (CRTSCTS): Change value.
+ (CRTS_IFLOW, CCTS_OFLOW): Change into compatibility macros.
+ [__USE_BSD] (CDTRCTS, CHWFLOW): New macros.
+ (B7200, B14400, B28800, B76800): New macros.
+
+2008-05-01 David S. Miller <davem@davemloft.net>
+
+ * sysdeps/unix/sysv/linux/sparc/sparc32/ucontext_i.sym: New file.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/Makefile [$(subdir) = stdlib]:
+ (gen-as-const-headers): Add it.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/getcontext.S: New file.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/makecontext.c: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/setcontext.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/swapcontext.S: Likewise.
+
+ * sysdeps/unix/sysv/linux/sparc/sparc32/syscall.S: Add support for
+ six system call parameters.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S: Likewise.
+
+2008-04-30 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/unix/sysv/linux/bits/resource.h: Define RUSAGE_THREAD and
+ RUSAGE_LWP.
+ * sysdeps/unix/sysv/linux/sparc/bits/resource.h: Likewise.
+ * sysdeps/unix/sysv/linux/alpha/bits/resource.h: Likewise.
+
+2008-04-30 Jakub Jelinek <jakub@redhat.com>
+
+ * stdlib/tst-setcontext.c: Include unistd.h.
+
+2008-04-25 David S. Miller <davem@davemloft.net>
+
+ * sysdeps/unix/sysv/linux/sparc/sparc64/semctl.c (semctl):
+ Pass "union semun" properly in to sys_ipc, it must be passed
+ by value, not by reference.
+
+2008-04-22 Jakub Jelinek <jakub@redhat.com>
+
+ * nscd/Makefile (nscd-cflags): Set back to -fpie.
+ * nscd/nscd.h (mem_in_flight): Add attribute_tls_model_ie.
+ * nscd/connections.c (mem_in_flight): Likewise.
+
+ * nscd/nscd.h (dbs): Make hidden.
+
+ * sysdeps/unix/sysv/linux/times.c (__times): Fix check for EFAULT.
+ Avoid returning -1, return 0 instead.
+
+2008-04-19 Ulrich Drepper <drepper@redhat.com>
+
+ * resolv/res_mkquery.c (__res_nopt): Use NS_PUT16 instead of ns_put16.
+
+2008-04-15 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #5209]
+ * sysdeps/unix/sysv/linux/times.c: New file.
+
+ [BZ #5381]
+ * nscd/nscd.h: Define enum in_flight, mem_in_flight, and
+ mem_in_flight_list variables. Add new parameter to mempool_alloc
+ prototype.
+ * nscd/mem.c (mempool_alloc): Take additional parameter. Initialize
+ appropriate mem_in_flight element.
+ (gc): Take allocations which have not yet been committed to the
+ database into account.
+ * nscd/cache.c (cache_add): Add new parameter to mempool_alloc call.
+ Reset mem_in_flight before returning.
+ * nscd/connections.c (nscd_run_worker): Initialize mem_in_flight and
+ cue it up in mem_in_flight_list.
+ * nscd/aicache.c: Adjust mempool_alloc call.
+ * nscd/grpcache.c: Likewise.
+ * nscd/hstcache.c: Likewise.
+ * nscd/initgrcache.c: Likewise.
+ * nscd/pwdcache.c: Likewise.
+ * nscd/servicescache.c: Likewise.
+ * nscd/Makefile (nscd-flags): Until ld is fixed, use -fpic instead
+ of -fpie.
+
+ * nscd/connections.c (handle_request): Provide better error message
+ in case SELinux forbids the service.
+
+ * version.h (VERSION): Bump to 2.8.90.
+
+2008-04-17 Jakub Jelinek <jakub@redhat.com>
+
+ * sysdeps/unix/sysv/linux/dl-osinfo.h: Include fcntl.h.
+
+2008-04-11 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/unix/sysv/linux/powerpc/bits/mathinline.h (__signbitl):
+ Also use for 32-bit.
+ * sysdeps/ieee754/ldbl-128ibm/s_nearbyintl.c (__nearbyintl): Use
+ __nextafter instead of nextafter to avoid local PLT.
+ * sysdeps/powerpc/fpu/e_sqrt.c: Avoid call to fetestexcept.
+ * sysdeps/powerpc/fpu/e_sqrtf.c: Likewise.
+
+ * scripts/data/localplt-powerpc64-linux-gnu.data: New file.
+
+ * sysdeps/powerpc/fpu/fenv_libc.h: Add libm_hidden_proto for
+ __fe_nomask_env.
+ * sysdeps/powerpc/fpu/fe_nomask.c: Add libm_hidden_def. Include
+ <fenv_libc.h> instead of <fenv.h>.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/fe_nomask.c: Likewise.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_nomask.c: Likewise.
+
+ * sysdeps/powerpc/bits/fenv.h: Make safe for C++.
+
+ * sysdeps/unix/sysv/linux/powerpc/bits/mathinline.h: New file.
+ * sysdeps/powerpc/fpu/fegetexcept.c (__fegetexcept): Rename
+ function from fegetexcept and make old name weak alias.
+ * include/fenv.h: Declare __fegetexcept.
+ * sysdeps/powerpc/fpu/fedisblxcpt.c: Use __fegetexcept instead of
+ fegetexcept.
+ * sysdeps/powerpc/fpu/feenablxcpt.c: Likewise.
+ * sysdeps/powerpc/fpu/fraiseexcpt.c (__feraiseexcept): Avoid call
+ to fetestexcept.
+ * sysdeps/ieee754/ldbl-128ibm/s_log1pl.c (__log1pl): Use __frexpl
+ instead of frexpl to avoid local PLT.
+ * math/s_significandl.c (__significandl): Use __ilogbl instead of
+ ilogbl to avoid local PLT.
+ * sysdeps/ieee754/ldbl-128ibm/s_expm1l.c (__expm1l): Use __ldexpl
+ instead of ldexpl to avoid local PLT.
+ * sysdeps/ieee754/ldbl-128ibm/e_expl.c (__ieee754_expl): Use
+ __roundl not roundl to avoid local PLT.
+ * sysdeps/ieee754/ldbl-128/e_j0l.c: Use function names which avoid
+ local PLTs. Use __sincosl instead of separate sinl and cosl
+ calls.
+ * sysdeps/ieee754/ldbl-128/e_j1l.c: Likewise.
+
+ * sysdeps/unix/sysv/linux/configure.in: Bump minimal kernel
+ version for ppc64 to 2.4.21 since without it makecontext will fail.
+
+ * elf/tls-macros.h [__powerpc64__] (__TLS_GET_ADDR): Define according
+ to the ABI in use.
+ [__powerpc64__] (TLS_LD): Use __TLS_GET_ADDR instead of
+ .__tls_get_addr.
+ [__powerpc64__] (TLS_GD): Likewise.
+
+2007-11-20 Ryan S. Arnold <rsa@us.ibm.com>
+
+ [BZ #4997]
+ * sysdeps/powerpc/powerpc32/fpu/s_lround.S (__lround): Fixed erroneous
+ result when x is +/-nextafter(+/-0.5,-/+1) i.e. all 1's in the
+ mantissa.
+ * sysdeps/powerpc/powerpc32/power4/fpu/s_llround.S (__llround):
+ Likewise. Also account for when x is an odd number between 2^52
+ and 2^53-1.
+ * sysdeps/powerpc/powerpc64/fpu/s_llround.S (__llround): Likewise.
+ * sysdeps/powerpc/powerpc64/fpu/s_llroundf.S (__llroundf): Likewise.
+ * math/libm-test.inc (lround_test, llround_test): Added test cases to
+ detect aforementioned erroneous conditions.
+
+2008-04-11 Jakub Jelinek <jakub@redhat.com>
+
+ * configure.in: Check for -fno-section-anchors in addition to
+ -fno-toplevel-reorder.
+
+2008-04-11 Ulrich Drepper <drepper@redhat.com>
+
+ * include/features.h (__GLIBC_MINOR__): Bump to 8.
+
+ * sysdeps/powerpc/powerpc32/fpu/s_lroundf.S: Remove duplicate comment.
+ * sysdeps/powerpc/powerpc32/power5+/fpu/s_llroundf.S: Likewise.
+ * sysdeps/powerpc/powerpc32/power6/fpu/s_llroundf.S: Likewise.
+ * sysdeps/powerpc/powerpc64/fpu/s_lrint.S: Likewise.
+ * sysdeps/powerpc/powerpc64/fpu/s_lround.S: Likewise.
+ * sysdeps/powerpc/powerpc64/fpu/s_lroundf.S: Likewise.
+
+2008-04-11 Jakub Jelinek <jakub@redhat.com>
+
+ [BZ #5443]
+ * time/era.c: Transform __libc_setlocale_lock into rwlock.
+ * time/alt_digit.c: Likewise.
+ * wcsmbs/wcsmbsload.c: Likewise.
+
+2008-04-10 Ulrich Drepper <drepper@redhat.com>
+
+ * version.h (VERSION): Bump to 2.8.
+
+ * timzeone/asia: Update from tzdata2008b.
+ * timezone/backward: Likewise.
+ * timezone/europe: Likewise.
+ * timezone/northamerica: Likewise.
+ * timezone/southamerica: Likewise.
+ * timezone/iso3166.tab: Likewise.
+ * timezone/leapseconds: Likewise.
+ * timezone/zone.tab: Likewise.
+ * timezone/private.h: Update from tzcode2008a.
+ * timezone/zdump.c: Likewise.
+ * timezone/zic.c: Likewise.
+
+2008-01-24 Steven Munroe <sjmunroe@us.ibm.com>
+
+ [BZ #5741]
+ * sysdeps/powerpc/powerpc64/dl-machine.h (PPC_DCBT, PPC_DCBF):
+ Define additonal Data Cache Block instruction macros.
+ (elf_machine_fixup_plt): Add dcbt for opd and plt entries.
+ Replace dcbst with dcbf and sync with sync/isync.
+
+2008-02-21 Alan Modra <amodra@bigpond.net.au>
+
+ * sysdeps/powerpc/powerpc64/dl-machine.h (elf_machine_type_class):
+ Always set ELF_RTYPE_CLASS_PLT.
+ (elf_machine_lookup_noexec_p, elf_machine_lookup_noplt_p): Delete.
+
+2008-04-03 Steven Munroe <sjmunroe@us.ibm.com>
+
+ * sysdeps/powerpc/powerpc32/power4/hp-timing.c: New file.
+ * sysdeps/powerpc/powerpc32/power4/hp-timing.h: New file.
+ * sysdeps/powerpc/powerpc64/hp-timing.h [_ARCH_PWR4] (HP_TIMING_NOW):
+ For ISA 2.01 and later replace mftb with mfspr 268.
+
+2008-02-19 Steven Munroe <sjmunroe@us.ibm.com>
+
+ [BZ #5768]
+ * sysdeps/powerpc/fpu/Makefile (libm-tests): Add test-powerpc-snan.
+ * sysdeps/powerpc/fpu/test-powerpc-snan.c: New file.
+
+2008-02-18 Steven Munroe <sjmunroe@us.ibm.com>
+
+ [BZ #5768]
+ * sysdeps/powerpc/powerpc32/fpu/s_isnan.S: New file.
+ * sysdeps/powerpc/powerpc32/fpu/s_isnan.c: Removed.
+ * sysdeps/powerpc/powerpc64/fpu/s_isnan.S: New file.
+ * sysdeps/powerpc/powerpc64/fpu/s_isnan.c: Removed.
+
+2008-04-10 Jakub Jelinek <jakub@redhat.com>
+
+ * stdlib/tst-makecontext.c (othervar): New variable.
+ (cf): Test sign extending the argument to long.
+
+2008-03-03 Steven Munroe <sjmunroe@us.ibm.com>
+
+ * sysdeps/powerpc/powerpc32/power5/fpu/s_isnan.S: New file.
+ * sysdeps/powerpc/powerpc32/power5/fpu/s_isnanf.S: New file.
+ * sysdeps/powerpc/powerpc32/power6/fpu/s_isnan.S: New file.
+ * sysdeps/powerpc/powerpc32/power6/fpu/s_isnanf.S: New file.
+ * sysdeps/powerpc/powerpc64/power5/fpu/s_isnan.S: New file.
+ * sysdeps/powerpc/powerpc64/power6/fpu/s_isnan.S: New file.
+ * sysdeps/powerpc/powerpc64/power6x/fpu/s_isnan.S: New file.
+
+2008-02-22 Alan Modra <amodra@bigpond.net.au>
+
+ * elf/Makefile (tests): Substitute tests-vis-yes here.
+ (tests-vis-yes): Delete.
+ (modules-name, modules-vis-yes): Similarly.
+
+2008-02-12 Pete Eberlein <eberlein@us.ibm.com>
+
+ [BZ #4407]
+ * sysdeps/ieee754/ldbl-128/e_lgammal_r.c (__ieee754_lgammal_r):
+ Preserve sign in signgamp when x is zero.
+
+2007-10-26 Steven Munroe <sjmunroe@us.ibm.com>
+
+ * sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.S: New File.
+ * sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.c: Removed.
+ * sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.S: New File.
+ * sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.c: Removed.
+ * sysdeps/powerpc/powerpc32/power5/fpu/w_sqrt.S: New File.
+ * sysdeps/powerpc/powerpc32/power5/fpu/w_sqrtf.S: New File.
+
+2008-04-09 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #4314]
+ * sysdeps/i386/i686/memcpy.S: Optimize copying of equally aligned
+ buffers.
+
+ [BZ #5209]
+ * sysdeps/unix/sysv/syscalls.list: The times syscall doesn't have
+ a reserved error value.
+
+ * stdlib/tst-makecontext.c: Change parameter to cf to negative
+ value to check for correct sign extension.
+
+ [BZ #5436]
+ * sysdeps/unix/sysv/linux/x86_64/makecontext.c (__makecontext):
+ Copy 64-bit parameter values even though this is not required in
+ the standard.
+
+ * sysdeps/unix/sysv/linux/x86_64/vfork.S (__vfork): Record return
+ PC save.
+
+2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/i386/vfork.S (__vfork): Record return
+ PC save.
+
+2008-04-09 Jakub Jelinek <jakub@redhat.com>
+
+ * nss_files/files-XXX.c (_nss_files_getXXent_r): Restore saved errno.
+
+2008-04-09 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #5998]
+ * libio/iofwrite.c (_IO_fwrite): Return correct count if flushing
+ in line-buffered stream failed.
+ * libio/iofwrite_u.c (fwrite_unlocked): Likewise.
+
+2008-04-08 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6024]
+ * scripts/abi-versions.awk: If the version specified by
+ --enable-oldest-abi is older than the first version for this
+ architecture, use the default version.
+
+ * locale/programs/ld-collate.c (collate_read): Ignore script lines
+ as well when ignoring the whole category.
+
+2008-04-07 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6042]
+ * sysdeps/unix/sysv/linux/net/ethernet.h: Add a few more
+ ETHERTYPE_* definitions.
+ Patch partly by Aurelien Jarno <aurelien@aurel32.net>.
+
+2008-04-07 Jakub Jelinek <jakub@redhat.com>
+
+ * stdlib/mbtowc.c (__no_r_state): Remove.
+ (mbtowc): New static state variable. Use it instead of
+ __no_r_state.
+ * stdlib/wctomb.c (__no_r_state): Remove extern decl.
+ (__wctomb_state): New hidden variable.
+ (wctomb): Use __wctomb_state instead of __no_r_state.
+ * debug/wctomb_chk.c (__no_r_state): Remove extern decl.
+ (__wctomb_state): New extern decl.
+ (__wctomb_chk): Use __wctomb_state instead of __no_r_state.
+
+2008-04-07 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #5475]
+ * resolv/res_init.c: Handle scope IDs in resolv.conf.
+
+2008-04-07 Jakub Jelinek <jakub@redhat.com>
+
+ * malloc/mtrace.pl: Use $@ instead of $* to keep perl 5.10 quiet.
+
+2008-04-06 Ulrich Drepper <drepper@redhat.com>
+
+ * po/nl.po: Update from translation team.
+
2008-03-31 Ulrich Drepper <drepper@redhat.com>
[BZ #6007]
diff --git a/libc/ChangeLog.eglibc b/libc/ChangeLog.eglibc
index 7bae20c7b..b41fe86fb 100644
--- a/libc/ChangeLog.eglibc
+++ b/libc/ChangeLog.eglibc
@@ -1,3 +1,47 @@
+2008-06-17 Joseph Myers <joseph@codesourcery.com>
+
+ * stdlib/tst-setcontext.c: Set back_in_main before exit if
+ getcontext returns ENOSYS.
+
+2008-05-15 Joseph Myers <joseph@codesourcery.com>
+
+ * posix/globtest.sh: Set HOME with env on test target system.
+
+2008-05-14 Joseph Myers <joseph@codesourcery.com>
+
+ * iconvdata/Makefile (bug-iconv6-ENV, tst-iconv7-ENV): Define.
+ * localedata/Makefile (LOCALES): Add en_US.UTF-8.
+
+2008-05-14 Maxim Kuvyrkov <maxim@codesourcery.com>
+
+ Generate zoneinfo when cross-building EGLIBC.
+
+ * timezone/Makefile: When cross-compiling, build cross-zic, then
+ use it to generate zoneinfo files.
+
+2008-04-25 Vladimir Prus <vladimir@codesourcery.com>
+
+ * sysdeps/sparc/sparc64/elf/configure.in: Hard-code result of TLS
+ link test.
+ * sysdeps/sparc/sparc64/elf/configure: Regenerate.
+
+2008-04-25 Maxim Kuvyrkov <maxim@codesourcery.com>
+
+ Cross-rpcgen.
+
+ * sunrpc/Makefile: Make librpcsvc.a built when cross-building.
+ Build cross-rpcgen for $build when cross-building.
+ * sunrpc/proto.h: Define stuff for cross-building.
+
+2008-04-15 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/configure: Regenerate.
+
+2008-04-12 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/powerpc/bits/mathinline.h: Also test
+ __NO_FPRS__.
+
2008-04-01 Maxim Kuvyrkov <maxim@codesourcery.com>
* Makerules (install-lib): Don't install libpthread_pic.a.
diff --git a/libc/Makeconfig b/libc/Makeconfig
index df7516047..4dca7a0a4 100644
--- a/libc/Makeconfig
+++ b/libc/Makeconfig
@@ -651,7 +651,7 @@ ifeq "$(strip $(+cflags))" ""
+cflags := $(default_cflags)
endif # $(+cflags) == ""
-+cflags += $(addprefix -mcpu=,$(with-cpu)) $(+gccwarn) $(+merge-constants)
++cflags += $(cflags-cpu) $(+gccwarn) $(+merge-constants)
+gcc-nowarn := -w
# Don't duplicate options if we inherited variables from the parent.
@@ -720,6 +720,10 @@ pic-ccflag = -fPIC
# This one should always stay like this unless there is a very good reason.
PIC-ccflag = -fPIC
endif
+# This can be changed by a sysdep makefile
+pie-ccflag = -fpie
+# This one should always stay like this unless there is a very good reason.
+PIE-ccflag = -fPIE
ifeq (yes,$(build-profile))
# Under --enable-profile, we will build a static library of profiled objects.
# The profiled object files are named foo.op.
@@ -834,6 +838,7 @@ $(common-objpfx)soversions.mk: $(common-objpfx)soversions.i $(..)Makeconfig
(seen_DEFAULT=0; seen_WORDSIZE32=0; seen_WORDSIZE64=0; \
while read which lib number setname; do \
eval seen_$$which=1; \
+ test x"$$which" != xABI || echo abi-name = "$$lib"; \
test x"$$which" = xDEFAULT || continue; \
case $$number in \
[0-9]*) echo "$$lib.so-version=.$$number"; \
diff --git a/libc/Makefile b/libc/Makefile
index f721ca833..b6c499d22 100644
--- a/libc/Makefile
+++ b/libc/Makefile
@@ -1,4 +1,5 @@
-# Copyright (C) 1991-2002,2003,2004,2005,2006 Free Software Foundation, Inc.
+# Copyright (C) 1991-2002,2003,2004,2005,2006,2008
+# 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
@@ -266,8 +267,12 @@ tests-clean:
tests: $(objpfx)c++-types-check.out $(objpfx)check-local-headers.out
ifneq ($(CXX),no)
check-data := $(firstword $(wildcard \
- $(foreach M,$(config-machine) $(base-machine),\
- scripts/data/c++-types-$M-$(config-os).data)))
+ $(foreach D,$(add-ons) scripts,\
+ $(patsubst %,$D/data/c++-types-%.data,\
+ $(abi-name) \
+ $(addsuffix -$(config-os),\
+ $(config-machine) \
+ $(base-machine))))))
ifneq (,$(check-data))
$(objpfx)c++-types-check.out: $(check-data) scripts/check-c++-types.sh
scripts/check-c++-types.sh $< $(CXX) $(filter-out -std=gnu99 -Wstrict-prototypes,$(CFLAGS)) $(CPPFLAGS) > $@
diff --git a/libc/NEWS b/libc/NEWS
index 1f5670413..c3ceaba42 100644
--- a/libc/NEWS
+++ b/libc/NEWS
@@ -1,15 +1,76 @@
-GNU C Library NEWS -- history of user-visible changes. 2007-12-12
-Copyright (C) 1992-2006, 2007 Free Software Foundation, Inc.
+GNU C Library NEWS -- history of user-visible changes. 2008-8-2
+Copyright (C) 1992-2007, 2008 Free Software Foundation, Inc.
See the end for copying conditions.
Please send GNU C library bug reports via <http://sources.redhat.com/bugzilla/>
using `glibc' in the "product" field.
+Version 2.9
+
+* Unified lookup for getaddrinfo: IPv4 and IPv6 addresses are now looked
+ up at the same time. Implemented by Ulrich Drepper.
+
+* TLS descriptors for LD and GD on x86 and x86-64.
+ Implemented by Alexandre Oliva.
+
+* getaddrinfo now handles DCCP and UDPlite.
+ Implemented by Ulrich Drepper.
+
+* New fixed-size conversion macros: htobe16, htole16, be16toh, le16toh,
+ htobe32, htole32, be32toh, le32toh, htobe64, htole64, be64toh, le64toh.
+ Implemented by Ulrich Drepper.
+
+* New implementation of memmem, strstr, and strcasestr which is O(n).
+ Implemented by Eric Blake.
+
+* New Linux interfaces: inotify_init1, paccept, dup3, epoll_create1, pipe2
+
+* Implement "e" option for popen to open file descriptor with the
+ close-on-exec flag set. Implemented by Ulrich Drepper.
+
+* Implement "b" mode for fmemopen. In this mode writes writes don't
+ implicitly add a NUL byte and seeks from the end of the buffer really
+ use the buffer end, not the string length as the basis.
+ Implemented by Ulrich Drepper.
+
+* Many functions, exported and internal, now atomically set the close-on-exec
+ flag when run on a sufficiently new kernel. Implemented by Ulrich Drepper.
+
+* Sorting rules for some Indian languages (Kannada, Gurumukhi, Telugu)
+ Implemented by Pravin Satpute.
+
Version 2.8
-* New locales: bo_CN, bo_IN.
+* New locales: bo_CN, bo_IN, shs_CA.
* New encoding: HP-ROMAN9, HP-GREEK8, HP-THAI8, HP-TURKISH8.
+
+* Sorting rules for some Indian languages (Devanagari and Gujarati).
+ Implemented by Pravin Satpute.
+
+* IPV6 addresses in /etc/resolv.conf can now have a scope ID
+
+* nscd caches now all timeouts for DNS entries
+ Implemented by Ulrich Drepper.
+
+* nscd is more efficient and wakes up less often.
+ Implemented by Ulrich Drepper.
+
+* More checking functions: asprintf, dprintf, obstack_printf, vasprintf,
+ vdprintf, and obstack_vprintf.
+ Implemented by Jakub Jelinek.
+
+* Faster memset for x86-64.
+ Implemented by Harsha Jagasia and H.J. Lu.
+
+* Faster memcpy on x86.
+ Implemented by Ulrich Drepper.
+
+* ARG_MAX is not anymore constant on Linux. Use sysconf(_SC_ARG_MAX).
+ Implemented by Ulrich Drepper.
+
+* Faster sqrt and sqrtf implemention for some PPC variants.
+ Implemented by Stephen Munroe.
Version 2.7
diff --git a/libc/Versions.def b/libc/Versions.def
index 0de15f8f7..856d87806 100644
--- a/libc/Versions.def
+++ b/libc/Versions.def
@@ -25,6 +25,7 @@ libc {
GLIBC_2.6
GLIBC_2.7
GLIBC_2.8
+ GLIBC_2.9
%ifdef USE_IN_LIBIO
HURD_CTHREADS_0.3
%endif
@@ -92,6 +93,7 @@ libresolv {
GLIBC_2.0
GLIBC_2.2
GLIBC_2.3.2
+ GLIBC_2.9
GLIBC_PRIVATE
}
librt {
@@ -105,6 +107,7 @@ librt {
}
libutil {
GLIBC_2.0
+ GLIBC_2.9
}
ld {
GLIBC_2.0
diff --git a/libc/bits/byteswap.h b/libc/bits/byteswap.h
index 949ed0bc9..45cb9471e 100644
--- a/libc/bits/byteswap.h
+++ b/libc/bits/byteswap.h
@@ -1,5 +1,5 @@
/* Macros to swap the order of bytes in integer values.
- Copyright (C) 1997,1998,2000,2001,2002,2005 Free Software Foundation, Inc.
+ Copyright (C) 1997,1998,2000-2002,2005,2008 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,7 +17,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#if !defined _BYTESWAP_H && !defined _NETINET_IN_H
+#if !defined _BYTESWAP_H && !defined _NETINET_IN_H && !defined _ENDIAN_H
# error "Never use <bits/byteswap.h> directly; include <byteswap.h> instead."
#endif
diff --git a/libc/bits/termios.h b/libc/bits/termios.h
index 43bb1ce52..293d0a606 100644
--- a/libc/bits/termios.h
+++ b/libc/bits/termios.h
@@ -24,6 +24,50 @@
/* These macros are also defined in some <bits/ioctls.h> files (with
numerically identical values), but this serves to shut up cpp's
complaining. */
+#if defined __USE_MISC || defined __USE_XOPEN
+
+# ifdef NL0
+# undef NL0
+# endif
+# ifdef NL1
+# undef NL1
+# endif
+# ifdef TAB0
+# undef TAB0
+# endif
+# ifdef TAB1
+# undef TAB1
+# endif
+# ifdef TAB2
+# undef TAB2
+# endif
+# ifdef CR0
+# undef CR0
+# endif
+# ifdef CR1
+# undef CR1
+# endif
+# ifdef CR2
+# undef CR2
+# endif
+# ifdef CR3
+# undef CR3
+# endif
+# ifdef FF0
+# undef FF0
+# endif
+# ifdef FF1
+# undef FF1
+# endif
+# ifdef BS0
+# undef BS0
+# endif
+# ifdef BS1
+# undef BS1
+# endif
+
+#endif /* __USE_MISC || __USE_XOPEN */
+
#ifdef __USE_BSD
# ifdef MDMBUF
@@ -91,13 +135,47 @@ struct termios
/* Output modes. */
tcflag_t c_oflag;
#define OPOST (1 << 0) /* Perform output processing. */
-#ifdef __USE_BSD
+#if defined __USE_BSD || defined __USE_XOPEN
# define ONLCR (1 << 1) /* Map NL to CR-NL on output. */
-# define OXTABS (1 << 2) /* Expand tabs to spaces. */
+#endif
+#ifdef __USE_BSD
+# define OXTABS TAB3 /* Expand tabs to spaces. */
# define ONOEOT (1 << 3) /* Discard EOT (^D) on output. */
#endif
+#if defined __USE_BSD || defined __USE_XOPEN
+# define OCRNL (1 << 4) /* Map CR to NL. */
+# define ONOCR (1 << 5) /* Discard CR's when on column 0. */
+# define ONLRET (1 << 6) /* Move to column 0 on NL. */
+#endif
+#if defined __USE_MISC || defined __USE_XOPEN
+# define NLDLY (3 << 8) /* NL delay. */
+# define NL0 (0 << 8) /* NL type 0. */
+# define NL1 (1 << 8) /* NL type 1. */
+# define TABDLY (3 << 10) /* TAB delay. */
+# define TAB0 (0 << 10) /* TAB delay type 0. */
+# define TAB1 (1 << 10) /* TAB delay type 1. */
+# define TAB2 (2 << 10) /* TAB delay type 2. */
+# define TAB3 (1 << 2) /* Expand tabs to spaces. */
+# define CRDLY (3 << 12) /* CR delay. */
+# define CR0 (0 << 12) /* CR delay type 0. */
+# define CR1 (1 << 12) /* CR delay type 1. */
+# define CR2 (2 << 12) /* CR delay type 2. */
+# define CR3 (3 << 12) /* CR delay type 3. */
+# define FFDLY (1 << 14) /* FF delay. */
+# define FF0 (0 << 14) /* FF delay type 0. */
+# define FF1 (1 << 14) /* FF delay type 1. */
+# define BSDLY (1 << 15) /* BS delay. */
+# define BS0 (0 << 15) /* BS delay type 0. */
+# define BS1 (1 << 15) /* BS delay type 1. */
+# define VTDLY (1 << 16) /* VT delay. */
+# define VT0 (0 << 16) /* VT delay type 0. */
+# define VT1 (1 << 16) /* VT delay type 1. */
+#endif /* __USE_MISC || __USE_XOPEN */
#ifdef __USE_GNU
-# define OLCUC (1 << 9) /* Translate lower case output to upper case */
+# define OLCUC (1 << 17) /* Translate lower case output to upper case */
+#endif
+#ifdef __USE_XOPEN
+# define OFILL (1 << 18) /* Send fill characters for delays. */
#endif
/* Control modes. */
@@ -117,10 +195,12 @@ 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 CRTSCTS (CCTS_OFLOW|CRTS_IFLOW) /* CTS/RTS flow control. */
-# define MDMBUF (1 << 20) /* Carrier flow control of output. */
+# define CRTSCTS (1 << 16) /* RTS/CTS flow control. */
+# define CRTS_IFLOW CRTSCTS /* Compatibility. */
+# define CCTS_OFLOW CRTSCTS /* Compatibility. */
+# define CDTRCTS (1 << 17) /* DTR/CTS flow control. */
+# define MDMBUF (1 << 20) /* DTR/DCD flow control. */
+# define CHWFLOW (MDMBUF|CRTSCTS|CDTRCTS) /* All types of flow control. */
#endif
/* Local modes. */
@@ -210,13 +290,17 @@ struct termios
#define B2400 2400 /* 2400 baud. */
#define B4800 4800 /* 4800 baud. */
#define B9600 9600 /* 9600 baud. */
+#define B7200 7200 /* 7200 baud. */
+#define B14400 14400 /* 14400 baud. */
#define B19200 19200 /* 19200 baud. */
+#define B28800 28800 /* 28800 baud. */
#define B38400 38400 /* 38400 baud. */
#ifdef __USE_MISC
# define EXTA 19200
# define EXTB 38400
#endif
#define B57600 57600
+#define B76800 76800
#define B115200 115200
#define B230400 230400
#define B460800 460800
diff --git a/libc/config.make.in b/libc/config.make.in
index 2d6c85b33..66e3ca329 100644
--- a/libc/config.make.in
+++ b/libc/config.make.in
@@ -31,7 +31,7 @@ base-machine = @base_machine@
config-vendor = @host_vendor@
config-os = @host_os@
config-sysdirs = @sysnames@
-with-cpu = @submachine@
+cflags-cpu = @libc_cv_cc_submachine@
defines = @DEFINES@
sysincludes = @SYSINCLUDES@
diff --git a/libc/configure b/libc/configure
index 0b76edfe5..6d5a75797 100755
--- a/libc/configure
+++ b/libc/configure
@@ -1,28 +1,57 @@
#! /bin/sh
# From configure.in CVSid.
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.59 for GNU C Library (see version.h).
+# Generated by GNU Autoconf 2.61 for GNU C Library (see version.h).
#
# Report bugs to <glibc>.
#
-# Copyright (C) 2003 Free Software Foundation, Inc.
+# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
+# 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.
## --------------------- ##
## M4sh Initialization. ##
## --------------------- ##
-# Be Bourne compatible
+# Be more Bourne compatible
+DUALCASE=1; export DUALCASE # for MKS sh
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
emulate sh
NULLCMD=:
# Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
# is contrary to our usage. Disable this feature.
alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
- set -o posix
+ setopt NO_GLOB_SUBST
+else
+ case `(set -o) 2>/dev/null` in
+ *posix*) set -o posix ;;
+esac
+
+fi
+
+
+
+
+# PATH needs CR
+# Avoid depending upon Character Ranges.
+as_cr_letters='abcdefghijklmnopqrstuvwxyz'
+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
+as_cr_Letters=$as_cr_letters$as_cr_LETTERS
+as_cr_digits='0123456789'
+as_cr_alnum=$as_cr_Letters$as_cr_digits
+
+# The user is always right.
+if test "${PATH_SEPARATOR+set}" != set; then
+ echo "#! /bin/sh" >conf$$.sh
+ echo "exit 0" >>conf$$.sh
+ chmod +x conf$$.sh
+ if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
+ PATH_SEPARATOR=';'
+ else
+ PATH_SEPARATOR=:
+ fi
+ rm -f conf$$.sh
fi
-DUALCASE=1; export DUALCASE # for MKS sh
# Support unset when possible.
if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
@@ -32,8 +61,43 @@ else
fi
+# IFS
+# We need space, tab and new line, in precisely that order. Quoting is
+# there to prevent editors from complaining about space-tab.
+# (If _AS_PATH_WALK were called with IFS unset, it would disable word
+# splitting by setting IFS to empty value.)
+as_nl='
+'
+IFS=" "" $as_nl"
+
+# Find who we are. Look in the path if we contain no directory separator.
+case $0 in
+ *[\\/]* ) as_myself=$0 ;;
+ *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
+done
+IFS=$as_save_IFS
+
+ ;;
+esac
+# We did not find ourselves, most probably we were run as `sh COMMAND'
+# in which case we are not to be found in the path.
+if test "x$as_myself" = x; then
+ as_myself=$0
+fi
+if test ! -f "$as_myself"; then
+ echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
+ { (exit 1); exit 1; }
+fi
+
# Work around bugs in pre-3.0 UWIN ksh.
-$as_unset ENV MAIL MAILPATH
+for as_var in ENV MAIL MAILPATH
+do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
+done
PS1='$ '
PS2='> '
PS4='+ '
@@ -47,18 +111,19 @@ do
if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
eval $as_var=C; export $as_var
else
- $as_unset $as_var
+ ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
fi
done
# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1; then
+if expr a : '\(a\)' >/dev/null 2>&1 &&
+ test "X`expr 00001 : '.*\(...\)'`" = X001; then
as_expr=expr
else
as_expr=false
fi
-if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
as_basename=basename
else
as_basename=false
@@ -66,157 +131,388 @@ fi
# Name of the executable.
-as_me=`$as_basename "$0" ||
+as_me=`$as_basename -- "$0" ||
$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)$' \| \
- . : '\(.\)' 2>/dev/null ||
+ X"$0" : 'X\(/\)' \| . 2>/dev/null ||
echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
- /^X\/\(\/\/\)$/{ s//\1/; q; }
- /^X\/\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
+ sed '/^.*\/\([^/][^/]*\)\/*$/{
+ s//\1/
+ q
+ }
+ /^X\/\(\/\/\)$/{
+ s//\1/
+ q
+ }
+ /^X\/\(\/\).*/{
+ s//\1/
+ q
+ }
+ s/.*/./; q'`
+# CDPATH.
+$as_unset CDPATH
-# PATH needs CR, and LINENO needs CR and PATH.
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
+if test "x$CONFIG_SHELL" = x; then
+ if (eval ":") 2>/dev/null; then
+ as_have_required=yes
+else
+ as_have_required=no
fi
+ if test $as_have_required = yes && (eval ":
+(as_func_return () {
+ (exit \$1)
+}
+as_func_success () {
+ as_func_return 0
+}
+as_func_failure () {
+ as_func_return 1
+}
+as_func_ret_success () {
+ return 0
+}
+as_func_ret_failure () {
+ return 1
+}
- as_lineno_1=$LINENO
- as_lineno_2=$LINENO
- as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
- test "x$as_lineno_1" != "x$as_lineno_2" &&
- test "x$as_lineno_3" = "x$as_lineno_2" || {
- # Find who we are. Look in the path if we contain no path at all
- # relative or not.
- case $0 in
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
+exitcode=0
+if as_func_success; then
+ :
+else
+ exitcode=1
+ echo as_func_success failed.
+fi
- ;;
- esac
- # We did not find ourselves, most probably we were run as `sh COMMAND'
- # in which case we are not to be found in the path.
- if test "x$as_myself" = x; then
- as_myself=$0
- fi
- if test ! -f "$as_myself"; then
- { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
- { (exit 1); exit 1; }; }
- fi
- case $CONFIG_SHELL in
- '')
+if as_func_failure; then
+ exitcode=1
+ echo as_func_failure succeeded.
+fi
+
+if as_func_ret_success; then
+ :
+else
+ exitcode=1
+ echo as_func_ret_success failed.
+fi
+
+if as_func_ret_failure; then
+ exitcode=1
+ echo as_func_ret_failure succeeded.
+fi
+
+if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
+ :
+else
+ exitcode=1
+ echo positional parameters were not saved.
+fi
+
+test \$exitcode = 0) || { (exit 1); exit 1; }
+
+(
+ as_lineno_1=\$LINENO
+ as_lineno_2=\$LINENO
+ test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
+ test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
+") 2> /dev/null; then
+ :
+else
+ as_candidate_shells=
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
- for as_base in sh bash ksh sh5; do
- case $as_dir in
+ case $as_dir in
/*)
- if ("$as_dir/$as_base" -c '
+ for as_base in sh bash ksh sh5; do
+ as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
+ done;;
+ esac
+done
+IFS=$as_save_IFS
+
+
+ for as_shell in $as_candidate_shells $SHELL; do
+ # Try only shells that exist, to save several forks.
+ if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
+ { ("$as_shell") 2> /dev/null <<\_ASEOF
+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
+ emulate sh
+ NULLCMD=:
+ # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
+ # is contrary to our usage. Disable this feature.
+ alias -g '${1+"$@"}'='"$@"'
+ setopt NO_GLOB_SUBST
+else
+ case `(set -o) 2>/dev/null` in
+ *posix*) set -o posix ;;
+esac
+
+fi
+
+
+:
+_ASEOF
+}; then
+ CONFIG_SHELL=$as_shell
+ as_have_required=yes
+ if { "$as_shell" 2> /dev/null <<\_ASEOF
+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
+ emulate sh
+ NULLCMD=:
+ # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
+ # is contrary to our usage. Disable this feature.
+ alias -g '${1+"$@"}'='"$@"'
+ setopt NO_GLOB_SUBST
+else
+ case `(set -o) 2>/dev/null` in
+ *posix*) set -o posix ;;
+esac
+
+fi
+
+
+:
+(as_func_return () {
+ (exit $1)
+}
+as_func_success () {
+ as_func_return 0
+}
+as_func_failure () {
+ as_func_return 1
+}
+as_func_ret_success () {
+ return 0
+}
+as_func_ret_failure () {
+ return 1
+}
+
+exitcode=0
+if as_func_success; then
+ :
+else
+ exitcode=1
+ echo as_func_success failed.
+fi
+
+if as_func_failure; then
+ exitcode=1
+ echo as_func_failure succeeded.
+fi
+
+if as_func_ret_success; then
+ :
+else
+ exitcode=1
+ echo as_func_ret_success failed.
+fi
+
+if as_func_ret_failure; then
+ exitcode=1
+ echo as_func_ret_failure succeeded.
+fi
+
+if ( set x; as_func_ret_success y && test x = "$1" ); then
+ :
+else
+ exitcode=1
+ echo positional parameters were not saved.
+fi
+
+test $exitcode = 0) || { (exit 1); exit 1; }
+
+(
as_lineno_1=$LINENO
as_lineno_2=$LINENO
- as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
test "x$as_lineno_1" != "x$as_lineno_2" &&
- test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
- $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
- $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
- CONFIG_SHELL=$as_dir/$as_base
- export CONFIG_SHELL
- exec "$CONFIG_SHELL" "$0" ${1+"$@"}
- fi;;
- esac
- done
-done
-;;
- esac
+ test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
+
+_ASEOF
+}; then
+ break
+fi
+
+fi
+
+ done
+
+ if test "x$CONFIG_SHELL" != x; then
+ for as_var in BASH_ENV ENV
+ do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
+ done
+ export CONFIG_SHELL
+ exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
+fi
+
+
+ if test $as_have_required = no; then
+ echo This script requires a shell more modern than all the
+ echo shells that I found on your system. Please install a
+ echo modern shell, or manually run the script under such a
+ echo shell if you do have one.
+ { (exit 1); exit 1; }
+fi
+
+
+fi
+
+fi
+
+
+
+(eval "as_func_return () {
+ (exit \$1)
+}
+as_func_success () {
+ as_func_return 0
+}
+as_func_failure () {
+ as_func_return 1
+}
+as_func_ret_success () {
+ return 0
+}
+as_func_ret_failure () {
+ return 1
+}
+
+exitcode=0
+if as_func_success; then
+ :
+else
+ exitcode=1
+ echo as_func_success failed.
+fi
+
+if as_func_failure; then
+ exitcode=1
+ echo as_func_failure succeeded.
+fi
+
+if as_func_ret_success; then
+ :
+else
+ exitcode=1
+ echo as_func_ret_success failed.
+fi
+
+if as_func_ret_failure; then
+ exitcode=1
+ echo as_func_ret_failure succeeded.
+fi
+
+if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
+ :
+else
+ exitcode=1
+ echo positional parameters were not saved.
+fi
+
+test \$exitcode = 0") || {
+ echo No shell found that supports shell functions.
+ echo Please tell autoconf@gnu.org about your system,
+ echo including any error possibly output before this
+ echo message
+}
+
+
+
+ as_lineno_1=$LINENO
+ as_lineno_2=$LINENO
+ test "x$as_lineno_1" != "x$as_lineno_2" &&
+ test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
# Create $as_me.lineno as a copy of $as_myself, but with $LINENO
# uniformly replaced by the line number. The first 'sed' inserts a
- # line-number line before each line; the second 'sed' does the real
- # work. The second script uses 'N' to pair each line-number line
- # with the numbered line, and appends trailing '-' during
- # substitution so that $LINENO is not a special case at line end.
+ # line-number line after each line using $LINENO; the second 'sed'
+ # does the real work. The second script uses 'N' to pair each
+ # line-number line with the line containing $LINENO, and appends
+ # trailing '-' during substitution so that $LINENO is not a special
+ # case at line end.
# (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
- # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
- sed '=' <$as_myself |
+ # scripts with optimization help from Paolo Bonzini. Blame Lee
+ # E. McMahon (1931-1989) for sed's syntax. :-)
+ sed -n '
+ p
+ /[$]LINENO/=
+ ' <$as_myself |
sed '
+ s/[$]LINENO.*/&-/
+ t lineno
+ b
+ :lineno
N
- s,$,-,
- : loop
- s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
+ :loop
+ s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
t loop
- s,-$,,
- s,^['$as_cr_digits']*\n,,
+ s/-\n.*//
' >$as_me.lineno &&
- chmod +x $as_me.lineno ||
+ chmod +x "$as_me.lineno" ||
{ echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
{ (exit 1); exit 1; }; }
# Don't try to exec as it changes $[0], causing all sort of problems
# (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensible to this).
- . ./$as_me.lineno
+ # original and so on. Autoconf is especially sensitive to this).
+ . "./$as_me.lineno"
# Exit status is that of the last command.
exit
}
-case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
- *c*,-n*) ECHO_N= ECHO_C='
-' ECHO_T=' ' ;;
- *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
- *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
+if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
+ as_dirname=dirname
+else
+ as_dirname=false
+fi
+
+ECHO_C= ECHO_N= ECHO_T=
+case `echo -n x` in
+-n*)
+ case `echo 'x\c'` in
+ *c*) ECHO_T=' ';; # ECHO_T is single tab character.
+ *) ECHO_C='\c';;
+ esac;;
+*)
+ ECHO_N='-n';;
esac
-if expr a : '\(a\)' >/dev/null 2>&1; then
+if expr a : '\(a\)' >/dev/null 2>&1 &&
+ test "X`expr 00001 : '.*\(...\)'`" = X001; then
as_expr=expr
else
as_expr=false
fi
rm -f conf$$ conf$$.exe conf$$.file
+if test -d conf$$.dir; then
+ rm -f conf$$.dir/conf$$.file
+else
+ rm -f conf$$.dir
+ mkdir conf$$.dir
+fi
echo >conf$$.file
if ln -s conf$$.file conf$$ 2>/dev/null; then
- # We could just check for DJGPP; but this test a) works b) is more generic
- # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
- if test -f conf$$.exe; then
- # Don't use ln at all; we don't have any links
+ as_ln_s='ln -s'
+ # ... but there are two gotchas:
+ # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
+ # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
+ # In both cases, we have to default to `cp -p'.
+ ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
as_ln_s='cp -p'
- else
- as_ln_s='ln -s'
- fi
elif ln conf$$.file conf$$ 2>/dev/null; then
as_ln_s=ln
else
as_ln_s='cp -p'
fi
-rm -f conf$$ conf$$.exe conf$$.file
+rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
+rmdir conf$$.dir 2>/dev/null
if mkdir -p . 2>/dev/null; then
as_mkdir_p=:
@@ -225,7 +521,28 @@ else
as_mkdir_p=false
fi
-as_executable_p="test -f"
+if test -x / >/dev/null 2>&1; then
+ as_test_x='test -x'
+else
+ if ls -dL / >/dev/null 2>&1; then
+ as_ls_L_option=L
+ else
+ as_ls_L_option=
+ fi
+ as_test_x='
+ eval sh -c '\''
+ if test -d "$1"; then
+ test -d "$1/.";
+ else
+ case $1 in
+ -*)set "./$1";;
+ esac;
+ case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
+ ???[sx]*):;;*)false;;esac;fi
+ '\'' sh
+ '
+fi
+as_executable_p=$as_test_x
# Sed expression to map a string onto a valid CPP name.
as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
@@ -234,39 +551,27 @@ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-# IFS
-# We need space, tab and new line, in precisely that order.
-as_nl='
-'
-IFS=" $as_nl"
-
-# CDPATH.
-$as_unset CDPATH
+exec 7<&0 </dev/null 6>&1
# Name of the host.
# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
# so uname gets run too.
ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-exec 6>&1
-
#
# Initializations.
#
ac_default_prefix=/usr/local
+ac_clean_files=
ac_config_libobj_dir=.
+LIBOBJS=
cross_compiling=no
subdirs=
MFLAGS=
MAKEFLAGS=
SHELL=${CONFIG_SHELL-/bin/sh}
-# Maximum number of lines to put in a shell here document.
-# This variable seems obsolete. It should probably be removed, and
-# only ac_max_sed_lines should be used.
-: ${ac_max_here_lines=38}
-
# Identity of this package.
PACKAGE_NAME='GNU C Library'
PACKAGE_TARNAME='c-library'
@@ -275,46 +580,208 @@ PACKAGE_STRING='GNU C Library (see version.h)'
PACKAGE_BUGREPORT='glibc'
ac_unique_file="include/features.h"
-ac_subdirs_all="$ac_subdirs_all "
# Factoring default headers for most tests.
ac_includes_default="\
#include <stdio.h>
-#if HAVE_SYS_TYPES_H
+#ifdef HAVE_SYS_TYPES_H
# include <sys/types.h>
#endif
-#if HAVE_SYS_STAT_H
+#ifdef HAVE_SYS_STAT_H
# include <sys/stat.h>
#endif
-#if STDC_HEADERS
+#ifdef STDC_HEADERS
# include <stdlib.h>
# include <stddef.h>
#else
-# if HAVE_STDLIB_H
+# ifdef HAVE_STDLIB_H
# include <stdlib.h>
# endif
#endif
-#if HAVE_STRING_H
-# if !STDC_HEADERS && HAVE_MEMORY_H
+#ifdef HAVE_STRING_H
+# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
# include <memory.h>
# endif
# include <string.h>
#endif
-#if HAVE_STRINGS_H
+#ifdef HAVE_STRINGS_H
# include <strings.h>
#endif
-#if HAVE_INTTYPES_H
+#ifdef HAVE_INTTYPES_H
# include <inttypes.h>
-#else
-# if HAVE_STDINT_H
-# include <stdint.h>
-# endif
#endif
-#if HAVE_UNISTD_H
+#ifdef HAVE_STDINT_H
+# include <stdint.h>
+#endif
+#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS with_fp with_cvs enable_check_abi oldest_abi bindnow force_install all_warnings libc_cv_cc_with_decimal_float build build_cpu build_vendor build_os host host_cpu host_vendor host_os subdirs add_ons add_on_subdirs base_machine submachine sysnames sysdeps_add_ons INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC OBJEXT BUILD_CC cross_compiling CPP CXX CXXFLAGS ac_ct_CXX AR NM OBJDUMP RANLIB ac_ct_RANLIB MIG AS LD PWD_P MAKE MSGFMT MAKEINFO SED AUTOCONF SYSINCLUDES CXX_SYSINCLUDES libc_cv_gcc_static_libgcc BASH_SHELL libc_cv_have_bash2 KSH libc_cv_have_ksh AWK PERL INSTALL_INFO BISON VERSIONING libc_cv_cc_with_libunwind libc_cv_Bgroup libc_cv_libgcc_s_suffix libc_cv_as_needed ASFLAGS_config libc_cv_z_combreloc libc_cv_z_execstack libc_cv_fpie libc_cv_hashstyle fno_unit_at_a_time libc_cv_ssp libc_cv_gnu89_inline libc_cv_have_initfini no_whole_archive exceptions LIBGD have_libaudit have_libcap have_selinux EGREP sizeof_long_double libc_cv_gcc_unwind_find_fde uname_sysname uname_release uname_version old_glibc_headers libc_cv_slibdir libc_cv_localedir libc_cv_sysconfdir libc_cv_rootsbindir libc_cv_forced_unwind use_ldconfig ldd_rewrite_script elf xcoff static shared pic_default profile omitfp bounded static_nss nopic_initfini DEFINES mach_interface_list VERSION RELEASE LIBOBJS LTLIBOBJS'
+ac_subst_vars='SHELL
+PATH_SEPARATOR
+PACKAGE_NAME
+PACKAGE_TARNAME
+PACKAGE_VERSION
+PACKAGE_STRING
+PACKAGE_BUGREPORT
+exec_prefix
+prefix
+program_transform_name
+bindir
+sbindir
+libexecdir
+datarootdir
+datadir
+sysconfdir
+sharedstatedir
+localstatedir
+includedir
+oldincludedir
+docdir
+infodir
+htmldir
+dvidir
+pdfdir
+psdir
+libdir
+localedir
+mandir
+DEFS
+ECHO_C
+ECHO_N
+ECHO_T
+LIBS
+build_alias
+host_alias
+target_alias
+with_fp
+with_cvs
+enable_check_abi
+oldest_abi
+bindnow
+force_install
+all_warnings
+libc_cv_cc_with_decimal_float
+build
+build_cpu
+build_vendor
+build_os
+host
+host_cpu
+host_vendor
+host_os
+subdirs
+add_ons
+add_on_subdirs
+base_machine
+submachine
+sysnames
+sysdeps_add_ons
+INSTALL_PROGRAM
+INSTALL_SCRIPT
+INSTALL_DATA
+LN_S
+CC
+CFLAGS
+LDFLAGS
+CPPFLAGS
+ac_ct_CC
+OBJEXT
+BUILD_CC
+cross_compiling
+CPP
+CXX
+CXXFLAGS
+ac_ct_CXX
+AR
+NM
+OBJDUMP
+RANLIB
+MIG
+AS
+LD
+PWD_P
+MAKE
+MSGFMT
+MAKEINFO
+SED
+AUTOCONF
+SYSINCLUDES
+CXX_SYSINCLUDES
+libc_cv_gcc_static_libgcc
+BASH_SHELL
+libc_cv_have_bash2
+KSH
+libc_cv_have_ksh
+AWK
+PERL
+INSTALL_INFO
+BISON
+VERSIONING
+libc_cv_cc_with_libunwind
+libc_cv_Bgroup
+libc_cv_libgcc_s_suffix
+libc_cv_as_needed
+ASFLAGS_config
+libc_cv_z_combreloc
+libc_cv_z_execstack
+libc_cv_fpie
+libc_cv_hashstyle
+fno_unit_at_a_time
+libc_cv_ssp
+libc_cv_gnu89_inline
+libc_cv_have_initfini
+no_whole_archive
+exceptions
+libc_cv_cc_submachine
+LIBGD
+have_libaudit
+have_libcap
+have_selinux
+GREP
+EGREP
+sizeof_long_double
+libc_cv_gcc_unwind_find_fde
+uname_sysname
+uname_release
+uname_version
+old_glibc_headers
+libc_cv_slibdir
+libc_cv_localedir
+libc_cv_sysconfdir
+libc_cv_rootsbindir
+libc_cv_forced_unwind
+use_ldconfig
+ldd_rewrite_script
+elf
+xcoff
+static
+shared
+pic_default
+profile
+omitfp
+bounded
+static_nss
+nopic_initfini
+DEFINES
+mach_interface_list
+VERSION
+RELEASE
+LIBOBJS
+LTLIBOBJS'
ac_subst_files=''
+ ac_precious_vars='build_alias
+host_alias
+target_alias
+CC
+CFLAGS
+LDFLAGS
+LIBS
+CPPFLAGS
+CPP
+CXX
+CXXFLAGS
+CCC'
+ac_subdirs_all=''
# Initialize some variables set by options.
ac_init_help=
@@ -341,34 +808,48 @@ x_libraries=NONE
# and all the variables that are supposed to be based on exec_prefix
# by default will actually change.
# Use braces instead of parens because sh, perl, etc. also accept them.
+# (The list follows the same order as the GNU Coding Standards.)
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
-datadir='${prefix}/share'
+datarootdir='${prefix}/share'
+datadir='${datarootdir}'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
-libdir='${exec_prefix}/lib'
includedir='${prefix}/include'
oldincludedir='/usr/include'
-infodir='${prefix}/info'
-mandir='${prefix}/man'
+docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
+infodir='${datarootdir}/info'
+htmldir='${docdir}'
+dvidir='${docdir}'
+pdfdir='${docdir}'
+psdir='${docdir}'
+libdir='${exec_prefix}/lib'
+localedir='${datarootdir}/locale'
+mandir='${datarootdir}/man'
ac_prev=
+ac_dashdash=
for ac_option
do
# If the previous option needs an argument, assign it.
if test -n "$ac_prev"; then
- eval "$ac_prev=\$ac_option"
+ eval $ac_prev=\$ac_option
ac_prev=
continue
fi
- ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
+ case $ac_option in
+ *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
+ *) ac_optarg=yes ;;
+ esac
# Accept the important Cygnus configure options, so we can diagnose typos.
- case $ac_option in
+ case $ac_dashdash$ac_option in
+ --)
+ ac_dashdash=yes ;;
-bindir | --bindir | --bindi | --bind | --bin | --bi)
ac_prev=bindir ;;
@@ -390,33 +871,45 @@ do
--config-cache | -C)
cache_file=config.cache ;;
- -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
+ -datadir | --datadir | --datadi | --datad)
ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
- | --da=*)
+ -datadir=* | --datadir=* | --datadi=* | --datad=*)
datadir=$ac_optarg ;;
+ -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
+ | --dataroo | --dataro | --datar)
+ ac_prev=datarootdir ;;
+ -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
+ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
+ datarootdir=$ac_optarg ;;
+
-disable-* | --disable-*)
ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
# Reject names that are not valid shell variable names.
- expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
+ expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
{ echo "$as_me: error: invalid feature name: $ac_feature" >&2
{ (exit 1); exit 1; }; }
- ac_feature=`echo $ac_feature | sed 's/-/_/g'`
- eval "enable_$ac_feature=no" ;;
+ ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
+ eval enable_$ac_feature=no ;;
+
+ -docdir | --docdir | --docdi | --doc | --do)
+ ac_prev=docdir ;;
+ -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
+ docdir=$ac_optarg ;;
+
+ -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
+ ac_prev=dvidir ;;
+ -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
+ dvidir=$ac_optarg ;;
-enable-* | --enable-*)
ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
# Reject names that are not valid shell variable names.
- expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
+ expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
{ echo "$as_me: error: invalid feature name: $ac_feature" >&2
{ (exit 1); exit 1; }; }
- ac_feature=`echo $ac_feature | sed 's/-/_/g'`
- case $ac_option in
- *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
- *) ac_optarg=yes ;;
- esac
- eval "enable_$ac_feature='$ac_optarg'" ;;
+ ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
+ eval enable_$ac_feature=\$ac_optarg ;;
-exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
| --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
@@ -443,6 +936,12 @@ do
-host=* | --host=* | --hos=* | --ho=*)
host_alias=$ac_optarg ;;
+ -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
+ ac_prev=htmldir ;;
+ -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
+ | --ht=*)
+ htmldir=$ac_optarg ;;
+
-includedir | --includedir | --includedi | --included | --include \
| --includ | --inclu | --incl | --inc)
ac_prev=includedir ;;
@@ -467,13 +966,16 @@ do
| --libexe=* | --libex=* | --libe=*)
libexecdir=$ac_optarg ;;
+ -localedir | --localedir | --localedi | --localed | --locale)
+ ac_prev=localedir ;;
+ -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
+ localedir=$ac_optarg ;;
+
-localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst \
- | --locals | --local | --loca | --loc | --lo)
+ | --localstate | --localstat | --localsta | --localst | --locals)
ac_prev=localstatedir ;;
-localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* \
- | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
+ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
localstatedir=$ac_optarg ;;
-mandir | --mandir | --mandi | --mand | --man | --ma | --m)
@@ -538,6 +1040,16 @@ do
| --progr-tra=* | --program-tr=* | --program-t=*)
program_transform_name=$ac_optarg ;;
+ -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
+ ac_prev=pdfdir ;;
+ -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
+ pdfdir=$ac_optarg ;;
+
+ -psdir | --psdir | --psdi | --psd | --ps)
+ ac_prev=psdir ;;
+ -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
+ psdir=$ac_optarg ;;
+
-q | -quiet | --quiet | --quie | --qui | --qu | --q \
| -silent | --silent | --silen | --sile | --sil)
silent=yes ;;
@@ -590,24 +1102,20 @@ do
-with-* | --with-*)
ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
# Reject names that are not valid shell variable names.
- expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
+ expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
{ echo "$as_me: error: invalid package name: $ac_package" >&2
{ (exit 1); exit 1; }; }
- ac_package=`echo $ac_package| sed 's/-/_/g'`
- case $ac_option in
- *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
- *) ac_optarg=yes ;;
- esac
- eval "with_$ac_package='$ac_optarg'" ;;
+ ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
+ eval with_$ac_package=\$ac_optarg ;;
-without-* | --without-*)
ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
# Reject names that are not valid shell variable names.
- expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
+ expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
{ echo "$as_me: error: invalid package name: $ac_package" >&2
{ (exit 1); exit 1; }; }
- ac_package=`echo $ac_package | sed 's/-/_/g'`
- eval "with_$ac_package=no" ;;
+ ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
+ eval with_$ac_package=no ;;
--x)
# Obsolete; use --with-x.
@@ -638,8 +1146,7 @@ Try \`$0 --help' for more information." >&2
expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
{ echo "$as_me: error: invalid variable name: $ac_envvar" >&2
{ (exit 1); exit 1; }; }
- ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
- eval "$ac_envvar='$ac_optarg'"
+ eval $ac_envvar=\$ac_optarg
export $ac_envvar ;;
*)
@@ -659,27 +1166,19 @@ if test -n "$ac_prev"; then
{ (exit 1); exit 1; }; }
fi
-# Be sure to have absolute paths.
-for ac_var in exec_prefix prefix
+# Be sure to have absolute directory names.
+for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
+ datadir sysconfdir sharedstatedir localstatedir includedir \
+ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
+ libdir localedir mandir
do
- eval ac_val=$`echo $ac_var`
+ eval ac_val=\$$ac_var
case $ac_val in
- [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
- *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
- { (exit 1); exit 1; }; };;
- esac
-done
-
-# Be sure to have absolute paths.
-for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
- localstatedir libdir includedir oldincludedir infodir mandir
-do
- eval ac_val=$`echo $ac_var`
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) ;;
- *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
- { (exit 1); exit 1; }; };;
+ [\\/$]* | ?:[\\/]* ) continue;;
+ NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
esac
+ { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
+ { (exit 1); exit 1; }; }
done
# There might be people who depend on the old broken behavior: `$host'
@@ -706,82 +1205,76 @@ test -n "$host_alias" && ac_tool_prefix=$host_alias-
test "$silent" = yes && exec 6>/dev/null
+ac_pwd=`pwd` && test -n "$ac_pwd" &&
+ac_ls_di=`ls -di .` &&
+ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
+ { echo "$as_me: error: Working directory cannot be determined" >&2
+ { (exit 1); exit 1; }; }
+test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
+ { echo "$as_me: error: pwd does not report name of working directory" >&2
+ { (exit 1); exit 1; }; }
+
+
# Find the source files, if location was not specified.
if test -z "$srcdir"; then
ac_srcdir_defaulted=yes
- # Try the directory containing this script, then its parent.
- ac_confdir=`(dirname "$0") 2>/dev/null ||
+ # Try the directory containing this script, then the parent directory.
+ ac_confdir=`$as_dirname -- "$0" ||
$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$0" : 'X\(//\)[^/]' \| \
X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
+ X"$0" : 'X\(/\)' \| . 2>/dev/null ||
echo X"$0" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+ s//\1/
+ q
+ }
+ /^X\(\/\/\)[^/].*/{
+ s//\1/
+ q
+ }
+ /^X\(\/\/\)$/{
+ s//\1/
+ q
+ }
+ /^X\(\/\).*/{
+ s//\1/
+ q
+ }
+ s/.*/./; q'`
srcdir=$ac_confdir
- if test ! -r $srcdir/$ac_unique_file; then
+ if test ! -r "$srcdir/$ac_unique_file"; then
srcdir=..
fi
else
ac_srcdir_defaulted=no
fi
-if test ! -r $srcdir/$ac_unique_file; then
- if test "$ac_srcdir_defaulted" = yes; then
- { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
- { (exit 1); exit 1; }; }
- else
- { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
+if test ! -r "$srcdir/$ac_unique_file"; then
+ test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
+ { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
{ (exit 1); exit 1; }; }
- fi
fi
-(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
- { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
+ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
+ac_abs_confdir=`(
+ cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2
{ (exit 1); exit 1; }; }
-srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
-ac_env_build_alias_set=${build_alias+set}
-ac_env_build_alias_value=$build_alias
-ac_cv_env_build_alias_set=${build_alias+set}
-ac_cv_env_build_alias_value=$build_alias
-ac_env_host_alias_set=${host_alias+set}
-ac_env_host_alias_value=$host_alias
-ac_cv_env_host_alias_set=${host_alias+set}
-ac_cv_env_host_alias_value=$host_alias
-ac_env_target_alias_set=${target_alias+set}
-ac_env_target_alias_value=$target_alias
-ac_cv_env_target_alias_set=${target_alias+set}
-ac_cv_env_target_alias_value=$target_alias
-ac_env_CC_set=${CC+set}
-ac_env_CC_value=$CC
-ac_cv_env_CC_set=${CC+set}
-ac_cv_env_CC_value=$CC
-ac_env_CFLAGS_set=${CFLAGS+set}
-ac_env_CFLAGS_value=$CFLAGS
-ac_cv_env_CFLAGS_set=${CFLAGS+set}
-ac_cv_env_CFLAGS_value=$CFLAGS
-ac_env_LDFLAGS_set=${LDFLAGS+set}
-ac_env_LDFLAGS_value=$LDFLAGS
-ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
-ac_cv_env_LDFLAGS_value=$LDFLAGS
-ac_env_CPPFLAGS_set=${CPPFLAGS+set}
-ac_env_CPPFLAGS_value=$CPPFLAGS
-ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
-ac_cv_env_CPPFLAGS_value=$CPPFLAGS
-ac_env_CPP_set=${CPP+set}
-ac_env_CPP_value=$CPP
-ac_cv_env_CPP_set=${CPP+set}
-ac_cv_env_CPP_value=$CPP
-ac_env_CXX_set=${CXX+set}
-ac_env_CXX_value=$CXX
-ac_cv_env_CXX_set=${CXX+set}
-ac_cv_env_CXX_value=$CXX
-ac_env_CXXFLAGS_set=${CXXFLAGS+set}
-ac_env_CXXFLAGS_value=$CXXFLAGS
-ac_cv_env_CXXFLAGS_set=${CXXFLAGS+set}
-ac_cv_env_CXXFLAGS_value=$CXXFLAGS
+ pwd)`
+# When building in place, set srcdir=.
+if test "$ac_abs_confdir" = "$ac_pwd"; then
+ srcdir=.
+fi
+# Remove unnecessary trailing slashes from srcdir.
+# Double slashes in file names in object file debugging info
+# mess up M-x gdb in Emacs.
+case $srcdir in
+*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
+esac
+for ac_var in $ac_precious_vars; do
+ eval ac_env_${ac_var}_set=\${${ac_var}+set}
+ eval ac_env_${ac_var}_value=\$${ac_var}
+ eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
+ eval ac_cv_env_${ac_var}_value=\$${ac_var}
+done
#
# Report the --help message.
@@ -810,9 +1303,6 @@ Configuration:
-n, --no-create do not create output files
--srcdir=DIR find the sources in DIR [configure dir or \`..']
-_ACEOF
-
- cat <<_ACEOF
Installation directories:
--prefix=PREFIX install architecture-independent files in PREFIX
[$ac_default_prefix]
@@ -830,15 +1320,22 @@ Fine tuning of the installation directories:
--bindir=DIR user executables [EPREFIX/bin]
--sbindir=DIR system admin executables [EPREFIX/sbin]
--libexecdir=DIR program executables [EPREFIX/libexec]
- --datadir=DIR read-only architecture-independent data [PREFIX/share]
--sysconfdir=DIR read-only single-machine data [PREFIX/etc]
--sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
--localstatedir=DIR modifiable single-machine data [PREFIX/var]
--libdir=DIR object code libraries [EPREFIX/lib]
--includedir=DIR C header files [PREFIX/include]
--oldincludedir=DIR C header files for non-gcc [/usr/include]
- --infodir=DIR info documentation [PREFIX/info]
- --mandir=DIR man documentation [PREFIX/man]
+ --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
+ --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
+ --infodir=DIR info documentation [DATAROOTDIR/info]
+ --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
+ --mandir=DIR man documentation [DATAROOTDIR/man]
+ --docdir=DIR documentation root [DATAROOTDIR/doc/c-library]
+ --htmldir=DIR html documentation [DOCDIR]
+ --dvidir=DIR dvi documentation [DOCDIR]
+ --pdfdir=DIR pdf documentation [DOCDIR]
+ --psdir=DIR ps documentation [DOCDIR]
_ACEOF
cat <<\_ACEOF
@@ -862,13 +1359,10 @@ Optional Features:
in special situations) [default=yes]
--enable-check-abi do "make check-abi" in "make check" (no/warn/yes)
[default=no]
- --enable-shared build shared library [default=yes if GNU ld &
- ELF]
+ --enable-shared build shared library [default=yes if GNU ld & ELF]
--enable-profile build profiled library [default=no]
- --enable-omitfp build undebuggable optimized library
- [default=no]
- --enable-bounded build with runtime bounds checking
- [default=no]
+ --enable-omitfp build undebuggable optimized library [default=no]
+ --enable-bounded build with runtime bounds checking [default=no]
--disable-versioning do not include versioning information in the library
objects [default=yes if supported]
--enable-oldest-abi=ABI configure the oldest ABI supported [e.g. 2.2]
@@ -887,6 +1381,7 @@ Optional Features:
--enable-kernel=VERSION compile for compatibility with kernel not older than
VERSION
--enable-all-warnings enable all useful warnings gcc can issue
+ --enable-decimal-float enable support for decimal floating point.
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
@@ -901,11 +1396,9 @@ Optional Packages:
--with-xcoff if using the XCOFF object format
--without-cvs if CVS should not be used
--with-headers=PATH location of system headers to use (for example
- /usr/src/linux/include) [default=compiler
- default]
+ /usr/src/linux/include) [default=compiler default]
--with-tls enable support for TLS
--without-__thread do not use TLS features even when supporting them
- --decimal-float enable support for decimal floating point.
--with-cpu=CPU select code for CPU variant
Some influential environment variables:
@@ -913,8 +1406,9 @@ Some influential environment variables:
CFLAGS C compiler flags
LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
nonstandard directory <lib dir>
- CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
- headers in a nonstandard directory <include dir>
+ LIBS libraries to pass to the linker, e.g. -l<library>
+ CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
+ you have headers in a nonstandard directory <include dir>
CPP C preprocessor
CXX C++ compiler command
CXXFLAGS C++ compiler flags
@@ -924,120 +1418,86 @@ it to find libraries and programs with nonstandard names/locations.
Report bugs to <glibc>.
_ACEOF
+ac_status=$?
fi
if test "$ac_init_help" = "recursive"; then
# If there are subdirs, report their specific --help.
- ac_popdir=`pwd`
for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d $ac_dir || continue
+ test -d "$ac_dir" || continue
ac_builddir=.
-if test "$ac_dir" != .; then
+case "$ac_dir" in
+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
+*)
ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
- # A "../" for each directory in $ac_dir_suffix.
- ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
- ac_dir_suffix= ac_top_builddir=
-fi
+ # A ".." for each directory in $ac_dir_suffix.
+ ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
+ case $ac_top_builddir_sub in
+ "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
+ *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
+ esac ;;
+esac
+ac_abs_top_builddir=$ac_pwd
+ac_abs_builddir=$ac_pwd$ac_dir_suffix
+# for backward compatibility:
+ac_top_builddir=$ac_top_build_prefix
case $srcdir in
- .) # No --srcdir option. We are building in place.
+ .) # We are building in place.
ac_srcdir=.
- if test -z "$ac_top_builddir"; then
- ac_top_srcdir=.
- else
- ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
- fi ;;
- [\\/]* | ?:[\\/]* ) # Absolute path.
+ ac_top_srcdir=$ac_top_builddir_sub
+ ac_abs_top_srcdir=$ac_pwd ;;
+ [\\/]* | ?:[\\/]* ) # Absolute name.
ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir ;;
- *) # Relative path.
- ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_builddir$srcdir ;;
-esac
-
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
- case "$ac_dir" in
- .) ac_abs_builddir=`pwd`;;
- [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
- *) ac_abs_builddir=`pwd`/"$ac_dir";;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
- case ${ac_top_builddir}. in
- .) ac_abs_top_builddir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
- *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
- case $ac_srcdir in
- .) ac_abs_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
- *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
- case $ac_top_srcdir in
- .) ac_abs_top_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
- *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
- esac;;
+ ac_top_srcdir=$srcdir
+ ac_abs_top_srcdir=$srcdir ;;
+ *) # Relative name.
+ ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
+ ac_top_srcdir=$ac_top_build_prefix$srcdir
+ ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
esac
-
- cd $ac_dir
- # Check for guested configure; otherwise get Cygnus style configure.
- if test -f $ac_srcdir/configure.gnu; then
- echo
- $SHELL $ac_srcdir/configure.gnu --help=recursive
- elif test -f $ac_srcdir/configure; then
- echo
- $SHELL $ac_srcdir/configure --help=recursive
- elif test -f $ac_srcdir/configure.ac ||
- test -f $ac_srcdir/configure.in; then
- echo
- $ac_configure --help
+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
+
+ cd "$ac_dir" || { ac_status=$?; continue; }
+ # Check for guested configure.
+ if test -f "$ac_srcdir/configure.gnu"; then
+ echo &&
+ $SHELL "$ac_srcdir/configure.gnu" --help=recursive
+ elif test -f "$ac_srcdir/configure"; then
+ echo &&
+ $SHELL "$ac_srcdir/configure" --help=recursive
else
echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi
- cd $ac_popdir
+ fi || ac_status=$?
+ cd "$ac_pwd" || { ac_status=$?; break; }
done
fi
-test -n "$ac_init_help" && exit 0
+test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
GNU C Library configure (see version.h)
-generated by GNU Autoconf 2.59
+generated by GNU Autoconf 2.61
-Copyright (C) 2003 Free Software Foundation, Inc.
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
+2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
_ACEOF
- exit 0
+ exit
fi
-exec 5>config.log
-cat >&5 <<_ACEOF
+cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by GNU C Library $as_me (see version.h), which was
-generated by GNU Autoconf 2.59. Invocation command line was
+generated by GNU Autoconf 2.61. Invocation command line was
$ $0 $@
_ACEOF
+exec 5>>config.log
{
cat <<_ASUNAME
## --------- ##
@@ -1056,7 +1516,7 @@ uname -v = `(uname -v) 2>/dev/null || echo unknown`
/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
+/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
@@ -1070,6 +1530,7 @@ do
test -z "$as_dir" && as_dir=.
echo "PATH: $as_dir"
done
+IFS=$as_save_IFS
} >&5
@@ -1091,7 +1552,6 @@ _ACEOF
ac_configure_args=
ac_configure_args0=
ac_configure_args1=
-ac_sep=
ac_must_keep_next=false
for ac_pass in 1 2
do
@@ -1102,7 +1562,7 @@ do
-q | -quiet | --quiet | --quie | --qui | --qu | --q \
| -silent | --silent | --silen | --sile | --sil)
continue ;;
- *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
+ *\'*)
ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
esac
case $ac_pass in
@@ -1124,9 +1584,7 @@ do
-* ) ac_must_keep_next=true ;;
esac
fi
- ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
- # Get rid of the leading space.
- ac_sep=" "
+ ac_configure_args="$ac_configure_args '$ac_arg'"
;;
esac
done
@@ -1137,8 +1595,8 @@ $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_
# When interrupted or exit'd, cleanup temporary files, and complete
# config.log. We remove comments because anyway the quotes in there
# would cause problems or look ugly.
-# WARNING: Be sure not to use single quotes in there, as some shells,
-# such as our DU 5.0 friend, will then `close' the trap.
+# WARNING: Use '\'' to represent an apostrophe within the trap.
+# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
trap 'exit_status=$?
# Save into config.log some information that might help in debugging.
{
@@ -1151,20 +1609,34 @@ trap 'exit_status=$?
_ASBOX
echo
# The following way of writing the cache mishandles newlines in values,
-{
+(
+ for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
+ eval ac_val=\$$ac_var
+ case $ac_val in #(
+ *${as_nl}*)
+ case $ac_var in #(
+ *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
+echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
+ esac
+ case $ac_var in #(
+ _ | IFS | as_nl) ;; #(
+ *) $as_unset $ac_var ;;
+ esac ;;
+ esac
+ done
(set) 2>&1 |
- case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
- *ac_space=\ *)
+ case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
+ *${as_nl}ac_space=\ *)
sed -n \
- "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
- ;;
+ "s/'\''/'\''\\\\'\'''\''/g;
+ s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
+ ;; #(
*)
- sed -n \
- "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
+ sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
;;
- esac;
-}
+ esac |
+ sort
+)
echo
cat <<\_ASBOX
@@ -1175,22 +1647,28 @@ _ASBOX
echo
for ac_var in $ac_subst_vars
do
- eval ac_val=$`echo $ac_var`
- echo "$ac_var='"'"'$ac_val'"'"'"
+ eval ac_val=\$$ac_var
+ case $ac_val in
+ *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
+ esac
+ echo "$ac_var='\''$ac_val'\''"
done | sort
echo
if test -n "$ac_subst_files"; then
cat <<\_ASBOX
-## ------------- ##
-## Output files. ##
-## ------------- ##
+## ------------------- ##
+## File substitutions. ##
+## ------------------- ##
_ASBOX
echo
for ac_var in $ac_subst_files
do
- eval ac_val=$`echo $ac_var`
- echo "$ac_var='"'"'$ac_val'"'"'"
+ eval ac_val=\$$ac_var
+ case $ac_val in
+ *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
+ esac
+ echo "$ac_var='\''$ac_val'\''"
done | sort
echo
fi
@@ -1202,26 +1680,24 @@ _ASBOX
## ----------- ##
_ASBOX
echo
- sed "/^$/d" confdefs.h | sort
+ cat confdefs.h
echo
fi
test "$ac_signal" != 0 &&
echo "$as_me: caught signal $ac_signal"
echo "$as_me: exit $exit_status"
} >&5
- rm -f core *.core &&
- rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
+ rm -f core *.core core.conftest.* &&
+ rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
exit $exit_status
- ' 0
+' 0
for ac_signal in 1 2 13 15; do
trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
done
ac_signal=0
# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo >confdefs.h
+rm -f -r conftest* confdefs.h
# Predefined preprocessor variables.
@@ -1252,14 +1728,17 @@ _ACEOF
# Let the site file select an alternate cache file if it wants to.
# Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
- fi
+if test -n "$CONFIG_SITE"; then
+ set x "$CONFIG_SITE"
+elif test "x$prefix" != xNONE; then
+ set x "$prefix/share/config.site" "$prefix/etc/config.site"
+else
+ set x "$ac_default_prefix/share/config.site" \
+ "$ac_default_prefix/etc/config.site"
fi
-for ac_site_file in $CONFIG_SITE; do
+shift
+for ac_site_file
+do
if test -r "$ac_site_file"; then
{ echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
echo "$as_me: loading site script $ac_site_file" >&6;}
@@ -1275,8 +1754,8 @@ if test -r "$cache_file"; then
{ echo "$as_me:$LINENO: loading cache $cache_file" >&5
echo "$as_me: loading cache $cache_file" >&6;}
case $cache_file in
- [\\/]* | ?:[\\/]* ) . $cache_file;;
- *) . ./$cache_file;;
+ [\\/]* | ?:[\\/]* ) . "$cache_file";;
+ *) . "./$cache_file";;
esac
fi
else
@@ -1288,12 +1767,11 @@ fi
# Check that the precious variables saved in the cache have kept the same
# value.
ac_cache_corrupted=false
-for ac_var in `(set) 2>&1 |
- sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
+for ac_var in $ac_precious_vars; do
eval ac_old_set=\$ac_cv_env_${ac_var}_set
eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val="\$ac_cv_env_${ac_var}_value"
- eval ac_new_val="\$ac_env_${ac_var}_value"
+ eval ac_old_val=\$ac_cv_env_${ac_var}_value
+ eval ac_new_val=\$ac_env_${ac_var}_value
case $ac_old_set,$ac_new_set in
set,)
{ echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
@@ -1318,8 +1796,7 @@ echo "$as_me: current value: $ac_new_val" >&2;}
# Pass precious variables to config.status.
if test "$ac_new_set" = set; then
case $ac_new_val in
- *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
- ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
+ *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
*) ac_arg=$ac_var=$ac_new_val ;;
esac
case " $ac_configure_args " in
@@ -1336,12 +1813,6 @@ echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start ov
{ (exit 1); exit 1; }; }
fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
@@ -1366,35 +1837,46 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
- ac_config_headers="$ac_config_headers config.h"
+ac_config_headers="$ac_config_headers config.h"
ac_aux_dir=
-for ac_dir in scripts $srcdir/scripts; do
- if test -f $ac_dir/install-sh; then
+for ac_dir in scripts "$srcdir"/scripts; do
+ if test -f "$ac_dir/install-sh"; then
ac_aux_dir=$ac_dir
ac_install_sh="$ac_aux_dir/install-sh -c"
break
- elif test -f $ac_dir/install.sh; then
+ elif test -f "$ac_dir/install.sh"; then
ac_aux_dir=$ac_dir
ac_install_sh="$ac_aux_dir/install.sh -c"
break
- elif test -f $ac_dir/shtool; then
+ elif test -f "$ac_dir/shtool"; then
ac_aux_dir=$ac_dir
ac_install_sh="$ac_aux_dir/shtool install -c"
break
fi
done
if test -z "$ac_aux_dir"; then
- { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in scripts $srcdir/scripts" >&5
-echo "$as_me: error: cannot find install-sh or install.sh in scripts $srcdir/scripts" >&2;}
+ { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in scripts \"$srcdir\"/scripts" >&5
+echo "$as_me: error: cannot find install-sh or install.sh in scripts \"$srcdir\"/scripts" >&2;}
{ (exit 1); exit 1; }; }
fi
-ac_config_guess="$SHELL $ac_aux_dir/config.guess"
-ac_config_sub="$SHELL $ac_aux_dir/config.sub"
-ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
+
+# These three variables are undocumented and unsupported,
+# and are intended to be withdrawn in a future Autoconf release.
+# They can cause serious problems if a builder's source tree is in a directory
+# whose full name contains unusual characters.
+ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
+ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
+ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
+
if test "`cd $srcdir; /bin/pwd`" = "`/bin/pwd`"; then
@@ -1408,36 +1890,36 @@ config_vars=
# Check for a --with-gd argument and set libgd-LDFLAGS in config.make.
-# Check whether --with-gd or --without-gd was given.
+# Check whether --with-gd was given.
if test "${with_gd+set}" = set; then
- withval="$with_gd"
- case "$with_gd" in
+ withval=$with_gd; case "$with_gd" in
yes|''|no) ;;
*) libgd_include="-I$withval/include"
libgd_ldflags="-L$withval/lib" ;;
esac
-fi;
+fi
+
-# Check whether --with-gd-include or --without-gd-include was given.
+# Check whether --with-gd-include was given.
if test "${with_gd_include+set}" = set; then
- withval="$with_gd_include"
- case "$with_gd_include" in
+ withval=$with_gd_include; case "$with_gd_include" in
''|no) ;;
*) libgd_include="-I$withval" ;;
esac
-fi;
+fi
+
-# Check whether --with-gd-lib or --without-gd-lib was given.
+# Check whether --with-gd-lib was given.
if test "${with_gd_lib+set}" = set; then
- withval="$with_gd_lib"
- case "$with_gd_lib" in
+ withval=$with_gd_lib; case "$with_gd_lib" in
''|no) ;;
*) libgd_ldflags="-L$withval" ;;
esac
-fi;
+fi
+
if test -n "$libgd_include"; then
config_vars="$config_vars
@@ -1449,54 +1931,54 @@ libgd-LDFLAGS = $libgd_ldflags"
fi
-# Check whether --with-fp or --without-fp was given.
+# Check whether --with-fp was given.
if test "${with_fp+set}" = set; then
- withval="$with_fp"
- with_fp=$withval
+ withval=$with_fp; with_fp=$withval
else
with_fp=yes
-fi;
+fi
-# Check whether --with-binutils or --without-binutils was given.
+
+# Check whether --with-binutils was given.
if test "${with_binutils+set}" = set; then
- withval="$with_binutils"
- path_binutils=$withval
+ withval=$with_binutils; path_binutils=$withval
else
path_binutils=''
-fi;
+fi
+
-# Check whether --with-elf or --without-elf was given.
+# Check whether --with-elf was given.
if test "${with_elf+set}" = set; then
- withval="$with_elf"
- elf=$withval
+ withval=$with_elf; elf=$withval
else
elf=no
-fi;
+fi
+
-# Check whether --with-selinux or --without-selinux was given.
+# Check whether --with-selinux was given.
if test "${with_selinux+set}" = set; then
- withval="$with_selinux"
- with_selinux=$withval
+ withval=$with_selinux; with_selinux=$withval
else
with_selinux=auto
-fi;
+fi
-# Check whether --with-xcoff or --without-xcoff was given.
+
+# Check whether --with-xcoff was given.
if test "${with_xcoff+set}" = set; then
- withval="$with_xcoff"
- xcoff=$withval
+ withval=$with_xcoff; xcoff=$withval
else
xcoff=no
-fi;
+fi
+
-# Check whether --with-cvs or --without-cvs was given.
+# Check whether --with-cvs was given.
if test "${with_cvs+set}" = set; then
- withval="$with_cvs"
- with_cvs=$withval
+ withval=$with_cvs; with_cvs=$withval
else
with_cvs=yes
-fi;
+fi
+
if test "$with_cvs" = yes; then
if test -d $srcdir/CVS && grep :pserver: $srcdir/CVS/Root > /dev/null
then
@@ -1506,75 +1988,75 @@ fi
-# Check whether --with-headers or --without-headers was given.
+# Check whether --with-headers was given.
if test "${with_headers+set}" = set; then
- withval="$with_headers"
- sysheaders=$withval
+ withval=$with_headers; sysheaders=$withval
else
sysheaders=''
-fi;
+fi
-# Check whether --enable-sanity-checks or --disable-sanity-checks was given.
+
+# Check whether --enable-sanity-checks was given.
if test "${enable_sanity_checks+set}" = set; then
- enableval="$enable_sanity_checks"
- enable_sanity=$enableval
+ enableval=$enable_sanity_checks; enable_sanity=$enableval
else
enable_sanity=yes
-fi;
+fi
+
-# Check whether --enable-check-abi or --disable-check-abi was given.
+# Check whether --enable-check-abi was given.
if test "${enable_check_abi+set}" = set; then
- enableval="$enable_check_abi"
- enable_check_abi=$enableval
+ enableval=$enable_check_abi; enable_check_abi=$enableval
else
enable_check_abi=no
-fi;
+fi
+
static=yes
-# Check whether --enable-shared or --disable-shared was given.
+# Check whether --enable-shared was given.
if test "${enable_shared+set}" = set; then
- enableval="$enable_shared"
- shared=$enableval
+ enableval=$enable_shared; shared=$enableval
else
shared=default
-fi;
-# Check whether --enable-profile or --disable-profile was given.
+fi
+
+# Check whether --enable-profile was given.
if test "${enable_profile+set}" = set; then
- enableval="$enable_profile"
- profile=$enableval
+ enableval=$enable_profile; profile=$enableval
else
profile=no
-fi;
-# Check whether --enable-omitfp or --disable-omitfp was given.
+fi
+
+# Check whether --enable-omitfp was given.
if test "${enable_omitfp+set}" = set; then
- enableval="$enable_omitfp"
- omitfp=$enableval
+ enableval=$enable_omitfp; omitfp=$enableval
else
omitfp=no
-fi;
-# Check whether --enable-bounded or --disable-bounded was given.
+fi
+
+# Check whether --enable-bounded was given.
if test "${enable_bounded+set}" = set; then
- enableval="$enable_bounded"
- bounded=$enableval
+ enableval=$enable_bounded; bounded=$enableval
else
bounded=no
-fi;
-# Check whether --enable-versioning or --disable-versioning was given.
+fi
+
+# Check whether --enable-versioning was given.
if test "${enable_versioning+set}" = set; then
- enableval="$enable_versioning"
- enable_versioning=$enableval
+ enableval=$enable_versioning; enable_versioning=$enableval
else
enable_versioning=yes
-fi;
+fi
-# Check whether --enable-oldest-abi or --disable-oldest-abi was given.
+
+# Check whether --enable-oldest-abi was given.
if test "${enable_oldest_abi+set}" = set; then
- enableval="$enable_oldest_abi"
- oldest_abi=$enableval
+ enableval=$enable_oldest_abi; oldest_abi=$enableval
else
oldest_abi=no
-fi;
+fi
+
if test "$oldest_abi" = yes || test "$oldest_abi" = no; then
oldest_abi=default
else
@@ -1585,13 +2067,13 @@ _ACEOF
fi
-# Check whether --enable-stackguard-randomization or --disable-stackguard-randomization was given.
+# Check whether --enable-stackguard-randomization was given.
if test "${enable_stackguard_randomization+set}" = set; then
- enableval="$enable_stackguard_randomization"
- enable_stackguard_randomize=$enableval
+ enableval=$enable_stackguard_randomization; enable_stackguard_randomize=$enableval
else
enable_stackguard_randomize=no
-fi;
+fi
+
if test "$enable_stackguard_randomize" = yes; then
cat >>confdefs.h <<\_ACEOF
#define ENABLE_STACKGUARD_RANDOMIZE 1
@@ -1599,39 +2081,39 @@ _ACEOF
fi
-# Check whether --enable-add-ons or --disable-add-ons was given.
+# Check whether --enable-add-ons was given.
if test "${enable_add_ons+set}" = set; then
- enableval="$enable_add_ons"
-
+ enableval=$enable_add_ons;
else
enable_add_ons=yes
-fi;
+fi
+
-# Check whether --with-tls or --without-tls was given.
+# Check whether --with-tls was given.
if test "${with_tls+set}" = set; then
- withval="$with_tls"
- usetls=$withval
+ withval=$with_tls; usetls=$withval
else
usetls=yes
-fi;
+fi
-# Check whether --with-__thread or --without-__thread was given.
+
+# Check whether --with-__thread was given.
if test "${with___thread+set}" = set; then
- withval="$with___thread"
- use__thread=$withval
+ withval=$with___thread; use__thread=$withval
else
use__thread=yes
-fi;
+fi
+
-# Check whether --enable-hidden-plt or --disable-hidden-plt was given.
+# Check whether --enable-hidden-plt was given.
if test "${enable_hidden_plt+set}" = set; then
- enableval="$enable_hidden_plt"
- hidden=$enableval
+ enableval=$enable_hidden_plt; hidden=$enableval
else
hidden=yes
-fi;
+fi
+
if test "x$hidden" = xno; then
cat >>confdefs.h <<\_ACEOF
#define NO_HIDDEN 1
@@ -1639,22 +2121,22 @@ _ACEOF
fi
-# Check whether --enable-bind-now or --disable-bind-now was given.
+# Check whether --enable-bind-now was given.
if test "${enable_bind_now+set}" = set; then
- enableval="$enable_bind_now"
- bindnow=$enableval
+ enableval=$enable_bind_now; bindnow=$enableval
else
bindnow=no
-fi;
+fi
-# Check whether --enable-static-nss or --disable-static-nss was given.
+
+# Check whether --enable-static-nss was given.
if test "${enable_static_nss+set}" = set; then
- enableval="$enable_static_nss"
- static_nss=$enableval
+ enableval=$enable_static_nss; static_nss=$enableval
else
static_nss=no
-fi;
+fi
+
if test x"$static_nss" = xyes || test x"$shared" = xno; then
static_nss=yes
cat >>confdefs.h <<\_ACEOF
@@ -1663,20 +2145,20 @@ _ACEOF
fi
-# Check whether --enable-force-install or --disable-force-install was given.
+# Check whether --enable-force-install was given.
if test "${enable_force_install+set}" = set; then
- enableval="$enable_force_install"
- force_install=$enableval
+ enableval=$enable_force_install; force_install=$enableval
else
force_install=yes
-fi;
+fi
+
-# Check whether --enable-kernel or --disable-kernel was given.
+# Check whether --enable-kernel was given.
if test "${enable_kernel+set}" = set; then
- enableval="$enable_kernel"
- minimum_kernel=$enableval
-fi;
+ enableval=$enable_kernel; minimum_kernel=$enableval
+fi
+
if test "$minimum_kernel" = yes || test "$minimum_kernel" = no; then
# Better nothing than this.
minimum_kernel=""
@@ -1686,25 +2168,24 @@ else
fi
fi
-# Check whether --enable-all-warnings or --disable-all-warnings was given.
+# Check whether --enable-all-warnings was given.
if test "${enable_all_warnings+set}" = set; then
- enableval="$enable_all_warnings"
- all_warnings=$enableval
-fi;
+ enableval=$enable_all_warnings; all_warnings=$enableval
+fi
-# Check whether --with-decimal-float or --without-decimal-float was given.
-if test "${with_decimal_float+set}" = set; then
- withval="$with_decimal_float"
- usedfp=$withval
+# Check whether --enable-decimal-float was given.
+if test "${enable_decimal_float+set}" = set; then
+ enableval=$enable_decimal_float; usedfp=$enableval
else
- usedfp=yes
-fi;
+ usedfp=no
+fi
+
if test "$usedfp" != no; then
# Check to make sure the compiler supports decimal floating point.
-echo "$as_me:$LINENO: checking for decimal-float-support in compiler" >&5
-echo $ECHO_N "checking for decimal-float-support in compiler... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for decimal-float-support in compiler" >&5
+echo $ECHO_N "checking for decimal-float-support in compiler... $ECHO_C" >&6; }
if test "${libc_cv_cc_with_decimal_float+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -1721,8 +2202,8 @@ then
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_cc_with_decimal_float" >&5
-echo "${ECHO_T}$libc_cv_cc_with_decimal_float" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_cc_with_decimal_float" >&5
+echo "${ECHO_T}$libc_cv_cc_with_decimal_float" >&6; }
if test $libc_cv_cc_with_decimal_float = yes; then
cat >> confdefs.h <<\EOF
@@ -1733,57 +2214,86 @@ fi
# Make sure we can run config.sub.
-$ac_config_sub sun4 >/dev/null 2>&1 ||
- { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
-echo "$as_me: error: cannot run $ac_config_sub" >&2;}
+$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
+ { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
+echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
{ (exit 1); exit 1; }; }
-echo "$as_me:$LINENO: checking build system type" >&5
-echo $ECHO_N "checking build system type... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking build system type" >&5
+echo $ECHO_N "checking build system type... $ECHO_C" >&6; }
if test "${ac_cv_build+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- ac_cv_build_alias=$build_alias
-test -z "$ac_cv_build_alias" &&
- ac_cv_build_alias=`$ac_config_guess`
-test -z "$ac_cv_build_alias" &&
+ ac_build_alias=$build_alias
+test "x$ac_build_alias" = x &&
+ ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
+test "x$ac_build_alias" = x &&
{ { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
{ (exit 1); exit 1; }; }
-ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
- { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
+ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
+ { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
+echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
{ (exit 1); exit 1; }; }
fi
-echo "$as_me:$LINENO: result: $ac_cv_build" >&5
-echo "${ECHO_T}$ac_cv_build" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_build" >&5
+echo "${ECHO_T}$ac_cv_build" >&6; }
+case $ac_cv_build in
+*-*-*) ;;
+*) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
+echo "$as_me: error: invalid value of canonical build" >&2;}
+ { (exit 1); exit 1; }; };;
+esac
build=$ac_cv_build
-build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-
-
-echo "$as_me:$LINENO: checking host system type" >&5
-echo $ECHO_N "checking host system type... $ECHO_C" >&6
+ac_save_IFS=$IFS; IFS='-'
+set x $ac_cv_build
+shift
+build_cpu=$1
+build_vendor=$2
+shift; shift
+# Remember, the first character of IFS is used to create $*,
+# except with old shells:
+build_os=$*
+IFS=$ac_save_IFS
+case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
+
+
+{ echo "$as_me:$LINENO: checking host system type" >&5
+echo $ECHO_N "checking host system type... $ECHO_C" >&6; }
if test "${ac_cv_host+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- ac_cv_host_alias=$host_alias
-test -z "$ac_cv_host_alias" &&
- ac_cv_host_alias=$ac_cv_build_alias
-ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
- { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
+ if test "x$host_alias" = x; then
+ ac_cv_host=$ac_cv_build
+else
+ ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
+ { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
+echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
{ (exit 1); exit 1; }; }
+fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_host" >&5
-echo "${ECHO_T}$ac_cv_host" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_host" >&5
+echo "${ECHO_T}$ac_cv_host" >&6; }
+case $ac_cv_host in
+*-*-*) ;;
+*) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
+echo "$as_me: error: invalid value of canonical host" >&2;}
+ { (exit 1); exit 1; }; };;
+esac
host=$ac_cv_host
-host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+ac_save_IFS=$IFS; IFS='-'
+set x $ac_cv_host
+shift
+host_cpu=$1
+host_vendor=$2
+shift; shift
+# Remember, the first character of IFS is used to create $*,
+# except with old shells:
+host_os=$*
+IFS=$ac_save_IFS
+case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
@@ -1848,10 +2358,9 @@ esac
submachine=
-# Check whether --with-cpu or --without-cpu was given.
+# Check whether --with-cpu was given.
if test "${with_cpu+set}" = set; then
- withval="$with_cpu"
- case "$withval" in
+ withval=$with_cpu; case "$withval" in
yes|'') { { echo "$as_me:$LINENO: error: --with-cpu requires an argument" >&5
echo "$as_me: error: --with-cpu requires an argument" >&2;}
{ (exit 1); exit 1; }; } ;;
@@ -1859,14 +2368,12 @@ echo "$as_me: error: --with-cpu requires an argument" >&2;}
*) submachine="$withval" ;;
esac
-fi;
+fi
# An add-on can set this when it wants to disable the sanity check below.
libc_config_ok=no
-
-
subdirs="$subdirs "
@@ -1985,15 +2492,15 @@ $d-srcdir = $subdir_srcdir"
if test -n "$libc_add_on"; then
if frags=`ls -d $libc_add_on_srcdir/sysdeps/*/preconfigure 2> /dev/null`
then
- echo "$as_me:$LINENO: checking add-on $libc_add_on for preconfigure fragments" >&5
-echo $ECHO_N "checking add-on $libc_add_on for preconfigure fragments... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking add-on $libc_add_on for preconfigure fragments" >&5
+echo $ECHO_N "checking add-on $libc_add_on for preconfigure fragments... $ECHO_C" >&6; }
for frag in $frags; do
name=`echo "$frag" | sed 's@/[^/]*$@@;s@^.*/@@'`
echo $ECHO_N "$name $ECHO_C" >&6
. "$frag"
done
- echo "$as_me:$LINENO: result: " >&5
-echo "${ECHO_T}" >&6
+ { echo "$as_me:$LINENO: result: " >&5
+echo "${ECHO_T}" >&6; }
fi
use_add_ons="$use_add_ons $libc_add_on"
add_ons_pfx="$add_ons_pfx $libc_add_on/"
@@ -2084,8 +2591,8 @@ fi
# Compute the list of sysdep directories for this configuration.
# This can take a while to compute.
sysdep_dir=$srcdir/sysdeps
-echo "$as_me:$LINENO: checking sysdep dirs" >&5
-echo $ECHO_N "checking sysdep dirs... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking sysdep dirs" >&5
+echo $ECHO_N "checking sysdep dirs... $ECHO_C" >&6; }
# Make sco3.2v4 become sco3.2.4 and sunos4.1.1_U1 become sunos4.1.1.U1.
os="`echo $os | sed 's/\([0-9A-Z]\)[v_]\([0-9A-Z]\)/\1.\2/g'`"
@@ -2320,8 +2827,8 @@ fi
sysnames="$names $default_sysnames"
# The other names were emitted during the scan.
-echo "$as_me:$LINENO: result: $default_sysnames" >&5
-echo "${ECHO_T}$default_sysnames" >&6
+{ echo "$as_me:$LINENO: result: $default_sysnames" >&5
+echo "${ECHO_T}$default_sysnames" >&6; }
# Collect the list of add-ons that supply partial sysdeps trees.
sysdeps_add_ons=
@@ -2398,8 +2905,8 @@ done
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# OS/2's system install, which has a completely different semantic
# ./install, which can be erroneously created by make from ./install.sh.
-echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
-echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
+echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; }
if test -z "$INSTALL"; then
if test "${ac_cv_path_install+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2421,7 +2928,7 @@ case $as_dir/ in
# by default.
for ac_prog in ginstall scoinst install; do
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
if test $ac_prog = install &&
grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
# AIX install. It has an incompatible calling convention.
@@ -2440,21 +2947,22 @@ case $as_dir/ in
;;
esac
done
+IFS=$as_save_IFS
fi
if test "${ac_cv_path_install+set}" = set; then
INSTALL=$ac_cv_path_install
else
- # As a last resort, use the slow shell script. We don't cache a
- # path for INSTALL within a source directory, because that will
+ # As a last resort, use the slow shell script. Don't cache a
+ # value for INSTALL within a source directory, because that will
# break other packages using the cache if that directory is
- # removed, or if the path is relative.
+ # removed, or if the value is a relative name.
INSTALL=$ac_install_sh
fi
fi
-echo "$as_me:$LINENO: result: $INSTALL" >&5
-echo "${ECHO_T}$INSTALL" >&6
+{ echo "$as_me:$LINENO: result: $INSTALL" >&5
+echo "${ECHO_T}$INSTALL" >&6; }
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
@@ -2468,15 +2976,15 @@ if test "$INSTALL" = "${srcdir}/scripts/install-sh -c"; then
# The makefiles need to use a different form to find it in $srcdir.
INSTALL='\$(..)./scripts/install-sh -c'
fi
-echo "$as_me:$LINENO: checking whether ln -s works" >&5
-echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether ln -s works" >&5
+echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; }
LN_S=$as_ln_s
if test "$LN_S" = "ln -s"; then
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+ { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
else
- echo "$as_me:$LINENO: result: no, using $LN_S" >&5
-echo "${ECHO_T}no, using $LN_S" >&6
+ { echo "$as_me:$LINENO: result: no, using $LN_S" >&5
+echo "${ECHO_T}no, using $LN_S" >&6; }
fi
@@ -2488,8 +2996,8 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
set dummy ${ac_tool_prefix}gcc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -2502,32 +3010,34 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_CC="${ac_tool_prefix}gcc"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
+ { echo "$as_me:$LINENO: result: $CC" >&5
+echo "${ECHO_T}$CC" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
fi
if test -z "$ac_cv_prog_CC"; then
ac_ct_CC=$CC
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -2540,36 +3050,51 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_ac_ct_CC="gcc"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6
+ { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
+echo "${ECHO_T}$ac_ct_CC" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
- CC=$ac_ct_CC
+ if test "x$ac_ct_CC" = x; then
+ CC=""
+ else
+ case $cross_compiling:$ac_tool_warned in
+yes:)
+{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet. If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&5
+echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet. If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+ac_tool_warned=yes ;;
+esac
+ CC=$ac_ct_CC
+ fi
else
CC="$ac_cv_prog_CC"
fi
if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
+ if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
set dummy ${ac_tool_prefix}cc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -2582,74 +3107,34 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_CC="${ac_tool_prefix}cc"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
-else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="cc"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
-done
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6
+ { echo "$as_me:$LINENO: result: $CC" >&5
+echo "${ECHO_T}$CC" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
- CC=$ac_ct_CC
-else
- CC="$ac_cv_prog_CC"
-fi
+ fi
fi
if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -2663,7 +3148,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
ac_prog_rejected=yes
continue
@@ -2674,6 +3159,7 @@ do
fi
done
done
+IFS=$as_save_IFS
if test $ac_prog_rejected = yes; then
# We found a bogon in the path, so make sure we never use it.
@@ -2691,22 +3177,23 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
+ { echo "$as_me:$LINENO: result: $CC" >&5
+echo "${ECHO_T}$CC" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
fi
if test -z "$CC"; then
if test -n "$ac_tool_prefix"; then
- for ac_prog in cl
+ for ac_prog in cl.exe
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -2719,36 +3206,38 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
+ { echo "$as_me:$LINENO: result: $CC" >&5
+echo "${ECHO_T}$CC" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$CC" && break
done
fi
if test -z "$CC"; then
ac_ct_CC=$CC
- for ac_prog in cl
+ for ac_prog in cl.exe
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -2761,29 +3250,45 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_ac_ct_CC="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6
+ { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
+echo "${ECHO_T}$ac_ct_CC" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$ac_ct_CC" && break
done
- CC=$ac_ct_CC
+ if test "x$ac_ct_CC" = x; then
+ CC=""
+ else
+ case $cross_compiling:$ac_tool_warned in
+yes:)
+{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet. If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&5
+echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet. If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+ac_tool_warned=yes ;;
+esac
+ CC=$ac_ct_CC
+ fi
fi
fi
@@ -2796,28 +3301,42 @@ See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
# Provide some information about the compiler.
-echo "$as_me:$LINENO:" \
- "checking for C compiler version" >&5
+echo "$as_me:$LINENO: checking for C compiler version" >&5
ac_compiler=`set X $ac_compile; echo $2`
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
- (eval $ac_compiler --version </dev/null >&5) 2>&5
+{ (ac_try="$ac_compiler --version >&5"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compiler --version >&5") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
- (eval $ac_compiler -v </dev/null >&5) 2>&5
+{ (ac_try="$ac_compiler -v >&5"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compiler -v >&5") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
- (eval $ac_compiler -V </dev/null >&5) 2>&5
+{ (ac_try="$ac_compiler -V >&5"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compiler -V >&5") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
EXEEXT=
-echo "$as_me:$LINENO: checking for suffix of object files" >&5
-echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for suffix of object files" >&5
+echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
if test "${ac_cv_objext+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -2837,14 +3356,20 @@ main ()
}
_ACEOF
rm -f conftest.o conftest.obj
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; then
- for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
+ for ac_file in conftest.o conftest.obj conftest.*; do
+ test -f "$ac_file" || continue;
case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
*) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
break;;
esac
@@ -2862,12 +3387,12 @@ fi
rm -f conftest.$ac_cv_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
-echo "${ECHO_T}$ac_cv_objext" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
+echo "${ECHO_T}$ac_cv_objext" >&6; }
OBJEXT=$ac_cv_objext
ac_objext=$OBJEXT
-echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
-echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
+echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
if test "${ac_cv_c_compiler_gnu+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -2890,50 +3415,49 @@ main ()
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_compiler_gnu=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_compiler_gnu=no
+ ac_compiler_gnu=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_cv_c_compiler_gnu=$ac_compiler_gnu
fi
-echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
+echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
GCC=`test $ac_compiler_gnu = yes && echo yes`
ac_test_CFLAGS=${CFLAGS+set}
ac_save_CFLAGS=$CFLAGS
-CFLAGS="-g"
-echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
-echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
+echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
if test "${ac_cv_prog_cc_g+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
+ ac_save_c_werror_flag=$ac_c_werror_flag
+ ac_c_werror_flag=yes
+ ac_cv_prog_cc_g=no
+ CFLAGS="-g"
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
@@ -2949,38 +3473,118 @@ main ()
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
+ ac_cv_prog_cc_g=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ CFLAGS=""
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
+ :
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ ac_c_werror_flag=$ac_save_c_werror_flag
+ CFLAGS="-g"
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_cv_prog_cc_g=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_prog_cc_g=no
+
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ ac_c_werror_flag=$ac_save_c_werror_flag
fi
-echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
+echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
if test "$ac_test_CFLAGS" = set; then
CFLAGS=$ac_save_CFLAGS
elif test $ac_cv_prog_cc_g = yes; then
@@ -2996,12 +3600,12 @@ else
CFLAGS=
fi
fi
-echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
-echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
-if test "${ac_cv_prog_cc_stdc+set}" = set; then
+{ echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
+echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
+if test "${ac_cv_prog_cc_c89+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- ac_cv_prog_cc_stdc=no
+ ac_cv_prog_cc_c89=no
ac_save_CC=$CC
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -3035,12 +3639,17 @@ static char *f (char * (*g) (char **, int), char **p, ...)
/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
function prototypes and stuff, but not '\xHH' hex character constants.
These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std1 is added to get
+ as 'x'. The following induces an error, until -std is added to get
proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std1. */
+ that's true only with -std. */
int osf4_cc_array ['\x00' == 0 ? 1 : -1];
+/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
+ inside strings and character constants. */
+#define FOO(x) 'x'
+int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
+
int test (int i, double x);
struct s1 {int (*f) (int a);};
struct s2 {int (*f) (double a);};
@@ -3055,205 +3664,57 @@ return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
return 0;
}
_ACEOF
-# Don't try gcc -ansi; that turns off useful extensions and
-# breaks some systems' header files.
-# AIX -qlanglvl=ansi
-# Ultrix and OSF/1 -std1
-# HP-UX 10.20 and later -Ae
-# HP-UX older versions -Aa -D_HPUX_SOURCE
-# SVR4 -Xc -D__EXTENSIONS__
-for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
+for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
+ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
do
CC="$ac_save_CC $ac_arg"
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_prog_cc_stdc=$ac_arg
-break
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
+ ac_cv_prog_cc_c89=$ac_arg
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+
fi
-rm -f conftest.err conftest.$ac_objext
+
+rm -f core conftest.err conftest.$ac_objext
+ test "x$ac_cv_prog_cc_c89" != "xno" && break
done
-rm -f conftest.$ac_ext conftest.$ac_objext
+rm -f conftest.$ac_ext
CC=$ac_save_CC
fi
-
-case "x$ac_cv_prog_cc_stdc" in
- x|xno)
- echo "$as_me:$LINENO: result: none needed" >&5
-echo "${ECHO_T}none needed" >&6 ;;
+# AC_CACHE_VAL
+case "x$ac_cv_prog_cc_c89" in
+ x)
+ { echo "$as_me:$LINENO: result: none needed" >&5
+echo "${ECHO_T}none needed" >&6; } ;;
+ xno)
+ { echo "$as_me:$LINENO: result: unsupported" >&5
+echo "${ECHO_T}unsupported" >&6; } ;;
*)
- echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
- CC="$CC $ac_cv_prog_cc_stdc" ;;
+ CC="$CC $ac_cv_prog_cc_c89"
+ { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
+echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
esac
-# Some people use a C++ compiler to compile C. Since we use `exit',
-# in C++ we need to declare it. In case someone uses the same compiler
-# for both compiling C and C++ we need to have the C++ compiler decide
-# the declaration of exit, since it's the most demanding environment.
-cat >conftest.$ac_ext <<_ACEOF
-#ifndef __cplusplus
- choke me
-#endif
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- for ac_declaration in \
- '' \
- 'extern "C" void std::exit (int) throw (); using std::exit;' \
- 'extern "C" void std::exit (int); using std::exit;' \
- 'extern "C" void exit (int) throw ();' \
- 'extern "C" void exit (int);' \
- 'void exit (int);'
-do
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_declaration
-#include <stdlib.h>
-int
-main ()
-{
-exit (42);
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- :
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-continue
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_declaration
-int
-main ()
-{
-exit (42);
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- break
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-rm -f conftest*
-if test -n "$ac_declaration"; then
- echo '#ifdef __cplusplus' >>confdefs.h
- echo $ac_declaration >>confdefs.h
- echo '#endif' >>confdefs.h
-fi
-
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
@@ -3265,8 +3726,8 @@ if test $host != $build; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_BUILD_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -3279,25 +3740,27 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_BUILD_CC="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
BUILD_CC=$ac_cv_prog_BUILD_CC
if test -n "$BUILD_CC"; then
- echo "$as_me:$LINENO: result: $BUILD_CC" >&5
-echo "${ECHO_T}$BUILD_CC" >&6
+ { echo "$as_me:$LINENO: result: $BUILD_CC" >&5
+echo "${ECHO_T}$BUILD_CC" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$BUILD_CC" && break
done
@@ -3308,8 +3771,8 @@ ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
-echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
+echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -3343,24 +3806,22 @@ cat >>conftest.$ac_ext <<_ACEOF
#endif
Syntax error
_ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (ac_try="$ac_cpp conftest.$ac_ext"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
- if test -s conftest.err; then
- ac_cpp_err=$ac_c_preproc_warn_flag
- ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
- else
- ac_cpp_err=
- fi
-else
- ac_cpp_err=yes
-fi
-if test -z "$ac_cpp_err"; then
+ (exit $ac_status); } >/dev/null && {
+ test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ }; then
:
else
echo "$as_me: failed program was:" >&5
@@ -3369,9 +3830,10 @@ sed 's/^/| /' conftest.$ac_ext >&5
# Broken: fails on valid input.
continue
fi
+
rm -f conftest.err conftest.$ac_ext
- # OK, works on sane cases. Now check whether non-existent headers
+ # OK, works on sane cases. Now check whether nonexistent headers
# can be detected and how.
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -3381,24 +3843,22 @@ cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
#include <ac_nonexistent.h>
_ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (ac_try="$ac_cpp conftest.$ac_ext"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
- if test -s conftest.err; then
- ac_cpp_err=$ac_c_preproc_warn_flag
- ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
- else
- ac_cpp_err=
- fi
-else
- ac_cpp_err=yes
-fi
-if test -z "$ac_cpp_err"; then
+ (exit $ac_status); } >/dev/null && {
+ test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ }; then
# Broken: success on invalid input.
continue
else
@@ -3409,6 +3869,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_preproc_ok=:
break
fi
+
rm -f conftest.err conftest.$ac_ext
done
@@ -3426,8 +3887,8 @@ fi
else
ac_cv_prog_CPP=$CPP
fi
-echo "$as_me:$LINENO: result: $CPP" >&5
-echo "${ECHO_T}$CPP" >&6
+{ echo "$as_me:$LINENO: result: $CPP" >&5
+echo "${ECHO_T}$CPP" >&6; }
ac_preproc_ok=false
for ac_c_preproc_warn_flag in '' yes
do
@@ -3450,24 +3911,22 @@ cat >>conftest.$ac_ext <<_ACEOF
#endif
Syntax error
_ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (ac_try="$ac_cpp conftest.$ac_ext"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
- if test -s conftest.err; then
- ac_cpp_err=$ac_c_preproc_warn_flag
- ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
- else
- ac_cpp_err=
- fi
-else
- ac_cpp_err=yes
-fi
-if test -z "$ac_cpp_err"; then
+ (exit $ac_status); } >/dev/null && {
+ test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ }; then
:
else
echo "$as_me: failed program was:" >&5
@@ -3476,9 +3935,10 @@ sed 's/^/| /' conftest.$ac_ext >&5
# Broken: fails on valid input.
continue
fi
+
rm -f conftest.err conftest.$ac_ext
- # OK, works on sane cases. Now check whether non-existent headers
+ # OK, works on sane cases. Now check whether nonexistent headers
# can be detected and how.
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -3488,24 +3948,22 @@ cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
#include <ac_nonexistent.h>
_ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (ac_try="$ac_cpp conftest.$ac_ext"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
- if test -s conftest.err; then
- ac_cpp_err=$ac_c_preproc_warn_flag
- ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
- else
- ac_cpp_err=
- fi
-else
- ac_cpp_err=yes
-fi
-if test -z "$ac_cpp_err"; then
+ (exit $ac_status); } >/dev/null && {
+ test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ }; then
# Broken: success on invalid input.
continue
else
@@ -3516,6 +3974,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_preproc_ok=:
break
fi
+
rm -f conftest.err conftest.$ac_ext
done
@@ -3538,18 +3997,22 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $
ac_compiler_gnu=$ac_cv_c_compiler_gnu
# We need the C++ compiler only for testing.
-ac_ext=cc
+ac_ext=cpp
ac_cpp='$CXXCPP $CPPFLAGS'
ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
+if test -z "$CXX"; then
+ if test -n "$CCC"; then
+ CXX=$CCC
+ else
+ if test -n "$ac_tool_prefix"; then
+ for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_CXX+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -3562,36 +4025,38 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
CXX=$ac_cv_prog_CXX
if test -n "$CXX"; then
- echo "$as_me:$LINENO: result: $CXX" >&5
-echo "${ECHO_T}$CXX" >&6
+ { echo "$as_me:$LINENO: result: $CXX" >&5
+echo "${ECHO_T}$CXX" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$CXX" && break
done
fi
if test -z "$CXX"; then
ac_ct_CXX=$CXX
- for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
+ for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -3604,55 +4069,85 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_ac_ct_CXX="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
if test -n "$ac_ct_CXX"; then
- echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
-echo "${ECHO_T}$ac_ct_CXX" >&6
+ { echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
+echo "${ECHO_T}$ac_ct_CXX" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$ac_ct_CXX" && break
done
-test -n "$ac_ct_CXX" || ac_ct_CXX="g++"
- CXX=$ac_ct_CXX
+ if test "x$ac_ct_CXX" = x; then
+ CXX="g++"
+ else
+ case $cross_compiling:$ac_tool_warned in
+yes:)
+{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet. If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&5
+echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet. If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+ac_tool_warned=yes ;;
+esac
+ CXX=$ac_ct_CXX
+ fi
fi
-
+ fi
+fi
# Provide some information about the compiler.
-echo "$as_me:$LINENO:" \
- "checking for C++ compiler version" >&5
+echo "$as_me:$LINENO: checking for C++ compiler version" >&5
ac_compiler=`set X $ac_compile; echo $2`
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
- (eval $ac_compiler --version </dev/null >&5) 2>&5
+{ (ac_try="$ac_compiler --version >&5"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compiler --version >&5") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
- (eval $ac_compiler -v </dev/null >&5) 2>&5
+{ (ac_try="$ac_compiler -v >&5"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compiler -v >&5") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
- (eval $ac_compiler -V </dev/null >&5) 2>&5
+{ (ac_try="$ac_compiler -V >&5"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compiler -V >&5") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
-echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5
-echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5
+echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6; }
if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -3675,50 +4170,49 @@ main ()
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_cxx_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_cxx_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_compiler_gnu=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_compiler_gnu=no
+ ac_compiler_gnu=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
fi
-echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
+echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6; }
GXX=`test $ac_compiler_gnu = yes && echo yes`
ac_test_CXXFLAGS=${CXXFLAGS+set}
ac_save_CXXFLAGS=$CXXFLAGS
-CXXFLAGS="-g"
-echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
-echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
+echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6; }
if test "${ac_cv_prog_cxx_g+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
+ ac_save_cxx_werror_flag=$ac_cxx_werror_flag
+ ac_cxx_werror_flag=yes
+ ac_cv_prog_cxx_g=no
+ CXXFLAGS="-g"
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
@@ -3734,159 +4228,133 @@ main ()
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_cxx_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_cxx_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_cv_prog_cxx_g=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_prog_cxx_g=no
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6
-if test "$ac_test_CXXFLAGS" = set; then
- CXXFLAGS=$ac_save_CXXFLAGS
-elif test $ac_cv_prog_cxx_g = yes; then
- if test "$GXX" = yes; then
- CXXFLAGS="-g -O2"
- else
- CXXFLAGS="-g"
- fi
-else
- if test "$GXX" = yes; then
- CXXFLAGS="-O2"
- else
- CXXFLAGS=
- fi
-fi
-for ac_declaration in \
- '' \
- 'extern "C" void std::exit (int) throw (); using std::exit;' \
- 'extern "C" void std::exit (int); using std::exit;' \
- 'extern "C" void exit (int) throw ();' \
- 'extern "C" void exit (int);' \
- 'void exit (int);'
-do
- cat >conftest.$ac_ext <<_ACEOF
+ CXXFLAGS=""
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_declaration
-#include <stdlib.h>
+
int
main ()
{
-exit (42);
+
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_cxx_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_cxx_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
:
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-continue
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- cat >conftest.$ac_ext <<_ACEOF
+ ac_cxx_werror_flag=$ac_save_cxx_werror_flag
+ CXXFLAGS="-g"
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_declaration
+
int
main ()
{
-exit (42);
+
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_cxx_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- break
+ (exit $ac_status); } && {
+ test -z "$ac_cxx_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
+ ac_cv_prog_cxx_g=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-rm -f conftest*
-if test -n "$ac_declaration"; then
- echo '#ifdef __cplusplus' >>confdefs.h
- echo $ac_declaration >>confdefs.h
- echo '#endif' >>confdefs.h
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ ac_cxx_werror_flag=$ac_save_cxx_werror_flag
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
+echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6; }
+if test "$ac_test_CXXFLAGS" = set; then
+ CXXFLAGS=$ac_save_CXXFLAGS
+elif test $ac_cv_prog_cxx_g = yes; then
+ if test "$GXX" = yes; then
+ CXXFLAGS="-g -O2"
+ else
+ CXXFLAGS="-g"
+ fi
+else
+ if test "$GXX" = yes; then
+ CXXFLAGS="-O2"
+ else
+ CXXFLAGS=
+ fi
+fi
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
@@ -3916,8 +4384,8 @@ if test "x$ac_ranlib" = xranlib; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_RANLIB+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -3930,32 +4398,34 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
RANLIB=$ac_cv_prog_RANLIB
if test -n "$RANLIB"; then
- echo "$as_me:$LINENO: result: $RANLIB" >&5
-echo "${ECHO_T}$RANLIB" >&6
+ { echo "$as_me:$LINENO: result: $RANLIB" >&5
+echo "${ECHO_T}$RANLIB" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
fi
if test -z "$ac_cv_prog_RANLIB"; then
ac_ct_RANLIB=$RANLIB
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -3968,27 +4438,41 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_ac_ct_RANLIB="ranlib"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
- test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
fi
fi
ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
if test -n "$ac_ct_RANLIB"; then
- echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
-echo "${ECHO_T}$ac_ct_RANLIB" >&6
+ { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
+echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
- RANLIB=$ac_ct_RANLIB
+ if test "x$ac_ct_RANLIB" = x; then
+ RANLIB=":"
+ else
+ case $cross_compiling:$ac_tool_warned in
+yes:)
+{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet. If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&5
+echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet. If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+ac_tool_warned=yes ;;
+esac
+ RANLIB=$ac_ct_RANLIB
+ fi
else
RANLIB="$ac_cv_prog_RANLIB"
fi
@@ -3999,8 +4483,8 @@ fi
# Determine whether we are using GNU binutils.
-echo "$as_me:$LINENO: checking whether $AS is GNU as" >&5
-echo $ECHO_N "checking whether $AS is GNU as... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether $AS is GNU as" >&5
+echo $ECHO_N "checking whether $AS is GNU as... $ECHO_C" >&6; }
if test "${libc_cv_prog_as_gnu+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4013,13 +4497,13 @@ else
fi
rm -fr contest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_prog_as_gnu" >&5
-echo "${ECHO_T}$libc_cv_prog_as_gnu" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_prog_as_gnu" >&5
+echo "${ECHO_T}$libc_cv_prog_as_gnu" >&6; }
rm -f a.out
gnu_as=$libc_cv_prog_as_gnu
-echo "$as_me:$LINENO: checking whether $LD is GNU ld" >&5
-echo $ECHO_N "checking whether $LD is GNU ld... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether $LD is GNU ld" >&5
+echo $ECHO_N "checking whether $LD is GNU ld... $ECHO_C" >&6; }
if test "${libc_cv_prog_ld_gnu+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4032,8 +4516,8 @@ else
fi
rm -fr contest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_prog_ld_gnu" >&5
-echo "${ECHO_T}$libc_cv_prog_ld_gnu" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_prog_ld_gnu" >&5
+echo "${ECHO_T}$libc_cv_prog_ld_gnu" >&6; }
gnu_ld=$libc_cv_prog_ld_gnu
@@ -4042,8 +4526,8 @@ for ac_prog in $AS
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_AS+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4056,25 +4540,27 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_AS="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
AS=$ac_cv_prog_AS
if test -n "$AS"; then
- echo "$as_me:$LINENO: result: $AS" >&5
-echo "${ECHO_T}$AS" >&6
+ { echo "$as_me:$LINENO: result: $AS" >&5
+echo "${ECHO_T}$AS" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$AS" && break
done
@@ -4082,8 +4568,8 @@ if test -z "$AS"; then
ac_verc_fail=yes
else
# Found it, now check the version.
- echo "$as_me:$LINENO: checking version of $AS" >&5
-echo $ECHO_N "checking version of $AS... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking version of $AS" >&5
+echo $ECHO_N "checking version of $AS... $ECHO_C" >&6; }
ac_prog_version=`$AS --version 2>&1 | sed -n 's/^.*GNU assembler.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -4092,8 +4578,8 @@ echo $ECHO_N "checking version of $AS... $ECHO_C" >&6
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
esac
- echo "$as_me:$LINENO: result: $ac_prog_version" >&5
-echo "${ECHO_T}$ac_prog_version" >&6
+ { echo "$as_me:$LINENO: result: $ac_prog_version" >&5
+echo "${ECHO_T}$ac_prog_version" >&6; }
fi
if test $ac_verc_fail = yes; then
AS=: critic_missing="$critic_missing as"
@@ -4103,8 +4589,8 @@ for ac_prog in $LD
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_LD+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4117,25 +4603,27 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_LD="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
LD=$ac_cv_prog_LD
if test -n "$LD"; then
- echo "$as_me:$LINENO: result: $LD" >&5
-echo "${ECHO_T}$LD" >&6
+ { echo "$as_me:$LINENO: result: $LD" >&5
+echo "${ECHO_T}$LD" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$LD" && break
done
@@ -4143,8 +4631,8 @@ if test -z "$LD"; then
ac_verc_fail=yes
else
# Found it, now check the version.
- echo "$as_me:$LINENO: checking version of $LD" >&5
-echo $ECHO_N "checking version of $LD... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking version of $LD" >&5
+echo $ECHO_N "checking version of $LD... $ECHO_C" >&6; }
ac_prog_version=`$LD --version 2>&1 | sed -n 's/^.*GNU ld.* \([0-9][0-9]*\.[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -4153,8 +4641,8 @@ echo $ECHO_N "checking version of $LD... $ECHO_C" >&6
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
esac
- echo "$as_me:$LINENO: result: $ac_prog_version" >&5
-echo "${ECHO_T}$ac_prog_version" >&6
+ { echo "$as_me:$LINENO: result: $ac_prog_version" >&5
+echo "${ECHO_T}$ac_prog_version" >&6; }
fi
if test $ac_verc_fail = yes; then
LD=: critic_missing="$critic_missing ld"
@@ -4168,8 +4656,8 @@ fi
# that.
# Extract the first word of "pwd", so it can be a program name with args.
set dummy pwd; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_PWD_P+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4184,28 +4672,29 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_path_PWD_P="$as_dir/$ac_word$ac_exec_ext"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
test -z "$ac_cv_path_PWD_P" && ac_cv_path_PWD_P="no"
;;
esac
fi
PWD_P=$ac_cv_path_PWD_P
-
if test -n "$PWD_P"; then
- echo "$as_me:$LINENO: result: $PWD_P" >&5
-echo "${ECHO_T}$PWD_P" >&6
+ { echo "$as_me:$LINENO: result: $PWD_P" >&5
+echo "${ECHO_T}$PWD_P" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
if test "$PWD_P" = no; then
{ { echo "$as_me:$LINENO: error: *** A pwd binary could not be found." >&5
echo "$as_me: error: *** A pwd binary could not be found." >&2;}
@@ -4219,8 +4708,8 @@ for ac_prog in ${ac_tool_prefix}gcc ${ac_tool_prefix}cc
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4233,25 +4722,27 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_CC="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
+ { echo "$as_me:$LINENO: result: $CC" >&5
+echo "${ECHO_T}$CC" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$CC" && break
done
@@ -4259,8 +4750,8 @@ if test -z "$CC"; then
ac_verc_fail=yes
else
# Found it, now check the version.
- echo "$as_me:$LINENO: checking version of $CC" >&5
-echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking version of $CC" >&5
+echo $ECHO_N "checking version of $CC... $ECHO_C" >&6; }
ac_prog_version=`$CC -v 2>&1 | sed -n 's/^.*version [egcygnustpi-]*\([0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -4269,8 +4760,8 @@ echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
esac
- echo "$as_me:$LINENO: result: $ac_prog_version" >&5
-echo "${ECHO_T}$ac_prog_version" >&6
+ { echo "$as_me:$LINENO: result: $ac_prog_version" >&5
+echo "${ECHO_T}$ac_prog_version" >&6; }
fi
if test $ac_verc_fail = yes; then
critic_missing="$critic_missing gcc"
@@ -4280,8 +4771,8 @@ for ac_prog in gnumake gmake make
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_MAKE+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4294,25 +4785,27 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_MAKE="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
MAKE=$ac_cv_prog_MAKE
if test -n "$MAKE"; then
- echo "$as_me:$LINENO: result: $MAKE" >&5
-echo "${ECHO_T}$MAKE" >&6
+ { echo "$as_me:$LINENO: result: $MAKE" >&5
+echo "${ECHO_T}$MAKE" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$MAKE" && break
done
@@ -4320,8 +4813,8 @@ if test -z "$MAKE"; then
ac_verc_fail=yes
else
# Found it, now check the version.
- echo "$as_me:$LINENO: checking version of $MAKE" >&5
-echo $ECHO_N "checking version of $MAKE... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking version of $MAKE" >&5
+echo $ECHO_N "checking version of $MAKE... $ECHO_C" >&6; }
ac_prog_version=`$MAKE --version 2>&1 | sed -n 's/^.*GNU Make[^0-9]*\([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -4330,8 +4823,8 @@ echo $ECHO_N "checking version of $MAKE... $ECHO_C" >&6
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
esac
- echo "$as_me:$LINENO: result: $ac_prog_version" >&5
-echo "${ECHO_T}$ac_prog_version" >&6
+ { echo "$as_me:$LINENO: result: $ac_prog_version" >&5
+echo "${ECHO_T}$ac_prog_version" >&6; }
fi
if test $ac_verc_fail = yes; then
critic_missing="$critic_missing make"
@@ -4342,8 +4835,8 @@ for ac_prog in gnumsgfmt gmsgfmt msgfmt
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_MSGFMT+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4356,25 +4849,27 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_MSGFMT="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
MSGFMT=$ac_cv_prog_MSGFMT
if test -n "$MSGFMT"; then
- echo "$as_me:$LINENO: result: $MSGFMT" >&5
-echo "${ECHO_T}$MSGFMT" >&6
+ { echo "$as_me:$LINENO: result: $MSGFMT" >&5
+echo "${ECHO_T}$MSGFMT" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$MSGFMT" && break
done
@@ -4382,8 +4877,8 @@ if test -z "$MSGFMT"; then
ac_verc_fail=yes
else
# Found it, now check the version.
- echo "$as_me:$LINENO: checking version of $MSGFMT" >&5
-echo $ECHO_N "checking version of $MSGFMT... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking version of $MSGFMT" >&5
+echo $ECHO_N "checking version of $MSGFMT... $ECHO_C" >&6; }
ac_prog_version=`$MSGFMT --version 2>&1 | sed -n 's/^.*GNU gettext.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -4392,8 +4887,8 @@ echo $ECHO_N "checking version of $MSGFMT... $ECHO_C" >&6
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
esac
- echo "$as_me:$LINENO: result: $ac_prog_version" >&5
-echo "${ECHO_T}$ac_prog_version" >&6
+ { echo "$as_me:$LINENO: result: $ac_prog_version" >&5
+echo "${ECHO_T}$ac_prog_version" >&6; }
fi
if test $ac_verc_fail = yes; then
MSGFMT=: aux_missing="$aux_missing msgfmt"
@@ -4403,8 +4898,8 @@ for ac_prog in makeinfo
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_MAKEINFO+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4417,25 +4912,27 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_MAKEINFO="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
MAKEINFO=$ac_cv_prog_MAKEINFO
if test -n "$MAKEINFO"; then
- echo "$as_me:$LINENO: result: $MAKEINFO" >&5
-echo "${ECHO_T}$MAKEINFO" >&6
+ { echo "$as_me:$LINENO: result: $MAKEINFO" >&5
+echo "${ECHO_T}$MAKEINFO" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$MAKEINFO" && break
done
@@ -4443,8 +4940,8 @@ if test -z "$MAKEINFO"; then
ac_verc_fail=yes
else
# Found it, now check the version.
- echo "$as_me:$LINENO: checking version of $MAKEINFO" >&5
-echo $ECHO_N "checking version of $MAKEINFO... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking version of $MAKEINFO" >&5
+echo $ECHO_N "checking version of $MAKEINFO... $ECHO_C" >&6; }
ac_prog_version=`$MAKEINFO --version 2>&1 | sed -n 's/^.*GNU texinfo.* \([0-9][0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -4453,8 +4950,8 @@ echo $ECHO_N "checking version of $MAKEINFO... $ECHO_C" >&6
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
esac
- echo "$as_me:$LINENO: result: $ac_prog_version" >&5
-echo "${ECHO_T}$ac_prog_version" >&6
+ { echo "$as_me:$LINENO: result: $ac_prog_version" >&5
+echo "${ECHO_T}$ac_prog_version" >&6; }
fi
if test $ac_verc_fail = yes; then
MAKEINFO=: aux_missing="$aux_missing makeinfo"
@@ -4464,8 +4961,8 @@ for ac_prog in sed
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_SED+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4478,25 +4975,27 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_SED="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
SED=$ac_cv_prog_SED
if test -n "$SED"; then
- echo "$as_me:$LINENO: result: $SED" >&5
-echo "${ECHO_T}$SED" >&6
+ { echo "$as_me:$LINENO: result: $SED" >&5
+echo "${ECHO_T}$SED" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$SED" && break
done
@@ -4504,8 +5003,8 @@ if test -z "$SED"; then
ac_verc_fail=yes
else
# Found it, now check the version.
- echo "$as_me:$LINENO: checking version of $SED" >&5
-echo $ECHO_N "checking version of $SED... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking version of $SED" >&5
+echo $ECHO_N "checking version of $SED... $ECHO_C" >&6; }
ac_prog_version=`$SED --version 2>&1 | sed -n 's/^.*GNU sed version \([0-9]*\.[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
@@ -4514,8 +5013,8 @@ echo $ECHO_N "checking version of $SED... $ECHO_C" >&6
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
esac
- echo "$as_me:$LINENO: result: $ac_prog_version" >&5
-echo "${ECHO_T}$ac_prog_version" >&6
+ { echo "$as_me:$LINENO: result: $ac_prog_version" >&5
+echo "${ECHO_T}$ac_prog_version" >&6; }
fi
if test $ac_verc_fail = yes; then
SED=: aux_missing="$aux_missing sed"
@@ -4526,8 +5025,8 @@ for ac_prog in autoconf
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_AUTOCONF+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4540,25 +5039,27 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_AUTOCONF="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
AUTOCONF=$ac_cv_prog_AUTOCONF
if test -n "$AUTOCONF"; then
- echo "$as_me:$LINENO: result: $AUTOCONF" >&5
-echo "${ECHO_T}$AUTOCONF" >&6
+ { echo "$as_me:$LINENO: result: $AUTOCONF" >&5
+echo "${ECHO_T}$AUTOCONF" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$AUTOCONF" && break
done
test -n "$AUTOCONF" || AUTOCONF="no"
@@ -4566,8 +5067,8 @@ test -n "$AUTOCONF" || AUTOCONF="no"
case "x$AUTOCONF" in
xno|x|x:) AUTOCONF=no ;;
*)
- echo "$as_me:$LINENO: checking whether $AUTOCONF${ACFLAGS:+ }$ACFLAGS works" >&5
-echo $ECHO_N "checking whether $AUTOCONF${ACFLAGS:+ }$ACFLAGS works... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking whether $AUTOCONF${ACFLAGS:+ }$ACFLAGS works" >&5
+echo $ECHO_N "checking whether $AUTOCONF${ACFLAGS:+ }$ACFLAGS works... $ECHO_C" >&6; }
if test "${libc_cv_autoconf_works+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4577,8 +5078,8 @@ else
libc_cv_autoconf_works=no
fi
fi
-echo "$as_me:$LINENO: result: $libc_cv_autoconf_works" >&5
-echo "${ECHO_T}$libc_cv_autoconf_works" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_autoconf_works" >&5
+echo "${ECHO_T}$libc_cv_autoconf_works" >&6; }
test $libc_cv_autoconf_works = yes || AUTOCONF=no
;;
esac
@@ -4610,7 +5111,7 @@ echo "$as_me: WARNING:
if test -n "$sysheaders"; then
SYSINCLUDES=-nostdinc
for d in include include-fixed; do
- i=`$CC -print-file-name="$d"` && test "x$i" != "x$d" &&
+ i=`$CC -print-file-name="$d"` && test "x$i" != x && test "x$i" != "x$d" &&
SYSINCLUDES="$SYSINCLUDES -isystem $i"
done
SYSINCLUDES="$SYSINCLUDES \
@@ -4627,8 +5128,8 @@ fi
# check if ranlib is necessary
-echo "$as_me:$LINENO: checking whether ranlib is necessary" >&5
-echo $ECHO_N "checking whether ranlib is necessary... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether ranlib is necessary" >&5
+echo $ECHO_N "checking whether ranlib is necessary... $ECHO_C" >&6; }
if test "${libc_cv_ranlib_necessary+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4648,8 +5149,8 @@ else
fi
rm -rf conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_ranlib_necessary" >&5
-echo "${ECHO_T}$libc_cv_ranlib_necessary" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_ranlib_necessary" >&5
+echo "${ECHO_T}$libc_cv_ranlib_necessary" >&6; }
if test "$libc_cv_ranlib_necessary" = no; then
RANLIB=:
fi
@@ -4661,8 +5162,8 @@ fi
# - one of the terminals (":" and ";") is the first or last sign
# - two terminals occur directly after each other
# - the path contains an element with a dot in it
-echo "$as_me:$LINENO: checking LD_LIBRARY_PATH variable" >&5
-echo $ECHO_N "checking LD_LIBRARY_PATH variable... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking LD_LIBRARY_PATH variable" >&5
+echo $ECHO_N "checking LD_LIBRARY_PATH variable... $ECHO_C" >&6; }
case ${LD_LIBRARY_PATH} in
[:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* )
ld_library_path_setting="contains current directory"
@@ -4671,8 +5172,8 @@ case ${LD_LIBRARY_PATH} in
ld_library_path_setting="ok"
;;
esac
-echo "$as_me:$LINENO: result: $ld_library_path_setting" >&5
-echo "${ECHO_T}$ld_library_path_setting" >&6
+{ echo "$as_me:$LINENO: result: $ld_library_path_setting" >&5
+echo "${ECHO_T}$ld_library_path_setting" >&6; }
if test "$ld_library_path_setting" != "ok"; then
{ { echo "$as_me:$LINENO: error:
*** LD_LIBRARY_PATH shouldn't contain the current directory when
@@ -4685,8 +5186,8 @@ echo "$as_me: error:
{ (exit 1); exit 1; }; }
fi
-echo "$as_me:$LINENO: checking whether GCC supports -static-libgcc" >&5
-echo $ECHO_N "checking whether GCC supports -static-libgcc... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether GCC supports -static-libgcc" >&5
+echo $ECHO_N "checking whether GCC supports -static-libgcc... $ECHO_C" >&6; }
if test "${libc_cv_gcc_static_libgcc+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4696,14 +5197,14 @@ else
libc_cv_gcc_static_libgcc=-static-libgcc
fi
fi
-echo "$as_me:$LINENO: result: $libc_cv_gcc_static_libgcc" >&5
-echo "${ECHO_T}$libc_cv_gcc_static_libgcc" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_gcc_static_libgcc" >&5
+echo "${ECHO_T}$libc_cv_gcc_static_libgcc" >&6; }
# Extract the first word of "bash", so it can be a program name with args.
set dummy bash; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_BASH_SHELL+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4718,28 +5219,29 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_path_BASH_SHELL="$as_dir/$ac_word$ac_exec_ext"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
test -z "$ac_cv_path_BASH_SHELL" && ac_cv_path_BASH_SHELL="no"
;;
esac
fi
BASH_SHELL=$ac_cv_path_BASH_SHELL
-
if test -n "$BASH_SHELL"; then
- echo "$as_me:$LINENO: result: $BASH_SHELL" >&5
-echo "${ECHO_T}$BASH_SHELL" >&6
+ { echo "$as_me:$LINENO: result: $BASH_SHELL" >&5
+echo "${ECHO_T}$BASH_SHELL" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
if test "$BASH_SHELL" != no &&
$BASH_SHELL -c 'test "$BASH_VERSINFO" \
&& test "$BASH_VERSINFO" -ge 2 >&/dev/null'; then
@@ -4752,8 +5254,8 @@ fi
if test "$BASH_SHELL" = no; then
# Extract the first word of "ksh", so it can be a program name with args.
set dummy ksh; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_KSH+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4768,28 +5270,29 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_path_KSH="$as_dir/$ac_word$ac_exec_ext"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
test -z "$ac_cv_path_KSH" && ac_cv_path_KSH="no"
;;
esac
fi
KSH=$ac_cv_path_KSH
-
if test -n "$KSH"; then
- echo "$as_me:$LINENO: result: $KSH" >&5
-echo "${ECHO_T}$KSH" >&6
+ { echo "$as_me:$LINENO: result: $KSH" >&5
+echo "${ECHO_T}$KSH" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
if test "$KSH" = no; then
libc_cv_have_ksh=no
else
@@ -4806,8 +5309,8 @@ for ac_prog in gawk mawk nawk awk
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_prog_AWK+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4820,32 +5323,34 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_prog_AWK="$ac_prog"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
fi
fi
AWK=$ac_cv_prog_AWK
if test -n "$AWK"; then
- echo "$as_me:$LINENO: result: $AWK" >&5
-echo "${ECHO_T}$AWK" >&6
+ { echo "$as_me:$LINENO: result: $AWK" >&5
+echo "${ECHO_T}$AWK" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
test -n "$AWK" && break
done
# Extract the first word of "perl", so it can be a program name with args.
set dummy perl; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_PERL+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4860,36 +5365,37 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
test -z "$ac_cv_path_PERL" && ac_cv_path_PERL="no"
;;
esac
fi
PERL=$ac_cv_path_PERL
-
if test -n "$PERL"; then
- echo "$as_me:$LINENO: result: $PERL" >&5
-echo "${ECHO_T}$PERL" >&6
+ { echo "$as_me:$LINENO: result: $PERL" >&5
+echo "${ECHO_T}$PERL" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
if test "$PERL" != no &&
(eval `$PERL -V:apiversion`; test `expr "$apiversion" \< 5` -ne 0); then
PERL=no
fi
# Extract the first word of "install-info", so it can be a program name with args.
set dummy install-info; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4905,32 +5411,33 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO="no"
;;
esac
fi
INSTALL_INFO=$ac_cv_path_INSTALL_INFO
-
if test -n "$INSTALL_INFO"; then
- echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
-echo "${ECHO_T}$INSTALL_INFO" >&6
+ { echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
+echo "${ECHO_T}$INSTALL_INFO" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
+
# Extract the first word of "bison", so it can be a program name with args.
set dummy bison; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
if test "${ac_cv_path_BISON+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4946,31 +5453,32 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+IFS=$as_save_IFS
test -z "$ac_cv_path_BISON" && ac_cv_path_BISON="no"
;;
esac
fi
BISON=$ac_cv_path_BISON
-
if test -n "$BISON"; then
- echo "$as_me:$LINENO: result: $BISON" >&5
-echo "${ECHO_T}$BISON" >&6
+ { echo "$as_me:$LINENO: result: $BISON" >&5
+echo "${ECHO_T}$BISON" >&6; }
else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
fi
-echo "$as_me:$LINENO: checking for signed size_t type" >&5
-echo $ECHO_N "checking for signed size_t type... $ECHO_C" >&6
+
+{ echo "$as_me:$LINENO: checking for signed size_t type" >&5
+echo $ECHO_N "checking for signed size_t type... $ECHO_C" >&6; }
if test "${libc_cv_signed_size_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -4984,8 +5492,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_signed_size_t" >&5
-echo "${ECHO_T}$libc_cv_signed_size_t" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_signed_size_t" >&5
+echo "${ECHO_T}$libc_cv_signed_size_t" >&6; }
if test $libc_cv_signed_size_t = yes; then
cat >> confdefs.h <<\EOF
#undef __SIZE_TYPE__
@@ -4994,8 +5502,8 @@ EOF
fi
-echo "$as_me:$LINENO: checking for libc-friendly stddef.h" >&5
-echo $ECHO_N "checking for libc-friendly stddef.h... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for libc-friendly stddef.h" >&5
+echo $ECHO_N "checking for libc-friendly stddef.h... $ECHO_C" >&6; }
if test "${libc_cv_friendly_stddef+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5023,45 +5531,41 @@ if (&size == NULL || &wchar == NULL) abort ();
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
libc_cv_friendly_stddef=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-libc_cv_friendly_stddef=no
+ libc_cv_friendly_stddef=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $libc_cv_friendly_stddef" >&5
-echo "${ECHO_T}$libc_cv_friendly_stddef" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_friendly_stddef" >&5
+echo "${ECHO_T}$libc_cv_friendly_stddef" >&6; }
if test $libc_cv_friendly_stddef = yes; then
config_vars="$config_vars
override stddef.h = # The installed <stddef.h> seems to be libc-friendly."
fi
-echo "$as_me:$LINENO: checking whether we need to use -P to assemble .S files" >&5
-echo $ECHO_N "checking whether we need to use -P to assemble .S files... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether we need to use -P to assemble .S files" >&5
+echo $ECHO_N "checking whether we need to use -P to assemble .S files... $ECHO_C" >&6; }
if test "${libc_cv_need_minus_P+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5081,15 +5585,15 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_need_minus_P" >&5
-echo "${ECHO_T}$libc_cv_need_minus_P" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_need_minus_P" >&5
+echo "${ECHO_T}$libc_cv_need_minus_P" >&6; }
if test $libc_cv_need_minus_P = yes; then
config_vars="$config_vars
asm-CPPFLAGS = -P # The assembler can't grok cpp's # line directives."
fi
-echo "$as_me:$LINENO: checking whether .text pseudo-op must be used" >&5
-echo $ECHO_N "checking whether .text pseudo-op must be used... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether .text pseudo-op must be used" >&5
+echo $ECHO_N "checking whether .text pseudo-op must be used... $ECHO_C" >&6; }
if test "${libc_cv_dot_text+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5109,15 +5613,15 @@ rm -f conftest*
fi
if test -z "$libc_cv_dot_text"; then
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
else
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+ { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
fi
-echo "$as_me:$LINENO: checking for assembler global-symbol directive" >&5
-echo $ECHO_N "checking for assembler global-symbol directive... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for assembler global-symbol directive" >&5
+echo $ECHO_N "checking for assembler global-symbol directive... $ECHO_C" >&6; }
if test "${libc_cv_asm_global_directive+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5140,8 +5644,8 @@ EOF
test $libc_cv_asm_global_directive != UNKNOWN && break
done
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_global_directive" >&5
-echo "${ECHO_T}$libc_cv_asm_global_directive" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_global_directive" >&5
+echo "${ECHO_T}$libc_cv_asm_global_directive" >&6; }
if test $libc_cv_asm_global_directive = UNKNOWN; then
{ { echo "$as_me:$LINENO: error: cannot determine asm global directive" >&5
echo "$as_me: error: cannot determine asm global directive" >&2;}
@@ -5153,8 +5657,8 @@ _ACEOF
fi
-echo "$as_me:$LINENO: checking for .set assembler directive" >&5
-echo $ECHO_N "checking for .set assembler directive... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for .set assembler directive" >&5
+echo $ECHO_N "checking for .set assembler directive... $ECHO_C" >&6; }
if test "${libc_cv_asm_set_directive+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5179,8 +5683,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_set_directive" >&5
-echo "${ECHO_T}$libc_cv_asm_set_directive" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_set_directive" >&5
+echo "${ECHO_T}$libc_cv_asm_set_directive" >&6; }
if test $libc_cv_asm_set_directive = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_ASM_SET_DIRECTIVE 1
@@ -5188,8 +5692,8 @@ _ACEOF
fi
-echo "$as_me:$LINENO: checking for assembler .type directive prefix" >&5
-echo $ECHO_N "checking for assembler .type directive prefix... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for assembler .type directive prefix" >&5
+echo $ECHO_N "checking for assembler .type directive prefix... $ECHO_C" >&6; }
if test "${libc_cv_asm_type_prefix+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5215,8 +5719,8 @@ EOF
test "x$libc_cv_asm_type_prefix" != xno && break
done
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_type_prefix" >&5
-echo "${ECHO_T}$libc_cv_asm_type_prefix" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_type_prefix" >&5
+echo "${ECHO_T}$libc_cv_asm_type_prefix" >&6; }
if test "x$libc_cv_asm_type_prefix" != xno; then
cat >>confdefs.h <<_ACEOF
#define ASM_TYPE_DIRECTIVE_PREFIX ${libc_cv_asm_type_prefix}
@@ -5224,8 +5728,8 @@ _ACEOF
fi
-echo "$as_me:$LINENO: checking for .symver assembler directive" >&5
-echo $ECHO_N "checking for .symver assembler directive... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for .symver assembler directive" >&5
+echo $ECHO_N "checking for .symver assembler directive... $ECHO_C" >&6; }
if test "${libc_cv_asm_symver_directive+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5241,10 +5745,10 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_symver_directive" >&5
-echo "${ECHO_T}$libc_cv_asm_symver_directive" >&6
-echo "$as_me:$LINENO: checking for ld --version-script" >&5
-echo $ECHO_N "checking for ld --version-script... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_symver_directive" >&5
+echo "${ECHO_T}$libc_cv_asm_symver_directive" >&6; }
+{ echo "$as_me:$LINENO: checking for ld --version-script" >&5
+echo $ECHO_N "checking for ld --version-script... $ECHO_C" >&6; }
if test "${libc_cv_ld_version_script_option+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5287,8 +5791,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_ld_version_script_option" >&5
-echo "${ECHO_T}$libc_cv_ld_version_script_option" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_ld_version_script_option" >&5
+echo "${ECHO_T}$libc_cv_ld_version_script_option" >&6; }
if test $shared != no &&
test $libc_cv_asm_symver_directive = yes &&
test $libc_cv_ld_version_script_option = yes &&
@@ -5311,8 +5815,8 @@ if test $elf = yes && test $shared != no && test $VERSIONING = no; then
*** For versioning you need recent binutils (binutils-2.8.1.0.23 or newer)."
fi
if test $elf = yes; then
- echo "$as_me:$LINENO: checking for .previous assembler directive" >&5
-echo $ECHO_N "checking for .previous assembler directive... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for .previous assembler directive" >&5
+echo $ECHO_N "checking for .previous assembler directive... $ECHO_C" >&6; }
if test "${libc_cv_asm_previous_directive+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5332,16 +5836,16 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_previous_directive" >&5
-echo "${ECHO_T}$libc_cv_asm_previous_directive" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_previous_directive" >&5
+echo "${ECHO_T}$libc_cv_asm_previous_directive" >&6; }
if test $libc_cv_asm_previous_directive = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_ASM_PREVIOUS_DIRECTIVE 1
_ACEOF
else
- echo "$as_me:$LINENO: checking for .popsection assembler directive" >&5
-echo $ECHO_N "checking for .popsection assembler directive... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for .popsection assembler directive" >&5
+echo $ECHO_N "checking for .popsection assembler directive... $ECHO_C" >&6; }
if test "${libc_cv_asm_popsection_directive+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5361,8 +5865,8 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_popsection_directive" >&5
-echo "${ECHO_T}$libc_cv_asm_popsection_directive" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_popsection_directive" >&5
+echo "${ECHO_T}$libc_cv_asm_popsection_directive" >&6; }
if test $libc_cv_asm_popsection_directive = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_ASM_POPSECTION_DIRECTIVE 1
@@ -5370,8 +5874,8 @@ _ACEOF
fi
fi
- echo "$as_me:$LINENO: checking for .protected and .hidden assembler directive" >&5
-echo $ECHO_N "checking for .protected and .hidden assembler directive... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for .protected and .hidden assembler directive" >&5
+echo $ECHO_N "checking for .protected and .hidden assembler directive... $ECHO_C" >&6; }
if test "${libc_cv_asm_protected_directive+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5395,12 +5899,12 @@ echo "$as_me: error: assembler support for symbol visibility is required" >&2;}
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_protected_directive" >&5
-echo "${ECHO_T}$libc_cv_asm_protected_directive" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_protected_directive" >&5
+echo "${ECHO_T}$libc_cv_asm_protected_directive" >&6; }
if test $libc_cv_asm_protected_directive = yes; then
- echo "$as_me:$LINENO: checking whether __attribute__((visibility())) is supported" >&5
-echo $ECHO_N "checking whether __attribute__((visibility())) is supported... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking whether __attribute__((visibility())) is supported" >&5
+echo $ECHO_N "checking whether __attribute__((visibility())) is supported... $ECHO_C" >&6; }
if test "${libc_cv_visibility_attribute+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5424,8 +5928,8 @@ EOF
rm -f conftest.cs
fi
-echo "$as_me:$LINENO: result: $libc_cv_visibility_attribute" >&5
-echo "${ECHO_T}$libc_cv_visibility_attribute" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_visibility_attribute" >&5
+echo "${ECHO_T}$libc_cv_visibility_attribute" >&6; }
if test $libc_cv_visibility_attribute != yes; then
{ { echo "$as_me:$LINENO: error: compiler support for visibility attribute is required" >&5
echo "$as_me: error: compiler support for visibility attribute is required" >&2;}
@@ -5434,8 +5938,8 @@ echo "$as_me: error: compiler support for visibility attribute is required" >&2;
fi
if test $libc_cv_visibility_attribute = yes; then
- echo "$as_me:$LINENO: checking for broken __attribute__((visibility()))" >&5
-echo $ECHO_N "checking for broken __attribute__((visibility()))... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for broken __attribute__((visibility()))" >&5
+echo $ECHO_N "checking for broken __attribute__((visibility()))... $ECHO_C" >&6; }
if test "${libc_cv_broken_visibility_attribute+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5458,8 +5962,8 @@ EOF
rm -f conftest.c conftest.s
fi
-echo "$as_me:$LINENO: result: $libc_cv_broken_visibility_attribute" >&5
-echo "${ECHO_T}$libc_cv_broken_visibility_attribute" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_broken_visibility_attribute" >&5
+echo "${ECHO_T}$libc_cv_broken_visibility_attribute" >&6; }
if test $libc_cv_broken_visibility_attribute = yes; then
{ { echo "$as_me:$LINENO: error: working compiler support for visibility attribute is required" >&5
echo "$as_me: error: working compiler support for visibility attribute is required" >&2;}
@@ -5467,8 +5971,8 @@ echo "$as_me: error: working compiler support for visibility attribute is requir
fi
fi
- echo "$as_me:$LINENO: checking for broken __attribute__((alias()))" >&5
-echo $ECHO_N "checking for broken __attribute__((alias()))... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for broken __attribute__((alias()))" >&5
+echo $ECHO_N "checking for broken __attribute__((alias()))... $ECHO_C" >&6; }
if test "${libc_cv_broken_alias_attribute+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5495,8 +5999,8 @@ EOF
rm -f conftest.c conftest.s
fi
-echo "$as_me:$LINENO: result: $libc_cv_broken_alias_attribute" >&5
-echo "${ECHO_T}$libc_cv_broken_alias_attribute" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_broken_alias_attribute" >&5
+echo "${ECHO_T}$libc_cv_broken_alias_attribute" >&6; }
if test $libc_cv_broken_alias_attribute = yes; then
{ { echo "$as_me:$LINENO: error: working alias attribute support required" >&5
echo "$as_me: error: working alias attribute support required" >&2;}
@@ -5504,8 +6008,8 @@ echo "$as_me: error: working alias attribute support required" >&2;}
fi
if test $libc_cv_visibility_attribute = yes; then
- echo "$as_me:$LINENO: checking whether to put _rtld_local into .sdata section" >&5
-echo $ECHO_N "checking whether to put _rtld_local into .sdata section... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking whether to put _rtld_local into .sdata section" >&5
+echo $ECHO_N "checking whether to put _rtld_local into .sdata section... $ECHO_C" >&6; }
if test "${libc_cv_have_sdata_section+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5518,8 +6022,8 @@ else
rm -f conftest.c conftest.so
fi
-echo "$as_me:$LINENO: result: $libc_cv_have_sdata_section" >&5
-echo "${ECHO_T}$libc_cv_have_sdata_section" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_have_sdata_section" >&5
+echo "${ECHO_T}$libc_cv_have_sdata_section" >&6; }
if test $libc_cv_have_sdata_section = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_SDATA_SECTION 1
@@ -5528,8 +6032,8 @@ _ACEOF
fi
fi
- echo "$as_me:$LINENO: checking for .preinit_array/.init_array/.fini_array support" >&5
-echo $ECHO_N "checking for .preinit_array/.init_array/.fini_array support... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for .preinit_array/.init_array/.fini_array support" >&5
+echo $ECHO_N "checking for .preinit_array/.init_array/.fini_array support... $ECHO_C" >&6; }
if test "${libc_cv_initfini_array+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5557,16 +6061,16 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_initfini_array" >&5
-echo "${ECHO_T}$libc_cv_initfini_array" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_initfini_array" >&5
+echo "${ECHO_T}$libc_cv_initfini_array" >&6; }
if test $libc_cv_initfini_array != yes; then
{ { echo "$as_me:$LINENO: error: Need linker with .init_array/.fini_array support." >&5
echo "$as_me: error: Need linker with .init_array/.fini_array support." >&2;}
{ (exit 1); exit 1; }; }
fi
- echo "$as_me:$LINENO: checking for libunwind-support in compiler" >&5
-echo $ECHO_N "checking for libunwind-support in compiler... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for libunwind-support in compiler" >&5
+echo $ECHO_N "checking for libunwind-support in compiler... $ECHO_C" >&6; }
if test "${libc_cv_cc_with_libunwind+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5582,8 +6086,8 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_cc_with_libunwind" >&5
-echo "${ECHO_T}$libc_cv_cc_with_libunwind" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_cc_with_libunwind" >&5
+echo "${ECHO_T}$libc_cv_cc_with_libunwind" >&6; }
if test $libc_cv_cc_with_libunwind = yes; then
cat >>confdefs.h <<\_ACEOF
@@ -5592,8 +6096,8 @@ _ACEOF
fi
- echo "$as_me:$LINENO: checking for -z nodelete option" >&5
-echo $ECHO_N "checking for -z nodelete option... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for -z nodelete option" >&5
+echo $ECHO_N "checking for -z nodelete option... $ECHO_C" >&6; }
if test "${libc_cv_z_nodelete+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5618,11 +6122,11 @@ echo "$as_me: error: linker with -z nodelete support required" >&2;}
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_z_nodelete" >&5
-echo "${ECHO_T}$libc_cv_z_nodelete" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_z_nodelete" >&5
+echo "${ECHO_T}$libc_cv_z_nodelete" >&6; }
- echo "$as_me:$LINENO: checking for -z nodlopen option" >&5
-echo $ECHO_N "checking for -z nodlopen option... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for -z nodlopen option" >&5
+echo $ECHO_N "checking for -z nodlopen option... $ECHO_C" >&6; }
if test "${libc_cv_z_nodlopen+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5647,11 +6151,11 @@ echo "$as_me: error: linker with -z nodlopen support required" >&2;}
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_z_nodlopen" >&5
-echo "${ECHO_T}$libc_cv_z_nodlopen" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_z_nodlopen" >&5
+echo "${ECHO_T}$libc_cv_z_nodlopen" >&6; }
- echo "$as_me:$LINENO: checking for -z initfirst option" >&5
-echo $ECHO_N "checking for -z initfirst option... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for -z initfirst option" >&5
+echo $ECHO_N "checking for -z initfirst option... $ECHO_C" >&6; }
if test "${libc_cv_z_initfirst+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5676,13 +6180,13 @@ echo "$as_me: error: linker with -z initfirst support required" >&2;}
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_z_initfirst" >&5
-echo "${ECHO_T}$libc_cv_z_initfirst" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_z_initfirst" >&5
+echo "${ECHO_T}$libc_cv_z_initfirst" >&6; }
case "$base_machine" in
i[34567]86 | x86_64 | powerpc* | s390* | sparc* | alpha*)
- echo "$as_me:$LINENO: checking for -z relro option" >&5
-echo $ECHO_N "checking for -z relro option... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for -z relro option" >&5
+echo $ECHO_N "checking for -z relro option... $ECHO_C" >&6; }
if test "${libc_cv_z_relro+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5705,8 +6209,8 @@ else
fi
fi
fi
-echo "$as_me:$LINENO: result: $libc_cv_z_relro" >&5
-echo "${ECHO_T}$libc_cv_z_relro" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_z_relro" >&5
+echo "${ECHO_T}$libc_cv_z_relro" >&6; }
if test "$libc_cv_z_relro" = no; then
{ { echo "$as_me:$LINENO: error: linker with -z relro support required" >&5
echo "$as_me: error: linker with -z relro support required" >&2;}
@@ -5716,8 +6220,8 @@ echo "$as_me: error: linker with -z relro support required" >&2;}
*) ;;
esac
- echo "$as_me:$LINENO: checking for -Bgroup option" >&5
-echo $ECHO_N "checking for -Bgroup option... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for -Bgroup option" >&5
+echo $ECHO_N "checking for -Bgroup option... $ECHO_C" >&6; }
if test "${libc_cv_Bgroup+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5739,12 +6243,12 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_Bgroup" >&5
-echo "${ECHO_T}$libc_cv_Bgroup" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_Bgroup" >&5
+echo "${ECHO_T}$libc_cv_Bgroup" >&6; }
- echo "$as_me:$LINENO: checking for libgcc_s suffix" >&5
-echo $ECHO_N "checking for libgcc_s suffix... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for libgcc_s suffix" >&5
+echo $ECHO_N "checking for libgcc_s suffix... $ECHO_C" >&6; }
if test "${libc_cv_libgcc_s_suffix+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5757,12 +6261,12 @@ EOF
| sed -n 's/^.* -lgcc_s\([^ ]*\) .*$/\1/p'`
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_libgcc_s_suffix" >&5
-echo "${ECHO_T}$libc_cv_libgcc_s_suffix" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_libgcc_s_suffix" >&5
+echo "${ECHO_T}$libc_cv_libgcc_s_suffix" >&6; }
- echo "$as_me:$LINENO: checking for --as-needed option" >&5
-echo $ECHO_N "checking for --as-needed option... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for --as-needed option" >&5
+echo $ECHO_N "checking for --as-needed option... $ECHO_C" >&6; }
if test "${libc_cv_as_needed+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5785,13 +6289,13 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_as_needed" >&5
-echo "${ECHO_T}$libc_cv_as_needed" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_as_needed" >&5
+echo "${ECHO_T}$libc_cv_as_needed" >&6; }
ASFLAGS_config=
- echo "$as_me:$LINENO: checking whether --noexecstack is desirable for .S files" >&5
-echo $ECHO_N "checking whether --noexecstack is desirable for .S files... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking whether --noexecstack is desirable for .S files" >&5
+echo $ECHO_N "checking whether --noexecstack is desirable for .S files... $ECHO_C" >&6; }
if test "${libc_cv_as_noexecstack+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5806,7 +6310,7 @@ EOF
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } \
&& grep -q .note.GNU-stack conftest.s \
- && { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -Wa,--noexecstack
+ && { ac_try='${CC-cc} $ASFLAGS -Wa,--noexecstack
-c -o conftest.o conftest.s 1>&5'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
@@ -5820,15 +6324,15 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_as_noexecstack" >&5
-echo "${ECHO_T}$libc_cv_as_noexecstack" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_as_noexecstack" >&5
+echo "${ECHO_T}$libc_cv_as_noexecstack" >&6; }
if test $libc_cv_as_noexecstack = yes; then
ASFLAGS_config="$ASFLAGS_config -Wa,--noexecstack"
fi
- echo "$as_me:$LINENO: checking for -z combreloc" >&5
-echo $ECHO_N "checking for -z combreloc... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for -z combreloc" >&5
+echo $ECHO_N "checking for -z combreloc... $ECHO_C" >&6; }
if test "${libc_cv_z_combreloc+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5857,8 +6361,8 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_z_combreloc" >&5
-echo "${ECHO_T}$libc_cv_z_combreloc" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_z_combreloc" >&5
+echo "${ECHO_T}$libc_cv_z_combreloc" >&6; }
if test "$libc_cv_z_combreloc" = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_Z_COMBRELOC 1
@@ -5867,8 +6371,8 @@ _ACEOF
fi
- echo "$as_me:$LINENO: checking for -z execstack" >&5
-echo $ECHO_N "checking for -z execstack... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for -z execstack" >&5
+echo $ECHO_N "checking for -z execstack... $ECHO_C" >&6; }
if test "${libc_cv_z_execstack+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5891,15 +6395,15 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_z_execstack" >&5
-echo "${ECHO_T}$libc_cv_z_execstack" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_z_execstack" >&5
+echo "${ECHO_T}$libc_cv_z_execstack" >&6; }
libc_cv_fpie=yes
- echo "$as_me:$LINENO: checking for --hash-style option" >&5
-echo $ECHO_N "checking for --hash-style option... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for --hash-style option" >&5
+echo $ECHO_N "checking for --hash-style option... $ECHO_C" >&6; }
if test "${libc_cv_hashstyle+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5921,20 +6425,20 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_hashstyle" >&5
-echo "${ECHO_T}$libc_cv_hashstyle" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_hashstyle" >&5
+echo "${ECHO_T}$libc_cv_hashstyle" >&6; }
fi
-echo "$as_me:$LINENO: checking for -fno-toplevel-reorder" >&5
-echo $ECHO_N "checking for -fno-toplevel-reorder... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for -fno-toplevel-reorder -fno-section-anchors" >&5
+echo $ECHO_N "checking for -fno-toplevel-reorder -fno-section-anchors... $ECHO_C" >&6; }
if test "${libc_cv_fno_toplevel_reorder+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat > conftest.c <<EOF
int foo;
EOF
-if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -S -fno-toplevel-reorder
+if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS -S -fno-toplevel-reorder -fno-section-anchors
conftest.c 1>&5'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
@@ -5948,17 +6452,17 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_fno_toplevel_reorder" >&5
-echo "${ECHO_T}$libc_cv_fno_toplevel_reorder" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_fno_toplevel_reorder" >&5
+echo "${ECHO_T}$libc_cv_fno_toplevel_reorder" >&6; }
if test $libc_cv_fno_toplevel_reorder = yes; then
- fno_unit_at_a_time=-fno-toplevel-reorder
+ fno_unit_at_a_time="-fno-toplevel-reorder -fno-section-anchors"
else
fno_unit_at_a_time=-fno-unit-at-a-time
fi
-echo "$as_me:$LINENO: checking for -fstack-protector" >&5
-echo $ECHO_N "checking for -fstack-protector... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for -fstack-protector" >&5
+echo $ECHO_N "checking for -fstack-protector... $ECHO_C" >&6; }
if test "${libc_cv_ssp+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -5966,7 +6470,7 @@ else
int foo;
main () { return 0;}
EOF
-if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS -fstack-protector
+if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS -Werror -fstack-protector
-o conftest conftest.c 1>&5'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
@@ -5980,12 +6484,12 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_ssp" >&5
-echo "${ECHO_T}$libc_cv_ssp" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_ssp" >&5
+echo "${ECHO_T}$libc_cv_ssp" >&6; }
-echo "$as_me:$LINENO: checking for -fgnu89-inline" >&5
-echo $ECHO_N "checking for -fgnu89-inline... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for -fgnu89-inline" >&5
+echo $ECHO_N "checking for -fgnu89-inline... $ECHO_C" >&6; }
if test "${libc_cv_gnu89_inline+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6011,8 +6515,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_gnu89_inline" >&5
-echo "${ECHO_T}$libc_cv_gnu89_inline" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_gnu89_inline" >&5
+echo "${ECHO_T}$libc_cv_gnu89_inline" >&6; }
if test $libc_cv_gnu89_inline = yes; then
libc_cv_gnu89_inline=-fgnu89-inline
else
@@ -6021,8 +6525,8 @@ fi
if test $elf != yes; then
- echo "$as_me:$LINENO: checking for .init and .fini sections" >&5
-echo $ECHO_N "checking for .init and .fini sections... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for .init and .fini sections" >&5
+echo $ECHO_N "checking for .init and .fini sections... $ECHO_C" >&6; }
if test "${libc_cv_have_initfini+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6044,38 +6548,34 @@ asm (".section .init");
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
libc_cv_have_initfini=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-libc_cv_have_initfini=no
+ libc_cv_have_initfini=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $libc_cv_have_initfini" >&5
-echo "${ECHO_T}$libc_cv_have_initfini" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_have_initfini" >&5
+echo "${ECHO_T}$libc_cv_have_initfini" >&6; }
if test $libc_cv_have_initfini = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_INITFINI 1
@@ -6085,8 +6585,8 @@ _ACEOF
fi
if test $elf = yes; then
- echo "$as_me:$LINENO: checking whether cc puts quotes around section names" >&5
-echo $ECHO_N "checking whether cc puts quotes around section names... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking whether cc puts quotes around section names" >&5
+echo $ECHO_N "checking whether cc puts quotes around section names... $ECHO_C" >&6; }
if test "${libc_cv_have_section_quotes+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6106,8 +6606,8 @@ EOF
rm -f conftest.cs
fi
-echo "$as_me:$LINENO: result: $libc_cv_have_section_quotes" >&5
-echo "${ECHO_T}$libc_cv_have_section_quotes" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_have_section_quotes" >&5
+echo "${ECHO_T}$libc_cv_have_section_quotes" >&6; }
if test $libc_cv_have_section_quotes = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_SECTION_QUOTES 1
@@ -6122,8 +6622,8 @@ if test $elf = yes; then
libc_cv_asm_underscores=no
else
if test $ac_cv_prog_cc_works = yes; then
- echo "$as_me:$LINENO: checking for _ prefix on C symbol names" >&5
-echo $ECHO_N "checking for _ prefix on C symbol names... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for _ prefix on C symbol names" >&5
+echo $ECHO_N "checking for _ prefix on C symbol names... $ECHO_C" >&6; }
if test "${libc_cv_asm_underscores+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6143,42 +6643,39 @@ glibc_foobar ();
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest$ac_exeext &&
+ $as_test_x conftest$ac_exeext; then
libc_cv_asm_underscores=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-libc_cv_asm_underscores=no
+ libc_cv_asm_underscores=no
fi
-rm -f conftest.err conftest.$ac_objext \
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_underscores" >&5
-echo "${ECHO_T}$libc_cv_asm_underscores" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_underscores" >&5
+echo "${ECHO_T}$libc_cv_asm_underscores" >&6; }
else
- echo "$as_me:$LINENO: checking for _ prefix on C symbol names" >&5
-echo $ECHO_N "checking for _ prefix on C symbol names... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for _ prefix on C symbol names" >&5
+echo $ECHO_N "checking for _ prefix on C symbol names... $ECHO_C" >&6; }
if test "${libc_cv_asm_underscores+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6208,8 +6705,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_underscores" >&5
-echo "${ECHO_T}$libc_cv_asm_underscores" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_underscores" >&5
+echo "${ECHO_T}$libc_cv_asm_underscores" >&6; }
fi
fi
if test $libc_cv_asm_underscores = no; then
@@ -6223,8 +6720,8 @@ if test $elf = yes; then
libc_cv_weak_symbols=yes
fi
-echo "$as_me:$LINENO: checking for assembler .weak directive" >&5
-echo $ECHO_N "checking for assembler .weak directive... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for assembler .weak directive" >&5
+echo $ECHO_N "checking for assembler .weak directive... $ECHO_C" >&6; }
if test "${libc_cv_asm_weak_directive+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6247,12 +6744,12 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_weak_directive" >&5
-echo "${ECHO_T}$libc_cv_asm_weak_directive" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_weak_directive" >&5
+echo "${ECHO_T}$libc_cv_asm_weak_directive" >&6; }
if test $libc_cv_asm_weak_directive = no; then
- echo "$as_me:$LINENO: checking for assembler .weakext directive" >&5
-echo $ECHO_N "checking for assembler .weakext directive... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for assembler .weakext directive" >&5
+echo $ECHO_N "checking for assembler .weakext directive... $ECHO_C" >&6; }
if test "${libc_cv_asm_weakext_directive+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6277,8 +6774,8 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_weakext_directive" >&5
-echo "${ECHO_T}$libc_cv_asm_weakext_directive" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_weakext_directive" >&5
+echo "${ECHO_T}$libc_cv_asm_weakext_directive" >&6; }
fi # no .weak
@@ -6294,8 +6791,8 @@ _ACEOF
fi
-echo "$as_me:$LINENO: checking whether CFI directives are supported" >&5
-echo $ECHO_N "checking whether CFI directives are supported... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether CFI directives are supported" >&5
+echo $ECHO_N "checking whether CFI directives are supported... $ECHO_C" >&6; }
if test "${libc_cv_asm_cfi_directives+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6324,8 +6821,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_asm_cfi_directives" >&5
-echo "${ECHO_T}$libc_cv_asm_cfi_directives" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_asm_cfi_directives" >&5
+echo "${ECHO_T}$libc_cv_asm_cfi_directives" >&6; }
if test $libc_cv_asm_cfi_directives = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_ASM_CFI_DIRECTIVES 1
@@ -6333,8 +6830,8 @@ _ACEOF
fi
-echo "$as_me:$LINENO: checking for ld --no-whole-archive" >&5
-echo $ECHO_N "checking for ld --no-whole-archive... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for ld --no-whole-archive" >&5
+echo $ECHO_N "checking for ld --no-whole-archive... $ECHO_C" >&6; }
if test "${libc_cv_ld_no_whole_archive+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6357,14 +6854,14 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_ld_no_whole_archive" >&5
-echo "${ECHO_T}$libc_cv_ld_no_whole_archive" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_ld_no_whole_archive" >&5
+echo "${ECHO_T}$libc_cv_ld_no_whole_archive" >&6; }
if test $libc_cv_ld_no_whole_archive = yes; then
no_whole_archive=-Wl,--no-whole-archive
fi
-echo "$as_me:$LINENO: checking for gcc -fexceptions" >&5
-echo $ECHO_N "checking for gcc -fexceptions... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for gcc -fexceptions" >&5
+echo $ECHO_N "checking for gcc -fexceptions... $ECHO_C" >&6; }
if test "${libc_cv_gcc_exceptions+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6387,8 +6884,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_gcc_exceptions" >&5
-echo "${ECHO_T}$libc_cv_gcc_exceptions" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_gcc_exceptions" >&5
+echo "${ECHO_T}$libc_cv_gcc_exceptions" >&6; }
if test $libc_cv_gcc_exceptions = yes; then
exceptions=-fexceptions
fi
@@ -6396,8 +6893,8 @@ fi
if test "$host_cpu" = powerpc ; then
# Check for a bug present in at least versions 2.8.x of GCC
# and versions 1.0.x of EGCS.
-echo "$as_me:$LINENO: checking whether clobbering cr0 causes problems" >&5
-echo $ECHO_N "checking whether clobbering cr0 causes problems... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether clobbering cr0 causes problems" >&5
+echo $ECHO_N "checking whether clobbering cr0 causes problems... $ECHO_C" >&6; }
if test "${libc_cv_c_asmcr0_bug+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6417,38 +6914,34 @@ main ()
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
libc_cv_c_asmcr0_bug='no'
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-libc_cv_c_asmcr0_bug='yes'
+ libc_cv_c_asmcr0_bug='yes'
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $libc_cv_c_asmcr0_bug" >&5
-echo "${ECHO_T}$libc_cv_c_asmcr0_bug" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_c_asmcr0_bug" >&5
+echo "${ECHO_T}$libc_cv_c_asmcr0_bug" >&6; }
if test "$libc_cv_c_asmcr0_bug" != 'no'; then
cat >>confdefs.h <<\_ACEOF
#define BROKEN_PPC_ASM_CR0 1
@@ -6457,8 +6950,8 @@ _ACEOF
fi
fi
-echo "$as_me:$LINENO: checking for __builtin_expect" >&5
-echo $ECHO_N "checking for __builtin_expect... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for __builtin_expect" >&5
+echo $ECHO_N "checking for __builtin_expect... $ECHO_C" >&6; }
if test "${libc_cv_gcc_builtin_expect+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6483,8 +6976,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_gcc_builtin_expect" >&5
-echo "${ECHO_T}$libc_cv_gcc_builtin_expect" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_gcc_builtin_expect" >&5
+echo "${ECHO_T}$libc_cv_gcc_builtin_expect" >&6; }
if test "$libc_cv_gcc_builtin_expect" = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_BUILTIN_EXPECT 1
@@ -6492,8 +6985,8 @@ _ACEOF
fi
-echo "$as_me:$LINENO: checking for __builtin_memset" >&5
-echo $ECHO_N "checking for __builtin_memset... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for __builtin_memset" >&5
+echo $ECHO_N "checking for __builtin_memset... $ECHO_C" >&6; }
if test "${libc_cv_gcc_builtin_memset+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6516,8 +7009,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_gcc_builtin_memset" >&5
-echo "${ECHO_T}$libc_cv_gcc_builtin_memset" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_gcc_builtin_memset" >&5
+echo "${ECHO_T}$libc_cv_gcc_builtin_memset" >&6; }
if test "$libc_cv_gcc_builtin_memset" = yes ; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_BUILTIN_MEMSET 1
@@ -6525,8 +7018,8 @@ _ACEOF
fi
-echo "$as_me:$LINENO: checking for redirection of built-in functions" >&5
-echo $ECHO_N "checking for redirection of built-in functions... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for redirection of built-in functions" >&5
+echo $ECHO_N "checking for redirection of built-in functions... $ECHO_C" >&6; }
if test "${libc_cv_gcc_builtin_redirection+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6550,8 +7043,8 @@ else
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_gcc_builtin_redirection" >&5
-echo "${ECHO_T}$libc_cv_gcc_builtin_redirection" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_gcc_builtin_redirection" >&5
+echo "${ECHO_T}$libc_cv_gcc_builtin_redirection" >&6; }
if test "$libc_cv_gcc_builtin_redirection" = yes ; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_BUILTIN_REDIRECTION 1
@@ -6560,8 +7053,8 @@ _ACEOF
fi
if test "x$use__thread" != xno; then
- echo "$as_me:$LINENO: checking for __thread" >&5
-echo $ECHO_N "checking for __thread... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for __thread" >&5
+echo $ECHO_N "checking for __thread... $ECHO_C" >&6; }
if test "${libc_cv_gcc___thread+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6580,8 +7073,8 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_gcc___thread" >&5
-echo "${ECHO_T}$libc_cv_gcc___thread" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_gcc___thread" >&5
+echo "${ECHO_T}$libc_cv_gcc___thread" >&6; }
if test "$libc_cv_gcc___thread" = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE___THREAD 1
@@ -6593,8 +7086,8 @@ else
fi
if test "$libc_cv_gcc___thread" = yes; then
- echo "$as_me:$LINENO: checking for tls_model attribute" >&5
-echo $ECHO_N "checking for tls_model attribute... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for tls_model attribute" >&5
+echo $ECHO_N "checking for tls_model attribute... $ECHO_C" >&6; }
if test "${libc_cv_gcc_tls_model_attr+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6613,8 +7106,8 @@ EOF
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_gcc_tls_model_attr" >&5
-echo "${ECHO_T}$libc_cv_gcc_tls_model_attr" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_gcc_tls_model_attr" >&5
+echo "${ECHO_T}$libc_cv_gcc_tls_model_attr" >&6; }
if test "$libc_cv_gcc_tls_model_attr" = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_TLS_MODEL_ATTRIBUTE 1
@@ -6623,8 +7116,37 @@ _ACEOF
fi
fi
-echo "$as_me:$LINENO: checking for libgd" >&5
-echo $ECHO_N "checking for libgd... $ECHO_C" >&6
+if test -n "$submachine"; then
+ { echo "$as_me:$LINENO: checking for compiler option for CPU variant" >&5
+echo $ECHO_N "checking for compiler option for CPU variant... $ECHO_C" >&6; }
+if test "${libc_cv_cc_submachine+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ libc_cv_cc_submachine=no
+ for opt in "-march=$submachine" "-mcpu=$submachine"; do
+ if { ac_try='${CC-cc} $opt -xc /dev/null -S -o /dev/null'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ libc_cv_cc_submachine="$opt"
+ break
+ fi
+ done
+fi
+{ echo "$as_me:$LINENO: result: $libc_cv_cc_submachine" >&5
+echo "${ECHO_T}$libc_cv_cc_submachine" >&6; }
+ if test "x$libc_cv_cc_submachine" = xno; then
+ { { echo "$as_me:$LINENO: error: ${CC-cc} does not support $submachine" >&5
+echo "$as_me: error: ${CC-cc} does not support $submachine" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+fi
+
+
+{ echo "$as_me:$LINENO: checking for libgd" >&5
+echo $ECHO_N "checking for libgd... $ECHO_C" >&6; }
if test "$with_gd" != "no"; then
old_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS $libgd_include"
@@ -6648,35 +7170,32 @@ gdImagePng (0, 0)
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest$ac_exeext &&
+ $as_test_x conftest$ac_exeext; then
LIBGD=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-LIBGD=no
+ LIBGD=no
fi
-rm -f conftest.err conftest.$ac_objext \
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
CFLAGS="$old_CFLAGS"
LDFLAGS="$old_LDFLAGS"
@@ -6684,8 +7203,8 @@ rm -f conftest.err conftest.$ac_objext \
else
LIBGD=no
fi
-echo "$as_me:$LINENO: result: $LIBGD" >&5
-echo "${ECHO_T}$LIBGD" >&6
+{ echo "$as_me:$LINENO: result: $LIBGD" >&5
+echo "${ECHO_T}$LIBGD" >&6; }
# SELinux detection
@@ -6693,8 +7212,8 @@ if test x$with_selinux = xno ; then
have_selinux=no;
else
# See if we have the SELinux library
- echo "$as_me:$LINENO: checking for is_selinux_enabled in -lselinux" >&5
-echo $ECHO_N "checking for is_selinux_enabled in -lselinux... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for is_selinux_enabled in -lselinux" >&5
+echo $ECHO_N "checking for is_selinux_enabled in -lselinux... $ECHO_C" >&6; }
if test "${ac_cv_lib_selinux_is_selinux_enabled+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6707,56 +7226,53 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-/* Override any gcc2 internal prototype to avoid an error. */
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
char is_selinux_enabled ();
int
main ()
{
-is_selinux_enabled ();
+return is_selinux_enabled ();
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest$ac_exeext &&
+ $as_test_x conftest$ac_exeext; then
ac_cv_lib_selinux_is_selinux_enabled=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_lib_selinux_is_selinux_enabled=no
+ ac_cv_lib_selinux_is_selinux_enabled=no
fi
-rm -f conftest.err conftest.$ac_objext \
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_is_selinux_enabled" >&5
-echo "${ECHO_T}$ac_cv_lib_selinux_is_selinux_enabled" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_is_selinux_enabled" >&5
+echo "${ECHO_T}$ac_cv_lib_selinux_is_selinux_enabled" >&6; }
if test $ac_cv_lib_selinux_is_selinux_enabled = yes; then
have_selinux=yes
else
@@ -6765,8 +7281,8 @@ fi
# See if we have the SELinux header with the NSCD permissions in it.
if test x$have_selinux = xyes ; then
- echo "$as_me:$LINENO: checking for NSCD Flask permissions in selinux/av_permissions.h" >&5
-echo $ECHO_N "checking for NSCD Flask permissions in selinux/av_permissions.h... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for NSCD Flask permissions in selinux/av_permissions.h" >&5
+echo $ECHO_N "checking for NSCD Flask permissions in selinux/av_permissions.h... $ECHO_C" >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
@@ -6787,37 +7303,33 @@ main ()
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
have_selinux=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-have_selinux=no
+ have_selinux=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- echo "$as_me:$LINENO: result: $have_selinux" >&5
-echo "${ECHO_T}$have_selinux" >&6
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ { echo "$as_me:$LINENO: result: $have_selinux" >&5
+echo "${ECHO_T}$have_selinux" >&6; }
fi
if test x$with_selinux = xyes ; then
@@ -6837,8 +7349,8 @@ _ACEOF
# See if we have the libaudit library
- echo "$as_me:$LINENO: checking for audit_log_user_avc_message in -laudit" >&5
-echo $ECHO_N "checking for audit_log_user_avc_message in -laudit... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for audit_log_user_avc_message in -laudit" >&5
+echo $ECHO_N "checking for audit_log_user_avc_message in -laudit... $ECHO_C" >&6; }
if test "${ac_cv_lib_audit_audit_log_user_avc_message+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6851,56 +7363,53 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-/* Override any gcc2 internal prototype to avoid an error. */
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
char audit_log_user_avc_message ();
int
main ()
{
-audit_log_user_avc_message ();
+return audit_log_user_avc_message ();
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest$ac_exeext &&
+ $as_test_x conftest$ac_exeext; then
ac_cv_lib_audit_audit_log_user_avc_message=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_lib_audit_audit_log_user_avc_message=no
+ ac_cv_lib_audit_audit_log_user_avc_message=no
fi
-rm -f conftest.err conftest.$ac_objext \
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_audit_audit_log_user_avc_message" >&5
-echo "${ECHO_T}$ac_cv_lib_audit_audit_log_user_avc_message" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_audit_audit_log_user_avc_message" >&5
+echo "${ECHO_T}$ac_cv_lib_audit_audit_log_user_avc_message" >&6; }
if test $ac_cv_lib_audit_audit_log_user_avc_message = yes; then
have_libaudit=yes
else
@@ -6917,8 +7426,8 @@ _ACEOF
# See if we have the libcap library
- echo "$as_me:$LINENO: checking for cap_init in -lcap" >&5
-echo $ECHO_N "checking for cap_init in -lcap... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking for cap_init in -lcap" >&5
+echo $ECHO_N "checking for cap_init in -lcap... $ECHO_C" >&6; }
if test "${ac_cv_lib_cap_cap_init+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -6931,56 +7440,53 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-/* Override any gcc2 internal prototype to avoid an error. */
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
char cap_init ();
int
main ()
{
-cap_init ();
+return cap_init ();
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest$ac_exeext &&
+ $as_test_x conftest$ac_exeext; then
ac_cv_lib_cap_cap_init=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_lib_cap_cap_init=no
+ ac_cv_lib_cap_cap_init=no
fi
-rm -f conftest.err conftest.$ac_objext \
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_cap_cap_init" >&5
-echo "${ECHO_T}$ac_cv_lib_cap_cap_init" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_cap_cap_init" >&5
+echo "${ECHO_T}$ac_cv_lib_cap_cap_init" >&6; }
if test $ac_cv_lib_cap_cap_init = yes; then
have_libcap=yes
else
@@ -6999,23 +7505,170 @@ fi
-echo "$as_me:$LINENO: checking for egrep" >&5
-echo $ECHO_N "checking for egrep... $ECHO_C" >&6
-if test "${ac_cv_prog_egrep+set}" = set; then
+{ echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
+echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
+if test "${ac_cv_path_GREP+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if echo a | (grep -E '(a|b)') >/dev/null 2>&1
- then ac_cv_prog_egrep='grep -E'
- else ac_cv_prog_egrep='egrep'
+ # Extract the first word of "grep ggrep" to use in msg output
+if test -z "$GREP"; then
+set dummy grep ggrep; ac_prog_name=$2
+if test "${ac_cv_path_GREP+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_path_GREP_found=false
+# Loop through the user's path and test for each of PROGNAME-LIST
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_prog in grep ggrep; do
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
+ { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
+ # Check for GNU ac_path_GREP and select it if it is found.
+ # Check for GNU $ac_path_GREP
+case `"$ac_path_GREP" --version 2>&1` in
+*GNU*)
+ ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
+*)
+ ac_count=0
+ echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
+ while :
+ do
+ cat "conftest.in" "conftest.in" >"conftest.tmp"
+ mv "conftest.tmp" "conftest.in"
+ cp "conftest.in" "conftest.nl"
+ echo 'GREP' >> "conftest.nl"
+ "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
+ ac_count=`expr $ac_count + 1`
+ if test $ac_count -gt ${ac_path_GREP_max-0}; then
+ # Best one so far, save it but keep looking for a better one
+ ac_cv_path_GREP="$ac_path_GREP"
+ ac_path_GREP_max=$ac_count
fi
+ # 10*(2^10) chars as input seems more than enough
+ test $ac_count -gt 10 && break
+ done
+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
+esac
+
+
+ $ac_path_GREP_found && break 3
+ done
+done
+
+done
+IFS=$as_save_IFS
+
+
+fi
+
+GREP="$ac_cv_path_GREP"
+if test -z "$GREP"; then
+ { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
+echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
+ { (exit 1); exit 1; }; }
+fi
+
+else
+ ac_cv_path_GREP=$GREP
+fi
+
+
fi
-echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
-echo "${ECHO_T}$ac_cv_prog_egrep" >&6
- EGREP=$ac_cv_prog_egrep
+{ echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
+echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
+ GREP="$ac_cv_path_GREP"
-echo "$as_me:$LINENO: checking for ANSI C header files" >&5
-echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for egrep" >&5
+echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
+if test "${ac_cv_path_EGREP+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
+ then ac_cv_path_EGREP="$GREP -E"
+ else
+ # Extract the first word of "egrep" to use in msg output
+if test -z "$EGREP"; then
+set dummy egrep; ac_prog_name=$2
+if test "${ac_cv_path_EGREP+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_path_EGREP_found=false
+# Loop through the user's path and test for each of PROGNAME-LIST
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_prog in egrep; do
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
+ { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
+ # Check for GNU ac_path_EGREP and select it if it is found.
+ # Check for GNU $ac_path_EGREP
+case `"$ac_path_EGREP" --version 2>&1` in
+*GNU*)
+ ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
+*)
+ ac_count=0
+ echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
+ while :
+ do
+ cat "conftest.in" "conftest.in" >"conftest.tmp"
+ mv "conftest.tmp" "conftest.in"
+ cp "conftest.in" "conftest.nl"
+ echo 'EGREP' >> "conftest.nl"
+ "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
+ ac_count=`expr $ac_count + 1`
+ if test $ac_count -gt ${ac_path_EGREP_max-0}; then
+ # Best one so far, save it but keep looking for a better one
+ ac_cv_path_EGREP="$ac_path_EGREP"
+ ac_path_EGREP_max=$ac_count
+ fi
+ # 10*(2^10) chars as input seems more than enough
+ test $ac_count -gt 10 && break
+ done
+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
+esac
+
+
+ $ac_path_EGREP_found && break 3
+ done
+done
+
+done
+IFS=$as_save_IFS
+
+
+fi
+
+EGREP="$ac_cv_path_EGREP"
+if test -z "$EGREP"; then
+ { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
+echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
+ { (exit 1); exit 1; }; }
+fi
+
+else
+ ac_cv_path_EGREP=$EGREP
+fi
+
+
+ fi
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
+echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
+ EGREP="$ac_cv_path_EGREP"
+
+
+{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5
+echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
if test "${ac_cv_header_stdc+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -7039,35 +7692,31 @@ main ()
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_cv_header_stdc=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_header_stdc=no
+ ac_cv_header_stdc=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
@@ -7123,6 +7772,7 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
#include <ctype.h>
+#include <stdlib.h>
#if ((' ' & 0x0FF) == 0x020)
# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
@@ -7142,18 +7792,27 @@ main ()
for (i = 0; i < 256; i++)
if (XOR (islower (i), ISLOWER (i))
|| toupper (i) != TOUPPER (i))
- exit(2);
- exit (0);
+ return 2;
+ return 0;
}
_ACEOF
rm -f conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_link") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+ { (case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_try") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
@@ -7166,12 +7825,14 @@ sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
ac_cv_header_stdc=no
fi
-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
+
+
fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
-echo "${ECHO_T}$ac_cv_header_stdc" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
+echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
if test $ac_cv_header_stdc = yes; then
cat >>confdefs.h <<\_ACEOF
@@ -7194,9 +7855,9 @@ for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
inttypes.h stdint.h unistd.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
+{ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -7210,38 +7871,35 @@ $ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-eval "$as_ac_Header=no"
+ eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+ac_res=`eval echo '${'$as_ac_Header'}'`
+ { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
if test `eval echo '${'$as_ac_Header'}'` = yes; then
cat >>confdefs.h <<_ACEOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
@@ -7252,8 +7910,8 @@ fi
done
-echo "$as_me:$LINENO: checking for long double" >&5
-echo $ECHO_N "checking for long double... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for long double" >&5
+echo $ECHO_N "checking for long double... $ECHO_C" >&6; }
if test "${ac_cv_type_long_double+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -7264,61 +7922,57 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
+typedef long double ac__type_new_;
int
main ()
{
-if ((long double *) 0)
+if ((ac__type_new_ *) 0)
return 0;
-if (sizeof (long double))
+if (sizeof (ac__type_new_))
return 0;
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_cv_type_long_double=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type_long_double=no
+ ac_cv_type_long_double=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_type_long_double" >&5
-echo "${ECHO_T}$ac_cv_type_long_double" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_type_long_double" >&5
+echo "${ECHO_T}$ac_cv_type_long_double" >&6; }
-echo "$as_me:$LINENO: checking size of long double" >&5
-echo $ECHO_N "checking size of long double... $ECHO_C" >&6
+# The cast to long int works around a bug in the HP C Compiler
+# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
+# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
+# This bug is HP SR number 8606223364.
+{ echo "$as_me:$LINENO: checking size of long double" >&5
+echo $ECHO_N "checking size of long double... $ECHO_C" >&6; }
if test "${ac_cv_sizeof_long_double+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type_long_double" = yes; then
- # The cast to unsigned long works around a bug in the HP C Compiler
- # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
- # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
- # This bug is HP SR number 8606223364.
if test "$cross_compiling" = yes; then
# Depending upon the size, compute the lo and hi bounds.
cat >conftest.$ac_ext <<_ACEOF
@@ -7328,10 +7982,11 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
+ typedef long double ac__type_sizeof_;
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long double))) >= 0)];
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
test_array [0] = 0
;
@@ -7339,27 +7994,22 @@ test_array [0] = 0
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_lo=0 ac_mid=0
while :; do
cat >conftest.$ac_ext <<_ACEOF
@@ -7369,10 +8019,11 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
+ typedef long double ac__type_sizeof_;
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long double))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
test_array [0] = 0
;
@@ -7380,56 +8031,53 @@ test_array [0] = 0
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_hi=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr $ac_mid + 1`
- if test $ac_lo -le $ac_mid; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid + 1`
+ ac_lo=`expr $ac_mid + 1`
+ if test $ac_lo -le $ac_mid; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid + 1`
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
done
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-cat >conftest.$ac_ext <<_ACEOF
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
+ typedef long double ac__type_sizeof_;
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long double))) < 0)];
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
test_array [0] = 0
;
@@ -7437,27 +8085,22 @@ test_array [0] = 0
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_hi=-1 ac_mid=-1
while :; do
cat >conftest.$ac_ext <<_ACEOF
@@ -7467,10 +8110,11 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
+ typedef long double ac__type_sizeof_;
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long double))) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
test_array [0] = 0
;
@@ -7478,50 +8122,48 @@ test_array [0] = 0
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_lo=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_hi=`expr '(' $ac_mid ')' - 1`
- if test $ac_mid -le $ac_hi; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid`
+ ac_hi=`expr '(' $ac_mid ')' - 1`
+ if test $ac_mid -le $ac_hi; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid`
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
done
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo= ac_hi=
+ ac_lo= ac_hi=
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
# Binary search between lo and hi bounds.
while test "x$ac_lo" != "x$ac_hi"; do
ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
@@ -7532,10 +8174,11 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
+ typedef long double ac__type_sizeof_;
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long double))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
test_array [0] = 0
;
@@ -7543,52 +8186,45 @@ test_array [0] = 0
}
_ACEOF
rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
ac_hi=$ac_mid
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr '(' $ac_mid ')' + 1`
+ ac_lo=`expr '(' $ac_mid ')' + 1`
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
done
case $ac_lo in
?*) ac_cv_sizeof_long_double=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long double), 77
+'') if test "$ac_cv_type_long_double" = yes; then
+ { { echo "$as_me:$LINENO: error: cannot compute sizeof (long double)
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long double), 77
+echo "$as_me: error: cannot compute sizeof (long double)
See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; } ;;
+ { (exit 77); exit 77; }; }
+ else
+ ac_cv_sizeof_long_double=0
+ fi ;;
esac
else
- if test "$cross_compiling" = yes; then
- { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
-else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
@@ -7596,8 +8232,9 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
-long longval () { return (long) (sizeof (long double)); }
-unsigned long ulongval () { return (long) (sizeof (long double)); }
+ typedef long double ac__type_sizeof_;
+static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
+static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
#include <stdio.h>
#include <stdlib.h>
int
@@ -7606,35 +8243,44 @@ main ()
FILE *f = fopen ("conftest.val", "w");
if (! f)
- exit (1);
- if (((long) (sizeof (long double))) < 0)
+ return 1;
+ if (((long int) (sizeof (ac__type_sizeof_))) < 0)
{
- long i = longval ();
- if (i != ((long) (sizeof (long double))))
- exit (1);
+ long int i = longval ();
+ if (i != ((long int) (sizeof (ac__type_sizeof_))))
+ return 1;
fprintf (f, "%ld\n", i);
}
else
{
- unsigned long i = ulongval ();
- if (i != ((long) (sizeof (long double))))
- exit (1);
+ unsigned long int i = ulongval ();
+ if (i != ((long int) (sizeof (ac__type_sizeof_))))
+ return 1;
fprintf (f, "%lu\n", i);
}
- exit (ferror (f) || fclose (f) != 0);
+ return ferror (f) || fclose (f) != 0;
;
return 0;
}
_ACEOF
rm -f conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_link") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+ { (case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_try") 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
@@ -7645,22 +8291,25 @@ echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long double), 77
+if test "$ac_cv_type_long_double" = yes; then
+ { { echo "$as_me:$LINENO: error: cannot compute sizeof (long double)
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long double), 77
+echo "$as_me: error: cannot compute sizeof (long double)
See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
-fi
-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+ { (exit 77); exit 77; }; }
+ else
+ ac_cv_sizeof_long_double=0
+ fi
fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
rm -f conftest.val
-else
- ac_cv_sizeof_long_double=0
-fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_double" >&5
-echo "${ECHO_T}$ac_cv_sizeof_long_double" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_double" >&5
+echo "${ECHO_T}$ac_cv_sizeof_long_double" >&6; }
+
+
+
cat >>confdefs.h <<_ACEOF
#define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double
_ACEOF
@@ -7688,8 +8337,8 @@ for dir in $sysnames; do
*) dest=$srcdir/$dir ;;
esac
if test -r $dest/configure; then
- echo "$as_me:$LINENO: result: running configure fragment for $dir" >&5
-echo "${ECHO_T}running configure fragment for $dir" >&6
+ { echo "$as_me:$LINENO: result: running configure fragment for $dir" >&5
+echo "${ECHO_T}running configure fragment for $dir" >&6; }
. $dest/configure
fi
@@ -7720,8 +8369,8 @@ if test "$uname" = "sysdeps/generic"; then
config_release=`echo $config_os | sed s/$uname_sysname//`
fi
- echo "$as_me:$LINENO: checking OS release for uname" >&5
-echo $ECHO_N "checking OS release for uname... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking OS release for uname" >&5
+echo $ECHO_N "checking OS release for uname... $ECHO_C" >&6; }
if test "${libc_cv_uname_release+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -7746,12 +8395,12 @@ else
libc_cv_uname_release=unknown
fi
fi
-echo "$as_me:$LINENO: result: $libc_cv_uname_release" >&5
-echo "${ECHO_T}$libc_cv_uname_release" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_uname_release" >&5
+echo "${ECHO_T}$libc_cv_uname_release" >&6; }
uname_release="$libc_cv_uname_release"
- echo "$as_me:$LINENO: checking OS version for uname" >&5
-echo $ECHO_N "checking OS version for uname... $ECHO_C" >&6
+ { echo "$as_me:$LINENO: checking OS version for uname" >&5
+echo $ECHO_N "checking OS version for uname... $ECHO_C" >&6; }
if test "${libc_cv_uname_version+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -7770,8 +8419,8 @@ else
libc_cv_uname_version=unknown
fi
fi
-echo "$as_me:$LINENO: result: $libc_cv_uname_version" >&5
-echo "${ECHO_T}$libc_cv_uname_version" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_uname_version" >&5
+echo "${ECHO_T}$libc_cv_uname_version" >&6; }
uname_version="$libc_cv_uname_version"
config_uname=config-name.h:config-name.in
@@ -7787,16 +8436,16 @@ _ACEOF
# Test for old glibc 2.0.x headers so that they can be removed properly
# Search only in includedir.
-echo "$as_me:$LINENO: checking for old glibc 2.0.x headers" >&5
-echo $ECHO_N "checking for old glibc 2.0.x headers... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for old glibc 2.0.x headers" >&5
+echo $ECHO_N "checking for old glibc 2.0.x headers... $ECHO_C" >&6; }
if eval test -f "${includedir}/elfclass.h" -a -f "${includedir}/fcntlbits.h"
then
old_glibc_headers=yes
else
old_glibc_headers=no
fi
-echo "$as_me:$LINENO: result: $old_glibc_headers" >&5
-echo "${ECHO_T}$old_glibc_headers" >&6
+{ echo "$as_me:$LINENO: result: $old_glibc_headers" >&5
+echo "${ECHO_T}$old_glibc_headers" >&6; }
if test ${old_glibc_headers} = yes; then
{ echo "$as_me:$LINENO: WARNING: *** During \"make install\" old headers from glibc 2.0.x will" >&5
echo "$as_me: WARNING: *** During \"make install\" old headers from glibc 2.0.x will" >&2;}
@@ -7834,8 +8483,8 @@ if test $shared = default; then
shared=$elf
fi
-echo "$as_me:$LINENO: checking whether -fPIC is default" >&5
-echo $ECHO_N "checking whether -fPIC is default... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether -fPIC is default" >&5
+echo $ECHO_N "checking whether -fPIC is default... $ECHO_C" >&6; }
if test "${pic_default+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -7850,8 +8499,8 @@ if eval "${CC-cc} -S conftest.c 2>&5 1>&5"; then
fi
rm -f conftest.*
fi
-echo "$as_me:$LINENO: result: $pic_default" >&5
-echo "${ECHO_T}$pic_default" >&6
+{ echo "$as_me:$LINENO: result: $pic_default" >&5
+echo "${ECHO_T}$pic_default" >&6; }
@@ -7875,9 +8524,9 @@ RELEASE=`sed -n -e 's/^#define RELEASE "\([^"]*\)"/\1/p' < $srcdir/version.h`
- ac_config_files="$ac_config_files config.make ${config_makefile} ${config_uname}"
+ac_config_files="$ac_config_files config.make ${config_makefile} ${config_uname}"
- ac_config_commands="$ac_config_commands default"
+ac_config_commands="$ac_config_commands default"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
@@ -7897,39 +8546,58 @@ _ACEOF
# The following way of writing the cache mishandles newlines in values,
# but we know of no workaround that is simple, portable, and efficient.
-# So, don't put newlines in cache variables' values.
+# So, we kill variables containing newlines.
# Ultrix sh set writes to stderr and can't be redirected directly,
# and sets the high bit in the cache file unless we assign to the vars.
-{
+(
+ for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
+ eval ac_val=\$$ac_var
+ case $ac_val in #(
+ *${as_nl}*)
+ case $ac_var in #(
+ *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
+echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
+ esac
+ case $ac_var in #(
+ _ | IFS | as_nl) ;; #(
+ *) $as_unset $ac_var ;;
+ esac ;;
+ esac
+ done
+
(set) 2>&1 |
- case `(ac_space=' '; set | grep ac_space) 2>&1` in
- *ac_space=\ *)
+ case $as_nl`(ac_space=' '; set) 2>&1` in #(
+ *${as_nl}ac_space=\ *)
# `set' does not quote correctly, so add quotes (double-quote
# substitution turns \\\\ into \\, and sed turns \\ into \).
sed -n \
"s/'/'\\\\''/g;
s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;;
+ ;; #(
*)
# `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n \
- "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
+ sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
;;
- esac;
-} |
+ esac |
+ sort
+) |
sed '
+ /^ac_cv_env_/b end
t clear
- : clear
+ :clear
s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
t end
- /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- : end' >>confcache
-if diff $cache_file confcache >/dev/null 2>&1; then :; else
- if test -w $cache_file; then
- test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
+ s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
+ :end' >>confcache
+if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
+ if test -w "$cache_file"; then
+ test "x$cache_file" != "x/dev/null" &&
+ { echo "$as_me:$LINENO: updating cache $cache_file" >&5
+echo "$as_me: updating cache $cache_file" >&6;}
cat confcache >$cache_file
else
- echo "not updating unwritable cache $cache_file"
+ { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
+echo "$as_me: not updating unwritable cache $cache_file" >&6;}
fi
fi
rm -f confcache
@@ -7938,32 +8606,18 @@ test "x$prefix" = xNONE && prefix=$ac_default_prefix
# Let make expand exec_prefix.
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-# VPATH may cause trouble with some makes, so we remove $(srcdir),
-# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=/{
-s/:*\$(srcdir):*/:/;
-s/:*\${srcdir}:*/:/;
-s/:*@srcdir@:*/:/;
-s/^\([^=]*=[ ]*\):*/\1/;
-s/:*$//;
-s/^[^=]*=[ ]*$//;
-}'
-fi
-
DEFS=-DHAVE_CONFIG_H
ac_libobjs=
ac_ltlibobjs=
for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
# 1. Remove the extension, and $U if already installed.
- ac_i=`echo "$ac_i" |
- sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
- # 2. Add them.
- ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
- ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
+ ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
+ ac_i=`echo "$ac_i" | sed "$ac_script"`
+ # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
+ # will be set to the directory where LIBOBJS objects are built.
+ ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
+ ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
done
LIBOBJS=$ac_libobjs
@@ -7994,17 +8648,45 @@ cat >>$CONFIG_STATUS <<\_ACEOF
## M4sh Initialization. ##
## --------------------- ##
-# Be Bourne compatible
+# Be more Bourne compatible
+DUALCASE=1; export DUALCASE # for MKS sh
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
emulate sh
NULLCMD=:
# Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
# is contrary to our usage. Disable this feature.
alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
- set -o posix
+ setopt NO_GLOB_SUBST
+else
+ case `(set -o) 2>/dev/null` in
+ *posix*) set -o posix ;;
+esac
+
+fi
+
+
+
+
+# PATH needs CR
+# Avoid depending upon Character Ranges.
+as_cr_letters='abcdefghijklmnopqrstuvwxyz'
+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
+as_cr_Letters=$as_cr_letters$as_cr_LETTERS
+as_cr_digits='0123456789'
+as_cr_alnum=$as_cr_Letters$as_cr_digits
+
+# The user is always right.
+if test "${PATH_SEPARATOR+set}" != set; then
+ echo "#! /bin/sh" >conf$$.sh
+ echo "exit 0" >>conf$$.sh
+ chmod +x conf$$.sh
+ if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
+ PATH_SEPARATOR=';'
+ else
+ PATH_SEPARATOR=:
+ fi
+ rm -f conf$$.sh
fi
-DUALCASE=1; export DUALCASE # for MKS sh
# Support unset when possible.
if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
@@ -8014,8 +8696,43 @@ else
fi
+# IFS
+# We need space, tab and new line, in precisely that order. Quoting is
+# there to prevent editors from complaining about space-tab.
+# (If _AS_PATH_WALK were called with IFS unset, it would disable word
+# splitting by setting IFS to empty value.)
+as_nl='
+'
+IFS=" "" $as_nl"
+
+# Find who we are. Look in the path if we contain no directory separator.
+case $0 in
+ *[\\/]* ) as_myself=$0 ;;
+ *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
+done
+IFS=$as_save_IFS
+
+ ;;
+esac
+# We did not find ourselves, most probably we were run as `sh COMMAND'
+# in which case we are not to be found in the path.
+if test "x$as_myself" = x; then
+ as_myself=$0
+fi
+if test ! -f "$as_myself"; then
+ echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
+ { (exit 1); exit 1; }
+fi
+
# Work around bugs in pre-3.0 UWIN ksh.
-$as_unset ENV MAIL MAILPATH
+for as_var in ENV MAIL MAILPATH
+do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
+done
PS1='$ '
PS2='> '
PS4='+ '
@@ -8029,18 +8746,19 @@ do
if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
eval $as_var=C; export $as_var
else
- $as_unset $as_var
+ ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
fi
done
# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1; then
+if expr a : '\(a\)' >/dev/null 2>&1 &&
+ test "X`expr 00001 : '.*\(...\)'`" = X001; then
as_expr=expr
else
as_expr=false
fi
-if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
as_basename=basename
else
as_basename=false
@@ -8048,159 +8766,120 @@ fi
# Name of the executable.
-as_me=`$as_basename "$0" ||
+as_me=`$as_basename -- "$0" ||
$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)$' \| \
- . : '\(.\)' 2>/dev/null ||
+ X"$0" : 'X\(/\)' \| . 2>/dev/null ||
echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
- /^X\/\(\/\/\)$/{ s//\1/; q; }
- /^X\/\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
-
-
-# PATH needs CR, and LINENO needs CR and PATH.
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
+ sed '/^.*\/\([^/][^/]*\)\/*$/{
+ s//\1/
+ q
+ }
+ /^X\/\(\/\/\)$/{
+ s//\1/
+ q
+ }
+ /^X\/\(\/\).*/{
+ s//\1/
+ q
+ }
+ s/.*/./; q'`
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
+# CDPATH.
+$as_unset CDPATH
- as_lineno_1=$LINENO
- as_lineno_2=$LINENO
- as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
- test "x$as_lineno_1" != "x$as_lineno_2" &&
- test "x$as_lineno_3" = "x$as_lineno_2" || {
- # Find who we are. Look in the path if we contain no path at all
- # relative or not.
- case $0 in
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
- ;;
- esac
- # We did not find ourselves, most probably we were run as `sh COMMAND'
- # in which case we are not to be found in the path.
- if test "x$as_myself" = x; then
- as_myself=$0
- fi
- if test ! -f "$as_myself"; then
- { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
-echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
- { (exit 1); exit 1; }; }
- fi
- case $CONFIG_SHELL in
- '')
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for as_base in sh bash ksh sh5; do
- case $as_dir in
- /*)
- if ("$as_dir/$as_base" -c '
as_lineno_1=$LINENO
as_lineno_2=$LINENO
- as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
test "x$as_lineno_1" != "x$as_lineno_2" &&
- test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
- $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
- $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
- CONFIG_SHELL=$as_dir/$as_base
- export CONFIG_SHELL
- exec "$CONFIG_SHELL" "$0" ${1+"$@"}
- fi;;
- esac
- done
-done
-;;
- esac
+ test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
# Create $as_me.lineno as a copy of $as_myself, but with $LINENO
# uniformly replaced by the line number. The first 'sed' inserts a
- # line-number line before each line; the second 'sed' does the real
- # work. The second script uses 'N' to pair each line-number line
- # with the numbered line, and appends trailing '-' during
- # substitution so that $LINENO is not a special case at line end.
+ # line-number line after each line using $LINENO; the second 'sed'
+ # does the real work. The second script uses 'N' to pair each
+ # line-number line with the line containing $LINENO, and appends
+ # trailing '-' during substitution so that $LINENO is not a special
+ # case at line end.
# (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
- # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
- sed '=' <$as_myself |
+ # scripts with optimization help from Paolo Bonzini. Blame Lee
+ # E. McMahon (1931-1989) for sed's syntax. :-)
+ sed -n '
+ p
+ /[$]LINENO/=
+ ' <$as_myself |
sed '
+ s/[$]LINENO.*/&-/
+ t lineno
+ b
+ :lineno
N
- s,$,-,
- : loop
- s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
+ :loop
+ s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
t loop
- s,-$,,
- s,^['$as_cr_digits']*\n,,
+ s/-\n.*//
' >$as_me.lineno &&
- chmod +x $as_me.lineno ||
- { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
-echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
+ chmod +x "$as_me.lineno" ||
+ { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
{ (exit 1); exit 1; }; }
# Don't try to exec as it changes $[0], causing all sort of problems
# (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensible to this).
- . ./$as_me.lineno
+ # original and so on. Autoconf is especially sensitive to this).
+ . "./$as_me.lineno"
# Exit status is that of the last command.
exit
}
-case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
- *c*,-n*) ECHO_N= ECHO_C='
-' ECHO_T=' ' ;;
- *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
- *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
+if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
+ as_dirname=dirname
+else
+ as_dirname=false
+fi
+
+ECHO_C= ECHO_N= ECHO_T=
+case `echo -n x` in
+-n*)
+ case `echo 'x\c'` in
+ *c*) ECHO_T=' ';; # ECHO_T is single tab character.
+ *) ECHO_C='\c';;
+ esac;;
+*)
+ ECHO_N='-n';;
esac
-if expr a : '\(a\)' >/dev/null 2>&1; then
+if expr a : '\(a\)' >/dev/null 2>&1 &&
+ test "X`expr 00001 : '.*\(...\)'`" = X001; then
as_expr=expr
else
as_expr=false
fi
rm -f conf$$ conf$$.exe conf$$.file
+if test -d conf$$.dir; then
+ rm -f conf$$.dir/conf$$.file
+else
+ rm -f conf$$.dir
+ mkdir conf$$.dir
+fi
echo >conf$$.file
if ln -s conf$$.file conf$$ 2>/dev/null; then
- # We could just check for DJGPP; but this test a) works b) is more generic
- # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
- if test -f conf$$.exe; then
- # Don't use ln at all; we don't have any links
+ as_ln_s='ln -s'
+ # ... but there are two gotchas:
+ # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
+ # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
+ # In both cases, we have to default to `cp -p'.
+ ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
as_ln_s='cp -p'
- else
- as_ln_s='ln -s'
- fi
elif ln conf$$.file conf$$ 2>/dev/null; then
as_ln_s=ln
else
as_ln_s='cp -p'
fi
-rm -f conf$$ conf$$.exe conf$$.file
+rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
+rmdir conf$$.dir 2>/dev/null
if mkdir -p . 2>/dev/null; then
as_mkdir_p=:
@@ -8209,7 +8888,28 @@ else
as_mkdir_p=false
fi
-as_executable_p="test -f"
+if test -x / >/dev/null 2>&1; then
+ as_test_x='test -x'
+else
+ if ls -dL / >/dev/null 2>&1; then
+ as_ls_L_option=L
+ else
+ as_ls_L_option=
+ fi
+ as_test_x='
+ eval sh -c '\''
+ if test -d "$1"; then
+ test -d "$1/.";
+ else
+ case $1 in
+ -*)set "./$1";;
+ esac;
+ case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
+ ???[sx]*):;;*)false;;esac;fi
+ '\'' sh
+ '
+fi
+as_executable_p=$as_test_x
# Sed expression to map a string onto a valid CPP name.
as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
@@ -8218,31 +8918,14 @@ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-# IFS
-# We need space, tab and new line, in precisely that order.
-as_nl='
-'
-IFS=" $as_nl"
-
-# CDPATH.
-$as_unset CDPATH
-
exec 6>&1
-# Open the log real soon, to keep \$[0] and so on meaningful, and to
+# Save the log message, to keep $[0] and so on meaningful, and to
# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling. Logging --version etc. is OK.
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
-} >&5
-cat >&5 <<_CSEOF
-
+# values after options handling.
+ac_log="
This file was extended by GNU C Library $as_me (see version.h), which was
-generated by GNU Autoconf 2.59. Invocation command line was
+generated by GNU Autoconf 2.61. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
@@ -8250,30 +8933,20 @@ generated by GNU Autoconf 2.59. Invocation command line was
CONFIG_COMMANDS = $CONFIG_COMMANDS
$ $0 $@
-_CSEOF
-echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
-echo >&5
+on `(hostname || uname -n) 2>/dev/null | sed 1q`
+"
+
_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF
# Files that config.status was made for.
-if test -n "$ac_config_files"; then
- echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
-fi
-
-if test -n "$ac_config_headers"; then
- echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
-fi
-
-if test -n "$ac_config_links"; then
- echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
-fi
+config_files="$ac_config_files"
+config_headers="$ac_config_headers"
+config_commands="$ac_config_commands"
-if test -n "$ac_config_commands"; then
- echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
-fi
+_ACEOF
cat >>$CONFIG_STATUS <<\_ACEOF
-
ac_cs_usage="\
\`$as_me' instantiates files from templates according to the
current configuration.
@@ -8281,7 +8954,7 @@ current configuration.
Usage: $0 [OPTIONS] [FILE]...
-h, --help print this help, then exit
- -V, --version print version number, then exit
+ -V, --version print version number and configuration settings, then exit
-q, --quiet do not print progress messages
-d, --debug don't remove temporary files
--recheck update $as_me by reconfiguring in the same conditions
@@ -8300,19 +8973,21 @@ Configuration commands:
$config_commands
Report bugs to <bug-autoconf@gnu.org>."
-_ACEOF
+_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
GNU C Library config.status (see version.h)
-configured by $0, generated by GNU Autoconf 2.59,
- with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
+configured by $0, generated by GNU Autoconf 2.61,
+ with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-Copyright (C) 2003 Free Software Foundation, Inc.
+Copyright (C) 2006 Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."
-srcdir=$srcdir
-INSTALL="$INSTALL"
+
+ac_pwd='$ac_pwd'
+srcdir='$srcdir'
+INSTALL='$INSTALL'
_ACEOF
cat >>$CONFIG_STATUS <<\_ACEOF
@@ -8323,39 +8998,24 @@ while test $# != 0
do
case $1 in
--*=*)
- ac_option=`expr "x$1" : 'x\([^=]*\)='`
- ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
+ ac_option=`expr "X$1" : 'X\([^=]*\)='`
+ ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
ac_shift=:
;;
- -*)
+ *)
ac_option=$1
ac_optarg=$2
ac_shift=shift
;;
- *) # This is not an option, so the user has probably given explicit
- # arguments.
- ac_option=$1
- ac_need_defaults=false;;
esac
case $ac_option in
# Handling of the options.
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
ac_cs_recheck=: ;;
- --version | --vers* | -V )
- echo "$ac_cs_version"; exit 0 ;;
- --he | --h)
- # Conflict between --help and --header
- { { echo "$as_me:$LINENO: error: ambiguous option: $1
-Try \`$0 --help' for more information." >&5
-echo "$as_me: error: ambiguous option: $1
-Try \`$0 --help' for more information." >&2;}
- { (exit 1); exit 1; }; };;
- --help | --hel | -h )
- echo "$ac_cs_usage"; exit 0 ;;
- --debug | --d* | -d )
+ --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
+ echo "$ac_cs_version"; exit ;;
+ --debug | --debu | --deb | --de | --d | -d )
debug=: ;;
--file | --fil | --fi | --f )
$ac_shift
@@ -8365,18 +9025,24 @@ Try \`$0 --help' for more information." >&2;}
$ac_shift
CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
ac_need_defaults=false;;
+ --he | --h)
+ # Conflict between --help and --header
+ { echo "$as_me: error: ambiguous option: $1
+Try \`$0 --help' for more information." >&2
+ { (exit 1); exit 1; }; };;
+ --help | --hel | -h )
+ echo "$ac_cs_usage"; exit ;;
-q | -quiet | --quiet | --quie | --qui | --qu | --q \
| -silent | --silent | --silen | --sile | --sil | --si | --s)
ac_cs_silent=: ;;
# This is an error.
- -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&5
-echo "$as_me: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&2;}
+ -*) { echo "$as_me: error: unrecognized option: $1
+Try \`$0 --help' for more information." >&2
{ (exit 1); exit 1; }; } ;;
- *) ac_config_targets="$ac_config_targets $1" ;;
+ *) ac_config_targets="$ac_config_targets $1"
+ ac_need_defaults=false ;;
esac
shift
@@ -8392,39 +9058,51 @@ fi
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
if \$ac_cs_recheck; then
- echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
- exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
+ echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
+ CONFIG_SHELL=$SHELL
+ export CONFIG_SHELL
+ exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
fi
_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF
+exec 5>>config.log
+{
+ echo
+ sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
+## Running $as_me. ##
+_ASBOX
+ echo "$ac_log"
+} >&5
+_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
#
-# INIT-COMMANDS section.
+# INIT-COMMANDS
#
-
config_vars='$config_vars'
_ACEOF
-
-
cat >>$CONFIG_STATUS <<\_ACEOF
+
+# Handling of arguments.
for ac_config_target in $ac_config_targets
do
- case "$ac_config_target" in
- # Handling of arguments.
- "config.make" ) CONFIG_FILES="$CONFIG_FILES config.make" ;;
- "${config_makefile}" ) CONFIG_FILES="$CONFIG_FILES ${config_makefile}" ;;
- "${config_uname}" ) CONFIG_FILES="$CONFIG_FILES ${config_uname}" ;;
- "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
- "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
+ case $ac_config_target in
+ "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
+ "config.make") CONFIG_FILES="$CONFIG_FILES config.make" ;;
+ "${config_makefile}") CONFIG_FILES="$CONFIG_FILES ${config_makefile}" ;;
+ "${config_uname}") CONFIG_FILES="$CONFIG_FILES ${config_uname}" ;;
+ "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
+
*) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
{ (exit 1); exit 1; }; };;
esac
done
+
# If the user did not use the arguments to specify the items to instantiate,
# then the envvar interface is used. Set only those that are not.
# We use the long form for the default assignment because of an extremely
@@ -8436,398 +9114,507 @@ if $ac_need_defaults; then
fi
# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason to put it here, and in addition,
+# simply because there is no reason against having it here, and in addition,
# creating and moving files from /tmp can sometimes cause problems.
-# Create a temporary directory, and hook for its removal unless debugging.
+# Hook for its removal unless debugging.
+# Note that there is a small window in which the directory will not be cleaned:
+# after its creation but before its name has been assigned to `$tmp'.
$debug ||
{
- trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
+ tmp=
+ trap 'exit_status=$?
+ { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
+' 0
trap '{ (exit 1); exit 1; }' 1 2 13 15
}
-
# Create a (secure) tmp directory for tmp files.
{
- tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
+ tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
test -n "$tmp" && test -d "$tmp"
} ||
{
- tmp=./confstat$$-$RANDOM
- (umask 077 && mkdir $tmp)
+ tmp=./conf$$-$RANDOM
+ (umask 077 && mkdir "$tmp")
} ||
{
echo "$me: cannot create a temporary directory in ." >&2
{ (exit 1); exit 1; }
}
-_ACEOF
-
-cat >>$CONFIG_STATUS <<_ACEOF
-
#
-# CONFIG_FILES section.
+# Set up the sed scripts for CONFIG_FILES section.
#
# No need to generate the scripts if there are no CONFIG_FILES.
# This happens for instance when ./config.status config.h
-if test -n "\$CONFIG_FILES"; then
- # Protect against being on the right side of a sed subst in config.status.
- sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
- s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
-s,@SHELL@,$SHELL,;t t
-s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
-s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
-s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
-s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
-s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
-s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
-s,@exec_prefix@,$exec_prefix,;t t
-s,@prefix@,$prefix,;t t
-s,@program_transform_name@,$program_transform_name,;t t
-s,@bindir@,$bindir,;t t
-s,@sbindir@,$sbindir,;t t
-s,@libexecdir@,$libexecdir,;t t
-s,@datadir@,$datadir,;t t
-s,@sysconfdir@,$sysconfdir,;t t
-s,@sharedstatedir@,$sharedstatedir,;t t
-s,@localstatedir@,$localstatedir,;t t
-s,@libdir@,$libdir,;t t
-s,@includedir@,$includedir,;t t
-s,@oldincludedir@,$oldincludedir,;t t
-s,@infodir@,$infodir,;t t
-s,@mandir@,$mandir,;t t
-s,@build_alias@,$build_alias,;t t
-s,@host_alias@,$host_alias,;t t
-s,@target_alias@,$target_alias,;t t
-s,@DEFS@,$DEFS,;t t
-s,@ECHO_C@,$ECHO_C,;t t
-s,@ECHO_N@,$ECHO_N,;t t
-s,@ECHO_T@,$ECHO_T,;t t
-s,@LIBS@,$LIBS,;t t
-s,@with_fp@,$with_fp,;t t
-s,@with_cvs@,$with_cvs,;t t
-s,@enable_check_abi@,$enable_check_abi,;t t
-s,@oldest_abi@,$oldest_abi,;t t
-s,@bindnow@,$bindnow,;t t
-s,@force_install@,$force_install,;t t
-s,@all_warnings@,$all_warnings,;t t
-s,@libc_cv_cc_with_decimal_float@,$libc_cv_cc_with_decimal_float,;t t
-s,@build@,$build,;t t
-s,@build_cpu@,$build_cpu,;t t
-s,@build_vendor@,$build_vendor,;t t
-s,@build_os@,$build_os,;t t
-s,@host@,$host,;t t
-s,@host_cpu@,$host_cpu,;t t
-s,@host_vendor@,$host_vendor,;t t
-s,@host_os@,$host_os,;t t
-s,@subdirs@,$subdirs,;t t
-s,@add_ons@,$add_ons,;t t
-s,@add_on_subdirs@,$add_on_subdirs,;t t
-s,@base_machine@,$base_machine,;t t
-s,@submachine@,$submachine,;t t
-s,@sysnames@,$sysnames,;t t
-s,@sysdeps_add_ons@,$sysdeps_add_ons,;t t
-s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
-s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
-s,@INSTALL_DATA@,$INSTALL_DATA,;t t
-s,@LN_S@,$LN_S,;t t
-s,@CC@,$CC,;t t
-s,@CFLAGS@,$CFLAGS,;t t
-s,@LDFLAGS@,$LDFLAGS,;t t
-s,@CPPFLAGS@,$CPPFLAGS,;t t
-s,@ac_ct_CC@,$ac_ct_CC,;t t
-s,@OBJEXT@,$OBJEXT,;t t
-s,@BUILD_CC@,$BUILD_CC,;t t
-s,@cross_compiling@,$cross_compiling,;t t
-s,@CPP@,$CPP,;t t
-s,@CXX@,$CXX,;t t
-s,@CXXFLAGS@,$CXXFLAGS,;t t
-s,@ac_ct_CXX@,$ac_ct_CXX,;t t
-s,@AR@,$AR,;t t
-s,@NM@,$NM,;t t
-s,@OBJDUMP@,$OBJDUMP,;t t
-s,@RANLIB@,$RANLIB,;t t
-s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
-s,@MIG@,$MIG,;t t
-s,@AS@,$AS,;t t
-s,@LD@,$LD,;t t
-s,@PWD_P@,$PWD_P,;t t
-s,@MAKE@,$MAKE,;t t
-s,@MSGFMT@,$MSGFMT,;t t
-s,@MAKEINFO@,$MAKEINFO,;t t
-s,@SED@,$SED,;t t
-s,@AUTOCONF@,$AUTOCONF,;t t
-s,@SYSINCLUDES@,$SYSINCLUDES,;t t
-s,@CXX_SYSINCLUDES@,$CXX_SYSINCLUDES,;t t
-s,@libc_cv_gcc_static_libgcc@,$libc_cv_gcc_static_libgcc,;t t
-s,@BASH_SHELL@,$BASH_SHELL,;t t
-s,@libc_cv_have_bash2@,$libc_cv_have_bash2,;t t
-s,@KSH@,$KSH,;t t
-s,@libc_cv_have_ksh@,$libc_cv_have_ksh,;t t
-s,@AWK@,$AWK,;t t
-s,@PERL@,$PERL,;t t
-s,@INSTALL_INFO@,$INSTALL_INFO,;t t
-s,@BISON@,$BISON,;t t
-s,@VERSIONING@,$VERSIONING,;t t
-s,@libc_cv_cc_with_libunwind@,$libc_cv_cc_with_libunwind,;t t
-s,@libc_cv_Bgroup@,$libc_cv_Bgroup,;t t
-s,@libc_cv_libgcc_s_suffix@,$libc_cv_libgcc_s_suffix,;t t
-s,@libc_cv_as_needed@,$libc_cv_as_needed,;t t
-s,@ASFLAGS_config@,$ASFLAGS_config,;t t
-s,@libc_cv_z_combreloc@,$libc_cv_z_combreloc,;t t
-s,@libc_cv_z_execstack@,$libc_cv_z_execstack,;t t
-s,@libc_cv_fpie@,$libc_cv_fpie,;t t
-s,@libc_cv_hashstyle@,$libc_cv_hashstyle,;t t
-s,@fno_unit_at_a_time@,$fno_unit_at_a_time,;t t
-s,@libc_cv_ssp@,$libc_cv_ssp,;t t
-s,@libc_cv_gnu89_inline@,$libc_cv_gnu89_inline,;t t
-s,@libc_cv_have_initfini@,$libc_cv_have_initfini,;t t
-s,@no_whole_archive@,$no_whole_archive,;t t
-s,@exceptions@,$exceptions,;t t
-s,@LIBGD@,$LIBGD,;t t
-s,@have_libaudit@,$have_libaudit,;t t
-s,@have_libcap@,$have_libcap,;t t
-s,@have_selinux@,$have_selinux,;t t
-s,@EGREP@,$EGREP,;t t
-s,@sizeof_long_double@,$sizeof_long_double,;t t
-s,@libc_cv_gcc_unwind_find_fde@,$libc_cv_gcc_unwind_find_fde,;t t
-s,@uname_sysname@,$uname_sysname,;t t
-s,@uname_release@,$uname_release,;t t
-s,@uname_version@,$uname_version,;t t
-s,@old_glibc_headers@,$old_glibc_headers,;t t
-s,@libc_cv_slibdir@,$libc_cv_slibdir,;t t
-s,@libc_cv_localedir@,$libc_cv_localedir,;t t
-s,@libc_cv_sysconfdir@,$libc_cv_sysconfdir,;t t
-s,@libc_cv_rootsbindir@,$libc_cv_rootsbindir,;t t
-s,@libc_cv_forced_unwind@,$libc_cv_forced_unwind,;t t
-s,@use_ldconfig@,$use_ldconfig,;t t
-s,@ldd_rewrite_script@,$ldd_rewrite_script,;t t
-s,@elf@,$elf,;t t
-s,@xcoff@,$xcoff,;t t
-s,@static@,$static,;t t
-s,@shared@,$shared,;t t
-s,@pic_default@,$pic_default,;t t
-s,@profile@,$profile,;t t
-s,@omitfp@,$omitfp,;t t
-s,@bounded@,$bounded,;t t
-s,@static_nss@,$static_nss,;t t
-s,@nopic_initfini@,$nopic_initfini,;t t
-s,@DEFINES@,$DEFINES,;t t
-s,@mach_interface_list@,$mach_interface_list,;t t
-s,@VERSION@,$VERSION,;t t
-s,@RELEASE@,$RELEASE,;t t
-s,@LIBOBJS@,$LIBOBJS,;t t
-s,@LTLIBOBJS@,$LTLIBOBJS,;t t
-CEOF
-
-_ACEOF
-
- cat >>$CONFIG_STATUS <<\_ACEOF
- # Split the substitutions into bite-sized pieces for seds with
- # small command number limits, like on Digital OSF/1 and HP-UX.
- ac_max_sed_lines=48
- ac_sed_frag=1 # Number of current file.
- ac_beg=1 # First line for current file.
- ac_end=$ac_max_sed_lines # Line after last line for current file.
- ac_more_lines=:
- ac_sed_cmds=
- while $ac_more_lines; do
- if test $ac_beg -gt 1; then
- sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
- else
- sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
- fi
- if test ! -s $tmp/subs.frag; then
- ac_more_lines=false
- else
- # The purpose of the label and of the branching condition is to
- # speed up the sed processing (if there are no `@' at all, there
- # is no need to browse any of the substitutions).
- # These are the two extra sed commands mentioned above.
- (echo ':t
- /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
- if test -z "$ac_sed_cmds"; then
- ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
- else
- ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
- fi
- ac_sed_frag=`expr $ac_sed_frag + 1`
- ac_beg=$ac_end
- ac_end=`expr $ac_end + $ac_max_sed_lines`
- fi
- done
- if test -z "$ac_sed_cmds"; then
- ac_sed_cmds=cat
+if test -n "$CONFIG_FILES"; then
+
+_ACEOF
+
+
+
+ac_delim='%!_!# '
+for ac_last_try in false false false false false :; do
+ cat >conf$$subs.sed <<_ACEOF
+SHELL!$SHELL$ac_delim
+PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
+PACKAGE_NAME!$PACKAGE_NAME$ac_delim
+PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
+PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
+PACKAGE_STRING!$PACKAGE_STRING$ac_delim
+PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
+exec_prefix!$exec_prefix$ac_delim
+prefix!$prefix$ac_delim
+program_transform_name!$program_transform_name$ac_delim
+bindir!$bindir$ac_delim
+sbindir!$sbindir$ac_delim
+libexecdir!$libexecdir$ac_delim
+datarootdir!$datarootdir$ac_delim
+datadir!$datadir$ac_delim
+sysconfdir!$sysconfdir$ac_delim
+sharedstatedir!$sharedstatedir$ac_delim
+localstatedir!$localstatedir$ac_delim
+includedir!$includedir$ac_delim
+oldincludedir!$oldincludedir$ac_delim
+docdir!$docdir$ac_delim
+infodir!$infodir$ac_delim
+htmldir!$htmldir$ac_delim
+dvidir!$dvidir$ac_delim
+pdfdir!$pdfdir$ac_delim
+psdir!$psdir$ac_delim
+libdir!$libdir$ac_delim
+localedir!$localedir$ac_delim
+mandir!$mandir$ac_delim
+DEFS!$DEFS$ac_delim
+ECHO_C!$ECHO_C$ac_delim
+ECHO_N!$ECHO_N$ac_delim
+ECHO_T!$ECHO_T$ac_delim
+LIBS!$LIBS$ac_delim
+build_alias!$build_alias$ac_delim
+host_alias!$host_alias$ac_delim
+target_alias!$target_alias$ac_delim
+with_fp!$with_fp$ac_delim
+with_cvs!$with_cvs$ac_delim
+enable_check_abi!$enable_check_abi$ac_delim
+oldest_abi!$oldest_abi$ac_delim
+bindnow!$bindnow$ac_delim
+force_install!$force_install$ac_delim
+all_warnings!$all_warnings$ac_delim
+libc_cv_cc_with_decimal_float!$libc_cv_cc_with_decimal_float$ac_delim
+build!$build$ac_delim
+build_cpu!$build_cpu$ac_delim
+build_vendor!$build_vendor$ac_delim
+build_os!$build_os$ac_delim
+host!$host$ac_delim
+host_cpu!$host_cpu$ac_delim
+host_vendor!$host_vendor$ac_delim
+host_os!$host_os$ac_delim
+subdirs!$subdirs$ac_delim
+add_ons!$add_ons$ac_delim
+add_on_subdirs!$add_on_subdirs$ac_delim
+base_machine!$base_machine$ac_delim
+submachine!$submachine$ac_delim
+sysnames!$sysnames$ac_delim
+sysdeps_add_ons!$sysdeps_add_ons$ac_delim
+INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
+INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
+INSTALL_DATA!$INSTALL_DATA$ac_delim
+LN_S!$LN_S$ac_delim
+CC!$CC$ac_delim
+CFLAGS!$CFLAGS$ac_delim
+LDFLAGS!$LDFLAGS$ac_delim
+CPPFLAGS!$CPPFLAGS$ac_delim
+ac_ct_CC!$ac_ct_CC$ac_delim
+OBJEXT!$OBJEXT$ac_delim
+BUILD_CC!$BUILD_CC$ac_delim
+cross_compiling!$cross_compiling$ac_delim
+CPP!$CPP$ac_delim
+CXX!$CXX$ac_delim
+CXXFLAGS!$CXXFLAGS$ac_delim
+ac_ct_CXX!$ac_ct_CXX$ac_delim
+AR!$AR$ac_delim
+NM!$NM$ac_delim
+OBJDUMP!$OBJDUMP$ac_delim
+RANLIB!$RANLIB$ac_delim
+MIG!$MIG$ac_delim
+AS!$AS$ac_delim
+LD!$LD$ac_delim
+PWD_P!$PWD_P$ac_delim
+MAKE!$MAKE$ac_delim
+MSGFMT!$MSGFMT$ac_delim
+MAKEINFO!$MAKEINFO$ac_delim
+SED!$SED$ac_delim
+AUTOCONF!$AUTOCONF$ac_delim
+SYSINCLUDES!$SYSINCLUDES$ac_delim
+CXX_SYSINCLUDES!$CXX_SYSINCLUDES$ac_delim
+libc_cv_gcc_static_libgcc!$libc_cv_gcc_static_libgcc$ac_delim
+BASH_SHELL!$BASH_SHELL$ac_delim
+libc_cv_have_bash2!$libc_cv_have_bash2$ac_delim
+KSH!$KSH$ac_delim
+libc_cv_have_ksh!$libc_cv_have_ksh$ac_delim
+AWK!$AWK$ac_delim
+_ACEOF
+
+ if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
+ break
+ elif $ac_last_try; then
+ { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
+echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
+ { (exit 1); exit 1; }; }
+ else
+ ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
fi
-fi # test -n "$CONFIG_FILES"
+done
+ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
+if test -n "$ac_eof"; then
+ ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
+ ac_eof=`expr $ac_eof + 1`
+fi
+
+cat >>$CONFIG_STATUS <<_ACEOF
+cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
+/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
_ACEOF
+sed '
+s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
+s/^/s,@/; s/!/@,|#_!!_#|/
+:n
+t n
+s/'"$ac_delim"'$/,g/; t
+s/$/\\/; p
+N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
+' >>$CONFIG_STATUS <conf$$subs.sed
+rm -f conf$$subs.sed
+cat >>$CONFIG_STATUS <<_ACEOF
+CEOF$ac_eof
+_ACEOF
+
+
+ac_delim='%!_!# '
+for ac_last_try in false false false false false :; do
+ cat >conf$$subs.sed <<_ACEOF
+PERL!$PERL$ac_delim
+INSTALL_INFO!$INSTALL_INFO$ac_delim
+BISON!$BISON$ac_delim
+VERSIONING!$VERSIONING$ac_delim
+libc_cv_cc_with_libunwind!$libc_cv_cc_with_libunwind$ac_delim
+libc_cv_Bgroup!$libc_cv_Bgroup$ac_delim
+libc_cv_libgcc_s_suffix!$libc_cv_libgcc_s_suffix$ac_delim
+libc_cv_as_needed!$libc_cv_as_needed$ac_delim
+ASFLAGS_config!$ASFLAGS_config$ac_delim
+libc_cv_z_combreloc!$libc_cv_z_combreloc$ac_delim
+libc_cv_z_execstack!$libc_cv_z_execstack$ac_delim
+libc_cv_fpie!$libc_cv_fpie$ac_delim
+libc_cv_hashstyle!$libc_cv_hashstyle$ac_delim
+fno_unit_at_a_time!$fno_unit_at_a_time$ac_delim
+libc_cv_ssp!$libc_cv_ssp$ac_delim
+libc_cv_gnu89_inline!$libc_cv_gnu89_inline$ac_delim
+libc_cv_have_initfini!$libc_cv_have_initfini$ac_delim
+no_whole_archive!$no_whole_archive$ac_delim
+exceptions!$exceptions$ac_delim
+libc_cv_cc_submachine!$libc_cv_cc_submachine$ac_delim
+LIBGD!$LIBGD$ac_delim
+have_libaudit!$have_libaudit$ac_delim
+have_libcap!$have_libcap$ac_delim
+have_selinux!$have_selinux$ac_delim
+GREP!$GREP$ac_delim
+EGREP!$EGREP$ac_delim
+sizeof_long_double!$sizeof_long_double$ac_delim
+libc_cv_gcc_unwind_find_fde!$libc_cv_gcc_unwind_find_fde$ac_delim
+uname_sysname!$uname_sysname$ac_delim
+uname_release!$uname_release$ac_delim
+uname_version!$uname_version$ac_delim
+old_glibc_headers!$old_glibc_headers$ac_delim
+libc_cv_slibdir!$libc_cv_slibdir$ac_delim
+libc_cv_localedir!$libc_cv_localedir$ac_delim
+libc_cv_sysconfdir!$libc_cv_sysconfdir$ac_delim
+libc_cv_rootsbindir!$libc_cv_rootsbindir$ac_delim
+libc_cv_forced_unwind!$libc_cv_forced_unwind$ac_delim
+use_ldconfig!$use_ldconfig$ac_delim
+ldd_rewrite_script!$ldd_rewrite_script$ac_delim
+elf!$elf$ac_delim
+xcoff!$xcoff$ac_delim
+static!$static$ac_delim
+shared!$shared$ac_delim
+pic_default!$pic_default$ac_delim
+profile!$profile$ac_delim
+omitfp!$omitfp$ac_delim
+bounded!$bounded$ac_delim
+static_nss!$static_nss$ac_delim
+nopic_initfini!$nopic_initfini$ac_delim
+DEFINES!$DEFINES$ac_delim
+mach_interface_list!$mach_interface_list$ac_delim
+VERSION!$VERSION$ac_delim
+RELEASE!$RELEASE$ac_delim
+LIBOBJS!$LIBOBJS$ac_delim
+LTLIBOBJS!$LTLIBOBJS$ac_delim
+_ACEOF
+
+ if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 55; then
+ break
+ elif $ac_last_try; then
+ { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
+echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
+ { (exit 1); exit 1; }; }
+ else
+ ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
+ fi
+done
+
+ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
+if test -n "$ac_eof"; then
+ ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
+ ac_eof=`expr $ac_eof + 1`
+fi
+
+cat >>$CONFIG_STATUS <<_ACEOF
+cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
+/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
+_ACEOF
+sed '
+s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
+s/^/s,@/; s/!/@,|#_!!_#|/
+:n
+t n
+s/'"$ac_delim"'$/,g/; t
+s/$/\\/; p
+N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
+' >>$CONFIG_STATUS <conf$$subs.sed
+rm -f conf$$subs.sed
+cat >>$CONFIG_STATUS <<_ACEOF
+:end
+s/|#_!!_#|//g
+CEOF$ac_eof
+_ACEOF
+
+
+# VPATH may cause trouble with some makes, so we remove $(srcdir),
+# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
+# trailing colons and then remove the whole line if VPATH becomes empty
+# (actually we leave an empty line to preserve line numbers).
+if test "x$srcdir" = x.; then
+ ac_vpsub='/^[ ]*VPATH[ ]*=/{
+s/:*\$(srcdir):*/:/
+s/:*\${srcdir}:*/:/
+s/:*@srcdir@:*/:/
+s/^\([^=]*=[ ]*\):*/\1/
+s/:*$//
+s/^[^=]*=[ ]*$//
+}'
+fi
+
cat >>$CONFIG_STATUS <<\_ACEOF
-for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
- # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case $ac_file in
- - | *:- | *:-:* ) # input from stdin
- cat >$tmp/stdin
- ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
- ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
- *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
- ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
- * ) ac_file_in=$ac_file.in ;;
+fi # test -n "$CONFIG_FILES"
+
+
+for ac_tag in :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS
+do
+ case $ac_tag in
+ :[FHLC]) ac_mode=$ac_tag; continue;;
+ esac
+ case $ac_mode$ac_tag in
+ :[FHL]*:*);;
+ :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
+echo "$as_me: error: Invalid tag $ac_tag." >&2;}
+ { (exit 1); exit 1; }; };;
+ :[FH]-) ac_tag=-:-;;
+ :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
esac
+ ac_save_IFS=$IFS
+ IFS=:
+ set x $ac_tag
+ IFS=$ac_save_IFS
+ shift
+ ac_file=$1
+ shift
- # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
- ac_dir=`(dirname "$ac_file") 2>/dev/null ||
+ case $ac_mode in
+ :L) ac_source=$1;;
+ :[FH])
+ ac_file_inputs=
+ for ac_f
+ do
+ case $ac_f in
+ -) ac_f="$tmp/stdin";;
+ *) # Look for the file first in the build tree, then in the source tree
+ # (if the path is not absolute). The absolute path cannot be DOS-style,
+ # because $ac_f cannot contain `:'.
+ test -f "$ac_f" ||
+ case $ac_f in
+ [\\/$]*) false;;
+ *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
+ esac ||
+ { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
+echo "$as_me: error: cannot find input file: $ac_f" >&2;}
+ { (exit 1); exit 1; }; };;
+ esac
+ ac_file_inputs="$ac_file_inputs $ac_f"
+ done
+
+ # Let's still pretend it is `configure' which instantiates (i.e., don't
+ # use $as_me), people would be surprised to read:
+ # /* config.h. Generated by config.status. */
+ configure_input="Generated from "`IFS=:
+ echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
+ if test x"$ac_file" != x-; then
+ configure_input="$ac_file. $configure_input"
+ { echo "$as_me:$LINENO: creating $ac_file" >&5
+echo "$as_me: creating $ac_file" >&6;}
+ fi
+
+ case $ac_tag in
+ *:-:* | *:-) cat >"$tmp/stdin";;
+ esac
+ ;;
+ esac
+
+ ac_dir=`$as_dirname -- "$ac_file" ||
$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$ac_file" : 'X\(//\)[^/]' \| \
X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
+ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
- { if $as_mkdir_p; then
- mkdir -p "$ac_dir"
- else
- as_dir="$ac_dir"
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+ s//\1/
+ q
+ }
+ /^X\(\/\/\)[^/].*/{
+ s//\1/
+ q
+ }
+ /^X\(\/\/\)$/{
+ s//\1/
+ q
+ }
+ /^X\(\/\).*/{
+ s//\1/
+ q
+ }
+ s/.*/./; q'`
+ { as_dir="$ac_dir"
+ case $as_dir in #(
+ -*) as_dir=./$as_dir;;
+ esac
+ test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
as_dirs=
- while test ! -d "$as_dir"; do
- as_dirs="$as_dir $as_dirs"
- as_dir=`(dirname "$as_dir") 2>/dev/null ||
+ while :; do
+ case $as_dir in #(
+ *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
+ *) as_qdir=$as_dir;;
+ esac
+ as_dirs="'$as_qdir' $as_dirs"
+ as_dir=`$as_dirname -- "$as_dir" ||
$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$as_dir" : 'X\(//\)[^/]' \| \
X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
+ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+ s//\1/
+ q
+ }
+ /^X\(\/\/\)[^/].*/{
+ s//\1/
+ q
+ }
+ /^X\(\/\/\)$/{
+ s//\1/
+ q
+ }
+ /^X\(\/\).*/{
+ s//\1/
+ q
+ }
+ s/.*/./; q'`
+ test -d "$as_dir" && break
done
- test ! -n "$as_dirs" || mkdir $as_dirs
- fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
+ test -z "$as_dirs" || eval "mkdir $as_dirs"
+ } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
+echo "$as_me: error: cannot create directory $as_dir" >&2;}
{ (exit 1); exit 1; }; }; }
-
ac_builddir=.
-if test "$ac_dir" != .; then
+case "$ac_dir" in
+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
+*)
ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
- # A "../" for each directory in $ac_dir_suffix.
- ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
- ac_dir_suffix= ac_top_builddir=
-fi
+ # A ".." for each directory in $ac_dir_suffix.
+ ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
+ case $ac_top_builddir_sub in
+ "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
+ *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
+ esac ;;
+esac
+ac_abs_top_builddir=$ac_pwd
+ac_abs_builddir=$ac_pwd$ac_dir_suffix
+# for backward compatibility:
+ac_top_builddir=$ac_top_build_prefix
case $srcdir in
- .) # No --srcdir option. We are building in place.
+ .) # We are building in place.
ac_srcdir=.
- if test -z "$ac_top_builddir"; then
- ac_top_srcdir=.
- else
- ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
- fi ;;
- [\\/]* | ?:[\\/]* ) # Absolute path.
+ ac_top_srcdir=$ac_top_builddir_sub
+ ac_abs_top_srcdir=$ac_pwd ;;
+ [\\/]* | ?:[\\/]* ) # Absolute name.
ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir ;;
- *) # Relative path.
- ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_builddir$srcdir ;;
+ ac_top_srcdir=$srcdir
+ ac_abs_top_srcdir=$srcdir ;;
+ *) # Relative name.
+ ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
+ ac_top_srcdir=$ac_top_build_prefix$srcdir
+ ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
esac
+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
- case "$ac_dir" in
- .) ac_abs_builddir=`pwd`;;
- [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
- *) ac_abs_builddir=`pwd`/"$ac_dir";;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
- case ${ac_top_builddir}. in
- .) ac_abs_top_builddir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
- *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
- case $ac_srcdir in
- .) ac_abs_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
- *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
- case $ac_top_srcdir in
- .) ac_abs_top_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
- *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
- esac;;
-esac
+ case $ac_mode in
+ :F)
+ #
+ # CONFIG_FILE
+ #
case $INSTALL in
[\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
- *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
+ *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
esac
+_ACEOF
- if test x"$ac_file" != x-; then
- { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
- rm -f "$ac_file"
- fi
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- if test x"$ac_file" = x-; then
- configure_input=
- else
- configure_input="$ac_file. "
- fi
- configure_input=$configure_input"Generated from `echo $ac_file_in |
- sed 's,.*/,,'` by configure."
-
- # First look for the input files in the build tree, otherwise in the
- # src tree.
- ac_file_inputs=`IFS=:
- for f in $ac_file_in; do
- case $f in
- -) echo $tmp/stdin ;;
- [\\/$]*)
- # Absolute (can't be DOS-style, as IFS=:)
- test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
- { (exit 1); exit 1; }; }
- echo "$f";;
- *) # Relative
- if test -f "$f"; then
- # Build tree
- echo "$f"
- elif test -f "$srcdir/$f"; then
- # Source tree
- echo "$srcdir/$f"
- else
- # /dev/null tree
- { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
- { (exit 1); exit 1; }; }
- fi;;
- esac
- done` || { (exit 1); exit 1; }
+cat >>$CONFIG_STATUS <<\_ACEOF
+# If the template does not know about datarootdir, expand it.
+# FIXME: This hack should be removed a few years after 2.60.
+ac_datarootdir_hack=; ac_datarootdir_seen=
+
+case `sed -n '/datarootdir/ {
+ p
+ q
+}
+/@datadir@/p
+/@docdir@/p
+/@infodir@/p
+/@localedir@/p
+/@mandir@/p
+' $ac_file_inputs` in
+*datarootdir*) ac_datarootdir_seen=yes;;
+*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
+ { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
+echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
+_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF
+ ac_datarootdir_hack='
+ s&@datadir@&$datadir&g
+ s&@docdir@&$docdir&g
+ s&@infodir@&$infodir&g
+ s&@localedir@&$localedir&g
+ s&@mandir@&$mandir&g
+ s&\\\${datarootdir}&$datarootdir&g' ;;
+esac
_ACEOF
+
+# Neutralize VPATH when `$srcdir' = `.'.
+# Shell code in configure.ac might set extrasub.
+# FIXME: do we really want to maintain this feature?
cat >>$CONFIG_STATUS <<_ACEOF
sed "$ac_vpsub
$extrasub
@@ -8835,374 +9622,148 @@ _ACEOF
cat >>$CONFIG_STATUS <<\_ACEOF
:t
/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s,@configure_input@,$configure_input,;t t
-s,@srcdir@,$ac_srcdir,;t t
-s,@abs_srcdir@,$ac_abs_srcdir,;t t
-s,@top_srcdir@,$ac_top_srcdir,;t t
-s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
-s,@builddir@,$ac_builddir,;t t
-s,@abs_builddir@,$ac_abs_builddir,;t t
-s,@top_builddir@,$ac_top_builddir,;t t
-s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
-s,@INSTALL@,$ac_INSTALL,;t t
-" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
- rm -f $tmp/stdin
- if test x"$ac_file" != x-; then
- mv $tmp/out $ac_file
- else
- cat $tmp/out
- rm -f $tmp/out
- fi
-
-done
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-
-#
-# CONFIG_HEADER section.
-#
-
-# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
-# NAME is the cpp macro being defined and VALUE is the value it is being given.
-#
-# ac_d sets the value in "#define NAME VALUE" lines.
-ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
-ac_dB='[ ].*$,\1#\2'
-ac_dC=' '
-ac_dD=',;t'
-# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
-ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
-ac_uB='$,\1#\2define\3'
-ac_uC=' '
-ac_uD=',;t'
-
-for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
- # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
+s&@configure_input@&$configure_input&;t t
+s&@top_builddir@&$ac_top_builddir_sub&;t t
+s&@srcdir@&$ac_srcdir&;t t
+s&@abs_srcdir@&$ac_abs_srcdir&;t t
+s&@top_srcdir@&$ac_top_srcdir&;t t
+s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
+s&@builddir@&$ac_builddir&;t t
+s&@abs_builddir@&$ac_abs_builddir&;t t
+s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
+s&@INSTALL@&$ac_INSTALL&;t t
+$ac_datarootdir_hack
+" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
+
+test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
+ { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
+ { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
+ { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+which seems to be undefined. Please make sure it is defined." >&5
+echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+which seems to be undefined. Please make sure it is defined." >&2;}
+
+ rm -f "$tmp/stdin"
case $ac_file in
- - | *:- | *:-:* ) # input from stdin
- cat >$tmp/stdin
- ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
- ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
- *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
- ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
- * ) ac_file_in=$ac_file.in ;;
+ -) cat "$tmp/out"; rm -f "$tmp/out";;
+ *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
esac
-
- test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
-
- # First look for the input files in the build tree, otherwise in the
- # src tree.
- ac_file_inputs=`IFS=:
- for f in $ac_file_in; do
- case $f in
- -) echo $tmp/stdin ;;
- [\\/$]*)
- # Absolute (can't be DOS-style, as IFS=:)
- test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
- { (exit 1); exit 1; }; }
- # Do quote $f, to prevent DOS paths from being IFS'd.
- echo "$f";;
- *) # Relative
- if test -f "$f"; then
- # Build tree
- echo "$f"
- elif test -f "$srcdir/$f"; then
- # Source tree
- echo "$srcdir/$f"
- else
- # /dev/null tree
- { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
- { (exit 1); exit 1; }; }
- fi;;
- esac
- done` || { (exit 1); exit 1; }
- # Remove the trailing spaces.
- sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
-
-_ACEOF
-
-# Transform confdefs.h into two sed scripts, `conftest.defines' and
-# `conftest.undefs', that substitutes the proper values into
-# config.h.in to produce config.h. The first handles `#define'
-# templates, and the second `#undef' templates.
-# And first: Protect against being on the right side of a sed subst in
-# config.status. Protect against being in an unquoted here document
-# in config.status.
-rm -f conftest.defines conftest.undefs
-# Using a here document instead of a string reduces the quoting nightmare.
-# Putting comments in sed scripts is not portable.
-#
-# `end' is used to avoid that the second main sed command (meant for
-# 0-ary CPP macros) applies to n-ary macro definitions.
-# See the Autoconf documentation for `clear'.
-cat >confdef2sed.sed <<\_ACEOF
-s/[\\&,]/\\&/g
-s,[\\$`],\\&,g
-t clear
-: clear
-s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
-t end
-s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
-: end
-_ACEOF
-# If some macros were called several times there might be several times
-# the same #defines, which is useless. Nevertheless, we may not want to
-# sort them, since we want the *last* AC-DEFINE to be honored.
-uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
-sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
-rm -f confdef2sed.sed
-
-# This sed command replaces #undef with comments. This is necessary, for
+ ;;
+ :H)
+ #
+ # CONFIG_HEADER
+ #
+_ACEOF
+
+# Transform confdefs.h into a sed script `conftest.defines', that
+# substitutes the proper values into config.h.in to produce config.h.
+rm -f conftest.defines conftest.tail
+# First, append a space to every undef/define line, to ease matching.
+echo 's/$/ /' >conftest.defines
+# Then, protect against being on the right side of a sed subst, or in
+# an unquoted here document, in config.status. If some macros were
+# called several times there might be several #defines for the same
+# symbol, which is useless. But do not sort them, since the last
+# AC_DEFINE must be honored.
+ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
+# These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where
+# NAME is the cpp macro being defined, VALUE is the value it is being given.
+# PARAMS is the parameter list in the macro definition--in most cases, it's
+# just an empty string.
+ac_dA='s,^\\([ #]*\\)[^ ]*\\([ ]*'
+ac_dB='\\)[ (].*,\\1define\\2'
+ac_dC=' '
+ac_dD=' ,'
+
+uniq confdefs.h |
+ sed -n '
+ t rset
+ :rset
+ s/^[ ]*#[ ]*define[ ][ ]*//
+ t ok
+ d
+ :ok
+ s/[\\&,]/\\&/g
+ s/^\('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p
+ s/^\('"$ac_word_re"'\)[ ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p
+ ' >>conftest.defines
+
+# Remove the space that was appended to ease matching.
+# Then replace #undef with comments. This is necessary, for
# example, in the case of _POSIX_SOURCE, which is predefined and required
# on some systems where configure will not decide to define it.
-cat >>conftest.undefs <<\_ACEOF
-s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
-_ACEOF
-
-# Break up conftest.defines because some shells have a limit on the size
-# of here documents, and old seds have small limits too (100 cmds).
-echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
-echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
-echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
-echo ' :' >>$CONFIG_STATUS
-rm -f conftest.tail
-while grep . conftest.defines >/dev/null
+# (The regexp can be short, since the line contains either #define or #undef.)
+echo 's/ $//
+s,^[ #]*u.*,/* & */,' >>conftest.defines
+
+# Break up conftest.defines:
+ac_max_sed_lines=50
+
+# First sed command is: sed -f defines.sed $ac_file_inputs >"$tmp/out1"
+# Second one is: sed -f defines.sed "$tmp/out1" >"$tmp/out2"
+# Third one will be: sed -f defines.sed "$tmp/out2" >"$tmp/out1"
+# et cetera.
+ac_in='$ac_file_inputs'
+ac_out='"$tmp/out1"'
+ac_nxt='"$tmp/out2"'
+
+while :
do
- # Write a limited-size here document to $tmp/defines.sed.
- echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
- # Speed up: don't consider the non `#define' lines.
- echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
- # Work around the forget-to-reset-the-flag bug.
- echo 't clr' >>$CONFIG_STATUS
- echo ': clr' >>$CONFIG_STATUS
- sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
+ # Write a here document:
+ cat >>$CONFIG_STATUS <<_ACEOF
+ # First, check the format of the line:
+ cat >"\$tmp/defines.sed" <<\\CEOF
+/^[ ]*#[ ]*undef[ ][ ]*$ac_word_re[ ]*\$/b def
+/^[ ]*#[ ]*define[ ][ ]*$ac_word_re[( ]/b def
+b
+:def
+_ACEOF
+ sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS
echo 'CEOF
- sed -f $tmp/defines.sed $tmp/in >$tmp/out
- rm -f $tmp/in
- mv $tmp/out $tmp/in
-' >>$CONFIG_STATUS
- sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
+ sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS
+ ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in
+ sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail
+ grep . conftest.tail >/dev/null || break
rm -f conftest.defines
mv conftest.tail conftest.defines
done
-rm -f conftest.defines
-echo ' fi # grep' >>$CONFIG_STATUS
-echo >>$CONFIG_STATUS
-
-# Break up conftest.undefs because some shells have a limit on the size
-# of here documents, and old seds have small limits too (100 cmds).
-echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
-rm -f conftest.tail
-while grep . conftest.undefs >/dev/null
-do
- # Write a limited-size here document to $tmp/undefs.sed.
- echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
- # Speed up: don't consider the non `#undef'
- echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
- # Work around the forget-to-reset-the-flag bug.
- echo 't clr' >>$CONFIG_STATUS
- echo ': clr' >>$CONFIG_STATUS
- sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
- echo 'CEOF
- sed -f $tmp/undefs.sed $tmp/in >$tmp/out
- rm -f $tmp/in
- mv $tmp/out $tmp/in
-' >>$CONFIG_STATUS
- sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
- rm -f conftest.undefs
- mv conftest.tail conftest.undefs
-done
-rm -f conftest.undefs
+rm -f conftest.defines conftest.tail
+echo "ac_result=$ac_in" >>$CONFIG_STATUS
cat >>$CONFIG_STATUS <<\_ACEOF
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- if test x"$ac_file" = x-; then
- echo "/* Generated by configure. */" >$tmp/config.h
- else
- echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
- fi
- cat $tmp/in >>$tmp/config.h
- rm -f $tmp/in
if test x"$ac_file" != x-; then
- if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
+ echo "/* $configure_input */" >"$tmp/config.h"
+ cat "$ac_result" >>"$tmp/config.h"
+ if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then
{ echo "$as_me:$LINENO: $ac_file is unchanged" >&5
echo "$as_me: $ac_file is unchanged" >&6;}
else
- ac_dir=`(dirname "$ac_file") 2>/dev/null ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
-echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
- { if $as_mkdir_p; then
- mkdir -p "$ac_dir"
- else
- as_dir="$ac_dir"
- as_dirs=
- while test ! -d "$as_dir"; do
- as_dirs="$as_dir $as_dirs"
- as_dir=`(dirname "$as_dir") 2>/dev/null ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
-echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
- done
- test ! -n "$as_dirs" || mkdir $as_dirs
- fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
- { (exit 1); exit 1; }; }; }
-
rm -f $ac_file
- mv $tmp/config.h $ac_file
+ mv "$tmp/config.h" $ac_file
fi
else
- cat $tmp/config.h
- rm -f $tmp/config.h
+ echo "/* $configure_input */"
+ cat "$ac_result"
fi
-done
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+ rm -f "$tmp/out12"
+ ;;
-#
-# CONFIG_COMMANDS section.
-#
-for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
- ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
- ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
- ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
-$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_dest" : 'X\(//\)[^/]' \| \
- X"$ac_dest" : 'X\(//\)$' \| \
- X"$ac_dest" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
-echo X"$ac_dest" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
- { if $as_mkdir_p; then
- mkdir -p "$ac_dir"
- else
- as_dir="$ac_dir"
- as_dirs=
- while test ! -d "$as_dir"; do
- as_dirs="$as_dir $as_dirs"
- as_dir=`(dirname "$as_dir") 2>/dev/null ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
-echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
- done
- test ! -n "$as_dirs" || mkdir $as_dirs
- fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
- { (exit 1); exit 1; }; }; }
-
- ac_builddir=.
-
-if test "$ac_dir" != .; then
- ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
- # A "../" for each directory in $ac_dir_suffix.
- ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
- ac_dir_suffix= ac_top_builddir=
-fi
-
-case $srcdir in
- .) # No --srcdir option. We are building in place.
- ac_srcdir=.
- if test -z "$ac_top_builddir"; then
- ac_top_srcdir=.
- else
- ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
- fi ;;
- [\\/]* | ?:[\\/]* ) # Absolute path.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir ;;
- *) # Relative path.
- ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_builddir$srcdir ;;
-esac
-
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
- case "$ac_dir" in
- .) ac_abs_builddir=`pwd`;;
- [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
- *) ac_abs_builddir=`pwd`/"$ac_dir";;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
- case ${ac_top_builddir}. in
- .) ac_abs_top_builddir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
- *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
- case $ac_srcdir in
- .) ac_abs_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
- *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
- case $ac_top_srcdir in
- .) ac_abs_top_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
- *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
- esac;;
-esac
+ :C) { echo "$as_me:$LINENO: executing $ac_file commands" >&5
+echo "$as_me: executing $ac_file commands" >&6;}
+ ;;
+ esac
- { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
-echo "$as_me: executing $ac_dest commands" >&6;}
- case $ac_dest in
- default )
+ case $ac_file$ac_mode in
+ "default":C)
case $CONFIG_FILES in *config.make*)
echo "$config_vars" >> config.make;;
esac
test -d bits || mkdir bits ;;
+
esac
-done
-_ACEOF
+done # for ac_tag
-cat >>$CONFIG_STATUS <<\_ACEOF
{ (exit 0); exit 0; }
_ACEOF
@@ -9239,7 +9800,10 @@ if test "$no_recursion" != yes; then
# Remove --cache-file and --srcdir arguments so they do not pile up.
ac_sub_configure_args=
ac_prev=
- for ac_arg in $ac_configure_args; do
+ eval "set x $ac_configure_args"
+ shift
+ for ac_arg
+ do
if test -n "$ac_prev"; then
ac_prev=
continue
@@ -9262,123 +9826,123 @@ if test "$no_recursion" != yes; then
ac_prev=prefix ;;
-prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
;;
- *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;;
+ *)
+ case $ac_arg in
+ *\'*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ esac
+ ac_sub_configure_args="$ac_sub_configure_args '$ac_arg'" ;;
esac
done
# Always prepend --prefix to ensure using the same prefix
# in subdir configurations.
- ac_sub_configure_args="--prefix=$prefix $ac_sub_configure_args"
+ ac_arg="--prefix=$prefix"
+ case $ac_arg in
+ *\'*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ esac
+ ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
+
+ # Pass --silent
+ if test "$silent" = yes; then
+ ac_sub_configure_args="--silent $ac_sub_configure_args"
+ fi
ac_popdir=`pwd`
for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
# Do not complain, so a configure script can configure whichever
# parts of a large source tree are present.
- test -d $srcdir/$ac_dir || continue
-
- { echo "$as_me:$LINENO: configuring in $ac_dir" >&5
-echo "$as_me: configuring in $ac_dir" >&6;}
- { if $as_mkdir_p; then
- mkdir -p "$ac_dir"
- else
- as_dir="$ac_dir"
+ test -d "$srcdir/$ac_dir" || continue
+
+ ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
+ echo "$as_me:$LINENO: $ac_msg" >&5
+ echo "$ac_msg" >&6
+ { as_dir="$ac_dir"
+ case $as_dir in #(
+ -*) as_dir=./$as_dir;;
+ esac
+ test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
as_dirs=
- while test ! -d "$as_dir"; do
- as_dirs="$as_dir $as_dirs"
- as_dir=`(dirname "$as_dir") 2>/dev/null ||
+ while :; do
+ case $as_dir in #(
+ *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
+ *) as_qdir=$as_dir;;
+ esac
+ as_dirs="'$as_qdir' $as_dirs"
+ as_dir=`$as_dirname -- "$as_dir" ||
$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$as_dir" : 'X\(//\)[^/]' \| \
X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
+ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+ s//\1/
+ q
+ }
+ /^X\(\/\/\)[^/].*/{
+ s//\1/
+ q
+ }
+ /^X\(\/\/\)$/{
+ s//\1/
+ q
+ }
+ /^X\(\/\).*/{
+ s//\1/
+ q
+ }
+ s/.*/./; q'`
+ test -d "$as_dir" && break
done
- test ! -n "$as_dirs" || mkdir $as_dirs
- fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
+ test -z "$as_dirs" || eval "mkdir $as_dirs"
+ } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
+echo "$as_me: error: cannot create directory $as_dir" >&2;}
{ (exit 1); exit 1; }; }; }
-
ac_builddir=.
-if test "$ac_dir" != .; then
+case "$ac_dir" in
+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
+*)
ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
- # A "../" for each directory in $ac_dir_suffix.
- ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
- ac_dir_suffix= ac_top_builddir=
-fi
+ # A ".." for each directory in $ac_dir_suffix.
+ ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
+ case $ac_top_builddir_sub in
+ "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
+ *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
+ esac ;;
+esac
+ac_abs_top_builddir=$ac_pwd
+ac_abs_builddir=$ac_pwd$ac_dir_suffix
+# for backward compatibility:
+ac_top_builddir=$ac_top_build_prefix
case $srcdir in
- .) # No --srcdir option. We are building in place.
+ .) # We are building in place.
ac_srcdir=.
- if test -z "$ac_top_builddir"; then
- ac_top_srcdir=.
- else
- ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
- fi ;;
- [\\/]* | ?:[\\/]* ) # Absolute path.
+ ac_top_srcdir=$ac_top_builddir_sub
+ ac_abs_top_srcdir=$ac_pwd ;;
+ [\\/]* | ?:[\\/]* ) # Absolute name.
ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir ;;
- *) # Relative path.
- ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_builddir$srcdir ;;
-esac
-
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
- case "$ac_dir" in
- .) ac_abs_builddir=`pwd`;;
- [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
- *) ac_abs_builddir=`pwd`/"$ac_dir";;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
- case ${ac_top_builddir}. in
- .) ac_abs_top_builddir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
- *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
- case $ac_srcdir in
- .) ac_abs_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
- *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
- case $ac_top_srcdir in
- .) ac_abs_top_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
- *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
- esac;;
+ ac_top_srcdir=$srcdir
+ ac_abs_top_srcdir=$srcdir ;;
+ *) # Relative name.
+ ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
+ ac_top_srcdir=$ac_top_build_prefix$srcdir
+ ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
esac
+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
- cd $ac_dir
+ cd "$ac_dir"
# Check for guested configure; otherwise get Cygnus style configure.
- if test -f $ac_srcdir/configure.gnu; then
- ac_sub_configure="$SHELL '$ac_srcdir/configure.gnu'"
- elif test -f $ac_srcdir/configure; then
- ac_sub_configure="$SHELL '$ac_srcdir/configure'"
- elif test -f $ac_srcdir/configure.in; then
- ac_sub_configure=$ac_configure
+ if test -f "$ac_srcdir/configure.gnu"; then
+ ac_sub_configure=$ac_srcdir/configure.gnu
+ elif test -f "$ac_srcdir/configure"; then
+ ac_sub_configure=$ac_srcdir/configure
+ elif test -f "$ac_srcdir/configure.in"; then
+ # This should be Cygnus configure.
+ ac_sub_configure=$ac_aux_dir/configure
else
{ echo "$as_me:$LINENO: WARNING: no configuration information is in $ac_dir" >&5
echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
@@ -9390,21 +9954,21 @@ echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
# Make the cache file name correct relative to the subdirectory.
case $cache_file in
[\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
- *) # Relative path.
- ac_sub_cache_file=$ac_top_builddir$cache_file ;;
+ *) # Relative name.
+ ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
esac
- { echo "$as_me:$LINENO: running $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
-echo "$as_me: running $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
+ { echo "$as_me:$LINENO: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
+echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
# The eval makes quoting arguments work.
- eval $ac_sub_configure $ac_sub_configure_args \
- --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir ||
+ eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
+ --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
{ { echo "$as_me:$LINENO: error: $ac_sub_configure failed for $ac_dir" >&5
echo "$as_me: error: $ac_sub_configure failed for $ac_dir" >&2;}
{ (exit 1); exit 1; }; }
fi
- cd $ac_popdir
+ cd "$ac_popdir"
done
fi
diff --git a/libc/configure.in b/libc/configure.in
index 832c6b2f7..8b9691496 100644
--- a/libc/configure.in
+++ b/libc/configure.in
@@ -355,7 +355,6 @@ AC_ARG_WITH([cpu],
esac
])
-
# An add-on can set this when it wants to disable the sanity check below.
libc_config_ok=no
@@ -1552,7 +1551,7 @@ EOF
if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS
-S -o conftest.s conftest.c 1>&AS_MESSAGE_LOG_FD]) \
&& grep -q .note.GNU-stack conftest.s \
- && AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS -Wa,--noexecstack
+ && AC_TRY_COMMAND([${CC-cc} $ASFLAGS -Wa,--noexecstack
-c -o conftest.o conftest.s 1>&AS_MESSAGE_LOG_FD])
then
libc_cv_as_noexecstack=yes
@@ -1637,11 +1636,11 @@ EOF
AC_SUBST(libc_cv_hashstyle)
fi
-AC_CACHE_CHECK(for -fno-toplevel-reorder, libc_cv_fno_toplevel_reorder, [dnl
+AC_CACHE_CHECK(for -fno-toplevel-reorder -fno-section-anchors, libc_cv_fno_toplevel_reorder, [dnl
cat > conftest.c <<EOF
int foo;
EOF
-if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS -S -fno-toplevel-reorder
+if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS -S -fno-toplevel-reorder -fno-section-anchors
conftest.c 1>&AS_MESSAGE_LOG_FD])
then
libc_cv_fno_toplevel_reorder=yes
@@ -1650,7 +1649,7 @@ else
fi
rm -f conftest*])
if test $libc_cv_fno_toplevel_reorder = yes; then
- fno_unit_at_a_time=-fno-toplevel-reorder
+ fno_unit_at_a_time="-fno-toplevel-reorder -fno-section-anchors"
else
fno_unit_at_a_time=-fno-unit-at-a-time
fi
@@ -1661,7 +1660,7 @@ cat > conftest.c <<EOF
int foo;
main () { return 0;}
EOF
-if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS -fstack-protector
+if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS -Werror -fstack-protector
-o conftest conftest.c 1>&AS_MESSAGE_LOG_FD])
then
libc_cv_ssp=yes
@@ -1996,6 +1995,22 @@ EOF
fi
fi
+if test -n "$submachine"; then
+ AC_CACHE_CHECK([for compiler option for CPU variant],
+ libc_cv_cc_submachine, [dnl
+ libc_cv_cc_submachine=no
+ for opt in "-march=$submachine" "-mcpu=$submachine"; do
+ if AC_TRY_COMMAND([${CC-cc} $opt -xc /dev/null -S -o /dev/null]); then
+ libc_cv_cc_submachine="$opt"
+ break
+ fi
+ done])
+ if test "x$libc_cv_cc_submachine" = xno; then
+ AC_MSG_ERROR([${CC-cc} does not support $submachine])
+ fi
+fi
+AC_SUBST(libc_cv_cc_submachine)
+
dnl Check whether we have the gd library available.
AC_MSG_CHECKING(for libgd)
if test "$with_gd" != "no"; then
diff --git a/libc/debug/wctomb_chk.c b/libc/debug/wctomb_chk.c
index d0366346b..23fc2ffbd 100644
--- a/libc/debug/wctomb_chk.c
+++ b/libc/debug/wctomb_chk.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2005 Free Software Foundation, Inc.
+/* Copyright (C) 2005, 2008 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
@@ -21,7 +21,7 @@
#include <wcsmbs/wcsmbsload.h>
-extern mbstate_t __no_r_state attribute_hidden; /* Defined in mbtowc.c. */
+extern mbstate_t __wctomb_state attribute_hidden; /* Defined in wctomb.c. */
int
@@ -32,5 +32,5 @@ __wctomb_chk (char *s, wchar_t wchar, size_t buflen)
if (buflen < MB_CUR_MAX)
__chk_fail ();
- return __wcrtomb (s, wchar, &__no_r_state);
+ return __wcrtomb (s, wchar, &__wctomb_state);
}
diff --git a/libc/dfp/Makefile b/libc/dfp/Makefile
index cdde76c87..f1d7ddd64 100644
--- a/libc/dfp/Makefile
+++ b/libc/dfp/Makefile
@@ -10,6 +10,7 @@ extra-libs-others := $(extra-libs)
# install-lib-ldscripts := libdfp.so
# The libdecnumber code is in the libdecnumber/ directory.
+ifeq ($(ARCH)
vpath %.c libdecnumber:libdecnumber/dpd
vpath %.h libdecnumber:libdecnumber/dpd
diff --git a/libc/dfp/test/README b/libc/dfp/test/README
index 3c2db0ece..46d569132 100644
--- a/libc/dfp/test/README
+++ b/libc/dfp/test/README
@@ -3,6 +3,9 @@
if test -z "$1"; then
cc="/opt/at05/bin/gcc"
export PATH=/opt/at05/bin:$PATH
+
+ SYSROOT=$HOME/tc
+ cc="$HOME/gcc/bin/gcc -I$SYSROOT/include -L$SYSROOT/lib -Wl,-rpath=$SYSROOT/lib -Wl,-dynamic-linker=$SYSROOT/lib/ld.so.1"
else
cc=$1/gcc
export PATH=$1:$PATH
@@ -14,9 +17,9 @@ for i in $( ls *.c);
if [ "$i" == "test-decimal.c" ]; then
continue;
fi
- echo "${cc} -ldfp -ldecnumber -std=gnu99 $i -o `basename $i .c`"
- ${cc} -ldfp -ldecnumber -std=gnu99 $i -o `basename $i .c`;
+ echo "${cc} -ldfp -std=gnu99 $i -o `basename $i .c`"
+ ${cc} -ldfp -std=gnu99 $i -o `basename $i .c`;
- echo "${cc} -m64 -ldfp -ldecnumber -std=gnu99 $i -o `basename $i .c`_64"
- ${cc} -ldfp -m64 -ldecnumber -std=gnu99 $i -o `basename $i .c`_64;
+ echo "${cc} -m64 -ldfp -std=gnu99 $i -o `basename $i .c`_64"
+ ${cc} -ldfp -m64 -std=gnu99 $i -o `basename $i .c`_64;
done
diff --git a/libc/elf/Makefile b/libc/elf/Makefile
index 774640f9a..16c752f26 100644
--- a/libc/elf/Makefile
+++ b/libc/elf/Makefile
@@ -160,7 +160,7 @@ tests += $(tests-static)
endif
ifeq (yes,$(build-shared))
tests += loadtest restest1 preloadtest loadfail multiload origtest resolvfail \
- constload1 order $(tests-vis-$(have-protected)) noload filter unload \
+ constload1 order vismain noload filter unload \
reldep reldep2 reldep3 reldep4 nodelete nodelete2 \
nodlopen nodlopen2 neededtest neededtest2 \
neededtest3 neededtest4 unload2 lateglobal initfirst global \
@@ -176,7 +176,6 @@ tests += loadtest restest1 preloadtest loadfail multiload origtest resolvfail \
tst-stackguard1 tst-addr1 tst-thrlock
# reldep9
test-srcs = tst-pathopt
-tests-vis-yes = vismain
tests-execstack-yes = tst-execstack tst-execstack-needed tst-execstack-prog
endif
ifeq (yesyes,$(have-fpie)$(build-shared))
@@ -185,7 +184,7 @@ endif
tests: $(objpfx)tst-leaks1-mem
modules-names = testobj1 testobj2 testobj3 testobj4 testobj5 testobj6 \
testobj1_1 failobj constload2 constload3 unloadmod \
- dep1 dep2 dep3 dep4 $(modules-vis-$(have-protected)) \
+ dep1 dep2 dep3 dep4 vismod1 vismod2 vismod3 \
nodelmod1 nodelmod2 nodelmod3 nodelmod4 \
nodel2mod1 nodel2mod2 nodel2mod3 \
nodlopenmod nodlopenmod2 filtmod1 filtmod2 \
@@ -221,7 +220,6 @@ endif
ifeq (yesyes,$(have-fpie)$(build-shared))
modules-names += tst-piemod1
endif
-modules-vis-yes = vismod1 vismod2 vismod3
modules-execstack-yes = tst-execstack-mod
extra-test-objs += $(addsuffix .os,$(strip $(modules-names)))
# We need this variable to be sure the test modules get the right CPPFLAGS.
@@ -807,7 +805,7 @@ $(objpfx)tst-array5-static.out: $(objpfx)tst-array5-static
cmp $@ tst-array5-static.exp > /dev/null
ifeq (yesyes,$(have-fpie)$(build-shared))
-CFLAGS-tst-pie1.c += -fpie
+CFLAGS-tst-pie1.c += $(pie-ccflag)
$(objpfx)tst-pie1.out: $(objpfx)tst-pie1
$(cross-test-wrapper) \
@@ -849,10 +847,14 @@ $(objpfx)tst-dlmodcount: $(libdl)
$(objpfx)tst-dlmodcount.out: $(test-modules)
check-data := $(firstword $(wildcard \
- $(patsubst %,../scripts/data/localplt-%.data,\
- $(addsuffix -$(config-os),\
- $(config-machine) $(base-machine))\
- generic)))
+ $(foreach D,$(add-ons) scripts,\
+ $(patsubst %,$(..)$D/data/localplt-%.data,\
+ $(abi-name) \
+ $(addsuffix -$(config-os),\
+ $(config-machine) \
+ $(base-machine)) \
+ generic))))
+
tests: $(objpfx)check-localplt.out
ifeq ($(have-thread-library),yes)
@@ -861,9 +863,11 @@ endif
$(objpfx)check-localplt.out: $(objpfx)check-localplt \
$(common-objpfx)libc.so \
- $(common-objpfx)math/libm.so $(thread-dso) \
- $(common-objpfx)rt/librt.so \
- $(common-objpfx)dlfcn/libdl.so \
+ $(common-objpfx)math/libm.so $(thread-dso) \
+ $(common-objpfx)rt/librt.so \
+ $(common-objpfx)dlfcn/libdl.so \
+ $(common-objpfx)resolv/libresolv.so \
+ $(common-objpfx)crypt/libcrypt.so \
$(check-data)
$(dir $<)$(notdir $<) $(filter-out $< $(check-data),$^) | \
LC_ALL=C sort | \
diff --git a/libc/elf/dl-conflict.c b/libc/elf/dl-conflict.c
index 9b49e77d2..b73010562 100644
--- a/libc/elf/dl-conflict.c
+++ b/libc/elf/dl-conflict.c
@@ -1,5 +1,5 @@
/* Resolve conflicts against already prelinked libraries.
- Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+ Copyright (C) 2001, 2002, 2003, 2004, 2005, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Jakub Jelinek <jakub@redhat.com>, 2001.
@@ -44,7 +44,6 @@ _dl_resolve_conflicts (struct link_map *l, ElfW(Rela) *conflict,
/* This macro is used as a callback from the ELF_DYNAMIC_RELOCATE code. */
#define RESOLVE_MAP(ref, version, flags) (*ref = NULL, NULL)
#define RESOLVE(ref, version, flags) (*ref = NULL, 0)
-#define CHECK_STATIC_TLS(ref_map, sym_map) ((void) 0)
#define RESOLVE_CONFLICT_FIND_MAP(map, r_offset) \
do { \
while ((resolve_conflict_map->l_map_end < (ElfW(Addr)) (r_offset)) \
@@ -61,6 +60,12 @@ _dl_resolve_conflicts (struct link_map *l, ElfW(Rela) *conflict,
#include "dynamic-link.h"
+ /* Override these, defined in dynamic-link.h. */
+#undef CHECK_STATIC_TLS
+#define CHECK_STATIC_TLS(ref_map, sym_map) ((void) 0)
+#undef TRY_STATIC_TLS
+#define TRY_STATIC_TLS(ref_map, sym_map) (0)
+
GL(dl_num_cache_relocations) += conflictend - conflict;
for (; conflict < conflictend; ++conflict)
diff --git a/libc/elf/dl-load.c b/libc/elf/dl-load.c
index 94531b271..8a8936f7b 100644
--- a/libc/elf/dl-load.c
+++ b/libc/elf/dl-load.c
@@ -163,7 +163,7 @@ static const size_t system_dirs_len[] =
/* Local version of `strdup' function. */
-static inline char *
+static char *
local_strdup (const char *s)
{
size_t len = strlen (s) + 1;
@@ -1470,15 +1470,6 @@ cannot enable executable stack as shared object requires");
{
/* Create an appropriate searchlist. It contains only this map.
This is the definition of DT_SYMBOLIC in SysVr4. */
- l->l_symbolic_searchlist.r_list =
- (struct link_map **) malloc (sizeof (struct link_map *));
-
- if (l->l_symbolic_searchlist.r_list == NULL)
- {
- errstring = N_("cannot create searchlist");
- goto call_lose_errno;
- }
-
l->l_symbolic_searchlist.r_list[0] = l;
l->l_symbolic_searchlist.r_nlist = 1;
diff --git a/libc/elf/dl-object.c b/libc/elf/dl-object.c
index 0e45aea39..be4ea38f9 100644
--- a/libc/elf/dl-object.c
+++ b/libc/elf/dl-object.c
@@ -1,5 +1,5 @@
/* Storage management for the chain of loaded shared objects.
- Copyright (C) 1995-2002, 2004, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1995-2002,2004,2006,2007,2008 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
@@ -50,13 +50,17 @@ _dl_new_object (char *realname, const char *libname, int type,
#endif
new = (struct link_map *) calloc (sizeof (*new) + audit_space
+ + sizeof (struct link_map *)
+ sizeof (*newname) + libname_len, 1);
if (new == NULL)
return NULL;
new->l_real = new;
- new->l_libname = newname = (struct libname_list *) ((char *) (new + 1)
- + audit_space);
+ new->l_symbolic_searchlist.r_list = (struct link_map **) ((char *) (new + 1)
+ + audit_space);
+
+ new->l_libname = newname
+ = (struct libname_list *) (new->l_symbolic_searchlist.r_list + 1);
newname->name = (char *) memcpy (newname + 1, libname, libname_len);
/* newname->next = NULL; We use calloc therefore not necessary. */
newname->dont_free = 1;
diff --git a/libc/elf/dl-reloc.c b/libc/elf/dl-reloc.c
index 496bf6ec4..877360f5c 100644
--- a/libc/elf/dl-reloc.c
+++ b/libc/elf/dl-reloc.c
@@ -1,5 +1,5 @@
/* Relocate a shared object and resolve its references to other loaded objects.
- Copyright (C) 1995-2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1995-2004, 2005, 2006, 2008 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
@@ -43,9 +43,9 @@
This function intentionally does not return any value but signals error
directly, as static TLS should be rare and code handling it should
not be inlined as much as possible. */
-void
-internal_function __attribute_noinline__
-_dl_allocate_static_tls (struct link_map *map)
+int
+internal_function
+_dl_try_allocate_static_tls (struct link_map *map)
{
/* If we've already used the variable with dynamic access, or if the
alignment requirements are too high, fail. */
@@ -53,8 +53,7 @@ _dl_allocate_static_tls (struct link_map *map)
|| map->l_tls_align > GL(dl_tls_static_align))
{
fail:
- _dl_signal_error (0, map->l_name, NULL, N_("\
-cannot allocate memory in static TLS block"));
+ return -1;
}
#if TLS_TCB_AT_TP
@@ -108,6 +107,20 @@ cannot allocate memory in static TLS block"));
}
else
map->l_need_tls_init = 1;
+
+ return 0;
+}
+
+void
+internal_function __attribute_noinline__
+_dl_allocate_static_tls (struct link_map *map)
+{
+ if (map->l_tls_offset == FORCED_DYNAMIC_TLS_OFFSET
+ || _dl_try_allocate_static_tls (map))
+ {
+ _dl_signal_error (0, map->l_name, NULL, N_("\
+cannot allocate memory in static TLS block"));
+ }
}
/* Initialize static TLS area and DTV for current (only) thread.
@@ -248,23 +261,6 @@ _dl_relocate_object (struct link_map *l, struct r_scope_elem *scope[],
l->l_lookup_cache.value = _lr; })) \
: l)
- /* This macro is used as a callback from elf_machine_rel{a,} when a
- static TLS reloc is about to be performed. Since (in dl-load.c) we
- permit dynamic loading of objects that might use such relocs, we
- have to check whether each use is actually doable. If the object
- whose TLS segment the reference resolves to was allocated space in
- the static TLS block at startup, then it's ok. Otherwise, we make
- an attempt to allocate it in surplus space on the fly. If that
- can't be done, we fall back to the error that DF_STATIC_TLS is
- intended to produce. */
-#define CHECK_STATIC_TLS(map, sym_map) \
- do { \
- if (__builtin_expect ((sym_map)->l_tls_offset == NO_TLS_OFFSET \
- || ((sym_map)->l_tls_offset \
- == FORCED_DYNAMIC_TLS_OFFSET), 0)) \
- _dl_allocate_static_tls (sym_map); \
- } while (0)
-
#include "dynamic-link.h"
ELF_DYNAMIC_RELOCATE (l, lazy, consider_profiling);
diff --git a/libc/elf/dl-support.c b/libc/elf/dl-support.c
index 2c11ac688..6bd573ec5 100644
--- a/libc/elf/dl-support.c
+++ b/libc/elf/dl-support.c
@@ -1,5 +1,5 @@
/* Support for dynamic linking code in static libc.
- Copyright (C) 1996-2005, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1996-2005, 2006, 2007, 2008 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
diff --git a/libc/elf/dl-sysdep.c b/libc/elf/dl-sysdep.c
index dd55905e1..e6f4272a6 100644
--- a/libc/elf/dl-sysdep.c
+++ b/libc/elf/dl-sysdep.c
@@ -270,6 +270,7 @@ _dl_show_auxv (void)
} auxvars[] =
{
[AT_EXECFD - 2] = { "AT_EXECFD: ", dec },
+ [AT_EXECFN - 2] = { "AT_EXECFN: ", str },
[AT_PHDR - 2] = { "AT_PHDR: 0x", hex },
[AT_PHENT - 2] = { "AT_PHENT: ", dec },
[AT_PHNUM - 2] = { "AT_PHNUM: ", dec },
diff --git a/libc/elf/dl-tls.c b/libc/elf/dl-tls.c
index 76a3f25c0..54c3590a9 100644
--- a/libc/elf/dl-tls.c
+++ b/libc/elf/dl-tls.c
@@ -691,6 +691,61 @@ _dl_update_slotinfo (unsigned long int req_modid)
}
+static void *
+__attribute_noinline__
+tls_get_addr_tail (dtv_t *dtv, struct link_map *the_map, size_t module)
+{
+ /* The allocation was deferred. Do it now. */
+ if (the_map == NULL)
+ {
+ /* Find the link map for this module. */
+ size_t idx = module;
+ struct dtv_slotinfo_list *listp = GL(dl_tls_dtv_slotinfo_list);
+
+ while (idx >= listp->len)
+ {
+ idx -= listp->len;
+ listp = listp->next;
+ }
+
+ the_map = listp->slotinfo[idx].map;
+ }
+
+ again:
+ /* Make sure that, if a dlopen running in parallel forces the
+ variable into static storage, we'll wait until the address in the
+ static TLS block is set up, and use that. If we're undecided
+ yet, make sure we make the decision holding the lock as well. */
+ if (__builtin_expect (the_map->l_tls_offset
+ != FORCED_DYNAMIC_TLS_OFFSET, 0))
+ {
+ __rtld_lock_lock_recursive (GL(dl_load_lock));
+ if (__builtin_expect (the_map->l_tls_offset == NO_TLS_OFFSET, 1))
+ {
+ the_map->l_tls_offset = FORCED_DYNAMIC_TLS_OFFSET;
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+ }
+ else
+ {
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+ if (__builtin_expect (the_map->l_tls_offset
+ != FORCED_DYNAMIC_TLS_OFFSET, 1))
+ {
+ void *p = dtv[module].pointer.val;
+ if (__builtin_expect (p == TLS_DTV_UNALLOCATED, 0))
+ goto again;
+
+ return p;
+ }
+ }
+ }
+ void *p = dtv[module].pointer.val = allocate_and_init (the_map);
+ dtv[module].pointer.is_static = false;
+
+ return p;
+}
+
+
/* The generic dynamic and local dynamic model cannot be used in
statically linked applications. */
void *
@@ -703,52 +758,10 @@ __tls_get_addr (GET_ADDR_ARGS)
if (__builtin_expect (dtv[0].counter != GL(dl_tls_generation), 0))
the_map = _dl_update_slotinfo (GET_ADDR_MODULE);
- retry:
p = dtv[GET_ADDR_MODULE].pointer.val;
if (__builtin_expect (p == TLS_DTV_UNALLOCATED, 0))
- {
- /* The allocation was deferred. Do it now. */
- if (the_map == NULL)
- {
- /* Find the link map for this module. */
- size_t idx = GET_ADDR_MODULE;
- struct dtv_slotinfo_list *listp = GL(dl_tls_dtv_slotinfo_list);
-
- while (idx >= listp->len)
- {
- idx -= listp->len;
- listp = listp->next;
- }
-
- the_map = listp->slotinfo[idx].map;
- }
-
- /* Make sure that, if a dlopen running in parallel forces the
- variable into static storage, we'll wait until the address in
- the static TLS block is set up, and use that. If we're
- undecided yet, make sure we make the decision holding the
- lock as well. */
- if (__builtin_expect (the_map->l_tls_offset
- != FORCED_DYNAMIC_TLS_OFFSET, 0))
- {
- __rtld_lock_lock_recursive (GL(dl_load_lock));
- if (__builtin_expect (the_map->l_tls_offset == NO_TLS_OFFSET, 1))
- {
- the_map->l_tls_offset = FORCED_DYNAMIC_TLS_OFFSET;
- __rtld_lock_unlock_recursive (GL(dl_load_lock));
- }
- else
- {
- __rtld_lock_unlock_recursive (GL(dl_load_lock));
- if (__builtin_expect (the_map->l_tls_offset
- != FORCED_DYNAMIC_TLS_OFFSET, 1))
- goto retry;
- }
- }
- p = dtv[GET_ADDR_MODULE].pointer.val = allocate_and_init (the_map);
- dtv[GET_ADDR_MODULE].pointer.is_static = false;
- }
+ p = tls_get_addr_tail (dtv, the_map, GET_ADDR_MODULE);
return (char *) p + GET_ADDR_OFFSET;
}
diff --git a/libc/elf/dynamic-link.h b/libc/elf/dynamic-link.h
index 7eb9a3613..c34cbcd43 100644
--- a/libc/elf/dynamic-link.h
+++ b/libc/elf/dynamic-link.h
@@ -1,5 +1,5 @@
/* Inline functions for dynamic linking.
- Copyright (C) 1995-2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1995-2005, 2006, 2008 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,31 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+/* This macro is used as a callback from elf_machine_rel{a,} when a
+ static TLS reloc is about to be performed. Since (in dl-load.c) we
+ permit dynamic loading of objects that might use such relocs, we
+ have to check whether each use is actually doable. If the object
+ whose TLS segment the reference resolves to was allocated space in
+ the static TLS block at startup, then it's ok. Otherwise, we make
+ an attempt to allocate it in surplus space on the fly. If that
+ can't be done, we fall back to the error that DF_STATIC_TLS is
+ intended to produce. */
+#define CHECK_STATIC_TLS(map, sym_map) \
+ do { \
+ if (__builtin_expect ((sym_map)->l_tls_offset == NO_TLS_OFFSET \
+ || ((sym_map)->l_tls_offset \
+ == FORCED_DYNAMIC_TLS_OFFSET), 0)) \
+ _dl_allocate_static_tls (sym_map); \
+ } while (0)
+
+#define TRY_STATIC_TLS(map, sym_map) \
+ (__builtin_expect ((sym_map)->l_tls_offset \
+ != FORCED_DYNAMIC_TLS_OFFSET, 1) \
+ && (__builtin_expect ((sym_map)->l_tls_offset != NO_TLS_OFFSET, 1) \
+ || _dl_try_allocate_static_tls (sym_map) == 0))
+
+int internal_function _dl_try_allocate_static_tls (struct link_map *map);
+
#include <elf.h>
#include <assert.h>
diff --git a/libc/elf/elf.h b/libc/elf/elf.h
index 928e9ec97..a4134462a 100644
--- a/libc/elf/elf.h
+++ b/libc/elf/elf.h
@@ -970,6 +970,8 @@ typedef struct
#define AT_SECURE 23 /* Boolean, was exec setuid-like? */
+#define AT_EXECFN 31 /* Filename of executable. */
+
/* Pointer to the global system page used for system calls and other
nice things. */
#define AT_SYSINFO 32
@@ -1159,8 +1161,17 @@ typedef struct
#define R_386_TLS_DTPMOD32 35 /* ID of module containing symbol */
#define R_386_TLS_DTPOFF32 36 /* Offset in TLS block */
#define R_386_TLS_TPOFF32 37 /* Negated offset in static TLS block */
+/* 38? */
+#define R_386_TLS_GOTDESC 39 /* GOT offset for TLS descriptor. */
+#define R_386_TLS_DESC_CALL 40 /* Marker of call through TLS
+ descriptor for
+ relaxation. */
+#define R_386_TLS_DESC 41 /* TLS descriptor containing
+ pointer to code and to
+ argument, returning the TLS
+ offset for the symbol. */
/* Keep this the last entry. */
-#define R_386_NUM 38
+#define R_386_NUM 42
/* SUN SPARC specific definitions. */
@@ -2557,8 +2568,17 @@ typedef Elf32_Addr Elf32_Conflict;
#define R_X86_64_GOTTPOFF 22 /* 32 bit signed PC relative offset
to GOT entry for IE symbol */
#define R_X86_64_TPOFF32 23 /* Offset in initial TLS block */
+#define R_X86_64_PC64 24 /* PC relative 64 bit */
+#define R_X86_64_GOTOFF64 25 /* 64 bit offset to GOT */
+#define R_X86_64_GOTPC32 26 /* 32 bit signed pc relative
+ offset to GOT */
+/* 27 .. 33 */
+#define R_X86_64_GOTPC32_TLSDESC 34 /* GOT offset for TLS descriptor. */
+#define R_X86_64_TLSDESC_CALL 35 /* Marker for call through TLS
+ descriptor. */
+#define R_X86_64_TLSDESC 36 /* TLS descriptor. */
-#define R_X86_64_NUM 24
+#define R_X86_64_NUM 37
/* AM33 relocations. */
diff --git a/libc/elf/soinit.c b/libc/elf/soinit.c
index c0a881ef5..6fecbb567 100644
--- a/libc/elf/soinit.c
+++ b/libc/elf/soinit.c
@@ -20,10 +20,6 @@ run_hooks (void (*const list[]) (void))
(**list) ();
}
-static const char __EH_FRAME_BEGIN__[]
- __attribute__ ((used, section (".eh_frame")))
- = { };
-
/* This function will be called from _init in init-first.c. */
void
__libc_global_ctors (void)
diff --git a/libc/elf/tls-macros.h b/libc/elf/tls-macros.h
index 37cbe7514..6463a6c3f 100644
--- a/libc/elf/tls-macros.h
+++ b/libc/elf/tls-macros.h
@@ -813,12 +813,17 @@ register void *__gp __asm__("$29");
: "=b" (__result) ); \
__result; \
})
+# ifdef HAVE_ASM_GLOBAL_DOT_NAME
+# define __TLS_GET_ADDR ".__tls_get_addr"
+# else
+# define __TLS_GET_ADDR "__tls_get_addr"
+# endif
/* PowerPC64 Local Dynamic TLS access. */
# define TLS_LD(x) \
({ int * __result; \
asm ( \
" addi 3,2," #x "@got@tlsld\n" \
- " bl .__tls_get_addr\n" \
+ " bl " __TLS_GET_ADDR "\n" \
" nop \n" \
" addis %0,3," #x "@dtprel@ha\n" \
" addi %0,%0," #x "@dtprel@l\n" \
@@ -834,7 +839,7 @@ register void *__gp __asm__("$29");
({ int * __result; \
asm ( \
" addi 3,2," #x "@got@tlsgd\n" \
- " bl .__tls_get_addr\n" \
+ " bl " __TLS_GET_ADDR "\n" \
" nop \n" \
" mr %0,3\n" \
: "=b" (__result) : \
diff --git a/libc/elf/tlsdeschtab.h b/libc/elf/tlsdeschtab.h
new file mode 100644
index 000000000..c3cbc3fb7
--- /dev/null
+++ b/libc/elf/tlsdeschtab.h
@@ -0,0 +1,157 @@
+/* Hash table for TLS descriptors.
+ Copyright (C) 2005, 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Alexandre Oliva <aoliva@redhat.com>
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef TLSDESCHTAB_H
+# define TLSDESCHTAB_H 1
+
+# ifdef SHARED
+
+# include <inline-hashtab.h>
+
+inline static int
+hash_tlsdesc (void *p)
+{
+ struct tlsdesc_dynamic_arg *td = p;
+
+ /* We know all entries are for the same module, so ti_offset is the
+ only distinguishing entry. */
+ return td->tlsinfo.ti_offset;
+}
+
+inline static int
+eq_tlsdesc (void *p, void *q)
+{
+ struct tlsdesc_dynamic_arg *tdp = p, *tdq = q;
+
+ return tdp->tlsinfo.ti_offset == tdq->tlsinfo.ti_offset;
+}
+
+inline static int
+map_generation (struct link_map *map)
+{
+ size_t idx = map->l_tls_modid;
+ struct dtv_slotinfo_list *listp = GL(dl_tls_dtv_slotinfo_list);
+
+ /* Find the place in the dtv slotinfo list. */
+ do
+ {
+ /* Does it fit in the array of this list element? */
+ if (idx < listp->len)
+ {
+ /* We should never get here for a module in static TLS, so
+ we can assume that, if the generation count is zero, we
+ still haven't determined the generation count for this
+ module. */
+ if (listp->slotinfo[idx].gen)
+ return listp->slotinfo[idx].gen;
+ else
+ break;
+ }
+ idx -= listp->len;
+ listp = listp->next;
+ }
+ while (listp != NULL);
+
+ /* If we get to this point, the module still hasn't been assigned an
+ entry in the dtv slotinfo data structures, and it will when we're
+ done with relocations. At that point, the module will get a
+ generation number that is one past the current generation, so
+ return exactly that. */
+ return GL(dl_tls_generation) + 1;
+}
+
+void *
+internal_function
+_dl_make_tlsdesc_dynamic (struct link_map *map, size_t ti_offset)
+{
+ struct hashtab *ht;
+ void **entry;
+ struct tlsdesc_dynamic_arg *td, test;
+
+ /* FIXME: We could use a per-map lock here, but is it worth it? */
+ __rtld_lock_lock_recursive (GL(dl_load_lock));
+
+ ht = map->l_mach.tlsdesc_table;
+ if (! ht)
+ {
+ ht = htab_create ();
+ if (! ht)
+ {
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+ return 0;
+ }
+ map->l_mach.tlsdesc_table = ht;
+ }
+
+ test.tlsinfo.ti_module = map->l_tls_modid;
+ test.tlsinfo.ti_offset = ti_offset;
+ entry = htab_find_slot (ht, &test, 1, hash_tlsdesc, eq_tlsdesc);
+ if (*entry)
+ {
+ td = *entry;
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+ return td;
+ }
+
+ *entry = td = malloc (sizeof (struct tlsdesc_dynamic_arg));
+ /* This may be higher than the map's generation, but it doesn't
+ matter much. Worst case, we'll have one extra DTV update per
+ thread. */
+ td->gen_count = map_generation (map);
+ td->tlsinfo = test.tlsinfo;
+
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+ return td;
+}
+
+# endif /* SHARED */
+
+/* The idea of the following two functions is to stop multiple threads
+ from attempting to resolve the same TLS descriptor without busy
+ waiting. Ideally, we should be able to release the lock right
+ after changing td->entry, and then using say a condition variable
+ or a futex wake to wake up any waiting threads, but let's try to
+ avoid introducing such dependencies. */
+
+inline static int
+_dl_tlsdesc_resolve_early_return_p (struct tlsdesc volatile *td, void *caller)
+{
+ if (caller != td->entry)
+ return 1;
+
+ __rtld_lock_lock_recursive (GL(dl_load_lock));
+ if (caller != td->entry)
+ {
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+ return 1;
+ }
+
+ td->entry = _dl_tlsdesc_resolve_hold;
+
+ return 0;
+}
+
+inline static void
+_dl_tlsdesc_wake_up_held_fixups (void)
+{
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+}
+
+#endif
diff --git a/libc/hurd/fd-read.c b/libc/hurd/fd-read.c
index 55dbc24e9..38706524f 100644
--- a/libc/hurd/fd-read.c
+++ b/libc/hurd/fd-read.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993,94,95,97,99,2002 Free Software Foundation, Inc.
+/* Copyright (C) 1993,94,95,97,99,2002,2008 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
@@ -35,11 +35,17 @@ _hurd_fd_read (struct hurd_fd *fd, void *buf, size_t *nbytes, loff_t offset)
}
data = buf;
+ nread = *nbytes;
if (err = HURD_FD_PORT_USE (fd, _hurd_ctty_input (port, ctty, readfd)))
return err;
if (data != buf)
{
+ if (nread > *nbytes) /* Sanity check for bogus server. */
+ {
+ __vm_deallocate (__mach_task_self (), (vm_address_t) data, nread);
+ return EGRATUITOUS;
+ }
memcpy (buf, data, nread);
__vm_deallocate (__mach_task_self (), (vm_address_t) data, nread);
}
diff --git a/libc/hurd/get-host.c b/libc/hurd/get-host.c
index bebad892c..3fe0b3ef7 100644
--- a/libc/hurd/get-host.c
+++ b/libc/hurd/get-host.c
@@ -51,6 +51,7 @@ _hurd_get_host_config (const char *item, char *buf, size_t buflen)
}
data = buf;
+ nread = buflen;
err = __io_read (config, &data, &nread, -1, buflen);
if (! err)
/* Check if there is more in the file we didn't read. */
diff --git a/libc/hurd/hurd/fd.h b/libc/hurd/hurd/fd.h
index 08d4407e8..d1aa867cb 100644
--- a/libc/hurd/hurd/fd.h
+++ b/libc/hurd/hurd/fd.h
@@ -27,6 +27,7 @@
#include <hurd/hurd_types.h>
#include <hurd/port.h>
+#include <sys/socket.h>
/* Structure representing a file descriptor. */
@@ -179,6 +180,18 @@ __hurd_dfail (int fd, error_t err)
errno = _hurd_fd_error (fd, err);
return -1;
}
+
+/* Likewise, but do not raise SIGPIPE on EPIPE if flags contain
+ MSG_NOSIGNAL. */
+
+_HURD_FD_H_EXTERN_INLINE int
+__hurd_sockfail (int fd, int flags, error_t err)
+{
+ if (!(flags & MSG_NOSIGNAL) || err != EPIPE)
+ err = _hurd_fd_error (fd, err);
+ errno = err;
+ return -1;
+}
/* Set up *FD to have PORT its server port, doing appropriate ctty magic.
Does no locking or unlocking. */
diff --git a/libc/hurd/hurd/signal.h b/libc/hurd/hurd/signal.h
index 39fa0f857..d4bcaf26a 100644
--- a/libc/hurd/hurd/signal.h
+++ b/libc/hurd/hurd/signal.h
@@ -1,5 +1,6 @@
/* Implementing POSIX.1 signals under the Hurd.
- Copyright (C) 1993,94,95,96,98,99,2002,2007 Free Software Foundation, Inc.
+ Copyright (C) 1993,94,95,96,98,99,2002,2007,2008
+ 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
@@ -342,10 +343,12 @@ extern mach_msg_timeout_t _hurd_interrupted_rpc_timeout;
do \
{ \
/* Get the message port. */ \
- if (__err = (fetch_msgport_expr)) \
+ __err = (fetch_msgport_expr); \
+ if (__err) \
break; \
/* Get the reference port. */ \
- if (__err = (fetch_refport_expr)) \
+ _err = (fetch_refport_expr); \
+ if (__err) \
{ \
/* Couldn't get it; deallocate MSGPORT and fail. */ \
__mach_port_deallocate (__mach_task_self (), msgport); \
diff --git a/libc/iconv/gconv_simple.c b/libc/iconv/gconv_simple.c
index ec8f38a96..5cf3237ab 100644
--- a/libc/iconv/gconv_simple.c
+++ b/libc/iconv/gconv_simple.c
@@ -1,5 +1,5 @@
/* Simple transformations functions.
- Copyright (C) 1997-2003, 2004, 2005, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1997-2005, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
@@ -820,9 +820,11 @@ ucs4le_internal_loop_single (struct __gconv_step *step,
STANDARD_FROM_LOOP_ERR_HANDLER (1); \
} \
else \
- /* It's an one byte sequence. */ \
- *((uint32_t *) outptr) = *inptr++; \
- outptr += sizeof (uint32_t); \
+ { \
+ /* It's an one byte sequence. */ \
+ *((uint32_t *) outptr) = *inptr++; \
+ outptr += sizeof (uint32_t); \
+ } \
}
#define LOOP_NEED_FLAGS
#include <iconv/loop.c>
@@ -851,9 +853,11 @@ ucs4le_internal_loop_single (struct __gconv_step *step,
STANDARD_TO_LOOP_ERR_HANDLER (4); \
} \
else \
- /* It's an one byte sequence. */ \
- *outptr++ = *((const uint32_t *) inptr); \
- inptr += sizeof (uint32_t); \
+ { \
+ /* It's an one byte sequence. */ \
+ *outptr++ = *((const uint32_t *) inptr); \
+ inptr += sizeof (uint32_t); \
+ } \
}
#define LOOP_NEED_FLAGS
#include <iconv/loop.c>
diff --git a/libc/iconvdata/Depend b/libc/iconvdata/Depend
index 401deb536..38c28d0c9 100644
--- a/libc/iconvdata/Depend
+++ b/libc/iconvdata/Depend
@@ -1 +1,2 @@
iconv
+localedata
diff --git a/libc/iconvdata/Makefile b/libc/iconvdata/Makefile
index af51901a2..6a8daed5f 100644
--- a/libc/iconvdata/Makefile
+++ b/libc/iconvdata/Makefile
@@ -76,6 +76,9 @@ tests += bug-iconv3
endif
test-srcs := tst-table-from tst-table-to
+
+bug-iconv6-ENV = LOCPATH=$(common-objpfx)localedata
+tst-iconv7-ENV = LOCPATH=$(common-objpfx)localedata
endif
# No code here is in libc.so.
diff --git a/libc/iconvdata/bug-iconv6.c b/libc/iconvdata/bug-iconv6.c
index f920954bc..b364f4c16 100644
--- a/libc/iconvdata/bug-iconv6.c
+++ b/libc/iconvdata/bug-iconv6.c
@@ -13,7 +13,7 @@ static const char testbuf[] = {
static int
do_test (void)
{
- setlocale (LC_ALL, "en_US.UTF-8");
+ setlocale (LC_ALL, "de_DE.UTF-8");
iconv_t ic = iconv_open ("ISO-2022-JP//TRANSLIT", "UTF-8");
if (ic == (iconv_t) -1)
{
diff --git a/libc/iconvdata/run-iconv-test.sh b/libc/iconvdata/run-iconv-test.sh
index d2361c314..03f53b187 100755
--- a/libc/iconvdata/run-iconv-test.sh
+++ b/libc/iconvdata/run-iconv-test.sh
@@ -1,6 +1,6 @@
#! /bin/sh -f
# Run available iconv(1) tests.
-# Copyright (C) 1998-2002, 2005, 2006 Free Software Foundation, Inc.
+# Copyright (C) 1998-2002, 2005, 2006, 2008 Free Software Foundation, Inc.
# This file is part of the GNU C Library.
# Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
#
@@ -137,7 +137,7 @@ while read from to subset targets <&5; do
done
fi
- if test "$subset" == N; then
+ if test "$subset" = N; then
echo $ac_n " suntzu: ASCII -> $to -> ASCII $ac_c"
$PROG -f ASCII -t $to testdata/suntzus |
$PROG -f $to -t ASCII > $temp1 ||
diff --git a/libc/include/arpa/nameser.h b/libc/include/arpa/nameser.h
index efbe95660..57f745784 100644
--- a/libc/include/arpa/nameser.h
+++ b/libc/include/arpa/nameser.h
@@ -1,3 +1,5 @@
+#ifndef _ARPA_NAMESER_H_
+
#include <resolv/arpa/nameser.h>
/* If the machine allows unaligned access we can do better than using
@@ -7,14 +9,14 @@
#include <stdint.h>
#include <netinet/in.h>
-extern struct _ns_flagdata _ns_flagdata[] attribute_hidden;
+extern const struct _ns_flagdata _ns_flagdata[] attribute_hidden;
#if _STRING_ARCH_unaligned
# undef NS_GET16
# define NS_GET16(s, cp) \
do { \
- uint16_t *t_cp = (uint16_t *) (cp); \
+ const uint16_t *t_cp = (const uint16_t *) (cp); \
(s) = ntohs (*t_cp); \
(cp) += NS_INT16SZ; \
} while (0)
@@ -22,7 +24,7 @@ extern struct _ns_flagdata _ns_flagdata[] attribute_hidden;
# undef NS_GET32
# define NS_GET32(l, cp) \
do { \
- uint32_t *t_cp = (uint32_t *) (cp); \
+ const uint32_t *t_cp = (const uint32_t *) (cp); \
(l) = ntohl (*t_cp); \
(cp) += NS_INT32SZ; \
} while (0)
@@ -44,3 +46,32 @@ extern struct _ns_flagdata _ns_flagdata[] attribute_hidden;
} while (0)
#endif
+
+extern u_int __ns_get16 (const u_char *) __THROW;
+extern u_long __ns_get32 (const u_char *) __THROW;
+
+#define ns_msg_getflag(handle, flag) \
+ (((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift)
+
+libresolv_hidden_proto (ns_get16)
+libresolv_hidden_proto (ns_get32)
+libresolv_hidden_proto (ns_put16)
+libresolv_hidden_proto (ns_put32)
+libresolv_hidden_proto (ns_initparse)
+libresolv_hidden_proto (ns_skiprr)
+libresolv_hidden_proto (ns_parserr)
+libresolv_hidden_proto (ns_name_ntop)
+libresolv_hidden_proto (ns_name_pton)
+libresolv_hidden_proto (ns_name_pack)
+libresolv_hidden_proto (ns_name_skip)
+libresolv_hidden_proto (ns_name_unpack)
+libresolv_hidden_proto (ns_name_compress)
+libresolv_hidden_proto (ns_name_uncompress)
+libresolv_hidden_proto (ns_sprintrr)
+libresolv_hidden_proto (ns_sprintrrf)
+libresolv_hidden_proto (ns_samedomain)
+libresolv_hidden_proto (ns_samename)
+libresolv_hidden_proto (ns_makecanon)
+libresolv_hidden_proto (ns_format_ttl)
+
+#endif
diff --git a/libc/include/arpa/nameser_compat.h b/libc/include/arpa/nameser_compat.h
index bfbb2de58..2e735ede4 100644
--- a/libc/include/arpa/nameser_compat.h
+++ b/libc/include/arpa/nameser_compat.h
@@ -1 +1,8 @@
+#ifndef _ARPA_NAMESER_COMPAT_
#include <resolv/arpa/nameser_compat.h>
+
+/* Picksome unused number to represent lookups of IPv4 and IPv6 (i.e.,
+ T_A and T_AAAA). */
+#define T_UNSPEC 62321
+
+#endif
diff --git a/libc/include/features.h b/libc/include/features.h
index d94436bc7..c7c31a2a7 100644
--- a/libc/include/features.h
+++ b/libc/include/features.h
@@ -310,7 +310,7 @@
/* Major and minor version number of the GNU C library package. Use
these macros to test for features in specific releases. */
#define __GLIBC__ 2
-#define __GLIBC_MINOR__ 7
+#define __GLIBC_MINOR__ 8
#define __GLIBC_PREREQ(maj, min) \
((__GLIBC__ << 16) + __GLIBC_MINOR__ >= ((maj) << 16) + (min))
diff --git a/libc/include/fenv.h b/libc/include/fenv.h
index 673eb4b97..3aec7e52b 100644
--- a/libc/include/fenv.h
+++ b/libc/include/fenv.h
@@ -4,6 +4,7 @@
/* Now define the internal interfaces. */
extern int __feclearexcept (int __excepts);
+extern int __fegetexcept (void);
extern int __fegetexceptflag (fexcept_t *__flagp, int __excepts);
extern int __feraiseexcept (int __excepts);
extern int __fesetexceptflag (__const fexcept_t *__flagp, int __excepts);
diff --git a/libc/include/inline-hashtab.h b/libc/include/inline-hashtab.h
new file mode 100644
index 000000000..c359161c5
--- /dev/null
+++ b/libc/include/inline-hashtab.h
@@ -0,0 +1,301 @@
+/* Fully-inline hash table, used mainly for managing TLS descriptors.
+
+ Copyright (C) 1999, 2000, 2001, 2002, 2003, 2005, 2008
+ Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Alexandre Oliva <aoliva@redhat.com>
+
+ This file is derived from a 2003's version of libiberty's
+ hashtab.c, contributed by Vladimir Makarov (vmakarov@cygnus.com),
+ but with most adaptation points and support for deleting elements
+ removed.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef INLINE_HASHTAB_H
+# define INLINE_HASHTAB_H 1
+
+extern void weak_function free (void *ptr);
+
+inline static unsigned long
+higher_prime_number (unsigned long n)
+{
+ /* These are primes that are near, but slightly smaller than, a
+ power of two. */
+ static const uint32_t primes[] = {
+ UINT32_C (7),
+ UINT32_C (13),
+ UINT32_C (31),
+ UINT32_C (61),
+ UINT32_C (127),
+ UINT32_C (251),
+ UINT32_C (509),
+ UINT32_C (1021),
+ UINT32_C (2039),
+ UINT32_C (4093),
+ UINT32_C (8191),
+ UINT32_C (16381),
+ UINT32_C (32749),
+ UINT32_C (65521),
+ UINT32_C (131071),
+ UINT32_C (262139),
+ UINT32_C (524287),
+ UINT32_C (1048573),
+ UINT32_C (2097143),
+ UINT32_C (4194301),
+ UINT32_C (8388593),
+ UINT32_C (16777213),
+ UINT32_C (33554393),
+ UINT32_C (67108859),
+ UINT32_C (134217689),
+ UINT32_C (268435399),
+ UINT32_C (536870909),
+ UINT32_C (1073741789),
+ UINT32_C (2147483647),
+ /* 4294967291L */
+ UINT32_C (2147483647) + UINT32_C (2147483644)
+ };
+
+ const uint32_t *low = &primes[0];
+ const uint32_t *high = &primes[sizeof (primes) / sizeof (primes[0])];
+
+ while (low != high)
+ {
+ const uint32_t *mid = low + (high - low) / 2;
+ if (n > *mid)
+ low = mid + 1;
+ else
+ high = mid;
+ }
+
+#if 0
+ /* If we've run out of primes, abort. */
+ if (n > *low)
+ {
+ fprintf (stderr, "Cannot find prime bigger than %lu\n", n);
+ abort ();
+ }
+#endif
+
+ return *low;
+}
+
+struct hashtab
+{
+ /* Table itself. */
+ void **entries;
+
+ /* Current size (in entries) of the hash table */
+ size_t size;
+
+ /* Current number of elements. */
+ size_t n_elements;
+
+ /* Free function for the entries array. This may vary depending on
+ how early the array was allocated. If it is NULL, then the array
+ can't be freed. */
+ void (*free) (void *ptr);
+};
+
+inline static struct hashtab *
+htab_create (void)
+{
+ struct hashtab *ht = malloc (sizeof (struct hashtab));
+
+ if (! ht)
+ return NULL;
+ ht->size = 3;
+ ht->entries = malloc (sizeof (void *) * ht->size);
+ ht->free = free;
+ if (! ht->entries)
+ {
+ if (ht->free)
+ ht->free (ht);
+ return NULL;
+ }
+
+ ht->n_elements = 0;
+
+ memset (ht->entries, 0, sizeof (void *) * ht->size);
+
+ return ht;
+}
+
+/* This is only called from _dl_unmap, so it's safe to call
+ free(). */
+inline static void
+htab_delete (struct hashtab *htab)
+{
+ int i;
+
+ for (i = htab->size - 1; i >= 0; i--)
+ free (htab->entries[i]);
+
+ if (htab->free)
+ htab->free (htab->entries);
+ free (htab);
+}
+
+/* Similar to htab_find_slot, but without several unwanted side effects:
+ - Does not call htab->eq_f when it finds an existing entry.
+ - Does not change the count of elements/searches/collisions in the
+ hash table.
+ This function also assumes there are no deleted entries in the table.
+ HASH is the hash value for the element to be inserted. */
+
+inline static void **
+find_empty_slot_for_expand (struct hashtab *htab, int hash)
+{
+ size_t size = htab->size;
+ unsigned int index = hash % size;
+ void **slot = htab->entries + index;
+ int hash2;
+
+ if (! *slot)
+ return slot;
+
+ hash2 = 1 + hash % (size - 2);
+ for (;;)
+ {
+ index += hash2;
+ if (index >= size)
+ index -= size;
+
+ slot = htab->entries + index;
+ if (! *slot)
+ return slot;
+ }
+}
+
+/* The following function changes size of memory allocated for the
+ entries and repeatedly inserts the table elements. The occupancy
+ of the table after the call will be about 50%. Naturally the hash
+ table must already exist. Remember also that the place of the
+ table entries is changed. If memory allocation failures are allowed,
+ this function will return zero, indicating that the table could not be
+ expanded. If all goes well, it will return a non-zero value. */
+
+inline static int
+htab_expand (struct hashtab *htab, int (*hash_fn) (void *))
+{
+ void **oentries;
+ void **olimit;
+ void **p;
+ void **nentries;
+ size_t nsize;
+
+ oentries = htab->entries;
+ olimit = oentries + htab->size;
+
+ /* Resize only when table after removal of unused elements is either
+ too full or too empty. */
+ if (htab->n_elements * 2 > htab->size)
+ nsize = higher_prime_number (htab->n_elements * 2);
+ else
+ nsize = htab->size;
+
+ nentries = malloc (sizeof (void *) * nsize);
+ memset (nentries, 0, sizeof (void *) * nsize);
+ if (nentries == NULL)
+ return 0;
+ htab->entries = nentries;
+ htab->size = nsize;
+
+ p = oentries;
+ do
+ {
+ if (*p)
+ *find_empty_slot_for_expand (htab, hash_fn (*p))
+ = *p;
+
+ p++;
+ }
+ while (p < olimit);
+
+ /* Without recording the free corresponding to the malloc used to
+ allocate the table, we couldn't tell whether this was allocated
+ by the malloc() built into ld.so or the one in the main
+ executable or libc. Calling free() for something that was
+ allocated by the early malloc(), rather than the final run-time
+ malloc() could do Very Bad Things (TM). We will waste memory
+ allocated early as long as there's no corresponding free(), but
+ this isn't so much memory as to be significant. */
+
+ if (htab->free)
+ htab->free (oentries);
+
+ /* Use the free() corresponding to the malloc() above to free this
+ up. */
+ htab->free = free;
+
+ return 1;
+}
+
+/* This function searches for a hash table slot containing an entry
+ equal to the given element. To delete an entry, call this with
+ INSERT = 0, then call htab_clear_slot on the slot returned (possibly
+ after doing some checks). To insert an entry, call this with
+ INSERT = 1, then write the value you want into the returned slot.
+ When inserting an entry, NULL may be returned if memory allocation
+ fails. */
+
+inline static void **
+htab_find_slot (struct hashtab *htab, void *ptr, int insert,
+ int (*hash_fn)(void *), int (*eq_fn)(void *, void *))
+{
+ unsigned int index;
+ int hash, hash2;
+ size_t size;
+ void **entry;
+
+ if (htab->size * 3 <= htab->n_elements * 4
+ && htab_expand (htab, hash_fn) == 0)
+ return NULL;
+
+ hash = hash_fn (ptr);
+
+ size = htab->size;
+ index = hash % size;
+
+ entry = &htab->entries[index];
+ if (!*entry)
+ goto empty_entry;
+ else if (eq_fn (*entry, ptr))
+ return entry;
+
+ hash2 = 1 + hash % (size - 2);
+ for (;;)
+ {
+ index += hash2;
+ if (index >= size)
+ index -= size;
+
+ entry = &htab->entries[index];
+ if (!*entry)
+ goto empty_entry;
+ else if (eq_fn (*entry, ptr))
+ return entry;
+ }
+
+ empty_entry:
+ if (!insert)
+ return NULL;
+
+ htab->n_elements++;
+ return entry;
+}
+
+#endif /* INLINE_HASHTAB_H */
diff --git a/libc/include/resolv.h b/libc/include/resolv.h
index c1c89f0ad..7ab7f8779 100644
--- a/libc/include/resolv.h
+++ b/libc/include/resolv.h
@@ -58,11 +58,11 @@ libc_hidden_proto (__res_randomid)
libc_hidden_proto (__res_state)
int __libc_res_nquery (res_state, const char *, int, int, u_char *, int,
- u_char **);
+ u_char **, u_char **, int *, int *);
int __libc_res_nsearch (res_state, const char *, int, int, u_char *, int,
- u_char **);
-int __libc_res_nsend (res_state, const u_char *, int, u_char *, int,
- u_char **)
+ u_char **, u_char **, int *, int *);
+int __libc_res_nsend (res_state, const u_char *, int, const u_char *, int,
+ u_char *, int, u_char **, u_char **, int *, int *)
attribute_hidden;
libresolv_hidden_proto (_sethtent)
@@ -98,11 +98,9 @@ libresolv_hidden_proto (__res_nameinquery)
libresolv_hidden_proto (__res_queriesmatch)
libresolv_hidden_proto (__res_nsend)
libresolv_hidden_proto (__b64_ntop)
-libresolv_hidden_proto (__ns_name_ntop)
-libresolv_hidden_proto (__ns_name_unpack)
-libresolv_hidden_proto (__ns_get16)
-libresolv_hidden_proto (__ns_get32)
libresolv_hidden_proto (__res_nopt)
+libresolv_hidden_proto (__dn_count_labels)
+libresolv_hidden_proto (__p_secstodate)
extern const char *_res_opcodes[];
libresolv_hidden_proto (_res_opcodes)
diff --git a/libc/include/rpc/clnt.h b/libc/include/rpc/clnt.h
index 1e72e22bc..75d88a65c 100644
--- a/libc/include/rpc/clnt.h
+++ b/libc/include/rpc/clnt.h
@@ -21,6 +21,18 @@ extern CLIENT *clntudp_bufcreate_internal (struct sockaddr_in *__raddr,
struct timeval __wait_resend,
int *__sockp, u_int __sendsz,
u_int __recvsz) attribute_hidden;
+extern CLIENT *__libc_clntudp_bufcreate (struct sockaddr_in *__raddr,
+ u_long __program, u_long __version,
+ struct timeval __wait_resend,
+ int *__sockp, u_int __sendsz,
+ u_int __recvsz, int __flags);
+extern CLIENT *__libc_clntudp_bufcreate_internal (struct sockaddr_in *__raddr,
+ u_long __program,
+ u_long __version,
+ struct timeval __wait_resend,
+ int *__sockp, u_int __sendsz,
+ u_int __recvsz, int __flags)
+ attribute_hidden;
extern CLIENT *clntunix_create_internal (struct sockaddr_un *__raddr,
u_long __program, u_long __version,
int *__sockp, u_int __sendsz,
diff --git a/libc/include/sys/socket.h b/libc/include/sys/socket.h
index 0a226726a..df892783a 100644
--- a/libc/include/sys/socket.h
+++ b/libc/include/sys/socket.h
@@ -153,4 +153,12 @@ extern int __libc_sa_len_internal (sa_family_t __af) attribute_hidden;
# define __connect(fd, addr, len) INTUSE(__connect) (fd, addr, len)
#endif
+#ifdef SOCK_CLOEXEC
+extern int __have_sock_cloexec;
+/* At lot of other functionality became available at the same time as
+ SOCK_CLOEXEC. Avoid defining separate variables for all of them
+ unless it is really necessary. */
+# define __have_paccept __have_sock_cloexec
+#endif
+
#endif
diff --git a/libc/include/unistd.h b/libc/include/unistd.h
index f34d53f22..34d7477f9 100644
--- a/libc/include/unistd.h
+++ b/libc/include/unistd.h
@@ -48,6 +48,7 @@ extern ssize_t __libc_write (int __fd, __const void *__buf, size_t __n);
libc_hidden_proto (__libc_write)
extern int __pipe (int __pipedes[2]);
libc_hidden_proto (__pipe)
+extern int __pipe2 (int __pipedes[2], int __flags);
extern unsigned int __sleep (unsigned int __seconds);
extern int __chown (__const char *__file,
__uid_t __owner, __gid_t __group);
@@ -165,4 +166,10 @@ extern int __libc_pause (void);
/* Not cancelable variant. */
extern int __pause_nocancel (void) attribute_hidden;
+extern int __have_sock_cloexec;
+/* At lot of other functionality became available at the same time as
+ SOCK_CLOEXEC. Avoid defining separate variables for all of them
+ unless it is really necessary. */
+#define __have_pipe2 __have_sock_cloexec
+
#endif
diff --git a/libc/inet/netinet/in.h b/libc/inet/netinet/in.h
index e3446a999..180227af5 100644
--- a/libc/inet/netinet/in.h
+++ b/libc/inet/netinet/in.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991-2001, 2003, 2004, 2006, 2007
+/* Copyright (C) 1991-2001, 2003, 2004, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -53,6 +53,8 @@ enum
#define IPPROTO_IDP IPPROTO_IDP
IPPROTO_TP = 29, /* SO Transport Protocol Class 4. */
#define IPPROTO_TP IPPROTO_TP
+ IPPROTO_DCCP = 33, /* Datagram Congestion Control Protocol. */
+#define IPPROTO_DCCP IPPROTO_DCCP
IPPROTO_IPV6 = 41, /* IPv6 header. */
#define IPPROTO_IPV6 IPPROTO_IPV6
IPPROTO_ROUTING = 43, /* IPv6 routing header. */
@@ -83,6 +85,8 @@ enum
#define IPPROTO_COMP IPPROTO_COMP
IPPROTO_SCTP = 132, /* Stream Control Transmission Protocol. */
#define IPPROTO_SCTP IPPROTO_SCTP
+ IPPROTO_UDPLITE = 136, /* UDP-Lite protocol. */
+#define IPPROTO_UDPLITE IPPROTO_UDPLITE
IPPROTO_RAW = 255, /* Raw IP packets. */
#define IPPROTO_RAW IPPROTO_RAW
IPPROTO_MAX
diff --git a/libc/io/Makefile b/libc/io/Makefile
index e83952e06..8edfee01d 100644
--- a/libc/io/Makefile
+++ b/libc/io/Makefile
@@ -1,4 +1,4 @@
-# Copyright (C) 1992-2002,2003,2005,2006, 2007 Free Software Foundation, Inc.
+# Copyright (C) 1992-2003,2005,2006,2007,2008 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
@@ -42,7 +42,7 @@ routines := \
open open64 openat openat64 close \
read write lseek lseek64 access euidaccess faccessat \
fcntl flock lockf lockf64 \
- dup dup2 pipe \
+ dup dup2 dup3 pipe pipe2 \
creat creat64 \
chdir fchdir \
getcwd getwd getdirname \
diff --git a/libc/io/Versions b/libc/io/Versions
index d603668f4..6c0a23b46 100644
--- a/libc/io/Versions
+++ b/libc/io/Versions
@@ -119,4 +119,7 @@ libc {
GLIBC_2.7 {
__open_2; __open64_2; __openat_2; __openat64_2;
}
+ GLIBC_2.9 {
+ dup3; pipe2;
+ }
}
diff --git a/libc/io/dup3.c b/libc/io/dup3.c
new file mode 100644
index 000000000..162ab4e68
--- /dev/null
+++ b/libc/io/dup3.c
@@ -0,0 +1,48 @@
+/* Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <errno.h>
+#include <fcntl.h>
+#include <unistd.h>
+
+
+/* Duplicate FD to FD2, closing the old FD2 and making FD2 be
+ open the same file as FD is which setting flags according to
+ FLAGS. Return FD2 or -1. */
+int
+dup3 (fd, fd2, flags)
+ int fd;
+ int fd2;
+ int flags;
+{
+ if (fd < 0 || fd2 < 0)
+ {
+ __set_errno (EBADF);
+ return -1;
+ }
+
+ if (fd == fd2)
+ /* No way to check that they are valid. */
+ return fd2;
+
+ __set_errno (ENOSYS);
+ return -1;
+}
+stub_warning (dup3)
+
+#include <stub-tag.h>
diff --git a/libc/io/ftw.c b/libc/io/ftw.c
index 5495bc7ec..9cc09077e 100644
--- a/libc/io/ftw.c
+++ b/libc/io/ftw.c
@@ -1,5 +1,5 @@
/* File tree walker functions.
- Copyright (C) 1996-2003, 2004, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1996-2004, 2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
@@ -243,7 +243,7 @@ object_compare (const void *p1, const void *p2)
}
-static inline int
+static int
add_object (struct ftw_data *data, struct STAT *st)
{
struct known_object *newp = malloc (sizeof (struct known_object));
diff --git a/libc/io/openat.c b/libc/io/openat.c
index 98fa1a1d6..a6bd62094 100644
--- a/libc/io/openat.c
+++ b/libc/io/openat.c
@@ -79,7 +79,7 @@ __openat_2 (fd, file, oflag)
if (oflag & O_CREAT)
__fortify_fail ("invalid openat call: O_CREAT without mode");
- return __openat (file, oflag);
+ return __openat (fd, file, oflag);
}
stub_warning (__openat_2)
diff --git a/libc/io/openat64.c b/libc/io/openat64.c
index 2d63490c6..1532afeea 100644
--- a/libc/io/openat64.c
+++ b/libc/io/openat64.c
@@ -79,7 +79,7 @@ __openat64_2 (fd, file, oflag)
if (oflag & O_CREAT)
__fortify_fail ("invalid openat64 call: O_CREAT without mode");
- return __openat64 (file, oflag);
+ return __openat64 (fd, file, oflag);
}
stub_warning (__openat_2)
diff --git a/ports/sysdeps/unix/sysv/linux/mips/xmknod.c b/libc/io/pipe2.c
index 2d0975240..aa54d17ae 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/xmknod.c
+++ b/libc/io/pipe2.c
@@ -1,6 +1,4 @@
-/* xmknod call using old-style Unix mknod system call.
- Copyright (C) 1991, 1993, 1995, 1996, 1997, 1998, 2000, 2002, 2003
- Free Software Foundation, Inc.
+/* Copyright (C) 1991, 1995, 1996, 2002, 2008 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,33 +17,28 @@
02111-1307 USA. */
#include <errno.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <sys/sysmacros.h>
+#include <unistd.h>
+#include <stddef.h>
-#include <sysdep.h>
-#include <sys/syscall.h>
-#include <bp-checks.h>
-
-/* Create a device file named PATH, with permission and special bits MODE
- and device number DEV (which can be constructed from major and minor
- device numbers with the `makedev' macro above). */
+/* Create a one-way communication channel (__pipe). If successful,
+ two file descriptors are stored in PIPEDES; bytes written on
+ PIPEDES[1] can be read from PIPEDES[0]. Apply FLAGS to the new
+ file descriptors. Returns 0 if successful, -1 if not. */
int
-__xmknod (int vers, const char *path, mode_t mode, dev_t *dev)
+__pipe2 (pipedes, flags)
+ int pipedes[2];
+ int flags;
{
- unsigned long k_dev;
-
- if (vers != _MKNOD_VER)
+ if (pipedes == NULL)
{
__set_errno (EINVAL);
return -1;
}
- /* We must convert the value to dev_t type used by the kernel. */
- k_dev = ((major (*dev) & 0xff) << 8) | (minor (*dev) & 0xff);
-
- return INLINE_SYSCALL (mknod, 3, CHECK_STRING (path), mode, k_dev);
+ __set_errno (ENOSYS);
+ return -1;
}
+weak_alias (__pipe2, pipe2)
+stub_warning (pipe2)
-weak_alias (__xmknod, _xmknod)
-libc_hidden_def (__xmknod)
+#include <stub-tag.h>
diff --git a/libc/libio/Makefile b/libc/libio/Makefile
index 260e82951..5a835a11d 100644
--- a/libc/libio/Makefile
+++ b/libc/libio/Makefile
@@ -1,4 +1,4 @@
-# Copyright (C) 1995-2002,2003,2004,2006,2007 Free Software Foundation, Inc.
+# Copyright (C) 1995-2004,2006,2007,2008 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
@@ -67,7 +67,7 @@ tests = test-fmemopen tst-ext tst-ext2 \
tst-mmap2-eofsync tst-mmap-offend bug-fopena+ \
bug-ungetc2 bug-ungetc3 bug-ungetc4 \
tst-memstream1 tst-memstream2 \
- bug-memstream1
+ bug-memstream1 tst-popen1
tests-$(OPTION_EGLIBC_LOCALE_CODE) \
+= tst-swscanf tst-fgetws tst-fopenloc tst-setvbuf1 \
tst-ungetwc1 tst-ungetwc2 bug-ftell bug-ungetwc2 \
diff --git a/libc/libio/fileops.c b/libc/libio/fileops.c
index 16fa2c297..2d86013c9 100644
--- a/libc/libio/fileops.c
+++ b/libc/libio/fileops.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 1995, 1997-2005, 2006, 2007
+/* Copyright (C) 1993, 1995, 1997-2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
Written by Per Bothner <bothner@cygnus.com>.
@@ -435,9 +435,11 @@ _IO_new_file_attach (fp, fd)
/* Get the current position of the file. */
/* We have to do that since that may be junk. */
fp->_offset = _IO_pos_BAD;
+ int save_errno = errno;
if (_IO_SEEKOFF (fp, (_IO_off64_t)0, _IO_seek_cur, _IOS_INPUT|_IOS_OUTPUT)
== _IO_pos_BAD && errno != ESPIPE)
return NULL;
+ __set_errno (save_errno);
return fp;
}
INTDEF2(_IO_new_file_attach, _IO_file_attach)
diff --git a/libc/libio/fmemopen.c b/libc/libio/fmemopen.c
index f3b280092..b618ce585 100644
--- a/libc/libio/fmemopen.c
+++ b/libc/libio/fmemopen.c
@@ -1,7 +1,7 @@
/* Fmemopen implementation.
- Copyright (C) 2000, 2002, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2002, 2005, 2006, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
- Contributed by Hanno Mueller, kontakt@hanno.de, 2000.
+ Contributed by Hanno Mueller, kontakt@hanno.de, 2000.
The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
@@ -82,6 +82,7 @@ struct fmemopen_cookie_struct
{
char *buffer;
int mybuffer;
+ int binmode;
size_t size;
_IO_off64_t pos;
size_t maxpos;
@@ -120,7 +121,7 @@ fmemopen_write (void *cookie, const char *b, size_t s)
c = (fmemopen_cookie_t *) cookie;
- addnullc = s == 0 || b[s - 1] != '\0';
+ addnullc = c->binmode == 0 && (s == 0 || b[s - 1] != '\0');
if (c->pos + s + addnullc > c->size)
{
@@ -165,7 +166,7 @@ fmemopen_seek (void *cookie, _IO_off64_t *p, int w)
break;
case SEEK_END:
- np = c->maxpos - *p;
+ np = (c->binmode ? c->size : c->maxpos) - *p;
break;
default:
@@ -248,6 +249,8 @@ fmemopen (void *buf, size_t len, const char *mode)
else
c->pos = 0;
+ c->binmode = mode[0] != '\0' && mode[1] == 'b';
+
iof.read = fmemopen_read;
iof.write = fmemopen_write;
iof.seek = fmemopen_seek;
diff --git a/libc/libio/freopen.c b/libc/libio/freopen.c
index d94a5629f..d80815f91 100644
--- a/libc/libio/freopen.c
+++ b/libc/libio/freopen.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993,95,96,97,98,2000,2001,2002,2003
+/* Copyright (C) 1993,95,96,97,98,2000,2001,2002,2003,2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -80,8 +80,7 @@ freopen (filename, mode, fp)
if (fd != -1)
{
__close (fd);
- if (filename != NULL)
- free ((char *) filename);
+ free ((char *) filename);
}
_IO_release_lock (fp);
return result;
diff --git a/libc/libio/freopen64.c b/libc/libio/freopen64.c
index f8da78c46..2dad6d7b4 100644
--- a/libc/libio/freopen64.c
+++ b/libc/libio/freopen64.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993,1995,1996,1997,1998,2000,2001,2002, 2003
+/* Copyright (C) 1993,1995,1996,1997,1998,2000,2001,2002, 2003, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -64,8 +64,7 @@ freopen64 (filename, mode, fp)
if (fd != -1)
{
__close (fd);
- if (filename != NULL)
- free ((char *) filename);
+ free ((char *) filename);
}
_IO_release_lock (fp);
return result;
diff --git a/libc/libio/iofwrite.c b/libc/libio/iofwrite.c
index 1f4331cc8..fb91d6f77 100644
--- a/libc/libio/iofwrite.c
+++ b/libc/libio/iofwrite.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 1996, 1997, 1998, 1999, 2000, 2002, 2003
+/* Copyright (C) 1993, 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -44,7 +44,11 @@ _IO_fwrite (buf, size, count, fp)
if (_IO_vtable_offset (fp) != 0 || _IO_fwide (fp, -1) == -1)
written = _IO_sputn (fp, (const char *) buf, request);
_IO_release_lock (fp);
- if (written == request)
+ /* We have written all of the input in case the return value indicates
+ this or EOF is returned. The latter is a special case where we
+ simply did not manage to flush the buffer. But the data is in the
+ buffer and therefore written as far as fwrite is concerned. */
+ if (written == request || written == EOF)
return count;
else
return written / size;
diff --git a/libc/libio/iofwrite_u.c b/libc/libio/iofwrite_u.c
index 738cc5b28..d27c02ac3 100644
--- a/libc/libio/iofwrite_u.c
+++ b/libc/libio/iofwrite_u.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 1996-2000, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1993, 1996-2000, 2002, 2008 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
@@ -45,7 +45,11 @@ fwrite_unlocked (buf, size, count, fp)
if (_IO_fwide (fp, -1) == -1)
{
written = _IO_sputn (fp, (const char *) buf, request);
- if (written == request)
+ /* We have written all of the input in case the return value indicates
+ this or EOF is returned. The latter is a special case where we
+ simply did not manage to flush the buffer. But the data is in the
+ buffer and therefore written as far as fwrite is concerned. */
+ if (written == request || written == EOF)
return count;
}
diff --git a/libc/libio/iopopen.c b/libc/libio/iopopen.c
index d5c6305b0..1a5cc0f59 100644
--- a/libc/libio/iopopen.c
+++ b/libc/libio/iopopen.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 1997-2002, 2003, 2004, 2007
+/* Copyright (C) 1993, 1997-2002, 2003, 2004, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
Written by Per Bothner <bothner@cygnus.com>.
@@ -44,6 +44,7 @@
#endif
#include <sys/types.h>
#include <sys/wait.h>
+#include <kernel-features.h>
#ifndef _IO_fork
#ifdef _LIBC
@@ -56,15 +57,6 @@ extern _IO_pid_t _IO_fork (void) __THROW;
#endif /* _IO_HAVE_SYS_WAIT */
-#ifndef _IO_pipe
-#ifdef _LIBC
-#define _IO_pipe __pipe
-#else
-#define _IO_pipe pipe
-#endif
-extern int _IO_pipe (int des[2]) __THROW;
-#endif
-
#ifndef _IO_dup2
#ifdef _LIBC
#define _IO_dup2 __dup2
@@ -127,45 +119,103 @@ _IO_new_proc_open (fp, command, mode)
const char *mode;
{
#if _IO_HAVE_SYS_WAIT
- volatile int read_or_write;
- volatile int parent_end, child_end;
+ int read_or_write;
+ int parent_end, child_end;
int pipe_fds[2];
_IO_pid_t child_pid;
+
+ int do_read = 0;
+ int do_write = 0;
+ int do_cloexec = 0;
+ while (*mode != '\0')
+ switch (*mode++)
+ {
+ case 'r':
+ do_read = 1;
+ break;
+ case 'w':
+ do_write = 1;
+ break;
+ case 'e':
+ do_cloexec = 1;
+ break;
+ default:
+ errout:
+ __set_errno (EINVAL);
+ return NULL;
+ }
+
+ if ((do_read ^ do_write) == 0)
+ goto errout;
+
if (_IO_file_is_open (fp))
return NULL;
- if (_IO_pipe (pipe_fds) < 0)
- return NULL;
- if (mode[0] == 'r' && mode[1] == '\0')
+
+#ifdef O_CLOEXEC
+# ifndef __ASSUME_PIPE2
+ if (__have_pipe2 >= 0)
+# endif
+ {
+ int r = __pipe2 (pipe_fds, O_CLOEXEC);
+# ifndef __ASSUME_PIPE2
+ if (__have_pipe2 == 0)
+ __have_pipe2 = r != -1 || errno != ENOSYS ? 1 : -1;
+
+ if (__have_pipe2 > 0)
+# endif
+ if (r < 0)
+ return NULL;
+ }
+#endif
+#ifndef __ASSUME_PIPE2
+# ifdef O_CLOEXEC
+ if (__have_pipe2 < 0)
+# endif
+ if (__pipe (pipe_fds) < 0)
+ return NULL;
+#endif
+
+ if (do_read)
{
parent_end = pipe_fds[0];
child_end = pipe_fds[1];
read_or_write = _IO_NO_WRITES;
}
- else if (mode[0] == 'w' && mode[1] == '\0')
+ else
{
parent_end = pipe_fds[1];
child_end = pipe_fds[0];
read_or_write = _IO_NO_READS;
}
- else
- {
- _IO_close (pipe_fds[0]);
- _IO_close (pipe_fds[1]);
- __set_errno (EINVAL);
- return NULL;
- }
+
((_IO_proc_file *) fp)->pid = child_pid = _IO_fork ();
if (child_pid == 0)
{
- int child_std_end = mode[0] == 'r' ? 1 : 0;
+ int child_std_end = do_read ? 1 : 0;
struct _IO_proc_file *p;
+#ifndef __ASSUME_PIPE2
+ /* If we have pipe2 the descriptor is marked for close-on-exec. */
_IO_close (parent_end);
+#endif
if (child_end != child_std_end)
{
_IO_dup2 (child_end, child_std_end);
+#ifndef __ASSUME_PIPE2
_IO_close (child_end);
+#endif
+ }
+#ifdef O_CLOEXEC
+ else
+ {
+ /* The descriptor is already the one we will use. But it must
+ not be marked close-on-exec. Undo the effects. */
+# ifndef __ASSUME_PIPE2
+ if (__have_pipe2 > 0)
+# endif
+ __fcntl (child_end, F_SETFD, 0);
}
+#endif
/* POSIX.2: "popen() shall ensure that any streams from previous
popen() calls that remain open in the parent process are closed
in the new child process." */
@@ -189,6 +239,28 @@ _IO_new_proc_open (fp, command, mode)
_IO_close (parent_end);
return NULL;
}
+
+ if (do_cloexec)
+ {
+#ifndef __ASSUME_PIPE2
+# ifdef O_CLOEXEC
+ if (__have_pipe2 < 0)
+# endif
+ __fcntl (parent_end, F_SETFD, FD_CLOEXEC);
+#endif
+ }
+ else
+ {
+#ifdef O_CLOEXEC
+ /* Undo the effects of the pipe2 call which set the
+ close-on-exec flag. */
+# ifndef __ASSUME_PIPE2
+ if (__have_pipe2 > 0)
+# endif
+ __fcntl (parent_end, F_SETFD, 0);
+#endif
+ }
+
_IO_fileno (fp) = parent_end;
/* Link into proc_file_chain. */
diff --git a/libc/libio/iosetvbuf.c b/libc/libio/iosetvbuf.c
index 7580230eb..a92eaebf8 100644
--- a/libc/libio/iosetvbuf.c
+++ b/libc/libio/iosetvbuf.c
@@ -45,7 +45,7 @@ _IO_setvbuf (fp, buf, mode, size)
switch (mode)
{
case _IOFBF:
- fp->_IO_file_flags &= ~_IO_LINE_BUF|_IO_UNBUFFERED;
+ fp->_IO_file_flags &= ~(_IO_LINE_BUF|_IO_UNBUFFERED);
if (buf == NULL)
{
if (fp->_IO_buf_base == NULL)
diff --git a/libc/libio/stdio.h b/libc/libio/stdio.h
index 1cbe9204b..9dacbe245 100644
--- a/libc/libio/stdio.h
+++ b/libc/libio/stdio.h
@@ -475,7 +475,7 @@ extern int __REDIRECT (vfscanf,
__isoc99_vfscanf)
__attribute__ ((__format__ (__scanf__, 2, 0))) __wur;
extern int __REDIRECT (vscanf, (__const char *__restrict __format,
- _G_va_list __arg), __isoc99_vfscanf)
+ _G_va_list __arg), __isoc99_vscanf)
__attribute__ ((__format__ (__scanf__, 1, 0))) __wur;
extern int __REDIRECT (vsscanf,
(__const char *__restrict __s,
diff --git a/libc/libio/tst-popen1.c b/libc/libio/tst-popen1.c
new file mode 100644
index 000000000..bae6615b9
--- /dev/null
+++ b/libc/libio/tst-popen1.c
@@ -0,0 +1,49 @@
+#include <fcntl.h>
+#include <stdio.h>
+
+static int
+do_test (void)
+{
+ int res = 0;
+
+ FILE *fp = popen ("echo hello", "r");
+ if (fp == NULL)
+ {
+ puts ("first popen failed");
+ res = 1;
+ }
+ else
+ {
+ int fd = fileno (fp);
+ if (fcntl (fd, F_GETFD) == FD_CLOEXEC)
+ {
+ puts ("first popen(\"r\") set FD_CLOEXEC");
+ res = 1;
+ }
+
+ fclose (fp);
+ }
+
+ fp = popen ("echo hello", "re");
+ if (fp == NULL)
+ {
+ puts ("second popen failed");
+ res = 1;
+ }
+ else
+ {
+ int fd = fileno (fp);
+ if (fcntl (fd, F_GETFD) != FD_CLOEXEC)
+ {
+ puts ("second popen(\"r\") did not set FD_CLOEXEC");
+ res = 1;
+ }
+
+ fclose (fp);
+ }
+
+ return res;
+}
+
+#define TEST_FUNCTION do_test ()
+#include "../test-skeleton.c"
diff --git a/libc/locale/programs/ld-collate.c b/libc/locale/programs/ld-collate.c
index 05e22d567..6425f1c6b 100644
--- a/libc/locale/programs/ld-collate.c
+++ b/libc/locale/programs/ld-collate.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995-2003, 2005, 2006, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 1995-2003, 2005-2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.org>, 1995.
@@ -2817,8 +2817,7 @@ collate_read (struct linereader *ldfile, struct localedef_t *result,
else
{
col_elem_free:
- if (symbol != NULL)
- free ((char *) symbol);
+ free ((char *) symbol);
free (arg->val.str.startmb);
free (arg->val.str.startwc);
}
@@ -2998,8 +2997,7 @@ collate_read (struct linereader *ldfile, struct localedef_t *result,
arg = lr_token (ldfile, charmap, result, repertoire, verbose);
if (arg->tok != tok_bsymbol)
{
- if (newname != NULL)
- free ((char *) newname);
+ free ((char *) newname);
goto err_label;
}
@@ -3013,10 +3011,8 @@ collate_read (struct linereader *ldfile, struct localedef_t *result,
"LC_COLLATE");
sym_equiv_free:
- if (newname != NULL)
- free ((char *) newname);
- if (symname != NULL)
- free ((char *) symname);
+ free ((char *) newname);
+ free ((char *) symname);
break;
}
if (symname == NULL)
@@ -3051,6 +3047,14 @@ error while adding equivalent collating symbol"));
break;
case tok_script:
+ /* Ignore the rest of the line if we don't need the input of
+ this line. */
+ if (ignore_content)
+ {
+ lr_ignore_rest (ldfile, 0);
+ break;
+ }
+
/* We get told about the scripts we know. */
arg = lr_token (ldfile, charmap, result, repertoire, verbose);
if (arg->tok != tok_bsymbol)
diff --git a/libc/locale/setlocale.c b/libc/locale/setlocale.c
index 0ff7167be..9593483d9 100644
--- a/libc/locale/setlocale.c
+++ b/libc/locale/setlocale.c
@@ -163,7 +163,7 @@ new_composite_name (int category, const char *newnames[__LC_LAST])
/* Put NAME in _nl_global_locale.__names. */
-static inline void
+static void
setname (int category, const char *name)
{
if (_nl_global_locale.__names[category] == name)
@@ -204,9 +204,16 @@ setlocale (int category, const char *locale)
if (locale == NULL)
return (char *) _nl_global_locale.__names[category];
+ /* Protect global data. */
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
+
if (strcmp (locale, _nl_global_locale.__names[category]) == 0)
- /* Changing to the same thing. */
- return (char *) _nl_global_locale.__names[category];
+ {
+ /* Changing to the same thing. */
+ __libc_rwlock_unlock (__libc_setlocale_lock);
+
+ return (char *) _nl_global_locale.__names[category];
+ }
/* We perhaps really have to load some data. So we determine the
path in which to look for the data now. The environment variable
@@ -220,12 +227,13 @@ setlocale (int category, const char *locale)
if (locpath_var != NULL && locpath_var[0] != '\0')
{
if (__argz_create_sep (locpath_var, ':',
- &locale_path, &locale_path_len) != 0)
- return NULL;
-
- if (__argz_add_sep (&locale_path, &locale_path_len,
- _nl_default_locale_path, ':') != 0)
- return NULL;
+ &locale_path, &locale_path_len) != 0
+ || __argz_add_sep (&locale_path, &locale_path_len,
+ _nl_default_locale_path, ':') != 0)
+ {
+ __libc_rwlock_unlock (__libc_setlocale_lock);
+ return NULL;
+ }
}
if (category == LC_ALL)
@@ -260,8 +268,13 @@ setlocale (int category, const char *locale)
break;
if (cnt == __LC_LAST)
- /* Bogus category name. */
- ERROR_RETURN;
+ {
+ error_return:
+ __libc_rwlock_unlock (__libc_setlocale_lock);
+
+ /* Bogus category name. */
+ ERROR_RETURN;
+ }
/* Found the category this clause sets. */
newnames[cnt] = ++cp;
@@ -280,12 +293,9 @@ setlocale (int category, const char *locale)
for (cnt = 0; cnt < __LC_LAST; ++cnt)
if (cnt != LC_ALL && newnames[cnt] == locale)
/* The composite name did not specify all categories. */
- ERROR_RETURN;
+ goto error_return;
}
- /* Protect global data. */
- __libc_rwlock_wrlock (__libc_setlocale_lock);
-
/* Load the new data for each category. */
while (category-- > 0)
if (category != LC_ALL)
@@ -363,9 +373,6 @@ setlocale (int category, const char *locale)
struct locale_data *newdata = NULL;
const char *newname[1] = { locale };
- /* Protect global data. */
- __libc_rwlock_wrlock (__libc_setlocale_lock);
-
if (CATEGORY_USED (category))
{
/* Only actually load the data if anything will use it. */
diff --git a/libc/localedata/ChangeLog b/libc/localedata/ChangeLog
index 324686bce..2bc9e8997 100644
--- a/libc/localedata/ChangeLog
+++ b/libc/localedata/ChangeLog
@@ -1,3 +1,78 @@
+2008-07-11 Ulrich Drepper <drepper@redhat.com>
+
+ * locales/iso14651_t1_common: Add Kannada collation support.
+ Patch by Pravin Satpute <psatpute@redhat.com>.
+
+2008-07-08 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6713]
+ * charmaps/UTF-8: Fix U1DBA entry representation.
+ Patch by Colin Watson.
+
+2008-06-27 Ulrich Drepper <drepper@redhat.com>
+
+ * tst-strptime.c (do_test): Add test of %EY.
+
+2008-06-25 Ulrich Drepper <drepper@redhat.com>
+
+ * tst-strptime.c (do_test): Add test for parsing era year
+ representation.
+
+ [BZ #5911]
+ * locales/es_CR: Define first_weekday and first_workday.
+
+ [BZ #5814]
+ * locales/fi_FI: Fix separator for hours, minutes, and seconds.
+
+2008-06-24 Ulrich Drepper <drepper@redhat.com>
+
+ * locales/iso14651_t1_common: Add support for Gurumukhi script.
+ Patch by Pravin Satpute <psatpute@redhat.com>.
+
+2008-05-21 Ulrich Drepper <drepper@redhat.com>
+
+ * locales/iso14651_t1_common: Remove U0C0D entry added for Telugu.
+ Reported by Pravin Satpute.
+
+2008-05-16 Ulrich Drepper <drepper@redhat.com>
+
+ * locales/iso14651_t1_common: Remove duplicate U0C7B definition.
+
+2008-05-14 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6438]
+ * locales/iso14651_t1_common: Add sorting data for Telugu.
+
+ [BZ #6447]
+ * locales/be_BY: Fix yesexpr.
+ Patch by Alexander Mikhailian <mikhailian@altern.org>.
+
+2008-04-15 Ulrich Drepper <drepper@redhat.com>
+
+ * charmaps/UTF-8: Update for Unicode v5.1.
+ * locales/i18n: Update for Unicode 5.
+
+2008-04-09 Ulrich Drepper <drepper@redhat.com>
+
+ * tst-langinfo.sh: Adjust for latest fr_FR locale changes.
+
+2008-04-07 Ulrich Drepper <drepper@redhat.com>
+
+ [BZ #6021]
+ * locales/es_ES: Fix p_cs_precedes and n_cs_precedes.
+ Use common collation definition.
+
+ [BZ #6040]
+ * locales/fr_FR: Fix abmon, abday, d_ftm, grouping.
+
+ [BZ #6004]
+ * locales/iso14651_t1_common: Fix first weight for U+1E60, U+1E62,
+ U+1E64, U+1E66, and U+1E68.
+ Patch by Jesse Thilo <unixweenie@gmail.com>.
+
+ [BZ #5478]
+ * locales/hu_HU: Fix name_fmt.
+
2008-03-31 Ulrich Drepper <drepper@redhat.com>
* locales/iso14651_t1_common: Add support for Gujarati script.
diff --git a/libc/localedata/Makefile b/libc/localedata/Makefile
index 7a61604f6..480057163 100644
--- a/libc/localedata/Makefile
+++ b/libc/localedata/Makefile
@@ -145,7 +145,7 @@ CFLAGS-tst-trans.c = -Wno-format
# eglibc: ifeq (no,$(cross-compiling))
# We have to generate locales
LOCALES := de_DE.ISO-8859-1 de_DE.UTF-8 en_US.ANSI_X3.4-1968 \
- en_US.ISO-8859-1 ja_JP.EUC-JP da_DK.ISO-8859-1 \
+ en_US.ISO-8859-1 en_US.UTF-8 ja_JP.EUC-JP da_DK.ISO-8859-1 \
hr_HR.ISO-8859-2 sv_SE.ISO-8859-1 ja_JP.SJIS fr_FR.ISO-8859-1 \
vi_VN.TCVN5712-1 nb_NO.ISO-8859-1 nn_NO.ISO-8859-1 \
tr_TR.UTF-8 cs_CZ.UTF-8 zh_TW.EUC-TW fa_IR.UTF-8 fr_FR.UTF-8 \
diff --git a/libc/localedata/charmaps/UTF-8 b/libc/localedata/charmaps/UTF-8
index 4ace37697..34b2f7ee8 100644
--- a/libc/localedata/charmaps/UTF-8
+++ b/libc/localedata/charmaps/UTF-8
@@ -899,7 +899,6 @@ CHARMAP
<U037C> /xcd/xbc GREEK SMALL DOTTED LUNATE SIGMA SYMBOL
<U037D> /xcd/xbd GREEK SMALL REVERSED DOTTED LUNATE SIGMA SYMBOL
<U037E> /xcd/xbe GREEK QUESTION MARK
-<U037F> /xcd/xbf GREEK CAPITAL KAI SYMBOL
<U0384> /xce/x84 GREEK TONOS
<U0385> /xce/x85 GREEK DIALYTIKA TONOS
<U0386> /xce/x86 GREEK CAPITAL LETTER ALPHA WITH TONOS
@@ -972,6 +971,7 @@ CHARMAP
<U03CC> /xcf/x8c GREEK SMALL LETTER OMICRON WITH TONOS
<U03CD> /xcf/x8d GREEK SMALL LETTER UPSILON WITH TONOS
<U03CE> /xcf/x8e GREEK SMALL LETTER OMEGA WITH TONOS
+<U03CF> /xcf/x8f GREEK CAPITAL KAI SYMBOL
<U03D0> /xcf/x90 GREEK BETA SYMBOL
<U03D1> /xcf/x91 GREEK THETA SYMBOL
<U03D2> /xcf/x92 GREEK UPSILON WITH HOOK SYMBOL
@@ -5961,7 +5961,7 @@ CHARMAP
<U1DB7> /xe1/xb6/xb7 MODIFIER LETTER SMALL UPSILON
<U1DB8> /xe1/xb6/xb8 MODIFIER LETTER SMALL CAPITAL U
<U1DB9> /xe1/xb6/xb9 MODIFIER LETTER SMALL V WITH HOOK
-<U1DBA> /xe1/xb6/xbe MODIFIER LETTER SMALL TURNED V
+<U1DBA> /xe1/xb6/xba MODIFIER LETTER SMALL TURNED V
<U1DBB> /xe1/xb6/xbb MODIFIER LETTER SMALL Z
<U1DBC> /xe1/xb6/xbc MODIFIER LETTER SMALL Z WITH RETROFLEX HOOK
<U1DBD> /xe1/xb6/xbd MODIFIER LETTER SMALL Z WITH CURL
@@ -9443,71 +9443,71 @@ CHARMAP
<U2D23> /xe2/xb4/xa3 GEORGIAN SMALL LETTER WE
<U2D24> /xe2/xb4/xa4 GEORGIAN SMALL LETTER HAR
<U2D25> /xe2/xb4/xa5 GEORGIAN SMALL LETTER HOE
-<U2D30> /xe2/xb4/xb0 TIFINAGH YA
-<U2D31> /xe2/xb4/xb1 LETTRE TIFINAGHE YAB
-<U2D32> /xe2/xb4/xb2 LETTRE TIFINAGHE YAB SPIRANT
-<U2D33> /xe2/xb4/xb3 LETTRE TIFINAGHE YAG
-<U2D34> /xe2/xb4/xb4 LETTRE TIFINAGHE YAG SPIRANT
-<U2D35> /xe2/xb4/xb5 LETTRE TIFINAGHE YADJ KABYLE
-<U2D36> /xe2/xb4/xb6 LETTRE TIFINAGHE YADJ
-<U2D37> /xe2/xb4/xb7 LETTRE TIFINAGHE YAD
-<U2D38> /xe2/xb4/xb8 LETTRE TIFINAGHE YAD SPIRANT (yadh)
-<U2D39> /xe2/xb4/xb9 LETTRE TIFINAGHE YADD
-<U2D3A> /xe2/xb4/xba LETTRE TIFINAGHE YADD SPIRANT
-<U2D3B> /xe2/xb4/xbb LETTRE TIFINAGHE YEY
-<U2D3C> /xe2/xb4/xbc LETTRE TIFINAGHE YAF
-<U2D3D> /xe2/xb4/xbd LETTRE TIFINAGHE YAK
-<U2D3E> /xe2/xb4/xbe LETTRE TIFINAGHE YAK TOUAREG
-<U2D3F> /xe2/xb4/xbf LETTRE TIFINAGHE YAK SPIRANT
-<U2D40> /xe2/xb5/x80 LETTRE TIFINAGHE YAH (yab touareg)
-<U2D41> /xe2/xb5/x81 LETTRE TIFINAGHE YAH KABYLE
-<U2D42> /xe2/xb5/x82 LETTRE TIFINAGHE YAH TOUAREG
-<U2D43> /xe2/xb5/x83 LETTRE TIFINAGHE YAHH
-<U2D44> /xe2/xb5/x84 LETTRE TIFINAGHE YA’
-<U2D45> /xe2/xb5/x85 LETTRE TIFINAGHE YAKH
-<U2D46> /xe2/xb5/x86 LETTRE TIFINAGHE YAKH TOUAREG (quatre-points en carré touareg)
-<U2D47> /xe2/xb5/x87 LETTRE TIFINAGHE YAQ
-<U2D48> /xe2/xb5/x88 LETTRE TIFINAGHE YAQ TOUAREG
-<U2D49> /xe2/xb5/x89 LETTRE TIFINAGHE YI
-<U2D4A> /xe2/xb5/x8a LETTRE TIFINAGHE YAJ
-<U2D4B> /xe2/xb5/x8b LETTRE TIFINAGHE YAJ DE L’AHAGGAR
-<U2D4C> /xe2/xb5/x8c LETTRE TIFINAGHE YAJ TOUAREG
-<U2D4D> /xe2/xb5/x8d LETTRE TIFINAGHE YAL
-<U2D4E> /xe2/xb5/x8e LETTRE TIFINAGHE YAM
-<U2D4F> /xe2/xb5/x8f LETTRE TIFINAGHE YAN
-<U2D50> /xe2/xb5/x90 LETTRE TIFINAGHE YAGN TOUAREG
-<U2D51> /xe2/xb5/x91 LETTRE TIFINAGHE YANG TOUAREG
-<U2D52> /xe2/xb5/x92 LETTRE TIFINAGHE YAP
-<U2D53> /xe2/xb5/x93 LETTRE TIFINAGHE YOU (yaw touareg)
-<U2D54> /xe2/xb5/x94 LETTRE TIFINAGHE YAR
-<U2D55> /xe2/xb5/x95 LETTRE TIFINAGHE YARR
-<U2D56> /xe2/xb5/x96 LETTRE TIFINAGHE YAGH
-<U2D57> /xe2/xb5/x97 LETTRE TIFINAGHE YAGH TOUAREG
-<U2D58> /xe2/xb5/x98 LETTRE TIFINAGHE YAGH DE L’AÃR (yadj de l’Adrar, cinq-points en quinconce touareg)
-<U2D59> /xe2/xb5/x99 LETTRE TIFINAGHE YAS
-<U2D5A> /xe2/xb5/x9a LETTRE TIFINAGHE YASS
-<U2D5B> /xe2/xb5/x9b LETTRE TIFINAGHE YACH
-<U2D5C> /xe2/xb5/x9c LETTRE TIFINAGHE YAT
-<U2D5D> /xe2/xb5/x9d LETTRE TIFINAGHE YAT SPIRANT (yath)
-<U2D5E> /xe2/xb5/x9e LETTRE TIFINAGHE YATCH
-<U2D5F> /xe2/xb5/x9f LETTRE TIFINAGHE YATT
-<U2D60> /xe2/xb5/xa0 LETTRE TIFINAGHE YAV
-<U2D61> /xe2/xb5/xa1 LETTRE TIFINAGHE YAW
-<U2D62> /xe2/xb5/xa2 LETTRE TIFINAGHE YAY
-<U2D63> /xe2/xb5/xa3 LETTRE TIFINAGHE YAZ
-<U2D64> /xe2/xb5/xa4 LETTRE TIFINAGHE YAZ TAWELLEMET (yaz harpon)
-<U2D65> /xe2/xb5/xa5 LETTRE TIFINAGHE YAZZ
-<U2D6F> /xe2/xb5/xaf LETTRE MODIFICATIVE TIFINAGHE DE LABIO-VÉLARISATION (tamatart)
-<U2D80> /xe2/xb6/x80 ETHIOPIC SYLLALE LOA
-<U2D81> /xe2/xb6/x81 ETHIOPIC SYLLALE MOA
-<U2D82> /xe2/xb6/x82 ETHIOPIC SYLLALE ROA
-<U2D83> /xe2/xb6/x83 ETHIOPIC SYLLALE SOA
-<U2D84> /xe2/xb6/x84 ETHIOPIC SYLLALE SHOA
-<U2D85> /xe2/xb6/x85 ETHIOPIC SYLLALE BOA
-<U2D86> /xe2/xb6/x86 ETHIOPIC SYLLALE TOA
-<U2D87> /xe2/xb6/x87 ETHIOPIC SYLLALE COA
-<U2D88> /xe2/xb6/x88 ETHIOPIC SYLLALE NOA
-<U2D89> /xe2/xb6/x89 ETHIOPIC SYLLALE NYOA
+<U2D30> /xe2/xb4/xb0 TIFINAGH LETTER YA
+<U2D31> /xe2/xb4/xb1 TIFINAGH LETTER YAB
+<U2D32> /xe2/xb4/xb2 TIFINAGH LETTER YABH
+<U2D33> /xe2/xb4/xb3 TIFINAGH LETTER YAG
+<U2D34> /xe2/xb4/xb4 TIFINAGH LETTER YAGHH
+<U2D35> /xe2/xb4/xb5 TIFINAGH LETTER BERBER ACADEMY YAJ
+<U2D36> /xe2/xb4/xb6 TIFINAGH LETTER YAJ
+<U2D37> /xe2/xb4/xb7 TIFINAGH LETTER YAD
+<U2D38> /xe2/xb4/xb8 TIFINAGH LETTER YADH
+<U2D39> /xe2/xb4/xb9 TIFINAGH LETTER YADD
+<U2D3A> /xe2/xb4/xba TIFINAGH LETTER YADDH
+<U2D3B> /xe2/xb4/xbb TIFINAGH LETTER YEY
+<U2D3C> /xe2/xb4/xbc TIFINAGH LETTER YAF
+<U2D3D> /xe2/xb4/xbd TIFINAGH LETTER YAK
+<U2D3E> /xe2/xb4/xbe TIFINAGH LETTER TUAREG YAK
+<U2D3F> /xe2/xb4/xbf TIFINAGH LETTER YAKHH
+<U2D40> /xe2/xb5/x80 TIFINAGH LETTER YAH
+<U2D41> /xe2/xb5/x81 TIFINAGH LETTER BERBER ACADEMY YAH
+<U2D42> /xe2/xb5/x82 TIFINAGH LETTER TUAREG YAH
+<U2D43> /xe2/xb5/x83 TIFINAGH LETTER YAHH
+<U2D44> /xe2/xb5/x84 TIFINAGH LETTER YAA
+<U2D45> /xe2/xb5/x85 TIFINAGH LETTER YAKH
+<U2D46> /xe2/xb5/x86 TIFINAGH LETTER TUAREG YAKH
+<U2D47> /xe2/xb5/x87 TIFINAGH LETTER YAQ
+<U2D48> /xe2/xb5/x88 TIFINAGH LETTER TUAREG YAQ
+<U2D49> /xe2/xb5/x89 TIFINAGH LETTER YI
+<U2D4A> /xe2/xb5/x8a TIFINAGH LETTER YAZH
+<U2D4B> /xe2/xb5/x8b TIFINAGH LETTER AHAGGAR YAZH
+<U2D4C> /xe2/xb5/x8c TIFINAGH LETTER TUAREG YAZH
+<U2D4D> /xe2/xb5/x8d TIFINAGH LETTER YAL
+<U2D4E> /xe2/xb5/x8e TIFINAGH LETTER YAM
+<U2D4F> /xe2/xb5/x8f TIFINAGH LETTER YAN
+<U2D50> /xe2/xb5/x90 TIFINAGH LETTER TUAREG YAGN
+<U2D51> /xe2/xb5/x91 TIFINAGH LETTER TUAREG YANG
+<U2D52> /xe2/xb5/x92 TIFINAGH LETTER YAP
+<U2D53> /xe2/xb5/x93 TIFINAGH LETTER YU
+<U2D54> /xe2/xb5/x94 TIFINAGH LETTER YAR
+<U2D55> /xe2/xb5/x95 TIFINAGH LETTER YARR
+<U2D56> /xe2/xb5/x96 TIFINAGH LETTER YAGH
+<U2D57> /xe2/xb5/x97 TIFINAGH LETTER TUAREG YAGH
+<U2D58> /xe2/xb5/x98 TIFINAGH LETTER AYER YAGH
+<U2D59> /xe2/xb5/x99 TIFINAGH LETTER YAS
+<U2D5A> /xe2/xb5/x9a TIFINAGH LETTER YASS
+<U2D5B> /xe2/xb5/x9b TIFINAGH LETTER YASH
+<U2D5C> /xe2/xb5/x9c TIFINAGH LETTER YAT
+<U2D5D> /xe2/xb5/x9d TIFINAGH LETTER YATH
+<U2D5E> /xe2/xb5/x9e TIFINAGH LETTER YACH
+<U2D5F> /xe2/xb5/x9f TIFINAGH LETTER YATT
+<U2D60> /xe2/xb5/xa0 TIFINAGH LETTER YAV
+<U2D61> /xe2/xb5/xa1 TIFINAGH LETTER YAW
+<U2D62> /xe2/xb5/xa2 TIFINAGH LETTER YAY
+<U2D63> /xe2/xb5/xa3 TIFINAGH LETTER YAZ
+<U2D64> /xe2/xb5/xa4 TIFINAGH LETTER TAWELLEMET YAZ
+<U2D65> /xe2/xb5/xa5 TIFINAGH LETTER YAZZ
+<U2D6F> /xe2/xb5/xaf TIFINAGH MODIFIER LETTER LABIALIZATION MARK
+<U2D80> /xe2/xb6/x80 ETHIOPIC SYLLABLE LOA
+<U2D81> /xe2/xb6/x81 ETHIOPIC SYLLABLE MOA
+<U2D82> /xe2/xb6/x82 ETHIOPIC SYLLABLE ROA
+<U2D83> /xe2/xb6/x83 ETHIOPIC SYLLABLE SOA
+<U2D84> /xe2/xb6/x84 ETHIOPIC SYLLABLE SHOA
+<U2D85> /xe2/xb6/x85 ETHIOPIC SYLLABLE BOA
+<U2D86> /xe2/xb6/x86 ETHIOPIC SYLLABLE TOA
+<U2D87> /xe2/xb6/x87 ETHIOPIC SYLLABLE COA
+<U2D88> /xe2/xb6/x88 ETHIOPIC SYLLABLE NOA
+<U2D89> /xe2/xb6/x89 ETHIOPIC SYLLABLE NYOA
<U2D8A> /xe2/xb6/x8a ETHIOPIC SYLLABLE GLOTTAL OA
<U2D8B> /xe2/xb6/x8b ETHIOPIC SYLLABLE ZOA
<U2D8C> /xe2/xb6/x8c ETHIOPIC SYLLABLE DOA
@@ -26425,7 +26425,6 @@ CHARMAP
<UFFFC> /xef/xbf/xbc OBJECT REPLACEMENT CHARACTER
<UFFFD> /xef/xbf/xbd REPLACEMENT CHARACTER
<U00010000> /xf0/x90/x80/x80 LINEAR B SYLLABLE B008 A
-<U00010000> /xf0/x90/x80/x80 LINEAR B SYLLABLE B008 A
<U00010001> /xf0/x90/x80/x81 LINEAR B SYLLABLE B038 E
<U00010002> /xf0/x90/x80/x82 LINEAR B SYLLABLE B028 I
<U00010003> /xf0/x90/x80/x83 LINEAR B SYLLABLE B061 O
diff --git a/libc/localedata/locales/be_BY b/libc/localedata/locales/be_BY
index 3111a6a62..0e02ac4de 100644
--- a/libc/localedata/locales/be_BY
+++ b/libc/localedata/locales/be_BY
@@ -69,7 +69,7 @@ translit_end
END LC_CTYPE
LC_MESSAGES
-yesexpr "<U005E><U005B><U0414><U0434><U0059><U0079><U005D><U002E><U002A>"
+yesexpr "<U005E><U005B><U0422><U0442><U0059><U0079><U005D><U002E><U002A>"
noexpr "<U005E><U005B><U041D><U043D><U004E><U006E><U005D><U002E><U002A>"
END LC_MESSAGES
diff --git a/libc/localedata/locales/es_CR b/libc/localedata/locales/es_CR
index 753b22b05..d582a20d9 100644
--- a/libc/localedata/locales/es_CR
+++ b/libc/localedata/locales/es_CR
@@ -113,6 +113,8 @@ t_fmt_ampm "<U0025><U0049><U003A><U0025><U004D><U003A><U0025><U0053><U0020><U002
date_fmt "<U0025><U0061><U0020><U0025><U0062><U0020><U0025><U0065>/
<U0020><U0025><U0048><U003A><U0025><U004D><U003A><U0025><U0053><U0020>/
<U0025><U005A><U0020><U0025><U0059>"
+first_weekday 1
+first_workday 2
END LC_TIME
LC_PAPER
diff --git a/libc/localedata/locales/es_ES b/libc/localedata/locales/es_ES
index feefeec78..01e13dfc7 100644
--- a/libc/localedata/locales/es_ES
+++ b/libc/localedata/locales/es_ES
@@ -48,2068 +48,8 @@ category "es_ES:2000";LC_TELEPHONE
END LC_IDENTIFICATION
LC_COLLATE
-
-% Base collation scheme: 1994-03-22
-
-% Ordering algorithm:
-% 1. Spaces and hyphen (but not soft
-% hyphen) before punctuation
-% characters, punctuation characters
-% before numbers,
-% numbers before letters.
-% 2. Letters with diacritical marks are
-% members of equivalence classes
-% 3. A distinction is made with regards
-% to case as noted below.
-% 4. Special characters are ignored
-% when comparing letters, but then
-% they are considered
-% 5. The alphabets are sorted in order
-% of first appearance in ISO 10646:
-% Latin, Greek, Cyrillic, etc.
-%
-% According to Greek specifications,
-% the steps 2. and 3. above are reversed
-% for the Greek script
-
-% collating symbols
-
-% The collating symbol naming is
-% mostly taken from ISO 10646-1,
-% for example the case and accent
-% names are from this standard.
-
-collating-symbol <CAPITAL>
-collating-symbol <CAPITAL-SMALL>
-collating-symbol <SMALL-CAPITAL>
-collating-symbol <SMALL>
-
-% <CAPITAL-SMALL> and <SMALL-CAPITAL>
-% are for cases like Danish <U0041><U0061>
-% and Spanish <U0043><U0068> being treated
-% as one letter.
-
-% The <a8> ...... <z8> collating
-% symbols have defined weights as
-% the last character in a group of
-% Latin letters. They are used
-% to specify deltas by locales using
-% a locale as the default ordering
-% and by "replace-after" statements
-% specifying the changed placement
-% in an ordering of a character.
-
-collating-symbol <a8>
-collating-symbol <b8>
-collating-symbol <c8>
-collating-symbol <d8>
-collating-symbol <e8>
-collating-symbol <f8>
-collating-symbol <g8>
-collating-symbol <h8>
-collating-symbol <i8>
-collating-symbol <j8>
-collating-symbol <k8>
-collating-symbol <l8>
-collating-symbol <m8>
-collating-symbol <n8>
-collating-symbol <o8>
-collating-symbol <p8>
-collating-symbol <q8>
-collating-symbol <r8>
-collating-symbol <s8>
-collating-symbol <t8>
-collating-symbol <u8>
-collating-symbol <v8>
-collating-symbol <w8>
-collating-symbol <x8>
-collating-symbol <y8>
-collating-symbol <z8>
-
-collating-symbol <NONE>
-collating-symbol <ACUTE>
-collating-symbol <ACUTE+DOT>
-collating-symbol <GRAVE>
-collating-symbol <DOUBLE-GRAVE>
-collating-symbol <BREVE>
-collating-symbol <BREVE+ACUTE>
-collating-symbol <BREVE+GRAVE>
-collating-symbol <BREVE+MACRON>
-collating-symbol <BREVE+HOOK>
-collating-symbol <BREVE+TILDE>
-collating-symbol <BREVE+DOT-BELOW>
-collating-symbol <BREVE-BELOW>
-collating-symbol <INVERTED-BREVE>
-collating-symbol <CIRCUMFLEX>
-collating-symbol <CIRCUMFLEX+ACUTE>
-collating-symbol <CIRCUMFLEX+GRAVE>
-collating-symbol <CIRCUMFLEX+HOOK>
-collating-symbol <CIRCUMFLEX+TILDE>
-collating-symbol <CIRCUMFLEX+DOT-BELOW>
-collating-symbol <CARON>
-collating-symbol <CARON+DIAERESIS>
-collating-symbol <CARON+DOT>
-collating-symbol <RING>
-collating-symbol <RING+ACUTE>
-collating-symbol <RING-BELOW>
-collating-symbol <DIAERESIS>
-collating-symbol <DIAERESIS+MACRON>
-collating-symbol <DIAERESIS+ACUTE>
-collating-symbol <DIAERESIS+GRAVE>
-collating-symbol <DIAERESIS+CARON>
-collating-symbol <DOUBLE-ACUTE>
-collating-symbol <HOOK>
-collating-symbol <TILDE>
-collating-symbol <TILDE+ACUTE>
-collating-symbol <TILDE+DIAERESIS>
-collating-symbol <TILDE-BELOW>
-collating-symbol <DOT>
-collating-symbol <DOT-BELOW>
-collating-symbol <DOT+DOT-BELOW>
-collating-symbol <STROKE>
-collating-symbol <STROKE+ACUTE>
-collating-symbol <CEDILLA>
-collating-symbol <CEDILLA+ACUTE>
-collating-symbol <CEDILLA+GRAVE>
-collating-symbol <CEDILLA+BREVE>
-collating-symbol <OGONEK>
-collating-symbol <OGONEK+MACRON>
-collating-symbol <MACRON>
-collating-symbol <MACRON+ACUTE>
-collating-symbol <MACRON+GRAVE>
-collating-symbol <MACRON+DIAERESIS>
-collating-symbol <MACRON+DIAERESIS-BELOW>
-collating-symbol <MACRON+DOT>
-collating-symbol <MACRON+DOT-BELOW>
-collating-symbol <MACRON+CIRCUMFLEX>
-collating-symbol <LINE-BELOW>
-collating-symbol <HORN>
-collating-symbol <HORN+ACUTE>
-collating-symbol <HORN+GRAVE>
-collating-symbol <HORN+HOOK>
-collating-symbol <HORN+TILDE>
-collating-symbol <HORN+DOT-BELOW>
-collating-symbol <PRECEDED-BY-APOSTROPHE>
-collating-symbol <GREEK>
-collating-symbol <TONOS>
-collating-symbol <DIALYTICA>
-collating-symbol <DIALYTICA+TONOS>
-collating-symbol <CYRILLIC>
-collating-symbol <HIRAGANA>
-collating-symbol <KATAKANA>
-collating-symbol <SPECIAL>
-
-% letter;accent;case;specials
-
-order_start forward;backward/
- ;forward;position
-
-% <CAPITAL> or <SMALL> letters first:
-
-<SMALL>
-<SMALL-CAPITAL>
-<CAPITAL-SMALL>
-<CAPITAL>
-
-% Accents:
-
-<NONE>
-<ACUTE>
-<ACUTE+DOT>
-<GRAVE>
-<DOUBLE-GRAVE>
-<BREVE>
-<BREVE+ACUTE>
-<BREVE+GRAVE>
-<BREVE+MACRON>
-<BREVE+HOOK>
-<BREVE+TILDE>
-<BREVE+DOT-BELOW>
-<BREVE-BELOW>
-<INVERTED-BREVE>
-<CIRCUMFLEX>
-<CIRCUMFLEX+ACUTE>
-<CIRCUMFLEX+GRAVE>
-<CIRCUMFLEX+HOOK>
-<CIRCUMFLEX+TILDE>
-<CIRCUMFLEX+DOT-BELOW>
-<CARON>
-<CARON+DIAERESIS>
-<CARON+DOT>
-<RING>
-<RING+ACUTE>
-<RING-BELOW>
-<DIAERESIS>
-<DIAERESIS+MACRON>
-<DIAERESIS+ACUTE>
-<DIAERESIS+GRAVE>
-<DIAERESIS+CARON>
-<DOUBLE-ACUTE>
-<HOOK>
-<TILDE>
-<TILDE+ACUTE>
-<TILDE+DIAERESIS>
-<TILDE-BELOW>
-<DOT>
-<DOT-BELOW>
-<DOT+DOT-BELOW>
-<STROKE>
-<STROKE+ACUTE>
-<CEDILLA>
-<CEDILLA+ACUTE>
-<CEDILLA+GRAVE>
-<CEDILLA+BREVE>
-<OGONEK>
-<OGONEK+MACRON>
-<MACRON>
-<MACRON+ACUTE>
-<MACRON+GRAVE>
-<MACRON+DIAERESIS>
-<MACRON+DIAERESIS-BELOW>
-<MACRON+DOT>
-<MACRON+DOT-BELOW>
-<MACRON+CIRCUMFLEX>
-<LINE-BELOW>
-<HORN>
-<HORN+ACUTE>
-<HORN+GRAVE>
-<HORN+HOOK>
-<HORN+TILDE>
-<HORN+DOT-BELOW>
-<PRECEDED-BY-APOSTROPHE>
-<GREEK>
-<TONOS>
-<DIALYTICA>
-<DIALYTICA+TONOS>
-<CYRILLIC>
-<HIRAGANA>
-<KATAKANA>
-<SPECIAL>
-
-<U00A0> <U00A0>;<U00A0>;<U00A0>;IGNORE
-<U0020> IGNORE;IGNORE;IGNORE;<U0020>
-<U0009> IGNORE;IGNORE;IGNORE;<U0009>
-<U000B> IGNORE;IGNORE;IGNORE;<U000B>
-<U000D> IGNORE;IGNORE;IGNORE;<U000D>
-<U000A> IGNORE;IGNORE;IGNORE;<U000A>
-<U000C> IGNORE;IGNORE;IGNORE;<U000C>
-<U005F> IGNORE;IGNORE;IGNORE;<U005F>
-<U00AF> IGNORE;IGNORE;IGNORE;<U00AF>
-<U00AD> IGNORE;IGNORE;IGNORE;<U00AD>
-<U002D> IGNORE;IGNORE;IGNORE;<U002D>
-<U002C> IGNORE;IGNORE;IGNORE;<U002C>
-<U003B> IGNORE;IGNORE;IGNORE;<U003B>
-<U003A> IGNORE;IGNORE;IGNORE;<U003A>
-<U0021> IGNORE;IGNORE;IGNORE;<U0021>
-<U00A1> IGNORE;IGNORE;IGNORE;<U00A1>
-<U003F> IGNORE;IGNORE;IGNORE;<U003F>
-<U00BF> IGNORE;IGNORE;IGNORE;<U00BF>
-<U002F> IGNORE;IGNORE;IGNORE;<U002F>
-<U002E> IGNORE;IGNORE;IGNORE;<U002E>
-<U00B4> IGNORE;IGNORE;IGNORE;<U00B4>
-<U0060> IGNORE;IGNORE;IGNORE;<U0060>
-<U005E> IGNORE;IGNORE;IGNORE;<U005E>
-<U00A8> IGNORE;IGNORE;IGNORE;<U00A8>
-<U007E> IGNORE;IGNORE;IGNORE;<U007E>
-<U00B7> IGNORE;IGNORE;IGNORE;<U00B7>
-<U00B8> IGNORE;IGNORE;IGNORE;<U00B8>
-<U0027> IGNORE;IGNORE;IGNORE;<U0027>
-<U2018> IGNORE;IGNORE;IGNORE;<U2018>
-<U2019> IGNORE;IGNORE;IGNORE;<U2019>
-<U0022> IGNORE;IGNORE;IGNORE;<U0022>
-<U201C> IGNORE;IGNORE;IGNORE;<U201C>
-<U201D> IGNORE;IGNORE;IGNORE;<U201D>
-<U00AB> IGNORE;IGNORE;IGNORE;<U00AB>
-<U00BB> IGNORE;IGNORE;IGNORE;<U00BB>
-<U0028> IGNORE;IGNORE;IGNORE;<U0028>
-<U207D> IGNORE;IGNORE;IGNORE;<U207D>
-<U0029> IGNORE;IGNORE;IGNORE;<U0029>
-<U207E> IGNORE;IGNORE;IGNORE;<U207E>
-<U005B> IGNORE;IGNORE;IGNORE;<U005B>
-<U005D> IGNORE;IGNORE;IGNORE;<U005D>
-<U007B> IGNORE;IGNORE;IGNORE;<U007B>
-<U007D> IGNORE;IGNORE;IGNORE;<U007D>
-<U00A7> IGNORE;IGNORE;IGNORE;<U00A7>
-<U00B6> IGNORE;IGNORE;IGNORE;<U00B6>
-<U00A9> IGNORE;IGNORE;IGNORE;<U00A9>
-<U00AE> IGNORE;IGNORE;IGNORE;<U00AE>
-<U0040> IGNORE;IGNORE;IGNORE;<U0040>
-<U00A4> IGNORE;IGNORE;IGNORE;<U00A4>
-<U00A2> IGNORE;IGNORE;IGNORE;<U00A2>
-<U0024> IGNORE;IGNORE;IGNORE;<U0024>
-<U00A3> IGNORE;IGNORE;IGNORE;<U00A3>
-<U00A5> IGNORE;IGNORE;IGNORE;<U00A5>
-<U002A> IGNORE;IGNORE;IGNORE;<U002A>
-<U005C> IGNORE;IGNORE;IGNORE;<U005C>
-<U0026> IGNORE;IGNORE;IGNORE;<U0026>
-<U0023> IGNORE;IGNORE;IGNORE;<U0023>
-<U0025> IGNORE;IGNORE;IGNORE;<U0025>
-<U207B> IGNORE;IGNORE;IGNORE;<U207B>
-<U002B> IGNORE;IGNORE;IGNORE;<U002B>
-<U207A> IGNORE;IGNORE;IGNORE;<U207A>
-<U00B1> IGNORE;IGNORE;IGNORE;<U00B1>
-<U00F7> IGNORE;IGNORE;IGNORE;<U00F7>
-<U00D7> IGNORE;IGNORE;IGNORE;<U00D7>
-<U2260> IGNORE;IGNORE;IGNORE;<U2260>
-<U003C> IGNORE;IGNORE;IGNORE;<U003C>
-<U2264> IGNORE;IGNORE;IGNORE;<U2264>
-<U003D> IGNORE;IGNORE;IGNORE;<U003D>
-<U2265> IGNORE;IGNORE;IGNORE;<U2265>
-<U003E> IGNORE;IGNORE;IGNORE;<U003E>
-<U00AC> IGNORE;IGNORE;IGNORE;<U00AC>
-<U007C> IGNORE;IGNORE;IGNORE;<U007C>
-<U00A6> IGNORE;IGNORE;IGNORE;<U00A6>
-<U00B0> IGNORE;IGNORE;IGNORE;<U00B0>
-<U00B5> IGNORE;IGNORE;IGNORE;<U00B5>
-<U02C7> IGNORE;IGNORE;IGNORE;<U02C7>
-<U02D8> IGNORE;IGNORE;IGNORE;<U02D8>
-<U02D9> IGNORE;IGNORE;IGNORE;<U02D9>
-<U02DA> IGNORE;IGNORE;IGNORE;<U02DA>
-<U02DB> IGNORE;IGNORE;IGNORE;<U02DB>
-<U02DC> IGNORE;IGNORE;IGNORE;<U02DC>
-<U02DD> IGNORE;IGNORE;IGNORE;<U02DD>
-<U0374> IGNORE;IGNORE;IGNORE;<U0374>
-<U0375> IGNORE;IGNORE;IGNORE;<U0375>
-<U037A> IGNORE;IGNORE;IGNORE;<U037A>
-<U037E> IGNORE;IGNORE;IGNORE;<U037E>
-<U0384> IGNORE;IGNORE;IGNORE;<U0384>
-<U0385> IGNORE;IGNORE;IGNORE;<U0385>
-<U0387> IGNORE;IGNORE;IGNORE;<U0387>
-<U03D0> IGNORE;IGNORE;IGNORE;<U03D0>
-<U1FBF> IGNORE;IGNORE;IGNORE;<U1FBF>
-<U1FC0> IGNORE;IGNORE;IGNORE;<U1FC0>
-<U1FC1> IGNORE;IGNORE;IGNORE;<U1FC1>
-<U1FCD> IGNORE;IGNORE;IGNORE;<U1FCD>
-<U1FCE> IGNORE;IGNORE;IGNORE;<U1FCE>
-<U1FCF> IGNORE;IGNORE;IGNORE;<U1FCF>
-<U1FDD> IGNORE;IGNORE;IGNORE;<U1FDD>
-<U1FDE> IGNORE;IGNORE;IGNORE;<U1FDE>
-<U1FDF> IGNORE;IGNORE;IGNORE;<U1FDF>
-<U1FED> IGNORE;IGNORE;IGNORE;<U1FED>
-<U1FEF> IGNORE;IGNORE;IGNORE;<U1FEF>
-<U1FFE> IGNORE;IGNORE;IGNORE;<U1FFE>
-<U2002> IGNORE;IGNORE;IGNORE;<U2002>
-<U2003> IGNORE;IGNORE;IGNORE;<U2003>
-<U2004> IGNORE;IGNORE;IGNORE;<U2004>
-<U2005> IGNORE;IGNORE;IGNORE;<U2005>
-<U2006> IGNORE;IGNORE;IGNORE;<U2006>
-<U200E> IGNORE;IGNORE;IGNORE;<U200E>
-<U200F> IGNORE;IGNORE;IGNORE;<U200F>
-<U2009> IGNORE;IGNORE;IGNORE;<U2009>
-<U200A> IGNORE;IGNORE;IGNORE;<U200A>
-<U2010> IGNORE;IGNORE;IGNORE;<U2010>
-<U2013> IGNORE;IGNORE;IGNORE;<U2013>
-<U2014> IGNORE;IGNORE;IGNORE;<U2014>
-<U2015> IGNORE;IGNORE;IGNORE;<U2015>
-<U2016> IGNORE;IGNORE;IGNORE;<U2016>
-<U2017> IGNORE;IGNORE;IGNORE;<U2017>
-<U201A> IGNORE;IGNORE;IGNORE;<U201A>
-<U201B> IGNORE;IGNORE;IGNORE;<U201B>
-<U201E> IGNORE;IGNORE;IGNORE;<U201E>
-<U201F> IGNORE;IGNORE;IGNORE;<U201F>
-<U2020> IGNORE;IGNORE;IGNORE;<U2020>
-<U2021> IGNORE;IGNORE;IGNORE;<U2021>
-<U2219> IGNORE;IGNORE;IGNORE;<U2219>
-<U2025> IGNORE;IGNORE;IGNORE;<U2025>
-<U2026> IGNORE;IGNORE;IGNORE;<U2026>
-<U2030> IGNORE;IGNORE;IGNORE;<U2030>
-<U2032> IGNORE;IGNORE;IGNORE;<U2032>
-<U2033> IGNORE;IGNORE;IGNORE;<U2033>
-<U2034> IGNORE;IGNORE;IGNORE;<U2034>
-<U2035> IGNORE;IGNORE;IGNORE;<U2035>
-<U2036> IGNORE;IGNORE;IGNORE;<U2036>
-<U2037> IGNORE;IGNORE;IGNORE;<U2037>
-<U2038> IGNORE;IGNORE;IGNORE;<U2038>
-<U2039> IGNORE;IGNORE;IGNORE;<U2039>
-<U203A> IGNORE;IGNORE;IGNORE;<U203A>
-<U203B> IGNORE;IGNORE;IGNORE;<U203B>
-<U203C> IGNORE;IGNORE;IGNORE;<U203C>
-<U203E> IGNORE;IGNORE;IGNORE;<U203E>
-<U207C> IGNORE;IGNORE;IGNORE;<U207C>
-<U2080> IGNORE;IGNORE;IGNORE;<U2080>
-<U2081> IGNORE;IGNORE;IGNORE;<U2081>
-<U2082> IGNORE;IGNORE;IGNORE;<U2082>
-<U2083> IGNORE;IGNORE;IGNORE;<U2083>
-<U2084> IGNORE;IGNORE;IGNORE;<U2084>
-<U2085> IGNORE;IGNORE;IGNORE;<U2085>
-<U2086> IGNORE;IGNORE;IGNORE;<U2086>
-<U2087> IGNORE;IGNORE;IGNORE;<U2087>
-<U2088> IGNORE;IGNORE;IGNORE;<U2088>
-<U2089> IGNORE;IGNORE;IGNORE;<U2089>
-<U208A> IGNORE;IGNORE;IGNORE;<U208A>
-<U208B> IGNORE;IGNORE;IGNORE;<U208B>
-<U208C> IGNORE;IGNORE;IGNORE;<U208C>
-<U208D> IGNORE;IGNORE;IGNORE;<U208D>
-<U208E> IGNORE;IGNORE;IGNORE;<U208E>
-<U20A3> IGNORE;IGNORE;IGNORE;<U20A3>
-<U20A4> IGNORE;IGNORE;IGNORE;<U20A4>
-<U20A7> IGNORE;IGNORE;IGNORE;<U20A7>
-<U20A9> IGNORE;IGNORE;IGNORE;<U20A9>
-<U2103> IGNORE;IGNORE;IGNORE;<U2103>
-<U2105> IGNORE;IGNORE;IGNORE;<U2105>
-<U2109> IGNORE;IGNORE;IGNORE;<U2109>
-<U2116> IGNORE;IGNORE;IGNORE;<U2116>
-<U2117> IGNORE;IGNORE;IGNORE;<U2117>
-<U211E> IGNORE;IGNORE;IGNORE;<U211E>
-<U2120> IGNORE;IGNORE;IGNORE;<U2120>
-<U2122> IGNORE;IGNORE;IGNORE;<U2122>
-<U2126> IGNORE;IGNORE;IGNORE;<U2126>
-<U212B> IGNORE;IGNORE;IGNORE;<U212B>
-<U2153> IGNORE;IGNORE;IGNORE;<U2153>
-<U2154> IGNORE;IGNORE;IGNORE;<U2154>
-<U2155> IGNORE;IGNORE;IGNORE;<U2155>
-<U2156> IGNORE;IGNORE;IGNORE;<U2156>
-<U2157> IGNORE;IGNORE;IGNORE;<U2157>
-<U2158> IGNORE;IGNORE;IGNORE;<U2158>
-<U2159> IGNORE;IGNORE;IGNORE;<U2159>
-<U215A> IGNORE;IGNORE;IGNORE;<U215A>
-<U2160> IGNORE;IGNORE;IGNORE;<U2160>
-<U2161> IGNORE;IGNORE;IGNORE;<U2161>
-<U2162> IGNORE;IGNORE;IGNORE;<U2162>
-<U2163> IGNORE;IGNORE;IGNORE;<U2163>
-<U2164> IGNORE;IGNORE;IGNORE;<U2164>
-<U2165> IGNORE;IGNORE;IGNORE;<U2165>
-<U2166> IGNORE;IGNORE;IGNORE;<U2166>
-<U2167> IGNORE;IGNORE;IGNORE;<U2167>
-<U2168> IGNORE;IGNORE;IGNORE;<U2168>
-<U2169> IGNORE;IGNORE;IGNORE;<U2169>
-<U216A> IGNORE;IGNORE;IGNORE;<U216A>
-<U216B> IGNORE;IGNORE;IGNORE;<U216B>
-<U216C> IGNORE;IGNORE;IGNORE;<U216C>
-<U216D> IGNORE;IGNORE;IGNORE;<U216D>
-<U216E> IGNORE;IGNORE;IGNORE;<U216E>
-<U216F> IGNORE;IGNORE;IGNORE;<U216F>
-<U2170> IGNORE;IGNORE;IGNORE;<U2170>
-<U2171> IGNORE;IGNORE;IGNORE;<U2171>
-<U2172> IGNORE;IGNORE;IGNORE;<U2172>
-<U2173> IGNORE;IGNORE;IGNORE;<U2173>
-<U2174> IGNORE;IGNORE;IGNORE;<U2174>
-<U2175> IGNORE;IGNORE;IGNORE;<U2175>
-<U2176> IGNORE;IGNORE;IGNORE;<U2176>
-<U2177> IGNORE;IGNORE;IGNORE;<U2177>
-<U2178> IGNORE;IGNORE;IGNORE;<U2178>
-<U2179> IGNORE;IGNORE;IGNORE;<U2179>
-<U217A> IGNORE;IGNORE;IGNORE;<U217A>
-<U217B> IGNORE;IGNORE;IGNORE;<U217B>
-<U217C> IGNORE;IGNORE;IGNORE;<U217C>
-<U217D> IGNORE;IGNORE;IGNORE;<U217D>
-<U217E> IGNORE;IGNORE;IGNORE;<U217E>
-<U217F> IGNORE;IGNORE;IGNORE;<U217F>
-<U2180> IGNORE;IGNORE;IGNORE;<U2180>
-<U2181> IGNORE;IGNORE;IGNORE;<U2181>
-<U2182> IGNORE;IGNORE;IGNORE;<U2182>
-<U2191> IGNORE;IGNORE;IGNORE;<U2191>
-<U2193> IGNORE;IGNORE;IGNORE;<U2193>
-<U2194> IGNORE;IGNORE;IGNORE;<U2194>
-<U2195> IGNORE;IGNORE;IGNORE;<U2195>
-<U2196> IGNORE;IGNORE;IGNORE;<U2196>
-<U2197> IGNORE;IGNORE;IGNORE;<U2197>
-<U2198> IGNORE;IGNORE;IGNORE;<U2198>
-<U2199> IGNORE;IGNORE;IGNORE;<U2199>
-<U21A8> IGNORE;IGNORE;IGNORE;<U21A8>
-<U21C0> IGNORE;IGNORE;IGNORE;<U21C0>
-<U21D0> IGNORE;IGNORE;IGNORE;<U21D0>
-<U21D2> IGNORE;IGNORE;IGNORE;<U21D2>
-<U21D4> IGNORE;IGNORE;IGNORE;<U21D4>
-<U2200> IGNORE;IGNORE;IGNORE;<U2200>
-<U2202> IGNORE;IGNORE;IGNORE;<U2202>
-<U2203> IGNORE;IGNORE;IGNORE;<U2203>
-<U2205> IGNORE;IGNORE;IGNORE;<U2205>
-<U2206> IGNORE;IGNORE;IGNORE;<U2206>
-<U2207> IGNORE;IGNORE;IGNORE;<U2207>
-<U2208> IGNORE;IGNORE;IGNORE;<U2208>
-<U220B> IGNORE;IGNORE;IGNORE;<U220B>
-<U220F> IGNORE;IGNORE;IGNORE;<U220F>
-<U2211> IGNORE;IGNORE;IGNORE;<U2211>
-<U2212> IGNORE;IGNORE;IGNORE;<U2212>
-<U2213> IGNORE;IGNORE;IGNORE;<U2213>
-<U2214> IGNORE;IGNORE;IGNORE;<U2214>
-<U2044> IGNORE;IGNORE;IGNORE;<U2044>
-<U2217> IGNORE;IGNORE;IGNORE;<U2217>
-<U2218> IGNORE;IGNORE;IGNORE;<U2218>
-<U2022> IGNORE;IGNORE;IGNORE;<U2022>
-<U221A> IGNORE;IGNORE;IGNORE;<U221A>
-<U221D> IGNORE;IGNORE;IGNORE;<U221D>
-<U221E> IGNORE;IGNORE;IGNORE;<U221E>
-<U221F> IGNORE;IGNORE;IGNORE;<U221F>
-<U2220> IGNORE;IGNORE;IGNORE;<U2220>
-<U2225> IGNORE;IGNORE;IGNORE;<U2225>
-<U2227> IGNORE;IGNORE;IGNORE;<U2227>
-<U2228> IGNORE;IGNORE;IGNORE;<U2228>
-<U2229> IGNORE;IGNORE;IGNORE;<U2229>
-<U222A> IGNORE;IGNORE;IGNORE;<U222A>
-<U222B> IGNORE;IGNORE;IGNORE;<U222B>
-<U222C> IGNORE;IGNORE;IGNORE;<U222C>
-<U222E> IGNORE;IGNORE;IGNORE;<U222E>
-<U2234> IGNORE;IGNORE;IGNORE;<U2234>
-<U2235> IGNORE;IGNORE;IGNORE;<U2235>
-<U2236> IGNORE;IGNORE;IGNORE;<U2236>
-<U2237> IGNORE;IGNORE;IGNORE;<U2237>
-<U223C> IGNORE;IGNORE;IGNORE;<U223C>
-<U223E> IGNORE;IGNORE;IGNORE;<U223E>
-<U2243> IGNORE;IGNORE;IGNORE;<U2243>
-<U2245> IGNORE;IGNORE;IGNORE;<U2245>
-<U2248> IGNORE;IGNORE;IGNORE;<U2248>
-<U224C> IGNORE;IGNORE;IGNORE;<U224C>
-<U2253> IGNORE;IGNORE;IGNORE;<U2253>
-<U2261> IGNORE;IGNORE;IGNORE;<U2261>
-<U226A> IGNORE;IGNORE;IGNORE;<U226A>
-<U226B> IGNORE;IGNORE;IGNORE;<U226B>
-<U226E> IGNORE;IGNORE;IGNORE;<U226E>
-<U226F> IGNORE;IGNORE;IGNORE;<U226F>
-<U2282> IGNORE;IGNORE;IGNORE;<U2282>
-<U2283> IGNORE;IGNORE;IGNORE;<U2283>
-<U2286> IGNORE;IGNORE;IGNORE;<U2286>
-<U2287> IGNORE;IGNORE;IGNORE;<U2287>
-<U2299> IGNORE;IGNORE;IGNORE;<U2299>
-<U229A> IGNORE;IGNORE;IGNORE;<U229A>
-<U22A5> IGNORE;IGNORE;IGNORE;<U22A5>
-<U22C5> IGNORE;IGNORE;IGNORE;<U22C5>
-<U22EE> IGNORE;IGNORE;IGNORE;<U22EE>
-<U2302> IGNORE;IGNORE;IGNORE;<U2302>
-<U2308> IGNORE;IGNORE;IGNORE;<U2308>
-<U2309> IGNORE;IGNORE;IGNORE;<U2309>
-<U230A> IGNORE;IGNORE;IGNORE;<U230A>
-<U230B> IGNORE;IGNORE;IGNORE;<U230B>
-<U2310> IGNORE;IGNORE;IGNORE;<U2310>
-<U2312> IGNORE;IGNORE;IGNORE;<U2312>
-<U2315> IGNORE;IGNORE;IGNORE;<U2315>
-<U2320> IGNORE;IGNORE;IGNORE;<U2320>
-<U2321> IGNORE;IGNORE;IGNORE;<U2321>
-<U2423> IGNORE;IGNORE;IGNORE;<U2423>
-<U2440> IGNORE;IGNORE;IGNORE;<U2440>
-<U2441> IGNORE;IGNORE;IGNORE;<U2441>
-<U2442> IGNORE;IGNORE;IGNORE;<U2442>
-<U2443> IGNORE;IGNORE;IGNORE;<U2443>
-<U2446> IGNORE;IGNORE;IGNORE;<U2446>
-<U2447> IGNORE;IGNORE;IGNORE;<U2447>
-<U2448> IGNORE;IGNORE;IGNORE;<U2448>
-<U2449> IGNORE;IGNORE;IGNORE;<U2449>
-<U2460> IGNORE;IGNORE;IGNORE;<U2460>
-<U2461> IGNORE;IGNORE;IGNORE;<U2461>
-<U2462> IGNORE;IGNORE;IGNORE;<U2462>
-<U2463> IGNORE;IGNORE;IGNORE;<U2463>
-<U2464> IGNORE;IGNORE;IGNORE;<U2464>
-<U2465> IGNORE;IGNORE;IGNORE;<U2465>
-<U2466> IGNORE;IGNORE;IGNORE;<U2466>
-<U2467> IGNORE;IGNORE;IGNORE;<U2467>
-<U2468> IGNORE;IGNORE;IGNORE;<U2468>
-<U2469> IGNORE;IGNORE;IGNORE;<U2469>
-<U246A> IGNORE;IGNORE;IGNORE;<U246A>
-<U246B> IGNORE;IGNORE;IGNORE;<U246B>
-<U246C> IGNORE;IGNORE;IGNORE;<U246C>
-<U246D> IGNORE;IGNORE;IGNORE;<U246D>
-<U246E> IGNORE;IGNORE;IGNORE;<U246E>
-<U246F> IGNORE;IGNORE;IGNORE;<U246F>
-<U2470> IGNORE;IGNORE;IGNORE;<U2470>
-<U2471> IGNORE;IGNORE;IGNORE;<U2471>
-<U2472> IGNORE;IGNORE;IGNORE;<U2472>
-<U2473> IGNORE;IGNORE;IGNORE;<U2473>
-<U2474> IGNORE;IGNORE;IGNORE;<U2474>
-<U2475> IGNORE;IGNORE;IGNORE;<U2475>
-<U2476> IGNORE;IGNORE;IGNORE;<U2476>
-<U2477> IGNORE;IGNORE;IGNORE;<U2477>
-<U2478> IGNORE;IGNORE;IGNORE;<U2478>
-<U2479> IGNORE;IGNORE;IGNORE;<U2479>
-<U247A> IGNORE;IGNORE;IGNORE;<U247A>
-<U247B> IGNORE;IGNORE;IGNORE;<U247B>
-<U247C> IGNORE;IGNORE;IGNORE;<U247C>
-<U247D> IGNORE;IGNORE;IGNORE;<U247D>
-<U247E> IGNORE;IGNORE;IGNORE;<U247E>
-<U247F> IGNORE;IGNORE;IGNORE;<U247F>
-<U2480> IGNORE;IGNORE;IGNORE;<U2480>
-<U2481> IGNORE;IGNORE;IGNORE;<U2481>
-<U2482> IGNORE;IGNORE;IGNORE;<U2482>
-<U2483> IGNORE;IGNORE;IGNORE;<U2483>
-<U2484> IGNORE;IGNORE;IGNORE;<U2484>
-<U2485> IGNORE;IGNORE;IGNORE;<U2485>
-<U2486> IGNORE;IGNORE;IGNORE;<U2486>
-<U2487> IGNORE;IGNORE;IGNORE;<U2487>
-<U2488> IGNORE;IGNORE;IGNORE;<U2488>
-<U2489> IGNORE;IGNORE;IGNORE;<U2489>
-<U248A> IGNORE;IGNORE;IGNORE;<U248A>
-<U248B> IGNORE;IGNORE;IGNORE;<U248B>
-<U248C> IGNORE;IGNORE;IGNORE;<U248C>
-<U248D> IGNORE;IGNORE;IGNORE;<U248D>
-<U248E> IGNORE;IGNORE;IGNORE;<U248E>
-<U248F> IGNORE;IGNORE;IGNORE;<U248F>
-<U2490> IGNORE;IGNORE;IGNORE;<U2490>
-<U2491> IGNORE;IGNORE;IGNORE;<U2491>
-<U2492> IGNORE;IGNORE;IGNORE;<U2492>
-<U2493> IGNORE;IGNORE;IGNORE;<U2493>
-<U2494> IGNORE;IGNORE;IGNORE;<U2494>
-<U2495> IGNORE;IGNORE;IGNORE;<U2495>
-<U2496> IGNORE;IGNORE;IGNORE;<U2496>
-<U2497> IGNORE;IGNORE;IGNORE;<U2497>
-<U2498> IGNORE;IGNORE;IGNORE;<U2498>
-<U2499> IGNORE;IGNORE;IGNORE;<U2499>
-<U249A> IGNORE;IGNORE;IGNORE;<U249A>
-<U249B> IGNORE;IGNORE;IGNORE;<U249B>
-<U24EA> IGNORE;IGNORE;IGNORE;<U24EA>
-<U2500> IGNORE;IGNORE;IGNORE;<U2500>
-<U2550> IGNORE;IGNORE;IGNORE;<U2550>
-<U2502> IGNORE;IGNORE;IGNORE;<U2502>
-<U2551> IGNORE;IGNORE;IGNORE;<U2551>
-<U2504> IGNORE;IGNORE;IGNORE;<U2504>
-<U2505> IGNORE;IGNORE;IGNORE;<U2505>
-<U2506> IGNORE;IGNORE;IGNORE;<U2506>
-<U2507> IGNORE;IGNORE;IGNORE;<U2507>
-<U2508> IGNORE;IGNORE;IGNORE;<U2508>
-<U2509> IGNORE;IGNORE;IGNORE;<U2509>
-<U250A> IGNORE;IGNORE;IGNORE;<U250A>
-<U250B> IGNORE;IGNORE;IGNORE;<U250B>
-<U250C> IGNORE;IGNORE;IGNORE;<U250C>
-<U2552> IGNORE;IGNORE;IGNORE;<U2552>
-<U2553> IGNORE;IGNORE;IGNORE;<U2553>
-<U2554> IGNORE;IGNORE;IGNORE;<U2554>
-<U2510> IGNORE;IGNORE;IGNORE;<U2510>
-<U2555> IGNORE;IGNORE;IGNORE;<U2555>
-<U2556> IGNORE;IGNORE;IGNORE;<U2556>
-<U2557> IGNORE;IGNORE;IGNORE;<U2557>
-<U2514> IGNORE;IGNORE;IGNORE;<U2514>
-<U2558> IGNORE;IGNORE;IGNORE;<U2558>
-<U2559> IGNORE;IGNORE;IGNORE;<U2559>
-<U255A> IGNORE;IGNORE;IGNORE;<U255A>
-<U2518> IGNORE;IGNORE;IGNORE;<U2518>
-<U255B> IGNORE;IGNORE;IGNORE;<U255B>
-<U255C> IGNORE;IGNORE;IGNORE;<U255C>
-<U255D> IGNORE;IGNORE;IGNORE;<U255D>
-<U251C> IGNORE;IGNORE;IGNORE;<U251C>
-<U255E> IGNORE;IGNORE;IGNORE;<U255E>
-<U251E> IGNORE;IGNORE;IGNORE;<U251E>
-<U251F> IGNORE;IGNORE;IGNORE;<U251F>
-<U255F> IGNORE;IGNORE;IGNORE;<U255F>
-<U2521> IGNORE;IGNORE;IGNORE;<U2521>
-<U2522> IGNORE;IGNORE;IGNORE;<U2522>
-<U2560> IGNORE;IGNORE;IGNORE;<U2560>
-<U2524> IGNORE;IGNORE;IGNORE;<U2524>
-<U2561> IGNORE;IGNORE;IGNORE;<U2561>
-<U2526> IGNORE;IGNORE;IGNORE;<U2526>
-<U2527> IGNORE;IGNORE;IGNORE;<U2527>
-<U2562> IGNORE;IGNORE;IGNORE;<U2562>
-<U2529> IGNORE;IGNORE;IGNORE;<U2529>
-<U252A> IGNORE;IGNORE;IGNORE;<U252A>
-<U2563> IGNORE;IGNORE;IGNORE;<U2563>
-<U252C> IGNORE;IGNORE;IGNORE;<U252C>
-<U252D> IGNORE;IGNORE;IGNORE;<U252D>
-<U252E> IGNORE;IGNORE;IGNORE;<U252E>
-<U2564> IGNORE;IGNORE;IGNORE;<U2564>
-<U2565> IGNORE;IGNORE;IGNORE;<U2565>
-<U2531> IGNORE;IGNORE;IGNORE;<U2531>
-<U2532> IGNORE;IGNORE;IGNORE;<U2532>
-<U2566> IGNORE;IGNORE;IGNORE;<U2566>
-<U2534> IGNORE;IGNORE;IGNORE;<U2534>
-<U2535> IGNORE;IGNORE;IGNORE;<U2535>
-<U2536> IGNORE;IGNORE;IGNORE;<U2536>
-<U2567> IGNORE;IGNORE;IGNORE;<U2567>
-<U2568> IGNORE;IGNORE;IGNORE;<U2568>
-<U2539> IGNORE;IGNORE;IGNORE;<U2539>
-<U253A> IGNORE;IGNORE;IGNORE;<U253A>
-<U2569> IGNORE;IGNORE;IGNORE;<U2569>
-<U253C> IGNORE;IGNORE;IGNORE;<U253C>
-<U253D> IGNORE;IGNORE;IGNORE;<U253D>
-<U253E> IGNORE;IGNORE;IGNORE;<U253E>
-<U256A> IGNORE;IGNORE;IGNORE;<U256A>
-<U2540> IGNORE;IGNORE;IGNORE;<U2540>
-<U2541> IGNORE;IGNORE;IGNORE;<U2541>
-<U256B> IGNORE;IGNORE;IGNORE;<U256B>
-<U2543> IGNORE;IGNORE;IGNORE;<U2543>
-<U2544> IGNORE;IGNORE;IGNORE;<U2544>
-<U2545> IGNORE;IGNORE;IGNORE;<U2545>
-<U2546> IGNORE;IGNORE;IGNORE;<U2546>
-<U2547> IGNORE;IGNORE;IGNORE;<U2547>
-<U2548> IGNORE;IGNORE;IGNORE;<U2548>
-<U2549> IGNORE;IGNORE;IGNORE;<U2549>
-<U254A> IGNORE;IGNORE;IGNORE;<U254A>
-<U256C> IGNORE;IGNORE;IGNORE;<U256C>
-<U2571> IGNORE;IGNORE;IGNORE;<U2571>
-<U2572> IGNORE;IGNORE;IGNORE;<U2572>
-<U2580> IGNORE;IGNORE;IGNORE;<U2580>
-<U2584> IGNORE;IGNORE;IGNORE;<U2584>
-<U2588> IGNORE;IGNORE;IGNORE;<U2588>
-<U258C> IGNORE;IGNORE;IGNORE;<U258C>
-<U2590> IGNORE;IGNORE;IGNORE;<U2590>
-<U2591> IGNORE;IGNORE;IGNORE;<U2591>
-<U2592> IGNORE;IGNORE;IGNORE;<U2592>
-<U2593> IGNORE;IGNORE;IGNORE;<U2593>
-<U25A0> IGNORE;IGNORE;IGNORE;<U25A0>
-<U25A1> IGNORE;IGNORE;IGNORE;<U25A1>
-<U25A2> IGNORE;IGNORE;IGNORE;<U25A2>
-<U25A3> IGNORE;IGNORE;IGNORE;<U25A3>
-<U25A4> IGNORE;IGNORE;IGNORE;<U25A4>
-<U25A5> IGNORE;IGNORE;IGNORE;<U25A5>
-<U25A6> IGNORE;IGNORE;IGNORE;<U25A6>
-<U25A7> IGNORE;IGNORE;IGNORE;<U25A7>
-<U25A8> IGNORE;IGNORE;IGNORE;<U25A8>
-<U25A9> IGNORE;IGNORE;IGNORE;<U25A9>
-<U25AA> IGNORE;IGNORE;IGNORE;<U25AA>
-<U25AC> IGNORE;IGNORE;IGNORE;<U25AC>
-<U25AD> IGNORE;IGNORE;IGNORE;<U25AD>
-<U25B2> IGNORE;IGNORE;IGNORE;<U25B2>
-<U25B3> IGNORE;IGNORE;IGNORE;<U25B3>
-<U25B7> IGNORE;IGNORE;IGNORE;<U25B7>
-<U25BA> IGNORE;IGNORE;IGNORE;<U25BA>
-<U25BC> IGNORE;IGNORE;IGNORE;<U25BC>
-<U25BD> IGNORE;IGNORE;IGNORE;<U25BD>
-<U25C1> IGNORE;IGNORE;IGNORE;<U25C1>
-<U25C4> IGNORE;IGNORE;IGNORE;<U25C4>
-<U25C6> IGNORE;IGNORE;IGNORE;<U25C6>
-<U25C7> IGNORE;IGNORE;IGNORE;<U25C7>
-<U25CA> IGNORE;IGNORE;IGNORE;<U25CA>
-<U25CB> IGNORE;IGNORE;IGNORE;<U25CB>
-<U25CE> IGNORE;IGNORE;IGNORE;<U25CE>
-<U25CF> IGNORE;IGNORE;IGNORE;<U25CF>
-<U25D0> IGNORE;IGNORE;IGNORE;<U25D0>
-<U25D1> IGNORE;IGNORE;IGNORE;<U25D1>
-<U25D8> IGNORE;IGNORE;IGNORE;<U25D8>
-<U25D9> IGNORE;IGNORE;IGNORE;<U25D9>
-<U25E2> IGNORE;IGNORE;IGNORE;<U25E2>
-<U25E3> IGNORE;IGNORE;IGNORE;<U25E3>
-<U25EF> IGNORE;IGNORE;IGNORE;<U25EF>
-<U2605> IGNORE;IGNORE;IGNORE;<U2605>
-<U2606> IGNORE;IGNORE;IGNORE;<U2606>
-<U260E> IGNORE;IGNORE;IGNORE;<U260E>
-<U260F> IGNORE;IGNORE;IGNORE;<U260F>
-<U261C> IGNORE;IGNORE;IGNORE;<U261C>
-<U261E> IGNORE;IGNORE;IGNORE;<U261E>
-<U263A> IGNORE;IGNORE;IGNORE;<U263A>
-<U263B> IGNORE;IGNORE;IGNORE;<U263B>
-<U263C> IGNORE;IGNORE;IGNORE;<U263C>
-<U2640> IGNORE;IGNORE;IGNORE;<U2640>
-<U2642> IGNORE;IGNORE;IGNORE;<U2642>
-<U2660> IGNORE;IGNORE;IGNORE;<U2660>
-<U2661> IGNORE;IGNORE;IGNORE;<U2661>
-<U2662> IGNORE;IGNORE;IGNORE;<U2662>
-<U2663> IGNORE;IGNORE;IGNORE;<U2663>
-<U2664> IGNORE;IGNORE;IGNORE;<U2664>
-<U2665> IGNORE;IGNORE;IGNORE;<U2665>
-<U2666> IGNORE;IGNORE;IGNORE;<U2666>
-<U2667> IGNORE;IGNORE;IGNORE;<U2667>
-<U2669> IGNORE;IGNORE;IGNORE;<U2669>
-<U266A> IGNORE;IGNORE;IGNORE;<U266A>
-<U266B> IGNORE;IGNORE;IGNORE;<U266B>
-<U266C> IGNORE;IGNORE;IGNORE;<U266C>
-<U266D> IGNORE;IGNORE;IGNORE;<U266D>
-<U266E> IGNORE;IGNORE;IGNORE;<U266E>
-<U266F> IGNORE;IGNORE;IGNORE;<U266F>
-<U2713> IGNORE;IGNORE;IGNORE;<U2713>
-<U2717> IGNORE;IGNORE;IGNORE;<U2717>
-<U2720> IGNORE;IGNORE;IGNORE;<U2720>
-<U3000> IGNORE;IGNORE;IGNORE;<U3000>
-<U3001> IGNORE;IGNORE;IGNORE;<U3001>
-<U3002> IGNORE;IGNORE;IGNORE;<U3002>
-<U3003> IGNORE;IGNORE;IGNORE;<U3003>
-<U3004> IGNORE;IGNORE;IGNORE;<U3004>
-<U3005> IGNORE;IGNORE;IGNORE;<U3005>
-<U3006> IGNORE;IGNORE;IGNORE;<U3006>
-<U3007> IGNORE;IGNORE;IGNORE;<U3007>
-<U300A> IGNORE;IGNORE;IGNORE;<U300A>
-<U300B> IGNORE;IGNORE;IGNORE;<U300B>
-<U300C> IGNORE;IGNORE;IGNORE;<U300C>
-<U300D> IGNORE;IGNORE;IGNORE;<U300D>
-<U300E> IGNORE;IGNORE;IGNORE;<U300E>
-<U300F> IGNORE;IGNORE;IGNORE;<U300F>
-<U3010> IGNORE;IGNORE;IGNORE;<U3010>
-<U3011> IGNORE;IGNORE;IGNORE;<U3011>
-<U3012> IGNORE;IGNORE;IGNORE;<U3012>
-<U3013> IGNORE;IGNORE;IGNORE;<U3013>
-<U3014> IGNORE;IGNORE;IGNORE;<U3014>
-<U3015> IGNORE;IGNORE;IGNORE;<U3015>
-<U3016> IGNORE;IGNORE;IGNORE;<U3016>
-<U3017> IGNORE;IGNORE;IGNORE;<U3017>
-<U301C> IGNORE;IGNORE;IGNORE;<U301C>
-<U3020> IGNORE;IGNORE;IGNORE;<U3020>
-<U309B> IGNORE;IGNORE;IGNORE;<U309B>
-<U309C> IGNORE;IGNORE;IGNORE;<U309C>
-<U309D> IGNORE;IGNORE;IGNORE;<U309D>
-<U309E> IGNORE;IGNORE;IGNORE;<U309E>
-<U30FB> IGNORE;IGNORE;IGNORE;<U30FB>
-<U30FC> IGNORE;IGNORE;IGNORE;<U30FC>
-<U30FD> IGNORE;IGNORE;IGNORE;<U30FD>
-<U30FE> IGNORE;IGNORE;IGNORE;<U30FE>
-<U321C> IGNORE;IGNORE;IGNORE;<U321C>
-<U3220> IGNORE;IGNORE;IGNORE;<U3220>
-<U3221> IGNORE;IGNORE;IGNORE;<U3221>
-<U3222> IGNORE;IGNORE;IGNORE;<U3222>
-<U3223> IGNORE;IGNORE;IGNORE;<U3223>
-<U3224> IGNORE;IGNORE;IGNORE;<U3224>
-<U3225> IGNORE;IGNORE;IGNORE;<U3225>
-<U3226> IGNORE;IGNORE;IGNORE;<U3226>
-<U3227> IGNORE;IGNORE;IGNORE;<U3227>
-<U3228> IGNORE;IGNORE;IGNORE;<U3228>
-<U3229> IGNORE;IGNORE;IGNORE;<U3229>
-<U327F> IGNORE;IGNORE;IGNORE;<U327F>
-<U33C2> IGNORE;IGNORE;IGNORE;<U33C2>
-<U33D8> IGNORE;IGNORE;IGNORE;<U33D8>
-<U0000> IGNORE;IGNORE;IGNORE;<U0000>
-<U0001> IGNORE;IGNORE;IGNORE;<U0001>
-<U0002> IGNORE;IGNORE;IGNORE;<U0002>
-<U0003> IGNORE;IGNORE;IGNORE;<U0003>
-<U0004> IGNORE;IGNORE;IGNORE;<U0004>
-<U0005> IGNORE;IGNORE;IGNORE;<U0005>
-<U0006> IGNORE;IGNORE;IGNORE;<U0006>
-<U0007> IGNORE;IGNORE;IGNORE;<U0007>
-<U0008> IGNORE;IGNORE;IGNORE;<U0008>
-<U000E> IGNORE;IGNORE;IGNORE;<U000E>
-<U000F> IGNORE;IGNORE;IGNORE;<U000F>
-<U0010> IGNORE;IGNORE;IGNORE;<U0010>
-<U0011> IGNORE;IGNORE;IGNORE;<U0011>
-<U0012> IGNORE;IGNORE;IGNORE;<U0012>
-<U0013> IGNORE;IGNORE;IGNORE;<U0013>
-<U0014> IGNORE;IGNORE;IGNORE;<U0014>
-<U0015> IGNORE;IGNORE;IGNORE;<U0015>
-<U0016> IGNORE;IGNORE;IGNORE;<U0016>
-<U0017> IGNORE;IGNORE;IGNORE;<U0017>
-<U0018> IGNORE;IGNORE;IGNORE;<U0018>
-<U0019> IGNORE;IGNORE;IGNORE;<U0019>
-<U001A> IGNORE;IGNORE;IGNORE;<U001A>
-<U001B> IGNORE;IGNORE;IGNORE;<U001B>
-<U001C> IGNORE;IGNORE;IGNORE;<U001C>
-<U001D> IGNORE;IGNORE;IGNORE;<U001D>
-<U001E> IGNORE;IGNORE;IGNORE;<U001E>
-<U001F> IGNORE;IGNORE;IGNORE;<U001F>
-<U007F> IGNORE;IGNORE;IGNORE;<U007F>
-<U0080> IGNORE;IGNORE;IGNORE;<U0080>
-<U0081> IGNORE;IGNORE;IGNORE;<U0081>
-<U0082> IGNORE;IGNORE;IGNORE;<U0082>
-<U0083> IGNORE;IGNORE;IGNORE;<U0083>
-<U0084> IGNORE;IGNORE;IGNORE;<U0084>
-<U0085> IGNORE;IGNORE;IGNORE;<U0085>
-<U0086> IGNORE;IGNORE;IGNORE;<U0086>
-<U0087> IGNORE;IGNORE;IGNORE;<U0087>
-<U0088> IGNORE;IGNORE;IGNORE;<U0088>
-<U0089> IGNORE;IGNORE;IGNORE;<U0089>
-<U008A> IGNORE;IGNORE;IGNORE;<U008A>
-<U008B> IGNORE;IGNORE;IGNORE;<U008B>
-<U008C> IGNORE;IGNORE;IGNORE;<U008C>
-<U008D> IGNORE;IGNORE;IGNORE;<U008D>
-<U008E> IGNORE;IGNORE;IGNORE;<U008E>
-<U008F> IGNORE;IGNORE;IGNORE;<U008F>
-<U0090> IGNORE;IGNORE;IGNORE;<U0090>
-<U0091> IGNORE;IGNORE;IGNORE;<U0091>
-<U0092> IGNORE;IGNORE;IGNORE;<U0092>
-<U0093> IGNORE;IGNORE;IGNORE;<U0093>
-<U0094> IGNORE;IGNORE;IGNORE;<U0094>
-<U0095> IGNORE;IGNORE;IGNORE;<U0095>
-<U0096> IGNORE;IGNORE;IGNORE;<U0096>
-<U0097> IGNORE;IGNORE;IGNORE;<U0097>
-<U0098> IGNORE;IGNORE;IGNORE;<U0098>
-<U0099> IGNORE;IGNORE;IGNORE;<U0099>
-<U009A> IGNORE;IGNORE;IGNORE;<U009A>
-<U009B> IGNORE;IGNORE;IGNORE;<U009B>
-<U009C> IGNORE;IGNORE;IGNORE;<U009C>
-<U009D> IGNORE;IGNORE;IGNORE;<U009D>
-<U009E> IGNORE;IGNORE;IGNORE;<U009E>
-<U009F> IGNORE;IGNORE;IGNORE;<U009F>
-<UE000> IGNORE;IGNORE;IGNORE;<UE000>
-<UE001> IGNORE;IGNORE;IGNORE;<UE001>
-<UE002> IGNORE;IGNORE;IGNORE;<UE002>
-<U0301> IGNORE;IGNORE;IGNORE;<U0301>
-<UE004> IGNORE;IGNORE;IGNORE;<UE004>
-<UE005> IGNORE;IGNORE;IGNORE;<UE005>
-<UE006> IGNORE;IGNORE;IGNORE;<UE006>
-<UE007> IGNORE;IGNORE;IGNORE;<UE007>
-<UE008> IGNORE;IGNORE;IGNORE;<UE008>
-<UE009> IGNORE;IGNORE;IGNORE;<UE009>
-<UE00A> IGNORE;IGNORE;IGNORE;<UE00A>
-<UE00B> IGNORE;IGNORE;IGNORE;<UE00B>
-<UE00C> IGNORE;IGNORE;IGNORE;<UE00C>
-<UE00D> IGNORE;IGNORE;IGNORE;<UE00D>
-<UE00E> IGNORE;IGNORE;IGNORE;<UE00E>
-<UE00F> IGNORE;IGNORE;IGNORE;<UE00F>
-<"=> IGNORE;IGNORE;IGNORE;<"=>
-<UE011> IGNORE;IGNORE;IGNORE;<UE011>
-<UE012> IGNORE;IGNORE;IGNORE;<UE012>
-<UE013> IGNORE;IGNORE;IGNORE;<UE013>
-<UE014> IGNORE;IGNORE;IGNORE;<UE014>
-<UE015> IGNORE;IGNORE;IGNORE;<UE015>
-<UE017> IGNORE;IGNORE;IGNORE;<UE017>
-<UE018> IGNORE;IGNORE;IGNORE;<UE018>
-<UE019> IGNORE;IGNORE;IGNORE;<UE019>
-UNDEFINED IGNORE;IGNORE;IGNORE
-
-<U0030> <U0030>;<U0030>;IGNORE;IGNORE
-<U2070> <U0030>;<U2070>;IGNORE;IGNORE
-<U215B> <U0030>;<U215B>;IGNORE;IGNORE
-<U00BC> <U0030>;<U00BC>;IGNORE;IGNORE
-<U215C> <U0030>;<U215C>;IGNORE;IGNORE
-<U00BD> <U0030>;<U00BD>;IGNORE;IGNORE
-<U215D> <U0030>;<U215D>;IGNORE;IGNORE
-<U00BE> <U0030>;<U00BE>;IGNORE;IGNORE
-<U215E> <U0030>;<U215E>;IGNORE;IGNORE
-<U0031> <U0031>;<U0031>;IGNORE;IGNORE
-<U0032> <U0032>;<U0032>;IGNORE;IGNORE
-<U0033> <U0033>;<U0033>;IGNORE;IGNORE
-<U0034> <U0034>;<U0034>;IGNORE;IGNORE
-<U0035> <U0035>;<U0035>;IGNORE;IGNORE
-<U0036> <U0036>;<U0036>;IGNORE;IGNORE
-<U0037> <U0037>;<U0037>;IGNORE;IGNORE
-<U0038> <U0038>;<U0038>;IGNORE;IGNORE
-<U0039> <U0039>;<U0039>;IGNORE;IGNORE
-<U00B9> <U0031>;<U00B9>;IGNORE;IGNORE
-<U00B2> <U0032>;<U00B2>;IGNORE;IGNORE
-<U00B3> <U0033>;<U00B3>;IGNORE;IGNORE
-<U2074> <U0034>;<U2074>;IGNORE;IGNORE
-<U2075> <U0035>;<U2075>;IGNORE;IGNORE
-<U2076> <U0036>;<U2076>;IGNORE;IGNORE
-<U2077> <U0037>;<U2077>;IGNORE;IGNORE
-<U2078> <U0038>;<U2078>;IGNORE;IGNORE
-<U2079> <U0039>;<U2079>;IGNORE;IGNORE
-<U0041> <U0041>;<NONE>;<CAPITAL>;IGNORE
-<U0061> <U0041>;<NONE>;<SMALL>;IGNORE
-<U00AA> <U0041>;<NONE>;<U00AA>;IGNORE
-<U00C1> <U0041>;<ACUTE>;<CAPITAL>;IGNORE
-<U00E1> <U0041>;<ACUTE>;<SMALL>;IGNORE
-<U00C0> <U0041>;<GRAVE>;<CAPITAL>;IGNORE
-<U00E0> <U0041>;<GRAVE>;<SMALL>;IGNORE
-<U0200> <U0041>;<DOUBLE-GRAVE>;<CAPITAL>;IGNORE
-<U0201> <U0041>;<DOUBLE-GRAVE>;<SMALL>;IGNORE
-<U0102> <U0041>;<BREVE>;<CAPITAL>;IGNORE
-<U0103> <U0041>;<BREVE>;<SMALL>;IGNORE
-<U1EAE> <U0041>;<BREVE+ACUTE>;<CAPITAL>;IGNORE
-<U1EAF> <U0041>;<BREVE+ACUTE>;<SMALL>;IGNORE
-<U1EB0> <U0041>;<BREVE+GRAVE>;<CAPITAL>;IGNORE
-<U1EB1> <U0041>;<BREVE+GRAVE>;<SMALL>;IGNORE
-<U1EB2> <U0041>;<BREVE+HOOK>;<CAPITAL>;IGNORE
-<U1EB3> <U0041>;<BREVE+HOOK>;<SMALL>;IGNORE
-<U1EB4> <U0041>;<BREVE+TILDE>;<CAPITAL>;IGNORE
-<U1EB5> <U0041>;<BREVE+TILDE>;<SMALL>;IGNORE
-<U1EB6> <U0041>;<BREVE+DOT-BELOW>;<CAPITAL>;IGNORE
-<U1EB7> <U0041>;<BREVE+DOT-BELOW>;<SMALL>;IGNORE
-<U0202> <U0041>;<INVERTED-BREVE>;<CAPITAL>;IGNORE
-<U0203> <U0041>;<INVERTED-BREVE>;<SMALL>;IGNORE
-<U00C2> <U0041>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U00E2> <U0041>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U1EA4> <U0041>;<CIRCUMFLEX+ACUTE>;<CAPITAL>;IGNORE
-<U1EA5> <U0041>;<CIRCUMFLEX+ACUTE>;<SMALL>;IGNORE
-<U1EA6> <U0041>;<CIRCUMFLEX+GRAVE>;<CAPITAL>;IGNORE
-<U1EA7> <U0041>;<CIRCUMFLEX+GRAVE>;<SMALL>;IGNORE
-<U1EA8> <U0041>;<CIRCUMFLEX+HOOK>;<CAPITAL>;IGNORE
-<U1EA9> <U0041>;<CIRCUMFLEX+HOOK>;<SMALL>;IGNORE
-<U1EAA> <U0041>;<CIRCUMFLEX+TILDE>;<CAPITAL>;IGNORE
-<U1EAB> <U0041>;<CIRCUMFLEX+TILDE>;<SMALL>;IGNORE
-<U1EAC> <U0041>;<CIRCUMFLEX+DOT-BELOW>;<CAPITAL>;IGNORE
-<U1EAD> <U0041>;<CIRCUMFLEX+DOT-BELOW>;<SMALL>;IGNORE
-<U01CD> <U0041>;<CARON>;<CAPITAL>;IGNORE
-<U01CE> <U0041>;<CARON>;<SMALL>;IGNORE
-<U00C5> <U0041>;<RING>;<CAPITAL>;IGNORE
-<U00E5> <U0041>;<RING>;<SMALL>;IGNORE
-<U01FA> <U0041>;<RING+ACUTE>;<CAPITAL>;IGNORE
-<U01FB> <U0041>;<RING+ACUTE>;<SMALL>;IGNORE
-<U1E00> <U0041>;<RING-BELOW>;<CAPITAL>;IGNORE
-<U1E01> <U0041>;<RING-BELOW>;<SMALL>;IGNORE
-<U00C4> <U0041>;<DIAERESIS>;<CAPITAL>;IGNORE
-<U00E4> <U0041>;<DIAERESIS>;<SMALL>;IGNORE
-<U01DE> <U0041>;<DIAERESIS+MACRON>;<CAPITAL>;IGNORE
-<U01DF> <U0041>;<DIAERESIS+MACRON>;<SMALL>;IGNORE
-<U1EA2> <U0041>;<HOOK>;<CAPITAL>;IGNORE
-<U1EA3> <U0041>;<HOOK>;<SMALL>;IGNORE
-<U00C3> <U0041>;<TILDE>;<CAPITAL>;IGNORE
-<U00E3> <U0041>;<TILDE>;<SMALL>;IGNORE
-<U1EA0> <U0041>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1EA1> <U0041>;<DOT-BELOW>;<SMALL>;IGNORE
-<U0104> <U0041>;<OGONEK>;<CAPITAL>;IGNORE
-<U0105> <U0041>;<OGONEK>;<SMALL>;IGNORE
-<U0100> <U0041>;<MACRON>;<CAPITAL>;IGNORE
-<U0101> <U0041>;<MACRON>;<SMALL>;IGNORE
-<U01E0> <U0041>;<MACRON+DOT>;<CAPITAL>;IGNORE
-<U01E1> <U0041>;<MACRON+DOT>;<SMALL>;IGNORE
-<a8>
-<U00C6> "<U0041><U0045>";"<U00C6><U00C6>";"<CAPITAL><CAPITAL>";IGNORE
-<U00E6> "<U0041><U0045>";"<U00C6><U00C6>";"<SMALL><SMALL>";IGNORE
-<U01FC> "<U0041><U0045>";"<U01FC><U01FC>";"<CAPITAL><CAPITAL>";IGNORE
-<U01FD> "<U0041><U0045>";"<U01FC><U01FC>";"<SMALL><SMALL>";IGNORE
-<U01E2> "<U0041><U0045>";"<U01E2><U01E2>";"<CAPITAL><CAPITAL>";IGNORE
-<U01E3> "<U0041><U0045>";"<U01E2><U01E2>";"<SMALL><SMALL>";IGNORE
-<U0042> <U0042>;<NONE>;<CAPITAL>;IGNORE
-<U0062> <U0042>;<NONE>;<SMALL>;IGNORE
-<U1E02> <U0042>;<DOT>;<CAPITAL>;IGNORE
-<U1E03> <U0042>;<DOT>;<SMALL>;IGNORE
-<U1E04> <U0042>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E05> <U0042>;<DOT-BELOW>;<SMALL>;IGNORE
-<U1E06> <U0042>;<LINE-BELOW>;<CAPITAL>;IGNORE
-<U1E07> <U0042>;<LINE-BELOW>;<SMALL>;IGNORE
-<b8>
-<U0043> <U0043>;<NONE>;<CAPITAL>;IGNORE
-<U0063> <U0043>;<NONE>;<SMALL>;IGNORE
-<U0106> <U0043>;<ACUTE>;<CAPITAL>;IGNORE
-<U0107> <U0043>;<ACUTE>;<SMALL>;IGNORE
-<U0108> <U0043>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U0109> <U0043>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U010C> <U0043>;<CARON>;<CAPITAL>;IGNORE
-<U010D> <U0043>;<CARON>;<SMALL>;IGNORE
-<U0187> <U0043>;<HOOK>;<CAPITAL>;IGNORE
-<U0188> <U0043>;<HOOK>;<SMALL>;IGNORE
-<U010A> <U0043>;<DOT>;<CAPITAL>;IGNORE
-<U010B> <U0043>;<DOT>;<SMALL>;IGNORE
-<U00C7> <U0043>;<CEDILLA>;<CAPITAL>;IGNORE
-<U00E7> <U0043>;<CEDILLA>;<SMALL>;IGNORE
-<U1E08> <U0043>;<CEDILLA+ACUTE>;<CAPITAL>;IGNORE
-<U1E09> <U0043>;<CEDILLA+ACUTE>;<SMALL>;IGNORE
-<c8>
-<U0044> <U0044>;<NONE>;<CAPITAL>;IGNORE
-<U0064> <U0044>;<NONE>;<SMALL>;IGNORE
-<U010E> <U0044>;<CARON>;<CAPITAL>;IGNORE
-<U010F> <U0044>;<CARON>;<SMALL>;IGNORE
-<U1E0A> <U0044>;<DOT>;<CAPITAL>;IGNORE
-<U1E0B> <U0044>;<DOT>;<SMALL>;IGNORE
-<U1E0C> <U0044>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E0D> <U0044>;<DOT-BELOW>;<SMALL>;IGNORE
-<U0110> <U0044>;<STROKE>;<CAPITAL>;IGNORE
-<U0111> <U0044>;<STROKE>;<SMALL>;IGNORE
-<U1E10> <U0044>;<CEDILLA>;<CAPITAL>;IGNORE
-<U1E11> <U0044>;<CEDILLA>;<SMALL>;IGNORE
-<U1E12> <U0044>;<MACRON+CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U1E13> <U0044>;<MACRON+CIRCUMFLEX>;<SMALL>;IGNORE
-<U1E0E> <U0044>;<LINE-BELOW>;<CAPITAL>;IGNORE
-<U1E0F> <U0044>;<LINE-BELOW>;<SMALL>;IGNORE
-<d8>
-<U0045> <U0045>;<NONE>;<CAPITAL>;IGNORE
-<U0065> <U0045>;<NONE>;<SMALL>;IGNORE
-<U00C9> <U0045>;<ACUTE>;<CAPITAL>;IGNORE
-<U00E9> <U0045>;<ACUTE>;<SMALL>;IGNORE
-<U00C8> <U0045>;<GRAVE>;<CAPITAL>;IGNORE
-<U00E8> <U0045>;<GRAVE>;<SMALL>;IGNORE
-<U0204> <U0045>;<DOUBLE-GRAVE>;<CAPITAL>;IGNORE
-<U0205> <U0045>;<DOUBLE-GRAVE>;<SMALL>;IGNORE
-<U0114> <U0045>;<BREVE>;<CAPITAL>;IGNORE
-<U0115> <U0045>;<BREVE>;<SMALL>;IGNORE
-<U0206> <U0045>;<INVERTED-BREVE>;<CAPITAL>;IGNORE
-<U0207> <U0045>;<INVERTED-BREVE>;<SMALL>;IGNORE
-<U00CA> <U0045>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U00EA> <U0045>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U1EBE> <U0045>;<CIRCUMFLEX+ACUTE>;<CAPITAL>;IGNORE
-<U1EBF> <U0045>;<CIRCUMFLEX+ACUTE>;<SMALL>;IGNORE
-<U1EC0> <U0045>;<CIRCUMFLEX+GRAVE>;<CAPITAL>;IGNORE
-<U1EC1> <U0045>;<CIRCUMFLEX+GRAVE>;<SMALL>;IGNORE
-<U1EC2> <U0045>;<CIRCUMFLEX+HOOK>;<CAPITAL>;IGNORE
-<U1EC3> <U0045>;<CIRCUMFLEX+HOOK>;<SMALL>;IGNORE
-<U1EC4> <U0045>;<CIRCUMFLEX+TILDE>;<CAPITAL>;IGNORE
-<U1EC5> <U0045>;<CIRCUMFLEX+TILDE>;<SMALL>;IGNORE
-<U1EC6> <U0045>;<CIRCUMFLEX+DOT-BELOW>;<CAPITAL>;IGNORE
-<U1EC7> <U0045>;<CIRCUMFLEX+DOT-BELOW>;<SMALL>;IGNORE
-<U011A> <U0045>;<CARON>;<CAPITAL>;IGNORE
-<U011B> <U0045>;<CARON>;<SMALL>;IGNORE
-<U00CB> <U0045>;<DIAERESIS>;<CAPITAL>;IGNORE
-<U00EB> <U0045>;<DIAERESIS>;<SMALL>;IGNORE
-<U1EBA> <U0045>;<HOOK>;<CAPITAL>;IGNORE
-<U1EBB> <U0045>;<HOOK>;<SMALL>;IGNORE
-<U1EBC> <U0045>;<TILDE>;<CAPITAL>;IGNORE
-<U1EBD> <U0045>;<TILDE>;<SMALL>;IGNORE
-<U1E1A> <U0045>;<TILDE-BELOW>;<CAPITAL>;IGNORE
-<U1E1B> <U0045>;<TILDE-BELOW>;<SMALL>;IGNORE
-<U0116> <U0045>;<DOT>;<CAPITAL>;IGNORE
-<U0117> <U0045>;<DOT>;<SMALL>;IGNORE
-<U1EB8> <U0045>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1EB9> <U0045>;<DOT-BELOW>;<SMALL>;IGNORE
-<U1E1C> <U0045>;<CEDILLA+BREVE>;<CAPITAL>;IGNORE
-<U1E1D> <U0045>;<CEDILLA+BREVE>;<SMALL>;IGNORE
-<U0118> <U0045>;<OGONEK>;<CAPITAL>;IGNORE
-<U0119> <U0045>;<OGONEK>;<SMALL>;IGNORE
-<U0112> <U0045>;<MACRON>;<CAPITAL>;IGNORE
-<U0113> <U0045>;<MACRON>;<SMALL>;IGNORE
-<U1E16> <U0045>;<MACRON+ACUTE>;<CAPITAL>;IGNORE
-<U1E17> <U0045>;<MACRON+ACUTE>;<SMALL>;IGNORE
-<U1E14> <U0045>;<MACRON+GRAVE>;<CAPITAL>;IGNORE
-<U1E15> <U0045>;<MACRON+GRAVE>;<SMALL>;IGNORE
-<U1E18> <U0045>;<MACRON+CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U1E19> <U0045>;<MACRON+CIRCUMFLEX>;<SMALL>;IGNORE
-<e8>
-<U0046> <U0046>;<NONE>;<CAPITAL>;IGNORE
-<U0066> <U0046>;<NONE>;<SMALL>;IGNORE
-<U0191> <U0046>;<HOOK>;<CAPITAL>;IGNORE
-<U0192> <U0046>;<HOOK>;<SMALL>;IGNORE
-<U1E1E> <U0046>;<DOT>;<CAPITAL>;IGNORE
-<U1E1F> <U0046>;<DOT>;<SMALL>;IGNORE
-<f8>
-<UFB00> "<U0046><U0046>";"<NONE><NONE>";"<UFB00><UFB00>";IGNORE
-<UFB01> "<U0046><U0049>";"<NONE><NONE>";"<UFB01><UFB01>";IGNORE
-<UFB02> "<U0046><U004C>";"<NONE><NONE>";"<UFB02><UFB02>";IGNORE
-<UFB03> "<U0046><U0046><U0049>";"<NONE><NONE><NONE>";"<UFB03><UFB03><UFB03>";IGNORE
-<UFB04> "<U0046><U0046><U004C>";"<NONE><NONE><NONE>";"<UFB04><UFB04><UFB04>";IGNORE
-<U0047> <U0047>;<NONE>;<CAPITAL>;IGNORE
-<U0067> <U0047>;<NONE>;<SMALL>;IGNORE
-<U01F4> <U0047>;<ACUTE>;<CAPITAL>;IGNORE
-<U01F5> <U0047>;<ACUTE>;<SMALL>;IGNORE
-<U011E> <U0047>;<BREVE>;<CAPITAL>;IGNORE
-<U011F> <U0047>;<BREVE>;<SMALL>;IGNORE
-<U011C> <U0047>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U011D> <U0047>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U01E6> <U0047>;<CARON>;<CAPITAL>;IGNORE
-<U01E7> <U0047>;<CARON>;<SMALL>;IGNORE
-<U0120> <U0047>;<DOT>;<CAPITAL>;IGNORE
-<U0121> <U0047>;<DOT>;<SMALL>;IGNORE
-<U01E4> <U0047>;<STROKE>;<CAPITAL>;IGNORE
-<U01E5> <U0047>;<STROKE>;<SMALL>;IGNORE
-<U0122> <U0047>;<CEDILLA>;<CAPITAL>;IGNORE
-<U0123> <U0047>;<CEDILLA>;<SMALL>;IGNORE
-<U1E20> <U0047>;<MACRON>;<CAPITAL>;IGNORE
-<U1E21> <U0047>;<MACRON>;<SMALL>;IGNORE
-<g8>
-<U0048> <U0048>;<NONE>;<CAPITAL>;IGNORE
-<U0068> <U0048>;<NONE>;<SMALL>;IGNORE
-<U1E2A> <U0048>;<BREVE-BELOW>;<CAPITAL>;IGNORE
-<U1E2B> <U0048>;<BREVE-BELOW>;<SMALL>;IGNORE
-<U0124> <U0048>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U0125> <U0048>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U1E26> <U0048>;<DIAERESIS>;<CAPITAL>;IGNORE
-<U1E27> <U0048>;<DIAERESIS>;<SMALL>;IGNORE
-<U1E22> <U0048>;<DOT>;<CAPITAL>;IGNORE
-<U1E23> <U0048>;<DOT>;<SMALL>;IGNORE
-<U1E24> <U0048>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E25> <U0048>;<DOT-BELOW>;<SMALL>;IGNORE
-<U0126> <U0048>;<STROKE>;<CAPITAL>;IGNORE
-<U0127> <U0048>;<STROKE>;<SMALL>;IGNORE
-<U1E28> <U0048>;<CEDILLA>;<CAPITAL>;IGNORE
-<U1E29> <U0048>;<CEDILLA>;<SMALL>;IGNORE
-<h8>
-<U0049> <U0049>;<NONE>;<CAPITAL>;IGNORE
-<U0069> <U0049>;<NONE>;<SMALL>;IGNORE
-<U00CD> <U0049>;<ACUTE>;<CAPITAL>;IGNORE
-<U00ED> <U0049>;<ACUTE>;<SMALL>;IGNORE
-<U00CC> <U0049>;<GRAVE>;<CAPITAL>;IGNORE
-<U00EC> <U0049>;<GRAVE>;<SMALL>;IGNORE
-<U0208> <U0049>;<DOUBLE-GRAVE>;<CAPITAL>;IGNORE
-<U0209> <U0049>;<DOUBLE-GRAVE>;<SMALL>;IGNORE
-<U012C> <U0049>;<BREVE>;<CAPITAL>;IGNORE
-<U012D> <U0049>;<BREVE>;<SMALL>;IGNORE
-<U020A> <U0049>;<INVERTED-BREVE>;<CAPITAL>;IGNORE
-<U020B> <U0049>;<INVERTED-BREVE>;<SMALL>;IGNORE
-<U00CE> <U0049>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U00EE> <U0049>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U01CF> <U0049>;<CARON>;<CAPITAL>;IGNORE
-<U01D0> <U0049>;<CARON>;<SMALL>;IGNORE
-<U00CF> <U0049>;<DIAERESIS>;<CAPITAL>;IGNORE
-<U00EF> <U0049>;<DIAERESIS>;<SMALL>;IGNORE
-<U1E2E> <U0049>;<DIAERESIS+ACUTE>;<CAPITAL>;IGNORE
-<U1E2F> <U0049>;<DIAERESIS+ACUTE>;<SMALL>;IGNORE
-<U1EC8> <U0049>;<HOOK>;<CAPITAL>;IGNORE
-<U1EC9> <U0049>;<HOOK>;<SMALL>;IGNORE
-<U0128> <U0049>;<TILDE>;<CAPITAL>;IGNORE
-<U0129> <U0049>;<TILDE>;<SMALL>;IGNORE
-<U1E2C> <U0049>;<TILDE-BELOW>;<CAPITAL>;IGNORE
-<U1E2D> <U0049>;<TILDE-BELOW>;<SMALL>;IGNORE
-<U0130> <U0049>;<DOT>;<CAPITAL>;IGNORE
-<U0131> <U0049>;<DOT>;<SMALL>;IGNORE
-<U1ECA> <U0049>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1ECB> <U0049>;<DOT-BELOW>;<SMALL>;IGNORE
-<U012E> <U0049>;<OGONEK>;<CAPITAL>;IGNORE
-<U012F> <U0049>;<OGONEK>;<SMALL>;IGNORE
-<U012A> <U0049>;<MACRON>;<CAPITAL>;IGNORE
-<U012B> <U0049>;<MACRON>;<SMALL>;IGNORE
-<i8>
-<U0132> "<U0049><U004A>";"<U0132><U0132>";"<CAPITAL><CAPITAL>";IGNORE
-<U0133> "<U0049><U004A>";"<U0132><U0132>";"<SMALL><SMALL>";IGNORE
-<U004A> <U004A>;<NONE>;<CAPITAL>;IGNORE
-<U006A> <U004A>;<NONE>;<SMALL>;IGNORE
-<U0134> <U004A>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U0135> <U004A>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<j8>
-<U004B> <U004B>;<NONE>;<CAPITAL>;IGNORE
-<U006B> <U004B>;<NONE>;<SMALL>;IGNORE
-<U1E30> <U004B>;<ACUTE>;<CAPITAL>;IGNORE
-<U1E31> <U004B>;<ACUTE>;<SMALL>;IGNORE
-<U01E8> <U004B>;<CARON>;<CAPITAL>;IGNORE
-<U01E9> <U004B>;<CARON>;<SMALL>;IGNORE
-<U0198> <U004B>;<HOOK>;<CAPITAL>;IGNORE
-<U0199> <U004B>;<HOOK>;<SMALL>;IGNORE
-<U1E32> <U004B>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E33> <U004B>;<DOT-BELOW>;<SMALL>;IGNORE
-<U0136> <U004B>;<CEDILLA>;<CAPITAL>;IGNORE
-<U0137> <U004B>;<CEDILLA>;<SMALL>;IGNORE
-<U1E34> <U004B>;<LINE-BELOW>;<CAPITAL>;IGNORE
-<U1E35> <U004B>;<LINE-BELOW>;<SMALL>;IGNORE
-<k8>
-<U0138> <U004B>;<U0138>;<SMALL>;IGNORE
-<U004C> <U004C>;<NONE>;<CAPITAL>;IGNORE
-<U006C> <U004C>;<NONE>;<SMALL>;IGNORE
-<U0139> <U004C>;<ACUTE>;<CAPITAL>;IGNORE
-<U013A> <U004C>;<ACUTE>;<SMALL>;IGNORE
-<U013D> <U004C>;<CARON>;<CAPITAL>;IGNORE
-<U013E> <U004C>;<CARON>;<SMALL>;IGNORE
-<U013F> <U004C>;<DOT>;<CAPITAL>;IGNORE
-<U0140> <U004C>;<DOT>;<SMALL>;IGNORE
-<U1E36> <U004C>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E37> <U004C>;<DOT-BELOW>;<SMALL>;IGNORE
-<U0141> <U004C>;<STROKE>;<CAPITAL>;IGNORE
-<U0142> <U004C>;<STROKE>;<SMALL>;IGNORE
-<U013B> <U004C>;<CEDILLA>;<CAPITAL>;IGNORE
-<U013C> <U004C>;<CEDILLA>;<SMALL>;IGNORE
-<U1E38> <U004C>;<MACRON+DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E39> <U004C>;<MACRON+DOT-BELOW>;<SMALL>;IGNORE
-<U1E3C> <U004C>;<MACRON+CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U1E3D> <U004C>;<MACRON+CIRCUMFLEX>;<SMALL>;IGNORE
-<U1E3A> <U004C>;<LINE-BELOW>;<CAPITAL>;IGNORE
-<U1E3B> <U004C>;<LINE-BELOW>;<SMALL>;IGNORE
-<l8>
-<U004D> <U004D>;<NONE>;<CAPITAL>;IGNORE
-<U006D> <U004D>;<NONE>;<SMALL>;IGNORE
-<U1E3E> <U004D>;<ACUTE>;<CAPITAL>;IGNORE
-<U1E3F> <U004D>;<ACUTE>;<SMALL>;IGNORE
-<U1E40> <U004D>;<DOT>;<CAPITAL>;IGNORE
-<U1E41> <U004D>;<DOT>;<SMALL>;IGNORE
-<U1E42> <U004D>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E43> <U004D>;<DOT-BELOW>;<SMALL>;IGNORE
-<m8>
-<U004E> <U004E>;<NONE>;<CAPITAL>;IGNORE
-<U006E> <U004E>;<NONE>;<SMALL>;IGNORE
-<U0143> <U004E>;<ACUTE>;<CAPITAL>;IGNORE
-<U0144> <U004E>;<ACUTE>;<SMALL>;IGNORE
-<U0147> <U004E>;<CARON>;<CAPITAL>;IGNORE
-<U0148> <U004E>;<CARON>;<SMALL>;IGNORE
-<U1E44> <U004E>;<DOT>;<CAPITAL>;IGNORE
-<U1E45> <U004E>;<DOT>;<SMALL>;IGNORE
-<U1E46> <U004E>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E47> <U004E>;<DOT-BELOW>;<SMALL>;IGNORE
-<U0145> <U004E>;<CEDILLA>;<CAPITAL>;IGNORE
-<U0146> <U004E>;<CEDILLA>;<SMALL>;IGNORE
-<U1E4A> <U004E>;<MACRON+CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U1E4B> <U004E>;<MACRON+CIRCUMFLEX>;<SMALL>;IGNORE
-<U1E48> <U004E>;<LINE-BELOW>;<CAPITAL>;IGNORE
-<U1E49> <U004E>;<LINE-BELOW>;<SMALL>;IGNORE
-<U0149> <U004E>;<PRECEDED-BY-APOSTROPHE>;<SMALL>;IGNORE
-<n8>
-<U00D1> <U00D1>;<NONE>;<CAPITAL>;IGNORE
-<U00F1> <U00D1>;<NONE>;<SMALL>;IGNORE
-<U014A> "<U004E><U0047>";"<U014A><U014A>";"<CAPITAL><CAPITAL>";IGNORE
-<U014B> "<U004E><U0047>";"<U014A><U014A>";"<SMALL><SMALL>";IGNORE
-<U004F> <U004F>;<NONE>;<CAPITAL>;IGNORE
-<U006F> <U004F>;<NONE>;<SMALL>;IGNORE
-<U00BA> <U004F>;<NONE>;<U00BA>;IGNORE
-<U00D3> <U004F>;<ACUTE>;<CAPITAL>;IGNORE
-<U00F3> <U004F>;<ACUTE>;<SMALL>;IGNORE
-<U00D2> <U004F>;<GRAVE>;<CAPITAL>;IGNORE
-<U00F2> <U004F>;<GRAVE>;<SMALL>;IGNORE
-<U020C> <U004F>;<DOUBLE-GRAVE>;<CAPITAL>;IGNORE
-<U020D> <U004F>;<DOUBLE-GRAVE>;<SMALL>;IGNORE
-<U014E> <U004F>;<BREVE>;<CAPITAL>;IGNORE
-<U014F> <U004F>;<BREVE>;<SMALL>;IGNORE
-<U020E> <U004F>;<INVERTED-BREVE>;<CAPITAL>;IGNORE
-<U020F> <U004F>;<INVERTED-BREVE>;<SMALL>;IGNORE
-<U00D4> <U004F>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U00F4> <U004F>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U1ED0> <U004F>;<CIRCUMFLEX+ACUTE>;<CAPITAL>;IGNORE
-<U1ED1> <U004F>;<CIRCUMFLEX+ACUTE>;<SMALL>;IGNORE
-<U1ED2> <U004F>;<CIRCUMFLEX+GRAVE>;<CAPITAL>;IGNORE
-<U1ED3> <U004F>;<CIRCUMFLEX+GRAVE>;<SMALL>;IGNORE
-<U1ED4> <U004F>;<CIRCUMFLEX+HOOK>;<CAPITAL>;IGNORE
-<U1ED5> <U004F>;<CIRCUMFLEX+HOOK>;<SMALL>;IGNORE
-<U1ED6> <U004F>;<CIRCUMFLEX+TILDE>;<CAPITAL>;IGNORE
-<U1ED7> <U004F>;<CIRCUMFLEX+TILDE>;<SMALL>;IGNORE
-<U1ED8> <U004F>;<CIRCUMFLEX+DOT-BELOW>;<CAPITAL>;IGNORE
-<U1ED9> <U004F>;<CIRCUMFLEX+DOT-BELOW>;<SMALL>;IGNORE
-<U01D1> <U004F>;<CARON>;<CAPITAL>;IGNORE
-<U01D2> <U004F>;<CARON>;<SMALL>;IGNORE
-<U00D6> <U004F>;<DIAERESIS>;<CAPITAL>;IGNORE
-<U00F6> <U004F>;<DIAERESIS>;<SMALL>;IGNORE
-<U0150> <U004F>;<DOUBLE-ACUTE>;<CAPITAL>;IGNORE
-<U0151> <U004F>;<DOUBLE-ACUTE>;<SMALL>;IGNORE
-<U1ECE> <U004F>;<HOOK>;<CAPITAL>;IGNORE
-<U1ECF> <U004F>;<HOOK>;<SMALL>;IGNORE
-<U00D5> <U004F>;<TILDE>;<CAPITAL>;IGNORE
-<U00F5> <U004F>;<TILDE>;<SMALL>;IGNORE
-<U1E4C> <U004F>;<TILDE+ACUTE>;<CAPITAL>;IGNORE
-<U1E4D> <U004F>;<TILDE+ACUTE>;<SMALL>;IGNORE
-<U1E4E> <U004F>;<TILDE+DIAERESIS>;<CAPITAL>;IGNORE
-<U1E4F> <U004F>;<TILDE+DIAERESIS>;<SMALL>;IGNORE
-<U1ECC> <U004F>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1ECD> <U004F>;<DOT-BELOW>;<SMALL>;IGNORE
-<U00D8> <U004F>;<STROKE>;<CAPITAL>;IGNORE
-<U00F8> <U004F>;<STROKE>;<SMALL>;IGNORE
-<U01FE> <U004F>;<STROKE+ACUTE>;<CAPITAL>;IGNORE
-<U01FF> <U004F>;<STROKE+ACUTE>;<SMALL>;IGNORE
-<U01EA> <U004F>;<OGONEK>;<CAPITAL>;IGNORE
-<U01EB> <U004F>;<OGONEK>;<SMALL>;IGNORE
-<U01EC> <U004F>;<OGONEK+MACRON>;<CAPITAL>;IGNORE
-<U01ED> <U004F>;<OGONEK+MACRON>;<SMALL>;IGNORE
-<U014C> <U004F>;<MACRON>;<CAPITAL>;IGNORE
-<U014D> <U004F>;<MACRON>;<SMALL>;IGNORE
-<U1E52> <U004F>;<MACRON+ACUTE>;<CAPITAL>;IGNORE
-<U1E53> <U004F>;<MACRON+ACUTE>;<SMALL>;IGNORE
-<U1E50> <U004F>;<MACRON+GRAVE>;<CAPITAL>;IGNORE
-<U1E51> <U004F>;<MACRON+GRAVE>;<SMALL>;IGNORE
-<U01A0> <U004F>;<HORN>;<CAPITAL>;IGNORE
-<U01A1> <U004F>;<HORN>;<SMALL>;IGNORE
-<U1EDA> <U004F>;<HORN+ACUTE>;<CAPITAL>;IGNORE
-<U1EDB> <U004F>;<HORN+ACUTE>;<SMALL>;IGNORE
-<U1EDC> <U004F>;<HORN+GRAVE>;<CAPITAL>;IGNORE
-<U1EDD> <U004F>;<HORN+GRAVE>;<SMALL>;IGNORE
-<U1EDE> <U004F>;<HORN+HOOK>;<CAPITAL>;IGNORE
-<U1EDF> <U004F>;<HORN+HOOK>;<SMALL>;IGNORE
-<U1EE0> <U004F>;<HORN+TILDE>;<CAPITAL>;IGNORE
-<U1EE1> <U004F>;<HORN+TILDE>;<SMALL>;IGNORE
-<U1EE2> <U004F>;<HORN+DOT-BELOW>;<CAPITAL>;IGNORE
-<U1EE3> <U004F>;<HORN+DOT-BELOW>;<SMALL>;IGNORE
-<o8>
-<U0152> "<U004F><U0045>";"<U0152><U0152>";"<CAPITAL><CAPITAL>";IGNORE
-<U0153> "<U004F><U0045>";"<U0152><U0152>";"<SMALL><SMALL>";IGNORE
-<U0050> <U0050>;<NONE>;<CAPITAL>;IGNORE
-<U0070> <U0050>;<NONE>;<SMALL>;IGNORE
-<U1E54> <U0050>;<ACUTE>;<CAPITAL>;IGNORE
-<U1E55> <U0050>;<ACUTE>;<SMALL>;IGNORE
-<U1E56> <U0050>;<DOT>;<CAPITAL>;IGNORE
-<U1E57> <U0050>;<DOT>;<SMALL>;IGNORE
-<p8>
-<U0051> <U0051>;<NONE>;<CAPITAL>;IGNORE
-<U0071> <U0051>;<NONE>;<SMALL>;IGNORE
-<q8>
-<U0052> <U0052>;<NONE>;<CAPITAL>;IGNORE
-<U0072> <U0052>;<NONE>;<SMALL>;IGNORE
-<U0154> <U0052>;<ACUTE>;<CAPITAL>;IGNORE
-<U0155> <U0052>;<ACUTE>;<SMALL>;IGNORE
-<U0210> <U0052>;<DOUBLE-GRAVE>;<CAPITAL>;IGNORE
-<U0211> <U0052>;<DOUBLE-GRAVE>;<SMALL>;IGNORE
-<U0212> <U0052>;<INVERTED-BREVE>;<CAPITAL>;IGNORE
-<U0213> <U0052>;<INVERTED-BREVE>;<SMALL>;IGNORE
-<U0158> <U0052>;<CARON>;<CAPITAL>;IGNORE
-<U0159> <U0052>;<CARON>;<SMALL>;IGNORE
-<U1E58> <U0052>;<DOT>;<CAPITAL>;IGNORE
-<U1E59> <U0052>;<DOT>;<SMALL>;IGNORE
-<U1E5A> <U0052>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E5B> <U0052>;<DOT-BELOW>;<SMALL>;IGNORE
-<U0156> <U0052>;<CEDILLA>;<CAPITAL>;IGNORE
-<U0157> <U0052>;<CEDILLA>;<SMALL>;IGNORE
-<U1E5C> <U0052>;<MACRON+DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E5D> <U0052>;<MACRON+DOT-BELOW>;<SMALL>;IGNORE
-<U1E5E> <U0052>;<LINE-BELOW>;<CAPITAL>;IGNORE
-<U1E5F> <U0052>;<LINE-BELOW>;<SMALL>;IGNORE
-<r8>
-<U0053> <U0053>;<NONE>;<CAPITAL>;IGNORE
-<U0073> <U0053>;<NONE>;<SMALL>;IGNORE
-<UFB06> "<U0053><U0054>";"<NONE><NONE>";"<UFB06><UFB06>";IGNORE
-<U015A> <U0053>;<ACUTE>;<CAPITAL>;IGNORE
-<U015B> <U0053>;<ACUTE>;<SMALL>;IGNORE
-<U1E64> <U0053>;<ACUTE+DOT>;<CAPITAL>;IGNORE
-<U1E65> <U0053>;<ACUTE+DOT>;<SMALL>;IGNORE
-<U015C> <U0053>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U015D> <U0053>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U0160> <U0053>;<CARON>;<CAPITAL>;IGNORE
-<U0161> <U0053>;<CARON>;<SMALL>;IGNORE
-<U1E66> <U0053>;<CARON+DOT>;<CAPITAL>;IGNORE
-<U1E67> <U0053>;<CARON+DOT>;<SMALL>;IGNORE
-<U1E60> <U0053>;<DOT>;<CAPITAL>;IGNORE
-<U1E61> <U0053>;<DOT>;<SMALL>;IGNORE
-<U1E62> <U0053>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E63> <U0053>;<DOT-BELOW>;<SMALL>;IGNORE
-<U1E68> <U0053>;<DOT+DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E69> <U0053>;<DOT+DOT-BELOW>;<SMALL>;IGNORE
-<U015E> <U0053>;<CEDILLA>;<CAPITAL>;IGNORE
-<U015F> <U0053>;<CEDILLA>;<SMALL>;IGNORE
-<s8>
-<U017F> <U0053>;<U017F>;<SMALL>;IGNORE
-<U00DF> "<U0053><U0053>";"<NONE><NONE>";"<SMALL><U00DF>";IGNORE
-<UFB05> "<U0053><U0054>";"<NONE><NONE>";"<UFB05><UFB05>";IGNORE
-<U0054> <U0054>;<NONE>;<CAPITAL>;IGNORE
-<U0074> <U0054>;<NONE>;<SMALL>;IGNORE
-<U0164> <U0054>;<CARON>;<CAPITAL>;IGNORE
-<U0165> <U0054>;<CARON>;<SMALL>;IGNORE
-<U1E6A> <U0054>;<DOT>;<CAPITAL>;IGNORE
-<U1E6B> <U0054>;<DOT>;<SMALL>;IGNORE
-<U1E6C> <U0054>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E6D> <U0054>;<DOT-BELOW>;<SMALL>;IGNORE
-<U0166> <U0054>;<STROKE>;<CAPITAL>;IGNORE
-<U0167> <U0054>;<STROKE>;<SMALL>;IGNORE
-<U0162> <U0054>;<CEDILLA>;<CAPITAL>;IGNORE
-<U0163> <U0054>;<CEDILLA>;<SMALL>;IGNORE
-<U1E70> <U0054>;<MACRON+CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U1E71> <U0054>;<MACRON+CIRCUMFLEX>;<SMALL>;IGNORE
-<U1E6E> <U0054>;<LINE-BELOW>;<CAPITAL>;IGNORE
-<U1E6F> <U0054>;<LINE-BELOW>;<SMALL>;IGNORE
-<t8>
-<U00DE> "<U0054><U0048>";"<U00DE><U00DE>";"<CAPITAL><CAPITAL>";IGNORE
-<U00FE> "<U0054><U0048>";"<U00DE><U00DE>";"<SMALL><SMALL>";IGNORE
-<U0055> <U0055>;<NONE>;<CAPITAL>;IGNORE
-<U0075> <U0055>;<NONE>;<SMALL>;IGNORE
-<U00DA> <U0055>;<ACUTE>;<CAPITAL>;IGNORE
-<U00FA> <U0055>;<ACUTE>;<SMALL>;IGNORE
-<U00D9> <U0055>;<GRAVE>;<CAPITAL>;IGNORE
-<U00F9> <U0055>;<GRAVE>;<SMALL>;IGNORE
-<U0214> <U0055>;<DOUBLE-GRAVE>;<CAPITAL>;IGNORE
-<U0215> <U0055>;<DOUBLE-GRAVE>;<SMALL>;IGNORE
-<U016C> <U0055>;<BREVE>;<CAPITAL>;IGNORE
-<U016D> <U0055>;<BREVE>;<SMALL>;IGNORE
-<U0216> <U0055>;<INVERTED-BREVE>;<CAPITAL>;IGNORE
-<U0217> <U0055>;<INVERTED-BREVE>;<SMALL>;IGNORE
-<U00DB> <U0055>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U00FB> <U0055>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U01D3> <U0055>;<CARON>;<CAPITAL>;IGNORE
-<U01D4> <U0055>;<CARON>;<SMALL>;IGNORE
-<U016E> <U0055>;<RING>;<CAPITAL>;IGNORE
-<U016F> <U0055>;<RING>;<SMALL>;IGNORE
-<U00DC> <U0055>;<DIAERESIS>;<CAPITAL>;IGNORE
-<U00FC> <U0055>;<DIAERESIS>;<SMALL>;IGNORE
-<U01D5> <U0055>;<DIAERESIS+MACRON>;<CAPITAL>;IGNORE
-<U01D6> <U0055>;<DIAERESIS+MACRON>;<SMALL>;IGNORE
-<U01D7> <U0055>;<DIAERESIS+ACUTE>;<CAPITAL>;IGNORE
-<U01D8> <U0055>;<DIAERESIS+ACUTE>;<SMALL>;IGNORE
-<U01DB> <U0055>;<DIAERESIS+GRAVE>;<CAPITAL>;IGNORE
-<U01DC> <U0055>;<DIAERESIS+GRAVE>;<SMALL>;IGNORE
-<U01D9> <U0055>;<DIAERESIS+CARON>;<CAPITAL>;IGNORE
-<U01DA> <U0055>;<DIAERESIS+CARON>;<SMALL>;IGNORE
-<U0170> <U0055>;<DOUBLE-ACUTE>;<CAPITAL>;IGNORE
-<U0171> <U0055>;<DOUBLE-ACUTE>;<SMALL>;IGNORE
-<U1EE6> <U0055>;<HOOK>;<CAPITAL>;IGNORE
-<U1EE7> <U0055>;<HOOK>;<SMALL>;IGNORE
-<U0168> <U0055>;<TILDE>;<CAPITAL>;IGNORE
-<U0169> <U0055>;<TILDE>;<SMALL>;IGNORE
-<U1E78> <U0055>;<TILDE+ACUTE>;<CAPITAL>;IGNORE
-<U1E79> <U0055>;<TILDE+ACUTE>;<SMALL>;IGNORE
-<U1E74> <U0055>;<TILDE-BELOW>;<CAPITAL>;IGNORE
-<U1E75> <U0055>;<TILDE-BELOW>;<SMALL>;IGNORE
-<U1EE4> <U0055>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1EE5> <U0055>;<DOT-BELOW>;<SMALL>;IGNORE
-<U0172> <U0055>;<OGONEK>;<CAPITAL>;IGNORE
-<U0173> <U0055>;<OGONEK>;<SMALL>;IGNORE
-<U016A> <U0055>;<MACRON>;<CAPITAL>;IGNORE
-<U016B> <U0055>;<MACRON>;<SMALL>;IGNORE
-<U1E7A> <U0055>;<MACRON+DIAERESIS>;<CAPITAL>;IGNORE
-<U1E7B> <U0055>;<MACRON+DIAERESIS>;<SMALL>;IGNORE
-<U1E72> <U0055>;<MACRON+DIAERESIS-BELOW>;<CAPITAL>;IGNORE
-<U1E73> <U0055>;<MACRON+DIAERESIS-BELOW>;<SMALL>;IGNORE
-<U1E76> <U0055>;<MACRON+CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U1E77> <U0055>;<MACRON+CIRCUMFLEX>;<SMALL>;IGNORE
-<U01AF> <U0055>;<HORN>;<CAPITAL>;IGNORE
-<U01B0> <U0055>;<HORN>;<SMALL>;IGNORE
-<U1EE8> <U0055>;<HORN+ACUTE>;<CAPITAL>;IGNORE
-<U1EE9> <U0055>;<HORN+ACUTE>;<SMALL>;IGNORE
-<U1EEA> <U0055>;<HORN+GRAVE>;<CAPITAL>;IGNORE
-<U1EEB> <U0055>;<HORN+GRAVE>;<SMALL>;IGNORE
-<U1EEC> <U0055>;<HORN+HOOK>;<CAPITAL>;IGNORE
-<U1EED> <U0055>;<HORN+HOOK>;<SMALL>;IGNORE
-<U1EEE> <U0055>;<HORN+TILDE>;<CAPITAL>;IGNORE
-<U1EEF> <U0055>;<HORN+TILDE>;<SMALL>;IGNORE
-<U1EF0> <U0055>;<HORN+DOT-BELOW>;<CAPITAL>;IGNORE
-<U1EF1> <U0055>;<HORN+DOT-BELOW>;<SMALL>;IGNORE
-<u8>
-<U0056> <U0056>;<NONE>;<CAPITAL>;IGNORE
-<U0076> <U0056>;<NONE>;<SMALL>;IGNORE
-<U1E7C> <U0056>;<TILDE>;<CAPITAL>;IGNORE
-<U1E7D> <U0056>;<TILDE>;<SMALL>;IGNORE
-<U1E7E> <U0056>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E7F> <U0056>;<DOT-BELOW>;<SMALL>;IGNORE
-<v8>
-<U0057> <U0057>;<NONE>;<CAPITAL>;IGNORE
-<U0077> <U0057>;<NONE>;<SMALL>;IGNORE
-<U1E82> <U0057>;<ACUTE>;<CAPITAL>;IGNORE
-<U1E83> <U0057>;<ACUTE>;<SMALL>;IGNORE
-<U1E80> <U0057>;<GRAVE>;<CAPITAL>;IGNORE
-<U1E81> <U0057>;<GRAVE>;<SMALL>;IGNORE
-<U0174> <U0057>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U0175> <U0057>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U1E84> <U0057>;<DIAERESIS>;<CAPITAL>;IGNORE
-<U1E85> <U0057>;<DIAERESIS>;<SMALL>;IGNORE
-<U1E86> <U0057>;<DOT>;<CAPITAL>;IGNORE
-<U1E87> <U0057>;<DOT>;<SMALL>;IGNORE
-<U1E88> <U0057>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E89> <U0057>;<DOT-BELOW>;<SMALL>;IGNORE
-<w8>
-<U0058> <U0058>;<NONE>;<CAPITAL>;IGNORE
-<U0078> <U0058>;<NONE>;<SMALL>;IGNORE
-<U1E8C> <U0058>;<DIAERESIS>;<CAPITAL>;IGNORE
-<U1E8D> <U0058>;<DIAERESIS>;<SMALL>;IGNORE
-<U1E8A> <U0058>;<DOT>;<CAPITAL>;IGNORE
-<U1E8B> <U0058>;<DOT>;<SMALL>;IGNORE
-<x8>
-<U0059> <U0059>;<NONE>;<CAPITAL>;IGNORE
-<U0079> <U0059>;<NONE>;<SMALL>;IGNORE
-<U00DD> <U0059>;<ACUTE>;<CAPITAL>;IGNORE
-<U00FD> <U0059>;<ACUTE>;<SMALL>;IGNORE
-<U1EF2> <U0059>;<GRAVE>;<CAPITAL>;IGNORE
-<U1EF3> <U0059>;<GRAVE>;<SMALL>;IGNORE
-<U0176> <U0059>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U0177> <U0059>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U0178> <U0059>;<DIAERESIS>;<CAPITAL>;IGNORE
-<U00FF> <U0059>;<DIAERESIS>;<SMALL>;IGNORE
-<U1EF6> <U0059>;<HOOK>;<CAPITAL>;IGNORE
-<U1EF7> <U0059>;<HOOK>;<SMALL>;IGNORE
-<U1EF8> <U0059>;<TILDE>;<CAPITAL>;IGNORE
-<U1EF9> <U0059>;<TILDE>;<SMALL>;IGNORE
-<U1E8E> <U0059>;<DOT>;<CAPITAL>;IGNORE
-<U1E8F> <U0059>;<DOT>;<SMALL>;IGNORE
-<U1EF4> <U0059>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1EF5> <U0059>;<DOT-BELOW>;<SMALL>;IGNORE
-<y8>
-<U005A> <U005A>;<NONE>;<CAPITAL>;IGNORE
-<U007A> <U005A>;<NONE>;<SMALL>;IGNORE
-<U0179> <U005A>;<ACUTE>;<CAPITAL>;IGNORE
-<U017A> <U005A>;<ACUTE>;<SMALL>;IGNORE
-<U1E90> <U005A>;<CIRCUMFLEX>;<CAPITAL>;IGNORE
-<U1E91> <U005A>;<CIRCUMFLEX>;<SMALL>;IGNORE
-<U017D> <U005A>;<CARON>;<CAPITAL>;IGNORE
-<U017E> <U005A>;<CARON>;<SMALL>;IGNORE
-<U017B> <U005A>;<DOT>;<CAPITAL>;IGNORE
-<U017C> <U005A>;<DOT>;<SMALL>;IGNORE
-<U1E92> <U005A>;<DOT-BELOW>;<CAPITAL>;IGNORE
-<U1E93> <U005A>;<DOT-BELOW>;<SMALL>;IGNORE
-<U01B5> <U005A>;<STROKE>;<CAPITAL>;IGNORE
-<U01B6> <U005A>;<STROKE>;<SMALL>;IGNORE
-<U1E94> <U005A>;<LINE-BELOW>;<CAPITAL>;IGNORE
-<U1E95> <U005A>;<LINE-BELOW>;<SMALL>;IGNORE
-<z8>
-<U0391> <U0391>;<CAPITAL>;<GREEK>;IGNORE
-<U0386> <U0391>;<CAPITAL>;<TONOS>;IGNORE
-<U03B1> <U0391>;<SMALL>;<GREEK>;IGNORE
-<U03AC> <U0391>;<SMALL>;<TONOS>;IGNORE
-<U0392> <U0392>;<CAPITAL>;<GREEK>;IGNORE
-<U03B2> <U0392>;<SMALL>;<GREEK>;IGNORE
-<U0393> <U0393>;<CAPITAL>;<GREEK>;IGNORE
-<U03B3> <U0393>;<SMALL>;<GREEK>;IGNORE
-<U0394> <U0394>;<CAPITAL>;<GREEK>;IGNORE
-<U03B4> <U0394>;<SMALL>;<GREEK>;IGNORE
-<U0395> <U0395>;<CAPITAL>;<GREEK>;IGNORE
-<U0388> <U0395>;<CAPITAL>;<TONOS>;IGNORE
-<U03B5> <U0395>;<SMALL>;<GREEK>;IGNORE
-<U03AD> <U0395>;<SMALL>;<TONOS>;IGNORE
-<U0396> <U0396>;<CAPITAL>;<GREEK>;IGNORE
-<U03B6> <U0396>;<SMALL>;<GREEK>;IGNORE
-<U0397> <U0397>;<CAPITAL>;<GREEK>;IGNORE
-<U0389> <U0397>;<CAPITAL>;<TONOS>;IGNORE
-<U03B7> <U0397>;<SMALL>;<GREEK>;IGNORE
-<U03AE> <U0397>;<SMALL>;<TONOS>;IGNORE
-<U0398> <U0398>;<CAPITAL>;<GREEK>;IGNORE
-<U03B8> <U0398>;<SMALL>;<GREEK>;IGNORE
-<U0399> <U0399>;<CAPITAL>;<GREEK>;IGNORE
-<U038A> <U0399>;<CAPITAL>;<TONOS>;IGNORE
-<U03AA> <U0399>;<CAPITAL>;<DIALYTICA>;IGNORE
-<U03B9> <U0399>;<SMALL>;<GREEK>;IGNORE
-<U03AF> <U0399>;<SMALL>;<TONOS>;IGNORE
-<U03CA> <U0399>;<SMALL>;<DIALYTICA>;IGNORE
-<U0390> <U0399>;<SMALL>;<DIALYTICA+TONOS>;IGNORE
-<U039A> <U039A>;<CAPITAL>;<GREEK>;IGNORE
-<U03BA> <U039A>;<SMALL>;<GREEK>;IGNORE
-<U039B> <U039B>;<CAPITAL>;<GREEK>;IGNORE
-<U03BB> <U039B>;<SMALL>;<GREEK>;IGNORE
-<U039C> <U039C>;<CAPITAL>;<GREEK>;IGNORE
-<U03BC> <U039C>;<SMALL>;<GREEK>;IGNORE
-<U039D> <U039D>;<CAPITAL>;<GREEK>;IGNORE
-<U03BD> <U039D>;<SMALL>;<GREEK>;IGNORE
-<U039E> <U039E>;<CAPITAL>;<GREEK>;IGNORE
-<U03BE> <U039E>;<SMALL>;<GREEK>;IGNORE
-<U039F> <U039F>;<CAPITAL>;<GREEK>;IGNORE
-<U038C> <U039F>;<CAPITAL>;<TONOS>;IGNORE
-<U03BF> <U039F>;<SMALL>;<GREEK>;IGNORE
-<U03CC> <U039F>;<SMALL>;<TONOS>;IGNORE
-<U03A0> <U03A0>;<CAPITAL>;<GREEK>;IGNORE
-<U03C0> <U03A0>;<SMALL>;<GREEK>;IGNORE
-<U03A1> <U03A1>;<CAPITAL>;<GREEK>;IGNORE
-<U03C1> <U03A1>;<SMALL>;<GREEK>;IGNORE
-<U03A3> <U03A3>;<CAPITAL>;<GREEK>;IGNORE
-<U03C3> <U03A3>;<SMALL>;<GREEK>;IGNORE
-<U03C2> <U03A3>;<SMALL>;<U03C2>;IGNORE
-<U03A4> <U03A4>;<CAPITAL>;<GREEK>;IGNORE
-<U03C4> <U03A4>;<SMALL>;<GREEK>;IGNORE
-<U03A5> <U03A5>;<CAPITAL>;<GREEK>;IGNORE
-<U038E> <U03A5>;<CAPITAL>;<TONOS>;IGNORE
-<U03AB> <U03A5>;<CAPITAL>;<DIALYTICA>;IGNORE
-<U03C5> <U03A5>;<SMALL>;<GREEK>;IGNORE
-<U03CD> <U03A5>;<SMALL>;<TONOS>;IGNORE
-<U03CB> <U03A5>;<SMALL>;<DIALYTICA>;IGNORE
-<U03B0> <U03A5>;<SMALL>;<DIALYTICA+TONOS>;IGNORE
-<U03A6> <U03A6>;<CAPITAL>;<GREEK>;IGNORE
-<U03C6> <U03A6>;<SMALL>;<GREEK>;IGNORE
-<U03A7> <U03A7>;<CAPITAL>;<GREEK>;IGNORE
-<U03C7> <U03A7>;<SMALL>;<GREEK>;IGNORE
-<U03A8> <U03A8>;<CAPITAL>;<GREEK>;IGNORE
-<U03C8> <U03A8>;<SMALL>;<GREEK>;IGNORE
-<U03A9> <U03A9>;<CAPITAL>;<GREEK>;IGNORE
-<U038F> <U03A9>;<CAPITAL>;<TONOS>;IGNORE
-<U03C9> <U03A9>;<SMALL>;<GREEK>;IGNORE
-<U03CE> <U03A9>;<SMALL>;<TONOS>;IGNORE
-<U0410> <U0410>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0430> <U0410>;<CYRILLIC>;<SMALL>;IGNORE
-<U0411> <U0411>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0431> <U0411>;<CYRILLIC>;<SMALL>;IGNORE
-<U0412> <U0412>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0432> <U0412>;<CYRILLIC>;<SMALL>;IGNORE
-<U0413> <U0413>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0433> <U0413>;<CYRILLIC>;<SMALL>;IGNORE
-<U0403> <U0403>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0453> <U0403>;<CYRILLIC>;<SMALL>;IGNORE
-<U0490> <U0490>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0491> <U0490>;<CYRILLIC>;<SMALL>;IGNORE
-<U0414> <U0414>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0434> <U0414>;<CYRILLIC>;<SMALL>;IGNORE
-<U0402> <U0402>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0452> <U0402>;<CYRILLIC>;<SMALL>;IGNORE
-<U0415> <U0415>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0435> <U0415>;<CYRILLIC>;<SMALL>;IGNORE
-<U0401> <U0401>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0451> <U0401>;<CYRILLIC>;<SMALL>;IGNORE
-<U0404> <U0404>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0454> <U0404>;<CYRILLIC>;<SMALL>;IGNORE
-<U0416> <U0416>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0436> <U0416>;<CYRILLIC>;<SMALL>;IGNORE
-<U0417> <U0417>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0437> <U0417>;<CYRILLIC>;<SMALL>;IGNORE
-<U0418> <U0418>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0438> <U0418>;<CYRILLIC>;<SMALL>;IGNORE
-<U0406> <U0406>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0456> <U0406>;<CYRILLIC>;<SMALL>;IGNORE
-<U0407> <U0407>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0457> <U0407>;<CYRILLIC>;<SMALL>;IGNORE
-<U0408> <U0408>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0458> <U0408>;<CYRILLIC>;<SMALL>;IGNORE
-<U0419> <U0419>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0439> <U0419>;<CYRILLIC>;<SMALL>;IGNORE
-<U041A> <U041A>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U043A> <U041A>;<CYRILLIC>;<SMALL>;IGNORE
-<U040C> <U040C>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U045C> <U040C>;<CYRILLIC>;<SMALL>;IGNORE
-<U041B> <U041B>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U043B> <U041B>;<CYRILLIC>;<SMALL>;IGNORE
-<U0409> <U0409>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0459> <U0409>;<CYRILLIC>;<SMALL>;IGNORE
-<U041C> <U041C>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U043C> <U041C>;<CYRILLIC>;<SMALL>;IGNORE
-<U041D> <U041D>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U043D> <U041D>;<CYRILLIC>;<SMALL>;IGNORE
-<U040A> <U040A>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U045A> <U040A>;<CYRILLIC>;<SMALL>;IGNORE
-<U041E> <U041E>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U043E> <U041E>;<CYRILLIC>;<SMALL>;IGNORE
-<U041F> <U041F>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U043F> <U041F>;<CYRILLIC>;<SMALL>;IGNORE
-<U0420> <U0420>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0440> <U0420>;<CYRILLIC>;<SMALL>;IGNORE
-<U0421> <U0421>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0441> <U0421>;<CYRILLIC>;<SMALL>;IGNORE
-<U0422> <U0422>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0442> <U0422>;<CYRILLIC>;<SMALL>;IGNORE
-<U040B> <U040B>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U045B> <U040B>;<CYRILLIC>;<SMALL>;IGNORE
-<U0423> <U0423>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0443> <U0423>;<CYRILLIC>;<SMALL>;IGNORE
-<U040E> <U040E>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U045E> <U040E>;<CYRILLIC>;<SMALL>;IGNORE
-<U0424> <U0424>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0444> <U0424>;<CYRILLIC>;<SMALL>;IGNORE
-<U0425> <U0425>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0445> <U0425>;<CYRILLIC>;<SMALL>;IGNORE
-<U0426> <U0426>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0446> <U0426>;<CYRILLIC>;<SMALL>;IGNORE
-<U0405> <U0405>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0455> <U0405>;<CYRILLIC>;<SMALL>;IGNORE
-<U0427> <U0427>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0447> <U0427>;<CYRILLIC>;<SMALL>;IGNORE
-<U040F> <U040F>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U045F> <U040F>;<CYRILLIC>;<SMALL>;IGNORE
-<U0428> <U0428>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0448> <U0428>;<CYRILLIC>;<SMALL>;IGNORE
-<U0429> <U0429>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0449> <U0429>;<CYRILLIC>;<SMALL>;IGNORE
-<U044A> <U044A>;<CYRILLIC>;<SMALL>;IGNORE
-<U042A> <U044A>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U042B> <U042B>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U044B> <U042B>;<CYRILLIC>;<SMALL>;IGNORE
-<U044C> <U044C>;<CYRILLIC>;<SMALL>;IGNORE
-<U042C> <U044C>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U042D> <U042D>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U044D> <U042D>;<CYRILLIC>;<SMALL>;IGNORE
-<U042E> <U042E>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U044E> <U042E>;<CYRILLIC>;<SMALL>;IGNORE
-<U042F> <U042F>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U044F> <U042F>;<CYRILLIC>;<SMALL>;IGNORE
-<U0462> <U0462>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0463> <U0462>;<CYRILLIC>;<SMALL>;IGNORE
-<U046A> <U046A>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U046B> <U046A>;<CYRILLIC>;<SMALL>;IGNORE
-<U0472> <U0472>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0473> <U0472>;<CYRILLIC>;<SMALL>;IGNORE
-<U0474> <U0474>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0475> <U0474>;<CYRILLIC>;<SMALL>;IGNORE
-<U0480> <U0480>;<CYRILLIC>;<CAPITAL>;IGNORE
-<U0481> <U0480>;<CYRILLIC>;<SMALL>;IGNORE
-<U05D0> <U05D0>;IGNORE;IGNORE;IGNORE
-<U05D1> <U05D1>;IGNORE;IGNORE;IGNORE
-<U05D2> <U05D2>;IGNORE;IGNORE;IGNORE
-<U05D3> <U05D3>;IGNORE;IGNORE;IGNORE
-<U05D4> <U05D4>;IGNORE;IGNORE;IGNORE
-<U05D5> <U05D5>;IGNORE;IGNORE;IGNORE
-<U05D6> <U05D6>;IGNORE;IGNORE;IGNORE
-<U05D7> <U05D7>;IGNORE;IGNORE;IGNORE
-<U05D8> <U05D8>;IGNORE;IGNORE;IGNORE
-<U05D9> <U05D9>;IGNORE;IGNORE;IGNORE
-<U05DA> <U05DA>;IGNORE;IGNORE;IGNORE
-<U05DB> <U05DB>;IGNORE;IGNORE;IGNORE
-<U05DC> <U05DC>;IGNORE;IGNORE;IGNORE
-<U05DD> <U05DD>;IGNORE;IGNORE;IGNORE
-<U05DE> <U05DE>;IGNORE;IGNORE;IGNORE
-<U05DF> <U05DF>;IGNORE;IGNORE;IGNORE
-<U05E0> <U05E0>;IGNORE;IGNORE;IGNORE
-<U05E1> <U05E1>;IGNORE;IGNORE;IGNORE
-<U05E2> <U05E2>;IGNORE;IGNORE;IGNORE
-<U05E3> <U05E3>;IGNORE;IGNORE;IGNORE
-<U05E4> <U05E4>;IGNORE;IGNORE;IGNORE
-<U05E5> <U05E5>;IGNORE;IGNORE;IGNORE
-<U05E6> <U05E6>;IGNORE;IGNORE;IGNORE
-<U05E7> <U05E7>;IGNORE;IGNORE;IGNORE
-<U05E8> <U05E8>;IGNORE;IGNORE;IGNORE
-<U05E9> <U05E9>;IGNORE;IGNORE;IGNORE
-<U05EA> <U05EA>;IGNORE;IGNORE;IGNORE
-
-% Arabic collating
-
-<U060C> IGNORE;IGNORE;IGNORE;<U060C>
-<U061B> IGNORE;IGNORE;IGNORE;<U061B>
-<U061F> IGNORE;IGNORE;IGNORE;<U061F>
-<U0640> IGNORE;IGNORE;IGNORE;<U0640>
-
-<U0621> <U0621>;<U0621>;IGNORE;IGNORE
-<U0622> <U0622>;<U0622>;IGNORE;IGNORE
-<UFE82> <U0622>;<UFE82>;IGNORE;IGNORE
-<U0623> <U0621>;<U0623>;IGNORE;IGNORE
-<UFE84> <U0621>;<UFE84>;IGNORE;IGNORE
-<U0624> <U0621>;<U0624>;IGNORE;IGNORE
-<U0625> <U0621>;<U0625>;IGNORE;IGNORE
-<UFE88> <U0621>;<UFE88>;IGNORE;IGNORE
-<U0626> <U0621>;<U0626>;IGNORE;IGNORE
-<U0670> <U0670>;<U0670>;IGNORE;IGNORE
-<U0627> <U0627>;<U0627>;IGNORE;IGNORE
-<UFE8D> <U0627>;<UFE8D>;IGNORE;IGNORE
-<UFE8E> <U0627>;<UFE8E>;IGNORE;IGNORE
-<UE016> <U0627>;<UE016>;IGNORE;IGNORE
-<U0628> <U0628>;<U0628>;IGNORE;IGNORE
-<UFE8F> <U0628>;<UFE8F>;IGNORE;IGNORE
-<UFE90> <U0628>;<UFE90>;IGNORE;IGNORE
-<UFE91> <U0628>;<UFE91>;IGNORE;IGNORE
-<UFE92> <U0628>;<UFE92>;IGNORE;IGNORE
-<U067E> <U067E>;<U067E>;IGNORE;IGNORE
-<U06A4> <U06A4>;<U06A4>;IGNORE;IGNORE
-<U0629> <U0629>;<U0629>;IGNORE;IGNORE
-<UFE93> <U0629>;<UFE93>;IGNORE;IGNORE
-<UFE94> <U0629>;<UFE94>;IGNORE;IGNORE
-<U062A> <U0629>;<U062A>;IGNORE;IGNORE
-<UFE95> <U0629>;<UFE95>;IGNORE;IGNORE
-<UFE96> <U0629>;<UFE96>;IGNORE;IGNORE
-<UFE97> <U0629>;<UFE97>;IGNORE;IGNORE
-<UFE98> <U0629>;<UFE98>;IGNORE;IGNORE
-<U062B> <U062B>;<U062B>;IGNORE;IGNORE
-<UFE99> <U062B>;<UFE99>;IGNORE;IGNORE
-<UFE9A> <U062B>;<UFE9A>;IGNORE;IGNORE
-<UFE9B> <U062B>;<UFE9B>;IGNORE;IGNORE
-<UFE9C> <U062B>;<UFE9C>;IGNORE;IGNORE
-<U062C> <U062C>;<U062C>;IGNORE;IGNORE
-<UFE9D> <U062C>;<UFE9D>;IGNORE;IGNORE
-<UFE9E> <U062C>;<UFE9E>;IGNORE;IGNORE
-<UFE9F> <U062C>;<UFE9F>;IGNORE;IGNORE
-<UFEA0> <U062C>;<UFEA0>;IGNORE;IGNORE
-<U062D> <U062D>;<U062D>;IGNORE;IGNORE
-<UFEA1> <U062D>;<UFEA1>;IGNORE;IGNORE
-<UFEA2> <U062D>;<UFEA2>;IGNORE;IGNORE
-<UFEA3> <U062D>;<UFEA3>;IGNORE;IGNORE
-<UFEA4> <U062D>;<UFEA4>;IGNORE;IGNORE
-<U062E> <U062E>;<U062E>;IGNORE;IGNORE
-<UFEA5> <U062E>;<UFEA5>;IGNORE;IGNORE
-<UFEA6> <U062E>;<UFEA6>;IGNORE;IGNORE
-<UFEA7> <U062E>;<UFEA7>;IGNORE;IGNORE
-<UFEA8> <U062E>;<UFEA8>;IGNORE;IGNORE
-<U062F> <U062F>;<U062F>;IGNORE;IGNORE
-<UFEA9> <U062F>;<UFEA9>;IGNORE;IGNORE
-<UFEAA> <U062F>;<UFEAA>;IGNORE;IGNORE
-<U0630> <U0630>;<U0630>;IGNORE;IGNORE
-<UFEAB> <U0630>;<UFEAB>;IGNORE;IGNORE
-<UFEAC> <U0630>;<UFEAC>;IGNORE;IGNORE
-<U0631> <U0631>;<U0631>;IGNORE;IGNORE
-<UFEAD> <U0631>;<UFEAD>;IGNORE;IGNORE
-<UFEAE> <U0631>;<UFEAE>;IGNORE;IGNORE
-<U0632> <U0632>;<U0632>;IGNORE;IGNORE
-<UFEAF> <U0632>;<UFEAF>;IGNORE;IGNORE
-<UFEB0> <U0632>;<UFEB0>;IGNORE;IGNORE
-<U0633> <U0633>;<U0633>;IGNORE;IGNORE
-<UFEB1> <U0633>;<UFEB1>;IGNORE;IGNORE
-<UFEB2> <U0633>;<UFEB2>;IGNORE;IGNORE
-<UFEB3> <U0633>;<UFEB3>;IGNORE;IGNORE
-<UFEB4> <U0633>;<UFEB4>;IGNORE;IGNORE
-<U0634> <U0634>;<U0634>;IGNORE;IGNORE
-<UFEB5> <U0634>;<UFEB5>;IGNORE;IGNORE
-<UFEB6> <U0634>;<UFEB6>;IGNORE;IGNORE
-<UFEB7> <U0634>;<UFEB7>;IGNORE;IGNORE
-<UFEB8> <U0634>;<UFEB8>;IGNORE;IGNORE
-<U0635> <U0635>;<U0635>;IGNORE;IGNORE
-<UFEB9> <U0635>;<UFEB9>;IGNORE;IGNORE
-<UFEBA> <U0635>;<UFEBA>;IGNORE;IGNORE
-<UFEBB> <U0635>;<UFEBB>;IGNORE;IGNORE
-<UFEBC> <U0635>;<UFEBC>;IGNORE;IGNORE
-<U0636> <U0636>;<U0636>;IGNORE;IGNORE
-<UFEBD> <U0636>;<UFEBD>;IGNORE;IGNORE
-<UFEBE> <U0636>;<UFEBE>;IGNORE;IGNORE
-<UFEBF> <U0636>;<UFEBF>;IGNORE;IGNORE
-<UFEC0> <U0636>;<UFEC0>;IGNORE;IGNORE
-<U0637> <U0637>;<U0637>;IGNORE;IGNORE
-<UFEC1> <U0637>;<UFEC1>;IGNORE;IGNORE
-<UFEC2> <U0637>;<UFEC2>;IGNORE;IGNORE
-<UFEC3> <U0637>;<UFEC3>;IGNORE;IGNORE
-<UFEC4> <U0637>;<UFEC4>;IGNORE;IGNORE
-<U0638> <U0638>;<U0638>;IGNORE;IGNORE
-<UFEC5> <U0638>;<UFEC5>;IGNORE;IGNORE
-<UFEC6> <U0638>;<UFEC6>;IGNORE;IGNORE
-<UFEC7> <U0638>;<UFEC7>;IGNORE;IGNORE
-<UFEC8> <U0638>;<UFEC8>;IGNORE;IGNORE
-<U0639> <U0639>;<U0639>;IGNORE;IGNORE
-<UFEC9> <U0639>;<UFEC9>;IGNORE;IGNORE
-<UFECA> <U0639>;<UFECA>;IGNORE;IGNORE
-<UFECB> <U0639>;<UFECB>;IGNORE;IGNORE
-<UFECC> <U0639>;<UFECC>;IGNORE;IGNORE
-<U063A> <U063A>;<U063A>;IGNORE;IGNORE
-<UFECD> <U063A>;<UFECD>;IGNORE;IGNORE
-<UFECE> <U063A>;<UFECE>;IGNORE;IGNORE
-<UFECF> <U063A>;<UFECF>;IGNORE;IGNORE
-<UFED0> <U063A>;<UFED0>;IGNORE;IGNORE
-<U0641> <U0641>;<U0641>;IGNORE;IGNORE
-<UFED1> <U0641>;<UFED1>;IGNORE;IGNORE
-<UFED2> <U0641>;<UFED2>;IGNORE;IGNORE
-<UFED3> <U0641>;<UFED3>;IGNORE;IGNORE
-<UFED4> <U0641>;<UFED4>;IGNORE;IGNORE
-<U0642> <U0642>;<U0642>;IGNORE;IGNORE
-<UFED5> <U0642>;<UFED5>;IGNORE;IGNORE
-<UFED6> <U0642>;<UFED6>;IGNORE;IGNORE
-<UFED7> <U0642>;<UFED7>;IGNORE;IGNORE
-<UFED8> <U0642>;<UFED8>;IGNORE;IGNORE
-<U0643> <U0643>;<U0643>;IGNORE;IGNORE
-<UFED9> <U0643>;<UFED9>;IGNORE;IGNORE
-<UFEDA> <U0643>;<UFEDA>;IGNORE;IGNORE
-<UFEDB> <U0643>;<UFEDB>;IGNORE;IGNORE
-<UFEDC> <U0643>;<UFEDC>;IGNORE;IGNORE
-<U0644> <U0644>;<U0644>;IGNORE;IGNORE
-<UFEDD> <U0644>;<UFEDD>;IGNORE;IGNORE
-<UFEDE> <U0644>;<UFEDE>;IGNORE;IGNORE
-<UFEDF> <U0644>;<UFEDF>;IGNORE;IGNORE
-<UFEE0> <U0644>;<UFEE0>;IGNORE;IGNORE
-<U0645> <U0645>;<U0645>;IGNORE;IGNORE
-<UFEE1> <U0645>;<UFEE1>;IGNORE;IGNORE
-<UFEE2> <U0645>;<UFEE2>;IGNORE;IGNORE
-<UFEE3> <U0645>;<UFEE3>;IGNORE;IGNORE
-<UFEE4> <U0645>;<UFEE4>;IGNORE;IGNORE
-<U0646> <U0646>;<U0646>;IGNORE;IGNORE
-<UFEE5> <U0646>;<UFEE5>;IGNORE;IGNORE
-<UFEE6> <U0646>;<UFEE6>;IGNORE;IGNORE
-<UFEE7> <U0646>;<UFEE7>;IGNORE;IGNORE
-<UFEE8> <U0646>;<UFEE8>;IGNORE;IGNORE
-<U0647> <U0647>;<U0647>;IGNORE;IGNORE
-<UFEE9> <U0647>;<UFEE9>;IGNORE;IGNORE
-<UFEEA> <U0647>;<UFEEA>;IGNORE;IGNORE
-<UFEEB> <U0647>;<UFEEB>;IGNORE;IGNORE
-<UFEEC> <U0647>;<UFEEC>;IGNORE;IGNORE
-<U0648> <U0648>;<U0648>;IGNORE;IGNORE
-<UFEED> <U0648>;<UFEED>;IGNORE;IGNORE
-<UFEEE> <U0648>;<UFEEE>;IGNORE;IGNORE
-<U0649> <U0649>;<U0649>;IGNORE;IGNORE
-<UFEEF> <U0649>;<UFEEF>;IGNORE;IGNORE
-<UFEF0> <U0649>;<UFEF0>;IGNORE;IGNORE
-<U064A> <U064A>;<U064A>;IGNORE;IGNORE
-<UFEF1> <U064A>;<UFEF1>;IGNORE;IGNORE
-<UFEF2> <U064A>;<UFEF2>;IGNORE;IGNORE
-<UFEF3> <U064A>;<UFEF3>;IGNORE;IGNORE
-<UFEF4> <U064A>;<UFEF4>;IGNORE;IGNORE
-
-<U064B> IGNORE;IGNORE;<U064B>;IGNORE
-<U064C> IGNORE;IGNORE;<U064C>;IGNORE
-<U064D> IGNORE;IGNORE;<U064D>;IGNORE
-<U064E> IGNORE;IGNORE;<U064E>;IGNORE
-<U064F> IGNORE;IGNORE;<U064F>;IGNORE
-<U0650> IGNORE;IGNORE;<U0650>;IGNORE
-<U0651> IGNORE;IGNORE;<U0651>;IGNORE
-<UFE7D> IGNORE;IGNORE;<UFE7D>;IGNORE
-<U0652> IGNORE;IGNORE;<U0652>;IGNORE
-
-<U0660> <U0030>;<U0660>;IGNORE;IGNORE
-<U0661> <U0031>;<U0661>;IGNORE;IGNORE
-<U0662> <U0032>;<U0662>;IGNORE;IGNORE
-<U0663> <U0033>;<U0663>;IGNORE;IGNORE
-<U0664> <U0034>;<U0664>;IGNORE;IGNORE
-<U0665> <U0035>;<U0665>;IGNORE;IGNORE
-<U0666> <U0036>;<U0666>;IGNORE;IGNORE
-<U0667> <U0037>;<U0667>;IGNORE;IGNORE
-<U0668> <U0038>;<U0668>;IGNORE;IGNORE
-<U0669> <U0039>;<U0669>;IGNORE;IGNORE
-
-<UFEF5> "<U0644><U0622>";"<U0644><U0622>";"<UFEF5><UFEF5>";IGNORE
-<UFEF6> "<U0644><U0622>";"<U0644><UFE82>";"<UFEF6><UFEF6>";IGNORE
-<UFEF7> "<U0644><U0623>";"<U0644><U0623>";"<UFEF7><UFEF7>";IGNORE
-<UFEF8> "<U0644><U0623>";"<U0644><UFE84>";"<UFEF8><UFEF8>";IGNORE
-<UFEF9> "<U0644><U0625>";"<U0644><U0625>";"<UFEF9><UFEF9>";IGNORE
-<UFEFA> "<U0644><U0625>";"<U0644><UFE88>";"<UFEFA><UFEFA>";IGNORE
-<UFEFB> "<U0644><U0627>";"<U0644><UFE8D>";"<UFEFB><UFEFB>";IGNORE
-<UFEFC> "<U0644><U0627>";"<U0644><UFE8E>";"<UFEFC><UFEFC>";IGNORE
-
-% katakana/hiragana sorting
-% base is katakana, as this is present in most charsets
-% normal before voiced before semi-voiced
-% small vocals before normal vocals
-% katakana before hiragana
-
-<U30A1> <U30A1>;<U30A1>;IGNORE;IGNORE
-<U3041> <U30A1>;<U3041>;IGNORE;IGNORE
-<U30A2> <U30A1>;<U30A2>;IGNORE;IGNORE
-<U3042> <U30A1>;<U3042>;IGNORE;IGNORE
-<U30A3> <U30A3>;<U30A3>;IGNORE;IGNORE
-<U3043> <U30A3>;<U3043>;IGNORE;IGNORE
-<U30A4> <U30A3>;<U30A4>;IGNORE;IGNORE
-<U3044> <U30A3>;<U3044>;IGNORE;IGNORE
-<U30A5> <U30A5>;<U30A5>;IGNORE;IGNORE
-<U3045> <U30A5>;<U3045>;IGNORE;IGNORE
-<U30A6> <U30A5>;<U30A6>;IGNORE;IGNORE
-<U3046> <U30A5>;<U3046>;IGNORE;IGNORE
-<U30F4> <U30A5>;<U30F4>;IGNORE;IGNORE
-<U30A7> <U30A7>;<U30A7>;IGNORE;IGNORE
-<U3047> <U30A7>;<U3047>;IGNORE;IGNORE
-<U30A8> <U30A7>;<U30A8>;IGNORE;IGNORE
-<U3048> <U30A7>;<U3048>;IGNORE;IGNORE
-<U30A9> <U30A9>;<U30A9>;IGNORE;IGNORE
-<U3049> <U30A9>;<U3049>;IGNORE;IGNORE
-<U30AA> <U30A9>;<U30AA>;IGNORE;IGNORE
-<U304A> <U30A9>;<U304A>;IGNORE;IGNORE
-<U30F5> <U30F5>;<U30F5>;IGNORE;IGNORE
-<U30AB> <U30F5>;<U30AB>;IGNORE;IGNORE
-<U304B> <U30F5>;<U304B>;IGNORE;IGNORE
-<U30AC> <U30F5>;<U30AC>;IGNORE;IGNORE
-<U304C> <U30F5>;<U304C>;IGNORE;IGNORE
-<U30AD> <U30AD>;<U30AD>;IGNORE;IGNORE
-<U304D> <U30AD>;<U304D>;IGNORE;IGNORE
-<U30AE> <U30AD>;<U30AE>;IGNORE;IGNORE
-<U304E> <U30AD>;<U304E>;IGNORE;IGNORE
-<U30AF> <U30AF>;<U30AF>;IGNORE;IGNORE
-<U304F> <U30AF>;<U304F>;IGNORE;IGNORE
-<U30B0> <U30AF>;<U30B0>;IGNORE;IGNORE
-<U3050> <U30AF>;<U3050>;IGNORE;IGNORE
-<U30F6> <U30F6>;<U30F6>;IGNORE;IGNORE
-<U30B1> <U30F6>;<U30B1>;IGNORE;IGNORE
-<U3051> <U30F6>;<U3051>;IGNORE;IGNORE
-<U30B2> <U30F6>;<U30B2>;IGNORE;IGNORE
-<U3052> <U30F6>;<U3052>;IGNORE;IGNORE
-<U30B3> <U30B3>;<U30B3>;IGNORE;IGNORE
-<U3053> <U30B3>;<U3053>;IGNORE;IGNORE
-<U30B4> <U30B3>;<U30B4>;IGNORE;IGNORE
-<U3054> <U30B3>;<U3054>;IGNORE;IGNORE
-<U30B5> <U30B5>;<U30B5>;IGNORE;IGNORE
-<U3055> <U30B5>;<U3055>;IGNORE;IGNORE
-<U30B6> <U30B5>;<U30B6>;IGNORE;IGNORE
-<U3056> <U30B5>;<U3056>;IGNORE;IGNORE
-<U30B7> <U30B7>;<U30B7>;IGNORE;IGNORE
-<U3057> <U30B7>;<U3057>;IGNORE;IGNORE
-<U30B8> <U30B7>;<U30B8>;IGNORE;IGNORE
-<U3058> <U30B7>;<U3058>;IGNORE;IGNORE
-<U30B9> <U30B9>;<U30B9>;IGNORE;IGNORE
-<U3059> <U30B9>;<U3059>;IGNORE;IGNORE
-<U30BA> <U30B9>;<U30BA>;IGNORE;IGNORE
-<U305A> <U30B9>;<U305A>;IGNORE;IGNORE
-<U30BB> <U30BB>;<U30BB>;IGNORE;IGNORE
-<U305B> <U30BB>;<U305B>;IGNORE;IGNORE
-<U30BC> <U30BB>;<U30BC>;IGNORE;IGNORE
-<U305C> <U30BB>;<U305C>;IGNORE;IGNORE
-<U30BD> <U30BD>;<U30BD>;IGNORE;IGNORE
-<U305D> <U30BD>;<U305D>;IGNORE;IGNORE
-<U30BE> <U30BD>;<U30BE>;IGNORE;IGNORE
-<U305E> <U30BD>;<U305E>;IGNORE;IGNORE
-<U30BF> <U30BF>;<U30BF>;IGNORE;IGNORE
-<U305F> <U30BF>;<U305F>;IGNORE;IGNORE
-<U30C0> <U30BF>;<U30C0>;IGNORE;IGNORE
-<U3060> <U30BF>;<U3060>;IGNORE;IGNORE
-<U30C1> <U30C1>;<U30C1>;IGNORE;IGNORE
-<U3061> <U30C1>;<U3061>;IGNORE;IGNORE
-<U30C2> <U30C1>;<U30C2>;IGNORE;IGNORE
-<U3062> <U30C1>;<U3062>;IGNORE;IGNORE
-<U30C3> <U30C3>;<U30C3>;IGNORE;IGNORE
-<U3063> <U30C3>;<U3063>;IGNORE;IGNORE
-<U30C4> <U30C3>;<U30C4>;IGNORE;IGNORE
-<U3064> <U30C3>;<U3064>;IGNORE;IGNORE
-<U30C5> <U30C3>;<U30C5>;IGNORE;IGNORE
-<U3065> <U30C3>;<U3065>;IGNORE;IGNORE
-<U30C6> <U30C6>;<U30C6>;IGNORE;IGNORE
-<U3066> <U30C6>;<U3066>;IGNORE;IGNORE
-<U30C7> <U30C6>;<U30C7>;IGNORE;IGNORE
-<U3067> <U30C6>;<U3067>;IGNORE;IGNORE
-<U30C8> <U30C8>;<U30C8>;IGNORE;IGNORE
-<U3068> <U30C8>;<U3068>;IGNORE;IGNORE
-<U30C9> <U30C8>;<U30C9>;IGNORE;IGNORE
-<U3069> <U30C8>;<U3069>;IGNORE;IGNORE
-<U30CA> <U30CA>;<U30CA>;IGNORE;IGNORE
-<U306A> <U30CA>;<U306A>;IGNORE;IGNORE
-<U30CB> <U30CB>;<U30CB>;IGNORE;IGNORE
-<U306B> <U30CB>;<U306B>;IGNORE;IGNORE
-<U30CC> <U30CC>;<U30CC>;IGNORE;IGNORE
-<U306C> <U30CC>;<U306C>;IGNORE;IGNORE
-<U30CD> <U30CD>;<U30CD>;IGNORE;IGNORE
-<U306D> <U30CD>;<U306D>;IGNORE;IGNORE
-<U30CE> <U30CE>;<U30CE>;IGNORE;IGNORE
-<U306E> <U30CE>;<U306E>;IGNORE;IGNORE
-<U30CF> <U30CF>;<U30CF>;IGNORE;IGNORE
-<U306F> <U30CF>;<U306F>;IGNORE;IGNORE
-<U30D0> <U30CF>;<U30D0>;IGNORE;IGNORE
-<U3070> <U30CF>;<U3070>;IGNORE;IGNORE
-<U30D1> <U30CF>;<U30D1>;IGNORE;IGNORE
-<U3071> <U30CF>;<U3071>;IGNORE;IGNORE
-<U30D2> <U30D2>;<U30D2>;IGNORE;IGNORE
-<U3072> <U30D2>;<U3072>;IGNORE;IGNORE
-<U30D3> <U30D2>;<U30D3>;IGNORE;IGNORE
-<U3073> <U30D2>;<U3073>;IGNORE;IGNORE
-<U30D4> <U30D2>;<U30D4>;IGNORE;IGNORE
-<U3074> <U30D2>;<U3074>;IGNORE;IGNORE
-<U30D5> <U30D5>;<U30D5>;IGNORE;IGNORE
-<U3075> <U30D5>;<U3075>;IGNORE;IGNORE
-<U30D6> <U30D5>;<U30D6>;IGNORE;IGNORE
-<U3076> <U30D5>;<U3076>;IGNORE;IGNORE
-<U30D7> <U30D5>;<U30D7>;IGNORE;IGNORE
-<U3077> <U30D5>;<U3077>;IGNORE;IGNORE
-<U30D8> <U30D8>;<U30D8>;IGNORE;IGNORE
-<U3078> <U30D8>;<U3078>;IGNORE;IGNORE
-<U30D9> <U30D8>;<U30D9>;IGNORE;IGNORE
-<U3079> <U30D8>;<U3079>;IGNORE;IGNORE
-<U30DA> <U30D8>;<U30DA>;IGNORE;IGNORE
-<U307A> <U30D8>;<U307A>;IGNORE;IGNORE
-<U30DB> <U30DB>;<U30DB>;IGNORE;IGNORE
-<U307B> <U30DB>;<U307B>;IGNORE;IGNORE
-<U30DC> <U30DB>;<U30DC>;IGNORE;IGNORE
-<U307C> <U30DB>;<U307C>;IGNORE;IGNORE
-<U30DD> <U30DB>;<U30DD>;IGNORE;IGNORE
-<U307D> <U30DB>;<U307D>;IGNORE;IGNORE
-<U30DE> <U30DE>;<U30DE>;IGNORE;IGNORE
-<U307E> <U30DE>;<U307E>;IGNORE;IGNORE
-<U30DF> <U30DF>;<U30DF>;IGNORE;IGNORE
-<U307F> <U30DF>;<U307F>;IGNORE;IGNORE
-<U30E0> <U30E0>;<U30E0>;IGNORE;IGNORE
-<U3080> <U30E0>;<U3080>;IGNORE;IGNORE
-<U30E1> <U30E1>;<U30E1>;IGNORE;IGNORE
-<U3081> <U30E1>;<U3081>;IGNORE;IGNORE
-<U30E2> <U30E2>;<U30E2>;IGNORE;IGNORE
-<U3082> <U30E2>;<U3082>;IGNORE;IGNORE
-<U30E3> <U30E3>;<U30E3>;IGNORE;IGNORE
-<U3083> <U30E3>;<U3083>;IGNORE;IGNORE
-<U30E4> <U30E3>;<U30E4>;IGNORE;IGNORE
-<U3084> <U30E3>;<U3084>;IGNORE;IGNORE
-<U30E5> <U30E5>;<U30E5>;IGNORE;IGNORE
-<U3085> <U30E5>;<U3085>;IGNORE;IGNORE
-<U30E6> <U30E5>;<U30E6>;IGNORE;IGNORE
-<U3086> <U30E5>;<U3086>;IGNORE;IGNORE
-<U30E7> <U30E7>;<U30E7>;IGNORE;IGNORE
-<U3087> <U30E7>;<U3087>;IGNORE;IGNORE
-<U30E8> <U30E7>;<U30E8>;IGNORE;IGNORE
-<U3088> <U30E7>;<U3088>;IGNORE;IGNORE
-<U30E9> <U30E9>;<U30E9>;IGNORE;IGNORE
-<U3089> <U30E9>;<U3089>;IGNORE;IGNORE
-<U30EA> <U30EA>;<U30EA>;IGNORE;IGNORE
-<U308A> <U30EA>;<U308A>;IGNORE;IGNORE
-<U30EB> <U30EB>;<U30EB>;IGNORE;IGNORE
-<U308B> <U30EB>;<U308B>;IGNORE;IGNORE
-<U30EC> <U30EC>;<U30EC>;IGNORE;IGNORE
-<U308C> <U30EC>;<U308C>;IGNORE;IGNORE
-<U30ED> <U30ED>;<U30ED>;IGNORE;IGNORE
-<U308D> <U30ED>;<U308D>;IGNORE;IGNORE
-<U30EE> <U30EE>;<U30EE>;IGNORE;IGNORE
-<U308E> <U30EE>;<U308E>;IGNORE;IGNORE
-<U30EF> <U30EE>;<U30EF>;IGNORE;IGNORE
-<U308F> <U30EE>;<U308F>;IGNORE;IGNORE
-<U30F0> <U30F0>;<U30F0>;IGNORE;IGNORE
-<U3090> <U30F0>;<U3090>;IGNORE;IGNORE
-<U30F1> <U30F1>;<U30F1>;IGNORE;IGNORE
-<U3091> <U30F1>;<U3091>;IGNORE;IGNORE
-<U30F2> <U30F2>;<U30F2>;IGNORE;IGNORE
-<U3092> <U30F2>;<U3092>;IGNORE;IGNORE
-<U30F3> <U30F3>;<U30F3>;IGNORE;IGNORE
-<U3093> <U30F3>;<U3093>;IGNORE;IGNORE
-
-order_end
-
+% Copy the template from ISO/IEC 14651
+copy "iso14651_t1"
END LC_COLLATE
LC_CTYPE
@@ -2135,9 +75,9 @@ positive_sign ""
negative_sign "<U002D>"
int_frac_digits 2
frac_digits 2
-p_cs_precedes 1
+p_cs_precedes 0
p_sep_by_space 1
-n_cs_precedes 1
+n_cs_precedes 0
n_sep_by_space 1
p_sign_posn 1
n_sign_posn 1
diff --git a/libc/localedata/locales/fi_FI b/libc/localedata/locales/fi_FI
index 9ffe8f103..a7920acb1 100644
--- a/libc/localedata/locales/fi_FI
+++ b/libc/localedata/locales/fi_FI
@@ -193,13 +193,15 @@ mon "<U0074><U0061><U006D><U006D><U0069><U006B><U0075><U0075>";/
"<U006D><U0061><U0072><U0072><U0061><U0073><U006B><U0075><U0075>";/
"<U006A><U006F><U0075><U006C><U0075><U006B><U0075><U0075>"
d_t_fmt "<U0025><U0061><U0020><U0025><U0065><U002E><U0020><U0025><U0042>/
-<U0074><U0061><U0020><U0025><U0059><U0020><U0025><U0054>"
+<U0074><U0061><U0020><U0025><U0059><U0020><U0025><U0048><U002E><U0025>/
+<U004D><U002E><U0025><U0053>"
d_fmt "<U0025><U0064><U002E><U0025><U006D><U002E><U0025><U0059>"
-t_fmt "<U0025><U0054>"
+t_fmt "<U0025><U0048><U002E><U0025><U004D><U002E><U0025><U0053>"
am_pm "";""
t_fmt_ampm ""
date_fmt "<U0025><U0061><U0020><U0025><U002D><U0064><U002E><U0025>/
-<U002D><U006D><U002E><U0025><U0059><U0020><U0025><U0054><U0020><U0025><U007A>"
+<U002D><U006D><U002E><U0025><U0059><U0020><U0025><U0048><U002E><U0025>/
+<U004D><U002E><U0025><U0053><U0020><U0025><U007A>"
first_weekday 2 % Monday
first_workday 2 % Monday
END LC_TIME
diff --git a/libc/localedata/locales/fr_FR b/libc/localedata/locales/fr_FR
index 8bae00565..92c3bde1b 100644
--- a/libc/localedata/locales/fr_FR
+++ b/libc/localedata/locales/fr_FR
@@ -3,33 +3,35 @@ escape_char /
%
% French Language Locale for France
% Source: RAP
-% Address: Sankt Jo//rgens Alle 8
-% DK-1615 Ko//benhavn V, Danmark
-% Contact: Keld Simonsen
-% Email: Keld.Simonsen@dkuug.dk
-% Tel: +45 - 31226543
-% Fax: +45 - 33256543
% Language: fr
+% Contact: Traduc.org
+% Address: 18, rue Cavendish
+% 75019 Paris
+% Email: traduc@traduc.org
% Territory: FR
-% Revision: 4.3
-% Date: 1996-10-15
+% Revision: 4.4
+% Date: 2008-03-02
% Users: general
% Charset: ISO-8859-1
+% Authors:
+% 2000-06-28, keld.simonsen@dkuug.dk
+% 2008-03-02, stephane.raimbault@gmail.com
+%
% Distribution and use is free, also
% for commercial purposes.
LC_IDENTIFICATION
title "French locale for France"
source "RAP"
-address "Sankt J<U00F8>rgens Alle 8, DK-1615 K<U00F8>benhavn V, Danmark"
-contact "Keld Simonsen"
+address ""
+contact "Traduc.org"
email "bug-glibc-locales@gnu.org"
tel ""
fax ""
language "French"
territory "France"
revision "1.0"
-date "2000-06-28"
+date "2008-03-15"
%
category "fr_FR:2000";LC_IDENTIFICATION
category "fr_FR:2000";LC_CTYPE
@@ -72,7 +74,7 @@ int_curr_symbol "<U0045><U0055><U0052><U0020>"
currency_symbol "<U20AC>"
mon_decimal_point "<U002C>"
mon_thousands_sep "<U0020>"
-mon_grouping 3;3
+mon_grouping 3
positive_sign ""
negative_sign "<U002D>"
int_frac_digits 2
@@ -88,14 +90,17 @@ END LC_MONETARY
LC_NUMERIC
decimal_point "<U002C>"
thousands_sep "<U0020>"
-grouping 0;0
+grouping 3
END LC_NUMERIC
LC_TIME
-abday "<U0064><U0069><U006D>";"<U006C><U0075><U006E>";/
- "<U006D><U0061><U0072>";"<U006D><U0065><U0072>";/
- "<U006A><U0065><U0075>";"<U0076><U0065><U006E>";/
- "<U0073><U0061><U006D>"
+abday "<U0064><U0069><U006D><U002E>";/
+ "<U006C><U0075><U006E><U002E>";/
+ "<U006D><U0061><U0072><U002E>";/
+ "<U006D><U0065><U0072><U002E>";/
+ "<U006A><U0065><U0075><U002E>";/
+ "<U0076><U0065><U006E><U002E>";/
+ "<U0073><U0061><U006D><U002E>"
day "<U0064><U0069><U006D><U0061><U006E><U0063><U0068><U0065>";/
"<U006C><U0075><U006E><U0064><U0069>";/
"<U006D><U0061><U0072><U0064><U0069>";/
@@ -103,12 +108,18 @@ day "<U0064><U0069><U006D><U0061><U006E><U0063><U0068><U0065>";/
"<U006A><U0065><U0075><U0064><U0069>";/
"<U0076><U0065><U006E><U0064><U0072><U0065><U0064><U0069>";/
"<U0073><U0061><U006D><U0065><U0064><U0069>"
-abmon "<U006A><U0061><U006E>";"<U0066><U00E9><U0076>";/
- "<U006D><U0061><U0072>";"<U0061><U0076><U0072>";/
- "<U006D><U0061><U0069>";"<U006A><U0075><U006E>";/
- "<U006A><U0075><U0069>";"<U0061><U006F><U00FB>";/
- "<U0073><U0065><U0070>";"<U006F><U0063><U0074>";/
- "<U006E><U006F><U0076>";"<U0064><U00E9><U0063>"
+abmon "<U006A><U0061><U006E><U0076><U002E>";/
+ "<U0066><U00E9><U0076><U0072><U002E>";/
+ "<U006D><U0061><U0072><U0073>";/
+ "<U0061><U0076><U0072><U0069><U006C>";/
+ "<U006D><U0061><U0069>";/
+ "<U006A><U0075><U0069><U006E>";/
+ "<U006A><U0075><U0069><U006C><U002E>";/
+ "<U0061><U006F><U00FB><U0074>";/
+ "<U0073><U0065><U0070><U0074><U002E>";/
+ "<U006F><U0063><U0074><U002E>";/
+ "<U006E><U006F><U0076><U002E>";/
+ "<U0064><U00E9><U0063><U002E>"
mon "<U006A><U0061><U006E><U0076><U0069><U0065><U0072>";/
"<U0066><U00E9><U0076><U0072><U0069><U0065><U0072>";/
"<U006D><U0061><U0072><U0073>";/
@@ -122,7 +133,7 @@ mon "<U006A><U0061><U006E><U0076><U0069><U0065><U0072>";/
"<U006E><U006F><U0076><U0065><U006D><U0062><U0072><U0065>";/
"<U0064><U00E9><U0063><U0065><U006D><U0062><U0072><U0065>"
d_t_fmt "<U0025><U0061><U0020><U0025><U0064><U0020><U0025><U0062><U0020><U0025><U0059><U0020><U0025><U0054><U0020><U0025><U005A>"
-d_fmt "<U0025><U0064><U002E><U0025><U006D><U002E><U0025><U0059>"
+d_fmt "<U0025><U0064><U002F><U0025><U006D><U002F><U0025><U0059>"
t_fmt "<U0025><U0054>"
am_pm "";""
t_fmt_ampm ""
diff --git a/libc/localedata/locales/hu_HU b/libc/localedata/locales/hu_HU
index 95be95b0a..97e544df6 100644
--- a/libc/localedata/locales/hu_HU
+++ b/libc/localedata/locales/hu_HU
@@ -543,8 +543,8 @@ measurement 1
END LC_MEASUREMENT
LC_NAME
-name_fmt "<U0025><U0064><U0025><U0074><U0025><U0067><U0025><U0074>/
-<U0025><U006D><U0025><U0074><U0025><U0066>"
+name_fmt "<U0025><U0064><U0025><U0074><U0025><U0066><U0025><U0074>/
+<U0025><U006D><U0025><U0074><U0025><U0067>"
END LC_NAME
LC_ADDRESS
diff --git a/libc/localedata/locales/i18n b/libc/localedata/locales/i18n
index 93ffe90e7..728742441 100644
--- a/libc/localedata/locales/i18n
+++ b/libc/localedata/locales/i18n
@@ -2,20 +2,17 @@ escape_char /
comment_char %
LC_IDENTIFICATION
-% This is the ISO/IEC TR 14652 "i18n" definition for
-% the LC_IDENTIFICATION category.
-%
-title "ISO/IEC TR 14652 i18n FDCC-set"
-source "ISO/IEC Copyright Office"
-address "Case postale 56, CH-1211 Geneve 20, Switzerland"
+title ""
+source ""
+address ""
contact ""
email ""
tel ""
fax ""
language ""
-territory "ISO"
-revision "1.0"
-date "2000-01-24"
+territory ""
+revision ""
+date "2008-04-13"
%
category "i18n:2000";LC_IDENTIFICATION
category "i18n:2000";LC_CTYPE
@@ -63,6 +60,7 @@ upper /
<U023A>;<U023B>;<U023D>;<U023E>;/
<U0241>;<U0243>..<U0246>;<U0248>;<U024A>;<U024C>;<U024E>;/
% BASIC GREEK/
+ <U0370>;<U0372>;<U0376>;/
<U0386>;<U0388>..<U038A>;<U038C>;<U038E>;<U038F>;<U0391>..<U03A1>;/
<U03A3>..<U03AB>;<U03D8>..(2)..<U03DE>;/
% GREEK SYMBOLS AND COPTIC/
@@ -73,7 +71,7 @@ upper /
<U0480>;<U048A>..(2)..<U04BE>;<U04C0>;<U04C1>..(2)..<U04CD>;/
<U04D0>..(2)..<U04FE>;/
% CYRILLIC SUPPLEMENT/
- <U0500>..(2)..<U0512>;/
+ <U0500>..(2)..<U0522>;/
% ARMENIAN/
<U0531>..<U0556>;/
% GEORGIAN/
@@ -83,8 +81,8 @@ upper /
<U10A0>..<U10C5>;/
% LATIN EXTENDED ADDITIONAL/
<U1E00>..(2)..<U1E7E>;/
- <U1E80>..(2)..<U1E94>;/
- <U1EA0>..(2)..<U1EF8>;/
+ <U1E80>..(2)..<U1E94>;<U1E9E>;/
+ <U1EA0>..(2)..<U1EFE>;/
% GREEK EXTENDED/
<U1F08>..<U1F0F>;<U1F18>..<U1F1D>;<U1F28>..<U1F2F>;<U1F38>..<U1F3F>;/
<U1F48>..<U1F4D>;<U1F59>..(2)..<U1F5F>;<U1F68>..<U1F6F>;/
@@ -101,9 +99,15 @@ upper /
% GLAGOLITIC/
<U2C00>..<U2C2E>;/
% LATIN EXTENDED-C/
- <U2C60>;<U2C62>..<U2C64>;<U2C67>..(2)..<U2C6B>;<U2C75>;/
+ <U2C60>;<U2C62>..<U2C64>;<U2C67>..(2)..<U2C6B>;<U2C6D>..<U2C6F>;/
+ <U2C72>;<U2C75>;<UA78B>;/
% COPTIC/
<U2C80>..(2)..<U2CE2>;/
+% CYRILLIC SUPPLEMENT 2/
+ <UA640>..(2)..<UA65E>;<UA662>..(2)..<UA66C>;<UA680>..(2)..<UA696>;/
+% LATIN EXTENDED-D/
+ <UA722>..(2)..<UA72E>;<UA732>..(2)..<UA76E>;<UA779>..(2)..<UA77D>;/
+ <UA77E>..(2)..<UA786>;/
% HALFWIDTH AND FULLWIDTH FORMS/
<UFF21>..<UFF3A>;/
% DESERET/
@@ -133,6 +137,7 @@ lower /
% COMBINING DIACRITICAL MARKS/
<U0345>;/
% BASIC GREEK/
+ <U0371>;<U0373>;<U0377>;/
<U037B>..<U037D>;/
<U03AC>..<U03AF>;<U03B1>..<U03CE>;/
% GREEK SYMBOLS AND COPTIC/
@@ -142,13 +147,13 @@ lower /
<U0430>..<U045F>;<U0461>..(2)..<U047F>;/
<U0481>;<U048B>..(2)..<U04BF>;<U04C2>..(2)..<U04CE>;/
<U04CF>;/
- <U04D1>..(2)..<U0513>;/
+ <U04D1>..(2)..<U0523>;/
% ARMENIAN/
<U0561>..<U0586>;/
% PHONETIC EXTENSIONS/
<U1D7D>;/
% LATIN EXTENDED ADDITIONAL/
- <U1E01>..(2)..<U1E95>;<U1E9B>;<U1EA1>..(2)..<U1EF9>;/
+ <U1E01>..(2)..<U1E95>;<U1E9B>..<U1E9D>;<U1E9F>;<U1EA1>..(2)..<U1EFF>;/
% GREEK EXTENDED/
<U1F00>..<U1F07>;<U1F10>..<U1F15>;<U1F20>..<U1F27>;<U1F30>..<U1F37>;/
<U1F40>..<U1F45>;<U1F51>..(2)..<U1F57>;<U1F60>..<U1F67>;<U1F70>..<U1F7D>;/
@@ -158,19 +163,25 @@ lower /
% LETTERLIKE SYMBOLS/
<U214E>;/
% NUMBER FORMS/
- <U2170>..<U217F>;<U2184>;/
+ <U2170>..<U217F>;<U2188>;/
% ENCLOSED ALPHANUMERICS/
<U24D0>..<U24E9>;/
% GLAGOLITIC/
<U2C30>..<U2C5E>;/
% LATIN EXTENDED-C/
- <U2C61>;<U2C65>;<U2C66>..(2)..<U2C6C>;<U2C76>;/
+ <U2C61>;<U2C65>;<U2C66>..(2)..<U2C6C>;<U2C71>;<U2C73>;<U2C74>;/
+ <U2C76>..<U2C7A>;/
% COPTIC/
<U2C81>..(2)..<U2CE3>;/
% GEORGIAN SUPPLEMENT/
% well, there are three georgian blocks defined; one caseless (the one usually/
% used), one defined as uppercase and one as lowercase. defining the lowercase one here/
<U2D00>..<U2D25>;/
+% CYRILLIC SUPPLEMENT 2/
+ <UA641>..(2)..<UA65F>;<UA663>..(2)..<UA66D>;<UA681>..(2)..<UA697>;/
+% LATIN EXTENDED-D/
+ <UA723>..(2)..<UA72F>;<UA730>;<UA731>..(2)..<UA76F>;<UA771>..<UA778>;/
+ <UA77A>..(2)..<UA77C>;<UA77F>..(2)..<UA787>;<UA78C>;/
% HALFWIDTH AND FULLWIDTH FORMS/
<UFF41>..<UFF5A>;/
% DESERET/
@@ -196,7 +207,7 @@ alpha /
% COMBINING DIACRITICAL MARKS/
<U0345>;/
% BASIC GREEK/
- <U037A>..<U037D>;<U0386>;/
+ <U0370>..<U0373>;<U0376>..<U0377>;<U037A>..<U037D>;<U0386>;/
<U0388>..<U038A>;<U038C>;<U038E>..<U03A1>;/
<U03A3>..<U03CE>;/
% GREEK SYMBOLS AND COPTIC/
@@ -204,18 +215,18 @@ alpha /
% CYRILLIC/
<U0400>..<U0481>;<U048A>..<U04FF>;/
% CYRILLIC SUPPLEMENT/
- <U0500>..<U0513>;/
+ <U0500>..<U0523>;/
% ARMENIAN/
<U0531>..<U0556>;<U0559>;<U0561>..<U0587>;/
% HEBREW/
<U05D0>..<U05EA>;<U05F0>..<U05F2>;/
% ARABIC/
- <U0621>..<U063A>;<U0640>..<U064A>;<U066E>..<U066F>;<U0671>..<U06D3>;/
+ <U0621>..<U064A>;<U066E>..<U066F>;<U0671>..<U06D3>;/
<U06D5>;<U06E5>..<U06E6>;<U06EE>..<U06EF>;<U06FA>..<U06FC>;<U06FF>;/
% SYRIAC/
<U0710>;<U0712>..<U072F>;<U074D>..<U074F>;/
% ARABIC SUPPLEMENT/
- <U0750>..<U076D>;/
+ <U0750>..<U077F>;/
% THAANA/
<U0780>..<U07A5>;<U07B1>;/
% NKO/
@@ -238,20 +249,20 @@ alpha /
% ORIYA/
<U0B05>..<U0B0C>;<U0B0F>;<U0B10>;<U0B13>..<U0B28>;<U0B2A>..<U0B30>;/
<U0B32>;<U0B33>;<U0B35>..<U0B39>;<U0B3D>;<U0B5C>;<U0B5D>;/
- <U0B5F>..<U0B61>;<U0B71>;/
+ <U0B5F>..<U0B63>;<U0B71>;/
% TAMIL/
<U0B83>;<U0B85>..<U0B8A>;<U0B8E>..<U0B90>;<U0B92>..<U0B95>;<U0B99>;/
<U0B9A>;<U0B9C>;<U0B9E>;<U0B9F>;<U0BA3>;<U0BA4>;<U0BA8>..<U0BAA>;/
<U0BAE>..<U0BB9>;/
% TELUGU/
<U0C05>..<U0C0C>;<U0C0E>..<U0C10>;<U0C12>..<U0C28>;<U0C2A>..<U0C33>;/
- <U0C35>..<U0C39>;<U0C60>..<U0C61>;/
+ <U0C35>..<U0C39>;<U0C3D>;<U0C58>..<U0C59>;<U0C60>..<U0C63>;/
% KANNADA/
<U0C85>..<U0C8C>;<U0C8E>..<U0C90>;<U0C92>..<U0CA8>;<U0CAA>..<U0CB3>;/
<U0CB5>..<U0CB9>;<U0CDE>;<U0CE0>..<U0CE1>;/
% MALAYALAM/
<U0D05>..<U0D0C>;<U0D0E>..<U0D10>;<U0D12>..<U0D28>;<U0D2A>..<U0D39>;/
- <U0D60>..<U0D61>;/
+ <U0D3D>;<U0D60>..<U0D63>;/
% SINHALA/
<U0D85>..<U0D96>;<U0D9A>..<U0DB1>;<U0DB3>..<U0DBB>;<U0DBD>;/
<U0DC0>..<U0DC6>;/
@@ -263,9 +274,10 @@ alpha /
<U0EAA>..<U0EAB>;<U0EAD>..<U0EB0>;<U0EB2>..<U0EB3>;<U0EBD>;/
<U0EC0>..<U0EC4>;<U0EC6>;<U0EDC>..<U0EDD>;/
% TIBETAN/
- <U0F00>;<U0F40>..<U0F47>;<U0F49>..<U0F6A>;<U0F88>..<U0F8B>;/
+ <U0F00>;<U0F40>..<U0F47>;<U0F49>..<U0F6C>;<U0F88>..<U0F8B>;/
% MYANMAR/
- <U1000>..<U1021>;<U1023>..<U1027>;<U1029>;<U102A>;<U1050>..<U1055>;/
+ <U1000>..<U102A>;<U1050>..<U1055>;<U105A>..<U105D>;<U1061>;<U0165>;/
+ <U1066>;<U106E>..<U1070>;<U1075>..<U1081>;<U108E>;/
% GEORGIAN/
<U10A0>..<U10C5>;<U10D0>..<U10FA>;<U10FC>;/
% HANGUL JAMO/
@@ -298,7 +310,7 @@ alpha /
% KHMER/
<U1780>..<U17B3>;<U17D7>;<U17DC>;/
% MONGOLIAN/
- <U1820>..<U1877>;<U1880>..<U18A8>;/
+ <U1820>..<U1877>;<U1880>..<U18A8>;<U18AA>;/
% LIMBU/
<U1900>..<U191C>;<U1946>..<U194F>;/
% TAI LE/
@@ -309,10 +321,16 @@ alpha /
<U1A00>..<U1A16>;/
% BALINESE/
<U1B05>..<U1B33>;<U1B45>..<U1B4B>;<U1B50>..<U1B59>;/
+% SUNDANESE/
+ <U1B83>..<U1BA0>;<U1BAE>..<U1BAF>;/
+% LEPCHA/
+ <U1C00>..<U1C23>;<U1C4D>..<U1C4F>;/
+% OL CHIKI/
+ <U1C5A>..<U1C7D>;/
% PHONETIC EXTENSIONS/
<U1D00>..<U1DBF>;/
% LATIN EXTENDED ADDITIONAL/
- <U1E00>..<U1E9B>;<U1EA0>..<U1EF9>;/
+ <U1E00>..<U1E9F>;<U1EA0>..<U1EFF>;/
% GREEK EXTENDED/
<U1F00>..<U1F15>;<U1F18>..<U1F1D>;<U1F20>..<U1F45>;<U1F48>..<U1F4D>;/
<U1F50>..<U1F57>;<U1F59>;<U1F5B>;<U1F5D>;<U1F5F>..<U1F7D>;/
@@ -326,13 +344,13 @@ alpha /
<U2126>;<U2128>..<U212D>;<U212F>..<U2139>;/
<U213C>..<U213F>;<U2145>..<U2149>;<U214E>;/
% NUMBER FORMS/
- <U2160>..<U2184>;/
+ <U2160>..<U2188>;/
% ENCLOSED ALPHANUMERICS/
<U249C>..<U24E9>;/
% GLAGOLITIC/
<U2C00>..<U2C2E>;<U2C30>..<U2C5E>;/
% LATIN EXTENDED-C/
- <U2C60>..<U2C6C>;<U2C74>..<U2C77>;/
+ <U2C60>..<U2C6F>;<U2C71>..<U2C7D>;/
% COPTIC/
<U2C80>..<U2CE4>;/
% GEORGIAN SUPPLEMENT/
@@ -350,7 +368,7 @@ alpha /
% KATAKANA/
<U30A1>..<U30FA>;<U30FC>..<U30FF>;/
% BOPOMOFO/
- <U3105>..<U312C>;/
+ <U3105>..<U312D>;/
% HANGUL COMPATIBILITY JAMO/
<U3131>..<U318E>;/
% BOPOMOFO EXTENDED/
@@ -363,12 +381,24 @@ alpha /
<U4E00>..<U9FBB>;/
% YI SYLLABLES/
<UA000>..<UA48C>;/
+% VAI SYLLABLES/
+ <UA500>..<UA60B>;<UA610>..<UA61F>;<UA62A>..<UA62B>;/
+% CYRILLIC SUPPLEMENT 2/
+ <UA640>..<UA65F>;<UA662>..<UA66E>;<UA680>..<UA697>;/
% LATIN EXTENDED-D/
- <UA717>..<UA71A>;/
+ <UA717>..<UA71F>;<UA722>..<UA78C>;<UA7FB>..<UA7FF>;/
% SYLOTI NEGRI/
<UA800>;<UA801>;<UA803>..<UA805>;<UA807>..<UA80A>;<UA80C>..<UA822>;/
% PHAGS PA/
<UA840>..<UA873>;/
+% SAURASHTRA/
+ <UA882>..<UA8B3>;/
+% KAYAH LI/
+ <UA90A>..<UA92D>;/
+% REJANG/
+ <UA930>..<UA946>;/
+% CHAM/
+ <UAA00>..<UAA28>;<UAA40>..<UAA42>;<UAA44>..<UAA4B>;/
% HANGUL SYLLABLES/
<UAC00>..<UD7A3>;/
% CJK COMPATIBILITY IDEOGRAPHS/
@@ -394,6 +424,10 @@ alpha /
<U00010080>..<U000100FA>;/
% ANCIENT GREEK NUMBERS/
<U00010140>..<U00010174>;/
+% LYCIAN/
+ <U00010280>..<U0001029C>;/
+% CARIAN/
+ <U000102A0>..<U000102D0>;/
% OLD ITALIC/
<U00010300>..<U0001031E>;/
% GOTHIC/
@@ -458,11 +492,11 @@ alpha /
% TAMIL/
<U0BE6>..<U0BEF>;/
% TELUGU/
- <U0C66>..<U0C6F>;/
+ <U0C66>..<U0C6F>;<U0C78>..<U0C7F>;/
% KANNADA/
<U0CE6>..<U0CEF>;/
% MALAYALAM/
- <U0D66>..<U0D6F>;/
+ <U0D66>..<U0D75>;<U0D79>..<U0D7F>;/
% THAI/
<U0E50>..<U0E59>;/
% LAO/
@@ -475,6 +509,20 @@ alpha /
<U17E0>..<U17E9>;/
% MONGOLIAN/
<U1810>..<U1819>;/
+% SUNDANESE/
+ <U1BB0>..<U1BB9>;/
+% LEPCHA/
+ <U1C40>..<U1C49>;/
+% OL CHIKI/
+ <U1C50>..<U1C59>;/
+% VAI/
+ <UA620>..<UA629>;/
+% SAURASHTRA/
+ <UA8D0>..<UA8D9>;/
+% KAYAH LI/
+ <UA900>..<UA909>;/
+% CHAM/
+ <UAA50>..<UAA59>;/
% HALFWIDTH AND FULLWIDTH FORMS/
<UFF10>..<UFF19>
@@ -514,57 +562,67 @@ punct /
<U02EF>..<U0344>;<U0346>..<U036F>;<U0374>..<U0375>;<U037E>;/
<U0384>..<U0385>;<U0387>;<U03F6>;<U0482>..<U0486>;<U0488>..<U0489>;/
<U055A>..<U055F>;<U0589>..<U058A>;<U0591>..<U05C7>;<U05F3>..<U05F4>;/
- <U0600>..<U0603>;<U060B>..<U0615>;<U061B>;<U061E>..<U061F>;/
+ <U0600>..<U0603>;<U060B>..<U061B>;<U061E>..<U061F>;/
<U064B>..<U065E>;<U066A>..<U066D>;<U0670>;<U06D4>;<U06D6>..<U06E4>;/
<U06E7>..<U06ED>;<U06FD>..<U06FE>;<U0700>..<U070D>;<U070F>;<U0711>;/
<U0730>..<U074A>;<U07A6>..<U07B0>;<U07EB>..<U07F3>;<U07F6>..<U07F9>;/
<U0901>..<U0903>;<U093C>;<U093E>..<U094D>;<U0951>..<U0954>;/
- <U0962>..<U0965>;<U0970>;<U0981>..<U0983>;<U09BC>;<U09BE>..<U09C4>;/
+ <U0962>..<U0965>;<U0972>;<U0981>..<U0983>;<U09BC>;<U09BE>..<U09C4>;/
<U09C7>..<U09C8>;<U09CB>..<U09CD>;<U09D7>;<U09E2>..<U09E3>;/
<U09F2>..<U09FA>;<U0A01>..<U0A03>;<U0A3C>;<U0A3E>..<U0A42>;/
- <U0A47>..<U0A48>;<U0A4B>..<U0A4D>;<U0A70>..<U0A71>;<U0A81>..<U0A83>;/
+ <U0A47>..<U0A48>;<U0A4B>..<U0A4D>;<U0A51>;<U0A70>..<U0A71>;/
+ <U0A75>;<U0A81>..<U0A83>;/
<U0ABC>;<U0ABE>..<U0AC5>;<U0AC7>..<U0AC9>;<U0ACB>..<U0ACD>;/
- <U0AE2>..<U0AE3>;<U0AF1>;<U0B01>..<U0B03>;<U0B3C>;<U0B3E>..<U0B43>;/
+ <U0AE2>..<U0AE3>;<U0AF1>;<U0B01>..<U0B03>;<U0B3C>;<U0B3E>..<U0B44>;/
<U0B47>..<U0B48>;<U0B4B>..<U0B4D>;<U0B56>..<U0B57>;<U0B70>;<U0B82>;/
- <U0BBE>..<U0BC2>;<U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD7>;/
+ <U0BBE>..<U0BC2>;<U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD0>;<U0BD7>;/
<U0BF0>..<U0BFA>;<U0C01>..<U0C03>;<U0C3E>..<U0C44>;<U0C46>..<U0C48>;/
<U0C4A>..<U0C4D>;<U0C55>..<U0C56>;<U0C82>..<U0C83>;<U0CBC>;/
<U0CBE>..<U0CC4>;<U0CC6>..<U0CC8>;<U0CCA>..<U0CCD>;<U0CD5>..<U0CD6>;/
- <U0CE2>..<U0CE3>;<U0CF1>..<U0CF2>;<U0D02>..<U0D03>;<U0D3E>..<U0D43>;/
+ <U0CE2>..<U0CE3>;<U0CF1>..<U0CF2>;<U0D02>..<U0D03>;<U0D3E>..<U0D44>;/
<U0D46>..<U0D48>;<U0D4A>..<U0D4D>;<U0D57>;<U0D82>..<U0D83>;<U0DCA>;/
<U0DCF>..<U0DD4>;<U0DD6>;<U0DD8>..<U0DDF>;<U0DF2>..<U0DF4>;<U0E2F>;/
<U0E3F>;<U0E46>;<U0E4F>;<U0E5A>..<U0E5B>;<U0EB1>;<U0EB4>..<U0EB9>;/
<U0EBB>..<U0EBC>;<U0EC8>..<U0ECD>;<U0F01>..<U0F1F>;<U0F2A>..<U0F3F>;/
<U0F71>..<U0F87>;<U0F90>..<U0F97>;<U0F99>..<U0FBC>;<U0FBE>..<U0FCC>;/
- <U0FCF>..<U0FD1>;<U102C>..<U1032>;<U1036>..<U1039>;<U104A>..<U104F>;/
- <U1056>..<U1059>;<U10FB>;<U135F>..<U137C>;<U1390>..<U1399>;/
+ <U0FCE>..<U0FD4>;<U102B>..<U103F>;<U104A>..<U104F>;<U1056>..<U1059>;/
+ <U105E>..<U1060>;<U1062>..<U1064>;<U1067>..<U106D>;<U1071>..<U1074>;/
+ <U1082>..<U108D>;<U108F>..<U1099>;<U109E>;<U109F>;/
+ <U10FB>;<U135F>..<U137C>;<U1390>..<U1399>;/
<U166D>..<U166E>;<U169B>..<U169C>;<U16EB>..<U16ED>;<U1712>..<U1714>;/
<U1732>..<U1736>;<U1752>..<U1753>;<U1772>..<U1773>;<U17B4>..<U17D6>;/
<U17D8>..<U17DB>;<U17DD>;<U17F0>..<U17F9>;<U1800>..<U180D>;<U18A9>;/
<U1920>..<U192B>;<U1930>..<U193B>;<U1940>;<U1944>..<U1945>;/
<U19B0>..<U19C0>;<U19C8>..<U19C9>;<U19DE>..<U19FF>;<U1A17>..<U1A1B>;/
<U1A1E>..<U1A1F>;<U1B00>..<U1B04>;<U1B34>..<U1B44>;<U1B5A>..<U1B7C>;/
- <U1DC0>..<U1DCA>;<U1DFE>..<U1DFF>;<U1FBD>;<U1FBF>..<U1FC1>;/
+ <U1B80>..<U1B82>;<U1BA1>..<U1BAA>;<U1C24>..<U1C37>;<U1C3B>..<U1C3F>;/
+ <U1C7E>..<U1C7F>;/
+ <U1DC0>..<U1DE6>;<U1DFE>..<U1DFF>;<U1FBD>;<U1FBF>..<U1FC1>;/
<U1FCD>..<U1FCF>;<U1FDD>..<U1FDF>;<U1FED>..<U1FEF>;<U1FFD>..<U1FFE>;/
- <U2007>;<U200B>..<U2027>;<U202A>..<U205E>;<U2060>..<U2063>;/
+ <U2007>;<U200B>..<U2027>;<U202A>..<U205E>;<U2060>..<U2064>;/
<U206A>..<U2070>;<U2074>..<U207E>;<U2080>..<U208E>;<U20A0>..<U20B5>;/
- <U20D0>..<U20EF>;<U2100>..<U2101>;<U2103>..<U2106>;<U2108>..<U2109>;/
+ <U20D0>..<U20F0>;<U2100>..<U2101>;<U2103>..<U2106>;<U2108>..<U2109>;/
<U2114>;<U2116>..<U2118>;<U211E>..<U2123>;<U2125>;<U2127>;<U212E>;/
<U213A>..<U213B>;<U2140>..<U2144>;<U214A>..<U214D>;<U2153>..<U215F>;/
<U2190>..<U23E7>;<U2400>..<U2426>;<U2440>..<U244A>;<U2460>..<U249B>;/
- <U24EA>..<U269C>;<U26A0>..<U26B2>;<U2701>..<U2704>;<U2706>..<U2709>;/
+ <U24EA>..<U269D>;<U26A0>..<U26C3>;<U2701>..<U2704>;<U2706>..<U2709>;/
<U270C>..<U2727>;<U2729>..<U274B>;<U274D>;<U274F>..<U2752>;<U2756>;/
<U2758>..<U275E>;<U2761>..<U2794>;<U2798>..<U27AF>;<U27B1>..<U27BE>;/
- <U27C0>..<U27CA>;<U27D0>..<U27EB>;<U27F0>..<U2B1A>;<U2B20>..<U2B23>;/
- <U2CE5>..<U2CEA>;<U2CF9>..<U2CFF>;<U2E00>..<U2E17>;<U2E1C>..<U2E1D>;/
+ <U27C0>..<U27CA>;<U27CC>;<U27D0>..<U27EF>;<U27F0>..<U2B4C>;/
+ <U2B50>..<U2B54>;<U2DE0>..<U2DFF>;/
+ <U2CE5>..<U2CEA>;<U2CF9>..<U2CFF>;<U2E00>..<U2E30>;/
<U2E80>..<U2E99>;<U2E9B>..<U2EF3>;<U2F00>..<U2FD5>;<U2FF0>..<U2FFB>;/
<U3001>..<U3004>;<U3008>..<U3020>;<U302A>..<U3030>;<U3036>..<U3037>;/
<U303D>..<U303F>;<U3099>..<U309C>;<U30A0>;<U30FB>;<U3190>..<U319F>;/
<U31C0>..<U31CF>;<U3200>..<U321E>;<U3220>..<U3243>;<U3250>..<U32FE>;/
- <U3300>..<U33FF>;<U4DC0>..<U4DFF>;<UA490>..<UA4C6>;<UA700>..<UA716>;/
+ <U3300>..<U33FF>;<U4DC0>..<U4DFF>;<UA490>..<UA4C6>;<UA60C>..<UA60F>;/
+ <UA66F>..<UA673>;<UA67C>..<UA67F>;<UA700>..<UA716>;/
<UA720>..<UA721>;<UA802>;<UA806>;<UA80B>;<UA823>..<UA82B>;/
- <UA874>..<UA877>;<UE000>..<UF8FF>;<UFB1E>;<UFB29>;<UFD3E>..<UFD3F>;/
- <UFDFC>..<UFDFD>;<UFE00>..<UFE19>;<UFE20>..<UFE23>;<UFE30>..<UFE52>;/
+ <UA874>..<UA877>;<UA880>;<UA881>;<UA8B4>..<UA8C4>;<UA8CE>..<UA8CF>;/
+ <UA92E>..<UA92F>;<UA947>..<UA953>;<UA95F>;<UAA29>..<UAA36>;<UAA43>;/
+ <UAA4C>..<UAA4D>;<UAA5C>..<UAA5F>;/
+ <UE000>..<UF8FF>;<UFB1E>;<UFB29>;<UFD3E>..<UFD3F>;/
+ <UFDFC>..<UFDFD>;<UFE00>..<UFE19>;<UFE20>..<UFE26>;<UFE30>..<UFE52>;/
<UFE54>..<UFE66>;<UFE68>..<UFE6B>;<UFEFF>;<UFF01>..<UFF0F>;/
<UFF1A>..<UFF20>;<UFF3B>..<UFF40>;<UFF5B>..<UFF65>;<UFFE0>..<UFFE6>;/
<UFFE8>..<UFFEE>;<UFFF9>..<UFFFD>;<U00010100>..<U00010102>;/
@@ -575,7 +633,7 @@ punct /
<U00010A0C>..<U00010A0F>;<U00010A38>..<U00010A3A>;/
<U00010A3F>..<U00010A47>;<U00010A50>..<U00010A58>;/
<U00012470>..<U00012473>;<U0001D000>..<U0001D0F5>;/
- <U0001D100>..<U0001D126>;<U0001D12A>..<U0001D1DD>;/
+ <U0001D100>..<U0001D126>;<U0001D129>..<U0001D1DD>;/
<U0001D200>..<U0001D245>;<U0001D300>..<U0001D356>;/
<U0001D360>..<U0001D371>;<U0001D6C1>;<U0001D6DB>;<U0001D6FB>;<U0001D715>;/
<U0001D735>;<U0001D74F>;<U0001D76F>;<U0001D789>;<U0001D7A9>;<U0001D7C3>;/
@@ -583,52 +641,55 @@ punct /
<U000F0000>..<U000FFFFD>;<U00100000>..<U0010FFFD>
graph /
- <U0021>..<U007E>;<U00A0>..<U036F>;<U0374>..<U0375>;<U037A>..<U037E>;/
- <U0384>..<U038A>;<U038C>;<U038E>..<U03A1>;<U03A3>..<U03CE>;/
- <U03D0>..<U0486>;<U0488>..<U0513>;<U0531>..<U0556>;<U0559>..<U055F>;/
+ <U0021>..<U007E>;<U00A0>..<U0377>;<U037A>..<U037E>;/
+ <U0384>..<U038A>;<U038C>;<U038E>..<U03A1>;<U03A3>..<U0486>;/
+ <U0488>..<U0523>;<U0531>..<U0556>;<U0559>..<U055F>;/
<U0561>..<U0587>;<U0589>..<U058A>;<U0591>..<U05C7>;<U05D0>..<U05EA>;/
- <U05F0>..<U05F4>;<U0600>..<U0603>;<U060B>..<U0615>;<U061B>;/
- <U061E>..<U061F>;<U0621>..<U063A>;<U0640>..<U065E>;<U0660>..<U070D>;/
- <U070F>..<U074A>;<U074D>..<U076D>;<U0780>..<U07B1>;<U07C0>..<U07FA>;/
- <U0901>..<U0939>;<U093C>..<U094D>;<U0950>..<U0954>;<U0958>..<U0970>;/
+ <U05F0>..<U05F4>;<U0600>..<U0603>;<U0606>..<U061B>;/
+ <U061E>..<U061F>;<U0621>..<U065E>;<U0660>..<U070D>;/
+ <U070F>..<U074A>;<U074D>..<U07B1>;<U07C0>..<U07FA>;/
+ <U0901>..<U0939>;<U093C>..<U094D>;<U0950>..<U0954>;<U0958>..<U0972>;/
<U097B>..<U097F>;<U0981>..<U0983>;<U0985>..<U098C>;<U098F>..<U0990>;/
<U0993>..<U09A8>;<U09AA>..<U09B0>;<U09B2>;<U09B6>..<U09B9>;/
<U09BC>..<U09C4>;<U09C7>..<U09C8>;<U09CB>..<U09CE>;<U09D7>;/
<U09DC>..<U09DD>;<U09DF>..<U09E3>;<U09E6>..<U09FA>;<U0A01>..<U0A03>;/
<U0A05>..<U0A0A>;<U0A0F>..<U0A10>;<U0A13>..<U0A28>;<U0A2A>..<U0A30>;/
<U0A32>..<U0A33>;<U0A35>..<U0A36>;<U0A38>..<U0A39>;<U0A3C>;/
- <U0A3E>..<U0A42>;<U0A47>..<U0A48>;<U0A4B>..<U0A4D>;<U0A59>..<U0A5C>;/
- <U0A5E>;<U0A66>..<U0A74>;<U0A81>..<U0A83>;<U0A85>..<U0A8D>;/
+ <U0A3E>..<U0A42>;<U0A47>..<U0A48>;<U0A4B>..<U0A4D>;<U0A51>;/
+ <U0A59>..<U0A5C>;/
+ <U0A5E>;<U0A66>..<U0A75>;<U0A81>..<U0A83>;<U0A85>..<U0A8D>;/
<U0A8F>..<U0A91>;<U0A93>..<U0AA8>;<U0AAA>..<U0AB0>;<U0AB2>..<U0AB3>;/
<U0AB5>..<U0AB9>;<U0ABC>..<U0AC5>;<U0AC7>..<U0AC9>;<U0ACB>..<U0ACD>;/
<U0AD0>;<U0AE0>..<U0AE3>;<U0AE6>..<U0AEF>;<U0AF1>;<U0B01>..<U0B03>;/
<U0B05>..<U0B0C>;<U0B0F>..<U0B10>;<U0B13>..<U0B28>;<U0B2A>..<U0B30>;/
- <U0B32>..<U0B33>;<U0B35>..<U0B39>;<U0B3C>..<U0B43>;<U0B47>..<U0B48>;/
- <U0B4B>..<U0B4D>;<U0B56>..<U0B57>;<U0B5C>..<U0B5D>;<U0B5F>..<U0B61>;/
+ <U0B32>..<U0B33>;<U0B35>..<U0B39>;<U0B3C>..<U0B44>;<U0B47>..<U0B48>;/
+ <U0B4B>..<U0B4D>;<U0B56>..<U0B57>;<U0B5C>..<U0B5D>;<U0B5F>..<U0B63>;/
<U0B66>..<U0B71>;<U0B82>..<U0B83>;<U0B85>..<U0B8A>;<U0B8E>..<U0B90>;/
<U0B92>..<U0B95>;<U0B99>..<U0B9A>;<U0B9C>;<U0B9E>..<U0B9F>;/
<U0BA3>..<U0BA4>;<U0BA8>..<U0BAA>;<U0BAE>..<U0BB9>;<U0BBE>..<U0BC2>;/
- <U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD7>;<U0BE6>..<U0BFA>;/
+ <U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD0>;<U0BD7>;<U0BE6>..<U0BFA>;/
<U0C01>..<U0C03>;<U0C05>..<U0C0C>;<U0C0E>..<U0C10>;<U0C12>..<U0C28>;/
- <U0C2A>..<U0C33>;<U0C35>..<U0C39>;<U0C3E>..<U0C44>;<U0C46>..<U0C48>;/
- <U0C4A>..<U0C4D>;<U0C55>..<U0C56>;<U0C60>..<U0C61>;<U0C66>..<U0C6F>;/
+ <U0C2A>..<U0C33>;<U0C35>..<U0C39>;<U0C3D>..<U0C44>;<U0C46>..<U0C48>;/
+ <U0C4A>..<U0C4D>;<U0C55>..<U0C56>;<U0C58>..<U0C59>;<U0C60>..<U0C63>;/
+ <U0C66>..<U0C6F>;<U0C78>..<U0C7F>;/
<U0C82>..<U0C83>;<U0C85>..<U0C8C>;<U0C8E>..<U0C90>;<U0C92>..<U0CA8>;/
<U0CAA>..<U0CB3>;<U0CB5>..<U0CB9>;<U0CBC>..<U0CC4>;<U0CC6>..<U0CC8>;/
<U0CCA>..<U0CCD>;<U0CD5>..<U0CD6>;<U0CDE>;<U0CE0>..<U0CE3>;/
<U0CE6>..<U0CEF>;<U0CF1>..<U0CF2>;<U0D02>..<U0D03>;<U0D05>..<U0D0C>;/
- <U0D0E>..<U0D10>;<U0D12>..<U0D28>;<U0D2A>..<U0D39>;<U0D3E>..<U0D43>;/
- <U0D46>..<U0D48>;<U0D4A>..<U0D4D>;<U0D57>;<U0D60>..<U0D61>;/
- <U0D66>..<U0D6F>;<U0D82>..<U0D83>;<U0D85>..<U0D96>;<U0D9A>..<U0DB1>;/
+ <U0D0E>..<U0D10>;<U0D12>..<U0D28>;<U0D2A>..<U0D39>;<U0D3D>..<U0D44>;/
+ <U0D46>..<U0D48>;<U0D4A>..<U0D4D>;<U0D57>;<U0D60>..<U0D63>;/
+ <U0D66>..<U0D75>;<U0D79>..<U0D7F>;<U0D82>..<U0D83>;<U0D85>..<U0D96>;/
+ <U0D9A>..<U0DB1>;/
<U0DB3>..<U0DBB>;<U0DBD>;<U0DC0>..<U0DC6>;<U0DCA>;<U0DCF>..<U0DD4>;/
<U0DD6>;<U0DD8>..<U0DDF>;<U0DF2>..<U0DF4>;<U0E01>..<U0E3A>;/
<U0E3F>..<U0E5B>;<U0E81>..<U0E82>;<U0E84>;<U0E87>..<U0E88>;<U0E8A>;/
<U0E8D>;<U0E94>..<U0E97>;<U0E99>..<U0E9F>;<U0EA1>..<U0EA3>;<U0EA5>;/
<U0EA7>;<U0EAA>..<U0EAB>;<U0EAD>..<U0EB9>;<U0EBB>..<U0EBD>;/
<U0EC0>..<U0EC4>;<U0EC6>;<U0EC8>..<U0ECD>;<U0ED0>..<U0ED9>;/
- <U0EDC>..<U0EDD>;<U0F00>..<U0F47>;<U0F49>..<U0F6A>;<U0F71>..<U0F8B>;/
- <U0F90>..<U0F97>;<U0F99>..<U0FBC>;<U0FBE>..<U0FCC>;<U0FCF>..<U0FD1>;/
- <U1000>..<U1021>;<U1023>..<U1027>;<U1029>..<U102A>;<U102C>..<U1032>;/
- <U1036>..<U1039>;<U1040>..<U1059>;<U10A0>..<U10C5>;<U10D0>..<U10FC>;/
+ <U0EDC>..<U0EDD>;<U0F00>..<U0F47>;<U0F49>..<U0F6C>;<U0F71>..<U0F8B>;/
+ <U0F90>..<U0F97>;<U0F99>..<U0FBC>;<U0FBE>..<U0FCC>;<U0FCE>..<U0FD4>;/
+ <U1000>..<U102A>;<U102B>..<U103F>;<U1040>..<U1099>;<U109E>;<U109F>;/
+ <U10A0>..<U10C5>;<U10D0>..<U10FC>;/
<U1100>..<U1159>;<U115F>..<U11A2>;<U11A8>..<U11F9>;<U1200>..<U1248>;/
<U124A>..<U124D>;<U1250>..<U1256>;<U1258>;<U125A>..<U125D>;/
<U1260>..<U1288>;<U128A>..<U128D>;<U1290>..<U12B0>;<U12B2>..<U12B5>;/
@@ -638,37 +699,43 @@ graph /
<U16A0>..<U16F0>;<U1700>..<U170C>;<U170E>..<U1714>;<U1720>..<U1736>;/
<U1740>..<U1753>;<U1760>..<U176C>;<U176E>..<U1770>;<U1772>..<U1773>;/
<U1780>..<U17DD>;<U17E0>..<U17E9>;<U17F0>..<U17F9>;<U1800>..<U180D>;/
- <U1810>..<U1819>;<U1820>..<U1877>;<U1880>..<U18A9>;<U1900>..<U191C>;/
+ <U1810>..<U1819>;<U1820>..<U1877>;<U1880>..<U18AA>;<U1900>..<U191C>;/
<U1920>..<U192B>;<U1930>..<U193B>;<U1940>;<U1944>..<U196D>;/
<U1970>..<U1974>;<U1980>..<U19A9>;<U19B0>..<U19C9>;<U19D0>..<U19D9>;/
<U19DE>..<U1A1B>;<U1A1E>..<U1A1F>;<U1B00>..<U1B4B>;<U1B50>..<U1B7C>;/
- <U1D00>..<U1DCA>;<U1DFE>..<U1E9B>;<U1EA0>..<U1EF9>;<U1F00>..<U1F15>;/
+ <U1B80>..<U1BAA>;<U1BAE>..<U1BB9>;<U1C00>..<U1C37>;<U1C3B>..<U1C49>;/
+ <U1C4D>..<U1C7F>;/
+ <U1D00>..<U1DE6>;<U1DFE>..<U1E9F>;<U1EA0>..<U1EFF>;<U1F00>..<U1F15>;/
<U1F18>..<U1F1D>;<U1F20>..<U1F45>;<U1F48>..<U1F4D>;<U1F50>..<U1F57>;/
<U1F59>;<U1F5B>;<U1F5D>;<U1F5F>..<U1F7D>;<U1F80>..<U1FB4>;/
<U1FB6>..<U1FC4>;<U1FC6>..<U1FD3>;<U1FD6>..<U1FDB>;<U1FDD>..<U1FEF>;/
<U1FF2>..<U1FF4>;<U1FF6>..<U1FFE>;<U2007>;<U200B>..<U2027>;/
- <U202A>..<U205E>;<U2060>..<U2063>;<U206A>..<U2071>;<U2074>..<U208E>;/
- <U2090>..<U2094>;<U20A0>..<U20B5>;<U20D0>..<U20EF>;<U2100>..<U214E>;/
- <U2153>..<U2184>;<U2190>..<U23E7>;<U2400>..<U2426>;<U2440>..<U244A>;/
- <U2460>..<U269C>;<U26A0>..<U26B2>;<U2701>..<U2704>;<U2706>..<U2709>;/
+ <U202A>..<U205E>;<U2060>..<U2064>;<U206A>..<U2071>;<U2074>..<U208E>;/
+ <U2090>..<U2094>;<U20A0>..<U20B5>;<U20D0>..<U20F0>;<U2100>..<U214F>;/
+ <U2153>..<U2188>;<U2190>..<U23E7>;<U2400>..<U2426>;<U2440>..<U244A>;/
+ <U2460>..<U269D>;<U26A0>..<U26C3>;<U2701>..<U2704>;<U2706>..<U2709>;/
<U270C>..<U2727>;<U2729>..<U274B>;<U274D>;<U274F>..<U2752>;<U2756>;/
<U2758>..<U275E>;<U2761>..<U2794>;<U2798>..<U27AF>;<U27B1>..<U27BE>;/
- <U27C0>..<U27CA>;<U27D0>..<U27EB>;<U27F0>..<U2B1A>;<U2B20>..<U2B23>;/
- <U2C00>..<U2C2E>;<U2C30>..<U2C5E>;<U2C60>..<U2C6C>;<U2C74>..<U2C77>;/
+ <U27C0>..<U27CA>;<U27CC>;<U27D0>..<U27EF>;<U27F0>..<U2B4C>;/
+ <U2B50>..<U2B54>;/
+ <U2C00>..<U2C2E>;<U2C30>..<U2C5E>;<U2C60>..<U2C6F>;<U2C71>..<U2C7D>;/
<U2C80>..<U2CEA>;<U2CF9>..<U2D25>;<U2D30>..<U2D65>;<U2D6F>;/
<U2D80>..<U2D96>;<U2DA0>..<U2DA6>;<U2DA8>..<U2DAE>;<U2DB0>..<U2DB6>;/
<U2DB8>..<U2DBE>;<U2DC0>..<U2DC6>;<U2DC8>..<U2DCE>;<U2DD0>..<U2DD6>;/
- <U2DD8>..<U2DDE>;<U2E00>..<U2E17>;<U2E1C>..<U2E1D>;<U2E80>..<U2E99>;/
+ <U2DD8>..<U2DDE>;<U2DE0>..<U2E30>;<U2E80>..<U2E99>;/
<U2E9B>..<U2EF3>;<U2F00>..<U2FD5>;<U2FF0>..<U2FFB>;<U3001>..<U303F>;/
- <U3041>..<U3096>;<U3099>..<U30FF>;<U3105>..<U312C>;<U3131>..<U318E>;/
+ <U3041>..<U3096>;<U3099>..<U30FF>;<U3105>..<U312D>;<U3131>..<U318E>;/
<U3190>..<U31B7>;<U31C0>..<U31CF>;<U31F0>..<U321E>;<U3220>..<U3243>;/
<U3250>..<U32FE>;<U3300>..<U4DB5>;<U4DC0>..<U9FBB>;<UA000>..<UA48C>;/
- <UA490>..<UA4C6>;<UA700>..<UA71A>;<UA720>..<UA721>;<UA800>..<UA82B>;/
- <UA840>..<UA877>;<UAC00>..<UD7A3>;<UE000>..<UFA2D>;<UFA30>..<UFA6A>;/
+ <UA490>..<UA4C6>;<UA500>..<UA62B>;<UA640>..<UA65F>;<UA662>..<UA673>;/
+ <UA67C>..<UA697>;<UA700>..<UA78C>;<UA7FB>..<UA7FF>;<UA800>..<UA82B>;/
+ <UA840>..<UA877>;<UA880>..<UA8C4>;<UA8CE>..<UA8D9>;<UA900>..<UA953>;/
+ <UA95F>;<UAA00>..<UAA36>;<UAA40>..<UAA4D>;<UAA50>..<UAA59>;/
+ <UAA5C>..<UAA5F>;<UAC00>..<UD7A3>;<UE000>..<UFA2D>;<UFA30>..<UFA6A>;/
<UFA70>..<UFAD9>;<UFB00>..<UFB06>;<UFB13>..<UFB17>;<UFB1D>..<UFB36>;/
<UFB38>..<UFB3C>;<UFB3E>;<UFB40>..<UFB41>;<UFB43>..<UFB44>;/
<UFB46>..<UFBB1>;<UFBD3>..<UFD3F>;<UFD50>..<UFD8F>;<UFD92>..<UFDC7>;/
- <UFDF0>..<UFDFD>;<UFE00>..<UFE19>;<UFE20>..<UFE23>;<UFE30>..<UFE52>;/
+ <UFDF0>..<UFDFD>;<UFE00>..<UFE19>;<UFE20>..<UFE26>;<UFE30>..<UFE52>;/
<UFE54>..<UFE66>;<UFE68>..<UFE6B>;<UFE70>..<UFE74>;<UFE76>..<UFEFC>;/
<UFEFF>;<UFF01>..<UFFBE>;<UFFC2>..<UFFC7>;<UFFCA>..<UFFCF>;/
<UFFD2>..<UFFD7>;<UFFDA>..<UFFDC>;<UFFE0>..<UFFE6>;<UFFE8>..<UFFEE>;/
@@ -677,6 +744,8 @@ graph /
<U0001003F>..<U0001004D>;<U00010050>..<U0001005D>;/
<U00010080>..<U000100FA>;<U00010100>..<U00010102>;/
<U00010107>..<U00010133>;<U00010137>..<U0001018A>;/
+ <U00010190>..<U0001019B>;<U000101D0>..<U000101FD>;/
+ <U00010280>..<U0001029C>;<U000102A0>..<U000102D0>;/
<U00010300>..<U0001031E>;<U00010320>..<U00010323>;/
<U00010330>..<U0001034A>;<U00010380>..<U0001039D>;/
<U0001039F>..<U000103C3>;<U000103C8>..<U000103D5>;/
@@ -690,7 +759,7 @@ graph /
<U00010A50>..<U00010A58>;<U00012000>..<U0001236E>;/
<U00012400>..<U00012462>;<U00012470>..<U00012473>;/
<U0001D000>..<U0001D0F5>;<U0001D100>..<U0001D126>;/
- <U0001D12A>..<U0001D1DD>;<U0001D200>..<U0001D245>;/
+ <U0001D129>..<U0001D1DD>;<U0001D200>..<U0001D245>;/
<U0001D300>..<U0001D356>;<U0001D360>..<U0001D371>;/
<U0001D400>..<U0001D454>;<U0001D456>..<U0001D49C>;/
<U0001D49E>..<U0001D49F>;<U0001D4A2>;<U0001D4A5>..<U0001D4A6>;/
@@ -701,57 +770,61 @@ graph /
<U0001D53B>..<U0001D53E>;<U0001D540>..<U0001D544>;<U0001D546>;/
<U0001D54A>..<U0001D550>;<U0001D552>..<U0001D6A5>;/
<U0001D6A8>..<U0001D7CB>;<U0001D7CE>..<U0001D7FF>;/
+ <U0001F000>..<U0001F02B>;<U0001F030>..<U0001F093>;/
<U00020000>..<U0002A6D6>;<U0002F800>..<U0002FA1D>;<U000E0001>;/
<U000E0020>..<U000E007F>;<U000E0100>..<U000E01EF>;/
<U000F0000>..<U000FFFFD>;<U00100000>..<U0010FFFD>
print /
- <U0020>..<U007E>;<U00A0>..<U036F>;<U0374>..<U0375>;<U037A>..<U037E>;/
- <U0384>..<U038A>;<U038C>;<U038E>..<U03A1>;<U03A3>..<U03CE>;/
- <U03D0>..<U0486>;<U0488>..<U0513>;<U0531>..<U0556>;<U0559>..<U055F>;/
+ <U0020>..<U007E>;<U00A0>..<U0377>;<U037A>..<U037E>;/
+ <U0384>..<U038A>;<U038C>;<U038E>..<U03A1>;<U03A3>..<U0486>;/
+ <U0488>..<U0523>;<U0531>..<U0556>;<U0559>..<U055F>;/
<U0561>..<U0587>;<U0589>..<U058A>;<U0591>..<U05C7>;<U05D0>..<U05EA>;/
- <U05F0>..<U05F4>;<U0600>..<U0603>;<U060B>..<U0615>;<U061B>;/
- <U061E>..<U061F>;<U0621>..<U063A>;<U0640>..<U065E>;<U0660>..<U070D>;/
- <U070F>..<U074A>;<U074D>..<U076D>;<U0780>..<U07B1>;<U07C0>..<U07FA>;/
- <U0901>..<U0939>;<U093C>..<U094D>;<U0950>..<U0954>;<U0958>..<U0970>;/
+ <U05F0>..<U05F4>;<U0600>..<U0603>;<U0606>..<U061B>;/
+ <U061E>..<U061F>;<U0621>..<U065E>;<U0660>..<U070D>;/
+ <U070F>..<U074A>;<U074D>..<U07B1>;<U07C0>..<U07FA>;/
+ <U0901>..<U0939>;<U093C>..<U094D>;<U0950>..<U0954>;<U0958>..<U0972>;/
<U097B>..<U097F>;<U0981>..<U0983>;<U0985>..<U098C>;<U098F>..<U0990>;/
<U0993>..<U09A8>;<U09AA>..<U09B0>;<U09B2>;<U09B6>..<U09B9>;/
<U09BC>..<U09C4>;<U09C7>..<U09C8>;<U09CB>..<U09CE>;<U09D7>;/
<U09DC>..<U09DD>;<U09DF>..<U09E3>;<U09E6>..<U09FA>;<U0A01>..<U0A03>;/
<U0A05>..<U0A0A>;<U0A0F>..<U0A10>;<U0A13>..<U0A28>;<U0A2A>..<U0A30>;/
<U0A32>..<U0A33>;<U0A35>..<U0A36>;<U0A38>..<U0A39>;<U0A3C>;/
- <U0A3E>..<U0A42>;<U0A47>..<U0A48>;<U0A4B>..<U0A4D>;<U0A59>..<U0A5C>;/
- <U0A5E>;<U0A66>..<U0A74>;<U0A81>..<U0A83>;<U0A85>..<U0A8D>;/
+ <U0A3E>..<U0A42>;<U0A47>..<U0A48>;<U0A4B>..<U0A4D>;<U0A51>;/
+ <U0A59>..<U0A5C>;/
+ <U0A5E>;<U0A66>..<U0A75>;<U0A81>..<U0A83>;<U0A85>..<U0A8D>;/
<U0A8F>..<U0A91>;<U0A93>..<U0AA8>;<U0AAA>..<U0AB0>;<U0AB2>..<U0AB3>;/
<U0AB5>..<U0AB9>;<U0ABC>..<U0AC5>;<U0AC7>..<U0AC9>;<U0ACB>..<U0ACD>;/
<U0AD0>;<U0AE0>..<U0AE3>;<U0AE6>..<U0AEF>;<U0AF1>;<U0B01>..<U0B03>;/
<U0B05>..<U0B0C>;<U0B0F>..<U0B10>;<U0B13>..<U0B28>;<U0B2A>..<U0B30>;/
- <U0B32>..<U0B33>;<U0B35>..<U0B39>;<U0B3C>..<U0B43>;<U0B47>..<U0B48>;/
- <U0B4B>..<U0B4D>;<U0B56>..<U0B57>;<U0B5C>..<U0B5D>;<U0B5F>..<U0B61>;/
+ <U0B32>..<U0B33>;<U0B35>..<U0B39>;<U0B3C>..<U0B44>;<U0B47>..<U0B48>;/
+ <U0B4B>..<U0B4D>;<U0B56>..<U0B57>;<U0B5C>..<U0B5D>;<U0B5F>..<U0B63>;/
<U0B66>..<U0B71>;<U0B82>..<U0B83>;<U0B85>..<U0B8A>;<U0B8E>..<U0B90>;/
<U0B92>..<U0B95>;<U0B99>..<U0B9A>;<U0B9C>;<U0B9E>..<U0B9F>;/
<U0BA3>..<U0BA4>;<U0BA8>..<U0BAA>;<U0BAE>..<U0BB9>;<U0BBE>..<U0BC2>;/
- <U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD7>;<U0BE6>..<U0BFA>;/
+ <U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD0>;<U0BD7>;<U0BE6>..<U0BFA>;/
<U0C01>..<U0C03>;<U0C05>..<U0C0C>;<U0C0E>..<U0C10>;<U0C12>..<U0C28>;/
- <U0C2A>..<U0C33>;<U0C35>..<U0C39>;<U0C3E>..<U0C44>;<U0C46>..<U0C48>;/
- <U0C4A>..<U0C4D>;<U0C55>..<U0C56>;<U0C60>..<U0C61>;<U0C66>..<U0C6F>;/
+ <U0C2A>..<U0C33>;<U0C35>..<U0C39>;<U0C3D>..<U0C44>;<U0C46>..<U0C48>;/
+ <U0C4A>..<U0C4D>;<U0C55>..<U0C56>;<U0C58>..<U0C59>;<U0C60>..<U0C63>;/
+ <U0C66>..<U0C6F>;<U0C78>..<U0C7F>;/
<U0C82>..<U0C83>;<U0C85>..<U0C8C>;<U0C8E>..<U0C90>;<U0C92>..<U0CA8>;/
<U0CAA>..<U0CB3>;<U0CB5>..<U0CB9>;<U0CBC>..<U0CC4>;<U0CC6>..<U0CC8>;/
<U0CCA>..<U0CCD>;<U0CD5>..<U0CD6>;<U0CDE>;<U0CE0>..<U0CE3>;/
<U0CE6>..<U0CEF>;<U0CF1>..<U0CF2>;<U0D02>..<U0D03>;<U0D05>..<U0D0C>;/
- <U0D0E>..<U0D10>;<U0D12>..<U0D28>;<U0D2A>..<U0D39>;<U0D3E>..<U0D43>;/
- <U0D46>..<U0D48>;<U0D4A>..<U0D4D>;<U0D57>;<U0D60>..<U0D61>;/
- <U0D66>..<U0D6F>;<U0D82>..<U0D83>;<U0D85>..<U0D96>;<U0D9A>..<U0DB1>;/
+ <U0D0E>..<U0D10>;<U0D12>..<U0D28>;<U0D2A>..<U0D39>;<U0D3D>..<U0D44>;/
+ <U0D46>..<U0D48>;<U0D4A>..<U0D4D>;<U0D57>;<U0D60>..<U0D63>;/
+ <U0D66>..<U0D75>;<U0D79>..<U0D7F>;<U0D82>..<U0D83>;<U0D85>..<U0D96>;/
+ <U0D9A>..<U0DB1>;/
<U0DB3>..<U0DBB>;<U0DBD>;<U0DC0>..<U0DC6>;<U0DCA>;<U0DCF>..<U0DD4>;/
<U0DD6>;<U0DD8>..<U0DDF>;<U0DF2>..<U0DF4>;<U0E01>..<U0E3A>;/
<U0E3F>..<U0E5B>;<U0E81>..<U0E82>;<U0E84>;<U0E87>..<U0E88>;<U0E8A>;/
<U0E8D>;<U0E94>..<U0E97>;<U0E99>..<U0E9F>;<U0EA1>..<U0EA3>;<U0EA5>;/
<U0EA7>;<U0EAA>..<U0EAB>;<U0EAD>..<U0EB9>;<U0EBB>..<U0EBD>;/
<U0EC0>..<U0EC4>;<U0EC6>;<U0EC8>..<U0ECD>;<U0ED0>..<U0ED9>;/
- <U0EDC>..<U0EDD>;<U0F00>..<U0F47>;<U0F49>..<U0F6A>;<U0F71>..<U0F8B>;/
- <U0F90>..<U0F97>;<U0F99>..<U0FBC>;<U0FBE>..<U0FCC>;<U0FCF>..<U0FD1>;/
- <U1000>..<U1021>;<U1023>..<U1027>;<U1029>..<U102A>;<U102C>..<U1032>;/
- <U1036>..<U1039>;<U1040>..<U1059>;<U10A0>..<U10C5>;<U10D0>..<U10FC>;/
+ <U0EDC>..<U0EDD>;<U0F00>..<U0F47>;<U0F49>..<U0F6C>;<U0F71>..<U0F8B>;/
+ <U0F90>..<U0F97>;<U0F99>..<U0FBC>;<U0FBE>..<U0FCC>;<U0FCE>..<U0FD4>;/
+ <U1000>..<U102A>;<U102B>..<U103F>;<U1040>..<U1099>;<U109E>;<U109F>;/
+ <U10A0>..<U10C5>;<U10D0>..<U10FC>;/
<U1100>..<U1159>;<U115F>..<U11A2>;<U11A8>..<U11F9>;<U1200>..<U1248>;/
<U124A>..<U124D>;<U1250>..<U1256>;<U1258>;<U125A>..<U125D>;/
<U1260>..<U1288>;<U128A>..<U128D>;<U1290>..<U12B0>;<U12B2>..<U12B5>;/
@@ -761,37 +834,45 @@ print /
<U16A0>..<U16F0>;<U1700>..<U170C>;<U170E>..<U1714>;<U1720>..<U1736>;/
<U1740>..<U1753>;<U1760>..<U176C>;<U176E>..<U1770>;<U1772>..<U1773>;/
<U1780>..<U17DD>;<U17E0>..<U17E9>;<U17F0>..<U17F9>;<U1800>..<U180E>;/
- <U1810>..<U1819>;<U1820>..<U1877>;<U1880>..<U18A9>;<U1900>..<U191C>;/
+ <U1810>..<U1819>;<U1820>..<U1877>;<U1880>..<U18AA>;<U1900>..<U191C>;/
<U1920>..<U192B>;<U1930>..<U193B>;<U1940>;<U1944>..<U196D>;/
<U1970>..<U1974>;<U1980>..<U19A9>;<U19B0>..<U19C9>;<U19D0>..<U19D9>;/
<U19DE>..<U1A1B>;<U1A1E>..<U1A1F>;<U1B00>..<U1B4B>;<U1B50>..<U1B7C>;/
- <U1D00>..<U1DCA>;<U1DFE>..<U1E9B>;<U1EA0>..<U1EF9>;<U1F00>..<U1F15>;/
+ <U1B80>..<U1BAA>;<U1BAE>..<U1BB9>;<U1C00>..<U1C37>;<U1C3B>..<U1C49>;/
+ <U1C4D>..<U1C7F>;/
+ <U1D00>..<U1DE6>;<U1DFE>..<U1E9F>;<U1EA0>..<U1EFF>;<U1F00>..<U1F15>;/
<U1F18>..<U1F1D>;<U1F20>..<U1F45>;<U1F48>..<U1F4D>;<U1F50>..<U1F57>;/
<U1F59>;<U1F5B>;<U1F5D>;<U1F5F>..<U1F7D>;<U1F80>..<U1FB4>;/
<U1FB6>..<U1FC4>;<U1FC6>..<U1FD3>;<U1FD6>..<U1FDB>;<U1FDD>..<U1FEF>;/
- <U1FF2>..<U1FF4>;<U1FF6>..<U1FFE>;<U2000>..<U2027>;<U202A>..<U2063>;/
+ <U1FF2>..<U1FF4>;<U1FF6>..<U1FFE>;<U2000>..<U2027>;<U202A>..<U2064>;/
<U206A>..<U2071>;<U2074>..<U208E>;<U2090>..<U2094>;<U20A0>..<U20B5>;/
- <U20D0>..<U20EF>;<U2100>..<U214E>;<U2153>..<U2184>;<U2190>..<U23E7>;/
- <U2400>..<U2426>;<U2440>..<U244A>;<U2460>..<U269C>;<U26A0>..<U26B2>;/
+ <U20D0>..<U20F0>;<U2100>..<U214F>;<U2153>..<U2188>;<U2190>..<U23E7>;/
+ <U2400>..<U2426>;<U2440>..<U244A>;<U2460>..<U269D>;<U26A0>..<U26C3>;/
<U2701>..<U2704>;<U2706>..<U2709>;<U270C>..<U2727>;<U2729>..<U274B>;/
<U274D>;<U274F>..<U2752>;<U2756>;<U2758>..<U275E>;<U2761>..<U2794>;/
- <U2798>..<U27AF>;<U27B1>..<U27BE>;<U27C0>..<U27CA>;<U27D0>..<U27EB>;/
- <U27F0>..<U2B1A>;<U2B20>..<U2B23>;<U2C00>..<U2C2E>;<U2C30>..<U2C5E>;/
- <U2C60>..<U2C6C>;<U2C74>..<U2C77>;<U2C80>..<U2CEA>;<U2CF9>..<U2D25>;/
+ <U2798>..<U27AF>;<U27B1>..<U27BE>;<U27C0>..<U27CA>;<U27CC>;/
+ <U27D0>..<U27EF>;/
+ <U27F0>..<U2B4C>;<U2B50>..<U2B54>;<U2C00>..<U2C2E>;<U2C30>..<U2C5E>;/
+ <U2C60>..<U2C6F>;<U2C71>..<U2C7D>;<U2C80>..<U2CEA>;<U2CF9>..<U2D25>;/
<U2D30>..<U2D65>;<U2D6F>;<U2D80>..<U2D96>;<U2DA0>..<U2DA6>;/
<U2DA8>..<U2DAE>;<U2DB0>..<U2DB6>;<U2DB8>..<U2DBE>;<U2DC0>..<U2DC6>;/
- <U2DC8>..<U2DCE>;<U2DD0>..<U2DD6>;<U2DD8>..<U2DDE>;<U2E00>..<U2E17>;/
- <U2E1C>..<U2E1D>;<U2E80>..<U2E99>;<U2E9B>..<U2EF3>;<U2F00>..<U2FD5>;/
+ <U2DC8>..<U2DCE>;<U2DD0>..<U2DD6>;<U2DD8>..<U2DDE>;<U2DE0>..<U2E30>;/
+ <U2E80>..<U2E99>;<U2E9B>..<U2EF3>;<U2F00>..<U2FD5>;/
<U2FF0>..<U2FFB>;<U3000>..<U303F>;<U3041>..<U3096>;<U3099>..<U30FF>;/
- <U3105>..<U312C>;<U3131>..<U318E>;<U3190>..<U31B7>;<U31C0>..<U31CF>;/
+ <U3105>..<U312D>;<U3131>..<U318E>;<U3190>..<U31B7>;<U31C0>..<U31CF>;/
<U31F0>..<U321E>;<U3220>..<U3243>;<U3250>..<U32FE>;<U3300>..<U4DB5>;/
- <U4DC0>..<U9FBB>;<UA000>..<UA48C>;<UA490>..<UA4C6>;<UA700>..<UA71A>;/
- <UA720>..<UA721>;<UA800>..<UA82B>;<UA840>..<UA877>;<UAC00>..<UD7A3>;/
+ <U4DC0>..<U9FBB>;<UA000>..<UA48C>;<UA490>..<UA4C6>;<UA500>..<UA62B>;/
+ <UA640>..<UA65F>;<UA662>..<UA673>;<UA67C>..<UA697>;<UA700>..<UA78C>;/
+ <UA7FB>..<UA7FF>;<UA800>..<UA82B>;<UA840>..<UA877>;/
+ <UA880>..<UA8C4>;<UA8CE>..<UA8D9>;<UAC00>..<UD7A3>;/
+ <UA840>..<UA877>;<UA880>..<UA8C4>;<UA8CE>..<UA8D9>;<UA900>..<UA953>;/
+ <UA95F>;<UAA00>..<UAA36>;<UAA40>..<UAA4D>;<UAA50>..<UAA59>;/
+ <UAA5C>..<UAA5F>;/
<UE000>..<UFA2D>;<UFA30>..<UFA6A>;<UFA70>..<UFAD9>;<UFB00>..<UFB06>;/
<UFB13>..<UFB17>;<UFB1D>..<UFB36>;<UFB38>..<UFB3C>;<UFB3E>;/
<UFB40>..<UFB41>;<UFB43>..<UFB44>;<UFB46>..<UFBB1>;<UFBD3>..<UFD3F>;/
<UFD50>..<UFD8F>;<UFD92>..<UFDC7>;<UFDF0>..<UFDFD>;<UFE00>..<UFE19>;/
- <UFE20>..<UFE23>;<UFE30>..<UFE52>;<UFE54>..<UFE66>;<UFE68>..<UFE6B>;/
+ <UFE20>..<UFE26>;<UFE30>..<UFE52>;<UFE54>..<UFE66>;<UFE68>..<UFE6B>;/
<UFE70>..<UFE74>;<UFE76>..<UFEFC>;<UFEFF>;<UFF01>..<UFFBE>;/
<UFFC2>..<UFFC7>;<UFFCA>..<UFFCF>;<UFFD2>..<UFFD7>;<UFFDA>..<UFFDC>;/
<UFFE0>..<UFFE6>;<UFFE8>..<UFFEE>;<UFFF9>..<UFFFD>;/
@@ -800,6 +881,8 @@ print /
<U0001003F>..<U0001004D>;<U00010050>..<U0001005D>;/
<U00010080>..<U000100FA>;<U00010100>..<U00010102>;/
<U00010107>..<U00010133>;<U00010137>..<U0001018A>;/
+ <U00010190>..<U0001019B>;<U000101D0>..<U000101FD>;/
+ <U00010280>..<U0001029C>;<U000102A0>..<U000102D0>;/
<U00010300>..<U0001031E>;<U00010320>..<U00010323>;/
<U00010330>..<U0001034A>;<U00010380>..<U0001039D>;/
<U0001039F>..<U000103C3>;<U000103C8>..<U000103D5>;/
@@ -813,7 +896,7 @@ print /
<U00010A50>..<U00010A58>;<U00012000>..<U0001236E>;/
<U00012400>..<U00012462>;<U00012470>..<U00012473>;/
<U0001D000>..<U0001D0F5>;<U0001D100>..<U0001D126>;/
- <U0001D12A>..<U0001D1DD>;<U0001D200>..<U0001D245>;/
+ <U0001D129>..<U0001D1DD>;<U0001D200>..<U0001D245>;/
<U0001D300>..<U0001D356>;<U0001D360>..<U0001D371>;/
<U0001D400>..<U0001D454>;<U0001D456>..<U0001D49C>;/
<U0001D49E>..<U0001D49F>;<U0001D4A2>;<U0001D4A5>..<U0001D4A6>;/
@@ -824,6 +907,7 @@ print /
<U0001D53B>..<U0001D53E>;<U0001D540>..<U0001D544>;<U0001D546>;/
<U0001D54A>..<U0001D550>;<U0001D552>..<U0001D6A5>;/
<U0001D6A8>..<U0001D7CB>;<U0001D7CE>..<U0001D7FF>;/
+ <U0001F000>..<U0001F02B>;<U0001F030>..<U0001F093>;/
<U00020000>..<U0002A6D6>;<U0002F800>..<U0002FA1D>;<U000E0001>;/
<U000E0020>..<U000E007F>;<U000E0100>..<U000E01EF>;/
<U000F0000>..<U000FFFFD>;<U00100000>..<U0010FFFD>
@@ -844,7 +928,8 @@ toupper /
(<U006D>,<U004D>);(<U006E>,<U004E>);(<U006F>,<U004F>);(<U0070>,<U0050>);/
(<U0071>,<U0051>);(<U0072>,<U0052>);(<U0073>,<U0053>);(<U0074>,<U0054>);/
(<U0075>,<U0055>);(<U0076>,<U0056>);(<U0077>,<U0057>);(<U0078>,<U0058>);/
- (<U0079>,<U0059>);(<U007A>,<U005A>);(<U00B5>,<U039C>);(<U00E0>,<U00C0>);/
+ (<U0079>,<U0059>);(<U007A>,<U005A>);(<U00B5>,<U039C>);(<U00DF>,<U1E9E>);/
+ (<U00E0>,<U00C0>);/
(<U00E1>,<U00C1>);(<U00E2>,<U00C2>);(<U00E3>,<U00C3>);(<U00E4>,<U00C4>);/
(<U00E5>,<U00C5>);(<U00E6>,<U00C6>);(<U00E7>,<U00C7>);(<U00E8>,<U00C8>);/
(<U00E9>,<U00C9>);(<U00EA>,<U00CA>);(<U00EB>,<U00CB>);(<U00EC>,<U00CC>);/
@@ -889,13 +974,16 @@ toupper /
(<U0229>,<U0228>);(<U022B>,<U022A>);(<U022D>,<U022C>);(<U022F>,<U022E>);/
(<U0231>,<U0230>);(<U0233>,<U0232>);(<U023C>,<U023B>);(<U0242>,<U0241>);/
(<U0247>,<U0246>);(<U0249>,<U0248>);(<U024B>,<U024A>);(<U024D>,<U024C>);/
- (<U024F>,<U024E>);(<U0253>,<U0181>);(<U0254>,<U0186>);(<U0256>,<U0189>);/
+ (<U024F>,<U024E>);(<U0250>,<U2C6F>);(<U0251>,<U2C6D>);(<U0253>,<U0181>);/
+ (<U0254>,<U0186>);(<U0256>,<U0189>);/
(<U0257>,<U018A>);(<U0259>,<U018F>);(<U025B>,<U0190>);(<U0260>,<U0193>);/
(<U0263>,<U0194>);(<U0268>,<U0197>);(<U0269>,<U0196>);(<U026B>,<U2C62>);/
- (<U026F>,<U019C>);(<U0272>,<U019D>);(<U0275>,<U019F>);(<U027D>,<U2C64>);/
+ (<U026F>,<U019C>);(<U0271>,<U2C6E>);(<U0272>,<U019D>);(<U0275>,<U019F>);/
+ (<U027D>,<U2C64>);/
(<U0280>,<U01A6>);(<U0283>,<U01A9>);(<U0288>,<U01AE>);(<U0289>,<U0244>);/
(<U028A>,<U01B1>);(<U028B>,<U01B2>);(<U028C>,<U0245>);(<U0292>,<U01B7>);/
- (<U0345>,<U0399>);(<U037B>,<U03FD>);(<U037C>,<U03FE>);(<U037D>,<U03FF>);/
+ (<U0345>,<U0399>);(<U0371>,<U0370>);(<U0373>,<U0372>);(<U0377>,<U0376>);/
+ (<U037B>,<U03FD>);(<U037C>,<U03FE>);(<U037D>,<U03FF>);/
(<U03AC>,<U0386>);(<U03AD>,<U0388>);(<U03AE>,<U0389>);(<U03AF>,<U038A>);/
(<U03B1>,<U0391>);(<U03B2>,<U0392>);(<U03B3>,<U0393>);(<U03B4>,<U0394>);/
(<U03B5>,<U0395>);(<U03B6>,<U0396>);(<U03B7>,<U0397>);(<U03B8>,<U0398>);/
@@ -943,7 +1031,9 @@ toupper /
(<U04F9>,<U04F8>);(<U04FB>,<U04FA>);(<U04FD>,<U04FC>);(<U04FF>,<U04FE>);/
(<U0501>,<U0500>);(<U0503>,<U0502>);(<U0505>,<U0504>);(<U0507>,<U0506>);/
(<U0509>,<U0508>);(<U050B>,<U050A>);(<U050D>,<U050C>);(<U050F>,<U050E>);/
- (<U0511>,<U0510>);(<U0513>,<U0512>);(<U0561>,<U0531>);(<U0562>,<U0532>);/
+ (<U0511>,<U0510>);(<U0513>,<U0512>);(<U0515>,<U0514>);(<U0517>,<U0516>);/
+ (<U0519>,<U0518>);(<U051B>,<U051A>);(<U051D>,<U051C>);(<U051F>,<U051E>);/
+ (<U0521>,<U0520>);(<U0523>,<U0522>);(<U0561>,<U0531>);(<U0562>,<U0532>);/
(<U0563>,<U0533>);(<U0564>,<U0534>);(<U0565>,<U0535>);(<U0566>,<U0536>);/
(<U0567>,<U0537>);(<U0568>,<U0538>);(<U0569>,<U0539>);(<U056A>,<U053A>);/
(<U056B>,<U053B>);(<U056C>,<U053C>);(<U056D>,<U053D>);(<U056E>,<U053E>);/
@@ -983,7 +1073,8 @@ toupper /
(<U1EDF>,<U1EDE>);(<U1EE1>,<U1EE0>);(<U1EE3>,<U1EE2>);(<U1EE5>,<U1EE4>);/
(<U1EE7>,<U1EE6>);(<U1EE9>,<U1EE8>);(<U1EEB>,<U1EEA>);(<U1EED>,<U1EEC>);/
(<U1EEF>,<U1EEE>);(<U1EF1>,<U1EF0>);(<U1EF3>,<U1EF2>);(<U1EF5>,<U1EF4>);/
- (<U1EF7>,<U1EF6>);(<U1EF9>,<U1EF8>);(<U1F00>,<U1F08>);(<U1F01>,<U1F09>);/
+ (<U1EF7>,<U1EF6>);(<U1EF9>,<U1EF8>);(<U1EFB>,<U1EFA>);(<U1EFD>,<U1EFC>);/
+ (<U1EFF>,<U1EFE>);(<U1F00>,<U1F08>);(<U1F01>,<U1F09>);/
(<U1F02>,<U1F0A>);(<U1F03>,<U1F0B>);(<U1F04>,<U1F0C>);(<U1F05>,<U1F0D>);/
(<U1F06>,<U1F0E>);(<U1F07>,<U1F0F>);(<U1F10>,<U1F18>);(<U1F11>,<U1F19>);/
(<U1F12>,<U1F1A>);(<U1F13>,<U1F1B>);(<U1F14>,<U1F1C>);(<U1F15>,<U1F1D>);/
@@ -1032,6 +1123,7 @@ toupper /
(<U2C59>,<U2C29>);(<U2C5A>,<U2C2A>);(<U2C5B>,<U2C2B>);(<U2C5C>,<U2C2C>);/
(<U2C5D>,<U2C2D>);(<U2C5E>,<U2C2E>);(<U2C61>,<U2C60>);(<U2C65>,<U023A>);/
(<U2C66>,<U023E>);(<U2C68>,<U2C67>);(<U2C6A>,<U2C69>);(<U2C6C>,<U2C6B>);/
+ (<U2C73>,<U2C72>);/
(<U2C76>,<U2C75>);(<U2C81>,<U2C80>);(<U2C83>,<U2C82>);(<U2C85>,<U2C84>);/
(<U2C87>,<U2C86>);(<U2C89>,<U2C88>);(<U2C8B>,<U2C8A>);(<U2C8D>,<U2C8C>);/
(<U2C8F>,<U2C8E>);(<U2C91>,<U2C90>);(<U2C93>,<U2C92>);(<U2C95>,<U2C94>);/
@@ -1139,7 +1231,8 @@ tolower /
(<U0232>,<U0233>);(<U023A>,<U2C65>);(<U023B>,<U023C>);(<U023D>,<U019A>);/
(<U023E>,<U2C66>);(<U0241>,<U0242>);(<U0243>,<U0180>);(<U0244>,<U0289>);/
(<U0245>,<U028C>);(<U0246>,<U0247>);(<U0248>,<U0249>);(<U024A>,<U024B>);/
- (<U024C>,<U024D>);(<U024E>,<U024F>);(<U0386>,<U03AC>);(<U0388>,<U03AD>);/
+ (<U024C>,<U024D>);(<U024E>,<U024F>);(<U0370>,<U0371>);(<U0372>,<U0373>);/
+ (<U0376>,<U0377>);(<U0386>,<U03AC>);(<U0388>,<U03AD>);/
(<U0389>,<U03AE>);(<U038A>,<U03AF>);(<U038C>,<U03CC>);(<U038E>,<U03CD>);/
(<U038F>,<U03CE>);(<U0391>,<U03B1>);(<U0392>,<U03B2>);(<U0393>,<U03B3>);/
(<U0394>,<U03B4>);(<U0395>,<U03B5>);(<U0396>,<U03B6>);(<U0397>,<U03B7>);/
@@ -1186,6 +1279,8 @@ tolower /
(<U04FC>,<U04FD>);(<U04FE>,<U04FF>);(<U0500>,<U0501>);(<U0502>,<U0503>);/
(<U0504>,<U0505>);(<U0506>,<U0507>);(<U0508>,<U0509>);(<U050A>,<U050B>);/
(<U050C>,<U050D>);(<U050E>,<U050F>);(<U0510>,<U0511>);(<U0512>,<U0513>);/
+ (<U0514>,<U0515>);(<U0516>,<U0517>);(<U0518>,<U0519>);(<U051A>,<U051B>);/
+ (<U051C>,<U051D>);(<U051E>,<U051F>);(<U0520>,<U0521>);(<U0522>,<U0523>);/
(<U0531>,<U0561>);(<U0532>,<U0562>);(<U0533>,<U0563>);(<U0534>,<U0564>);/
(<U0535>,<U0565>);(<U0536>,<U0566>);(<U0537>,<U0567>);(<U0538>,<U0568>);/
(<U0539>,<U0569>);(<U053A>,<U056A>);(<U053B>,<U056B>);(<U053C>,<U056C>);/
@@ -1223,7 +1318,8 @@ tolower /
(<U1E78>,<U1E79>);(<U1E7A>,<U1E7B>);(<U1E7C>,<U1E7D>);(<U1E7E>,<U1E7F>);/
(<U1E80>,<U1E81>);(<U1E82>,<U1E83>);(<U1E84>,<U1E85>);(<U1E86>,<U1E87>);/
(<U1E88>,<U1E89>);(<U1E8A>,<U1E8B>);(<U1E8C>,<U1E8D>);(<U1E8E>,<U1E8F>);/
- (<U1E90>,<U1E91>);(<U1E92>,<U1E93>);(<U1E94>,<U1E95>);(<U1EA0>,<U1EA1>);/
+ (<U1E90>,<U1E91>);(<U1E92>,<U1E93>);(<U1E94>,<U1E95>);(<U1E9E>,<U00DF>);/
+ (<U1EA0>,<U1EA1>);/
(<U1EA2>,<U1EA3>);(<U1EA4>,<U1EA5>);(<U1EA6>,<U1EA7>);(<U1EA8>,<U1EA9>);/
(<U1EAA>,<U1EAB>);(<U1EAC>,<U1EAD>);(<U1EAE>,<U1EAF>);(<U1EB0>,<U1EB1>);/
(<U1EB2>,<U1EB3>);(<U1EB4>,<U1EB5>);(<U1EB6>,<U1EB7>);(<U1EB8>,<U1EB9>);/
@@ -1235,6 +1331,7 @@ tolower /
(<U1EE2>,<U1EE3>);(<U1EE4>,<U1EE5>);(<U1EE6>,<U1EE7>);(<U1EE8>,<U1EE9>);/
(<U1EEA>,<U1EEB>);(<U1EEC>,<U1EED>);(<U1EEE>,<U1EEF>);(<U1EF0>,<U1EF1>);/
(<U1EF2>,<U1EF3>);(<U1EF4>,<U1EF5>);(<U1EF6>,<U1EF7>);(<U1EF8>,<U1EF9>);/
+ (<U1EFA>,<U1EFB>);(<U1EFC>,<U1EFD>);(<U1EFE>,<U1EFF>);/
(<U1F08>,<U1F00>);(<U1F09>,<U1F01>);(<U1F0A>,<U1F02>);(<U1F0B>,<U1F03>);/
(<U1F0C>,<U1F04>);(<U1F0D>,<U1F05>);(<U1F0E>,<U1F06>);(<U1F0F>,<U1F07>);/
(<U1F18>,<U1F10>);(<U1F19>,<U1F11>);(<U1F1A>,<U1F12>);(<U1F1B>,<U1F13>);/
@@ -1284,7 +1381,8 @@ tolower /
(<U2C29>,<U2C59>);(<U2C2A>,<U2C5A>);(<U2C2B>,<U2C5B>);(<U2C2C>,<U2C5C>);/
(<U2C2D>,<U2C5D>);(<U2C2E>,<U2C5E>);(<U2C60>,<U2C61>);(<U2C62>,<U026B>);/
(<U2C63>,<U1D7D>);(<U2C64>,<U027D>);(<U2C67>,<U2C68>);(<U2C69>,<U2C6A>);/
- (<U2C6B>,<U2C6C>);(<U2C75>,<U2C76>);(<U2C80>,<U2C81>);(<U2C82>,<U2C83>);/
+ (<U2C6B>,<U2C6C>);(<U2C6D>,<U0251>);(<U2C6E>,<U0271>);(<U2C6F>,<U0250>);/
+ (<U2C72>,<U2C73>);(<U2C75>,<U2C76>);(<U2C80>,<U2C81>);(<U2C82>,<U2C83>);/
(<U2C84>,<U2C85>);(<U2C86>,<U2C87>);(<U2C88>,<U2C89>);(<U2C8A>,<U2C8B>);/
(<U2C8C>,<U2C8D>);(<U2C8E>,<U2C8F>);(<U2C90>,<U2C91>);(<U2C92>,<U2C93>);/
(<U2C94>,<U2C95>);(<U2C96>,<U2C97>);(<U2C98>,<U2C99>);(<U2C9A>,<U2C9B>);/
@@ -1431,7 +1529,9 @@ map "totitle"; /
(<U04F9>,<U04F8>);(<U04FB>,<U04FA>);(<U04FD>,<U04FC>);(<U04FF>,<U04FE>);/
(<U0501>,<U0500>);(<U0503>,<U0502>);(<U0505>,<U0504>);(<U0507>,<U0506>);/
(<U0509>,<U0508>);(<U050B>,<U050A>);(<U050D>,<U050C>);(<U050F>,<U050E>);/
- (<U0511>,<U0510>);(<U0513>,<U0512>);(<U0561>,<U0531>);(<U0562>,<U0532>);/
+ (<U0511>,<U0510>);(<U0513>,<U0512>);(<U0515>,<U0514>);(<U0517>,<U0516>);/
+ (<U0519>,<U0518>);(<U051B>,<U051A>);(<U051D>,<U051C>);(<U051F>,<U051E>);/
+ (<U0521>,<U0520>);(<U0523>,<U0522>);(<U0561>,<U0531>);(<U0562>,<U0532>);/
(<U0563>,<U0533>);(<U0564>,<U0534>);(<U0565>,<U0535>);(<U0566>,<U0536>);/
(<U0567>,<U0537>);(<U0568>,<U0538>);(<U0569>,<U0539>);(<U056A>,<U053A>);/
(<U056B>,<U053B>);(<U056C>,<U053C>);(<U056D>,<U053D>);(<U056E>,<U053E>);/
@@ -1574,35 +1674,40 @@ map "totitle"; /
% That is, all combining characters (level 2+3).
class "combining"; /
<U0300>..<U036F>;<U0483>..<U0486>;<U0488>..<U0489>;<U0591>..<U05BD>;/
- <U05BF>;<U05C1>..<U05C2>;<U05C4>..<U05C5>;<U05C7>;<U0610>..<U0615>;/
+ <U05BF>;<U05C1>..<U05C2>;<U05C4>..<U05C5>;<U05C7>;<U0610>..<U061A>;/
<U064B>..<U065E>;<U0670>;<U06D6>..<U06DC>;<U06DE>..<U06E4>;/
<U06E7>..<U06E8>;<U06EA>..<U06ED>;<U0711>;<U0730>..<U074A>;/
<U07A6>..<U07B0>;<U07EB>..<U07F3>;<U0901>..<U0903>;<U093C>;/
<U093E>..<U094D>;<U0951>..<U0954>;<U0962>..<U0963>;<U0981>..<U0983>;/
<U09BC>;<U09BE>..<U09C4>;<U09C7>..<U09C8>;<U09CB>..<U09CD>;<U09D7>;/
<U09E2>..<U09E3>;<U0A01>..<U0A03>;<U0A3C>;<U0A3E>..<U0A42>;/
- <U0A47>..<U0A48>;<U0A4B>..<U0A4D>;<U0A70>..<U0A71>;<U0A81>..<U0A83>;/
+ <U0A47>..<U0A48>;<U0A4B>..<U0A4D>;<U0A51>;<U0A70>..<U0A71>;/
+ <U0A75>;<U0A81>..<U0A83>;/
<U0ABC>;<U0ABE>..<U0AC5>;<U0AC7>..<U0AC9>;<U0ACB>..<U0ACD>;/
- <U0AE2>..<U0AE3>;<U0B01>..<U0B03>;<U0B3C>;<U0B3E>..<U0B43>;/
+ <U0AE2>..<U0AE3>;<U0B01>..<U0B03>;<U0B3C>;<U0B3E>..<U0B44>;/
<U0B47>..<U0B48>;<U0B4B>..<U0B4D>;<U0B56>..<U0B57>;<U0B82>;/
- <U0BBE>..<U0BC2>;<U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD7>;/
+ <U0BBE>..<U0BC2>;<U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD0>;<U0BD7>;/
<U0C01>..<U0C03>;<U0C3E>..<U0C44>;<U0C46>..<U0C48>;<U0C4A>..<U0C4D>;/
- <U0C55>..<U0C56>;<U0C82>..<U0C83>;<U0CBC>;<U0CBE>..<U0CC4>;/
+ <U0C55>..<U0C56>;<U0C62>..<U0C63>;<U0C82>..<U0C83>;<U0CBC>;/
+ <U0CBE>..<U0CC4>;/
<U0CC6>..<U0CC8>;<U0CCA>..<U0CCD>;<U0CD5>..<U0CD6>;<U0CE2>..<U0CE3>;/
- <U0D02>..<U0D03>;<U0D3E>..<U0D43>;<U0D46>..<U0D48>;<U0D4A>..<U0D4D>;/
- <U0D57>;<U0D82>..<U0D83>;<U0DCA>;<U0DCF>..<U0DD4>;<U0DD6>;/
- <U0DD8>..<U0DDF>;<U0DF2>..<U0DF3>;<U0E31>;<U0E34>..<U0E3A>;/
+ <U0D02>..<U0D03>;<U0D3E>..<U0D44>;<U0D46>..<U0D48>;<U0D4A>..<U0D4D>;/
+ <U0D57>;<U0D62>..<U0D63>;<U0D82>..<U0D83>;<U0DCA>;<U0DCF>..<U0DD4>;/
+ <U0DD6>;<U0DD8>..<U0DDF>;<U0DF2>..<U0DF3>;<U0E31>;<U0E34>..<U0E3A>;/
<U0E47>..<U0E4E>;<U0EB1>;<U0EB4>..<U0EB9>;<U0EBB>..<U0EBC>;/
<U0EC8>..<U0ECD>;<U0F18>..<U0F19>;<U0F35>;<U0F37>;<U0F39>;/
<U0F3E>..<U0F3F>;<U0F71>..<U0F84>;<U0F86>..<U0F87>;<U0F90>..<U0F97>;/
- <U0F99>..<U0FBC>;<U0FC6>;<U102C>..<U1032>;<U1036>..<U1039>;/
- <U1056>..<U1059>;<U135F>;<U1712>..<U1714>;<U1732>..<U1734>;/
+ <U0F99>..<U0FBC>;<U0FC6>;<U102B>..<U103F>;/
+ <U1056>..<U1059>;<U105E>..<U1060>;<U1062>..<U1064>;<U1067>..<U106D>;/
+ <U1071>..<U1074>;<U1082>..<U108D>;<U108F>;/
+ <U135F>;<U1712>..<U1714>;<U1732>..<U1734>;/
<U1752>..<U1753>;<U1772>..<U1773>;<U17B6>..<U17D3>;<U17DD>;/
<U180B>..<U180D>;<U18A9>;<U1920>..<U192B>;<U1930>..<U193B>;/
<U19B0>..<U19C0>;<U19C8>..<U19C9>;<U1A17>..<U1A1B>;<U1B00>..<U1B04>;/
- <U1B34>..<U1B44>;<U1B6B>..<U1B73>;<U1DC0>..<U1DCA>;<U1DFE>..<U1DFF>;/
- <U20D0>..<U20EF>;<U302A>..<U302F>;<U3099>..<U309A>;<UA802>;<UA806>;/
- <UA80B>;<UA823>..<UA827>;<UFB1E>;<UFE00>..<UFE0F>;<UFE20>..<UFE23>;/
+ <U1B34>..<U1B44>;<U1B6B>..<U1B73>;<U1DC0>..<U1DE6>;<U1DFE>..<U1DFF>;/
+ <U20D0>..<U20F0>;<U2DE0>..<U2DFF>;<U302A>..<U302F>;<U3099>..<U309A>;/
+ <UA66F>..<UA672>;<UA67C>;<UA67D>;<UA802>;<UA806>;/
+ <UA80B>;<UA823>..<UA827>;<UFB1E>;<UFE00>..<UFE0F>;<UFE20>..<UFE26>;/
<U00010A01>..<U00010A03>;<U00010A05>..<U00010A06>;/
<U00010A0C>..<U00010A0F>;<U00010A38>..<U00010A3A>;<U00010A3F>;/
<U0001D165>..<U0001D169>;<U0001D16D>..<U0001D172>;/
@@ -1619,20 +1724,25 @@ class "combining_level3"; /
<U0962>..<U0963>;<U0981>..<U0983>;<U09BC>;<U09BE>..<U09C4>;/
<U09C7>..<U09C8>;<U09CB>..<U09CD>;<U09D7>;<U09E2>..<U09E3>;/
<U0A01>..<U0A03>;<U0A3C>;<U0A3E>..<U0A42>;<U0A47>..<U0A48>;/
- <U0A4B>..<U0A4D>;<U0A70>..<U0A71>;<U0A81>..<U0A83>;<U0ABC>;/
+ <U0A4B>..<U0A4D>;<U0A51>;<U0A70>..<U0A71>;<U0375>;<U0A81>..<U0A83>;/
+ <U0ABC>;/
<U0ABE>..<U0AC5>;<U0AC7>..<U0AC9>;<U0ACB>..<U0ACD>;<U0AE2>..<U0AE3>;/
- <U0B01>..<U0B03>;<U0B3C>;<U0B3E>..<U0B43>;<U0B47>..<U0B48>;/
+ <U0B01>..<U0B03>;<U0B3C>;<U0B3E>..<U0B44>;<U0B47>..<U0B48>;/
<U0B4B>..<U0B4D>;<U0B56>..<U0B57>;<U0B82>;<U0BBE>..<U0BC2>;/
- <U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD7>;<U0C01>..<U0C03>;/
+ <U0BC6>..<U0BC8>;<U0BCA>..<U0BCD>;<U0BD0>;<U0BD7>;<U0C01>..<U0C03>;/
<U0C3E>..<U0C44>;<U0C46>..<U0C48>;<U0C4A>..<U0C4D>;<U0C55>..<U0C56>;/
+ <U0C62>..<U0C63>;/
<U0C82>..<U0C83>;<U0CBC>;<U0CBE>..<U0CC4>;<U0CC6>..<U0CC8>;/
<U0CCA>..<U0CCD>;<U0CD5>..<U0CD6>;<U0CE2>..<U0CE3>;<U0D02>..<U0D03>;/
- <U0D3E>..<U0D43>;<U0D46>..<U0D48>;<U0D4A>..<U0D4D>;<U0D57>;/
+ <U0D3E>..<U0D44>;<U0D46>..<U0D48>;<U0D4A>..<U0D4D>;<U0D57>;/
+ <U0D62>..<U0D63>;/
<U0D82>..<U0D83>;<U0DCA>;<U0DCF>..<U0DD4>;<U0DD6>;<U0DD8>..<U0DDF>;/
<U0DF2>..<U0DF3>;<U0E31>;<U0E34>..<U0E3A>;<U0E47>..<U0E4E>;<U0EB1>;/
<U0EB4>..<U0EB9>;<U0EBB>..<U0EBC>;<U0EC8>..<U0ECD>;<U0F3E>..<U0F3F>;/
<U0F71>..<U0F81>;<U0F84>;<U0F90>..<U0F97>;<U0F99>..<U0FBC>;/
- <U102C>..<U1032>;<U1036>..<U1039>;<U1056>..<U1059>;<U1712>..<U1714>;/
+ <U102B>..<U103F>;<U1056>..<U1059>;<U105E>..<U1060>;<U1062>..<U1064>;/
+ <U1067>..<U106D>;/
+ <U1071>..<U1074>;<U1082>..<U108D>;<U108F>;<U1712>..<U1714>;/
<U1732>..<U1734>;<U1752>..<U1753>;<U1772>..<U1773>;<U17B6>..<U17D3>;/
<U180B>..<U180D>;<U1920>..<U192B>;<U1930>..<U1938>;<U19B0>..<U19C0>;/
<U19C8>..<U19C9>;<U1A19>..<U1A1B>;<U1B00>..<U1B04>;<U1B34>..<U1B44>;/
diff --git a/libc/localedata/locales/iso14651_t1_common b/libc/localedata/locales/iso14651_t1_common
index 2d1202a3c..cbca3eb86 100644
--- a/libc/localedata/locales/iso14651_t1_common
+++ b/libc/localedata/locales/iso14651_t1_common
@@ -62,6 +62,9 @@ script <ARMENIAN>
script <GEORGIAN>
script <DEVANAGARI>
script <GUJARATI>
+script <TELUGU>
+script <GURUMUKHI>
+script <KANNADA>
# Déclaration des symboles internes / Declaration of internal symbols
#
@@ -475,84 +478,84 @@ collating-symbol <GEORG-FI>
collating-symbol <NUM>
collating-symbol <NKT>
collating-symbol <dv-abbrevation>
-collating-symbol <dom>
-collating-symbol <dvw-shorta>
-collating-symbol <dvw-a>
-collating-symbol <dvw-aa>
-collating-symbol <dvw-i>
-collating-symbol <dvw-ii>
-collating-symbol <dvw-u>
-collating-symbol <dvw-uu>
-collating-symbol <dvw-vocalicr>
-collating-symbol <dvw-vocalicrr>
-collating-symbol <dvw-vocalicl>
-collating-symbol <dvw-vocalicll>
-collating-symbol <dvw-candrae>
-collating-symbol <dvw-shorte>
-collating-symbol <dvw-e>
-collating-symbol <dvw-ai>
-collating-symbol <dvw-candrao>
-collating-symbol <dvw-shorto>
-collating-symbol <dvw-o>
-collating-symbol <dvw-au>
-collating-symbol <d_ka>
-collating-symbol <d_kha>
-collating-symbol <d_ga>
-collating-symbol <d_gga>
-collating-symbol <d_gha>
-collating-symbol <d_nga>
-collating-symbol <d_ca>
-collating-symbol <d_cha>
-collating-symbol <d_ja>
-collating-symbol <d_jja>
-collating-symbol <d_jha>
-collating-symbol <d_nya>
-collating-symbol <d_tta>
-collating-symbol <d_ttha>
-collating-symbol <d_dda>
-collating-symbol <d_ddda>
-collating-symbol <d_ddha>
-collating-symbol <d_nna>
-collating-symbol <d_ta>
-collating-symbol <d_tha>
-collating-symbol <d_da>
-collating-symbol <d_dha>
-collating-symbol <d_na>
-collating-symbol <d_pa>
-collating-symbol <d_pha>
-collating-symbol <d_ba>
+collating-symbol <dom>
+collating-symbol <dvw-shorta>
+collating-symbol <dvw-a>
+collating-symbol <dvw-aa>
+collating-symbol <dvw-i>
+collating-symbol <dvw-ii>
+collating-symbol <dvw-u>
+collating-symbol <dvw-uu>
+collating-symbol <dvw-vocalicr>
+collating-symbol <dvw-vocalicrr>
+collating-symbol <dvw-vocalicl>
+collating-symbol <dvw-vocalicll>
+collating-symbol <dvw-candrae>
+collating-symbol <dvw-shorte>
+collating-symbol <dvw-e>
+collating-symbol <dvw-ai>
+collating-symbol <dvw-candrao>
+collating-symbol <dvw-shorto>
+collating-symbol <dvw-o>
+collating-symbol <dvw-au>
+collating-symbol <d_ka>
+collating-symbol <d_kha>
+collating-symbol <d_ga>
+collating-symbol <d_gga>
+collating-symbol <d_gha>
+collating-symbol <d_nga>
+collating-symbol <d_ca>
+collating-symbol <d_cha>
+collating-symbol <d_ja>
+collating-symbol <d_jja>
+collating-symbol <d_jha>
+collating-symbol <d_nya>
+collating-symbol <d_tta>
+collating-symbol <d_ttha>
+collating-symbol <d_dda>
+collating-symbol <d_ddda>
+collating-symbol <d_ddha>
+collating-symbol <d_nna>
+collating-symbol <d_ta>
+collating-symbol <d_tha>
+collating-symbol <d_da>
+collating-symbol <d_dha>
+collating-symbol <d_na>
+collating-symbol <d_pa>
+collating-symbol <d_pha>
+collating-symbol <d_ba>
collating-symbol <d_bba>
-collating-symbol <d_bha>
-collating-symbol <d_ma>
-collating-symbol <d_ya>
-collating-symbol <d_ra>
-collating-symbol <d_la>
-collating-symbol <d_lla>
-collating-symbol <d_va>
-collating-symbol <d_sha>
-collating-symbol <d_ssa>
-collating-symbol <d_sa>
-collating-symbol <d_ha>
-collating-symbol <d_avagrah>
-collating-symbol <d_glo-stop>
-collating-symbol <dm-aa>
-collating-symbol <dm-i>
-collating-symbol <dm-ii>
-collating-symbol <dm-u>
+collating-symbol <d_bha>
+collating-symbol <d_ma>
+collating-symbol <d_ya>
+collating-symbol <d_ra>
+collating-symbol <d_la>
+collating-symbol <d_lla>
+collating-symbol <d_va>
+collating-symbol <d_sha>
+collating-symbol <d_ssa>
+collating-symbol <d_sa>
+collating-symbol <d_ha>
+collating-symbol <d_avagrah>
+collating-symbol <d_glo-stop>
+collating-symbol <dm-aa>
+collating-symbol <dm-i>
+collating-symbol <dm-ii>
+collating-symbol <dm-u>
collating-symbol <dm-uu>
-collating-symbol <dm-vocalicr>
-collating-symbol <dm-vocalicrr>
-collating-symbol <dm-vocalicl>
-collating-symbol <dm-vocalicll>
-collating-symbol <dm-candrae>
-collating-symbol <dm-shorte>
-collating-symbol <dm-e>
-collating-symbol <dm-ai>
-collating-symbol <dm-candrao>
-collating-symbol <dm-shorto>
-collating-symbol <dm-o>
-collating-symbol <dm-au>
-collating-symbol <dvd-anuswara>
+collating-symbol <dm-vocalicr>
+collating-symbol <dm-vocalicrr>
+collating-symbol <dm-vocalicl>
+collating-symbol <dm-vocalicll>
+collating-symbol <dm-candrae>
+collating-symbol <dm-shorte>
+collating-symbol <dm-e>
+collating-symbol <dm-ai>
+collating-symbol <dm-candrao>
+collating-symbol <dm-shorto>
+collating-symbol <dm-o>
+collating-symbol <dm-au>
+collating-symbol <dvd-anuswara>
collating-symbol <dvd-chandrabindu>
collating-symbol <dvd-visarg>
collating-symbol <d_halant>
@@ -576,82 +579,337 @@ collating-element <gu-tra> from "<U0AA4><U0ACD><U0AB0>"
# defning symbols
collating-symbol <GNKT>
-collating-symbol <gom>
-collating-symbol <gvw-a>
-collating-symbol <gvw-aa>
-collating-symbol <gvw-i>
-collating-symbol <gvw-ii>
-collating-symbol <gvw-u>
-collating-symbol <gvw-uu>
-collating-symbol <gvw-vocalicr>
-collating-symbol <gvw-vocalicrr>
-collating-symbol <gvw-vocalicl>
-collating-symbol <gvw-vocalicll>
-collating-symbol <gvw-candrae>
-collating-symbol <gvw-e>
-collating-symbol <gvw-ai>
-collating-symbol <gvw-candrao>
-collating-symbol <gvw-o>
-collating-symbol <gvw-au>
-collating-symbol <g-ka>
-collating-symbol <g-kha>
-collating-symbol <g-ga>
-collating-symbol <g-gha>
-collating-symbol <g-nga>
-collating-symbol <g-ca>
-collating-symbol <g-cha>
-collating-symbol <g-ja>
-collating-symbol <g-jha>
-collating-symbol <g-nya>
-collating-symbol <g-tta>
-collating-symbol <g-ttha>
-collating-symbol <g-dda>
-collating-symbol <g-ddha>
-collating-symbol <g-nna>
-collating-symbol <g-ta>
-collating-symbol <g-tha>
-collating-symbol <g-da>
-collating-symbol <g-dha>
-collating-symbol <g-na>
-collating-symbol <g-pa>
-collating-symbol <g-pha>
-collating-symbol <g-ba>
-collating-symbol <g-bha>
-collating-symbol <g-ma>
-collating-symbol <g-ya>
-collating-symbol <g-ra>
-collating-symbol <g-la>
-collating-symbol <g-lla>
-collating-symbol <g-va>
-collating-symbol <g-sha>
-collating-symbol <g-ssa>
-collating-symbol <g-sa>
-collating-symbol <g-ha>
+collating-symbol <gom>
+collating-symbol <gvw-a>
+collating-symbol <gvw-aa>
+collating-symbol <gvw-i>
+collating-symbol <gvw-ii>
+collating-symbol <gvw-u>
+collating-symbol <gvw-uu>
+collating-symbol <gvw-vocalicr>
+collating-symbol <gvw-vocalicrr>
+collating-symbol <gvw-vocalicl>
+collating-symbol <gvw-vocalicll>
+collating-symbol <gvw-candrae>
+collating-symbol <gvw-e>
+collating-symbol <gvw-ai>
+collating-symbol <gvw-candrao>
+collating-symbol <gvw-o>
+collating-symbol <gvw-au>
+collating-symbol <g-ka>
+collating-symbol <g-kha>
+collating-symbol <g-ga>
+collating-symbol <g-gha>
+collating-symbol <g-nga>
+collating-symbol <g-ca>
+collating-symbol <g-cha>
+collating-symbol <g-ja>
+collating-symbol <g-jha>
+collating-symbol <g-nya>
+collating-symbol <g-tta>
+collating-symbol <g-ttha>
+collating-symbol <g-dda>
+collating-symbol <g-ddha>
+collating-symbol <g-nna>
+collating-symbol <g-ta>
+collating-symbol <g-tha>
+collating-symbol <g-da>
+collating-symbol <g-dha>
+collating-symbol <g-na>
+collating-symbol <g-pa>
+collating-symbol <g-pha>
+collating-symbol <g-ba>
+collating-symbol <g-bha>
+collating-symbol <g-ma>
+collating-symbol <g-ya>
+collating-symbol <g-ra>
+collating-symbol <g-la>
+collating-symbol <g-lla>
+collating-symbol <g-va>
+collating-symbol <g-sha>
+collating-symbol <g-ssa>
+collating-symbol <g-sa>
+collating-symbol <g-ha>
collating-symbol <g-ksha>
collating-symbol <g-dnya>
collating-symbol <g-shra>
collating-symbol <g-tra>
-collating-symbol <g-avagrah>
-collating-symbol <gm-aa>
-collating-symbol <gm-i>
-collating-symbol <gm-ii>
-collating-symbol <gm-u>
+collating-symbol <g-avagrah>
+collating-symbol <gm-aa>
+collating-symbol <gm-i>
+collating-symbol <gm-ii>
+collating-symbol <gm-u>
collating-symbol <gm-uu>
-collating-symbol <gm-vocalicr>
-collating-symbol <gm-vocalicrr>
-collating-symbol <gm-vocalicl>
-collating-symbol <gm-vocalicll>
-collating-symbol <gm-candrae>
-collating-symbol <gm-e>
-collating-symbol <gm-ai>
-collating-symbol <gm-candrao>
-collating-symbol <gm-o>
-collating-symbol <gm-au>
-collating-symbol <gvd-anuswara>
+collating-symbol <gm-vocalicr>
+collating-symbol <gm-vocalicrr>
+collating-symbol <gm-vocalicl>
+collating-symbol <gm-vocalicll>
+collating-symbol <gm-candrae>
+collating-symbol <gm-e>
+collating-symbol <gm-ai>
+collating-symbol <gm-candrao>
+collating-symbol <gm-o>
+collating-symbol <gm-au>
+collating-symbol <gvd-anuswara>
collating-symbol <gvd-chandrabindu>
collating-symbol <gvd-visarg>
collating-symbol <g-halant>
+# <TELUGU>
+#
+# tvd - denotes Telugu vowel modifier
+# tm - denotes Telugu matras
+# tvw - denotes Telugu vowels
+
+# defining symbols
+collating-symbol <tummu>
+collating-symbol <tvw-a>
+collating-symbol <tvw-aa>
+collating-symbol <tvw-i>
+collating-symbol <tvw-ii>
+collating-symbol <tvw-u>
+collating-symbol <tvw-uu>
+collating-symbol <tvw-vocalicr>
+collating-symbol <tvw-vocalicrr>
+collating-symbol <tvw-vocalicl>
+collating-symbol <tvw-vocalicll>
+collating-symbol <tvw-candrae>
+collating-symbol <tvw-shorte>
+collating-symbol <tvw-e>
+collating-symbol <tvw-ai>
+collating-symbol <tvw-shorto>
+collating-symbol <tvw-o>
+collating-symbol <tvw-au>
+collating-symbol <t-ka>
+collating-symbol <t-kha>
+collating-symbol <t-ga>
+collating-symbol <t-gga>
+collating-symbol <t-gha>
+collating-symbol <t-nga>
+collating-symbol <t-ca>
+collating-symbol <t-tsa>
+collating-symbol <t-cha>
+collating-symbol <t-ja>
+collating-symbol <t-dza>
+collating-symbol <t-jja>
+collating-symbol <t-jha>
+collating-symbol <t-nya>
+collating-symbol <t-tta>
+collating-symbol <t-ttha>
+collating-symbol <t-dda>
+collating-symbol <t-ddda>
+collating-symbol <t-ddha>
+collating-symbol <t-nna>
+collating-symbol <t-ta>
+collating-symbol <t-tha>
+collating-symbol <t-da>
+collating-symbol <t-dha>
+collating-symbol <t-na>
+collating-symbol <t-pa>
+collating-symbol <t-pha>
+collating-symbol <t-ba>
+collating-symbol <t-bba>
+collating-symbol <t-bha>
+collating-symbol <t-ma>
+collating-symbol <t-ya>
+collating-symbol <t-ra>
+collating-symbol <t-rra>
+collating-symbol <t-la>
+collating-symbol <t-lla>
+collating-symbol <t-va>
+collating-symbol <t-sha>
+collating-symbol <t-ssa>
+collating-symbol <t-sa>
+collating-symbol <t-ha>
+collating-symbol <t-avagrah>
+collating-symbol <tm-aa>
+collating-symbol <tm-i>
+collating-symbol <tm-ii>
+collating-symbol <tm-u>
+collating-symbol <tm-uu>
+collating-symbol <tm-vocalicr>
+collating-symbol <tm-vocalicrr>
+collating-symbol <tm-vocalicl>
+collating-symbol <tm-vocalicll>
+collating-symbol <tm-shorte>
+collating-symbol <tm-e>
+collating-symbol <tm-ai>
+collating-symbol <tm-shorto>
+collating-symbol <tm-o>
+collating-symbol <tm-au>
+collating-symbol <tvd-chandrabindu>
+collating-symbol <tvd-anuswara>
+collating-symbol <tvd-visarg>
+collating-symbol <t-halant>
+collating-symbol <t-lenghtmark>
+collating-symbol <t-ailenghtmark>
+
+#<GURUMUKHI>
+#
+# pm - denotes panjabi matras
+# pvw - panjabi denotes vowels
+# pavd - denotes panjabi vowel modifier
+# PNKT - Punjabi Nukta
+
+# defning symbols
+collating-symbol <PNKT>
+collating-symbol <adi-shakti>
+collating-symbol <onkar>
+collating-symbol <ura>
+collating-symbol <pavw-u>
+collating-symbol <pavw-uu>
+collating-symbol <pavw-o>
+collating-symbol <pavw-a>
+collating-symbol <pavw-aa>
+collating-symbol <pavw-ai>
+collating-symbol <pavw-au>
+collating-symbol <iri>
+collating-symbol <pavw-i>
+collating-symbol <pavw-ii>
+collating-symbol <pavw-e>
+collating-symbol <pa-sa>
+collating-symbol <pa-ha>
+collating-symbol <pa-udatta>
+collating-symbol <pa-ka>
+collating-symbol <pa-kha>
+collating-symbol <pa-ga>
+collating-symbol <pa-gha>
+collating-symbol <pa-nga>
+collating-symbol <pa-ca>
+collating-symbol <pa-cha>
+collating-symbol <pa-ja>
+collating-symbol <pa-jha>
+collating-symbol <pa-nya>
+collating-symbol <pa-tta>
+collating-symbol <pa-ttha>
+collating-symbol <pa-dda>
+collating-symbol <pa-ddha>
+collating-symbol <pa-nna>
+collating-symbol <pa-ta>
+collating-symbol <pa-tha>
+collating-symbol <pa-da>
+collating-symbol <pa-dha>
+collating-symbol <pa-na>
+collating-symbol <pa-pa>
+collating-symbol <pa-pha>
+collating-symbol <pa-ba>
+collating-symbol <pa-bha>
+collating-symbol <pa-ma>
+collating-symbol <pa-ya>
+collating-symbol <sign-yakash>
+collating-symbol <pa-ra>
+collating-symbol <pa-la>
+collating-symbol <pa-va>
+collating-symbol <pa-rra>
+collating-symbol <pam-aa>
+collating-symbol <pam-i>
+collating-symbol <pam-ii>
+collating-symbol <pam-u>
+collating-symbol <pam-uu>
+collating-symbol <pam-e>
+collating-symbol <pam-ai>
+collating-symbol <pam-o>
+collating-symbol <pam-au>
+collating-symbol <pavd-adakbindi>
+collating-symbol <pavd-bindi>
+collating-symbol <pavd-visarg>
+collating-symbol <tippi>
+collating-symbol <adak>
+collating-symbol <pa-halant>
+
+#<KANNADA>
+#
+# kvd- denotes vowel modifier
+# km- denotes matras
+# kvw- denotes vowels
+# <KNKT> denotes Nukta characters
+
+collating-element <kn-sign_ii> from "<U0CBF><U0CD5>"
+collating-element <kn-sign_e> from "<U0CC6><U0CD5>"
+collating-element <kn-sign_o> from "<U0CC6><U0CC2><U0CD5>"
+collating-element <kn-sign1_o> from "<U0CCA><U0CD5>"
+collating-element <kn-sign_shorto> from "<U0CC6><U0CC2>"
+collating-element <kn-sign_ai> from "<U0CC6><U0CD6>"
+
+# defning symbols
+
+collating-symbol <sign-jihvamuliya>
+collating-symbol <sign-upadhmaniya>
+collating-symbol <KNKT>
+collating-symbol <kvw-a>
+collating-symbol <kvw-aa>
+collating-symbol <kvw-i>
+collating-symbol <kvw-ii>
+collating-symbol <kvw-u>
+collating-symbol <kvw-uu>
+collating-symbol <kvw-vocalicr>
+collating-symbol <kvw-vocalicrr>
+collating-symbol <kvw-vocalicl>
+collating-symbol <kvw-vocalicll>
+collating-symbol <kvw-shorte>
+collating-symbol <kvw-e>
+collating-symbol <kvw-ai>
+collating-symbol <kvw-shorto>
+collating-symbol <kvw-o>
+collating-symbol <kvw-au>
+collating-symbol <k-ka>
+collating-symbol <k-kha>
+collating-symbol <k-ga>
+collating-symbol <k-gha>
+collating-symbol <k-nga>
+collating-symbol <k-ca>
+collating-symbol <k-cha>
+collating-symbol <k-ja>
+collating-symbol <k-jha>
+collating-symbol <k-nya>
+collating-symbol <k-tta>
+collating-symbol <k-ttha>
+collating-symbol <k-dda>
+collating-symbol <k-ddha>
+collating-symbol <k-nna>
+collating-symbol <k-ta>
+collating-symbol <k-tha>
+collating-symbol <k-da>
+collating-symbol <k-dha>
+collating-symbol <k-na>
+collating-symbol <k-pa>
+collating-symbol <k-pha>
+collating-symbol <k-ba>
+collating-symbol <k-bha>
+collating-symbol <k-ma>
+collating-symbol <k-ya>
+collating-symbol <k-ra>
+collating-symbol <k-rra>
+collating-symbol <k-la>
+collating-symbol <k-va>
+collating-symbol <k-sha>
+collating-symbol <k-ssa>
+collating-symbol <k-sa>
+collating-symbol <k-ha>
+collating-symbol <k-lla>
+collating-symbol <k-fa>
+collating-symbol <k-avagrah>
+collating-symbol <km-aa>
+collating-symbol <km-i>
+collating-symbol <km-ii>
+collating-symbol <km-u>
+collating-symbol <km-uu>
+collating-symbol <km-vocalicr>
+collating-symbol <km-vocalicrr>
+collating-symbol <km-vocalicl>
+collating-symbol <km-vocalicll>
+collating-symbol <km-shorte>
+collating-symbol <km-e>
+collating-symbol <km-ai>
+collating-symbol <km-shorto>
+collating-symbol <km-o>
+collating-symbol <km-au>
+collating-symbol <kvd-anuswara>
+collating-symbol <kvd-visarg>
+collating-symbol <k-halant>
+collating-symbol <k-lenght_mark>
+collating-symbol <k-ai_lenght_mark>
+
# Ordre des symboles internes / Order of internal symbols
#
# SYMB. N°
@@ -1074,83 +1332,83 @@ collating-symbol <g-halant>
<dv-grave>
<dv-acute>
<dv-abbrevation>
-<dom>
-<dvw-shorta>
-<dvw-a>
-<dvw-aa>
-<dvw-i>
-<dvw-ii>
-<dvw-u>
-<dvw-uu>
-<dvw-vocalicr>
-<dvw-vocalicrr>
-<dvw-vocalicl>
-<dvw-vocalicll>
-<dvw-candrae>
-<dvw-shorte>
-<dvw-e>
-<dvw-ai>
-<dvw-candrao>
-<dvw-shorto>
-<dvw-o>
-<dvw-au>
-<d_ka>
-<d_kha>
-<d_ga>
-<d_gga>
-<d_gha>
-<d_nga>
-<d_ca>
-<d_cha>
-<d_ja>
-<d_jja>
-<d_jha>
-<d_nya>
-<d_tta>
-<d_ttha>
-<d_dda>
-<d_ddda>
-<d_ddha>
-<d_nna>
-<d_ta>
-<d_tha>
-<d_da>
-<d_dha>
-<d_na>
-<d_pa>
-<d_pha>
-<d_ba>
+<dom>
+<dvw-shorta>
+<dvw-a>
+<dvw-aa>
+<dvw-i>
+<dvw-ii>
+<dvw-u>
+<dvw-uu>
+<dvw-vocalicr>
+<dvw-vocalicrr>
+<dvw-vocalicl>
+<dvw-vocalicll>
+<dvw-candrae>
+<dvw-shorte>
+<dvw-e>
+<dvw-ai>
+<dvw-candrao>
+<dvw-shorto>
+<dvw-o>
+<dvw-au>
+<d_ka>
+<d_kha>
+<d_ga>
+<d_gga>
+<d_gha>
+<d_nga>
+<d_ca>
+<d_cha>
+<d_ja>
+<d_jja>
+<d_jha>
+<d_nya>
+<d_tta>
+<d_ttha>
+<d_dda>
+<d_ddda>
+<d_ddha>
+<d_nna>
+<d_ta>
+<d_tha>
+<d_da>
+<d_dha>
+<d_na>
+<d_pa>
+<d_pha>
+<d_ba>
<d_bba>
-<d_bha>
-<d_ma>
-<d_ya>
-<d_ra>
-<d_la>
-<d_lla>
-<d_va>
-<d_sha>
-<d_ssa>
-<d_sa>
-<d_ha>
-<d_avagrah>
-<d_glo-stop>
-<dm-aa>
-<dm-i>
-<dm-ii>
-<dm-u>
+<d_bha>
+<d_ma>
+<d_ya>
+<d_ra>
+<d_la>
+<d_lla>
+<d_va>
+<d_sha>
+<d_ssa>
+<d_sa>
+<d_ha>
+<d_avagrah>
+<d_glo-stop>
+<dm-aa>
+<dm-i>
+<dm-ii>
+<dm-u>
<dm-uu>
-<dm-vocalicr>
-<dm-vocalicrr>
-<dm-vocalicl>
-<dm-vocalicll>
-<dm-candrae>
-<dm-shorte>
-<dm-e>
-<dm-ai>
-<dm-candrao>
-<dm-shorto>
-<dm-o>
-<dm-au>
+<dm-vocalicr>
+<dm-vocalicrr>
+<dm-vocalicl>
+<dm-vocalicll>
+<dm-candrae>
+<dm-shorte>
+<dm-e>
+<dm-ai>
+<dm-candrao>
+<dm-shorto>
+<dm-o>
+<dm-au>
<dvd-anuswara>
<dvd-chandrabindu>
<dvd-visarg>
@@ -1161,81 +1419,319 @@ collating-symbol <g-halant>
# collation weights in order
<GNKT>
-<gom>
-<gvw-a>
-<gvw-aa>
-<gvw-i>
-<gvw-ii>
-<gvw-u>
-<gvw-uu>
-<gvw-vocalicr>
-<gvw-vocalicrr>
-<gvw-vocalicl>
-<gvw-vocalicll>
-<gvw-candrae>
-<gvw-e>
-<gvw-ai>
-<gvw-candrao>
-<gvw-o>
-<gvw-au>
-<g-ka>
-<g-kha>
-<g-ga>
-<g-gha>
-<g-nga>
-<g-ca>
-<g-cha>
-<g-ja>
-<g-jha>
-<g-nya>
-<g-tta>
-<g-ttha>
-<g-dda>
-<g-ddha>
-<g-nna>
-<g-ta>
-<g-tha>
-<g-da>
-<g-dha>
-<g-na>
-<g-pa>
-<g-pha>
-<g-ba>
-<g-bha>
-<g-ma>
-<g-ya>
-<g-ra>
-<g-la>
-<g-lla>
-<g-va>
-<g-sha>
-<g-ssa>
-<g-sa>
-<g-ha>
+<gom>
+<gvw-a>
+<gvw-aa>
+<gvw-i>
+<gvw-ii>
+<gvw-u>
+<gvw-uu>
+<gvw-vocalicr>
+<gvw-vocalicrr>
+<gvw-vocalicl>
+<gvw-vocalicll>
+<gvw-candrae>
+<gvw-e>
+<gvw-ai>
+<gvw-candrao>
+<gvw-o>
+<gvw-au>
+<g-ka>
+<g-kha>
+<g-ga>
+<g-gha>
+<g-nga>
+<g-ca>
+<g-cha>
+<g-ja>
+<g-jha>
+<g-nya>
+<g-tta>
+<g-ttha>
+<g-dda>
+<g-ddha>
+<g-nna>
+<g-ta>
+<g-tha>
+<g-da>
+<g-dha>
+<g-na>
+<g-pa>
+<g-pha>
+<g-ba>
+<g-bha>
+<g-ma>
+<g-ya>
+<g-ra>
+<g-la>
+<g-lla>
+<g-va>
+<g-sha>
+<g-ssa>
+<g-sa>
+<g-ha>
<g-ksha>
<g-dnya>
<g-shra>
<g-tra>
-<g-avagrah>
-<gm-aa>
-<gm-i>
-<gm-ii>
-<gm-u>
+<g-avagrah>
+<gm-aa>
+<gm-i>
+<gm-ii>
+<gm-u>
<gm-uu>
-<gm-vocalicr>
-<gm-vocalicrr>
-<gm-vocalicl>
-<gm-vocalicll>
-<gm-candrae>
-<gm-e>
-<gm-ai>
-<gm-candrao>
-<gm-o>
-<gm-au>
+<gm-vocalicr>
+<gm-vocalicrr>
+<gm-vocalicl>
+<gm-vocalicll>
+<gm-candrae>
+<gm-e>
+<gm-ai>
+<gm-candrao>
+<gm-o>
+<gm-au>
<gvd-anuswara>
<gvd-chandrabindu>
<gvd-visarg>
<g-halant>
+#
+#<TELUGU>
+#
+# collation weights in order
+
+<tummu>
+<tvw-a>
+<tvw-aa>
+<tvw-i>
+<tvw-ii>
+<tvw-u>
+<tvw-uu>
+<tvw-vocalicr>
+<tvw-vocalicrr>
+<tvw-vocalicl>
+<tvw-vocalicll>
+<tvw-candrae>
+<tvw-shorte>
+<tvw-e>
+<tvw-ai>
+<tvw-shorto>
+<tvw-o>
+<tvw-au>
+<t-ka>
+<t-kha>
+<t-ga>
+<t-gga>
+<t-gha>
+<t-nga>
+<t-ca>
+<t-tsa>
+<t-cha>
+<t-ja>
+<t-dza>
+<t-jja>
+<t-jha>
+<t-nya>
+<t-tta>
+<t-ttha>
+<t-dda>
+<t-ddda>
+<t-ddha>
+<t-nna>
+<t-ta>
+<t-tha>
+<t-da>
+<t-dha>
+<t-na>
+<t-pa>
+<t-pha>
+<t-ba>
+<t-bba>
+<t-bha>
+<t-ma>
+<t-ya>
+<t-ra>
+<t-rra>
+<t-la>
+<t-lla>
+<t-va>
+<t-sha>
+<t-ssa>
+<t-sa>
+<t-ha>
+<t-avagrah>
+<tm-aa>
+<tm-i>
+<tm-ii>
+<tm-u>
+<tm-uu>
+<tm-vocalicr>
+<tm-vocalicrr>
+<tm-vocalicl>
+<tm-vocalicll>
+<tm-shorte>
+<tm-e>
+<tm-ai>
+<tm-shorto>
+<tm-o>
+<tm-au>
+<tvd-chandrabindu>
+<tvd-anuswara>
+<tvd-visarg>
+<t-halant>
+<t-lenghtmark>
+<t-ailenghtmark>
+
+#
+# <GURUMUKHI>
+#
+# collation weights in order
+
+<PNKT>
+<adak>
+<adi-shakti>
+<onkar>
+<ura>
+<pavw-u>
+<pavw-uu>
+<pavw-o>
+<pavw-a>
+<pavw-aa>
+<pavw-ai>
+<pavw-au>
+<iri>
+<pavw-i>
+<pavw-ii>
+<pavw-e>
+<pa-sa>
+<pa-ha>
+<pa-udatta>
+<pa-ka>
+<pa-kha>
+<pa-ga>
+<pa-gha>
+<pa-nga>
+<pa-ca>
+<pa-cha>
+<pa-ja>
+<pa-jha>
+<pa-nya>
+<pa-tta>
+<pa-ttha>
+<pa-dda>
+<pa-ddha>
+<pa-nna>
+<pa-ta>
+<pa-tha>
+<pa-da>
+<pa-dha>
+<pa-na>
+<pa-pa>
+<pa-pha>
+<pa-ba>
+<pa-bha>
+<pa-ma>
+<pa-ya>
+<sign-yakash>
+<pa-ra>
+<pa-la>
+<pa-va>
+<pa-rra>
+<pam-aa>
+<pam-i>
+<pam-ii>
+<pam-u>
+<pam-uu>
+<pam-e>
+<pam-ai>
+<pam-o>
+<pam-au>
+<pavd-adakbindi>
+<pavd-bindi>
+<pavd-visarg>
+<tippi>
+<pa-halant>
+
+#
+# <KANNADA>
+#
+# collation weights in order
+
+<KNKT>
+<sign-jihvamuliya>
+<sign-upadhmaniya>
+<kvw-a>
+<kvw-aa>
+<kvw-i>
+<kvw-ii>
+<kvw-u>
+<kvw-uu>
+<kvw-vocalicr>
+<kvw-vocalicrr>
+<kvw-vocalicl>
+<kvw-vocalicll>
+<kvw-shorte>
+<kvw-e>
+<kvw-ai>
+<kvw-shorto>
+<kvw-o>
+<kvw-au>
+<k-ka>
+<k-kha>
+<k-ga>
+<k-gha>
+<k-nga>
+<k-ca>
+<k-cha>
+<k-ja>
+<k-jha>
+<k-nya>
+<k-tta>
+<k-ttha>
+<k-dda>
+<k-ddha>
+<k-nna>
+<k-ta>
+<k-tha>
+<k-da>
+<k-dha>
+<k-na>
+<k-pa>
+<k-pha>
+<k-ba>
+<k-bha>
+<k-ma>
+<k-ya>
+<k-ra>
+<k-rra>
+<k-la>
+<k-va>
+<k-sha>
+<k-ssa>
+<k-sa>
+<k-ha>
+<k-lla>
+<k-fa>
+<k-avagrah>
+<km-aa>
+<km-i>
+<km-ii>
+<km-u>
+<km-uu>
+<km-vocalicr>
+<km-vocalicrr>
+<km-vocalicl>
+<km-vocalicll>
+<km-shorte>
+<km-e>
+<km-ai>
+<km-shorto>
+<km-o>
+<km-au>
+<kvd-anuswara>
+<kvd-visarg>
+<k-halant>
+<k-lenght_mark>
+<k-ai_lenght_mark>
order_start <SPECIAL>;forward;backward;forward;forward,position
#
@@ -2071,11 +2567,11 @@ endif
<U0160> <s>;<CAR>;<CAP>;IGNORE # 742 <S<>
<U015E> <s>;<CDI>;<CAP>;IGNORE # 743 <S,>
<U0218> <s>;<CDI>;<CAP>;IGNORE # 744 Ș
-<U1E60> <r>;<PCT>;<CAP>;IGNORE # 745 á¹ 
-<U1E62> <r>;<BPT>;<CAP>;IGNORE # 746 á¹¢
-<U1E64> <r>;<ACA>;<CAP>;<PCT> # 747 Ṥ
-<U1E66> <r>;<CAR>;<CAP>;<PCT> # 748 Ṧ
-<U1E68> <r>;<BPT>;<CAP>;<PCT> # 749 Ṩ
+<U1E60> <s>;<PCT>;<CAP>;IGNORE # 745 á¹ 
+<U1E62> <s>;<BPT>;<CAP>;IGNORE # 746 á¹¢
+<U1E64> <s>;<ACA>;<CAP>;<PCT> # 747 Ṥ
+<U1E66> <s>;<CAR>;<CAP>;<PCT> # 748 Ṧ
+<U1E68> <s>;<BPT>;<CAP>;<PCT> # 749 Ṩ
<U0054> <t>;<BAS>;<CAP>;IGNORE # 750 T
<U0164> <t>;<CAR>;<CAP>;IGNORE # 751 <T<>
<U0166> <t>;<OBL>;<CAP>;IGNORE # 752 <T//>
@@ -3015,99 +3511,99 @@ order_start <DEVANAGARI>;forward;forward;forward;forward,position
<U096D> <7>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
<U096E> <8>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
<U096F> <9>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
-<U0950> <dom> ;<BAS>;<MIN>;IGNORE
+<U0950> <dom> ;<BAS>;<MIN>;IGNORE
<U0904> <dvw-shorta> ;<BAS>;<MIN>;IGNORE
<U0905> <dvw-a> ;<BAS>;<MIN>;IGNORE
<U0906> <dvw-aa> ;<BAS>;<MIN>;IGNORE
<U0907> <dvw-i> ;<BAS>;<MIN>;IGNORE
<U0908> <dvw-ii> ;<BAS>;<MIN>;IGNORE
<U0909> <dvw-u> ;<BAS>;<MIN>;IGNORE
-<U090A> <dvw-uu>;<BAS>;<MIN>;IGNORE
-<U090B> <dvw-vocalicr>;<BAS>;<MIN>;IGNORE
-<U0960> <dvw-vocalicrr>;<BAS>;<MIN>;IGNORE
-<U090C> <dvw-vocalicl>;<BAS>;<MIN>;IGNORE
-<U0961> <dvw-vocalicll>;<BAS>;<MIN>;IGNORE
-<U090D> <dvw-candrae>;<BAS>;<MIN>;IGNORE
-<U090E> <dvw-shorte>;<BAS>;<MIN>;IGNORE
-<U090F> <dvw-e>;<BAS>;<MIN>;IGNORE
-<U0910> <dvw-ai>;<BAS>;<MIN>;IGNORE
-<U0911> <dvw-candrao>;<BAS>;<MIN>;IGNORE
-<U0912> <dvw-shorto>;<BAS>;<MIN>;IGNORE
-<U0913> <dvw-o>;<BAS>;<MIN>;IGNORE
+<U090A> <dvw-uu>;<BAS>;<MIN>;IGNORE
+<U090B> <dvw-vocalicr>;<BAS>;<MIN>;IGNORE
+<U0960> <dvw-vocalicrr>;<BAS>;<MIN>;IGNORE
+<U090C> <dvw-vocalicl>;<BAS>;<MIN>;IGNORE
+<U0961> <dvw-vocalicll>;<BAS>;<MIN>;IGNORE
+<U090D> <dvw-candrae>;<BAS>;<MIN>;IGNORE
+<U090E> <dvw-shorte>;<BAS>;<MIN>;IGNORE
+<U090F> <dvw-e>;<BAS>;<MIN>;IGNORE
+<U0910> <dvw-ai>;<BAS>;<MIN>;IGNORE
+<U0911> <dvw-candrao>;<BAS>;<MIN>;IGNORE
+<U0912> <dvw-shorto>;<BAS>;<MIN>;IGNORE
+<U0913> <dvw-o>;<BAS>;<MIN>;IGNORE
<U0914> <dvw-au>;<BAS>;<MIN>;IGNORE
-<U0915> <d_ka>;<BAS>;<MIN>;IGNORE
-<U0958> <d_ka>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U0916> <d_kha>;<BAS>;<MIN>;IGNORE
-<U0959> <d_kha>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U0917> <d_ga>;<BAS>;<MIN>;IGNORE
-<U095A> <d_ga>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U097B> <d_gga>;<BAS>;<MIN>;IGNORE
+<U0915> <d_ka>;<BAS>;<MIN>;IGNORE
+<U0958> <d_ka>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
+<U0916> <d_kha>;<BAS>;<MIN>;IGNORE
+<U0959> <d_kha>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
+<U0917> <d_ga>;<BAS>;<MIN>;IGNORE
+<U095A> <d_ga>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
+<U097B> <d_gga>;<BAS>;<MIN>;IGNORE
<U0918> <d_gha>;<BAS>;<MIN>;IGNORE
-<U0919> <d_nga>;<BAS>;<MIN>;IGNORE
-<U091A> <d_ca>;<BAS>;<MIN>;IGNORE
-<U091B> <d_cha>;<BAS>;<MIN>;IGNORE
-<U091C> <d_ja>;<BAS>;<MIN>;IGNORE
-<U095B> <d_ja>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U097C> <d_jja>;<BAS>;<MIN>;IGNORE
-<U091D> <d_jha>;<BAS>;<MIN>;IGNORE
-<U091E> <d_nya>;<BAS>;<MIN>;IGNORE
-<U091F> <d_tta>;<BAS>;<MIN>;IGNORE
-<U0920> <d_ttha>;<BAS>;<MIN>;IGNORE
-<U0921> <d_dda>;<BAS>;<MIN>;IGNORE
+<U0919> <d_nga>;<BAS>;<MIN>;IGNORE
+<U091A> <d_ca>;<BAS>;<MIN>;IGNORE
+<U091B> <d_cha>;<BAS>;<MIN>;IGNORE
+<U091C> <d_ja>;<BAS>;<MIN>;IGNORE
+<U095B> <d_ja>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
+<U097C> <d_jja>;<BAS>;<MIN>;IGNORE
+<U091D> <d_jha>;<BAS>;<MIN>;IGNORE
+<U091E> <d_nya>;<BAS>;<MIN>;IGNORE
+<U091F> <d_tta>;<BAS>;<MIN>;IGNORE
+<U0920> <d_ttha>;<BAS>;<MIN>;IGNORE
+<U0921> <d_dda>;<BAS>;<MIN>;IGNORE
<U095C> <d_dda>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U097E> <d_ddda>;<BAS>;<MIN>;IGNORE
-<U0922> <d_ddha>;<BAS>;<MIN>;IGNORE
+<U097E> <d_ddda>;<BAS>;<MIN>;IGNORE
+<U0922> <d_ddha>;<BAS>;<MIN>;IGNORE
<U095D> <d_ddha>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U0923> <d_nna>;<BAS>;<MIN>;IGNORE
-<U0924> <d_ta>;<BAS>;<MIN>;IGNORE
-<U0925> <d_tha>;<BAS>;<MIN>;IGNORE
-<U0926> <d_da>;<BAS>;<MIN>;IGNORE
-<U0927> <d_dha>;<BAS>;<MIN>;IGNORE
-<U0928> <d_na>;<BAS>;<MIN>;IGNORE
+<U0923> <d_nna>;<BAS>;<MIN>;IGNORE
+<U0924> <d_ta>;<BAS>;<MIN>;IGNORE
+<U0925> <d_tha>;<BAS>;<MIN>;IGNORE
+<U0926> <d_da>;<BAS>;<MIN>;IGNORE
+<U0927> <d_dha>;<BAS>;<MIN>;IGNORE
+<U0928> <d_na>;<BAS>;<MIN>;IGNORE
<U0929> <d_na>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U092A> <d_pa>;<BAS>;<MIN>;IGNORE
-<U092B> <d_pha>;<BAS>;<MIN>;IGNORE
+<U092A> <d_pa>;<BAS>;<MIN>;IGNORE
+<U092B> <d_pha>;<BAS>;<MIN>;IGNORE
<U095E> <d_pha>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U092C> <d_ba>;<BAS>;<MIN>;IGNORE
-<U097F> <d_bba>;<BAS>;<MIN>;IGNORE
-<U092D> <d_bha>;<BAS>;<MIN>;IGNORE
-<U092E> <d_ma>;<BAS>;<MIN>;IGNORE
-<U092F> <d_ya>;<BAS>;<MIN>;IGNORE
+<U092C> <d_ba>;<BAS>;<MIN>;IGNORE
+<U097F> <d_bba>;<BAS>;<MIN>;IGNORE
+<U092D> <d_bha>;<BAS>;<MIN>;IGNORE
+<U092E> <d_ma>;<BAS>;<MIN>;IGNORE
+<U092F> <d_ya>;<BAS>;<MIN>;IGNORE
<U095F> <d_ya>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U0930> <d_ra>;<BAS>;<MIN>;IGNORE
+<U0930> <d_ra>;<BAS>;<MIN>;IGNORE
<U0931> <d_ra>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U0932> <d_la>;<BAS>;<MIN>;IGNORE
-<U0933> <d_lla>;<BAS>;<MIN>;IGNORE
+<U0932> <d_la>;<BAS>;<MIN>;IGNORE
+<U0933> <d_lla>;<BAS>;<MIN>;IGNORE
<U0934> <d_lla>;"<BAS><NKT>";"<MIN><MIN>";IGNORE
-<U0935> <d_va>;<BAS>;<MIN>;IGNORE
-<U0936> <d_sha>;<BAS>;<MIN>;IGNORE
-<U0937> <d_ssa>;<BAS>;<MIN>;IGNORE
-<U0938> <d_sa>;<BAS>;<MIN>;IGNORE
-<U0939> <d_ha>;<BAS>;<MIN>;IGNORE
-<U093D> <d_avagrah>;<BAS>;<MIN>;IGNORE
-<U097D> <d_glo-stop>;<BAS>;<MIN>;IGNORE
-<U093E> <dm-aa>;<BAS>;<MIN>;IGNORE
-<U093F> <dm-i>;<BAS>;<MIN>;IGNORE
-<U0940> <dm-ii>;<BAS>;<MIN>;IGNORE
-<U0941> <dm-u>;<BAS>;<MIN>;IGNORE
+<U0935> <d_va>;<BAS>;<MIN>;IGNORE
+<U0936> <d_sha>;<BAS>;<MIN>;IGNORE
+<U0937> <d_ssa>;<BAS>;<MIN>;IGNORE
+<U0938> <d_sa>;<BAS>;<MIN>;IGNORE
+<U0939> <d_ha>;<BAS>;<MIN>;IGNORE
+<U093D> <d_avagrah>;<BAS>;<MIN>;IGNORE
+<U097D> <d_glo-stop>;<BAS>;<MIN>;IGNORE
+<U093E> <dm-aa>;<BAS>;<MIN>;IGNORE
+<U093F> <dm-i>;<BAS>;<MIN>;IGNORE
+<U0940> <dm-ii>;<BAS>;<MIN>;IGNORE
+<U0941> <dm-u>;<BAS>;<MIN>;IGNORE
<U0942> <dm-uu>;<BAS>;<MIN>;IGNORE
-<U0943> <dm-vocalicr>;<BAS>;<MIN>;IGNORE
-<U0944> <dm-vocalicrr>;<BAS>;<MIN>;IGNORE
-<U0962> <dm-vocalicl>;<BAS>;<MIN>;IGNORE
-<U0963> <dm-vocalicll>;<BAS>;<MIN>;IGNORE
-<U0945> <dm-candrae>;<BAS>;<MIN>;IGNORE
-<U0946> <dm-shorte>;<BAS>;<MIN>;IGNORE
-<U0947> <dm-e>;<BAS>;<MIN>;IGNORE
-<U0948> <dm-ai>;<BAS>;<MIN>;IGNORE
-<U0949> <dm-candrao>;<BAS>;<MIN>;IGNORE
-<U094A> <dm-shorto>;<BAS>;<MIN>;IGNORE
-<U094B> <dm-o>;<BAS>;<MIN>;IGNORE
-<U094C> <dm-au>;<BAS>;<MIN>;IGNORE
+<U0943> <dm-vocalicr>;<BAS>;<MIN>;IGNORE
+<U0944> <dm-vocalicrr>;<BAS>;<MIN>;IGNORE
+<U0962> <dm-vocalicl>;<BAS>;<MIN>;IGNORE
+<U0963> <dm-vocalicll>;<BAS>;<MIN>;IGNORE
+<U0945> <dm-candrae>;<BAS>;<MIN>;IGNORE
+<U0946> <dm-shorte>;<BAS>;<MIN>;IGNORE
+<U0947> <dm-e>;<BAS>;<MIN>;IGNORE
+<U0948> <dm-ai>;<BAS>;<MIN>;IGNORE
+<U0949> <dm-candrao>;<BAS>;<MIN>;IGNORE
+<U094A> <dm-shorto>;<BAS>;<MIN>;IGNORE
+<U094B> <dm-o>;<BAS>;<MIN>;IGNORE
+<U094C> <dm-au>;<BAS>;<MIN>;IGNORE
<U0902> <dvd-anuswara>;<BAS>;<MIN>;IGNORE
<U0901> <dvd-chandrabindu>;<BAS>;<MIN>;IGNORE
<U0903> <dvd-visarg>;<BAS>;<MIN>;IGNORE
<U094D> <d_halant>;<BAS>;<MIN>;IGNORE
-<U093C> IGNORE;<NKT>;<MIN>;IGNORE
+<U093C> IGNORE;<NKT>;<MIN>;IGNORE
<U0951> IGNORE;<d_udatta>;<MIN>;IGNORE
<U0952> IGNORE;<d_anudatta>;<MIN>;IGNORE
<U0953> IGNORE;<dv-grave>;<MIN>;IGNORE
@@ -3124,83 +3620,354 @@ order_start <GUJARATI>;forward;forward;forward;forward,position
<U0AED> <7>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
<U0AEE> <8>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
<U0AEF> <9>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
-<U0AD0> <gom> ;<BAS>;<MIN>;IGNORE
+<U0AD0> <gom> ;<BAS>;<MIN>;IGNORE
<U0A85> <gvw-a> ;<BAS>;<MIN>;IGNORE
<U0A86> <gvw-aa> ;<BAS>;<MIN>;IGNORE
<U0A87> <gvw-i> ;<BAS>;<MIN>;IGNORE
<U0A88> <gvw-ii> ;<BAS>;<MIN>;IGNORE
<U0A89> <gvw-u> ;<BAS>;<MIN>;IGNORE
-<U0A8A> <gvw-uu>;<BAS>;<MIN>;IGNORE
-<U0A8B> <gvw-vocalicr>;<BAS>;<MIN>;IGNORE
-<U0AE0> <gvw-vocalicrr>;<BAS>;<MIN>;IGNORE
-<U0A8C> <gvw-vocalicl>;<BAS>;<MIN>;IGNORE
-<U0AE1> <gvw-vocalicll>;<BAS>;<MIN>;IGNORE
-<U0A8D> <gvw-candrae>;<BAS>;<MIN>;IGNORE
-<U0A8F> <gvw-e>;<BAS>;<MIN>;IGNORE
-<U0A90> <gvw-ai>;<BAS>;<MIN>;IGNORE
-<U0A91> <gvw-candrao>;<BAS>;<MIN>;IGNORE
-<U0A93> <gvw-o>;<BAS>;<MIN>;IGNORE
+<U0A8A> <gvw-uu>;<BAS>;<MIN>;IGNORE
+<U0A8B> <gvw-vocalicr>;<BAS>;<MIN>;IGNORE
+<U0AE0> <gvw-vocalicrr>;<BAS>;<MIN>;IGNORE
+<U0A8C> <gvw-vocalicl>;<BAS>;<MIN>;IGNORE
+<U0AE1> <gvw-vocalicll>;<BAS>;<MIN>;IGNORE
+<U0A8D> <gvw-candrae>;<BAS>;<MIN>;IGNORE
+<U0A8F> <gvw-e>;<BAS>;<MIN>;IGNORE
+<U0A90> <gvw-ai>;<BAS>;<MIN>;IGNORE
+<U0A91> <gvw-candrao>;<BAS>;<MIN>;IGNORE
+<U0A93> <gvw-o>;<BAS>;<MIN>;IGNORE
<U0A94> <gvw-au>;<BAS>;<MIN>;IGNORE
-<U0A95> <g-ka>;<BAS>;<MIN>;IGNORE
-<U0A96> <g-kha>;<BAS>;<MIN>;IGNORE
-<U0A97> <g-ga>;<BAS>;<MIN>;IGNORE
+<U0A95> <g-ka>;<BAS>;<MIN>;IGNORE
+<U0A96> <g-kha>;<BAS>;<MIN>;IGNORE
+<U0A97> <g-ga>;<BAS>;<MIN>;IGNORE
<U0A98> <g-gha>;<BAS>;<MIN>;IGNORE
-<U0A99> <g-nga>;<BAS>;<MIN>;IGNORE
-<U0A9A> <g-ca>;<BAS>;<MIN>;IGNORE
-<U0A9B> <g-cha>;<BAS>;<MIN>;IGNORE
-<U0A9C> <g-ja>;<BAS>;<MIN>;IGNORE
-<U0A9D> <g-jha>;<BAS>;<MIN>;IGNORE
-<U0A9E> <g-nya>;<BAS>;<MIN>;IGNORE
-<U0A9F> <g-tta>;<BAS>;<MIN>;IGNORE
-<U0AA0> <g-ttha>;<BAS>;<MIN>;IGNORE
-<U0AA1> <g-dda>;<BAS>;<MIN>;IGNORE
-<U0AA2> <g-ddha>;<BAS>;<MIN>;IGNORE
-<U0AA3> <g-nna>;<BAS>;<MIN>;IGNORE
-<U0AA4> <g-ta>;<BAS>;<MIN>;IGNORE
-<U0AA5> <g-tha>;<BAS>;<MIN>;IGNORE
-<U0AA6> <g-da>;<BAS>;<MIN>;IGNORE
-<U0AA7> <g-dha>;<BAS>;<MIN>;IGNORE
-<U0AA8> <g-na>;<BAS>;<MIN>;IGNORE
-<U0AAA> <g-pa>;<BAS>;<MIN>;IGNORE
-<U0AAB> <g-pha>;<BAS>;<MIN>;IGNORE
-<U0AAC> <g-ba>;<BAS>;<MIN>;IGNORE
-<U0AAD> <g-bha>;<BAS>;<MIN>;IGNORE
-<U0AAE> <g-ma>;<BAS>;<MIN>;IGNORE
-<U0AAF> <g-ya>;<BAS>;<MIN>;IGNORE
-<U0AB0> <g-ra>;<BAS>;<MIN>;IGNORE
-<U0AB2> <g-la>;<BAS>;<MIN>;IGNORE
-<U0AB3> <g-lla>;<BAS>;<MIN>;IGNORE
-<U0AB5> <g-va>;<BAS>;<MIN>;IGNORE
-<U0AB6> <g-sha>;<BAS>;<MIN>;IGNORE
-<U0AB7> <g-ssa>;<BAS>;<MIN>;IGNORE
-<U0AB8> <g-sa>;<BAS>;<MIN>;IGNORE
-<U0AB9> <g-ha>;<BAS>;<MIN>;IGNORE
-<gu-ksha> <g-ksha>;<BAS>;<MIN>;IGNORE
-<gu-dnya> <g-dnya>;<BAS>;<MIN>;IGNORE
+<U0A99> <g-nga>;<BAS>;<MIN>;IGNORE
+<U0A9A> <g-ca>;<BAS>;<MIN>;IGNORE
+<U0A9B> <g-cha>;<BAS>;<MIN>;IGNORE
+<U0A9C> <g-ja>;<BAS>;<MIN>;IGNORE
+<U0A9D> <g-jha>;<BAS>;<MIN>;IGNORE
+<U0A9E> <g-nya>;<BAS>;<MIN>;IGNORE
+<U0A9F> <g-tta>;<BAS>;<MIN>;IGNORE
+<U0AA0> <g-ttha>;<BAS>;<MIN>;IGNORE
+<U0AA1> <g-dda>;<BAS>;<MIN>;IGNORE
+<U0AA2> <g-ddha>;<BAS>;<MIN>;IGNORE
+<U0AA3> <g-nna>;<BAS>;<MIN>;IGNORE
+<U0AA4> <g-ta>;<BAS>;<MIN>;IGNORE
+<U0AA5> <g-tha>;<BAS>;<MIN>;IGNORE
+<U0AA6> <g-da>;<BAS>;<MIN>;IGNORE
+<U0AA7> <g-dha>;<BAS>;<MIN>;IGNORE
+<U0AA8> <g-na>;<BAS>;<MIN>;IGNORE
+<U0AAA> <g-pa>;<BAS>;<MIN>;IGNORE
+<U0AAB> <g-pha>;<BAS>;<MIN>;IGNORE
+<U0AAC> <g-ba>;<BAS>;<MIN>;IGNORE
+<U0AAD> <g-bha>;<BAS>;<MIN>;IGNORE
+<U0AAE> <g-ma>;<BAS>;<MIN>;IGNORE
+<U0AAF> <g-ya>;<BAS>;<MIN>;IGNORE
+<U0AB0> <g-ra>;<BAS>;<MIN>;IGNORE
+<U0AB2> <g-la>;<BAS>;<MIN>;IGNORE
+<U0AB3> <g-lla>;<BAS>;<MIN>;IGNORE
+<U0AB5> <g-va>;<BAS>;<MIN>;IGNORE
+<U0AB6> <g-sha>;<BAS>;<MIN>;IGNORE
+<U0AB7> <g-ssa>;<BAS>;<MIN>;IGNORE
+<U0AB8> <g-sa>;<BAS>;<MIN>;IGNORE
+<U0AB9> <g-ha>;<BAS>;<MIN>;IGNORE
+<gu-ksha> <g-ksha>;<BAS>;<MIN>;IGNORE
+<gu-dnya> <g-dnya>;<BAS>;<MIN>;IGNORE
<gu-shra> <g-shra>;<BAS>;<MIN>;IGNORE
<gu-tra> <g-tra>;<BAS>;<MIN>;IGNORE
-<U0ABD> <g-avagrah>;<BAS>;<MIN>;IGNORE
-<U0ABE> <gm-aa>;<BAS>;<MIN>;IGNORE
-<U0ABF> <gm-i>;<BAS>;<MIN>;IGNORE
-<U0AC0> <gm-ii>;<BAS>;<MIN>;IGNORE
-<U0AC1> <gm-u>;<BAS>;<MIN>;IGNORE
+<U0ABD> <g-avagrah>;<BAS>;<MIN>;IGNORE
+<U0ABE> <gm-aa>;<BAS>;<MIN>;IGNORE
+<U0ABF> <gm-i>;<BAS>;<MIN>;IGNORE
+<U0AC0> <gm-ii>;<BAS>;<MIN>;IGNORE
+<U0AC1> <gm-u>;<BAS>;<MIN>;IGNORE
<U0AC2> <gm-uu>;<BAS>;<MIN>;IGNORE
-<U0AC3> <gm-vocalicr>;<BAS>;<MIN>;IGNORE
-<U0AC4> <gm-vocalicrr>;<BAS>;<MIN>;IGNORE
-<U0AE2> <gm-vocalicl>;<BAS>;<MIN>;IGNORE
-<U0AE3> <gm-vocalicll>;<BAS>;<MIN>;IGNORE
-<U0AC5> <gm-candrae>;<BAS>;<MIN>;IGNORE
-<U0AC7> <gm-e>;<BAS>;<MIN>;IGNORE
-<U0AC8> <gm-ai>;<BAS>;<MIN>;IGNORE
-<U0AC9> <gm-candrao>;<BAS>;<MIN>;IGNORE
-<U0ACB> <gm-o>;<BAS>;<MIN>;IGNORE
-<U0ACC> <gm-au>;<BAS>;<MIN>;IGNORE
+<U0AC3> <gm-vocalicr>;<BAS>;<MIN>;IGNORE
+<U0AC4> <gm-vocalicrr>;<BAS>;<MIN>;IGNORE
+<U0AE2> <gm-vocalicl>;<BAS>;<MIN>;IGNORE
+<U0AE3> <gm-vocalicll>;<BAS>;<MIN>;IGNORE
+<U0AC5> <gm-candrae>;<BAS>;<MIN>;IGNORE
+<U0AC7> <gm-e>;<BAS>;<MIN>;IGNORE
+<U0AC8> <gm-ai>;<BAS>;<MIN>;IGNORE
+<U0AC9> <gm-candrao>;<BAS>;<MIN>;IGNORE
+<U0ACB> <gm-o>;<BAS>;<MIN>;IGNORE
+<U0ACC> <gm-au>;<BAS>;<MIN>;IGNORE
<U0A82> <gvd-anuswara>;<BAS>;<MIN>;IGNORE
<U0A81> <gvd-chandrabindu>;<BAS>;<MIN>;IGNORE
<U0A83> <gvd-visarg>;<BAS>;<MIN>;IGNORE
<U0ACD> <g-halant>;<BAS>;<MIN>;IGNORE
<U0ABC> IGNORE;<GNKT>;<MIN>;IGNORE
+order_start <TELUGU>;forward;forward;forward;forward,position
+<U0C66> <0>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C78> <0>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C67> <1>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C79> <1>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C7C> <1>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C68> <2>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C7A> <2>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C7D> <2>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C69> <3>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C7B> <3>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C7E> <3>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C6A> <4>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C6B> <5>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C6C> <6>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C6D> <7>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C6E> <8>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C6F> <9>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0C7F> <tummu> ;<BAS>;<MIN>;IGNORE
+<U0C05> <tvw-a> ;<BAS>;<MIN>;IGNORE
+<U0C06> <tvw-aa> ;<BAS>;<MIN>;IGNORE
+<U0C07> <tvw-i> ;<BAS>;<MIN>;IGNORE
+<U0C08> <tvw-ii> ;<BAS>;<MIN>;IGNORE
+<U0C09> <tvw-u> ;<BAS>;<MIN>;IGNORE
+<U0C0A> <tvw-uu>;<BAS>;<MIN>;IGNORE
+<U0C0B> <tvw-vocalicr>;<BAS>;<MIN>;IGNORE
+<U0C60> <tvw-vocalicrr>;<BAS>;<MIN>;IGNORE
+<U0C0C> <tvw-vocalicl>;<BAS>;<MIN>;IGNORE
+<U0C61> <tvw-vocalicll>;<BAS>;<MIN>;IGNORE
+<U0C0E> <tvw-shorte>;<BAS>;<MIN>;IGNORE
+<U0C0F> <tvw-e>;<BAS>;<MIN>;IGNORE
+<U0C10> <tvw-ai>;<BAS>;<MIN>;IGNORE
+<U0C12> <tvw-shorto>;<BAS>;<MIN>;IGNORE
+<U0C13> <tvw-o>;<BAS>;<MIN>;IGNORE
+<U0C14> <tvw-au>;<BAS>;<MIN>;IGNORE
+<U0C15> <t-ka>;<BAS>;<MIN>;IGNORE
+<U0C16> <t-kha>;<BAS>;<MIN>;IGNORE
+<U0C17> <t-ga>;<BAS>;<MIN>;IGNORE
+<U0C18> <t-gha>;<BAS>;<MIN>;IGNORE
+<U0C19> <t-nga>;<BAS>;<MIN>;IGNORE
+<U0C1A> <t-ca>;<BAS>;<MIN>;IGNORE
+<U0C58> <t-tsa>;<BAS>;<MIN>;IGNORE
+<U0C1B> <t-cha>;<BAS>;<MIN>;IGNORE
+<U0C1C> <t-ja>;<BAS>;<MIN>;IGNORE
+<U0C59> <t-dza>;<BAS>;<MIN>;IGNORE
+<U0C1D> <t-jha>;<BAS>;<MIN>;IGNORE
+<U0C1E> <t-nya>;<BAS>;<MIN>;IGNORE
+<U0C1F> <t-tta>;<BAS>;<MIN>;IGNORE
+<U0C20> <t-ttha>;<BAS>;<MIN>;IGNORE
+<U0C21> <t-dda>;<BAS>;<MIN>;IGNORE
+<U0C22> <t-ddha>;<BAS>;<MIN>;IGNORE
+<U0C23> <t-nna>;<BAS>;<MIN>;IGNORE
+<U0C24> <t-ta>;<BAS>;<MIN>;IGNORE
+<U0C25> <t-tha>;<BAS>;<MIN>;IGNORE
+<U0C26> <t-da>;<BAS>;<MIN>;IGNORE
+<U0C27> <t-dha>;<BAS>;<MIN>;IGNORE
+<U0C28> <t-na>;<BAS>;<MIN>;IGNORE
+<U0C2A> <t-pa>;<BAS>;<MIN>;IGNORE
+<U0C2B> <t-pha>;<BAS>;<MIN>;IGNORE
+<U0C2C> <t-ba>;<BAS>;<MIN>;IGNORE
+<U0C2D> <t-bha>;<BAS>;<MIN>;IGNORE
+<U0C2E> <t-ma>;<BAS>;<MIN>;IGNORE
+<U0C2F> <t-ya>;<BAS>;<MIN>;IGNORE
+<U0C30> <t-ra>;<BAS>;<MIN>;IGNORE
+<U0C31> <t-rra>;<BAS>;<MIN>;IGNORE
+<U0C32> <t-la>;<BAS>;<MIN>;IGNORE
+<U0C33> <t-lla>;<BAS>;<MIN>;IGNORE
+<U0C35> <t-va>;<BAS>;<MIN>;IGNORE
+<U0C36> <t-sha>;<BAS>;<MIN>;IGNORE
+<U0C37> <t-ssa>;<BAS>;<MIN>;IGNORE
+<U0C38> <t-sa>;<BAS>;<MIN>;IGNORE
+<U0C39> <t-ha>;<BAS>;<MIN>;IGNORE
+<U0C3D> <t-avagrah>;<BAS>;<MIN>;IGNORE
+<U0C3E> <tm-aa>;<BAS>;<MIN>;IGNORE
+<U0C3F> <tm-i>;<BAS>;<MIN>;IGNORE
+<U0C40> <tm-ii>;<BAS>;<MIN>;IGNORE
+<U0C41> <tm-u>;<BAS>;<MIN>;IGNORE
+<U0C42> <tm-uu>;<BAS>;<MIN>;IGNORE
+<U0C43> <tm-vocalicr>;<BAS>;<MIN>;IGNORE
+<U0C44> <tm-vocalicrr>;<BAS>;<MIN>;IGNORE
+<U0C62> <tm-vocalicl>;<BAS>;<MIN>;IGNORE
+<U0C63> <tm-vocalicll>;<BAS>;<MIN>;IGNORE
+<U0C46> <tm-shorte>;<BAS>;<MIN>;IGNORE
+<U0C47> <tm-e>;<BAS>;<MIN>;IGNORE
+<U0C48> <tm-ai>;<BAS>;<MIN>;IGNORE
+<U0C4A> <tm-shorto>;<BAS>;<MIN>;IGNORE
+<U0C4B> <tm-o>;<BAS>;<MIN>;IGNORE
+<U0C4C> <tm-au>;<BAS>;<MIN>;IGNORE
+<U0C01> <tvd-chandrabindu>;<BAS>;<MIN>;IGNORE
+<U0C02> <tvd-anuswara>;<BAS>;<MIN>;IGNORE
+<U0C03> <tvd-visarg>;<BAS>;<MIN>;IGNORE
+<U0C4D> <t-halant>;<BAS>;<MIN>;IGNORE
+<U0C55> <t-lenghtmark>;<BAS>;<MIN>;IGNORE
+<U0C56> <t-ailenghtmark>;<BAS>;<MIN>;IGNORE
+
+order_start <GURUMUKHI>;forward;forward;forward;forward,position
+<U0A66> <0>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0A67> <1>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0A68> <2>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0A69> <3>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0A6A> <4>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0A6B> <5>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0A6C> <6>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0A6D> <7>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0A6E> <8>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0A6F> <9>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U262c> <adi-shakti>;<BAS>;<MIN>;IGNORE
+<U0A74> <onkar>;<BAS>;<MIN>;IGNORE
+<U0A73> <ura>;<BAS>;<MIN>;IGNORE
+<U0A09> <pavw-u> ;<BAS>;<MIN>;IGNORE
+<U0A0A> <pavw-uu>;<BAS>;<MIN>;IGNORE
+<U0A13> <pavw-o>;<BAS>;<MIN>;IGNORE
+<U0A05> <pavw-a> ;<BAS>;<MIN>;IGNORE
+<U0A06> <pavw-aa> ;<BAS>;<MIN>;IGNORE
+<U0A10> <pavw-ai>;<BAS>;<MIN>;IGNORE
+<U0A14> <pavw-au>;<BAS>;<MIN>;IGNORE
+<U0A72> <iri>;<BAS>;<MIN>;IGNORE
+<U0A07> <pavw-i> ;<BAS>;<MIN>;IGNORE
+<U0A08> <pavw-ii> ;<BAS>;<MIN>;IGNORE
+<U0A0F> <pavw-e>;<BAS>;<MIN>;IGNORE
+<U0A38> <pa-sa>;<BAS>;<MIN>;IGNORE
+<U0A36> <pa-sa>;"<BAS><PNKT>";"<MIN><MIN>";IGNORE
+<U0A39> <pa-ha>;<BAS>;<MIN>;IGNORE
+<U0A51> <pa-udatta>;<BAS>;<MIN>;IGNORE
+<U0A15> <pa-ka>;<BAS>;<MIN>;IGNORE
+<U0A16> <pa-kha>;<BAS>;<MIN>;IGNORE
+<U0A59> <pa-kha>;"<BAS><PNKT>";"<MIN><MIN>";IGNORE
+<U0A17> <pa-ga>;<BAS>;<MIN>;IGNORE
+<U0A5A> <pa-ga>;"<BAS><PNKT>";"<MIN><MIN>";IGNORE
+<U0A18> <pa-gha>;<BAS>;<MIN>;IGNORE
+<U0A19> <pa-nga>;<BAS>;<MIN>;IGNORE
+<U0A1A> <pa-ca>;<BAS>;<MIN>;IGNORE
+<U0A1B> <pa-cha>;<BAS>;<MIN>;IGNORE
+<U0A1C> <pa-ja>;<BAS>;<MIN>;IGNORE
+<U0A5B> <pa-ja>;"<BAS><PNKT>";"<MIN><MIN>";IGNORE
+<U0A1D> <pa-jha>;<BAS>;<MIN>;IGNORE
+<U0A1E> <pa-nya>;<BAS>;<MIN>;IGNORE
+<U0A1F> <pa-tta>;<BAS>;<MIN>;IGNORE
+<U0A20> <pa-ttha>;<BAS>;<MIN>;IGNORE
+<U0A21> <pa-dda>;<BAS>;<MIN>;IGNORE
+<U0A22> <pa-ddha>;<BAS>;<MIN>;IGNORE
+<U0A23> <pa-nna>;<BAS>;<MIN>;IGNORE
+<U0A24> <pa-ta>;<BAS>;<MIN>;IGNORE
+<U0A25> <pa-tha>;<BAS>;<MIN>;IGNORE
+<U0A26> <pa-da>;<BAS>;<MIN>;IGNORE
+<U0A27> <pa-dha>;<BAS>;<MIN>;IGNORE
+<U0A28> <pa-na>;<BAS>;<MIN>;IGNORE
+<U0A2A> <pa-pa>;<BAS>;<MIN>;IGNORE
+<U0A2B> <pa-pha>;<BAS>;<MIN>;IGNORE
+<U0A5E> <pa-pha>;"<BAS><PNKT>";"<MIN><MIN>";IGNORE
+<U0A2C> <pa-ba>;<BAS>;<MIN>;IGNORE
+<U0A2D> <pa-bha>;<BAS>;<MIN>;IGNORE
+<U0A2E> <pa-ma>;<BAS>;<MIN>;IGNORE
+<U0A2F> <pa-ya>;<BAS>;<MIN>;IGNORE
+<U0A75> <sign-yakash>;<BAS>;<MIN>;IGNORE
+<U0A30> <pa-ra>;<BAS>;<MIN>;IGNORE
+<U0A32> <pa-la>;<BAS>;<MIN>;IGNORE
+<U0A33> <pa-la>;"<BAS><PNKT>";"<MIN><MIN>";IGNORE
+<U0A35> <pa-va>;<BAS>;<MIN>;IGNORE
+<U0A5C> <pa-rra>;<BAS>;<MIN>;IGNORE
+<U0A3E> <pam-aa>;<BAS>;<MIN>;IGNORE
+<U0A3F> <pam-i>;<BAS>;<MIN>;IGNORE
+<U0A40> <pam-ii>;<BAS>;<MIN>;IGNORE
+<U0A41> <pam-u>;<BAS>;<MIN>;IGNORE
+<U0A42> <pam-uu>;<BAS>;<MIN>;IGNORE
+<U0A47> <pam-e>;<BAS>;<MIN>;IGNORE
+<U0A48> <pam-ai>;<BAS>;<MIN>;IGNORE
+<U0A4B> <pam-o>;<BAS>;<MIN>;IGNORE
+<U0A4C> <pam-au>;<BAS>;<MIN>;IGNORE
+<U0A01> <pavd-adakbindi>;<BAS>;<MIN>;IGNORE
+<U0A02> <pavd-bindi>;<BAS>;<MIN>;IGNORE
+<U0A03> <pavd-visarg>;<BAS>;<MIN>;IGNORE
+<U0A70> <tippi>;<BAS>;<MIN>;IGNORE
+<U0A4D> <pa-halant>;<BAS>;<MIN>;IGNORE
+<U0A3C> IGNORE;<PNKT>;<MIN>;IGNORE
+<U0A71> IGNORE;<adak>;<MIN>;IGNORE
+
+order_start <KANNADA>;forward;forward;forward;forward,position
+<U0CE6> <0>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CE7> <1>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CE8> <2>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CE9> <3>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CEA> <4>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CEB> <5>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CEC> <6>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CED> <7>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CEE> <8>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CEF> <9>;"<BAS><NUM>";"<MIN><MIN>";IGNORE
+<U0CF1> <sign-jihvamuliya>;<BAS>;<MIN>;IGNORE
+<U0CF2> <sign-upadhmaniya>;<BAS>;<MIN>;IGNORE
+<U0C85> <kvw-a>;<BAS>;<MIN>;IGNORE
+<U0C86> <kvw-aa>;<BAS>;<MIN>;IGNORE
+<U0C87> <kvw-i>;<BAS>;<MIN>;IGNORE
+<U0C88> <kvw-ii>;<BAS>;<MIN>;IGNORE
+<U0C89> <kvw-u>;<BAS>;<MIN>;IGNORE
+<U0C8A> <kvw-uu>;<BAS>;<MIN>;IGNORE
+<U0C8B> <kvw-vocalicr>;<BAS>;<MIN>;IGNORE
+<U0CE0> <kvw-vocalicrr>;<BAS>;<MIN>;IGNORE
+<U0C8C> <kvw-vocalicl>;<BAS>;<MIN>;IGNORE
+<U0CE1> <kvw-vocalicll>;<BAS>;<MIN>;IGNORE
+<U0C8E> <kvw-shorte>;<BAS>;<MIN>;IGNORE
+<U0C8F> <kvw-e>;<BAS>;<MIN>;IGNORE
+<U0C90> <kvw-ai>;<BAS>;<MIN>;IGNORE
+<U0C92> <kvw-shorto>;<BAS>;<MIN>;IGNORE
+<U0C93> <kvw-o>;<BAS>;<MIN>;IGNORE
+<U0C94> <kvw-au>;<BAS>;<MIN>;IGNORE
+<U0C95> <k-ka>;<BAS>;<MIN>;IGNORE
+<U0C96> <k-kha>;<BAS>;<MIN>;IGNORE
+<U0C97> <k-ga>;<BAS>;<MIN>;IGNORE
+<U0C98> <k-gha>;<BAS>;<MIN>;IGNORE
+<U0C99> <k-nga>;<BAS>;<MIN>;IGNORE
+<U0C9A> <k-ca>;<BAS>;<MIN>;IGNORE
+<U0C9B> <k-cha>;<BAS>;<MIN>;IGNORE
+<U0C9C> <k-ja>;<BAS>;<MIN>;IGNORE
+<U0C9D> <k-jha>;<BAS>;<MIN>;IGNORE
+<U0C9E> <k-nya>;<BAS>;<MIN>;IGNORE
+<U0C9F> <k-tta>;<BAS>;<MIN>;IGNORE
+<U0CA0> <k-ttha>;<BAS>;<MIN>;IGNORE
+<U0CA1> <k-dda>;<BAS>;<MIN>;IGNORE
+<U0CA2> <k-ddha>;<BAS>;<MIN>;IGNORE
+<U0CA3> <k-nna>;<BAS>;<MIN>;IGNORE
+<U0CA4> <k-ta>;<BAS>;<MIN>;IGNORE
+<U0CA5> <k-tha>;<BAS>;<MIN>;IGNORE
+<U0CA6> <k-da>;<BAS>;<MIN>;IGNORE
+<U0CA7> <k-dha>;<BAS>;<MIN>;IGNORE
+<U0CA8> <k-na>;<BAS>;<MIN>;IGNORE
+<U0CAA> <k-pa>;<BAS>;<MIN>;IGNORE
+<U0CAB> <k-pha>;<BAS>;<MIN>;IGNORE
+<U0CAC> <k-ba>;<BAS>;<MIN>;IGNORE
+<U0CAD> <k-bha>;<BAS>;<MIN>;IGNORE
+<U0CAE> <k-ma>;<BAS>;<MIN>;IGNORE
+<U0CAF> <k-ya>;<BAS>;<MIN>;IGNORE
+<U0CB0> <k-ra>;<BAS>;<MIN>;IGNORE
+<U0CB1> <k-rra>;<BAS>;<MIN>;IGNORE
+<U0CB2> <k-la>;<BAS>;<MIN>;IGNORE
+<U0CB5> <k-va>;<BAS>;<MIN>;IGNORE
+<U0CB6> <k-sha>;<BAS>;<MIN>;IGNORE
+<U0CB7> <k-ssa>;<BAS>;<MIN>;IGNORE
+<U0CB8> <k-sa>;<BAS>;<MIN>;IGNORE
+<U0CB9> <k-ha>;<BAS>;<MIN>;IGNORE
+<U0CB3> <k-lla>;<BAS>;<MIN>;IGNORE
+<U0CDE> <k-fa>;<BAS>;<MIN>;IGNORE
+<U0CBD> <k-avagrah>;<BAS>;<MIN>;IGNORE
+<U0CBE> <km-aa>;<BAS>;<MIN>;IGNORE
+<U0CBF> <km-i>;<BAS>;<MIN>;IGNORE
+<U0CC0> <km-ii>;<BAS>;<MIN>;IGNORE
+<kn-sign_ii> <km-ii>;<BAS>;<MIN>;IGNORE
+<U0CC1> <km-u>;<BAS>;<MIN>;IGNORE
+<U0CC2> <km-uu>;<BAS>;<MIN>;IGNORE
+<U0CC3> <km-vocalicr>;<BAS>;<MIN>;IGNORE
+<U0CC4> <km-vocalicrr>;<BAS>;<MIN>;IGNORE
+<U0CE2> <km-vocalicl>;<BAS>;<MIN>;IGNORE
+<U0CE3> <km-vocalicll>;<BAS>;<MIN>;IGNORE
+<U0CC6> <km-shorte>;<BAS>;<MIN>;IGNORE
+<U0CC7> <km-e>;<BAS>;<MIN>;IGNORE
+<kn-sign_e> <km-e>;<BAS>;<MIN>;IGNORE
+<U0CC8> <km-ai>;<BAS>;<MIN>;IGNORE
+<kn-sign_ai> <km-ai>;<BAS>;<MIN>;IGNORE
+<U0CCA> <km-shorto>;<BAS>;<MIN>;IGNORE
+<kn-sign_shorto> <km-shorto>;<BAS>;<MIN>;IGNORE
+<U0CCB> <km-o>;<BAS>;<MIN>;IGNORE
+<kn-sign_o> <km-o>;<BAS>;<MIN>;IGNORE
+<kn-sign1_o> <km-o>;<BAS>;<MIN>;IGNORE
+<U0CCC> <km-au>;<BAS>;<MIN>;IGNORE
+<U0C82> <kvd-anuswara>;<BAS>;<MIN>;IGNORE
+<U0C83> <kvd-visarg>;<BAS>;<MIN>;IGNORE
+<U0CCD> <k-halant>;<BAS>;<MIN>;IGNORE
+<U0CD5> <k-lenght_mark>;<BAS>;<MIN>;IGNORE
+<U0CD6> <k-ai_lenght_mark>;<BAS>;<MIN>;IGNORE
+<U0CBC> IGNORE;<KNKT>;<MIN>;IGNORE
+
order_end
END LC_COLLATE
diff --git a/libc/localedata/tst-langinfo.sh b/libc/localedata/tst-langinfo.sh
index 375352d33..b169adedb 100755
--- a/libc/localedata/tst-langinfo.sh
+++ b/libc/localedata/tst-langinfo.sh
@@ -1,6 +1,6 @@
#! /bin/sh
# Test nl_langinfo.
-# Copyright (C) 2000, 2001, 2003, 2007 Free Software Foundation, Inc.
+# Copyright (C) 2000, 2001, 2003, 2007, 2008 Free Software Foundation, Inc.
# This file is part of the GNU C Library.
#
@@ -245,13 +245,13 @@ de_DE.UTF-8 RADIXCHAR ,
de_DE.UTF-8 THOUSEP .
de_DE.UTF-8 YESEXPR ^[jJyY].*
de_DE.UTF-8 NOEXPR ^[nN].*
-fr_FR.ISO-8859-1 ABDAY_1 dim
-fr_FR.ISO-8859-1 ABDAY_2 lun
-fr_FR.ISO-8859-1 ABDAY_3 mar
-fr_FR.ISO-8859-1 ABDAY_4 mer
-fr_FR.ISO-8859-1 ABDAY_5 jeu
-fr_FR.ISO-8859-1 ABDAY_6 ven
-fr_FR.ISO-8859-1 ABDAY_7 sam
+fr_FR.ISO-8859-1 ABDAY_1 dim.
+fr_FR.ISO-8859-1 ABDAY_2 lun.
+fr_FR.ISO-8859-1 ABDAY_3 mar.
+fr_FR.ISO-8859-1 ABDAY_4 mer.
+fr_FR.ISO-8859-1 ABDAY_5 jeu.
+fr_FR.ISO-8859-1 ABDAY_6 ven.
+fr_FR.ISO-8859-1 ABDAY_7 sam.
fr_FR.ISO-8859-1 DAY_1 dimanche
fr_FR.ISO-8859-1 DAY_2 lundi
fr_FR.ISO-8859-1 DAY_3 mardi
@@ -259,18 +259,18 @@ fr_FR.ISO-8859-1 DAY_4 mercredi
fr_FR.ISO-8859-1 DAY_5 jeudi
fr_FR.ISO-8859-1 DAY_6 vendredi
fr_FR.ISO-8859-1 DAY_7 samedi
-fr_FR.ISO-8859-1 ABMON_1 jan
-fr_FR.ISO-8859-1 ABMON_2 fév
-fr_FR.ISO-8859-1 ABMON_3 mar
-fr_FR.ISO-8859-1 ABMON_4 avr
+fr_FR.ISO-8859-1 ABMON_1 janv.
+fr_FR.ISO-8859-1 ABMON_2 févr.
+fr_FR.ISO-8859-1 ABMON_3 mars
+fr_FR.ISO-8859-1 ABMON_4 avril
fr_FR.ISO-8859-1 ABMON_5 mai
-fr_FR.ISO-8859-1 ABMON_6 jun
-fr_FR.ISO-8859-1 ABMON_7 jui
-fr_FR.ISO-8859-1 ABMON_8 aoû
-fr_FR.ISO-8859-1 ABMON_9 sep
-fr_FR.ISO-8859-1 ABMON_10 oct
-fr_FR.ISO-8859-1 ABMON_11 nov
-fr_FR.ISO-8859-1 ABMON_12 déc
+fr_FR.ISO-8859-1 ABMON_6 juin
+fr_FR.ISO-8859-1 ABMON_7 juil.
+fr_FR.ISO-8859-1 ABMON_8 août
+fr_FR.ISO-8859-1 ABMON_9 sept.
+fr_FR.ISO-8859-1 ABMON_10 oct.
+fr_FR.ISO-8859-1 ABMON_11 nov.
+fr_FR.ISO-8859-1 ABMON_12 déc.
fr_FR.ISO-8859-1 MON_1 janvier
fr_FR.ISO-8859-1 MON_2 février
fr_FR.ISO-8859-1 MON_3 mars
@@ -284,7 +284,7 @@ fr_FR.ISO-8859-1 MON_10 octobre
fr_FR.ISO-8859-1 MON_11 novembre
fr_FR.ISO-8859-1 MON_12 décembre
fr_FR.ISO-8859-1 D_T_FMT "%a %d %b %Y %T %Z"
-fr_FR.ISO-8859-1 D_FMT "%d.%m.%Y"
+fr_FR.ISO-8859-1 D_FMT "%d/%m/%Y"
fr_FR.ISO-8859-1 T_FMT "%T"
fr_FR.ISO-8859-1 RADIXCHAR ,
fr_FR.ISO-8859-1 THOUSEP " "
diff --git a/libc/localedata/tst-strptime.c b/libc/localedata/tst-strptime.c
index b5ab232d7..bc2c7f1b6 100644
--- a/libc/localedata/tst-strptime.c
+++ b/libc/localedata/tst-strptime.c
@@ -1,22 +1,53 @@
#include <locale.h>
#include <time.h>
#include <stdio.h>
+#include <string.h>
static int
do_test (void)
{
+ int result = 0;
+
if (setlocale (LC_ALL, "vi_VN.TCVN5712-1") == NULL)
{
puts ("cannot set locale");
return 1;
}
struct tm tm;
+ memset (&tm, '\0', sizeof (tm));
/* This is November in Vietnamese encoded using TCVN5712-1. */
static const char s[] = "\
-\x54\x68\xb8\x6e\x67\x20\x6d\xad\xea\x69\x20\x6d\xe9\x74";
+\x54\x68\xb8\x6e\x67\x20\x6d\xad\xea\x69\x20\x6d\xe9\x74\0";
char *r = strptime (s, "%b", &tm);
printf ("r = %p, r-s = %tu, tm.tm_mon = %d\n", r, r - s, tm.tm_mon);
- return r == NULL || r - s != 14 || tm.tm_mon != 10;
+ result = r == NULL || r - s != 14 || tm.tm_mon != 10;
+
+ if (setlocale (LC_ALL, "ja_JP.UTF-8") == NULL)
+ {
+ puts ("cannot set locale");
+ return 1;
+ }
+ static const char s2[] = "\
+\x32\x35\x20\x30\x36\x20\xe5\xb9\xb3\xe6\x88\x90\x32\x30\0";
+ memset (&tm, '\0', sizeof (tm));
+ r = strptime (s2, "%d %m %EC%Ey", &tm);
+ printf ("\
+r = %p, r-s2 = %tu, tm.tm_mday = %d, tm.tm_mon = %d, tm.tm_year = %d\n",
+ r, r - s2, tm.tm_mday, tm.tm_mon, tm.tm_year);
+ result |= (r == NULL || r - s2 != 14 || tm.tm_mday != 25 || tm.tm_mon != 5
+ || tm.tm_year != 108);
+
+ static const char s3[] = "\
+\x32\x35\x20\x30\x36\x20\xe5\xb9\xb3\xe6\x88\x90\x32\x30\xe5\xb9\xb4\0";
+ memset (&tm, '\0', sizeof (tm));
+ r = strptime (s3, "%d %m %EY", &tm);
+ printf ("\
+r = %p, r-s3 = %tu, tm.tm_mday = %d, tm.tm_mon = %d, tm.tm_year = %d\n",
+ r, r - s3, tm.tm_mday, tm.tm_mon, tm.tm_year);
+ result |= (r == NULL || r - s3 != 17 || tm.tm_mday != 25 || tm.tm_mon != 5
+ || tm.tm_year != 108);
+
+ return result;
}
#define TEST_FUNCTION do_test ()
diff --git a/libc/login/utmp_file.c b/libc/login/utmp_file.c
index a1c6a2571..9033f72a4 100644
--- a/libc/login/utmp_file.c
+++ b/libc/login/utmp_file.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996-2002, 2003, 2004, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 1996-2004, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>
and Paul Janzen <pcj@primenet.com>, 1996.
@@ -22,6 +22,7 @@
#include <errno.h>
#include <fcntl.h>
#include <signal.h>
+#include <stdbool.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
@@ -167,10 +168,11 @@ setutent_file (void)
# ifdef O_CLOEXEC
if (__have_o_cloexec == 0)
__have_o_cloexec = (result & FD_CLOEXEC) ? 1 : -1;
-# endif
- result = fcntl_not_cancel (file_fd, F_SETFD,
- result | FD_CLOEXEC);
+ if (__have_o_cloexec < 0)
+# endif
+ result = fcntl_not_cancel (file_fd, F_SETFD,
+ result | FD_CLOEXEC);
}
if (result == -1)
@@ -243,12 +245,16 @@ getutent_r_file (struct utmp *buffer, struct utmp **result)
static int
-internal_getut_r (const struct utmp *id, struct utmp *buffer)
+internal_getut_r (const struct utmp *id, struct utmp *buffer,
+ bool *lock_failed)
{
int result = -1;
LOCK_FILE (file_fd, F_RDLCK)
- LOCKING_FAILED ();
+ {
+ *lock_failed = true;
+ LOCKING_FAILED ();
+ }
#if _HAVE_UT_TYPE - 0
if (id->ut_type == RUN_LVL || id->ut_type == BOOT_TIME
@@ -319,7 +325,10 @@ getutid_r_file (const struct utmp *id, struct utmp *buffer,
return -1;
}
- if (internal_getut_r (id, &last_entry) < 0)
+ /* We don't have to distinguish whether we can lock the file or
+ whether there is no entry. */
+ bool lock_failed = false;
+ if (internal_getut_r (id, &last_entry, &lock_failed) < 0)
{
*result = NULL;
return -1;
@@ -409,7 +418,16 @@ pututline_file (const struct utmp *data)
__utmp_equal (&last_entry, data)))
found = 1;
else
- found = internal_getut_r (data, &buffer);
+ {
+ bool lock_failed = false;
+ found = internal_getut_r (data, &buffer, &lock_failed);
+
+ if (__builtin_expect (lock_failed, false))
+ {
+ __set_errno (EAGAIN);
+ return NULL;
+ }
+ }
LOCK_FILE (file_fd, F_WRLCK)
{
diff --git a/libc/malloc/hooks.c b/libc/malloc/hooks.c
index 1e01b73af..c88937665 100644
--- a/libc/malloc/hooks.c
+++ b/libc/malloc/hooks.c
@@ -1,5 +1,5 @@
/* Malloc implementation for multiple threads without lock contention.
- Copyright (C) 2001-2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 2001-2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Wolfram Gloger <wg@malloc.de>, 2001.
@@ -96,8 +96,6 @@ __malloc_check_init()
__free_hook = free_check;
__realloc_hook = realloc_check;
__memalign_hook = memalign_check;
- if(check_action & 1)
- malloc_printerr (5, "malloc: using debugging hooks", NULL);
}
/* A simple, standard set of debugging hooks. Overhead is `only' one
diff --git a/libc/malloc/mtrace.c b/libc/malloc/mtrace.c
index 1a9522b09..fafa52e91 100644
--- a/libc/malloc/mtrace.c
+++ b/libc/malloc/mtrace.c
@@ -1,5 +1,5 @@
/* More debugging hooks for `malloc'.
- Copyright (C) 1991-1994,1996-2003, 2004 Free Software Foundation, Inc.
+ Copyright (C) 1991-1994,1996-2004, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Written April 2, 1991 by John Gilmore of Cygnus Support.
Based on mcheck.c by Mike Haertel.
@@ -34,13 +34,13 @@
#include <stdio-common/_itoa.h>
-#ifdef _LIBC
-# include <libc-internal.h>
+#include <libc-internal.h>
-# include <libio/iolibio.h>
-# define setvbuf(s, b, f, l) INTUSE(_IO_setvbuf) (s, b, f, l)
-# define fwrite(buf, size, count, fp) _IO_fwrite (buf, size, count, fp)
-#endif
+#include <libio/iolibio.h>
+#define setvbuf(s, b, f, l) INTUSE(_IO_setvbuf) (s, b, f, l)
+#define fwrite(buf, size, count, fp) _IO_fwrite (buf, size, count, fp)
+
+#include <kernel-features.h>
#ifndef attribute_hidden
# define attribute_hidden
@@ -315,9 +315,10 @@ mtrace ()
if (mtb == NULL)
return;
- mallstream = fopen (mallfile != NULL ? mallfile : "/dev/null", "wc");
+ mallstream = fopen (mallfile != NULL ? mallfile : "/dev/null", "wce");
if (mallstream != NULL)
{
+#ifndef __ASSUME_O_CLOEXEC
/* Make sure we close the file descriptor on exec. */
int flags = __fcntl (fileno (mallstream), F_GETFD, 0);
if (flags >= 0)
@@ -325,6 +326,7 @@ mtrace ()
flags |= FD_CLOEXEC;
__fcntl (fileno (mallstream), F_SETFD, flags);
}
+#endif
/* Be sure it doesn't malloc its buffer! */
malloc_trace_buffer = mtb;
setvbuf (mallstream, malloc_trace_buffer, _IOFBF, TRACE_BUFFER_SIZE);
diff --git a/libc/malloc/mtrace.pl b/libc/malloc/mtrace.pl
index 5e5e1ea0a..782861129 100644
--- a/libc/malloc/mtrace.pl
+++ b/libc/malloc/mtrace.pl
@@ -1,5 +1,5 @@
#! @PERL@
-eval "exec @PERL@ -S $0 $*"
+eval "exec @PERL@ -S $0 $@"
if 0;
# Copyright (C) 1997-2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
# This file is part of the GNU C Library.
diff --git a/libc/manual/arith.texi b/libc/manual/arith.texi
index 078885e86..b1580a06f 100644
--- a/libc/manual/arith.texi
+++ b/libc/manual/arith.texi
@@ -418,7 +418,7 @@ This function returns @code{-1} if @var{x} represents negative infinity,
This function returns a nonzero value if @var{x} is a ``not a number''
value, and zero otherwise.
-@strong{Note:} The @code{isnan} macro defined by @w{ISO C99} overrides
+@strong{NB:} The @code{isnan} macro defined by @w{ISO C99} overrides
the BSD function. This is normally not a problem, because the two
routines behave identically. However, if you really need to get the BSD
function for some reason, you can write
@@ -968,7 +968,7 @@ decide whether traps will occur for each of the exceptions, by setting
bits in the @dfn{control word}. In C, traps result in the program
receiving the @code{SIGFPE} signal; see @ref{Signal Handling}.
-@strong{Note:} @w{IEEE 754} says that trap handlers are given details of
+@strong{NB:} @w{IEEE 754} says that trap handlers are given details of
the exceptional situation, and can set the result value. C signals do
not provide any mechanism to pass this information back and forth.
Trapping exceptions in C is therefore not very useful.
@@ -1721,7 +1721,7 @@ Not all machines provide hardware support for these operations. On
machines that don't, the macros can be very slow. Therefore, you should
not use these functions when NaN is not a concern.
-@strong{Note:} There are no macros @code{isequal} or @code{isunequal}.
+@strong{NB:} There are no macros @code{isequal} or @code{isunequal}.
They are unnecessary, because the @code{==} and @code{!=} operators do
@emph{not} throw an exception if one or both of the operands are NaN.
diff --git a/libc/manual/creature.texi b/libc/manual/creature.texi
index c825edd5a..96501568a 100644
--- a/libc/manual/creature.texi
+++ b/libc/manual/creature.texi
@@ -217,7 +217,7 @@ sequence of definitions:
Note that if you do this, you must link your program with the BSD
compatibility library by passing the @samp{-lbsd-compat} option to the
-compiler or linker. @strong{Note:} If you forget to do this, you may
+compiler or linker. @strong{NB:} If you forget to do this, you may
get very strange errors at run time.
@end defvr
diff --git a/libc/manual/filesys.texi b/libc/manual/filesys.texi
index 9719d4194..a486f7de3 100644
--- a/libc/manual/filesys.texi
+++ b/libc/manual/filesys.texi
@@ -3239,7 +3239,7 @@ are replaced with six characters which make the whole string a unique
file name. Usually the template string is something like
@samp{/tmp/@var{prefix}XXXXXX}, and each program uses a unique @var{prefix}.
-@strong{Note:} Because @code{mktemp} and @code{mkstemp} modify the
+@strong{NB:} Because @code{mktemp} and @code{mkstemp} modify the
template string, you @emph{must not} pass string constants to them.
String constants are normally in read-only storage, so your program
would crash when @code{mktemp} or @code{mkstemp} tried to modify the
diff --git a/libc/manual/math.texi b/libc/manual/math.texi
index 7ebcddee3..50e087c48 100644
--- a/libc/manual/math.texi
+++ b/libc/manual/math.texi
@@ -1366,7 +1366,7 @@ The prototypes for these functions are in @file{stdlib.h}.
This function returns the next pseudo-random number in the sequence.
The value returned ranges from @code{0} to @code{RAND_MAX}.
-@strong{Note:} Temporarily this function was defined to return a
+@strong{NB:} Temporarily this function was defined to return a
@code{int32_t} value to indicate that the return value always contains
32 bits even if @code{long int} is wider. The standard demands it
differently. Users must always be aware of the 32-bit limitation,
diff --git a/libc/manual/memory.texi b/libc/manual/memory.texi
index cbe147b71..43afc7bf9 100644
--- a/libc/manual/memory.texi
+++ b/libc/manual/memory.texi
@@ -2326,7 +2326,7 @@ additional block on each iteration. This is impossible with
variable-sized arrays.
@end itemize
-@strong{Note:} If you mix use of @code{alloca} and variable-sized arrays
+@strong{NB:} If you mix use of @code{alloca} and variable-sized arrays
within one function, exiting a scope in which a variable-sized array was
declared frees all blocks allocated with @code{alloca} during the
execution of that scope.
diff --git a/libc/manual/resource.texi b/libc/manual/resource.texi
index aabd28976..4a814c9e4 100644
--- a/libc/manual/resource.texi
+++ b/libc/manual/resource.texi
@@ -591,7 +591,7 @@ ready to execute instructions right now. When a process blocks to wait
for something like I/O, its absolute priority is irrelevant.
@cindex runnable process
-@strong{Note:} The term ``runnable'' is a synonym for ``ready to run.''
+@strong{NB:} The term ``runnable'' is a synonym for ``ready to run.''
When two processes are running or ready to run and both have the same
absolute priority, it's more interesting. In that case, who gets the
@@ -663,7 +663,7 @@ privileged process constantly monitors the process' CPU usage and raises
its absolute priority when the process isn't getting its entitled share
and lowers it when the process is exceeding it.
-@strong{Note:} The absolute priority is sometimes called the ``static
+@strong{NB:} The absolute priority is sometimes called the ``static
priority.'' We don't use that term in this manual because it misses the
most important feature of the absolute priority: its absoluteness.
diff --git a/libc/manual/syslog.texi b/libc/manual/syslog.texi
index 02c8e28a7..e16b5d247 100644
--- a/libc/manual/syslog.texi
+++ b/libc/manual/syslog.texi
@@ -337,7 +337,7 @@ Locally defined
Results are undefined if the facility code is anything else.
-@strong{note:} @code{syslog} recognizes one other facility code: that of
+@strong{NB:} @code{syslog} recognizes one other facility code: that of
the kernel. But you can't specify that facility code with these
functions. If you try, it looks the same to @code{syslog} as if you are
requesting the default facility. But you wouldn't want to anyway,
diff --git a/libc/manual/time.texi b/libc/manual/time.texi
index 64763a2d2..393bccd99 100644
--- a/libc/manual/time.texi
+++ b/libc/manual/time.texi
@@ -1652,7 +1652,7 @@ The seconds as a decimal number (range @code{0} through @code{60}).
Leading zeroes are permitted but not required.
-@strong{Note:} The Unix specification says the upper bound on this value
+@strong{NB:} The Unix specification says the upper bound on this value
is @code{61}, a result of a decision to allow double leap seconds. You
will not see the value @code{61} because no minute has more than one
leap second, but the myth persists.
diff --git a/libc/math/libm-test.inc b/libc/math/libm-test.inc
index 7b383b414..6d9a3ec6c 100644
--- a/libc/math/libm-test.inc
+++ b/libc/math/libm-test.inc
@@ -2511,8 +2511,8 @@ exp_test (void)
TEST_f_f (exp, 0.75L, 2.11700001661267466854536981983709561L);
TEST_f_f (exp, 50.0L, 5184705528587072464087.45332293348538L);
TEST_f_f (exp, 88.72269439697265625L, 3.40233126623160774937554134772290447915e38L);
-#ifdef TEST_LDOUBLE
- /* The result can only be represented in long double. */
+#if defined TEST_LDOUBLE && __LDBL_MAX_EXP__ > 1024
+ /* The result can only be represented in sane long double. */
TEST_f_f (exp, 1000.0L, 0.197007111401704699388887935224332313e435L);
#endif
@@ -4301,6 +4301,17 @@ lround_test (void)
# endif
TEST_f_l (lround, 2097152.5, 2097153);
TEST_f_l (lround, -2097152.5, -2097153);
+ /* nextafter(0.5,-1) */
+ TEST_f_l (lround, 0x1.fffffffffffffp-2, 0);
+ /* nextafter(-0.5,1) */
+ TEST_f_l (lround, -0x1.fffffffffffffp-2, 0);
+#else
+ /* nextafter(0.5,-1) */
+ TEST_f_l (lround, 0x1.fffffp-2, 0);
+ /* nextafter(-0.5,1) */
+ TEST_f_l (lround, -0x1.fffffp-2, 0);
+ TEST_f_l (lround, 0x1.fffffep+23, 16777215);
+ TEST_f_l (lround, -0x1.fffffep+23, -16777215);
#endif
END (lround);
}
@@ -4360,8 +4371,40 @@ llround_test (void)
TEST_f_L (llround, 4294967295.5, 4294967296LL);
/* 0x200000000 */
TEST_f_L (llround, 8589934591.5, 8589934592LL);
+
+ /* nextafter(0.5,-1) */
+ TEST_f_L (llround, 0x1.fffffffffffffp-2, 0);
+ /* nextafter(-0.5,1) */
+ TEST_f_L (llround, -0x1.fffffffffffffp-2, 0);
+ /* On PowerPC an exponent of '52' is the largest incrementally
+ * representable sequence of whole-numbers in the 'double' range. We test
+ * lround to make sure that a guard bit set during the lround operation
+ * hasn't forced an erroneous shift giving us an incorrect result. The odd
+ * numbers between +-(2^52+1 and 2^53-1) are affected since they have the
+ * rightmost bit set. */
+ /* +-(2^52+1) */
+ TEST_f_L (llround, 0x1.0000000000001p+52,4503599627370497LL);
+ TEST_f_L (llround, -0x1.0000000000001p+52,-4503599627370497LL);
+ /* +-(2^53-1): Input is the last (positive and negative) incrementally
+ * representable whole-number in the 'double' range that might round
+ * erroneously. */
+ TEST_f_L (llround, 0x1.fffffffffffffp+52, 9007199254740991LL);
+ TEST_f_L (llround, -0x1.fffffffffffffp+52, -9007199254740991LL);
+#else
+ /* nextafter(0.5,-1) */
+ TEST_f_L (llround, 0x1.fffffep-2, 0);
+ /* nextafter(-0.5,1) */
+ TEST_f_L (llround, -0x1.fffffep-2, 0);
+ /* As above, on PowerPC an exponent of '23' is the largest incrementally
+ * representable sequence of whole-numbers in the 'float' range.
+ * Likewise, numbers between +-(2^23+1 and 2^24-1) are affected. */
+ TEST_f_L (llround, 0x1.000002p+23,8388609);
+ TEST_f_L (llround, -0x1.000002p+23,-8388609);
+ TEST_f_L (llround, 0x1.fffffep+23, 16777215);
+ TEST_f_L (llround, -0x1.fffffep+23, -16777215);
#endif
+
#ifdef TEST_LDOUBLE
/* The input can only be represented in long double. */
TEST_f_L (llround, 4503599627370495.5L, 4503599627370496LL);
diff --git a/libc/math/s_significandl.c b/libc/math/s_significandl.c
index 9fa0e4ff9..238b79ae5 100644
--- a/libc/math/s_significandl.c
+++ b/libc/math/s_significandl.c
@@ -34,6 +34,6 @@ static char rcsid[] = "$NetBSD: $";
long double x;
#endif
{
- return __ieee754_scalbl(x,(long double) -ilogbl(x));
+ return __ieee754_scalbl(x,(long double) -__ilogbl(x));
}
weak_alias (__significandl, significandl)
diff --git a/libc/misc/fstab.c b/libc/misc/fstab.c
index b434203a8..ab5581e9b 100644
--- a/libc/misc/fstab.c
+++ b/libc/misc/fstab.c
@@ -1,4 +1,5 @@
-/* Copyright (C) 1995, 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
+/* Copyright (C) 1995, 1996, 1997, 1998, 2000, 2008
+ 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
@@ -185,6 +186,5 @@ libc_freeres_fn (fstab_free)
char *buffer;
buffer = fstab_state.fs_buffer;
- if (buffer != NULL)
- free ((void *) buffer);
+ free ((void *) buffer);
}
diff --git a/libc/misc/regexp.h b/libc/misc/regexp.h
index b7b50b710..0e979d2d8 100644
--- a/libc/misc/regexp.h
+++ b/libc/misc/regexp.h
@@ -1,4 +1,5 @@
-/* Copyright (C) 1996, 1997, 1998, 1999, 2004 Free Software Foundation, Inc.
+/* Copyright (C) 1996, 1997, 1998, 1999, 2004, 2008
+ Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
@@ -129,8 +130,9 @@ compile (char *__restrict instring, char *__restrict expbuf,
__expr_ptr = (regex_t *) expbuf;
/* The remaining space in the buffer can be used for the compiled
pattern. */
- __expr_ptr->buffer = expbuf + sizeof (regex_t);
- __expr_ptr->allocated = endbuf - (char *) __expr_ptr->buffer;
+ __expr_ptr->__REPB_PREFIX (buffer) = expbuf + sizeof (regex_t);
+ __expr_ptr->__REPB_PREFIX (allocated)
+ = endbuf - (char *) __expr_ptr->__REPB_PREFIX (buffer);
while ((__ch = (GETC ())) != eof)
{
@@ -162,7 +164,10 @@ compile (char *__restrict instring, char *__restrict expbuf,
}
__input_buffer[__current_size++] = __ch;
}
- __input_buffer[__current_size++] = '\0';
+ if (__current_size)
+ __input_buffer[__current_size++] = '\0';
+ else
+ __input_buffer = "";
/* Now compile the pattern. */
__error = regcomp (__expr_ptr, __input_buffer, REG_NEWLINE);
@@ -198,7 +203,8 @@ compile (char *__restrict instring, char *__restrict expbuf,
}
/* Everything is ok. */
- RETURN ((char *) (__expr_ptr->buffer + __expr_ptr->used));
+ RETURN ((char *) (__expr_ptr->__REPB_PREFIX (buffer)
+ + __expr_ptr->__REPB_PREFIX (used)));
}
#endif
diff --git a/libc/misc/syslog.c b/libc/misc/syslog.c
index 5781b4a96..8f84faf75 100644
--- a/libc/misc/syslog.c
+++ b/libc/misc/syslog.c
@@ -348,10 +348,35 @@ openlog_internal(const char *ident, int logstat, int logfac)
(void)strncpy(SyslogAddr.sun_path, _PATH_LOG,
sizeof(SyslogAddr.sun_path));
if (LogStat & LOG_NDELAY) {
- if ((LogFile = __socket(AF_UNIX, LogType, 0))
- == -1)
+#ifdef SOCK_CLOEXEC
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec >= 0) {
+# endif
+ LogFile = __socket(AF_UNIX,
+ LogType
+ | SOCK_CLOEXEC, 0);
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec == 0)
+ __have_sock_cloexec
+ = (LogFile != -1
+ || errno != EINVAL);
+ }
+#endif
+#endif
+#ifndef __ASSUME_SOCK_CLOEXEC
+# ifdef SOCK_CLOEXEC
+ if (__have_sock_cloexec < 0)
+# endif
+ LogFile = __socket(AF_UNIX, LogType, 0);
+#endif
+ if (LogFile == -1)
return;
- (void)__fcntl(LogFile, F_SETFD, 1);
+#ifndef __ASSUME_SOCK_CLOEXEC
+# ifdef SOCK_CLOEXEC
+ if (__have_sock_cloexec < 0)
+# endif
+ __fcntl(LogFile, F_SETFD, FD_CLOEXEC);
+#endif
}
}
if (LogFile != -1 && !connected)
diff --git a/libc/misc/truncate64.c b/libc/misc/truncate64.c
index d7e80dc3a..4a8a54074 100644
--- a/libc/misc/truncate64.c
+++ b/libc/misc/truncate64.c
@@ -31,5 +31,5 @@ truncate64 (path, length)
__set_errno (EINVAL);
return -1;
}
- return truncate (path, (off_t) length);
+ return __truncate (path, (off_t) length);
}
diff --git a/libc/nis/Versions b/libc/nis/Versions
index be4453e28..ef9a51241 100644
--- a/libc/nis/Versions
+++ b/libc/nis/Versions
@@ -95,7 +95,7 @@ libnss_nis {
_nss_nis_setgrent; _nss_nis_sethostent; _nss_nis_setnetent;
_nss_nis_setnetgrent; _nss_nis_setprotoent; _nss_nis_setpwent;
_nss_nis_setrpcent; _nss_nis_setservent; _nss_nis_setspent;
- _nss_nis_initgroups_dyn;
+ _nss_nis_initgroups_dyn; _nss_nis_gethostbyname4_r;
}
}
@@ -126,5 +126,6 @@ libnss_nisplus {
_nss_nisplus_setnetent; _nss_nisplus_setnetgrent; _nss_nisplus_setprotoent;
_nss_nisplus_setpwent; _nss_nisplus_setrpcent; _nss_nisplus_setservent;
_nss_nisplus_setspent; _nss_nisplus_initgroups_dyn;
+ _nss_nisplus_gethostbyname4_r;
}
}
diff --git a/libc/nis/nss_nis/nis-hosts.c b/libc/nis/nss_nis/nis-hosts.c
index 7bf4af786..24d13634d 100644
--- a/libc/nis/nss_nis/nis-hosts.c
+++ b/libc/nis/nss_nis/nis-hosts.c
@@ -1,4 +1,5 @@
-/* Copyright (C) 1996-2000, 2002, 2003, 2006, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 1996-2000, 2002, 2003, 2006, 2007, 2008
+ Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Thorsten Kukuk <kukuk@suse.de>, 1996.
@@ -17,6 +18,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+#include <assert.h>
#include <nss.h>
#include <ctype.h>
/* The following is an ugly trick to avoid a prototype declaration for
@@ -61,9 +63,12 @@ LINE_PARSER
STRING_FIELD (addr, isspace, 1);
+ assert (af == AF_INET || af == AF_INET6 || af == AF_UNSPEC);
+
/* Parse address. */
- if (af == AF_INET && inet_pton (AF_INET, addr, entdata->host_addr) > 0)
+ if (af != AF_INET6 && inet_pton (AF_INET, addr, entdata->host_addr) > 0)
{
+ assert ((flags & AI_V4MAPPED) == 0 || af != AF_UNSPEC);
if (flags & AI_V4MAPPED)
{
map_v4v6_address ((char *) entdata->host_addr,
@@ -77,7 +82,7 @@ LINE_PARSER
result->h_length = INADDRSZ;
}
}
- else if (af == AF_INET6
+ else if (af != AF_INET
&& inet_pton (AF_INET6, addr, entdata->host_addr) > 0)
{
result->h_addrtype = AF_INET6;
@@ -102,6 +107,7 @@ static bool_t new_start = 1;
static char *oldkey = NULL;
static int oldkeylen = 0;
+
enum nss_status
_nss_nis_sethostent (int stayopen)
{
@@ -124,6 +130,7 @@ _nss_nis_sethostent (int stayopen)
is used so this makes no difference. */
strong_alias (_nss_nis_sethostent, _nss_nis_endhostent)
+
/* The calling function always need to get a lock first. */
static enum nss_status
internal_nis_gethostent_r (struct hostent *host, char *buffer,
@@ -216,6 +223,7 @@ internal_nis_gethostent_r (struct hostent *host, char *buffer,
return NSS_STATUS_SUCCESS;
}
+
enum nss_status
_nss_nis_gethostent_r (struct hostent *host, char *buffer, size_t buflen,
int *errnop, int *h_errnop)
@@ -233,6 +241,7 @@ _nss_nis_gethostent_r (struct hostent *host, char *buffer, size_t buflen,
return status;
}
+
static enum nss_status
internal_gethostbyname2_r (const char *name, int af, struct hostent *host,
char *buffer, size_t buflen, int *errnop,
@@ -323,16 +332,24 @@ internal_gethostbyname2_r (const char *name, int af, struct hostent *host,
return NSS_STATUS_SUCCESS;
}
+
enum nss_status
_nss_nis_gethostbyname2_r (const char *name, int af, struct hostent *host,
char *buffer, size_t buflen, int *errnop,
int *h_errnop)
{
+ if (af != AF_INET && af != AF_INET6)
+ {
+ *h_errnop = HOST_NOT_FOUND;
+ return NSS_STATUS_NOTFOUND;
+ }
+
return internal_gethostbyname2_r (name, af, host, buffer, buflen, errnop,
h_errnop,
((_res.options & RES_USE_INET6) ? AI_V4MAPPED : 0));
}
+
enum nss_status
_nss_nis_gethostbyname_r (const char *name, struct hostent *host, char *buffer,
size_t buflen, int *errnop, int *h_errnop)
@@ -351,6 +368,7 @@ _nss_nis_gethostbyname_r (const char *name, struct hostent *host, char *buffer,
errnop, h_errnop, 0);
}
+
enum nss_status
_nss_nis_gethostbyaddr_r (const void *addr, socklen_t addrlen, int af,
struct hostent *host, char *buffer, size_t buflen,
@@ -430,13 +448,93 @@ _nss_nis_gethostbyaddr_r (const void *addr, socklen_t addrlen, int af,
return NSS_STATUS_SUCCESS;
}
-#if 0
+
enum nss_status
-_nss_nis_getipnodebyname_r (const char *name, int af, int flags,
- struct hostent *result, char *buffer,
- size_t buflen, int *errnop, int *herrnop)
+_nss_nis_gethostbyname4_r (const char *name, struct gaih_addrtuple **pat,
+ char *buffer, size_t buflen, int *errnop,
+ int *herrnop, int32_t *ttlp)
{
- return internal_gethostbyname2_r (name, af, result, buffer, buflen,
- errnop, herrnop, flags);
+ char *domain;
+ if (yp_get_default_domain (&domain))
+ return NSS_STATUS_UNAVAIL;
+
+ /* Convert name to lowercase. */
+ size_t namlen = strlen (name);
+ char name2[namlen + 1];
+ size_t i;
+
+ for (i = 0; i < namlen; ++i)
+ name2[i] = tolower (name[i]);
+ name2[i] = '\0';
+
+ char *result;
+ int len;
+ int yperr = yp_match (domain, "hosts.byname", name2, namlen, &result, &len);
+
+ if (__builtin_expect (yperr != YPERR_SUCCESS, 0))
+ {
+ enum nss_status retval = yperr2nss (yperr);
+
+ if (retval == NSS_STATUS_TRYAGAIN)
+ {
+ *herrnop = TRY_AGAIN;
+ *errnop = errno;
+ }
+ if (retval == NSS_STATUS_NOTFOUND)
+ *herrnop = HOST_NOT_FOUND;
+ return retval;
+ }
+
+ struct parser_data data;
+ struct hostent host;
+ int parse_res = parse_line (result, &host, &data, buflen, errnop, AF_UNSPEC,
+ 0);
+ if (__builtin_expect (parse_res < 1, 0))
+ {
+ if (parse_res == -1)
+ {
+ *herrnop = NETDB_INTERNAL;
+ return NSS_STATUS_TRYAGAIN;
+ }
+ else
+ {
+ *herrnop = HOST_NOT_FOUND;
+ return NSS_STATUS_NOTFOUND;
+ }
+ }
+
+ if (*pat == NULL)
+ {
+ uintptr_t pad = (-(uintptr_t) buffer
+ % __alignof__ (struct gaih_addrtuple));
+ buffer += pad;
+ buflen = buflen > pad ? buflen - pad : 0;
+
+ if (__builtin_expect (buflen < sizeof (struct gaih_addrtuple), 0))
+ {
+ erange:
+ free (result);
+ *errnop = ERANGE;
+ *herrnop = NETDB_INTERNAL;
+ return NSS_STATUS_TRYAGAIN;
+ }
+
+ *pat = (struct gaih_addrtuple *) buffer;
+ buffer += sizeof (struct gaih_addrtuple);
+ buflen -= sizeof (struct gaih_addrtuple);
+ }
+
+ (*pat)->next = NULL;
+ size_t h_name_len = strlen (host.h_name);
+ if (h_name_len >= buflen)
+ goto erange;
+ (*pat)->name = memcpy (buffer, host.h_name, h_name_len + 1);
+ (*pat)->family = host.h_addrtype;
+ memcpy ((*pat)->addr, host.h_addr_list[0], host.h_length);
+ (*pat)->scopeid = 0;
+ assert (host.h_addr_list[1] == NULL);
+
+ free (result);
+
+ return NSS_STATUS_SUCCESS;
}
-#endif
diff --git a/libc/nis/nss_nisplus/nisplus-hosts.c b/libc/nis/nss_nisplus/nisplus-hosts.c
index f5f0ac96d..37d44773f 100644
--- a/libc/nis/nss_nisplus/nisplus-hosts.c
+++ b/libc/nis/nss_nisplus/nisplus-hosts.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997-2002, 2003, 2005, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1997-2003, 2005, 2006, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Thorsten Kukuk <kukuk@suse.de>, 1997.
@@ -17,6 +17,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+#include <assert.h>
#include <atomic.h>
#include <ctype.h>
#include <errno.h>
@@ -58,15 +59,15 @@ _nss_nisplus_parse_hostent (nis_result *result, int af, struct hostent *host,
if (result == NULL)
return 0;
- if ((result->status != NIS_SUCCESS && result->status != NIS_S_SUCCESS) ||
- __type_of (NIS_RES_OBJECT (result)) != NIS_ENTRY_OBJ ||
- strcmp(NIS_RES_OBJECT (result)[0].EN_data.en_type, "hosts_tbl") != 0 ||
- NIS_RES_OBJECT (result)[0].EN_data.en_cols.en_cols_len < 4)
+ if ((result->status != NIS_SUCCESS && result->status != NIS_S_SUCCESS)
+ || __type_of (NIS_RES_OBJECT (result)) != NIS_ENTRY_OBJ
+ || strcmp (NIS_RES_OBJECT (result)[0].EN_data.en_type, "hosts_tbl") != 0
+ || NIS_RES_OBJECT (result)[0].EN_data.en_cols.en_cols_len < 4)
return 0;
char *data = first_unused;
- if (room_left < (af == AF_INET6 || (flags & AI_V4MAPPED) != 0
+ if (room_left < (af != AF_INET || (flags & AI_V4MAPPED) != 0
? IN6ADDRSZ : INADDRSZ))
{
no_more_room:
@@ -75,8 +76,10 @@ _nss_nisplus_parse_hostent (nis_result *result, int af, struct hostent *host,
}
/* Parse address. */
- if (af == AF_INET && inet_pton (af, NISENTRYVAL (0, 2, result), data) > 0)
+ if (af != AF_INET6
+ && inet_pton (AF_INET, NISENTRYVAL (0, 2, result), data) > 0)
{
+ assert ((flags & AI_V4MAPPED) == 0 || af != AF_UNSPEC);
if (flags & AI_V4MAPPED)
{
map_v4v6_address (data, data);
@@ -89,7 +92,7 @@ _nss_nisplus_parse_hostent (nis_result *result, int af, struct hostent *host,
host->h_length = INADDRSZ;
}
}
- else if (af == AF_INET6
+ else if (af != AF_INET
&& inet_pton (AF_INET6, NISENTRYVAL (0, 2, result), data) > 0)
{
host->h_addrtype = AF_INET6;
@@ -109,27 +112,33 @@ _nss_nisplus_parse_hostent (nis_result *result, int af, struct hostent *host,
first_unused = __stpncpy (first_unused, NISENTRYVAL (0, 0, result),
NISENTRYLEN (0, 0, result));
*first_unused++ = '\0';
- room_left -= NISENTRYLEN (0, 0, result) + 1;
- /* XXX Rewrite at some point to allocate the array first and then
- copy the strings. It wasteful to first concatenate the strings
- to just split them again later. */
+ room_left -= NISENTRYLEN (0, 0, result) + 1;
char *line = first_unused;
- for (i = 0; i < NIS_RES_NUMOBJ (result); ++i)
+
+ /* When this is a call to gethostbyname4_r we do not need the aliases. */
+ if (af != AF_UNSPEC)
{
- if (strcmp (NISENTRYVAL (i, 1, result), host->h_name) != 0)
+ /* XXX Rewrite at some point to allocate the array first and then
+ copy the strings. It is wasteful to first concatenate the strings
+ to just split them again later. */
+ for (i = 0; i < NIS_RES_NUMOBJ (result); ++i)
{
- if (NISENTRYLEN (i, 1, result) + 2 > room_left)
- goto no_more_room;
-
- *first_unused++ = ' ';
- first_unused = __stpncpy (first_unused, NISENTRYVAL (i, 1, result),
- NISENTRYLEN (i, 1, result));
- *first_unused = '\0';
- room_left -= NISENTRYLEN (i, 1, result) + 1;
+ if (strcmp (NISENTRYVAL (i, 1, result), host->h_name) != 0)
+ {
+ if (NISENTRYLEN (i, 1, result) + 2 > room_left)
+ goto no_more_room;
+
+ *first_unused++ = ' ';
+ first_unused = __stpncpy (first_unused,
+ NISENTRYVAL (i, 1, result),
+ NISENTRYLEN (i, 1, result));
+ *first_unused = '\0';
+ room_left -= NISENTRYLEN (i, 1, result) + 1;
+ }
}
+ *first_unused++ = '\0';
}
- *first_unused++ = '\0';
/* Adjust the pointer so it is aligned for
storing pointers. */
@@ -147,30 +156,34 @@ _nss_nisplus_parse_hostent (nis_result *result, int af, struct hostent *host,
host->h_addr_list[1] = NULL;
host->h_aliases = &host->h_addr_list[2];
- i = 0;
- while (*line != '\0')
+ /* When this is a call to gethostbyname4_r we do not need the aliases. */
+ if (af != AF_UNSPEC)
{
- /* Skip leading blanks. */
- while (isspace (*line))
- ++line;
+ i = 0;
+ while (*line != '\0')
+ {
+ /* Skip leading blanks. */
+ while (isspace (*line))
+ ++line;
- if (*line == '\0')
- break;
+ if (*line == '\0')
+ break;
- if (room_left < sizeof (char *))
- goto no_more_room;
+ if (room_left < sizeof (char *))
+ goto no_more_room;
- room_left -= sizeof (char *);
- host->h_aliases[i++] = line;
+ room_left -= sizeof (char *);
+ host->h_aliases[i++] = line;
- while (*line != '\0' && *line != ' ')
- ++line;
+ while (*line != '\0' && *line != ' ')
+ ++line;
- if (*line == ' ')
- *line++ = '\0';
- }
+ if (*line == ' ')
+ *line++ = '\0';
+ }
- host->h_aliases[i] = NULL;
+ host->h_aliases[i] = NULL;
+ }
return 1;
}
@@ -204,6 +217,7 @@ _nss_create_tablename (int *errnop)
return NSS_STATUS_SUCCESS;
}
+
enum nss_status
_nss_nisplus_sethostent (int stayopen)
{
@@ -226,6 +240,7 @@ _nss_nisplus_sethostent (int stayopen)
return status;
}
+
enum nss_status
_nss_nisplus_endhostent (void)
{
@@ -242,6 +257,7 @@ _nss_nisplus_endhostent (void)
return NSS_STATUS_SUCCESS;
}
+
static enum nss_status
internal_nisplus_gethostent_r (struct hostent *host, char *buffer,
size_t buflen, int *errnop, int *herrnop)
@@ -329,6 +345,7 @@ internal_nisplus_gethostent_r (struct hostent *host, char *buffer,
return NSS_STATUS_SUCCESS;
}
+
enum nss_status
_nss_nisplus_gethostent_r (struct hostent *result, char *buffer,
size_t buflen, int *errnop, int *herrnop)
@@ -345,26 +362,33 @@ _nss_nisplus_gethostent_r (struct hostent *result, char *buffer,
return status;
}
+
+static enum nss_status
+get_tablename (int *herrnop)
+{
+ __libc_lock_lock (lock);
+
+ enum nss_status status = _nss_create_tablename (herrnop);
+
+ __libc_lock_unlock (lock);
+
+ if (status != NSS_STATUS_SUCCESS)
+ *herrnop = NETDB_INTERNAL;
+
+ return status;
+}
+
+
static enum nss_status
internal_gethostbyname2_r (const char *name, int af, struct hostent *host,
char *buffer, size_t buflen, int *errnop,
int *herrnop, int flags)
{
- int parse_res, retval;
-
if (tablename_val == NULL)
{
- __libc_lock_lock (lock);
-
- enum nss_status status = _nss_create_tablename (errnop);
-
- __libc_lock_unlock (lock);
-
+ enum nss_status status = get_tablename (herrnop);
if (status != NSS_STATUS_SUCCESS)
- {
- *herrnop = NETDB_INTERNAL;
- return NSS_STATUS_UNAVAIL;
- }
+ return status;
}
if (name == NULL)
@@ -374,39 +398,36 @@ internal_gethostbyname2_r (const char *name, int af, struct hostent *host,
return NSS_STATUS_NOTFOUND;
}
- nis_result *result;
char buf[strlen (name) + 10 + tablename_len];
int olderr = errno;
/* Search at first in the alias list, and use the correct name
for the next search. */
snprintf (buf, sizeof (buf), "[name=%s],%s", name, tablename_val);
- result = nis_list (buf, FOLLOW_PATH | FOLLOW_LINKS, NULL, NULL);
+ nis_result *result = nis_list (buf, FOLLOW_PATH | FOLLOW_LINKS, NULL, NULL);
if (result != NULL)
{
- char *bufptr = buf;
-
/* If we did not find it, try it as original name. But if the
database is correct, we should find it in the first case, too. */
- if ((result->status != NIS_SUCCESS
- && result->status != NIS_S_SUCCESS)
- || __type_of (result->objects.objects_val) != NIS_ENTRY_OBJ
- || strcmp (result->objects.objects_val->EN_data.en_type,
- "hosts_tbl") != 0
- || result->objects.objects_val->EN_data.en_cols.en_cols_len < 3)
- snprintf (buf, sizeof (buf), "[cname=%s],%s", name, tablename_val);
- else
+ char *bufptr = buf;
+ size_t buflen = sizeof (buf);
+
+ if ((result->status == NIS_SUCCESS || result->status == NIS_S_SUCCESS)
+ && __type_of (result->objects.objects_val) == NIS_ENTRY_OBJ
+ && strcmp (result->objects.objects_val->EN_data.en_type,
+ "hosts_tbl") == 0
+ && result->objects.objects_val->EN_data.en_cols.en_cols_len >= 3)
{
/* We need to allocate a new buffer since there is no
- guarantee the returned name has a length limit. */
- const char *entryval = NISENTRYVAL(0, 0, result);
- size_t buflen = strlen (entryval) + 10 + tablename_len;
+ guarantee the returned alias name has a length limit. */
+ name = NISENTRYVAL(0, 0, result);
+ size_t buflen = strlen (name) + 10 + tablename_len;
bufptr = alloca (buflen);
- snprintf (bufptr, buflen, "[cname=%s],%s",
- entryval, tablename_val);
}
+ snprintf (bufptr, buflen, "[cname=%s],%s", name, tablename_val);
+
nis_freeresult (result);
result = nis_list (bufptr, FOLLOW_PATH | FOLLOW_LINKS, NULL, NULL);
}
@@ -417,7 +438,7 @@ internal_gethostbyname2_r (const char *name, int af, struct hostent *host,
return NSS_STATUS_TRYAGAIN;
}
- retval = niserr2nss (result->status);
+ int retval = niserr2nss (result->status);
if (__builtin_expect (retval != NSS_STATUS_SUCCESS, 0))
{
if (retval == NSS_STATUS_TRYAGAIN)
@@ -431,8 +452,8 @@ internal_gethostbyname2_r (const char *name, int af, struct hostent *host,
return retval;
}
- parse_res = _nss_nisplus_parse_hostent (result, af, host, buffer,
- buflen, errnop, flags);
+ int parse_res = _nss_nisplus_parse_hostent (result, af, host, buffer,
+ buflen, errnop, flags);
nis_freeresult (result);
@@ -450,16 +471,24 @@ internal_gethostbyname2_r (const char *name, int af, struct hostent *host,
return NSS_STATUS_NOTFOUND;
}
+
enum nss_status
_nss_nisplus_gethostbyname2_r (const char *name, int af, struct hostent *host,
char *buffer, size_t buflen, int *errnop,
int *herrnop)
{
+ if (af != AF_INET && af != AF_INET6)
+ {
+ *herrnop = HOST_NOT_FOUND;
+ return NSS_STATUS_NOTFOUND;
+ }
+
return internal_gethostbyname2_r (name, af, host, buffer, buflen, errnop,
herrnop,
((_res.options & RES_USE_INET6) ? AI_V4MAPPED : 0));
}
+
enum nss_status
_nss_nisplus_gethostbyname_r (const char *name, struct hostent *host,
char *buffer, size_t buflen, int *errnop,
@@ -480,6 +509,7 @@ _nss_nisplus_gethostbyname_r (const char *name, struct hostent *host,
buflen, errnop, h_errnop, 0);
}
+
enum nss_status
_nss_nisplus_gethostbyaddr_r (const void *addr, socklen_t addrlen, int af,
struct hostent *host, char *buffer,
@@ -487,12 +517,7 @@ _nss_nisplus_gethostbyaddr_r (const void *addr, socklen_t addrlen, int af,
{
if (tablename_val == NULL)
{
- __libc_lock_lock (lock);
-
- enum nss_status status = _nss_create_tablename (errnop);
-
- __libc_lock_unlock (lock);
-
+ enum nss_status status = get_tablename (herrnop);
if (status != NSS_STATUS_SUCCESS)
return status;
}
@@ -547,3 +572,44 @@ _nss_nisplus_gethostbyaddr_r (const void *addr, socklen_t addrlen, int af,
__set_errno (olderr);
return NSS_STATUS_NOTFOUND;
}
+
+
+enum nss_status
+_nss_nisplus_gethostbyname4_r (const char *name, struct gaih_addrtuple **pat,
+ char *buffer, size_t buflen, int *errnop,
+ int *herrnop, int32_t *ttlp)
+{
+ struct hostent host;
+
+ enum nss_status status = internal_gethostbyname2_r (name, AF_UNSPEC, &host,
+ buffer, buflen,
+ errnop, herrnop, 0);
+ if (__builtin_expect (status == NSS_STATUS_SUCCESS, 1))
+ {
+ if (*pat == NULL)
+ {
+ uintptr_t pad = (-(uintptr_t) buffer
+ % __alignof__ (struct gaih_addrtuple));
+ buffer += pad;
+ buflen = buflen > pad ? buflen - pad : 0;
+
+ if (__builtin_expect (buflen < sizeof (struct gaih_addrtuple), 0))
+ {
+ free (result);
+ *errnop = ERANGE;
+ *herrnop = NETDB_INTERNAL;
+ return NSS_STATUS_TRYAGAIN;
+ }
+ }
+
+ (*pat)->next = NULL;
+ (*pat)->name = host.h_name;
+ (*pat)->family = host.h_addrtype;
+
+ memcpy ((*pat)->addr, host.h_addr_list[0], host.h_length);
+ (*pat)->scopeid = 0;
+ assert (host.h_addr_list[1] == NULL);
+ }
+
+ return status;
+}
diff --git a/libc/nis/ypclnt.c b/libc/nis/ypclnt.c
index 7d0091bd2..aaf4eb6e5 100644
--- a/libc/nis/ypclnt.c
+++ b/libc/nis/ypclnt.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996-2001, 2002, 2003, 2004, 2005, 2006
+/* Copyright (C) 1996-2001, 2002, 2003, 2004, 2005, 2006, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Thorsten Kukuk <kukuk@suse.de>, 1996.
@@ -28,6 +28,7 @@
#include <rpcsvc/yp.h>
#include <rpcsvc/ypclnt.h>
#include <rpcsvc/ypupd.h>
+#include <sys/socket.h>
#include <sys/uio.h>
#include <bits/libc-lock.h>
@@ -69,14 +70,24 @@ yp_bind_client_create (const char *domain, dom_binding *ysd,
ysd->dom_domain[YPMAXDOMAIN] = '\0';
ysd->dom_socket = RPC_ANYSOCK;
- ysd->dom_client = clntudp_create (&ysd->dom_server_addr, YPPROG, YPVERS,
- UDPTIMEOUT, &ysd->dom_socket);
+#ifdef SOCK_CLOEXEC
+# define xflags SOCK_CLOEXEC
+#else
+# define xflags 0
+#endif
+ ysd->dom_client = __libc_clntudp_bufcreate (&ysd->dom_server_addr, YPPROG,
+ YPVERS, UDPTIMEOUT,
+ &ysd->dom_socket,
+ UDPMSGSIZE, UDPMSGSIZE,
+ xflags);
if (ysd->dom_client != NULL)
{
+#ifndef SOCK_CLOEXEC
/* If the program exits, close the socket */
if (fcntl (ysd->dom_socket, F_SETFD, FD_CLOEXEC) == -1)
perror ("fcntl: F_SETFD");
+#endif
}
}
diff --git a/libc/nptl/ChangeLog b/libc/nptl/ChangeLog
index e771107f5..d638dde58 100644
--- a/libc/nptl/ChangeLog
+++ b/libc/nptl/ChangeLog
@@ -1,6 +1,112 @@
+2008-08-15 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/x86_64/pthreaddef.h: Remove ARCH_MAP_FLAGS and
+ ARCH_RETRY_MMAP definitions.
+ * allocatestack.c: Remove definition of ARCH_MAP_FLAGS.
+ Define MAP_STACK when not defined.
+ (allocate_stack): Use MAP_STACK instead of ARCH_MAP_FLAGS. Remove
+ handling of ARCH_RETRY_MMAP.
+
+2008-07-30 Ulrich Drepper <drepper@redhat.com>
+
+ * tst-align2.c (f): Print message that f is reached.
+
+2008-04-28 Hiroki Kaminaga <kaminaga@sm.sony.co.jp>
+
+ [BZ #6740]
+ * sysdeps/powerpc/tcb-offsets.sym (PRIVATE_FUTEX_OFFSET): Guard symbol
+ definition with #ifndef __ASSUME_PRIVATE_FUTEX.
+
+2008-07-25 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/unix/sysv/linux/mq_notify.c (init_mq_netlink): Use
+ SOCK_CLOEXEC if possible.
+
+2008-05-29 Ulrich Drepper <drepper@redhat.com>
+
+ * Makefile (tests): Add tst-rwlock2a.
+ * tst-rwlock2.c: Use TYPE macro to decide what rwlock type to use.
+ * tst-rwlock2a.c: New file.
+
+2008-06-12 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/pthread/pthread.h: Remove inadvertant checkin.
+
+2008-05-17 Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+ * sysdeps/pthread/pthread.h: Fix typo in comment.
+
+2008-05-28 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/pthread/createthread.c (do_clone): Pass accurate length
+ of CPU set to the kernel.
+
+2008-05-23 Paul Pluzhnikov <ppluzhnikov@google.com>
+
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Add
+ cfi directives.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
+ * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
+
+2008-05-22 Paul Pluzhnikov <ppluzhnikov@google.com>
+
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S: Add
+ cfi directives.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
+ Likewise.
+ * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
+ Likewise.
+ * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
+ Likewise.
+
+2008-05-26 Ulrich Drepper <drepper@redhat.com>
+
+ * tst-typesizes.c: Explicitly check __SIZEOF_PTHREAD_* constants.
+
+2008-05-20 Jakub Jelinek <jakub@redhat.com>
+
+ David S. Miller <davem@davemloft.net>
+
+ * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: New file.
+
+2008-05-10 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Access
+ __pshared correctly.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
+ Likewise.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
+ Likewise.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S:
+ Likewise.
+ * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S:
+ Likewise.
+ Reported by Clemens Kolbitsch <clemens.kol@gmx.at>.
+
+2008-04-14 David S. Miller <davem@davemloft.net>
+
+ * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c
+ (__old_sem_wait): Fix argument to lll_futex_wait().
+
+2007-11-26 Daniel Jacobowitz <dan@codesourcery.com>
+
+ * pthread_create.c: Require pthread_mutex_trylock and
+ pthread_key_delete for libgcc.
+
+2008-04-08 Jakub Jelinek <jakub@redhat.com>
+
+ [BZ #6020]
+ * sysdeps/unix/sysv/linux/sparc/lowlevellock.h
+ (lll_futex_wake_unlock): Add private argument to the pre-v9 macro.
+ Patch by Sunil Amitkumar Janki <devel.sjanki@gmail.com>.
+
2008-03-27 Ulrich Drepper <drepper@redhat.com>
- * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefined ARG_MAX if
+ * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine ARG_MAX if
<linux/limits.h> has defined it.
* sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
* sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
diff --git a/libc/nptl/Makefile b/libc/nptl/Makefile
index 59f9554fb..6f72e08a8 100644
--- a/libc/nptl/Makefile
+++ b/libc/nptl/Makefile
@@ -214,9 +214,9 @@ tests = tst-typesizes \
tst-robust6 tst-robust7 tst-robust8 tst-robust9 \
tst-robustpi1 tst-robustpi2 tst-robustpi3 tst-robustpi4 tst-robustpi5 \
tst-robustpi6 tst-robustpi7 tst-robustpi8 tst-robustpi9 \
- tst-rwlock1 tst-rwlock2 tst-rwlock3 tst-rwlock4 tst-rwlock5 \
- tst-rwlock6 tst-rwlock7 tst-rwlock8 tst-rwlock9 tst-rwlock10 \
- tst-rwlock11 tst-rwlock12 tst-rwlock13 tst-rwlock14 \
+ tst-rwlock1 tst-rwlock2 tst-rwlock2a tst-rwlock3 tst-rwlock4 \
+ tst-rwlock5 tst-rwlock6 tst-rwlock7 tst-rwlock8 tst-rwlock9 \
+ tst-rwlock10 tst-rwlock11 tst-rwlock12 tst-rwlock13 tst-rwlock14 \
tst-once1 tst-once2 tst-once3 tst-once4 \
tst-key1 tst-key2 tst-key3 tst-key4 \
tst-sem1 tst-sem2 tst-sem3 tst-sem4 tst-sem5 tst-sem6 tst-sem7 \
diff --git a/libc/nptl/allocatestack.c b/libc/nptl/allocatestack.c
index b01f28d10..a8235e667 100644
--- a/libc/nptl/allocatestack.c
+++ b/libc/nptl/allocatestack.c
@@ -84,10 +84,10 @@
#endif
-/* Let the architecture add some flags to the mmap() call used to
- allocate stacks. */
-#ifndef ARCH_MAP_FLAGS
-# define ARCH_MAP_FLAGS 0
+/* Newer kernels have the MAP_STACK flag to indicate a mapping is used for
+ a stack. Use it when possible. */
+#ifndef MAP_STACK
+# define MAP_STACK 0
#endif
/* This yields the pointer that TLS support code calls the thread pointer. */
@@ -454,20 +454,14 @@ allocate_stack (const struct pthread_attr *attr, struct pthread **pdp,
#endif
mem = mmap (NULL, size, prot,
- MAP_PRIVATE | MAP_ANONYMOUS | ARCH_MAP_FLAGS, -1, 0);
+ MAP_PRIVATE | MAP_ANONYMOUS | MAP_STACK, -1, 0);
if (__builtin_expect (mem == MAP_FAILED, 0))
{
-#ifdef ARCH_RETRY_MMAP
- mem = ARCH_RETRY_MMAP (size, prot);
- if (__builtin_expect (mem == MAP_FAILED, 0))
-#endif
- {
- if (errno == ENOMEM)
- errno = EAGAIN;
+ if (errno == ENOMEM)
+ __set_errno (EAGAIN);
- return errno;
- }
+ return errno;
}
/* SIZE is guaranteed to be greater than zero.
diff --git a/libc/nptl/pthread_create.c b/libc/nptl/pthread_create.c
index f678a6f03..e93efe7fc 100644
--- a/libc/nptl/pthread_create.c
+++ b/libc/nptl/pthread_create.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002,2003,2004,2005,2006,2007 Free Software Foundation, Inc.
+/* Copyright (C) 2002-2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
@@ -603,11 +603,13 @@ compat_symbol (libpthread, __pthread_create_2_0, pthread_create,
/* If pthread_create is present, libgcc_eh.a and libsupc++.a expects some other POSIX thread
functions to be present as well. */
PTHREAD_STATIC_FN_REQUIRE (pthread_mutex_lock)
+PTHREAD_STATIC_FN_REQUIRE (pthread_mutex_trylock)
PTHREAD_STATIC_FN_REQUIRE (pthread_mutex_unlock)
PTHREAD_STATIC_FN_REQUIRE (pthread_once)
PTHREAD_STATIC_FN_REQUIRE (pthread_cancel)
PTHREAD_STATIC_FN_REQUIRE (pthread_key_create)
+PTHREAD_STATIC_FN_REQUIRE (pthread_key_delete)
PTHREAD_STATIC_FN_REQUIRE (pthread_setspecific)
PTHREAD_STATIC_FN_REQUIRE (pthread_getspecific)
diff --git a/libc/nptl/sysdeps/powerpc/tcb-offsets.sym b/libc/nptl/sysdeps/powerpc/tcb-offsets.sym
index eda43dce8..8ac133dfd 100644
--- a/libc/nptl/sysdeps/powerpc/tcb-offsets.sym
+++ b/libc/nptl/sysdeps/powerpc/tcb-offsets.sym
@@ -15,4 +15,6 @@ MULTIPLE_THREADS_OFFSET thread_offsetof (header.multiple_threads)
PID thread_offsetof (pid)
TID thread_offsetof (tid)
POINTER_GUARD (offsetof (tcbhead_t, pointer_guard) - TLS_TCB_OFFSET - sizeof (tcbhead_t))
+#ifndef __ASSUME_PRIVATE_FUTEX
PRIVATE_FUTEX_OFFSET thread_offsetof (header.private_futex)
+#endif
diff --git a/libc/nptl/sysdeps/pthread/createthread.c b/libc/nptl/sysdeps/pthread/createthread.c
index 59e62c2dc..66fafe805 100644
--- a/libc/nptl/sysdeps/pthread/createthread.c
+++ b/libc/nptl/sysdeps/pthread/createthread.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2003, 2004, 2006, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2002-2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
@@ -98,7 +98,7 @@ do_clone (struct pthread *pd, const struct pthread_attr *attr,
if (attr->cpuset != NULL)
{
res = INTERNAL_SYSCALL (sched_setaffinity, err, 3, pd->tid,
- sizeof (cpu_set_t), attr->cpuset);
+ attr->cpusetsize, attr->cpuset);
if (__builtin_expect (INTERNAL_SYSCALL_ERROR_P (res, err), 0))
{
diff --git a/libc/nptl/sysdeps/pthread/pthread.h b/libc/nptl/sysdeps/pthread/pthread.h
index f3ab0ae71..d5ffd383f 100644
--- a/libc/nptl/sysdeps/pthread/pthread.h
+++ b/libc/nptl/sysdeps/pthread/pthread.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007
+/* Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -127,7 +127,7 @@ enum
# if __WORDSIZE == 64
# define PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP \
{ { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, \
- PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP } }
+ PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP } }
# else
# if __BYTE_ORDER == __LITTLE_ENDIAN
# define PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP \
@@ -399,7 +399,7 @@ extern int pthread_attr_getaffinity_np (__const pthread_attr_t *__attr,
/* Initialize thread attribute *ATTR with attributes corresponding to the
- already running thread TH. It shall be called on unitialized ATTR
+ already running thread TH. It shall be called on uninitialized ATTR
and destroyed with pthread_attr_destroy when no longer needed. */
extern int pthread_getattr_np (pthread_t __th, pthread_attr_t *__attr)
__THROW __nonnull ((2));
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S
index 77d252de8..040d7f8c3 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S
@@ -27,7 +27,10 @@
.type pthread_barrier_wait,@function
.align 16
pthread_barrier_wait:
+ cfi_startproc
pushl %ebx
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%ebx, -8)
movl 8(%esp), %ebx
@@ -45,6 +48,8 @@ pthread_barrier_wait:
/* There are more threads to come. */
pushl %esi
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%esi, -12)
#if CURR_EVENT == 0
movl (%ebx), %edx
@@ -101,9 +106,16 @@ pthread_barrier_wait:
10: movl %esi, %eax /* != PTHREAD_BARRIER_SERIAL_THREAD */
popl %esi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%esi)
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
ret
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%ebx, -8)
+
/* The necessary number of threads arrived. */
3:
#if CURR_EVENT == 0
@@ -140,8 +152,12 @@ pthread_barrier_wait:
5: orl $-1, %eax /* == PTHREAD_BARRIER_SERIAL_THREAD */
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
ret
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%ebx, -8)
1: movl PRIVATE(%ebx), %ecx
leal MUTEX(%ebx), %edx
xorl $LLL_SHARED, %ecx
@@ -154,6 +170,8 @@ pthread_barrier_wait:
call __lll_unlock_wake
jmp 5b
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%esi, -12)
6: movl PRIVATE(%ebx), %ecx
leal MUTEX(%ebx), %eax
xorl $LLL_SHARED, %ecx
@@ -165,4 +183,5 @@ pthread_barrier_wait:
xorl $LLL_SHARED, %ecx
call __lll_unlock_wake
jmp 10b
+ cfi_endproc
.size pthread_barrier_wait,.-pthread_barrier_wait
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
index 776c47f6c..f46b4b874 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
@@ -32,11 +32,19 @@
.type __pthread_cond_broadcast, @function
.align 16
__pthread_cond_broadcast:
-
+ cfi_startproc
pushl %ebx
+ cfi_adjust_cfa_offset(4)
pushl %esi
+ cfi_adjust_cfa_offset(4)
pushl %edi
+ cfi_adjust_cfa_offset(4)
pushl %ebp
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%ebx, -8)
+ cfi_offset(%esi, -12)
+ cfi_offset(%edi, -16)
+ cfi_offset(%ebp, -20)
movl 20(%esp), %ebx
@@ -114,11 +122,24 @@ __pthread_cond_broadcast:
10: xorl %eax, %eax
popl %ebp
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebp)
popl %edi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%edi)
popl %esi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%esi)
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
ret
+ cfi_adjust_cfa_offset(16)
+ cfi_offset(%ebx, -8)
+ cfi_offset(%esi, -12)
+ cfi_offset(%edi, -16)
+ cfi_offset(%ebp, -20)
.align 16
/* Unlock. */
4: LOCK
@@ -127,11 +148,24 @@ __pthread_cond_broadcast:
6: xorl %eax, %eax
popl %ebp
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebp)
popl %edi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%edi)
popl %esi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%esi)
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
ret
+ cfi_adjust_cfa_offset(16)
+ cfi_offset(%ebx, -8)
+ cfi_offset(%esi, -12)
+ cfi_offset(%edi, -16)
+ cfi_offset(%ebp, -20)
/* Initial locking failed. */
1:
#if cond_lock == 0
@@ -199,6 +233,7 @@ __pthread_cond_broadcast:
movl $SYS_futex, %eax
ENTER_KERNEL
jmp 10b
+ cfi_endproc
.size __pthread_cond_broadcast, .-__pthread_cond_broadcast
versioned_symbol (libpthread, __pthread_cond_broadcast, pthread_cond_broadcast,
GLIBC_2_3_2)
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
index 36a18036c..4909f4910 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
@@ -33,8 +33,13 @@
.align 16
__pthread_cond_signal:
+ cfi_startproc
pushl %ebx
+ cfi_adjust_cfa_offset(4)
pushl %edi
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%ebx, -8)
+ cfi_offset(%edi, -12)
movl 12(%esp), %edi
@@ -69,7 +74,12 @@ __pthread_cond_signal:
/* Wake up one thread. */
pushl %esi
+ cfi_adjust_cfa_offset(4)
pushl %ebp
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%esi, -16)
+ cfi_offset(%ebp, -20)
+
#if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
@@ -91,7 +101,11 @@ __pthread_cond_signal:
ENTER_KERNEL */
int $0x80
popl %ebp
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebp)
popl %esi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%esi)
/* For any kind of error, we try again with WAKE.
The general test also covers running on old kernels. */
@@ -100,9 +114,17 @@ __pthread_cond_signal:
6: xorl %eax, %eax
popl %edi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%edi)
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
ret
+ cfi_adjust_cfa_offset(8)
+ cfi_offset(%ebx, -8)
+ cfi_offset(%edi, -12)
+
7: /* %ecx should be either FUTEX_WAKE_OP or
FUTEX_WAKE_OP|FUTEX_PRIVATE_FLAG from the previous syscall. */
xorl $(FUTEX_WAKE ^ FUTEX_WAKE_OP), %ecx
@@ -152,6 +174,7 @@ __pthread_cond_signal:
call __lll_lock_wait
jmp 2b
+ cfi_endproc
.size __pthread_cond_signal, .-__pthread_cond_signal
versioned_symbol (libpthread, __pthread_cond_signal, pthread_cond_signal,
GLIBC_2_3_2)
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S
index d8f1bd54a..4e5f0c5b2 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S
@@ -30,8 +30,13 @@
.type __pthread_rwlock_rdlock,@function
.align 16
__pthread_rwlock_rdlock:
+ cfi_startproc
pushl %esi
+ cfi_adjust_cfa_offset(4)
pushl %ebx
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%esi, -8)
+ cfi_offset(%ebx, -12)
xorl %esi, %esi
movl 12(%esp), %ebx
@@ -113,16 +118,23 @@ __pthread_rwlock_rdlock:
movl %edx, %eax
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
popl %esi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%esi)
ret
+ cfi_adjust_cfa_offset(8)
+ cfi_offset(%esi, -8)
+ cfi_offset(%ebx, -12)
1:
#if MUTEX == 0
movl %ebx, %edx
#else
leal MUTEX(%ebx), %edx
#endif
- movl PSHARED(%ebx), %ecx
+ movzbl PSHARED(%ebx), %ecx
call __lll_lock_wait
jmp 2b
@@ -138,7 +150,7 @@ __pthread_rwlock_rdlock:
#else
leal MUTEX(%ebx), %eax
#endif
- movl PSHARED(%ebx), %ecx
+ movzbl PSHARED(%ebx), %ecx
call __lll_unlock_wake
jmp 7b
@@ -158,7 +170,7 @@ __pthread_rwlock_rdlock:
#else
leal MUTEX(%ebx), %eax
#endif
- movl PSHARED(%ebx), %ecx
+ movzbl PSHARED(%ebx), %ecx
call __lll_unlock_wake
jmp 11b
@@ -168,9 +180,10 @@ __pthread_rwlock_rdlock:
#else
leal MUTEX(%ebx), %edx
#endif
- movl PSHARED(%ebx), %ecx
+ movzbl PSHARED(%ebx), %ecx
call __lll_lock_wait
jmp 13b
+ cfi_endproc
.size __pthread_rwlock_rdlock,.-__pthread_rwlock_rdlock
.globl pthread_rwlock_rdlock
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S
index 0d96e0325..2b84cd06c 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S
@@ -30,11 +30,21 @@
.type pthread_rwlock_timedrdlock,@function
.align 16
pthread_rwlock_timedrdlock:
+ cfi_startproc
pushl %esi
+ cfi_adjust_cfa_offset(4)
pushl %edi
+ cfi_adjust_cfa_offset(4)
pushl %ebx
+ cfi_adjust_cfa_offset(4)
pushl %ebp
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%esi, -8)
+ cfi_offset(%edi, -12)
+ cfi_offset(%ebx, -16)
+ cfi_offset(%ebp, -20)
subl $8, %esp
+ cfi_adjust_cfa_offset(8)
movl 28(%esp), %ebp
movl 32(%esp), %edi
@@ -150,19 +160,33 @@ pthread_rwlock_timedrdlock:
7: movl %edx, %eax
addl $8, %esp
+ cfi_adjust_cfa_offset(-8)
popl %ebp
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebp)
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
popl %edi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%edi)
popl %esi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%esi)
ret
+ cfi_adjust_cfa_offset(24)
+ cfi_offset(%esi, -8)
+ cfi_offset(%edi, -12)
+ cfi_offset(%ebx, -16)
+ cfi_offset(%ebp, -20)
1:
#if MUTEX == 0
movl %ebp, %edx
#else
leal MUTEX(%ebp), %edx
#endif
- movl PSHARED(%ebp), %ecx
+ movzbl PSHARED(%ebp), %ecx
call __lll_lock_wait
jmp 2b
@@ -177,7 +201,7 @@ pthread_rwlock_timedrdlock:
#else
leal MUTEX(%ebp), %eax
#endif
- movl PSHARED(%ebp), %ecx
+ movzbl PSHARED(%ebp), %ecx
call __lll_unlock_wake
jmp 7b
@@ -197,7 +221,7 @@ pthread_rwlock_timedrdlock:
#else
leal MUTEX(%ebp), %eax
#endif
- movl PSHARED(%ebp), %ecx
+ movzbl PSHARED(%ebp), %ecx
call __lll_unlock_wake
jmp 11b
@@ -207,7 +231,7 @@ pthread_rwlock_timedrdlock:
#else
leal MUTEX(%ebp), %edx
#endif
- movl PSHARED(%ebp), %ecx
+ movzbl PSHARED(%ebp), %ecx
call __lll_lock_wait
jmp 13b
@@ -216,4 +240,5 @@ pthread_rwlock_timedrdlock:
19: movl $EINVAL, %edx
jmp 9b
+ cfi_endproc
.size pthread_rwlock_timedrdlock,.-pthread_rwlock_timedrdlock
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S
index e78fdf6dd..91652467c 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S
@@ -30,11 +30,21 @@
.type pthread_rwlock_timedwrlock,@function
.align 16
pthread_rwlock_timedwrlock:
+ cfi_startproc
pushl %esi
+ cfi_adjust_cfa_offset(4)
pushl %edi
+ cfi_adjust_cfa_offset(4)
pushl %ebx
+ cfi_adjust_cfa_offset(4)
pushl %ebp
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%esi, -8)
+ cfi_offset(%edi, -12)
+ cfi_offset(%ebx, -16)
+ cfi_offset(%ebp, -20)
subl $8, %esp
+ cfi_adjust_cfa_offset(8)
movl 28(%esp), %ebp
movl 32(%esp), %edi
@@ -148,19 +158,33 @@ pthread_rwlock_timedwrlock:
7: movl %edx, %eax
addl $8, %esp
+ cfi_adjust_cfa_offset(-8)
popl %ebp
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebp)
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
popl %edi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%edi)
popl %esi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%esi)
ret
+ cfi_adjust_cfa_offset(24)
+ cfi_offset(%esi, -8)
+ cfi_offset(%edi, -12)
+ cfi_offset(%ebx, -16)
+ cfi_offset(%ebp, -20)
1:
#if MUTEX == 0
movl %ebp, %edx
#else
leal MUTEX(%ebp), %edx
#endif
- movl PSHARED(%ebp), %ecx
+ movzbl PSHARED(%ebp), %ecx
call __lll_lock_wait
jmp 2b
@@ -175,7 +199,7 @@ pthread_rwlock_timedwrlock:
#else
leal MUTEX(%ebp), %eax
#endif
- movl PSHARED(%ebp), %ecx
+ movzbl PSHARED(%ebp), %ecx
call __lll_unlock_wake
jmp 7b
@@ -190,7 +214,7 @@ pthread_rwlock_timedwrlock:
#else
leal MUTEX(%ebp), %eax
#endif
- movl PSHARED(%ebp), %ecx
+ movzbl PSHARED(%ebp), %ecx
call __lll_unlock_wake
jmp 11b
@@ -200,7 +224,7 @@ pthread_rwlock_timedwrlock:
#else
leal MUTEX(%ebp), %edx
#endif
- movl PSHARED(%ebp), %ecx
+ movzbl PSHARED(%ebp), %ecx
call __lll_lock_wait
jmp 13b
@@ -209,4 +233,5 @@ pthread_rwlock_timedwrlock:
19: movl $EINVAL, %edx
jmp 9b
+ cfi_endproc
.size pthread_rwlock_timedwrlock,.-pthread_rwlock_timedwrlock
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S
index a23e1b50a..aabb92960 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S
@@ -29,8 +29,13 @@
.type __pthread_rwlock_unlock,@function
.align 16
__pthread_rwlock_unlock:
+ cfi_startproc
pushl %ebx
+ cfi_adjust_cfa_offset(4)
pushl %edi
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%ebx, -8)
+ cfi_offset(%edi, -12)
movl 12(%esp), %edi
@@ -87,9 +92,16 @@ __pthread_rwlock_unlock:
xorl %eax, %eax
popl %edi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%edi)
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
ret
+ cfi_adjust_cfa_offset(8)
+ cfi_offset(%ebx, -8)
+ cfi_offset(%edi, -12)
.align 16
6: LOCK
#if MUTEX == 0
@@ -110,7 +122,7 @@ __pthread_rwlock_unlock:
#else
leal MUTEX(%edi), %edx
#endif
- movl PSHARED(%edi), %ecx
+ movzbl PSHARED(%edi), %ecx
call __lll_lock_wait
jmp 2b
@@ -120,7 +132,7 @@ __pthread_rwlock_unlock:
#else
leal MUTEX(%edi), %eax
#endif
- movl PSHARED(%edi), %ecx
+ movzbl PSHARED(%edi), %ecx
call __lll_unlock_wake
jmp 4b
@@ -130,10 +142,10 @@ __pthread_rwlock_unlock:
#else
leal MUTEX(%edi), %eax
#endif
- movl PSHARED(%edi), %ecx
+ movzbl PSHARED(%edi), %ecx
call __lll_unlock_wake
jmp 8b
-
+ cfi_endproc
.size __pthread_rwlock_unlock,.-__pthread_rwlock_unlock
.globl pthread_rwlock_unlock
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S
index 65b99fe7d..100736499 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S
@@ -30,8 +30,13 @@
.type __pthread_rwlock_wrlock,@function
.align 16
__pthread_rwlock_wrlock:
+ cfi_startproc
pushl %esi
+ cfi_adjust_cfa_offset(4)
pushl %ebx
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%esi, -8)
+ cfi_offset(%ebx, -12)
xorl %esi, %esi
movl 12(%esp), %ebx
@@ -111,16 +116,23 @@ __pthread_rwlock_wrlock:
movl %edx, %eax
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
popl %esi
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%esi)
ret
+ cfi_adjust_cfa_offset(8)
+ cfi_offset(%esi, -8)
+ cfi_offset(%ebx, -12)
1:
#if MUTEX == 0
movl %ebx, %edx
#else
leal MUTEX(%ebx), %edx
#endif
- movl PSHARED(%ebx), %ecx
+ movzbl PSHARED(%ebx), %ecx
call __lll_lock_wait
jmp 2b
@@ -135,7 +147,7 @@ __pthread_rwlock_wrlock:
#else
leal MUTEX(%ebx), %eax
#endif
- movl PSHARED(%ebx), %ecx
+ movzbl PSHARED(%ebx), %ecx
call __lll_unlock_wake
jmp 7b
@@ -149,7 +161,7 @@ __pthread_rwlock_wrlock:
#else
leal MUTEX(%ebx), %eax
#endif
- movl PSHARED(%ebx), %ecx
+ movzbl PSHARED(%ebx), %ecx
call __lll_unlock_wake
jmp 11b
@@ -159,9 +171,10 @@ __pthread_rwlock_wrlock:
#else
leal MUTEX(%ebx), %edx
#endif
- movl PSHARED(%ebx), %ecx
+ movzbl PSHARED(%ebx), %ecx
call __lll_lock_wait
jmp 13b
+ cfi_endproc
.size __pthread_rwlock_wrlock,.-__pthread_rwlock_wrlock
.globl pthread_rwlock_wrlock
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/sem_post.S b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/sem_post.S
index 2edcdde4f..86992c877 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/sem_post.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/i386/i486/sem_post.S
@@ -30,7 +30,10 @@
.type __new_sem_post,@function
.align 16
__new_sem_post:
+ cfi_startproc
pushl %ebx
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%ebx, -8)
movl 8(%esp), %ebx
@@ -64,8 +67,12 @@ __new_sem_post:
2: xorl %eax, %eax
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
ret
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%ebx, -8)
1:
#ifdef PIC
call __i686.get_pc_thunk.bx
@@ -116,14 +123,20 @@ __new_sem_post:
orl $-1, %eax
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
ret
+ cfi_endproc
.size __new_sem_post,.-__new_sem_post
versioned_symbol(libpthread, __new_sem_post, sem_post, GLIBC_2_1)
#if SHLIB_COMPAT(libpthread, GLIBC_2_0, GLIBC_2_1)
.global __old_sem_post
.type __old_sem_post,@function
__old_sem_post:
+ cfi_startproc
pushl %ebx
+ cfi_adjust_cfa_offset(4)
+ cfi_offset(%ebx, -8)
movl 8(%esp), %ebx
LOCK
@@ -139,7 +152,10 @@ __old_sem_post:
xorl %eax, %eax
popl %ebx
+ cfi_adjust_cfa_offset(-4)
+ cfi_restore(%ebx)
ret
+ cfi_endproc
.size __old_sem_post,.-__old_sem_post
compat_symbol(libpthread, __old_sem_post, sem_post, GLIBC_2_0)
#endif
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/mq_notify.c b/libc/nptl/sysdeps/unix/sysv/linux/mq_notify.c
index 2ec11bf68..49ddeae05 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/mq_notify.c
+++ b/libc/nptl/sysdeps/unix/sysv/linux/mq_notify.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2004, 2005 Free Software Foundation, Inc.
+/* Copyright (C) 2004, 2005, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contribute by Ulrich Drepper <drepper@redhat.com>, 2004.
@@ -29,6 +29,7 @@
#include <unistd.h>
#include <sys/socket.h>
#include <not-cancel.h>
+#include <kernel-features.h>
#ifdef __NR_mq_notify
@@ -152,18 +153,40 @@ reset_once (void)
static void
init_mq_netlink (void)
{
+#ifdef SOCK_CLOEXEC
+# ifndef __ASSUME_SOCK_CLOEXEC
+ static int have_sock_cloexec;
+# else
+# define have_sock_cloexec 1
+# endif
+#else
+# define have_sock_cloexec -1
+# define SOCK_CLOEXEC 0
+#endif
+
/* This code might be called a second time after fork(). The file
descriptor is inherited from the parent. */
if (netlink_socket == -1)
{
/* Just a normal netlink socket, not bound. */
- netlink_socket = socket (AF_NETLINK, SOCK_RAW, 0);
+ if (have_sock_cloexec >= 0)
+ {
+ netlink_socket = socket (AF_NETLINK, SOCK_RAW | SOCK_CLOEXEC, 0);
+#if defined SOCK_CLOEXEC && !defined __ASSUME_SOCK_CLOEXEC
+ if (have_sock_cloexec == 0)
+ have_sock_cloexec = (netlink_socket != -1 || errno != EINVAL
+ ? 1 : -1);
+#endif
+ }
+ if (have_sock_cloexec < 0)
+ netlink_socket = socket (AF_NETLINK, SOCK_RAW, 0);
/* No need to do more if we have no socket. */
if (netlink_socket == -1)
return;
/* Make sure the descriptor is closed on exec. */
- if (fcntl (netlink_socket, F_SETFD, FD_CLOEXEC) != 0)
+ if (have_sock_cloexec < 0
+ && fcntl (netlink_socket, F_SETFD, FD_CLOEXEC) != 0)
goto errout;
}
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/sparc/lowlevellock.h b/libc/nptl/sysdeps/unix/sysv/linux/sparc/lowlevellock.h
index f4512b262..754a0f51f 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/sparc/lowlevellock.h
+++ b/libc/nptl/sysdeps/unix/sysv/linux/sparc/lowlevellock.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2003, 2004, 2006, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2003, 2004, 2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Jakub Jelinek <jakub@redhat.com>, 2003.
@@ -120,7 +120,7 @@
/* Returns non-zero if error happened, zero if success. */
#ifdef __sparc32_atomic_do_lock
/* Avoid FUTEX_WAKE_OP if supporting pre-v9 CPUs. */
-# define lll_futex_wake_unlock(futexp, nr_wake, nr_wake2, futexp2) 1
+# define lll_futex_wake_unlock(futexp, nr_wake, nr_wake2, futexp2, private) 1
#else
# define lll_futex_wake_unlock(futexp, nr_wake, nr_wake2, futexp2, private) \
({ \
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c b/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c
index 3c71c969b..b14f976a6 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c
+++ b/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c
@@ -155,7 +155,7 @@ __old_sem_wait (sem_t *sem)
/* Enable asynchronous cancellation. Required by the standard. */
int oldtype = __pthread_enable_asynccancel ();
- err = lll_futex_wait (futex, 0,
+ err = lll_futex_wait (&isem->value, 0,
isem->private ^ FUTEX_PRIVATE_FLAG);
/* Disable asynchronous cancellation. */
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc64/Makefile b/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc64/Makefile
new file mode 100644
index 000000000..774b267ef
--- /dev/null
+++ b/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc64/Makefile
@@ -0,0 +1,4 @@
+ifeq ($(subdir),nptl)
+CFLAGS-pause.c += -fexceptions
+CFLAGS-sigsuspend.c += -fexceptions
+endif
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S b/libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
index 0fa271442..366c96fc3 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
@@ -33,10 +33,19 @@
.type pthread_rwlock_timedrdlock,@function
.align 16
pthread_rwlock_timedrdlock:
+ cfi_startproc
pushq %r12
+ cfi_adjust_cfa_offset(8)
pushq %r13
+ cfi_adjust_cfa_offset(8)
pushq %r14
+ cfi_adjust_cfa_offset(8)
+ cfi_offset(%r12, -16)
+ cfi_offset(%r13, -24)
+ cfi_offset(%r14, -32)
+
subq $16, %rsp
+ cfi_adjust_cfa_offset(16)
movq %rdi, %r12
movq %rsi, %r13
@@ -155,11 +164,22 @@ pthread_rwlock_timedrdlock:
7: movq %rdx, %rax
addq $16, %rsp
+ cfi_adjust_cfa_offset(-16)
popq %r14
+ cfi_adjust_cfa_offset(-8)
+ cfi_restore(%r14)
popq %r13
+ cfi_adjust_cfa_offset(-8)
+ cfi_restore(%r13)
popq %r12
+ cfi_adjust_cfa_offset(-8)
+ cfi_restore(%r12)
retq
+ cfi_adjust_cfa_offset(40)
+ cfi_offset(%r12, -16)
+ cfi_offset(%r13, -24)
+ cfi_offset(%r14, -32)
1: movl PSHARED(%rdi), %esi
#if MUTEX != 0
addq $MUTEX, %rdi
@@ -214,4 +234,5 @@ pthread_rwlock_timedrdlock:
19: movl $EINVAL, %edx
jmp 9b
+ cfi_endproc
.size pthread_rwlock_timedrdlock,.-pthread_rwlock_timedrdlock
diff --git a/libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S b/libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
index 1e43933ca..dde6b5883 100644
--- a/libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
+++ b/libc/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
@@ -33,10 +33,19 @@
.type pthread_rwlock_timedwrlock,@function
.align 16
pthread_rwlock_timedwrlock:
+ cfi_startproc
pushq %r12
+ cfi_adjust_cfa_offset(8)
pushq %r13
+ cfi_adjust_cfa_offset(8)
pushq %r14
+ cfi_adjust_cfa_offset(8)
+ cfi_offset(%r12, -16)
+ cfi_offset(%r13, -24)
+ cfi_offset(%r14, -32)
+
subq $16, %rsp
+ cfi_adjust_cfa_offset(16)
movq %rdi, %r12
movq %rsi, %r13
@@ -152,11 +161,22 @@ pthread_rwlock_timedwrlock:
7: movq %rdx, %rax
addq $16, %rsp
+ cfi_adjust_cfa_offset(-16)
popq %r14
+ cfi_adjust_cfa_offset(-8)
+ cfi_restore(%r14)
popq %r13
+ cfi_adjust_cfa_offset(-8)
+ cfi_restore(%r13)
popq %r12
+ cfi_adjust_cfa_offset(-8)
+ cfi_restore(%r12)
retq
+ cfi_adjust_cfa_offset(40)
+ cfi_offset(%r12, -16)
+ cfi_offset(%r13, -24)
+ cfi_offset(%r14, -32)
1: movl PSHARED(%rdi), %esi
#if MUTEX != 0
addq $MUTEX, %rdi
@@ -206,4 +226,5 @@ pthread_rwlock_timedwrlock:
19: movl $EINVAL, %edx
jmp 9b
+ cfi_endproc
.size pthread_rwlock_timedwrlock,.-pthread_rwlock_timedwrlock
diff --git a/libc/nptl/sysdeps/x86_64/pthreaddef.h b/libc/nptl/sysdeps/x86_64/pthreaddef.h
index 0195bc928..be63a8c74 100644
--- a/libc/nptl/sysdeps/x86_64/pthreaddef.h
+++ b/libc/nptl/sysdeps/x86_64/pthreaddef.h
@@ -36,16 +36,6 @@
({ char *frame; asm ("movq %%rsp, %0" : "=r" (frame)); frame; })
-/* We prefer to have the stack allocated in the low 4GB since this
- allows faster context switches. */
-#define ARCH_MAP_FLAGS MAP_32BIT
-
-/* If it is not possible to allocate memory there retry without that
- flag. */
-#define ARCH_RETRY_MMAP(size, prot) \
- mmap (NULL, size, prot, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0)
-
-
/* XXX Until we have a better place keep the definitions here. */
/* While there is no such syscall. */
diff --git a/libc/nptl/tst-align2.c b/libc/nptl/tst-align2.c
index 9c300ecd1..9112bdc8f 100644
--- a/libc/nptl/tst-align2.c
+++ b/libc/nptl/tst-align2.c
@@ -31,6 +31,8 @@ f (void *arg)
{
bool ok = true;
+ puts ("in f");
+
if (TEST_STACK_ALIGN ())
ok = false;
diff --git a/libc/nptl/tst-rwlock2.c b/libc/nptl/tst-rwlock2.c
index 6f38682b8..2d2e8e4a3 100644
--- a/libc/nptl/tst-rwlock2.c
+++ b/libc/nptl/tst-rwlock2.c
@@ -26,15 +26,41 @@ static int
do_test (void)
{
pthread_rwlock_t r;
+ pthread_rwlockattr_t at;
int e;
- if (pthread_rwlock_init (&r, NULL) != 0)
+ if (pthread_rwlockattr_init (&at) != 0)
+ {
+ puts ("rwlockattr_init failed");
+ return 1;
+ }
+ puts ("rwlockattr_init succeeded");
+
+#ifndef TYPE
+# define TYPE PTHREAD_RWLOCK_PREFER_READER_NP
+#endif
+
+ if (pthread_rwlockattr_setkind_np (&at, TYPE) != 0)
+ {
+ puts ("rwlockattr_setkind failed");
+ return 1;
+ }
+ puts ("rwlockattr_setkind succeeded");
+
+ if (pthread_rwlock_init (&r, &at) != 0)
{
puts ("rwlock_init failed");
return 1;
}
puts ("rwlock_init succeeded");
+ if (pthread_rwlockattr_destroy (&at) != 0)
+ {
+ puts ("rwlockattr_destroy failed");
+ return 1;
+ }
+ puts ("rwlockattr_destroy succeeded");
+
if (pthread_rwlock_wrlock (&r) != 0)
{
puts ("1st rwlock_wrlock failed");
diff --git a/libc/nptl/tst-rwlock2a.c b/libc/nptl/tst-rwlock2a.c
new file mode 100644
index 000000000..615de5c01
--- /dev/null
+++ b/libc/nptl/tst-rwlock2a.c
@@ -0,0 +1,2 @@
+#define TYPE PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP
+#include "tst-rwlock2.c"
diff --git a/libc/nptl/tst-typesizes.c b/libc/nptl/tst-typesizes.c
index 17a1e297d..545cee6bd 100644
--- a/libc/nptl/tst-typesizes.c
+++ b/libc/nptl/tst-typesizes.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2005, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2005, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2005.
@@ -21,6 +21,25 @@
#include <pthreadP.h>
#include <semaphore.h>
+static const struct
+{
+ const char *name;
+ size_t expected;
+ size_t is;
+} types[] =
+ {
+#define T(t, c) \
+ { #t, c, sizeof (t) }
+ T (pthread_attr_t, __SIZEOF_PTHREAD_ATTR_T),
+ T (pthread_mutex_t, __SIZEOF_PTHREAD_MUTEX_T),
+ T (pthread_mutexattr_t, __SIZEOF_PTHREAD_MUTEXATTR_T),
+ T (pthread_cond_t, __SIZEOF_PTHREAD_COND_T),
+ T (pthread_condattr_t, __SIZEOF_PTHREAD_CONDATTR_T),
+ T (pthread_rwlock_t, __SIZEOF_PTHREAD_RWLOCK_T),
+ T (pthread_rwlockattr_t, __SIZEOF_PTHREAD_RWLOCKATTR_T),
+ T (pthread_barrier_t, __SIZEOF_PTHREAD_BARRIER_T),
+ T (pthread_barrierattr_t, __SIZEOF_PTHREAD_BARRIERATTR_T)
+ };
static int
do_test (void)
@@ -62,6 +81,14 @@ do_test (void)
TEST_TYPE2 (sem_t, struct new_sem);
TEST_TYPE2 (sem_t, struct old_sem);
+ for (size_t i = 0; i < sizeof (types) / sizeof (types[0]); ++i)
+ if (types[i].expected != types[i].is)
+ {
+ printf ("%s: expected %zu, is %zu\n",
+ types[i].name, types[i].expected, types[i].is);
+ result = 1;
+ }
+
return result;
}
diff --git a/libc/nscd/Makefile b/libc/nscd/Makefile
index efcb68315..8d9d70686 100644
--- a/libc/nscd/Makefile
+++ b/libc/nscd/Makefile
@@ -1,4 +1,4 @@
-# Copyright (C) 1998,2000,2002,2003,2004,2005,2006,2007
+# Copyright (C) 1998,2000,2002,2003,2004,2005,2006,2007,2008
# Free Software Foundation, Inc.
# This file is part of the GNU C Library.
@@ -98,7 +98,7 @@ CFLAGS-nscd_initgroups.c = -fexceptions
nscd-cflags = -DIS_IN_nscd=1 -D_FORTIFY_SOURCE=2
ifeq (yesyes,$(have-fpie)$(build-shared))
-nscd-cflags += -fpie
+nscd-cflags += $(pie-ccflag)
endif
ifeq (yes,$(have-ssp))
nscd-cflags += -fstack-protector
diff --git a/libc/nscd/aicache.c b/libc/nscd/aicache.c
index a69a7781d..5ffab76a0 100644
--- a/libc/nscd/aicache.c
+++ b/libc/nscd/aicache.c
@@ -1,5 +1,5 @@
/* Cache handling for host lookup.
- Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2004.
@@ -21,6 +21,7 @@
#include <errno.h>
#include <libintl.h>
#include <netdb.h>
+#include <nss.h>
#include <string.h>
#include <time.h>
#include <unistd.h>
@@ -33,6 +34,10 @@
#endif
+typedef enum nss_status (*nss_gethostbyname4_r)
+ (const char *name, struct gaih_addrtuple **pat,
+ char *buffer, size_t buflen, int *errnop,
+ int *h_errnop, int32_t *ttlp);
typedef enum nss_status (*nss_gethostbyname3_r)
(const char *name, int af, struct hostent *host,
char *buffer, size_t buflen, int *errnop,
@@ -109,7 +114,6 @@ addhstaiX (struct database_dyn *db, int fd, request_header *req,
char *tmpbuf6 = alloca (tmpbuf6len);
size_t tmpbuf4len = 0;
char *tmpbuf4 = NULL;
- char *canon = NULL;
int32_t ttl = INT32_MAX;
ssize_t total = 0;
char *key_copy = NULL;
@@ -117,16 +121,104 @@ addhstaiX (struct database_dyn *db, int fd, request_header *req,
while (!no_more)
{
+ void *cp;
int status[2] = { NSS_STATUS_UNAVAIL, NSS_STATUS_UNAVAIL };
+ int naddrs = 0;
+ size_t addrslen = 0;
+ char *canon = NULL;
+ size_t canonlen;
+
+ nss_gethostbyname4_r fct4 = __nss_lookup_function (nip,
+ "gethostbyname4_r");
+ if (fct4 != NULL)
+ {
+ struct gaih_addrtuple *at = NULL;
+ while (1)
+ {
+ rc6 = 0;
+ herrno = 0;
+ status[1] = DL_CALL_FCT (fct4, (key, &at, tmpbuf6, tmpbuf6len,
+ &rc6, &herrno, &ttl));
+ if (rc6 != ERANGE || (herrno != NETDB_INTERNAL
+ && herrno != TRY_AGAIN))
+ break;
+ tmpbuf6 = extend_alloca (tmpbuf6, tmpbuf6len, 2 * tmpbuf6len);
+ }
+
+ if (rc6 != 0 && herrno == NETDB_INTERNAL)
+ goto out;
+
+ if (status[1] != NSS_STATUS_SUCCESS)
+ goto next_nip;
+
+ /* We found the data. Count the addresses and the size. */
+ for (const struct gaih_addrtuple *at2 = at; at2 != NULL;
+ at2 = at2->next)
+ {
+ ++naddrs;
+ /* We do not handle anything other than IPv4 and IPv6
+ addresses. The getaddrinfo implementation does not
+ either so it is not worth trying to do more. */
+ if (at2->family == AF_INET)
+ addrslen += INADDRSZ;
+ else if (at2->family == AF_INET6)
+ addrslen += IN6ADDRSZ;
+ }
+ canon = at->name;
+ canonlen = strlen (canon) + 1;
+
+ total = sizeof (*dataset) + naddrs + addrslen + canonlen;
+
+ /* Now we can allocate the data structure. If the TTL of the
+ entry is reported as zero do not cache the entry at all. */
+ if (ttl != 0 && he == NULL)
+ {
+ dataset = (struct dataset *) mempool_alloc (db, total
+ + req->key_len,
+ IDX_result_data);
+ if (dataset == NULL)
+ ++db->head->addfailed;
+ }
+
+ if (dataset == NULL)
+ {
+ /* We cannot permanently add the result in the moment. But
+ we can provide the result as is. Store the data in some
+ temporary memory. */
+ dataset = (struct dataset *) alloca (total + req->key_len);
+
+ /* We cannot add this record to the permanent database. */
+ alloca_used = true;
+ }
+
+ /* Fill in the address and address families. */
+ char *addrs = dataset->strdata;
+ uint8_t *family = (uint8_t *) (addrs + addrslen);
- /* Prefer the function which also returns the TTL and canonical name. */
- nss_gethostbyname3_r fct = __nss_lookup_function (nip,
- "gethostbyname3_r");
- if (fct == NULL)
- fct = __nss_lookup_function (nip, "gethostbyname2_r");
+ for (const struct gaih_addrtuple *at2 = at; at2 != NULL;
+ at2 = at2->next)
+ {
+ *family++ = at2->family;
+ if (at2->family == AF_INET)
+ addrs = mempcpy (addrs, at2->addr, INADDRSZ);
+ else if (at2->family == AF_INET6)
+ addrs = mempcpy (addrs, at2->addr, IN6ADDRSZ);
+ }
- if (fct != NULL)
+ cp = family;
+ }
+ else
{
+ /* Prefer the function which also returns the TTL and
+ canonical name. */
+ nss_gethostbyname3_r fct = __nss_lookup_function (nip,
+ "gethostbyname3_r");
+ if (fct == NULL)
+ fct = __nss_lookup_function (nip, "gethostbyname2_r");
+
+ if (fct == NULL)
+ goto next_nip;
+
struct hostent th[2];
/* Collect IPv6 information first. */
@@ -134,8 +226,8 @@ addhstaiX (struct database_dyn *db, int fd, request_header *req,
{
rc6 = 0;
status[0] = DL_CALL_FCT (fct, (key, AF_INET6, &th[0], tmpbuf6,
- tmpbuf6len, &rc6, &herrno,
- &ttl, &canon));
+ tmpbuf6len, &rc6, &herrno, &ttl,
+ &canon));
if (rc6 != ERANGE || herrno != NETDB_INTERNAL)
break;
tmpbuf6 = extend_alloca (tmpbuf6, tmpbuf6len, 2 * tmpbuf6len);
@@ -173,229 +265,228 @@ addhstaiX (struct database_dyn *db, int fd, request_header *req,
if (rc4 != 0 && herrno == NETDB_INTERNAL)
goto out;
- if (status[0] == NSS_STATUS_SUCCESS
- || status[1] == NSS_STATUS_SUCCESS)
+ if (status[0] != NSS_STATUS_SUCCESS
+ && status[1] != NSS_STATUS_SUCCESS)
+ goto next_nip;
+
+ /* We found the data. Count the addresses and the size. */
+ for (int j = 0; j < 2; ++j)
+ if (status[j] == NSS_STATUS_SUCCESS)
+ for (int i = 0; th[j].h_addr_list[i] != NULL; ++i)
+ {
+ ++naddrs;
+ addrslen += th[j].h_length;
+ }
+
+ if (canon == NULL)
{
- /* We found the data. Count the addresses and the size. */
- int naddrs = 0;
- size_t addrslen = 0;
- for (int j = 0; j < 2; ++j)
- if (status[j] == NSS_STATUS_SUCCESS)
- for (int i = 0; th[j].h_addr_list[i] != NULL; ++i)
+ /* Determine the canonical name. */
+ nss_getcanonname_r cfct;
+ cfct = __nss_lookup_function (nip, "getcanonname_r");
+ if (cfct != NULL)
+ {
+ const size_t max_fqdn_len = 256;
+ char *buf = alloca (max_fqdn_len);
+ char *s;
+ int rc;
+
+ if (DL_CALL_FCT (cfct, (key, buf, max_fqdn_len, &s,
+ &rc, &herrno))
+ == NSS_STATUS_SUCCESS)
+ canon = s;
+ else
+ /* Set to name now to avoid using gethostbyaddr. */
+ canon = key;
+ }
+ else
+ {
+ struct hostent *he = NULL;
+ int herrno;
+ struct hostent he_mem;
+ void *addr;
+ size_t addrlen;
+ int addrfamily;
+
+ if (status[1] == NSS_STATUS_SUCCESS)
+ {
+ addr = th[1].h_addr_list[0];
+ addrlen = sizeof (struct in_addr);
+ addrfamily = AF_INET;
+ }
+ else
{
- ++naddrs;
- addrslen += th[j].h_length;
+ addr = th[0].h_addr_list[0];
+ addrlen = sizeof (struct in6_addr);
+ addrfamily = AF_INET6;
}
- if (canon == NULL)
- {
- /* Determine the canonical name. */
- nss_getcanonname_r cfct;
- cfct = __nss_lookup_function (nip, "getcanonname_r");
- if (cfct != NULL)
+ size_t tmpbuflen = 512;
+ char *tmpbuf = alloca (tmpbuflen);
+ int rc;
+ while (1)
{
- const size_t max_fqdn_len = 256;
- char *buf = alloca (max_fqdn_len);
- char *s;
- int rc;
-
- if (DL_CALL_FCT (cfct, (key, buf, max_fqdn_len, &s, &rc,
- &herrno)) == NSS_STATUS_SUCCESS)
- canon = s;
- else
- /* Set to name now to avoid using gethostbyaddr. */
- canon = key;
+ rc = __gethostbyaddr2_r (addr, addrlen, addrfamily,
+ &he_mem, tmpbuf, tmpbuflen,
+ &he, &herrno, NULL);
+ if (rc != ERANGE || herrno != NETDB_INTERNAL)
+ break;
+ tmpbuf = extend_alloca (tmpbuf, tmpbuflen,
+ tmpbuflen * 2);
}
- else
+
+ if (rc == 0)
{
- struct hostent *he = NULL;
- int herrno;
- struct hostent he_mem;
- void *addr;
- size_t addrlen;
- int addrfamily;
-
- if (status[1] == NSS_STATUS_SUCCESS)
- {
- addr = th[1].h_addr_list[0];
- addrlen = sizeof (struct in_addr);
- addrfamily = AF_INET;
- }
+ if (he != NULL)
+ canon = he->h_name;
else
- {
- addr = th[0].h_addr_list[0];
- addrlen = sizeof (struct in6_addr);
- addrfamily = AF_INET6;
- }
-
- size_t tmpbuflen = 512;
- char *tmpbuf = alloca (tmpbuflen);
- int rc;
- while (1)
- {
- rc = __gethostbyaddr2_r (addr, addrlen, addrfamily,
- &he_mem, tmpbuf, tmpbuflen,
- &he, &herrno, NULL);
- if (rc != ERANGE || herrno != NETDB_INTERNAL)
- break;
- tmpbuf = extend_alloca (tmpbuf, tmpbuflen,
- tmpbuflen * 2);
- }
-
- if (rc == 0)
- {
- if (he != NULL)
- canon = he->h_name;
- else
- canon = key;
- }
+ canon = key;
}
}
- size_t canonlen = canon == NULL ? 0 : (strlen (canon) + 1);
+ }
- total = sizeof (*dataset) + naddrs + addrslen + canonlen;
+ canonlen = canon == NULL ? 0 : (strlen (canon) + 1);
- /* Now we can allocate the data structure. If the TTL
- of the entry is reported as zero do not cache the
- entry at all. */
- if (ttl != 0 && he == NULL)
- {
- dataset = (struct dataset *) mempool_alloc (db,
- total
- + req->key_len);
- if (dataset == NULL)
- ++db->head->addfailed;
- }
+ total = sizeof (*dataset) + naddrs + addrslen + canonlen;
+
+ /* Now we can allocate the data structure. If the TTL of the
+ entry is reported as zero do not cache the entry at all. */
+ if (ttl != 0 && he == NULL)
+ {
+ dataset = (struct dataset *) mempool_alloc (db, total
+ + req->key_len,
+ IDX_result_data);
if (dataset == NULL)
- {
- /* We cannot permanently add the result in the moment. But
- we can provide the result as is. Store the data in some
- temporary memory. */
- dataset = (struct dataset *) alloca (total + req->key_len);
+ ++db->head->addfailed;
+ }
- /* We cannot add this record to the permanent database. */
- alloca_used = true;
+ if (dataset == NULL)
+ {
+ /* We cannot permanently add the result in the moment. But
+ we can provide the result as is. Store the data in some
+ temporary memory. */
+ dataset = (struct dataset *) alloca (total + req->key_len);
+
+ /* We cannot add this record to the permanent database. */
+ alloca_used = true;
+ }
+
+ /* Fill in the address and address families. */
+ char *addrs = dataset->strdata;
+ uint8_t *family = (uint8_t *) (addrs + addrslen);
+
+ for (int j = 0; j < 2; ++j)
+ if (status[j] == NSS_STATUS_SUCCESS)
+ for (int i = 0; th[j].h_addr_list[i] != NULL; ++i)
+ {
+ addrs = mempcpy (addrs, th[j].h_addr_list[i],
+ th[j].h_length);
+ *family++ = th[j].h_addrtype;
}
- dataset->head.allocsize = total + req->key_len;
- dataset->head.recsize = total - offsetof (struct dataset, resp);
- dataset->head.notfound = false;
- dataset->head.nreloads = he == NULL ? 0 : (dh->nreloads + 1);
- dataset->head.usable = true;
-
- /* Compute the timeout time. */
- dataset->head.timeout = time (NULL) + (ttl == INT32_MAX
- ? db->postimeout : ttl);
-
- dataset->resp.version = NSCD_VERSION;
- dataset->resp.found = 1;
- dataset->resp.naddrs = naddrs;
- dataset->resp.addrslen = addrslen;
- dataset->resp.canonlen = canonlen;
- dataset->resp.error = NETDB_SUCCESS;
-
- char *addrs = (char *) (&dataset->resp + 1);
- uint8_t *family = (uint8_t *) (addrs + addrslen);
-
- for (int j = 0; j < 2; ++j)
- if (status[j] == NSS_STATUS_SUCCESS)
- for (int i = 0; th[j].h_addr_list[i] != NULL; ++i)
- {
- addrs = mempcpy (addrs, th[j].h_addr_list[i],
- th[j].h_length);
- *family++ = th[j].h_addrtype;
- }
+ cp = family;
+ }
- void *cp = family;
- if (canon != NULL)
- cp = mempcpy (cp, canon, canonlen);
+ /* Fill in the rest of the dataset. */
+ dataset->head.allocsize = total + req->key_len;
+ dataset->head.recsize = total - offsetof (struct dataset, resp);
+ dataset->head.notfound = false;
+ dataset->head.nreloads = he == NULL ? 0 : (dh->nreloads + 1);
+ dataset->head.usable = true;
- key_copy = memcpy (cp, key, req->key_len);
+ /* Compute the timeout time. */
+ dataset->head.timeout = time (NULL) + (ttl == INT32_MAX
+ ? db->postimeout : ttl);
- /* Now we can determine whether on refill we have to
- create a new record or not. */
- if (he != NULL)
- {
- assert (fd == -1);
+ dataset->resp.version = NSCD_VERSION;
+ dataset->resp.found = 1;
+ dataset->resp.naddrs = naddrs;
+ dataset->resp.addrslen = addrslen;
+ dataset->resp.canonlen = canonlen;
+ dataset->resp.error = NETDB_SUCCESS;
- if (total + req->key_len == dh->allocsize
- && total - offsetof (struct dataset, resp) == dh->recsize
- && memcmp (&dataset->resp, dh->data,
- dh->allocsize
- - offsetof (struct dataset, resp)) == 0)
- {
- /* The data has not changed. We will just bump the
- timeout value. Note that the new record has been
- allocated on the stack and need not be freed. */
- dh->timeout = dataset->head.timeout;
- ++dh->nreloads;
- }
- else
- {
- /* We have to create a new record. Just allocate
- appropriate memory and copy it. */
- struct dataset *newp
- = (struct dataset *) mempool_alloc (db,
- total
- + req->key_len);
- if (__builtin_expect (newp != NULL, 1))
- {
- /* Adjust pointer into the memory block. */
- key_copy = (char *) newp + (key_copy
- - (char *) dataset);
-
- dataset = memcpy (newp, dataset,
- total + req->key_len);
- alloca_used = false;
- }
- else
- ++db->head->addfailed;
+ if (canon != NULL)
+ cp = mempcpy (cp, canon, canonlen);
- /* Mark the old record as obsolete. */
- dh->usable = false;
- }
+ key_copy = memcpy (cp, key, req->key_len);
+
+ assert (cp == (char *) dataset + total);
+
+ /* Now we can determine whether on refill we have to create a
+ new record or not. */
+ if (he != NULL)
+ {
+ assert (fd == -1);
+
+ if (total + req->key_len == dh->allocsize
+ && total - offsetof (struct dataset, resp) == dh->recsize
+ && memcmp (&dataset->resp, dh->data,
+ dh->allocsize - offsetof (struct dataset,
+ resp)) == 0)
+ {
+ /* The data has not changed. We will just bump the
+ timeout value. Note that the new record has been
+ allocated on the stack and need not be freed. */
+ dh->timeout = dataset->head.timeout;
+ ++dh->nreloads;
+ }
+ else
+ {
+ /* We have to create a new record. Just allocate
+ appropriate memory and copy it. */
+ struct dataset *newp
+ = (struct dataset *) mempool_alloc (db, total + req->key_len,
+ IDX_result_data);
+ if (__builtin_expect (newp != NULL, 1))
+ {
+ /* Adjust pointer into the memory block. */
+ key_copy = (char *) newp + (key_copy - (char *) dataset);
+
+ dataset = memcpy (newp, dataset, total + req->key_len);
+ alloca_used = false;
}
else
- {
- /* We write the dataset before inserting it to the
- database since while inserting this thread might
- block and so would unnecessarily let the receiver
- wait. */
- assert (fd != -1);
+ ++db->head->addfailed;
+
+ /* Mark the old record as obsolete. */
+ dh->usable = false;
+ }
+ }
+ else
+ {
+ /* We write the dataset before inserting it to the database
+ since while inserting this thread might block and so
+ would unnecessarily let the receiver wait. */
+ assert (fd != -1);
#ifdef HAVE_SENDFILE
- if (__builtin_expect (db->mmap_used, 1) && !alloca_used)
- {
- assert (db->wr_fd != -1);
- assert ((char *) &dataset->resp > (char *) db->data);
- assert ((char *) &dataset->resp - (char *) db->head
- + total
- <= (sizeof (struct database_pers_head)
- + db->head->module * sizeof (ref_t)
- + db->head->data_size));
- ssize_t written;
- written = sendfileall (fd, db->wr_fd,
- (char *) &dataset->resp
- - (char *) db->head, total);
+ if (__builtin_expect (db->mmap_used, 1) && !alloca_used)
+ {
+ assert (db->wr_fd != -1);
+ assert ((char *) &dataset->resp > (char *) db->data);
+ assert ((char *) &dataset->resp - (char *) db->head + total
+ <= (sizeof (struct database_pers_head)
+ + db->head->module * sizeof (ref_t)
+ + db->head->data_size));
+ ssize_t written;
+ written = sendfileall (fd, db->wr_fd, (char *) &dataset->resp
+ - (char *) db->head, total);
# ifndef __ASSUME_SENDFILE
- if (written == -1 && errno == ENOSYS)
- goto use_write;
+ if (written == -1 && errno == ENOSYS)
+ goto use_write;
# endif
- }
- else
+ }
+ else
# ifndef __ASSUME_SENDFILE
- use_write:
+ use_write:
# endif
#endif
- writeall (fd, &dataset->resp, total);
- }
-
- goto out;
- }
-
+ writeall (fd, &dataset->resp, total);
}
+ goto out;
+
+next_nip:
if (nss_next_action (nip, status[1]) == NSS_ACTION_RETURN)
break;
@@ -424,7 +515,8 @@ addhstaiX (struct database_dyn *db, int fd, request_header *req,
if (fd != -1)
TEMP_FAILURE_RETRY (send (fd, &notfound, total, MSG_NOSIGNAL));
- dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len);
+ dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len,
+ IDX_result_data);
/* If we cannot permanently store the result, so be it. */
if (dataset != NULL)
{
@@ -465,10 +557,8 @@ addhstaiX (struct database_dyn *db, int fd, request_header *req,
/* Now get the lock to safely insert the records. */
pthread_rwlock_rdlock (&db->lock);
- if (cache_add (req->type, key_copy, req->key_len, &dataset->head, true,
- db, uid) < 0)
- /* Ensure the data can be recovered. */
- dataset->head.usable = false;
+ (void) cache_add (req->type, key_copy, req->key_len, &dataset->head,
+ true, db, uid, he == NULL);
pthread_rwlock_unlock (&db->lock);
diff --git a/libc/nscd/cache.c b/libc/nscd/cache.c
index 12c4f01e4..cd6e6b444 100644
--- a/libc/nscd/cache.c
+++ b/libc/nscd/cache.c
@@ -1,4 +1,4 @@
-/* Copyright (c) 1998, 1999, 2003-2006, 2007 Free Software Foundation, Inc.
+/* Copyright (c) 1998, 1999, 2003-2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
@@ -135,7 +135,7 @@ cache_search (request_type type, void *key, size_t len,
int
cache_add (int type, const void *key, size_t len, struct datahead *packet,
bool first, struct database_dyn *table,
- uid_t owner)
+ uid_t owner, bool prune_wakeup)
{
if (__builtin_expect (debug_level >= 2, 0))
{
@@ -155,11 +155,21 @@ cache_add (int type, const void *key, size_t len, struct datahead *packet,
unsigned long int hash = __nis_hash (key, len) % table->head->module;
struct hashentry *newp;
- newp = mempool_alloc (table, sizeof (struct hashentry));
+ newp = mempool_alloc (table, sizeof (struct hashentry), IDX_record_data);
/* If we cannot allocate memory, just do not do anything. */
if (newp == NULL)
{
++table->head->addfailed;
+
+ /* If necessary mark the entry as unusable so that lookups will
+ not use it. */
+ if (first)
+ packet->usable = false;
+
+ /* Mark the in-flight memory as unused. */
+ for (enum in_flight idx = 0; idx < IDX_record_data; ++idx)
+ mem_in_flight.block[idx].dbidx = -1;
+
return -1;
}
@@ -170,6 +180,7 @@ cache_add (int type, const void *key, size_t len, struct datahead *packet,
assert (newp->key + newp->len <= table->head->first_free);
newp->owner = owner;
newp->packet = (char *) packet - table->data;
+ assert ((newp->packet & BLOCK_ALIGN_M1) == 0);
/* Put the new entry in the first position. */
do
@@ -201,19 +212,31 @@ cache_add (int type, const void *key, size_t len, struct datahead *packet,
(char *) &table->head->array[hash] - (char *) table->head
+ sizeof (ref_t), MS_ASYNC);
- /* Perhaps the prune thread for the data is not running in a long
- time. Wake it if necessary. */
- time_t next_wakeup = table->wakeup_time;
- while (next_wakeup + CACHE_PRUNE_INTERVAL > packet->timeout)
- if (atomic_compare_and_exchange_bool_acq (&table->wakeup_time,
- packet->timeout,
- next_wakeup) == 0)
- {
+ /* We do not have to worry about the pruning thread if we are
+ re-adding the data since this is done by the pruning thread. We
+ also do not have to do anything in case this is not the first
+ time the data is entered since different data heads all have the
+ same timeout. */
+ if (first && prune_wakeup)
+ {
+ /* Perhaps the prune thread for the table is not running in a long
+ time. Wake it if necessary. */
+ pthread_mutex_lock (&table->prune_lock);
+ time_t next_wakeup = table->wakeup_time;
+ bool do_wakeup = false;
+ if (next_wakeup > packet->timeout + CACHE_PRUNE_INTERVAL)
+ {
+ table->wakeup_time = packet->timeout;
+ do_wakeup = true;
+ }
+ pthread_mutex_unlock (&table->prune_lock);
+ if (do_wakeup)
pthread_cond_signal (&table->prune_cond);
- break;
- }
- else
- next_wakeup = table->wakeup_time;
+ }
+
+ /* Mark the in-flight memory as unused. */
+ for (enum in_flight idx = 0; idx < IDX_last; ++idx)
+ mem_in_flight.block[idx].dbidx = -1;
return 0;
}
@@ -251,7 +274,7 @@ prune_cache (struct database_dyn *table, time_t now, int fd)
/* If we check for the modification of the underlying file we invalidate
the entries also in this case. */
- if (table->check_file && now != LONG_MAX)
+ if (table->inotify_descr < 0 && table->check_file && now != LONG_MAX)
{
struct stat64 st;
@@ -422,7 +445,8 @@ prune_cache (struct database_dyn *table, time_t now, int fd)
ref_t *old = &table->head->array[first];
ref_t run = table->head->array[first];
- while (run != ENDREF)
+ assert (run != ENDREF);
+ do
{
struct hashentry *runp = (struct hashentry *) (data + run);
struct datahead *dh
@@ -448,6 +472,7 @@ prune_cache (struct database_dyn *table, time_t now, int fd)
run = runp->next;
}
}
+ while (run != ENDREF);
}
++first;
diff --git a/libc/nscd/connections.c b/libc/nscd/connections.c
index 5da5e5f08..3395e54fa 100644
--- a/libc/nscd/connections.c
+++ b/libc/nscd/connections.c
@@ -35,6 +35,9 @@
#ifdef HAVE_EPOLL
# include <sys/epoll.h>
#endif
+#ifdef HAVE_INOTIFY
+# include <sys/inotify.h>
+#endif
#include <sys/mman.h>
#include <sys/param.h>
#include <sys/poll.h>
@@ -48,6 +51,7 @@
#include "nscd.h"
#include "dbg_log.h"
#include "selinux.h"
+#include <resolv/resolv.h>
#ifdef HAVE_SENDFILE
# include <kernel-features.h>
#endif
@@ -222,9 +226,30 @@ int max_nthreads = 32;
/* Socket for incoming connections. */
static int sock;
+#ifdef HAVE_INOTIFY
+/* Inotify descriptor. */
+static int inotify_fd = -1;
+
+/* Watch descriptor for resolver configuration file. */
+static int resolv_conf_descr = -1;
+#endif
+
+#ifndef __ASSUME_SOCK_CLOEXEC
+/* Negative if SOCK_CLOEXEC is not supported, positive if it is, zero
+ before be know the result. */
+static int have_sock_cloexec;
+/* The paccept syscall was introduced at the same time as SOCK_CLOEXEC. */
+# define have_paccept have_sock_cloexec
+#endif
+
/* Number of times clients had to wait. */
unsigned long int client_queued;
+/* Data structure for recording in-flight memory allocation. */
+__thread struct mem_in_flight mem_in_flight attribute_tls_model_ie;
+/* Global list of the mem_in_flight variables of all the threads. */
+struct mem_in_flight *mem_in_flight_list;
+
ssize_t
writeall (int fd, const void *buf, size_t len)
@@ -498,6 +523,19 @@ nscd_init (void)
/* No configuration for this value, assume a default. */
nthreads = 4;
+#ifdef HAVE_INOTIFY
+ /* Use inotify to recognize changed files. */
+ inotify_fd = inotify_init1 (IN_NONBLOCK);
+# ifndef __ASSUME_IN_NONBLOCK
+ if (inotify_fd == -1 && errno == ENOSYS)
+ {
+ inotify_fd = inotify_init ();
+ if (inotify_fd != -1)
+ fcntl (inotify_fd, F_SETFL, O_RDONLY | O_NONBLOCK);
+ }
+# endif
+#endif
+
for (size_t cnt = 0; cnt < lastdb; ++cnt)
if (dbs[cnt].enabled)
{
@@ -800,25 +838,57 @@ cannot set socket to close on exec: %s; disabling paranoia mode"),
assert (dbs[cnt].ro_fd == -1);
}
+ dbs[cnt].inotify_descr = -1;
if (dbs[cnt].check_file)
{
- /* We need the modification date of the file. */
- struct stat64 st;
-
- if (stat64 (dbs[cnt].filename, &st) < 0)
+#ifdef HAVE_INOTIFY
+ if (inotify_fd < 0
+ || (dbs[cnt].inotify_descr
+ = inotify_add_watch (inotify_fd, dbs[cnt].filename,
+ IN_DELETE_SELF | IN_MODIFY)) < 0)
+ /* We cannot notice changes in the main thread. */
+#endif
{
- /* We cannot stat() the file, disable file checking. */
- dbg_log (_("cannot stat() file `%s': %s"),
- dbs[cnt].filename, strerror (errno));
- dbs[cnt].check_file = 0;
+ /* We need the modification date of the file. */
+ struct stat64 st;
+
+ if (stat64 (dbs[cnt].filename, &st) < 0)
+ {
+ /* We cannot stat() the file, disable file checking. */
+ dbg_log (_("cannot stat() file `%s': %s"),
+ dbs[cnt].filename, strerror (errno));
+ dbs[cnt].check_file = 0;
+ }
+ else
+ dbs[cnt].file_mtime = st.st_mtime;
}
- else
- dbs[cnt].file_mtime = st.st_mtime;
}
+
+#ifdef HAVE_INOTIFY
+ if (cnt == hstdb && inotify_fd >= -1)
+ /* We also monitor the resolver configuration file. */
+ resolv_conf_descr = inotify_add_watch (inotify_fd,
+ _PATH_RESCONF,
+ IN_DELETE_SELF | IN_MODIFY);
+#endif
}
/* Create the socket. */
- sock = socket (AF_UNIX, SOCK_STREAM, 0);
+#ifndef __ASSUME_SOCK_CLOEXEC
+ sock = -1;
+ if (have_sock_cloexec >= 0)
+#endif
+ {
+ sock = socket (AF_UNIX, SOCK_STREAM | SOCK_CLOEXEC | SOCK_NONBLOCK, 0);
+#ifndef __ASSUME_SOCK_CLOEXEC
+ if (have_sock_cloexec == 0)
+ have_sock_cloexec = sock != -1 || errno != EINVAL ? 1 : -1;
+#endif
+ }
+#ifndef __ASSUME_SOCK_CLOEXEC
+ if (have_sock_cloexec < 0)
+ sock = socket (AF_UNIX, SOCK_STREAM, 0);
+#endif
if (sock < 0)
{
dbg_log (_("cannot open socket: %s"), strerror (errno));
@@ -834,22 +904,27 @@ cannot set socket to close on exec: %s; disabling paranoia mode"),
exit (errno == EACCES ? 4 : 1);
}
- /* We don't want to get stuck on accept. */
- int fl = fcntl (sock, F_GETFL);
- if (fl == -1 || fcntl (sock, F_SETFL, fl | O_NONBLOCK) == -1)
+#ifndef __ASSUME_SOCK_CLOEXEC
+ if (have_sock_cloexec < 0)
{
- dbg_log (_("cannot change socket to nonblocking mode: %s"),
- strerror (errno));
- exit (1);
- }
+ /* We don't want to get stuck on accept. */
+ int fl = fcntl (sock, F_GETFL);
+ if (fl == -1 || fcntl (sock, F_SETFL, fl | O_NONBLOCK) == -1)
+ {
+ dbg_log (_("cannot change socket to nonblocking mode: %s"),
+ strerror (errno));
+ exit (1);
+ }
- /* The descriptor needs to be closed on exec. */
- if (paranoia && fcntl (sock, F_SETFD, FD_CLOEXEC) == -1)
- {
- dbg_log (_("cannot set socket to close on exec: %s"),
- strerror (errno));
- exit (1);
+ /* The descriptor needs to be closed on exec. */
+ if (paranoia && fcntl (sock, F_SETFD, FD_CLOEXEC) == -1)
+ {
+ dbg_log (_("cannot set socket to close on exec: %s"),
+ strerror (errno));
+ exit (1);
+ }
}
+#endif
/* Set permissions for the socket. */
chmod (_PATH_NSCDSOCKET, DEFFILEMODE);
@@ -964,7 +1039,7 @@ send_ro_fd (struct database_dyn *db, char *key, int fd)
/* Handle new request. */
static void
-handle_request (int fd, request_header *req, void *key, uid_t uid)
+handle_request (int fd, request_header *req, void *key, uid_t uid, pid_t pid)
{
if (__builtin_expect (req->version, NSCD_VERSION) != NSCD_VERSION)
{
@@ -979,7 +1054,31 @@ cannot handle old request version %d; current version is %d"),
if (selinux_enabled && nscd_request_avc_has_perm (fd, req->type) != 0)
{
if (debug_level > 0)
- dbg_log (_("request not handled due to missing permission"));
+ {
+#ifdef SO_PEERCRED
+# ifdef PATH_MAX
+ char buf[PATH_MAX];
+# else
+ char buf[4096];
+# endif
+
+ snprintf (buf, sizeof (buf), "/proc/%ld/exe", (long int) pid);
+ ssize_t n = readlink (buf, buf, sizeof (buf) - 1);
+
+ if (n <= 0)
+ dbg_log (_("\
+request from %ld not handled due to missing permission"), (long int) pid);
+ else
+ {
+ buf[n] = '\0';
+ dbg_log (_("\
+request from '%s' [%ld] not handled due to missing permission"),
+ buf, (long int) pid);
+ }
+#else
+ dbg_log (_("request not handled due to missing permission"));
+#endif
+ }
return;
}
@@ -1301,11 +1400,14 @@ cannot change to old working directory: %s; disabling paranoia mode"),
}
/* Synchronize memory. */
+ int32_t certainly[lastdb];
for (int cnt = 0; cnt < lastdb; ++cnt)
if (dbs[cnt].enabled)
{
/* Make sure nobody keeps using the database. */
dbs[cnt].head->timestamp = 0;
+ certainly[cnt] = dbs[cnt].head->nscd_certainly_running;
+ dbs[cnt].head->nscd_certainly_running = 0;
if (dbs[cnt].persistent)
// XXX async OK?
@@ -1328,6 +1430,15 @@ cannot change to old working directory: %s; disabling paranoia mode"),
dbg_log (_("cannot change current working directory to \"/\": %s"),
strerror (errno));
paranoia = 0;
+
+ /* Reenable the databases. */
+ time_t now = time (NULL);
+ for (int cnt = 0; cnt < lastdb; ++cnt)
+ if (dbs[cnt].enabled)
+ {
+ dbs[cnt].head->timestamp = now;
+ dbs[cnt].head->nscd_certainly_running = certainly[cnt];
+ }
}
@@ -1365,42 +1476,75 @@ nscd_run_prune (void *p)
int dont_need_update = setup_thread (&dbs[my_number]);
+ time_t now = time (NULL);
+
/* We are running. */
- dbs[my_number].head->timestamp = time (NULL);
+ dbs[my_number].head->timestamp = now;
struct timespec prune_ts;
- if (clock_gettime (timeout_clock, &prune_ts) == -1)
+ if (__builtin_expect (clock_gettime (timeout_clock, &prune_ts) == -1, 0))
/* Should never happen. */
abort ();
/* Compute the initial timeout time. Prevent all the timers to go
off at the same time by adding a db-based value. */
prune_ts.tv_sec += CACHE_PRUNE_INTERVAL + my_number;
+ dbs[my_number].wakeup_time = now + CACHE_PRUNE_INTERVAL + my_number;
+
+ pthread_mutex_t *prune_lock = &dbs[my_number].prune_lock;
+ pthread_cond_t *prune_cond = &dbs[my_number].prune_cond;
- pthread_mutex_lock (&dbs[my_number].prune_lock);
+ pthread_mutex_lock (prune_lock);
while (1)
{
/* Wait, but not forever. */
- int e = pthread_cond_timedwait (&dbs[my_number].prune_cond,
- &dbs[my_number].prune_lock,
- &prune_ts);
- assert (e == 0 || e == ETIMEDOUT);
+ int e = 0;
+ if (! dbs[my_number].clear_cache)
+ e = pthread_cond_timedwait (prune_cond, prune_lock, &prune_ts);
+ assert (__builtin_expect (e == 0 || e == ETIMEDOUT, 1));
time_t next_wait;
- time_t now = time (NULL);
- if (e == ETIMEDOUT || now >= dbs[my_number].wakeup_time)
+ now = time (NULL);
+ if (e == ETIMEDOUT || now >= dbs[my_number].wakeup_time
+ || dbs[my_number].clear_cache)
{
- next_wait = prune_cache (&dbs[my_number], now, -1);
+ /* We will determine the new timout values based on the
+ cache content. Should there be concurrent additions to
+ the cache which are not accounted for in the cache
+ pruning we want to know about it. Therefore set the
+ timeout to the maximum. It will be descreased when adding
+ new entries to the cache, if necessary. */
+ if (sizeof (time_t) == sizeof (long int))
+ dbs[my_number].wakeup_time = LONG_MAX;
+ else
+ dbs[my_number].wakeup_time = INT_MAX;
+
+ /* Unconditionally reset the flag. */
+ time_t prune_now = dbs[my_number].clear_cache ? LONG_MAX : now;
+ dbs[my_number].clear_cache = 0;
+
+ pthread_mutex_unlock (prune_lock);
+
+ next_wait = prune_cache (&dbs[my_number], prune_now, -1);
+
next_wait = MAX (next_wait, CACHE_PRUNE_INTERVAL);
/* If clients cannot determine for sure whether nscd is running
we need to wake up occasionally to update the timestamp.
Wait 90% of the update period. */
#define UPDATE_MAPPING_TIMEOUT (MAPPING_TIMEOUT * 9 / 10)
if (__builtin_expect (! dont_need_update, 0))
- next_wait = MIN (UPDATE_MAPPING_TIMEOUT, next_wait);
+ {
+ next_wait = MIN (UPDATE_MAPPING_TIMEOUT, next_wait);
+ dbs[my_number].head->timestamp = now;
+ }
+
+ pthread_mutex_lock (prune_lock);
/* Make it known when we will wake up again. */
- dbs[my_number].wakeup_time = now + next_wait;
+ if (now + next_wait < dbs[my_number].wakeup_time)
+ dbs[my_number].wakeup_time = now + next_wait;
+ else
+ next_wait = dbs[my_number].wakeup_time - now;
}
else
/* The cache was just pruned. Do not do it again now. Just
@@ -1426,6 +1570,16 @@ nscd_run_worker (void *p)
{
char buf[256];
+ /* Initialize the memory-in-flight list. */
+ for (enum in_flight idx = 0; idx < IDX_last; ++idx)
+ mem_in_flight.block[idx].dbidx = -1;
+ /* And queue this threads structure. */
+ do
+ mem_in_flight.next = mem_in_flight_list;
+ while (atomic_compare_and_exchange_bool_acq (&mem_in_flight_list,
+ &mem_in_flight,
+ mem_in_flight.next) != 0);
+
/* Initial locking. */
pthread_mutex_lock (&readylist_lock);
@@ -1455,10 +1609,15 @@ nscd_run_worker (void *p)
/* We are done with the list. */
pthread_mutex_unlock (&readylist_lock);
- /* We do not want to block on a short read or so. */
- int fl = fcntl (fd, F_GETFL);
- if (fl == -1 || fcntl (fd, F_SETFL, fl | O_NONBLOCK) == -1)
- goto close_and_out;
+#ifndef __ASSUME_SOCK_CLOEXEC
+ if (have_sock_cloexec < 0)
+ {
+ /* We do not want to block on a short read or so. */
+ int fl = fcntl (fd, F_GETFL);
+ if (fl == -1 || fcntl (fd, F_SETFL, fl | O_NONBLOCK) == -1)
+ goto close_and_out;
+ }
+#endif
/* Now read the request. */
request_header req;
@@ -1491,6 +1650,8 @@ nscd_run_worker (void *p)
if (getsockopt (fd, SOL_SOCKET, SO_PEERCRED, &caller, &optlen) == 0)
pid = caller.pid;
}
+#else
+ const pid_t pid = 0;
#endif
/* It should not be possible to crash the nscd with a silly
@@ -1531,7 +1692,7 @@ handle_request: request received (Version = %d)"), req.version);
}
/* Phew, we got all the data, now process it. */
- handle_request (fd, &req, keybuf, uid);
+ handle_request (fd, &req, keybuf, uid, pid);
}
close_and_out:
@@ -1624,6 +1785,16 @@ main_loop_poll (void)
size_t nused = 1;
size_t firstfree = 1;
+#ifdef HAVE_INOTIFY
+ if (inotify_fd != -1)
+ {
+ conns[1].fd = inotify_fd;
+ conns[1].events = POLLRDNORM;
+ nused = 2;
+ firstfree = 2;
+ }
+#endif
+
while (1)
{
/* Wait for any event. We wait at most a couple of seconds so
@@ -1646,7 +1817,24 @@ main_loop_poll (void)
if (conns[0].revents != 0)
{
/* We have a new incoming connection. Accept the connection. */
- int fd = TEMP_FAILURE_RETRY (accept (sock, NULL, NULL));
+ int fd;
+
+#ifndef __ASSUME_PACCEPT
+ fd = -1;
+ if (have_paccept >= 0)
+#endif
+ {
+ fd = TEMP_FAILURE_RETRY (paccept (sock, NULL, NULL, NULL,
+ SOCK_NONBLOCK));
+#ifndef __ASSUME_PACCEPT
+ if (have_paccept == 0)
+ have_paccept = fd != -1 || errno != ENOSYS ? 1 : -1;
+#endif
+ }
+#ifndef __ASSUME_PACCEPT
+ if (have_paccept < 0)
+ fd = TEMP_FAILURE_RETRY (accept (sock, NULL, NULL));
+#endif
/* Use the descriptor if we have not reached the limit. */
if (fd >= 0)
@@ -1671,7 +1859,80 @@ main_loop_poll (void)
--n;
}
- for (size_t cnt = 1; cnt < nused && n > 0; ++cnt)
+ size_t first = 1;
+#ifdef HAVE_INOTIFY
+ if (inotify_fd != -1 && conns[1].fd == inotify_fd)
+ {
+ if (conns[1].revents != 0)
+ {
+ bool to_clear[lastdb] = { false, };
+ union
+ {
+# ifndef PATH_MAX
+# define PATH_MAX 1024
+# endif
+ struct inotify_event i;
+ char buf[sizeof (struct inotify_event) + PATH_MAX];
+ } inev;
+
+ while (1)
+ {
+ ssize_t nb = TEMP_FAILURE_RETRY (read (inotify_fd, &inev,
+ sizeof (inev)));
+ if (nb < (ssize_t) sizeof (struct inotify_event))
+ {
+ if (__builtin_expect (nb == -1 && errno != EAGAIN,
+ 0))
+ {
+ /* Something went wrong when reading the inotify
+ data. Better disable inotify. */
+ dbg_log (_("\
+disabled inotify after read error %d"),
+ errno);
+ conns[1].fd = -1;
+ firstfree = 1;
+ if (nused == 2)
+ nused = 1;
+ close (inotify_fd);
+ inotify_fd = -1;
+ }
+ break;
+ }
+
+ /* Check which of the files changed. */
+ for (size_t dbcnt = 0; dbcnt < lastdb; ++dbcnt)
+ if (inev.i.wd == dbs[dbcnt].inotify_descr)
+ {
+ to_clear[dbcnt] = true;
+ goto next;
+ }
+
+ if (inev.i.wd == resolv_conf_descr)
+ {
+ res_init ();
+ to_clear[hstdb] = true;
+ }
+ next:;
+ }
+
+ /* Actually perform the cache clearing. */
+ for (size_t dbcnt = 0; dbcnt < lastdb; ++dbcnt)
+ if (to_clear[dbcnt])
+ {
+ pthread_mutex_lock (&dbs[dbcnt].prune_lock);
+ dbs[dbcnt].clear_cache = 1;
+ pthread_mutex_unlock (&dbs[dbcnt].prune_lock);
+ pthread_cond_signal (&dbs[dbcnt].prune_cond);
+ }
+
+ --n;
+ }
+
+ first = 2;
+ }
+#endif
+
+ for (size_t cnt = first; cnt < nused && n > 0; ++cnt)
if (conns[cnt].revents != 0)
{
fd_ready (conns[cnt].fd);
@@ -1737,6 +1998,18 @@ main_loop_epoll (int efd)
/* We cannot use epoll. */
return;
+#ifdef HAVE_INOTIFY
+ if (inotify_fd != -1)
+ {
+ ev.events = EPOLLRDNORM;
+ ev.data.fd = inotify_fd;
+ if (epoll_ctl (efd, EPOLL_CTL_ADD, inotify_fd, &ev) == -1)
+ /* We cannot use epoll. */
+ return;
+ nused = 2;
+ }
+#endif
+
while (1)
{
struct epoll_event revs[100];
@@ -1773,6 +2046,63 @@ main_loop_epoll (int efd)
}
}
}
+#ifdef HAVE_INOTIFY
+ else if (revs[cnt].data.fd == inotify_fd)
+ {
+ bool to_clear[lastdb] = { false, };
+ union
+ {
+ struct inotify_event i;
+ char buf[sizeof (struct inotify_event) + PATH_MAX];
+ } inev;
+
+ while (1)
+ {
+ ssize_t nb = TEMP_FAILURE_RETRY (read (inotify_fd, &inev,
+ sizeof (inev)));
+ if (nb < (ssize_t) sizeof (struct inotify_event))
+ {
+ if (__builtin_expect (nb == -1 && errno != EAGAIN, 0))
+ {
+ /* Something went wrong when reading the inotify
+ data. Better disable inotify. */
+ dbg_log (_("disabled inotify after read error %d"),
+ errno);
+ (void) epoll_ctl (efd, EPOLL_CTL_DEL, inotify_fd,
+ NULL);
+ close (inotify_fd);
+ inotify_fd = -1;
+ }
+ break;
+ }
+
+ /* Check which of the files changed. */
+ for (size_t dbcnt = 0; dbcnt < lastdb; ++dbcnt)
+ if (inev.i.wd == dbs[dbcnt].inotify_descr)
+ {
+ to_clear[dbcnt] = true;
+ goto next;
+ }
+
+ if (inev.i.wd == resolv_conf_descr)
+ {
+ res_init ();
+ to_clear[hstdb] = true;
+ }
+ next:;
+ }
+
+ /* Actually perform the cache clearing. */
+ for (size_t dbcnt = 0; dbcnt < lastdb; ++dbcnt)
+ if (to_clear[dbcnt])
+ {
+ pthread_mutex_lock (&dbs[dbcnt].prune_lock);
+ dbs[dbcnt].clear_cache = 1;
+ pthread_mutex_unlock (&dbs[dbcnt].prune_lock);
+ pthread_cond_signal (&dbs[dbcnt].prune_cond);
+ }
+ }
+#endif
else
{
/* Remove the descriptor from the epoll descriptor. */
@@ -1794,8 +2124,10 @@ main_loop_epoll (int efd)
/* Now look for descriptors for accepted connections which have
no reply in too long of a time. */
time_t laststart = now - ACCEPT_TIMEOUT;
+ assert (starttime[sock] == 0);
+ assert (inotify_fd == -1 || starttime[inotify_fd] == 0);
for (int cnt = highest; cnt > STDERR_FILENO; --cnt)
- if (cnt != sock && starttime[cnt] != 0 && starttime[cnt] < laststart)
+ if (starttime[cnt] != 0 && starttime[cnt] < laststart)
{
/* We are waiting for this one for too long. Close it. */
(void) epoll_ctl (efd, EPOLL_CTL_DEL, cnt, NULL);
diff --git a/libc/nscd/grpcache.c b/libc/nscd/grpcache.c
index 002f04fb3..c49c0e190 100644
--- a/libc/nscd/grpcache.c
+++ b/libc/nscd/grpcache.c
@@ -1,5 +1,5 @@
/* Cache handling for group lookup.
- Copyright (C) 1998-2005, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1998-2005, 2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
@@ -113,7 +113,8 @@ cache_addgr (struct database_dyn *db, int fd, request_header *req,
written = TEMP_FAILURE_RETRY (send (fd, &notfound, total,
MSG_NOSIGNAL));
- dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len);
+ dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len,
+ IDX_result_data);
/* If we cannot permanently store the result, so be it. */
if (dataset != NULL)
{
@@ -145,10 +146,8 @@ cache_addgr (struct database_dyn *db, int fd, request_header *req,
/* Now get the lock to safely insert the records. */
pthread_rwlock_rdlock (&db->lock);
- if (cache_add (req->type, &dataset->strdata, req->key_len,
- &dataset->head, true, db, owner) < 0)
- /* Ensure the data can be recovered. */
- dataset->head.usable = false;
+ (void) cache_add (req->type, &dataset->strdata, req->key_len,
+ &dataset->head, true, db, owner, he == NULL);
pthread_rwlock_unlock (&db->lock);
@@ -191,7 +190,7 @@ cache_addgr (struct database_dyn *db, int fd, request_header *req,
gr_mem_len_total += gr_mem_len[gr_mem_cnt];
}
- written = total = (sizeof (struct dataset)
+ written = total = (offsetof (struct dataset, strdata)
+ gr_mem_cnt * sizeof (uint32_t)
+ gr_name_len + gr_passwd_len + gr_mem_len_total);
@@ -204,7 +203,8 @@ cache_addgr (struct database_dyn *db, int fd, request_header *req,
if (he == NULL)
{
- dataset = (struct dataset *) mempool_alloc (db, total + n);
+ dataset = (struct dataset *) mempool_alloc (db, total + n,
+ IDX_result_data);
if (dataset == NULL)
++db->head->addfailed;
}
@@ -252,6 +252,9 @@ cache_addgr (struct database_dyn *db, int fd, request_header *req,
char *key_copy = cp + key_offset;
assert (key_copy == (char *) rawmemchr (cp, '\0') + 1);
+ assert (cp == dataset->strdata + total - offsetof (struct dataset,
+ strdata));
+
/* Now we can determine whether on refill we have to create a new
record or not. */
if (he != NULL)
@@ -274,7 +277,8 @@ cache_addgr (struct database_dyn *db, int fd, request_header *req,
/* We have to create a new record. Just allocate
appropriate memory and copy it. */
struct dataset *newp
- = (struct dataset *) mempool_alloc (db, total + n);
+ = (struct dataset *) mempool_alloc (db, total + n,
+ IDX_result_data);
if (newp != NULL)
{
/* Adjust pointers into the memory block. */
@@ -352,13 +356,8 @@ cache_addgr (struct database_dyn *db, int fd, request_header *req,
if (req->type == GETGRBYGID)
{
if (cache_add (GETGRBYGID, cp, key_offset, &dataset->head, true,
- db, owner) < 0)
- {
- /* Could not allocate memory. Make sure the data gets
- discarded. */
- dataset->head.usable = false;
- goto out;
- }
+ db, owner, he == NULL) < 0)
+ goto out;
first = false;
}
@@ -366,13 +365,8 @@ cache_addgr (struct database_dyn *db, int fd, request_header *req,
else if (strcmp (key_copy, gr_name) != 0)
{
if (cache_add (GETGRBYNAME, key_copy, key_len + 1,
- &dataset->head, true, db, owner) < 0)
- {
- /* Could not allocate memory. Make sure the data gets
- discarded. */
- dataset->head.usable = false;
- goto out;
- }
+ &dataset->head, true, db, owner, he == NULL) < 0)
+ goto out;
first = false;
}
@@ -381,17 +375,14 @@ cache_addgr (struct database_dyn *db, int fd, request_header *req,
if ((req->type == GETGRBYNAME || db->propagate)
&& __builtin_expect (cache_add (GETGRBYNAME, gr_name,
gr_name_len,
- &dataset->head, first, db, owner)
+ &dataset->head, first, db, owner,
+ he == NULL)
== 0, 1))
{
if (req->type == GETGRBYNAME && db->propagate)
(void) cache_add (GETGRBYGID, cp, key_offset, &dataset->head,
- req->type != GETGRBYNAME, db, owner);
+ false, db, owner, false);
}
- else if (first)
- /* Could not allocate memory. Make sure the data gets
- discarded. */
- dataset->head.usable = false;
out:
pthread_rwlock_unlock (&db->lock);
diff --git a/libc/nscd/hstcache.c b/libc/nscd/hstcache.c
index cc041581e..4333917ba 100644
--- a/libc/nscd/hstcache.c
+++ b/libc/nscd/hstcache.c
@@ -1,5 +1,5 @@
/* Cache handling for host lookup.
- Copyright (C) 1998-2005, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1998-2005, 2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
@@ -83,8 +83,7 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
struct hashentry *he, struct datahead *dh, int errval,
int32_t ttl)
{
- ssize_t total;
- ssize_t written;
+ bool all_written = true;
time_t t = time (NULL);
/* We allocate all data in one memory block: the iov vector,
@@ -108,20 +107,20 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
if (reload_count != UINT_MAX)
/* Do not reset the value if we never not reload the record. */
dh->nreloads = reload_count - 1;
-
- written = total = 0;
}
else
{
/* We have no data. This means we send the standard reply for this
case. */
- written = total = sizeof (notfound);
+ ssize_t total = sizeof (notfound);
- if (fd != -1)
- written = TEMP_FAILURE_RETRY (send (fd, &notfound, total,
- MSG_NOSIGNAL));
+ if (fd != -1 &&
+ TEMP_FAILURE_RETRY (send (fd, &notfound, total,
+ MSG_NOSIGNAL)) != total)
+ all_written = false;
- dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len);
+ dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len,
+ IDX_result_data);
/* If we cannot permanently store the result, so be it. */
if (dataset != NULL)
{
@@ -154,10 +153,8 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
/* Now get the lock to safely insert the records. */
pthread_rwlock_rdlock (&db->lock);
- if (cache_add (req->type, &dataset->strdata, req->key_len,
- &dataset->head, true, db, owner) < 0)
- /* Ensure the data can be recovered. */
- dataset->head.usable = false;
+ (void) cache_add (req->type, &dataset->strdata, req->key_len,
+ &dataset->head, true, db, owner, he == NULL);
pthread_rwlock_unlock (&db->lock);
@@ -182,6 +179,7 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
char *key_copy = NULL;
char *cp;
size_t cnt;
+ ssize_t total;
/* Determine the number of aliases. */
h_aliases_cnt = 0;
@@ -209,7 +207,6 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
+ h_name_len
+ h_aliases_cnt * sizeof (uint32_t)
+ h_addr_list_cnt * hst->h_length);
- written = total;
/* If we refill the cache, first assume the reconrd did not
change. Allocate memory on the cache since it is likely
@@ -226,7 +223,8 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
if (he == NULL && h_addr_list_cnt == 1)
{
dataset = (struct dataset *) mempool_alloc (db,
- total + req->key_len);
+ total + req->key_len,
+ IDX_result_data);
if (dataset == NULL)
++db->head->addfailed;
}
@@ -260,6 +258,9 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
dataset->resp.h_addr_list_cnt = h_addr_list_cnt;
dataset->resp.error = NETDB_SUCCESS;
+ /* Make sure there is no gap. */
+ assert ((char *) (&dataset->resp.error + 1) == dataset->strdata);
+
cp = dataset->strdata;
cp = mempcpy (cp, hst->h_name, h_name_len);
@@ -286,6 +287,8 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
we explicitly add the name here. */
key_copy = memcpy (cp, key, req->key_len);
+ assert ((char *) &dataset->resp + dataset->head.recsize == cp);
+
/* Now we can determine whether on refill we have to create a new
record or not. */
if (he != NULL)
@@ -312,7 +315,8 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
appropriate memory and copy it. */
struct dataset *newp
= (struct dataset *) mempool_alloc (db,
- total + req->key_len);
+ total + req->key_len,
+ IDX_result_data);
if (newp != NULL)
{
/* Adjust pointers into the memory block. */
@@ -350,20 +354,27 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
<= (sizeof (struct database_pers_head)
+ db->head->module * sizeof (ref_t)
+ db->head->data_size));
- written = sendfileall (fd, db->wr_fd,
- (char *) &dataset->resp
- - (char *) db->head, total);
+ ssize_t written = sendfileall (fd, db->wr_fd,
+ (char *) &dataset->resp
+ - (char *) db->head,
+ dataset->head.recsize);
+ if (written != dataset->head.recsize)
+ {
# ifndef __ASSUME_SENDFILE
- if (written == -1 && errno == ENOSYS)
- goto use_write;
+ if (written == -1 && errno == ENOSYS)
+ goto use_write;
# endif
+ all_written = false;
+ }
}
else
# ifndef __ASSUME_SENDFILE
use_write:
# endif
#endif
- written = writeall (fd, &dataset->resp, total);
+ if (writeall (fd, &dataset->resp, dataset->head.recsize)
+ != dataset->head.recsize)
+ all_written = false;
}
/* Add the record to the database. But only if it has not been
@@ -406,17 +417,14 @@ cache_addhst (struct database_dyn *db, int fd, request_header *req,
|| req->type == GETHOSTBYADDR
|| req->type == GETHOSTBYADDRv6);
- if (cache_add (req->type, key_copy, req->key_len,
- &dataset->head, true, db, owner) < 0)
- /* Could not allocate memory. Make sure the
- data gets discarded. */
- dataset->head.usable = false;
+ (void) cache_add (req->type, key_copy, req->key_len,
+ &dataset->head, true, db, owner, he == NULL);
pthread_rwlock_unlock (&db->lock);
}
}
- if (__builtin_expect (written != total, 0) && debug_level > 0)
+ if (__builtin_expect (!all_written, 0) && debug_level > 0)
{
char buf[256];
dbg_log (_("short write in %s: %s"), __FUNCTION__,
diff --git a/libc/nscd/initgrcache.c b/libc/nscd/initgrcache.c
index 157cd7860..c5693c6be 100644
--- a/libc/nscd/initgrcache.c
+++ b/libc/nscd/initgrcache.c
@@ -1,5 +1,5 @@
/* Cache handling for host lookup.
- Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2004, 2005, 2006, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2004.
@@ -197,7 +197,8 @@ addinitgroupsX (struct database_dyn *db, int fd, request_header *req,
written = TEMP_FAILURE_RETRY (send (fd, &notfound, total,
MSG_NOSIGNAL));
- dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len);
+ dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len,
+ IDX_result_data);
/* If we cannot permanently store the result, so be it. */
if (dataset != NULL)
{
@@ -229,10 +230,8 @@ addinitgroupsX (struct database_dyn *db, int fd, request_header *req,
/* Now get the lock to safely insert the records. */
pthread_rwlock_rdlock (&db->lock);
- if (cache_add (req->type, key_copy, req->key_len,
- &dataset->head, true, db, uid) < 0)
- /* Ensure the data can be recovered. */
- dataset->head.usable = false;
+ (void) cache_add (req->type, key_copy, req->key_len,
+ &dataset->head, true, db, uid, he == NULL);
pthread_rwlock_unlock (&db->lock);
@@ -247,7 +246,8 @@ addinitgroupsX (struct database_dyn *db, int fd, request_header *req,
else
{
- written = total = sizeof (struct dataset) + start * sizeof (int32_t);
+ written = total = (offsetof (struct dataset, strdata)
+ + start * sizeof (int32_t));
/* If we refill the cache, first assume the reconrd did not
change. Allocate memory on the cache since it is likely
@@ -259,7 +259,8 @@ addinitgroupsX (struct database_dyn *db, int fd, request_header *req,
if (he == NULL)
{
dataset = (struct dataset *) mempool_alloc (db,
- total + req->key_len);
+ total + req->key_len,
+ IDX_result_data);
if (dataset == NULL)
++db->head->addfailed;
}
@@ -307,6 +308,9 @@ addinitgroupsX (struct database_dyn *db, int fd, request_header *req,
/* Finally the user name. */
memcpy (cp, key, req->key_len);
+ assert (cp == dataset->strdata + total - offsetof (struct dataset,
+ strdata));
+
/* Now we can determine whether on refill we have to create a new
record or not. */
if (he != NULL)
@@ -329,7 +333,8 @@ addinitgroupsX (struct database_dyn *db, int fd, request_header *req,
/* We have to create a new record. Just allocate
appropriate memory and copy it. */
struct dataset *newp
- = (struct dataset *) mempool_alloc (db, total + req->key_len);
+ = (struct dataset *) mempool_alloc (db, total + req->key_len,
+ IDX_result_data);
if (newp != NULL)
{
/* Adjust pointer into the memory block. */
@@ -396,11 +401,8 @@ addinitgroupsX (struct database_dyn *db, int fd, request_header *req,
/* Now get the lock to safely insert the records. */
pthread_rwlock_rdlock (&db->lock);
- if (cache_add (INITGROUPS, cp, req->key_len, &dataset->head, true,
- db, uid) < 0)
- /* Could not allocate memory. Make sure the data gets
- discarded. */
- dataset->head.usable = false;
+ (void) cache_add (INITGROUPS, cp, req->key_len, &dataset->head, true,
+ db, uid, he == NULL);
pthread_rwlock_unlock (&db->lock);
}
diff --git a/libc/nscd/mem.c b/libc/nscd/mem.c
index 048e3ddd3..e821729da 100644
--- a/libc/nscd/mem.c
+++ b/libc/nscd/mem.c
@@ -1,5 +1,5 @@
/* Cache memory handling.
- Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2004, 2005, 2006, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2004.
@@ -24,6 +24,7 @@
#include <inttypes.h>
#include <libintl.h>
#include <limits.h>
+#include <obstack.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
@@ -79,6 +80,7 @@ static void
markrange (BITMAP_T *mark, ref_t start, size_t len)
{
/* Adjust parameters for block alignment. */
+ assert ((start & BLOCK_ALIGN_M1) == 0);
start /= BLOCK_ALIGN;
len = (len + BLOCK_ALIGN_M1) / BLOCK_ALIGN;
@@ -93,7 +95,7 @@ markrange (BITMAP_T *mark, ref_t start, size_t len)
return;
}
- mark[elem++] |= 0xff << (start % BITS);
+ mark[elem++] |= ALLBITS << (start % BITS);
len -= BITS - (start % BITS);
}
@@ -130,14 +132,14 @@ gc (struct database_dyn *db)
size_t stack_used = sizeof (bool) * db->head->module;
if (__builtin_expect (stack_used > MAX_STACK_USE, 0))
stack_used = 0;
- size_t memory_needed = ((db->head->first_free / BLOCK_ALIGN + BITS - 1)
- / BITS) * sizeof (BITMAP_T);
- if (memory_needed <= MAX_STACK_USE)
+ size_t nmark = (db->head->first_free / BLOCK_ALIGN + BITS - 1) / BITS;
+ size_t memory_needed = nmark * sizeof (BITMAP_T);
+ if (stack_used + memory_needed <= MAX_STACK_USE)
{
mark = (BITMAP_T *) alloca (memory_needed);
mark_use_malloc = false;
memset (mark, '\0', memory_needed);
- stack_used = memory_needed;
+ stack_used += memory_needed;
}
else
{
@@ -156,6 +158,7 @@ gc (struct database_dyn *db)
he = alloca (db->head->nentries * sizeof (struct hashentry *));
he_data = alloca (db->head->nentries * sizeof (struct hashentry *));
he_use_malloc = false;
+ stack_used += memory_needed;
}
else
{
@@ -197,6 +200,32 @@ gc (struct database_dyn *db)
}
assert (cnt == db->head->nentries);
+ /* Go through the list of in-flight memory blocks. */
+ struct mem_in_flight *mrunp = mem_in_flight_list;
+ while (mrunp != NULL)
+ {
+ /* NB: There can be no race between this test and another thread
+ setting the field to the index we are looking for because
+ this would require the other thread to also have the memlock
+ for the database.
+
+ NB2: we do not have to look at latter blocks (higher indices) if
+ earlier blocks are not in flight. They are always allocated in
+ sequence. */
+ for (enum in_flight idx = IDX_result_data;
+ idx < IDX_last && mrunp->block[idx].dbidx == db - dbs; ++idx)
+ {
+ assert (mrunp->block[idx].blockoff >= 0);
+ assert (mrunp->block[idx].blocklen < db->memsize);
+ assert (mrunp->block[idx].blockoff
+ + mrunp->block[0].blocklen <= db->memsize);
+ markrange (mark, mrunp->block[idx].blockoff,
+ mrunp->block[idx].blocklen);
+ }
+
+ mrunp = mrunp->next;
+ }
+
/* Sort the entries by the addresses of the referenced data. All
the entries pointing to the same DATAHEAD object will have the
same key. Stability of the sorting is unimportant. */
@@ -206,8 +235,13 @@ gc (struct database_dyn *db)
/* Sort the entries by their address. */
qsort (he, cnt, sizeof (struct hashentry *), sort_he);
+#define obstack_chunk_alloc xmalloc
+#define obstack_chunk_free free
+ struct obstack ob;
+ obstack_init (&ob);
+
/* Determine the highest used address. */
- size_t high = sizeof (mark);
+ size_t high = nmark;
while (high > 0 && mark[high - 1] == 0)
--high;
@@ -338,8 +372,14 @@ gc (struct database_dyn *db)
displacement. */
ref_t disp = off_alloc - off_free;
- struct moveinfo *new_move
- = (struct moveinfo *) alloca (sizeof (*new_move));
+ struct moveinfo *new_move;
+ if (stack_used + sizeof (*new_move) <= MAX_STACK_USE)
+ {
+ new_move = alloca (sizeof (*new_move));
+ stack_used += sizeof (*new_move);
+ }
+ else
+ new_move = obstack_alloc (&ob, sizeof (*new_move));
new_move->from = db->data + off_alloc;
new_move->to = db->data + off_free;
new_move->size = off_allocend - off_alloc;
@@ -499,11 +539,13 @@ gc (struct database_dyn *db)
free (he);
if (mark_use_malloc)
free (mark);
+
+ obstack_free (&ob, NULL);
}
void *
-mempool_alloc (struct database_dyn *db, size_t len)
+mempool_alloc (struct database_dyn *db, size_t len, enum in_flight idx)
{
/* Make sure LEN is a multiple of our maximum alignment so we can
keep track of used memory is multiples of this alignment value. */
@@ -564,9 +606,16 @@ mempool_alloc (struct database_dyn *db, size_t len)
}
else
{
+ /* Remember that we have allocated this memory. */
+ assert (idx >= 0 && idx < IDX_last);
+ mem_in_flight.block[idx].dbidx = db - dbs;
+ mem_in_flight.block[idx].blocklen = len;
+ mem_in_flight.block[idx].blockoff = db->head->first_free;
+
db->head->first_free += len;
db->last_alloc_failed = false;
+
}
pthread_mutex_unlock (&db->memlock);
diff --git a/libc/nscd/nscd.h b/libc/nscd/nscd.h
index ec2d9454c..5c77dd3c4 100644
--- a/libc/nscd/nscd.h
+++ b/libc/nscd/nscd.h
@@ -73,6 +73,8 @@ struct database_dyn
int enabled;
int check_file;
+ int inotify_descr;
+ int clear_cache;
int persistent;
int shared;
int propagate;
@@ -130,7 +132,7 @@ struct database_dyn
/* Global variables. */
-extern struct database_dyn dbs[lastdb];
+extern struct database_dyn dbs[lastdb] attribute_hidden;
extern const char *const dbnames[lastdb];
extern const char *const serv2str[LASTREQ];
@@ -181,6 +183,31 @@ extern uid_t old_uid;
extern gid_t old_gid;
+/* Memory allocation in flight. Each thread can have a limited number
+ of allocation in flight. No need to create dynamic data
+ structures. We use fixed indices. */
+enum in_flight
+ {
+ IDX_result_data = 0,
+ /* Keep the IDX_record_data entry last at all times. */
+ IDX_record_data = 1,
+ IDX_last
+ };
+extern __thread struct mem_in_flight
+{
+ struct
+ {
+ int dbidx;
+ nscd_ssize_t blocklen;
+ nscd_ssize_t blockoff;
+ } block[IDX_last];
+
+ struct mem_in_flight *next;
+} mem_in_flight attribute_tls_model_ie;
+/* Global list of the mem_in_flight variables of all the threads. */
+extern struct mem_in_flight *mem_in_flight_list;
+
+
/* Prototypes for global functions. */
/* nscd.c */
@@ -206,7 +233,8 @@ extern struct datahead *cache_search (request_type, void *key, size_t len,
uid_t owner);
extern int cache_add (int type, const void *key, size_t len,
struct datahead *packet, bool first,
- struct database_dyn *table, uid_t owner);
+ struct database_dyn *table, uid_t owner,
+ bool prune_wakeup);
extern time_t prune_cache (struct database_dyn *table, time_t now, int fd);
/* pwdcache.c */
@@ -271,7 +299,8 @@ extern void readdservbyport (struct database_dyn *db, struct hashentry *he,
struct datahead *dh);
/* mem.c */
-extern void *mempool_alloc (struct database_dyn *db, size_t len);
+extern void *mempool_alloc (struct database_dyn *db, size_t len,
+ enum in_flight idx);
extern void gc (struct database_dyn *db);
diff --git a/libc/nscd/nscd_getserv_r.c b/libc/nscd/nscd_getserv_r.c
index 3cd5a2429..b1ad7e2e4 100644
--- a/libc/nscd/nscd_getserv_r.c
+++ b/libc/nscd/nscd_getserv_r.c
@@ -53,7 +53,7 @@ __nscd_getservbyport_r (int port, const char *proto,
portstr[sizeof (portstr) - 1] = '\0';
char *cp = _itoa_word (port, portstr + sizeof (portstr) - 1, 10, 0);
- return nscd_getserv_r (portstr, portstr + sizeof (portstr) - cp, proto,
+ return nscd_getserv_r (cp, portstr + sizeof (portstr) - cp, proto,
GETSERVBYPORT, result_buf, buf, buflen, result);
}
diff --git a/libc/nscd/nscd_helper.c b/libc/nscd/nscd_helper.c
index 9828a46df..7db5d0984 100644
--- a/libc/nscd/nscd_helper.c
+++ b/libc/nscd/nscd_helper.c
@@ -33,6 +33,7 @@
#include <sys/un.h>
#include <not-cancel.h>
#include <nis/rpcsvc/nis.h>
+#include <kernel-features.h>
#include "nscd-client.h"
@@ -161,7 +162,26 @@ __readvall (int fd, const struct iovec *iov, int iovcnt)
static int
open_socket (request_type type, const char *key, size_t keylen)
{
- int sock = __socket (PF_UNIX, SOCK_STREAM, 0);
+ int sock;
+
+#ifdef SOCK_CLOEXEC
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec >= 0)
+# endif
+ {
+ sock = __socket (PF_UNIX, SOCK_STREAM | SOCK_CLOEXEC | SOCK_NONBLOCK, 0);
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec == 0)
+ __have_sock_cloexec = sock != -1 || errno != EINVAL ? 1 : -1;
+# endif
+ }
+#endif
+#ifndef __ASSUME_SOCK_CLOEXEC
+# ifdef SOCK_CLOEXEC
+ if (__have_sock_cloexec < 0)
+# endif
+ sock = __socket (PF_UNIX, SOCK_STREAM, 0);
+#endif
if (sock < 0)
return -1;
@@ -172,8 +192,13 @@ open_socket (request_type type, const char *key, size_t keylen)
} reqdata;
size_t real_sizeof_reqdata = sizeof (request_header) + keylen;
- /* Make socket non-blocking. */
- __fcntl (sock, F_SETFL, O_RDWR | O_NONBLOCK);
+#ifndef __ASSUME_SOCK_CLOEXEC
+# ifdef SOCK_NONBLOCK
+ if (__have_sock_cloexec < 0)
+# endif
+ /* Make socket non-blocking. */
+ __fcntl (sock, F_SETFL, O_RDWR | O_NONBLOCK);
+#endif
struct sockaddr_un sun;
sun.sun_family = AF_UNIX;
diff --git a/libc/nscd/pwdcache.c b/libc/nscd/pwdcache.c
index bc1b6bab2..782b10137 100644
--- a/libc/nscd/pwdcache.c
+++ b/libc/nscd/pwdcache.c
@@ -1,5 +1,5 @@
/* Cache handling for passwd lookup.
- Copyright (C) 1998-2005, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1998-2005, 2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
@@ -120,7 +120,8 @@ cache_addpw (struct database_dyn *db, int fd, request_header *req,
written = TEMP_FAILURE_RETRY (send (fd, &notfound, total,
MSG_NOSIGNAL));
- dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len);
+ dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len,
+ IDX_result_data);
/* If we cannot permanently store the result, so be it. */
if (dataset != NULL)
{
@@ -152,11 +153,8 @@ cache_addpw (struct database_dyn *db, int fd, request_header *req,
/* Now get the lock to safely insert the records. */
pthread_rwlock_rdlock (&db->lock);
- if (cache_add (req->type, key_copy, req->key_len,
- &dataset->head, true, db, owner) < 0)
- /* Ensure the data can be recovered. */
- dataset->head.usable = false;
-
+ (void) cache_add (req->type, key_copy, req->key_len,
+ &dataset->head, true, db, owner, he == NULL);
pthread_rwlock_unlock (&db->lock);
@@ -187,7 +185,8 @@ cache_addpw (struct database_dyn *db, int fd, request_header *req,
n = snprintf (buf, buf_len, "%d%c%n%s", pwd->pw_uid, '\0',
&key_offset, (char *) key) + 1;
- written = total = (sizeof (struct dataset) + pw_name_len + pw_passwd_len
+ written = total = (offsetof (struct dataset, strdata)
+ + pw_name_len + pw_passwd_len
+ pw_gecos_len + pw_dir_len + pw_shell_len);
/* If we refill the cache, first assume the reconrd did not
@@ -199,7 +198,8 @@ cache_addpw (struct database_dyn *db, int fd, request_header *req,
if (he == NULL)
{
- dataset = (struct dataset *) mempool_alloc (db, total + n);
+ dataset = (struct dataset *) mempool_alloc (db, total + n,
+ IDX_result_data);
if (dataset == NULL)
++db->head->addfailed;
}
@@ -248,16 +248,28 @@ cache_addpw (struct database_dyn *db, int fd, request_header *req,
char *key_copy = cp + key_offset;
assert (key_copy == (char *) rawmemchr (cp, '\0') + 1);
+ assert (cp == dataset->strdata + total - offsetof (struct dataset,
+ strdata));
+
/* Now we can determine whether on refill we have to create a new
record or not. */
if (he != NULL)
{
assert (fd == -1);
- if (total + n == dh->allocsize
- && total - offsetof (struct dataset, resp) == dh->recsize
+#if 0
+ if (dataset->head.datasize == dh->allocsize
+ && dataset->head.recsize == dh->recsize
&& memcmp (&dataset->resp, dh->data,
dh->allocsize - offsetof (struct dataset, resp)) == 0)
+#else
+ if (dataset->head.allocsize != dh->allocsize)
+ goto nnn;
+ if (dataset->head.recsize != dh->recsize)
+ goto nnn;
+ if(memcmp (&dataset->resp, dh->data,
+ dh->allocsize - offsetof (struct dataset, resp)) == 0)
+#endif
{
/* The data has not changed. We will just bump the
timeout value. Note that the new record has been
@@ -267,10 +279,12 @@ cache_addpw (struct database_dyn *db, int fd, request_header *req,
}
else
{
+ nnn:;
/* We have to create a new record. Just allocate
appropriate memory and copy it. */
struct dataset *newp
- = (struct dataset *) mempool_alloc (db, total + n);
+ = (struct dataset *) mempool_alloc (db, total + n,
+ IDX_result_data);
if (newp != NULL)
{
/* Adjust pointer into the memory block. */
@@ -348,13 +362,8 @@ cache_addpw (struct database_dyn *db, int fd, request_header *req,
if (req->type == GETPWBYUID)
{
if (cache_add (GETPWBYUID, cp, key_offset, &dataset->head, true,
- db, owner) < 0)
- {
- /* Could not allocate memory. Make sure the data gets
- discarded. */
- dataset->head.usable = false;
- goto out;
- }
+ db, owner, he == NULL) < 0)
+ goto out;
first = false;
}
@@ -362,13 +371,8 @@ cache_addpw (struct database_dyn *db, int fd, request_header *req,
else if (strcmp (key_copy, dataset->strdata) != 0)
{
if (cache_add (GETPWBYNAME, key_copy, key_len + 1,
- &dataset->head, true, db, owner) < 0)
- {
- /* Could not allocate memory. Make sure the data gets
- discarded. */
- dataset->head.usable = false;
- goto out;
- }
+ &dataset->head, true, db, owner, he == NULL) < 0)
+ goto out;
first = false;
}
@@ -377,16 +381,13 @@ cache_addpw (struct database_dyn *db, int fd, request_header *req,
if ((req->type == GETPWBYNAME || db->propagate)
&& __builtin_expect (cache_add (GETPWBYNAME, dataset->strdata,
pw_name_len, &dataset->head,
- first, db, owner) == 0, 1))
+ first, db, owner, he == NULL)
+ == 0, 1))
{
if (req->type == GETPWBYNAME && db->propagate)
(void) cache_add (GETPWBYUID, cp, key_offset, &dataset->head,
- req->type != GETPWBYNAME, db, owner);
+ false, db, owner, false);
}
- else if (first)
- /* Could not allocate memory. Make sure the data gets
- discarded. */
- dataset->head.usable = false;
out:
pthread_rwlock_unlock (&db->lock);
diff --git a/libc/nscd/servicescache.c b/libc/nscd/servicescache.c
index e122cb3f1..44f12a3c6 100644
--- a/libc/nscd/servicescache.c
+++ b/libc/nscd/servicescache.c
@@ -1,5 +1,5 @@
/* Cache handling for services lookup.
- Copyright (C) 2007 Free Software Foundation, Inc.
+ Copyright (C) 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@drepper.com>, 2007.
@@ -103,7 +103,8 @@ cache_addserv (struct database_dyn *db, int fd, request_header *req,
written = TEMP_FAILURE_RETRY (send (fd, &notfound, total,
MSG_NOSIGNAL));
- dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len);
+ dataset = mempool_alloc (db, sizeof (struct dataset) + req->key_len,
+ IDX_result_data);
/* If we cannot permanently store the result, so be it. */
if (dataset != NULL)
{
@@ -135,10 +136,8 @@ cache_addserv (struct database_dyn *db, int fd, request_header *req,
/* Now get the lock to safely insert the records. */
pthread_rwlock_rdlock (&db->lock);
- if (cache_add (req->type, &dataset->strdata, req->key_len,
- &dataset->head, true, db, owner) < 0)
- /* Ensure the data can be recovered. */
- dataset->head.usable = false;
+ (void) cache_add (req->type, &dataset->strdata, req->key_len,
+ &dataset->head, true, db, owner, he == NULL);
pthread_rwlock_unlock (&db->lock);
@@ -174,7 +173,7 @@ cache_addserv (struct database_dyn *db, int fd, request_header *req,
total += s_aliases_len[cnt];
}
- total += (sizeof (struct dataset)
+ total += (offsetof (struct dataset, strdata)
+ s_name_len
+ s_proto_len
+ s_aliases_cnt * sizeof (uint32_t));
@@ -190,7 +189,8 @@ cache_addserv (struct database_dyn *db, int fd, request_header *req,
if (he == NULL)
{
dataset = (struct dataset *) mempool_alloc (db,
- total + req->key_len);
+ total + req->key_len,
+ IDX_result_data);
if (dataset == NULL)
++db->head->addfailed;
}
@@ -261,7 +261,8 @@ cache_addserv (struct database_dyn *db, int fd, request_header *req,
/* We have to create a new record. Just allocate
appropriate memory and copy it. */
struct dataset *newp
- = (struct dataset *) mempool_alloc (db, total + req->key_len);
+ = (struct dataset *) mempool_alloc (db, total + req->key_len,
+ IDX_result_data);
if (newp != NULL)
{
/* Adjust pointers into the memory block. */
@@ -329,11 +330,8 @@ cache_addserv (struct database_dyn *db, int fd, request_header *req,
/* Now get the lock to safely insert the records. */
pthread_rwlock_rdlock (&db->lock);
- if (cache_add (req->type, key_copy, req->key_len,
- &dataset->head, true, db, owner) < 0)
- /* Could not allocate memory. Make sure the
- data gets discarded. */
- dataset->head.usable = false;
+ (void) cache_add (req->type, key_copy, req->key_len,
+ &dataset->head, true, db, owner, he == NULL);
pthread_rwlock_unlock (&db->lock);
}
diff --git a/libc/nss/Versions b/libc/nss/Versions
index 8f2f0fb37..f7f0e5697 100644
--- a/libc/nss/Versions
+++ b/libc/nss/Versions
@@ -38,6 +38,7 @@ libnss_files {
_nss_files_endhostent;
_nss_files_gethostbyaddr_r;
_nss_files_gethostbyname2_r;
+ _nss_files_gethostbyname4_r;
_nss_files_gethostbyname_r;
_nss_files_gethostent_r;
_nss_files_gethostton_r;
diff --git a/libc/nss/getent.c b/libc/nss/getent.c
index 420095945..1ca445b7c 100644
--- a/libc/nss/getent.c
+++ b/libc/nss/getent.c
@@ -343,6 +343,22 @@ ahosts_keys_int (int af, int xflags, int number, char *key[])
sockstr = "DGRAM";
else if (runp->ai_socktype == SOCK_RAW)
sockstr = "RAW";
+#ifdef SOCK_SEQPACKET
+ else if (runp->ai_socktype == SOCK_SEQPACKET)
+ sockstr = "SEQPACKET";
+#endif
+#ifdef SOCK_RDM
+ else if (runp->ai_socktype == SOCK_RDM)
+ sockstr = "RDM";
+#endif
+#ifdef SOCK_DCCP
+ else if (runp->ai_socktype == SOCK_DCCP)
+ sockstr = "DCCP";
+#endif
+#ifdef SOCK_PACKET
+ else if (runp->ai_socktype == SOCK_PACKET)
+ sockstr = "PACKET";
+#endif
else
{
snprintf (sockbuf, sizeof (sockbuf), "%d",
diff --git a/libc/nss/nss.h b/libc/nss/nss.h
index f5c12afab..611b2580a 100644
--- a/libc/nss/nss.h
+++ b/libc/nss/nss.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996, 1997, 1999 Free Software Foundation, Inc.
+/* Copyright (C) 1996, 1997, 1999, 2008 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
@@ -23,6 +23,7 @@
#define _NSS_H 1
#include <features.h>
+#include <stdint.h>
__BEGIN_DECLS
@@ -38,6 +39,17 @@ enum nss_status
};
+/* Data structure used for the 'gethostbyname4_r' function. */
+struct gaih_addrtuple
+ {
+ struct gaih_addrtuple *next;
+ char *name;
+ int family;
+ uint32_t addr[4];
+ uint32_t scopeid;
+ };
+
+
/* Overwrite service selection for database DBNAME using specification
in STRING.
This function should only be used by system programs which have to
diff --git a/libc/nss/nss_files/files-XXX.c b/libc/nss/nss_files/files-XXX.c
index 426007e1a..852b58a7e 100644
--- a/libc/nss/nss_files/files-XXX.c
+++ b/libc/nss/nss_files/files-XXX.c
@@ -259,7 +259,7 @@ CONCAT(_nss_files_get,ENTNAME_r) (struct STRUCTURE *result, char *buffer,
status = internal_setent (0);
- __set_errno (errno);
+ __set_errno (save_errno);
if (status == NSS_STATUS_SUCCESS && fgetpos (stream, &position) < 0)
{
diff --git a/libc/nss/nss_files/files-hosts.c b/libc/nss/nss_files/files-hosts.c
index b06467225..7b69d47fc 100644
--- a/libc/nss/nss_files/files-hosts.c
+++ b/libc/nss/nss_files/files-hosts.c
@@ -1,6 +1,5 @@
/* Hosts file parser in nss_files module.
- Copyright (C) 1996-2001, 2003, 2004, 2006, 2007
- Free Software Foundation, Inc.
+ Copyright (C) 1996-2001, 2003-2007, 2008 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
@@ -56,7 +55,10 @@ LINE_PARSER
STRING_FIELD (addr, isspace, 1);
/* Parse address. */
- if (inet_pton (af, addr, entdata->host_addr) <= 0)
+ if (inet_pton (af == AF_UNSPEC ? AF_INET : af, addr, entdata->host_addr)
+ > 0)
+ af = af == AF_UNSPEC ? AF_INET : af;
+ else
{
if (af == AF_INET6 && (flags & AI_V4MAPPED) != 0
&& inet_pton (AF_INET, addr, entdata->host_addr) > 0)
@@ -76,6 +78,9 @@ LINE_PARSER
/* Illegal address: ignore line. */
return 0;
}
+ else if (af == AF_UNSPEC
+ && inet_pton (AF_INET6, addr, entdata->host_addr) > 0)
+ af = AF_INET6;
else
/* Illegal address: ignore line. */
return 0;
@@ -101,8 +106,6 @@ _nss_files_get##name##_r (proto, \
struct STRUCTURE *result, char *buffer, \
size_t buflen, int *errnop H_ERRNO_PROTO) \
{ \
- enum nss_status status; \
- \
uintptr_t pad = -(uintptr_t) buffer % __alignof__ (struct hostent_data); \
buffer += pad; \
buflen = buflen > pad ? buflen - pad : 0; \
@@ -110,7 +113,7 @@ _nss_files_get##name##_r (proto, \
__libc_lock_lock (lock); \
\
/* Reset file pointer to beginning or open file. */ \
- status = internal_setent (keep_stream); \
+ enum nss_status status = internal_setent (keep_stream); \
\
if (status == NSS_STATUS_SUCCESS) \
{ \
@@ -288,9 +291,9 @@ HOST_DB_LOOKUP (hostbyname, ,,
{
LOOKUP_NAME_CASE (h_name, h_aliases)
}, const char *name)
+#undef EXTRA_ARGS_VALUE
-#undef EXTRA_ARGS_VALUE
/* XXX Is using _res to determine whether we want to convert IPv4 addresses
to IPv6 addresses really the right thing to do? */
#define EXTRA_ARGS_VALUE \
@@ -299,8 +302,9 @@ HOST_DB_LOOKUP (hostbyname2, ,,
{
LOOKUP_NAME_CASE (h_name, h_aliases)
}, const char *name, int af)
-
#undef EXTRA_ARGS_VALUE
+
+
/* We only need to consider IPv4 mapped addresses if the input to the
gethostbyaddr() function is an IPv6 address. */
#define EXTRA_ARGS_VALUE \
@@ -311,3 +315,116 @@ DB_LOOKUP (hostbyaddr, ,,
&& ! memcmp (addr, result->h_addr_list[0], len))
break;
}, const void *addr, socklen_t len, int af)
+#undef EXTRA_ARGS_VALUE
+
+
+enum nss_status
+_nss_files_gethostbyname4_r (const char *name, struct gaih_addrtuple **pat,
+ char *buffer, size_t buflen, int *errnop,
+ int *herrnop, int32_t *ttlp)
+{
+ __libc_lock_lock (lock);
+
+ /* Reset file pointer to beginning or open file. */
+ enum nss_status status = internal_setent (keep_stream);
+
+ if (status == NSS_STATUS_SUCCESS)
+ {
+ /* Tell getent function that we have repositioned the file pointer. */
+ last_use = getby;
+
+ bool any = false;
+ bool got_canon = false;
+ while (1)
+ {
+ /* Align the buffer for the next record. */
+ uintptr_t pad = (-(uintptr_t) buffer
+ % __alignof__ (struct hostent_data));
+ buffer += pad;
+ buflen = buflen > pad ? buflen - pad : 0;
+
+ struct hostent result;
+ status = internal_getent (&result, buffer, buflen, errnop
+ H_ERRNO_ARG, AF_UNSPEC, 0);
+ if (status != NSS_STATUS_SUCCESS)
+ break;
+
+ int naliases = 0;
+ if (__strcasecmp (name, result.h_name) != 0)
+ {
+ for (; result.h_aliases[naliases] != NULL; ++naliases)
+ if (! __strcasecmp (name, result.h_aliases[naliases]))
+ break;
+ if (result.h_aliases[naliases] == NULL)
+ continue;
+
+ /* We know this alias exist. Count it. */
+ ++naliases;
+ }
+
+ /* Determine how much memory has been used so far. */
+ // XXX It is not necessary to preserve the aliases array
+ while (result.h_aliases[naliases] != NULL)
+ ++naliases;
+ char *bufferend = (char *) &result.h_aliases[naliases + 1];
+ assert (buflen >= bufferend - buffer);
+ buflen -= bufferend - buffer;
+ buffer = bufferend;
+
+ /* We found something. */
+ any = true;
+
+ /* Create the record the caller expects. There is only one
+ address. */
+ assert (result.h_addr_list[1] == NULL);
+ if (*pat == NULL)
+ {
+ uintptr_t pad = (-(uintptr_t) buffer
+ % __alignof__ (struct gaih_addrtuple));
+ buffer += pad;
+ buflen = buflen > pad ? buflen - pad : 0;
+
+ if (__builtin_expect (buflen < sizeof (struct gaih_addrtuple),
+ 0))
+ {
+ *errnop = ERANGE;
+ *herrnop = NETDB_INTERNAL;
+ status = NSS_STATUS_TRYAGAIN;
+ break;
+ }
+
+ *pat = (struct gaih_addrtuple *) buffer;
+ buffer += sizeof (struct gaih_addrtuple);
+ buflen -= sizeof (struct gaih_addrtuple);
+ }
+
+ (*pat)->next = NULL;
+ (*pat)->name = got_canon ? NULL : result.h_name;
+ got_canon = true;
+ (*pat)->family = result.h_addrtype;
+ memcpy ((*pat)->addr, result.h_addr_list[0], result.h_length);
+ (*pat)->scopeid = 0;
+
+ pat = &((*pat)->next);
+
+ /* If we only look for the first matching entry we are done. */
+ if ((_res_hconf.flags & HCONF_FLAG_MULTI) == 0)
+ break;
+ }
+
+ /* If we have to look for multiple records and found one, this
+ is a success. */
+ if (status == NSS_STATUS_NOTFOUND && any)
+ {
+ assert ((_res_hconf.flags & HCONF_FLAG_MULTI) != 0);
+ status = NSS_STATUS_SUCCESS;
+ }
+
+ if (! keep_stream)
+ internal_endent ();
+ }
+
+ __libc_lock_unlock (lock);
+
+ return status;
+}
diff --git a/libc/po/libc.pot b/libc/po/libc.pot
index 2919793be..a4ae24fd1 100644
--- a/libc/po/libc.pot
+++ b/libc/po/libc.pot
@@ -5,8 +5,8 @@
#, fuzzy
msgid ""
msgstr ""
-"Project-Id-Version: libc 2.6.90\n"
-"POT-Creation-Date: 2007-10-15 21:18-0700\n"
+"Project-Id-Version: libc 2.7.90\n"
+"POT-Creation-Date: 2008-04-09 08:07-0700\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -129,7 +129,7 @@ msgid ""
"[OUTPUT-FILE [INPUT-FILE]...]"
msgstr ""
-#: catgets/gencat.c:232 debug/pcprofiledump.c:204 iconv/iconv_prog.c:411
+#: catgets/gencat.c:232 debug/pcprofiledump.c:204 iconv/iconv_prog.c:408
#: iconv/iconvconfig.c:380 locale/programs/localedef.c:371
#: login/programs/pt_chown.c:88 malloc/memusagestat.c:526 nss/makedb.c:231
msgid ""
@@ -138,7 +138,7 @@ msgid ""
msgstr ""
#: catgets/gencat.c:246 debug/xtrace.sh:64 elf/ldconfig.c:296
-#: elf/ldd.bash.in:39 elf/sprof.c:355 iconv/iconv_prog.c:426
+#: elf/ldd.bash.in:39 elf/sprof.c:355 iconv/iconv_prog.c:423
#: iconv/iconvconfig.c:395 locale/programs/locale.c:275
#: locale/programs/localedef.c:387 login/programs/pt_chown.c:59
#: malloc/memusage.sh:71 nscd/nscd.c:406 nss/getent.c:83 nss/makedb.c:245
@@ -151,7 +151,7 @@ msgid ""
msgstr ""
#: catgets/gencat.c:251 debug/xtrace.sh:68 elf/ldconfig.c:301 elf/sprof.c:361
-#: iconv/iconv_prog.c:431 iconv/iconvconfig.c:400 locale/programs/locale.c:280
+#: iconv/iconv_prog.c:428 iconv/iconvconfig.c:400 locale/programs/locale.c:280
#: locale/programs/localedef.c:392 malloc/memusage.sh:75 nscd/nscd.c:411
#: nss/getent.c:88 nss/makedb.c:250 posix/getconf.c:1017
#, c-format
@@ -162,7 +162,7 @@ msgstr ""
msgid "*standard input*"
msgstr ""
-#: catgets/gencat.c:288 iconv/iconv_charmap.c:158 iconv/iconv_prog.c:298
+#: catgets/gencat.c:288 iconv/iconv_charmap.c:170 iconv/iconv_prog.c:294
#: nss/makedb.c:170
#, c-format
msgid "cannot open input file `%s'"
@@ -351,7 +351,7 @@ msgstr ""
msgid ", OS ABI: %s %d.%d.%d"
msgstr ""
-#: elf/cache.c:134 elf/ldconfig.c:1270
+#: elf/cache.c:134 elf/ldconfig.c:1269
#, c-format
msgid "Can't open cache file %s\n"
msgstr ""
@@ -395,7 +395,7 @@ msgstr ""
msgid "cannot create scope list"
msgstr ""
-#: elf/dl-close.c:724
+#: elf/dl-close.c:725
msgid "shared object not open"
msgstr ""
@@ -626,29 +626,29 @@ msgstr ""
msgid "invalid target namespace in dlmopen()"
msgstr ""
-#: elf/dl-reloc.c:54
+#: elf/dl-reloc.c:56
msgid "cannot allocate memory in static TLS block"
msgstr ""
-#: elf/dl-reloc.c:196
+#: elf/dl-reloc.c:198
msgid "cannot make segment writable for relocation"
msgstr ""
-#: elf/dl-reloc.c:277
+#: elf/dl-reloc.c:281
#, c-format
msgid "%s: no PLTREL found in object %s\n"
msgstr ""
-#: elf/dl-reloc.c:288
+#: elf/dl-reloc.c:292
#, c-format
msgid "%s: out of memory to store relocation results for %s\n"
msgstr ""
-#: elf/dl-reloc.c:304
+#: elf/dl-reloc.c:308
msgid "cannot restore segment prot after reloc"
msgstr ""
-#: elf/dl-reloc.c:329
+#: elf/dl-reloc.c:333
msgid "cannot apply additional memory protection after relocation"
msgstr ""
@@ -656,11 +656,11 @@ msgstr ""
msgid "RTLD_NEXT used in code not dynamically loaded"
msgstr ""
-#: elf/dl-sysdep.c:469 elf/dl-sysdep.c:481
+#: elf/dl-sysdep.c:475 elf/dl-sysdep.c:487
msgid "cannot create capability list"
msgstr ""
-#: elf/dl-tls.c:825
+#: elf/dl-tls.c:848
msgid "cannot create TLS data structures"
msgstr ""
@@ -873,17 +873,17 @@ msgstr ""
msgid "%s:%u: cannot read directory %s"
msgstr ""
-#: elf/ldconfig.c:1223
+#: elf/ldconfig.c:1222
#, c-format
msgid "relative path `%s' used to build cache"
msgstr ""
-#: elf/ldconfig.c:1249
+#: elf/ldconfig.c:1248
#, c-format
msgid "Can't chdir to /"
msgstr ""
-#: elf/ldconfig.c:1291
+#: elf/ldconfig.c:1290
#, c-format
msgid "Can't open cache file directory %s\n"
msgstr ""
@@ -1120,28 +1120,33 @@ msgstr ""
msgid "cannot allocate symbol data"
msgstr ""
-#: iconv/iconv_charmap.c:176 iconv/iconv_prog.c:316
+#: iconv/iconv_charmap.c:142 iconv/iconv_prog.c:446
+#, c-format
+msgid "cannot open output file"
+msgstr ""
+
+#: iconv/iconv_charmap.c:188 iconv/iconv_prog.c:312
#, c-format
msgid "error while closing input `%s'"
msgstr ""
-#: iconv/iconv_charmap.c:450
+#: iconv/iconv_charmap.c:462
#, c-format
msgid "illegal input sequence at position %Zd"
msgstr ""
-#: iconv/iconv_charmap.c:469 iconv/iconv_prog.c:526
+#: iconv/iconv_charmap.c:481 iconv/iconv_prog.c:537
#, c-format
msgid "incomplete character or shift sequence at end of buffer"
msgstr ""
-#: iconv/iconv_charmap.c:514 iconv/iconv_charmap.c:550 iconv/iconv_prog.c:569
-#: iconv/iconv_prog.c:605
+#: iconv/iconv_charmap.c:526 iconv/iconv_charmap.c:562 iconv/iconv_prog.c:580
+#: iconv/iconv_prog.c:616
#, c-format
msgid "error while reading the input"
msgstr ""
-#: iconv/iconv_charmap.c:532 iconv/iconv_prog.c:587
+#: iconv/iconv_charmap.c:544 iconv/iconv_prog.c:598
#, c-format
msgid "unable to allocate buffer for input"
msgstr ""
@@ -1194,62 +1199,57 @@ msgstr ""
msgid "[FILE...]"
msgstr ""
-#: iconv/iconv_prog.c:200
-#, c-format
-msgid "cannot open output file"
-msgstr ""
-
-#: iconv/iconv_prog.c:242
+#: iconv/iconv_prog.c:234
#, c-format
msgid "conversions from `%s' and to `%s' are not supported"
msgstr ""
-#: iconv/iconv_prog.c:247
+#: iconv/iconv_prog.c:239
#, c-format
msgid "conversion from `%s' is not supported"
msgstr ""
-#: iconv/iconv_prog.c:254
+#: iconv/iconv_prog.c:246
#, c-format
msgid "conversion to `%s' is not supported"
msgstr ""
-#: iconv/iconv_prog.c:258
+#: iconv/iconv_prog.c:250
#, c-format
msgid "conversion from `%s' to `%s' is not supported"
msgstr ""
-#: iconv/iconv_prog.c:268
+#: iconv/iconv_prog.c:260
#, c-format
msgid "failed to start conversion processing"
msgstr ""
-#: iconv/iconv_prog.c:362
+#: iconv/iconv_prog.c:358
#, c-format
msgid "error while closing output file"
msgstr ""
-#: iconv/iconv_prog.c:471 iconv/iconv_prog.c:497
+#: iconv/iconv_prog.c:456
#, c-format
msgid "conversion stopped due to problem in writing the output"
msgstr ""
-#: iconv/iconv_prog.c:522
+#: iconv/iconv_prog.c:533
#, c-format
msgid "illegal input sequence at position %ld"
msgstr ""
-#: iconv/iconv_prog.c:530
+#: iconv/iconv_prog.c:541
#, c-format
msgid "internal error (illegal descriptor)"
msgstr ""
-#: iconv/iconv_prog.c:533
+#: iconv/iconv_prog.c:544
#, c-format
msgid "unknown iconv() error %d"
msgstr ""
-#: iconv/iconv_prog.c:779
+#: iconv/iconv_prog.c:790
msgid ""
"The following list contain all the coded character sets known. This does\n"
"not necessarily mean that all combinations of these names can be used for\n"
@@ -1483,7 +1483,7 @@ msgid "no symbolic name given for end of range"
msgstr ""
#: locale/programs/charmap.c:610 locale/programs/ld-address.c:600
-#: locale/programs/ld-collate.c:2767 locale/programs/ld-collate.c:3924
+#: locale/programs/ld-collate.c:2767 locale/programs/ld-collate.c:3928
#: locale/programs/ld-ctype.c:2232 locale/programs/ld-ctype.c:2984
#: locale/programs/ld-identification.c:452
#: locale/programs/ld-measurement.c:238 locale/programs/ld-messages.c:332
@@ -1510,7 +1510,7 @@ msgid "%s: error in state machine"
msgstr ""
#: locale/programs/charmap.c:850 locale/programs/ld-address.c:616
-#: locale/programs/ld-collate.c:2764 locale/programs/ld-collate.c:4115
+#: locale/programs/ld-collate.c:2764 locale/programs/ld-collate.c:4121
#: locale/programs/ld-ctype.c:2229 locale/programs/ld-ctype.c:3001
#: locale/programs/ld-identification.c:468
#: locale/programs/ld-measurement.c:254 locale/programs/ld-messages.c:348
@@ -1534,7 +1534,7 @@ msgid ""
"same: %d vs %d"
msgstr ""
-#: locale/programs/charmap.c:993 locale/programs/ld-collate.c:3047
+#: locale/programs/charmap.c:993 locale/programs/ld-collate.c:3045
#: locale/programs/repertoire.c:419
msgid "invalid names for character range"
msgstr ""
@@ -1643,7 +1643,7 @@ msgstr ""
msgid "%s: unknown character in field `%s'"
msgstr ""
-#: locale/programs/ld-address.c:597 locale/programs/ld-collate.c:3922
+#: locale/programs/ld-address.c:597 locale/programs/ld-collate.c:3926
#: locale/programs/ld-ctype.c:2981 locale/programs/ld-identification.c:449
#: locale/programs/ld-measurement.c:235 locale/programs/ld-messages.c:330
#: locale/programs/ld-monetary.c:941 locale/programs/ld-name.c:305
@@ -1656,7 +1656,7 @@ msgstr ""
#: locale/programs/ld-address.c:607 locale/programs/ld-collate.c:542
#: locale/programs/ld-collate.c:594 locale/programs/ld-collate.c:890
#: locale/programs/ld-collate.c:903 locale/programs/ld-collate.c:2733
-#: locale/programs/ld-collate.c:2754 locale/programs/ld-collate.c:4105
+#: locale/programs/ld-collate.c:2754 locale/programs/ld-collate.c:4111
#: locale/programs/ld-ctype.c:1960 locale/programs/ld-ctype.c:2219
#: locale/programs/ld-ctype.c:2806 locale/programs/ld-ctype.c:2992
#: locale/programs/ld-identification.c:459
@@ -1763,7 +1763,7 @@ msgstr ""
msgid "`%s' and `%.*s' are not valid names for symbolic range"
msgstr ""
-#: locale/programs/ld-collate.c:1369 locale/programs/ld-collate.c:3858
+#: locale/programs/ld-collate.c:1369 locale/programs/ld-collate.c:3862
#, c-format
msgid "%s: order for `%.*s' already defined at %s:%Zu"
msgstr ""
@@ -1804,7 +1804,7 @@ msgstr ""
msgid "too many errors; giving up"
msgstr ""
-#: locale/programs/ld-collate.c:2659 locale/programs/ld-collate.c:4044
+#: locale/programs/ld-collate.c:2659 locale/programs/ld-collate.c:4050
#, c-format
msgid "%s: nested conditionals not supported"
msgstr ""
@@ -1824,112 +1824,112 @@ msgstr ""
msgid "%s: duplicate declaration of section `%s'"
msgstr ""
-#: locale/programs/ld-collate.c:3027
+#: locale/programs/ld-collate.c:3025
#, c-format
msgid "%s: unknown character in collating symbol name"
msgstr ""
-#: locale/programs/ld-collate.c:3159
+#: locale/programs/ld-collate.c:3155
#, c-format
msgid "%s: unknown character in equivalent definition name"
msgstr ""
-#: locale/programs/ld-collate.c:3172
+#: locale/programs/ld-collate.c:3168
#, c-format
msgid "%s: unknown character in equivalent definition value"
msgstr ""
-#: locale/programs/ld-collate.c:3182
+#: locale/programs/ld-collate.c:3178
#, c-format
msgid "%s: unknown symbol `%s' in equivalent definition"
msgstr ""
-#: locale/programs/ld-collate.c:3191
+#: locale/programs/ld-collate.c:3187
msgid "error while adding equivalent collating symbol"
msgstr ""
-#: locale/programs/ld-collate.c:3221
+#: locale/programs/ld-collate.c:3225
#, c-format
msgid "duplicate definition of script `%s'"
msgstr ""
-#: locale/programs/ld-collate.c:3269
+#: locale/programs/ld-collate.c:3273
#, c-format
msgid "%s: unknown section name `%.*s'"
msgstr ""
-#: locale/programs/ld-collate.c:3298
+#: locale/programs/ld-collate.c:3302
#, c-format
msgid "%s: multiple order definitions for section `%s'"
msgstr ""
-#: locale/programs/ld-collate.c:3326
+#: locale/programs/ld-collate.c:3330
#, c-format
msgid "%s: invalid number of sorting rules"
msgstr ""
-#: locale/programs/ld-collate.c:3353
+#: locale/programs/ld-collate.c:3357
#, c-format
msgid "%s: multiple order definitions for unnamed section"
msgstr ""
-#: locale/programs/ld-collate.c:3407 locale/programs/ld-collate.c:3537
-#: locale/programs/ld-collate.c:3900
+#: locale/programs/ld-collate.c:3411 locale/programs/ld-collate.c:3541
+#: locale/programs/ld-collate.c:3904
#, c-format
msgid "%s: missing `order_end' keyword"
msgstr ""
-#: locale/programs/ld-collate.c:3470
+#: locale/programs/ld-collate.c:3474
#, c-format
msgid "%s: order for collating symbol %.*s not yet defined"
msgstr ""
-#: locale/programs/ld-collate.c:3488
+#: locale/programs/ld-collate.c:3492
#, c-format
msgid "%s: order for collating element %.*s not yet defined"
msgstr ""
-#: locale/programs/ld-collate.c:3499
+#: locale/programs/ld-collate.c:3503
#, c-format
msgid "%s: cannot reorder after %.*s: symbol not known"
msgstr ""
-#: locale/programs/ld-collate.c:3551 locale/programs/ld-collate.c:3912
+#: locale/programs/ld-collate.c:3555 locale/programs/ld-collate.c:3916
#, c-format
msgid "%s: missing `reorder-end' keyword"
msgstr ""
-#: locale/programs/ld-collate.c:3585 locale/programs/ld-collate.c:3783
+#: locale/programs/ld-collate.c:3589 locale/programs/ld-collate.c:3787
#, c-format
msgid "%s: section `%.*s' not known"
msgstr ""
-#: locale/programs/ld-collate.c:3650
+#: locale/programs/ld-collate.c:3654
#, c-format
msgid "%s: bad symbol <%.*s>"
msgstr ""
-#: locale/programs/ld-collate.c:3846
+#: locale/programs/ld-collate.c:3850
#, c-format
msgid "%s: cannot have `%s' as end of ellipsis range"
msgstr ""
-#: locale/programs/ld-collate.c:3896
+#: locale/programs/ld-collate.c:3900
#, c-format
msgid "%s: empty category description not allowed"
msgstr ""
-#: locale/programs/ld-collate.c:3915
+#: locale/programs/ld-collate.c:3919
#, c-format
msgid "%s: missing `reorder-sections-end' keyword"
msgstr ""
-#: locale/programs/ld-collate.c:4077
+#: locale/programs/ld-collate.c:4083
#, c-format
msgid "%s: '%s' without matching 'ifdef' or 'ifndef'"
msgstr ""
-#: locale/programs/ld-collate.c:4095
+#: locale/programs/ld-collate.c:4101
#, c-format
msgid "%s: 'endif' without matching 'ifdef' or 'ifndef'"
msgstr ""
@@ -2260,7 +2260,7 @@ msgstr ""
msgid "%s: starting date is invalid in string %Zd in `era' field"
msgstr ""
-#: locale/programs/ld-time.c:407
+#: locale/programs/ld-time.c:407 locale/programs/ld-time.c:435
#, c-format
msgid "%s: invalid stopping date in string %Zd in `era' field"
msgstr ""
@@ -2270,11 +2270,6 @@ msgstr ""
msgid "%s: garbage at end of stopping date in string %Zd in `era' field"
msgstr ""
-#: locale/programs/ld-time.c:435
-#, c-format
-msgid "%s: stopping date is invalid in string %Zd in `era' field"
-msgstr ""
-
#: locale/programs/ld-time.c:444
#, c-format
msgid "%s: missing era name in string %Zd in `era' field"
@@ -2686,7 +2681,7 @@ msgid "cannot create output file `%s' for category `%s'"
msgstr ""
#: locale/programs/locfile.c:782
-msgid "expect string argument for `copy'"
+msgid "expecting string argument for `copy'"
msgstr ""
#: locale/programs/locfile.c:786
@@ -3503,251 +3498,265 @@ msgstr ""
msgid "yp_update: cannot get server address\n"
msgstr ""
-#: nscd/aicache.c:77 nscd/hstcache.c:468
+#: nscd/aicache.c:77 nscd/hstcache.c:473
#, c-format
msgid "Haven't found \"%s\" in hosts cache!"
msgstr ""
-#: nscd/aicache.c:79 nscd/hstcache.c:470
+#: nscd/aicache.c:79 nscd/hstcache.c:475
#, c-format
msgid "Reloading \"%s\" in hosts cache!"
msgstr ""
-#: nscd/cache.c:146
+#: nscd/cache.c:150
#, c-format
msgid "add new entry \"%s\" of type %s for %s to cache%s"
msgstr ""
-#: nscd/cache.c:148
+#: nscd/cache.c:152
msgid " (first)"
msgstr ""
-#: nscd/cache.c:256 nscd/connections.c:810
+#: nscd/cache.c:263 nscd/connections.c:811
#, c-format
msgid "cannot stat() file `%s': %s"
msgstr ""
-#: nscd/cache.c:285
+#: nscd/cache.c:305
#, c-format
msgid "pruning %s cache; time %ld"
msgstr ""
-#: nscd/cache.c:312
+#: nscd/cache.c:334
#, c-format
msgid "considering %s entry \"%s\", timeout %<PRIu64>"
msgstr ""
-#: nscd/connections.c:521 nscd/connections.c:533 nscd/connections.c:545
-#: nscd/connections.c:564
+#: nscd/connections.c:527
#, c-format
msgid "invalid persistent database file \"%s\": %s"
msgstr ""
#: nscd/connections.c:535
+msgid "uninitialized header"
+msgstr ""
+
+#: nscd/connections.c:540
msgid "header size does not match"
msgstr ""
-#: nscd/connections.c:547
+#: nscd/connections.c:550
msgid "file size does not match"
msgstr ""
-#: nscd/connections.c:566
+#: nscd/connections.c:567
msgid "verification failed"
msgstr ""
-#: nscd/connections.c:580
+#: nscd/connections.c:581
#, c-format
msgid ""
"suggested size of table for database %s larger than the persistent "
"database's table"
msgstr ""
-#: nscd/connections.c:591 nscd/connections.c:673
+#: nscd/connections.c:592 nscd/connections.c:674
#, c-format
msgid "cannot create read-only descriptor for \"%s\"; no mmap"
msgstr ""
-#: nscd/connections.c:652
+#: nscd/connections.c:653
#, c-format
msgid ""
"database for %s corrupted or simultaneously used; remove %s manually if "
"necessary and restart"
msgstr ""
-#: nscd/connections.c:659
+#: nscd/connections.c:660
#, c-format
msgid "cannot create %s; no persistent database used"
msgstr ""
-#: nscd/connections.c:662
+#: nscd/connections.c:663
#, c-format
msgid "cannot create %s; no sharing possible"
msgstr ""
-#: nscd/connections.c:733
+#: nscd/connections.c:734
#, c-format
msgid "cannot write to database file %s: %s"
msgstr ""
-#: nscd/connections.c:772
+#: nscd/connections.c:773
#, c-format
msgid "cannot set socket to close on exec: %s; disabling paranoia mode"
msgstr ""
-#: nscd/connections.c:823
+#: nscd/connections.c:824
#, c-format
msgid "cannot open socket: %s"
msgstr ""
-#: nscd/connections.c:840
+#: nscd/connections.c:841
#, c-format
msgid "cannot change socket to nonblocking mode: %s"
msgstr ""
-#: nscd/connections.c:848
+#: nscd/connections.c:849
#, c-format
msgid "cannot set socket to close on exec: %s"
msgstr ""
-#: nscd/connections.c:859
+#: nscd/connections.c:860
#, c-format
msgid "cannot enable socket to accept connections: %s"
msgstr ""
-#: nscd/connections.c:955
+#: nscd/connections.c:960
#, c-format
msgid "provide access to FD %d, for %s"
msgstr ""
-#: nscd/connections.c:967
+#: nscd/connections.c:972
#, c-format
msgid "cannot handle old request version %d; current version is %d"
msgstr ""
-#: nscd/connections.c:1009 nscd/connections.c:1062
+#: nscd/connections.c:982
+msgid "request not handled due to missing permission"
+msgstr ""
+
+#: nscd/connections.c:1018 nscd/connections.c:1071
#, c-format
msgid "cannot write result: %s"
msgstr ""
-#: nscd/connections.c:1145
+#: nscd/connections.c:1154
#, c-format
msgid "error getting caller's id: %s"
msgstr ""
-#: nscd/connections.c:1204
+#: nscd/connections.c:1213
#, c-format
msgid "cannot open /proc/self/cmdline: %s; disabling paranoia mode"
msgstr ""
-#: nscd/connections.c:1218
+#: nscd/connections.c:1227
#, c-format
msgid "cannot read /proc/self/cmdline: %s; disabling paranoia mode"
msgstr ""
-#: nscd/connections.c:1258
+#: nscd/connections.c:1267
#, c-format
msgid "cannot change to old UID: %s; disabling paranoia mode"
msgstr ""
-#: nscd/connections.c:1268
+#: nscd/connections.c:1277
#, c-format
msgid "cannot change to old GID: %s; disabling paranoia mode"
msgstr ""
-#: nscd/connections.c:1281
+#: nscd/connections.c:1290
#, c-format
msgid "cannot change to old working directory: %s; disabling paranoia mode"
msgstr ""
-#: nscd/connections.c:1310
+#: nscd/connections.c:1319
#, c-format
msgid "re-exec failed: %s; disabling paranoia mode"
msgstr ""
-#: nscd/connections.c:1319
+#: nscd/connections.c:1328
#, c-format
msgid "cannot change current working directory to \"/\": %s"
msgstr ""
-#: nscd/connections.c:1437
+#: nscd/connections.c:1471
#, c-format
msgid "short read while reading request: %s"
msgstr ""
-#: nscd/connections.c:1468
+#: nscd/connections.c:1502
#, c-format
msgid "key length in request too long: %d"
msgstr ""
-#: nscd/connections.c:1481
+#: nscd/connections.c:1515
#, c-format
msgid "short read while reading request key: %s"
msgstr ""
-#: nscd/connections.c:1490
+#: nscd/connections.c:1524
#, c-format
msgid "handle_request: request received (Version = %d) from PID %ld"
msgstr ""
-#: nscd/connections.c:1495
+#: nscd/connections.c:1529
#, c-format
msgid "handle_request: request received (Version = %d)"
msgstr ""
-#: nscd/connections.c:1856
-#, c-format
-msgid "could only start %d threads; terminating"
+#: nscd/connections.c:1866
+msgid "could not initialize conditional variable"
msgstr ""
-#: nscd/connections.c:1904 nscd/connections.c:1905 nscd/connections.c:1922
-#: nscd/connections.c:1931 nscd/connections.c:1949 nscd/connections.c:1960
-#: nscd/connections.c:1971
+#: nscd/connections.c:1874
+msgid "could not start clean-up thread; terminating"
+msgstr ""
+
+#: nscd/connections.c:1888
+msgid "could not start any worker thread; terminating"
+msgstr ""
+
+#: nscd/connections.c:1939 nscd/connections.c:1940 nscd/connections.c:1957
+#: nscd/connections.c:1966 nscd/connections.c:1984 nscd/connections.c:1995
+#: nscd/connections.c:2006
#, c-format
msgid "Failed to run nscd as user '%s'"
msgstr ""
-#: nscd/connections.c:1923
+#: nscd/connections.c:1958
#, c-format
msgid "initial getgrouplist failed"
msgstr ""
-#: nscd/connections.c:1932
+#: nscd/connections.c:1967
#, c-format
msgid "getgrouplist failed"
msgstr ""
-#: nscd/connections.c:1950
+#: nscd/connections.c:1985
#, c-format
msgid "setgroups failed"
msgstr ""
-#: nscd/grpcache.c:402 nscd/hstcache.c:418 nscd/initgrcache.c:412
-#: nscd/pwdcache.c:397 nscd/servicescache.c:343
+#: nscd/grpcache.c:404 nscd/hstcache.c:422 nscd/initgrcache.c:414
+#: nscd/pwdcache.c:399 nscd/servicescache.c:345
#, c-format
msgid "short write in %s: %s"
msgstr ""
-#: nscd/grpcache.c:445 nscd/initgrcache.c:78
+#: nscd/grpcache.c:447 nscd/initgrcache.c:78
#, c-format
msgid "Haven't found \"%s\" in group cache!"
msgstr ""
-#: nscd/grpcache.c:447 nscd/initgrcache.c:80
+#: nscd/grpcache.c:449 nscd/initgrcache.c:80
#, c-format
msgid "Reloading \"%s\" in group cache!"
msgstr ""
-#: nscd/grpcache.c:524
+#: nscd/grpcache.c:526
#, c-format
msgid "Invalid numeric gid \"%s\"!"
msgstr ""
-#: nscd/mem.c:383
+#: nscd/mem.c:422
#, c-format
msgid "freed %zu bytes in %s cache"
msgstr ""
-#: nscd/mem.c:512
+#: nscd/mem.c:557
#, c-format
msgid "no more memory for database '%s'"
msgstr ""
@@ -3773,7 +3782,7 @@ msgid "Shut the server down"
msgstr ""
#: nscd/nscd.c:103
-msgid "Print current configuration statistic"
+msgid "Print current configuration statistics"
msgstr ""
#: nscd/nscd.c:104
@@ -3860,37 +3869,37 @@ msgstr ""
msgid "Parse error: %s"
msgstr ""
-#: nscd/nscd_conf.c:193
+#: nscd/nscd_conf.c:194
#, c-format
msgid "Must specify user name for server-user option"
msgstr ""
-#: nscd/nscd_conf.c:200
+#: nscd/nscd_conf.c:201
#, c-format
msgid "Must specify user name for stat-user option"
msgstr ""
-#: nscd/nscd_conf.c:244
+#: nscd/nscd_conf.c:245
#, c-format
msgid "invalid value for 'reload-count': %u"
msgstr ""
-#: nscd/nscd_conf.c:259
+#: nscd/nscd_conf.c:260
#, c-format
msgid "Must specify value for restart-interval option"
msgstr ""
-#: nscd/nscd_conf.c:273
+#: nscd/nscd_conf.c:274
#, c-format
msgid "Unknown option: %s %s %s"
msgstr ""
-#: nscd/nscd_conf.c:286
+#: nscd/nscd_conf.c:287
#, c-format
msgid "cannot get current working directory: %s; disabling paranoia mode"
msgstr ""
-#: nscd/nscd_conf.c:306
+#: nscd/nscd_conf.c:307
#, c-format
msgid "maximum file size for %s database too small"
msgstr ""
@@ -3989,17 +3998,17 @@ msgid ""
"%15s check /etc/%s for changes\n"
msgstr ""
-#: nscd/pwdcache.c:440
+#: nscd/pwdcache.c:442
#, c-format
msgid "Haven't found \"%s\" in password cache!"
msgstr ""
-#: nscd/pwdcache.c:442
+#: nscd/pwdcache.c:444
#, c-format
msgid "Reloading \"%s\" in password cache!"
msgstr ""
-#: nscd/pwdcache.c:520
+#: nscd/pwdcache.c:522
#, c-format
msgid "Invalid numeric uid \"%s\"!"
msgstr ""
@@ -4075,7 +4084,11 @@ msgstr ""
msgid "Error getting sid from context"
msgstr ""
-#: nscd/selinux.c:399
+#: nscd/selinux.c:374
+msgid "compile-time support for database policy missing"
+msgstr ""
+
+#: nscd/selinux.c:407
#, c-format
msgid ""
"\n"
@@ -4091,12 +4104,12 @@ msgid ""
"%15u CAV misses\n"
msgstr ""
-#: nscd/servicescache.c:390
+#: nscd/servicescache.c:392
#, c-format
msgid "Haven't found \"%s\" in services cache!"
msgstr ""
-#: nscd/servicescache.c:392
+#: nscd/servicescache.c:394
#, c-format
msgid "Reloading \"%s\" in services cache!"
msgstr ""
@@ -4220,61 +4233,56 @@ msgstr ""
msgid "Unrecognized variable `%s'"
msgstr ""
-#: posix/getopt.c:571 posix/getopt.c:587
-#, c-format
-msgid "%s: option `%s' is ambiguous\n"
-msgstr ""
-
-#: posix/getopt.c:620 posix/getopt.c:624
+#: posix/getopt.c:570 posix/getopt.c:586
#, c-format
-msgid "%s: option `--%s' doesn't allow an argument\n"
+msgid "%s: option '%s' is ambiguous\n"
msgstr ""
-#: posix/getopt.c:633 posix/getopt.c:638
+#: posix/getopt.c:619 posix/getopt.c:623
#, c-format
-msgid "%s: option `%c%s' doesn't allow an argument\n"
+msgid "%s: option '--%s' doesn't allow an argument\n"
msgstr ""
-#: posix/getopt.c:681 posix/getopt.c:700 posix/getopt.c:1016
-#: posix/getopt.c:1035
+#: posix/getopt.c:632 posix/getopt.c:637
#, c-format
-msgid "%s: option `%s' requires an argument\n"
+msgid "%s: option '%c%s' doesn't allow an argument\n"
msgstr ""
-#: posix/getopt.c:738 posix/getopt.c:741
+#: posix/getopt.c:680 posix/getopt.c:699 posix/getopt.c:1002
+#: posix/getopt.c:1021
#, c-format
-msgid "%s: unrecognized option `--%s'\n"
+msgid "%s: option '%s' requires an argument\n"
msgstr ""
-#: posix/getopt.c:749 posix/getopt.c:752
+#: posix/getopt.c:737 posix/getopt.c:740
#, c-format
-msgid "%s: unrecognized option `%c%s'\n"
+msgid "%s: unrecognized option '--%s'\n"
msgstr ""
-#: posix/getopt.c:804 posix/getopt.c:807
+#: posix/getopt.c:748 posix/getopt.c:751
#, c-format
-msgid "%s: illegal option -- %c\n"
+msgid "%s: unrecognized option '%c%s'\n"
msgstr ""
-#: posix/getopt.c:813 posix/getopt.c:816
+#: posix/getopt.c:800 posix/getopt.c:803
#, c-format
-msgid "%s: invalid option -- %c\n"
+msgid "%s: invalid option -- '%c'\n"
msgstr ""
-#: posix/getopt.c:868 posix/getopt.c:884 posix/getopt.c:1088
-#: posix/getopt.c:1106
+#: posix/getopt.c:853 posix/getopt.c:870 posix/getopt.c:1073
+#: posix/getopt.c:1091
#, c-format
-msgid "%s: option requires an argument -- %c\n"
+msgid "%s: option requires an argument -- '%c'\n"
msgstr ""
-#: posix/getopt.c:937 posix/getopt.c:953
+#: posix/getopt.c:923 posix/getopt.c:939
#, c-format
-msgid "%s: option `-W %s' is ambiguous\n"
+msgid "%s: option '-W %s' is ambiguous\n"
msgstr ""
-#: posix/getopt.c:977 posix/getopt.c:995
+#: posix/getopt.c:963 posix/getopt.c:981
#, c-format
-msgid "%s: option `-W %s' doesn't allow an argument\n"
+msgid "%s: option '-W %s' doesn't allow an argument\n"
msgstr ""
#: posix/regcomp.c:135
@@ -4429,133 +4437,138 @@ msgstr ""
msgid "Unknown signal %d"
msgstr ""
-#: sunrpc/auth_unix.c:114
-msgid "authunix_create: out of memory\n"
+#: sunrpc/auth_unix.c:114 sunrpc/clnt_tcp.c:131 sunrpc/clnt_udp.c:140
+#: sunrpc/clnt_unix.c:128 sunrpc/svc_tcp.c:179 sunrpc/svc_tcp.c:218
+#: sunrpc/svc_udp.c:153 sunrpc/svc_unix.c:176 sunrpc/svc_unix.c:215
+#: sunrpc/xdr.c:566 sunrpc/xdr.c:718 sunrpc/xdr_array.c:106
+#: sunrpc/xdr_rec.c:156 sunrpc/xdr_ref.c:85
+msgid "out of memory\n"
msgstr ""
#: sunrpc/auth_unix.c:350
msgid "auth_unix.c: Fatal marshalling problem"
msgstr ""
-#: sunrpc/clnt_perr.c:118 sunrpc/clnt_perr.c:139
+#: sunrpc/clnt_perr.c:105 sunrpc/clnt_perr.c:121
#, c-format
-msgid "; low version = %lu, high version = %lu"
+msgid "%s: %s; low version = %lu, high version = %lu"
msgstr ""
-#: sunrpc/clnt_perr.c:125
-msgid "; why = "
+#: sunrpc/clnt_perr.c:112
+#, c-format
+msgid "%s: %s; why = %s\n"
msgstr ""
-#: sunrpc/clnt_perr.c:132
+#: sunrpc/clnt_perr.c:114
#, c-format
-msgid "(unknown authentication error - %d)"
+msgid "%s: %s; why = (unknown authentication error - %d)\n"
msgstr ""
-#: sunrpc/clnt_perr.c:172
+#: sunrpc/clnt_perr.c:159
msgid "RPC: Success"
msgstr ""
-#: sunrpc/clnt_perr.c:175
+#: sunrpc/clnt_perr.c:162
msgid "RPC: Can't encode arguments"
msgstr ""
-#: sunrpc/clnt_perr.c:179
+#: sunrpc/clnt_perr.c:166
msgid "RPC: Can't decode result"
msgstr ""
-#: sunrpc/clnt_perr.c:183
+#: sunrpc/clnt_perr.c:170
msgid "RPC: Unable to send"
msgstr ""
-#: sunrpc/clnt_perr.c:187
+#: sunrpc/clnt_perr.c:174
msgid "RPC: Unable to receive"
msgstr ""
-#: sunrpc/clnt_perr.c:191
+#: sunrpc/clnt_perr.c:178
msgid "RPC: Timed out"
msgstr ""
-#: sunrpc/clnt_perr.c:195
+#: sunrpc/clnt_perr.c:182
msgid "RPC: Incompatible versions of RPC"
msgstr ""
-#: sunrpc/clnt_perr.c:199
+#: sunrpc/clnt_perr.c:186
msgid "RPC: Authentication error"
msgstr ""
-#: sunrpc/clnt_perr.c:203
+#: sunrpc/clnt_perr.c:190
msgid "RPC: Program unavailable"
msgstr ""
-#: sunrpc/clnt_perr.c:207
+#: sunrpc/clnt_perr.c:194
msgid "RPC: Program/version mismatch"
msgstr ""
-#: sunrpc/clnt_perr.c:211
+#: sunrpc/clnt_perr.c:198
msgid "RPC: Procedure unavailable"
msgstr ""
-#: sunrpc/clnt_perr.c:215
+#: sunrpc/clnt_perr.c:202
msgid "RPC: Server can't decode arguments"
msgstr ""
-#: sunrpc/clnt_perr.c:219
+#: sunrpc/clnt_perr.c:206
msgid "RPC: Remote system error"
msgstr ""
-#: sunrpc/clnt_perr.c:223
+#: sunrpc/clnt_perr.c:210
msgid "RPC: Unknown host"
msgstr ""
-#: sunrpc/clnt_perr.c:227
+#: sunrpc/clnt_perr.c:214
msgid "RPC: Unknown protocol"
msgstr ""
-#: sunrpc/clnt_perr.c:231
+#: sunrpc/clnt_perr.c:218
msgid "RPC: Port mapper failure"
msgstr ""
-#: sunrpc/clnt_perr.c:235
+#: sunrpc/clnt_perr.c:222
msgid "RPC: Program not registered"
msgstr ""
-#: sunrpc/clnt_perr.c:239
+#: sunrpc/clnt_perr.c:226
msgid "RPC: Failed (unspecified error)"
msgstr ""
-#: sunrpc/clnt_perr.c:280
+#: sunrpc/clnt_perr.c:267
msgid "RPC: (unknown error code)"
msgstr ""
-#: sunrpc/clnt_perr.c:342
+#: sunrpc/clnt_perr.c:330
msgid "Authentication OK"
msgstr ""
-#: sunrpc/clnt_perr.c:345
+#: sunrpc/clnt_perr.c:333
msgid "Invalid client credential"
msgstr ""
-#: sunrpc/clnt_perr.c:349
+#: sunrpc/clnt_perr.c:337
msgid "Server rejected credential"
msgstr ""
-#: sunrpc/clnt_perr.c:353
+#: sunrpc/clnt_perr.c:341
msgid "Invalid client verifier"
msgstr ""
-#: sunrpc/clnt_perr.c:357
+#: sunrpc/clnt_perr.c:345
msgid "Server rejected verifier"
msgstr ""
-#: sunrpc/clnt_perr.c:361
+#: sunrpc/clnt_perr.c:349
msgid "Client credential too weak"
msgstr ""
-#: sunrpc/clnt_perr.c:365
+#: sunrpc/clnt_perr.c:353
msgid "Invalid server verifier"
msgstr ""
-#: sunrpc/clnt_perr.c:369
+#: sunrpc/clnt_perr.c:357
msgid "Failed (unspecified error)"
msgstr ""
@@ -4563,18 +4576,6 @@ msgstr ""
msgid "clnt_raw.c: fatal header serialization error"
msgstr ""
-#: sunrpc/clnt_tcp.c:131
-msgid "clnttcp_create: out of memory\n"
-msgstr ""
-
-#: sunrpc/clnt_udp.c:139
-msgid "clntudp_create: out of memory\n"
-msgstr ""
-
-#: sunrpc/clnt_unix.c:128
-msgid "clntunix_create: out of memory\n"
-msgstr ""
-
#: sunrpc/pm_getmaps.c:83
msgid "pmap_getmaps.c: rpc problem"
msgstr ""
@@ -4859,14 +4860,6 @@ msgstr ""
msgid "svc_tcp.c - cannot getsockname or listen"
msgstr ""
-#: sunrpc/svc_tcp.c:179
-msgid "svctcp_create: out of memory\n"
-msgstr ""
-
-#: sunrpc/svc_tcp.c:218
-msgid "svc_tcp: makefd_xprt: out of memory\n"
-msgstr ""
-
#: sunrpc/svc_udp.c:128
msgid "svcudp_create: socket creation problem"
msgstr ""
@@ -4875,39 +4868,35 @@ msgstr ""
msgid "svcudp_create - cannot getsockname"
msgstr ""
-#: sunrpc/svc_udp.c:152
-msgid "svcudp_create: out of memory\n"
-msgstr ""
-
-#: sunrpc/svc_udp.c:174
+#: sunrpc/svc_udp.c:175
msgid "svcudp_create: xp_pad is too small for IP_PKTINFO\n"
msgstr ""
-#: sunrpc/svc_udp.c:474
+#: sunrpc/svc_udp.c:475
msgid "enablecache: cache already enabled"
msgstr ""
-#: sunrpc/svc_udp.c:480
+#: sunrpc/svc_udp.c:481
msgid "enablecache: could not allocate cache"
msgstr ""
-#: sunrpc/svc_udp.c:489
+#: sunrpc/svc_udp.c:490
msgid "enablecache: could not allocate cache data"
msgstr ""
-#: sunrpc/svc_udp.c:497
+#: sunrpc/svc_udp.c:498
msgid "enablecache: could not allocate cache fifo"
msgstr ""
-#: sunrpc/svc_udp.c:532
+#: sunrpc/svc_udp.c:533
msgid "cache_set: victim not found"
msgstr ""
-#: sunrpc/svc_udp.c:543
+#: sunrpc/svc_udp.c:544
msgid "cache_set: victim alloc failed"
msgstr ""
-#: sunrpc/svc_udp.c:550
+#: sunrpc/svc_udp.c:551
msgid "cache_set: could not allocate new rpc_buffer"
msgstr ""
@@ -4919,34 +4908,6 @@ msgstr ""
msgid "svc_unix.c - cannot getsockname or listen"
msgstr ""
-#: sunrpc/svc_unix.c:176
-msgid "svcunix_create: out of memory\n"
-msgstr ""
-
-#: sunrpc/svc_unix.c:215
-msgid "svc_unix: makefd_xprt: out of memory\n"
-msgstr ""
-
-#: sunrpc/xdr.c:566
-msgid "xdr_bytes: out of memory\n"
-msgstr ""
-
-#: sunrpc/xdr.c:718
-msgid "xdr_string: out of memory\n"
-msgstr ""
-
-#: sunrpc/xdr_array.c:106
-msgid "xdr_array: out of memory\n"
-msgstr ""
-
-#: sunrpc/xdr_rec.c:156
-msgid "xdrrec_create: out of memory\n"
-msgstr ""
-
-#: sunrpc/xdr_ref.c:86
-msgid "xdr_reference: out of memory\n"
-msgstr ""
-
#: sysdeps/generic/siglist.h:29 sysdeps/unix/siglist.c:27
msgid "Hangup"
msgstr ""
diff --git a/libc/po/lt.po b/libc/po/lt.po
new file mode 100644
index 000000000..3556ba06c
--- /dev/null
+++ b/libc/po/lt.po
@@ -0,0 +1,7082 @@
+# translation of libc-2.7 to Lithuanian
+# Copyright (C) 2008 Free Software Foundation, Inc.
+# This file is distributed under the same license as the glibc package.
+#
+# Gintautas Miliauskas <gintas@akl.lt>, 2008.
+msgid ""
+msgstr ""
+"Project-Id-Version: libc-2.7\n"
+"POT-Creation-Date: 2007-10-15 21:18-0700\n"
+"PO-Revision-Date: 2008-05-14 01:35+0300\n"
+"Last-Translator: Gintautas Miliauskas <gintas@akl.lt>\n"
+"Language-Team: Lithuanian <komp_lt@konferencijos.lt>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Generator: KBabel 1.11.4\n"
+"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
+
+#: argp/argp-help.c:228
+#, c-format
+msgid "%.*s: ARGP_HELP_FMT parameter requires a value"
+msgstr "%.*s: ARGP_HELP_FMT parametrui rekia reikšmės"
+
+#: argp/argp-help.c:238
+#, c-format
+msgid "%.*s: Unknown ARGP_HELP_FMT parameter"
+msgstr "%.*s: Nežinomas ARGP_HELP_FMT parametras"
+
+#: argp/argp-help.c:251
+#, c-format
+msgid "Garbage in ARGP_HELP_FMT: %s"
+msgstr "Šiukšlės ARGP_HELP_FMT: %s"
+
+#: argp/argp-help.c:1215
+msgid "Mandatory or optional arguments to long options are also mandatory or optional for any corresponding short options."
+msgstr "Būtini ar nebūtini argumentai ilgiems parametrams atitinkamai būtini ar nebūtini trumpoms jų formoms."
+
+#: argp/argp-help.c:1601
+msgid "Usage:"
+msgstr "Naudojimas:"
+
+#: argp/argp-help.c:1605
+msgid " or: "
+msgstr " arba: "
+
+#: argp/argp-help.c:1617
+msgid " [OPTION...]"
+msgstr "[PARAMETRAS...]"
+
+#: argp/argp-help.c:1644
+#, fuzzy, c-format
+msgid "Try `%s --help' or `%s --usage' for more information.\n"
+msgstr "Pabandykite „memusage --help“, jei norite gauti daugiau informacijos."
+
+#: argp/argp-help.c:1672
+#, c-format
+msgid "Report bugs to %s.\n"
+msgstr "Praneškite apie klaidas %s.\n"
+
+#: argp/argp-parse.c:102
+msgid "Give this help list"
+msgstr "Pateikti šį pagalbinį sąrašą"
+
+#: argp/argp-parse.c:103
+msgid "Give a short usage message"
+msgstr "Pateikti trumpą pranešimą apie naudojimą"
+
+#: argp/argp-parse.c:104
+msgid "Set the program name"
+msgstr "Nustatyti programos pavadinimÄ…"
+
+#: argp/argp-parse.c:106
+msgid "Hang for SECS seconds (default 3600)"
+msgstr "Laukti SECS sekundžių (standartiškai 3600)"
+
+#: argp/argp-parse.c:167
+msgid "Print program version"
+msgstr "IÅ¡spausdinti programos versijÄ…"
+
+#: argp/argp-parse.c:183
+msgid "(PROGRAM ERROR) No version known!?"
+msgstr "(PROGRAM ERROR) Nežinoma joka versija!?"
+
+#: argp/argp-parse.c:623
+#, c-format
+msgid "%s: Too many arguments\n"
+msgstr "%s: Per daug argumentų\n"
+
+#: argp/argp-parse.c:766
+#, fuzzy
+msgid "(PROGRAM ERROR) Option should have been recognized!?"
+msgstr "(PROGRAM ERROR) Nežinoma joka versija!?"
+
+#: assert/assert-perr.c:57
+#, c-format
+msgid "%s%s%s:%u: %s%sUnexpected error: %s.\n"
+msgstr "%s%s%s:%u: %s%sNetikÄ—ta klaida: %s.\n"
+
+#: assert/assert.c:57
+#, c-format
+msgid "%s%s%s:%u: %s%sAssertion `%s' failed.\n"
+msgstr "%s%s%s:%u: %s%sPrielaida „%s“ pažeista.\n"
+
+#: catgets/gencat.c:110 catgets/gencat.c:114 nscd/nscd.c:97 nss/makedb.c:61
+msgid "NAME"
+msgstr "PAVADINIMAS"
+
+#: catgets/gencat.c:111
+msgid "Create C header file NAME containing symbol definitions"
+msgstr "Sukurti C antraÅ¡Äių failÄ… duotu PAVADINIMU, kuriame suraÅ¡yti simbolių apibrėžimus"
+
+#: catgets/gencat.c:113
+msgid "Do not use existing catalog, force new output file"
+msgstr "Nenaudoti egzistuojanÄio katalogo, kurti naujÄ… iÅ¡vedimo failÄ…"
+
+#: catgets/gencat.c:114 nss/makedb.c:61
+msgid "Write output to file NAME"
+msgstr "Išvesti į failą duotu PAVADINIMU"
+
+#: catgets/gencat.c:119
+msgid ""
+"Generate message catalog.\vIf INPUT-FILE is -, input is read from standard input. If OUTPUT-FILE\n"
+"is -, output is written to standard output.\n"
+msgstr ""
+
+#: catgets/gencat.c:124
+msgid ""
+"-o OUTPUT-FILE [INPUT-FILE]...\n"
+"[OUTPUT-FILE [INPUT-FILE]...]"
+msgstr ""
+"-o IŠVEDIMO-FAILAS [DUOMENŲ-FAILAS]...\n"
+"[IŠVEDIMO-FAILAS [DUOMENŲ-FAILAS]...]"
+
+#: catgets/gencat.c:232 debug/pcprofiledump.c:204 iconv/iconv_prog.c:411
+#: iconv/iconvconfig.c:380 locale/programs/localedef.c:371
+#: login/programs/pt_chown.c:88 malloc/memusagestat.c:526 nss/makedb.c:231
+msgid ""
+"For bug reporting instructions, please see:\n"
+"<http://www.gnu.org/software/libc/bugs.html>.\n"
+msgstr ""
+
+#: catgets/gencat.c:246 debug/xtrace.sh:64 elf/ldconfig.c:296
+#: elf/ldd.bash.in:39 elf/sprof.c:355 iconv/iconv_prog.c:426
+#: iconv/iconvconfig.c:395 locale/programs/locale.c:275
+#: locale/programs/localedef.c:387 login/programs/pt_chown.c:59
+#: malloc/memusage.sh:71 nscd/nscd.c:406 nss/getent.c:83 nss/makedb.c:245
+#: posix/getconf.c:1012
+#, c-format
+msgid ""
+"Copyright (C) %s Free Software Foundation, Inc.\n"
+"This is free software; see the source for copying conditions. There is NO\n"
+"warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n"
+msgstr ""
+
+#: catgets/gencat.c:251 debug/xtrace.sh:68 elf/ldconfig.c:301 elf/sprof.c:361
+#: iconv/iconv_prog.c:431 iconv/iconvconfig.c:400 locale/programs/locale.c:280
+#: locale/programs/localedef.c:392 malloc/memusage.sh:75 nscd/nscd.c:411
+#: nss/getent.c:88 nss/makedb.c:250 posix/getconf.c:1017
+#, c-format
+msgid "Written by %s.\n"
+msgstr "Parašė %s.\n"
+
+#: catgets/gencat.c:282
+msgid "*standard input*"
+msgstr "*standartinis įvedimas*"
+
+#: catgets/gencat.c:288 iconv/iconv_charmap.c:158 iconv/iconv_prog.c:298
+#: nss/makedb.c:170
+#, fuzzy, c-format
+msgid "cannot open input file `%s'"
+msgstr "%s: nepavyko atverti laikinojo failo: %s"
+
+#: catgets/gencat.c:417 catgets/gencat.c:494
+#, fuzzy
+msgid "illegal set number"
+msgstr "nekorektiška eilutė"
+
+#: catgets/gencat.c:444
+msgid "duplicate set definition"
+msgstr "pakartotinis rinkinio apibrėžimas"
+
+#: catgets/gencat.c:446 catgets/gencat.c:623 catgets/gencat.c:677
+msgid "this is the first definition"
+msgstr "šis apibrėžimas pirmasis"
+
+#: catgets/gencat.c:522
+#, c-format
+msgid "unknown set `%s'"
+msgstr "nežinomas rinkinys „%s“"
+
+#: catgets/gencat.c:563
+#, fuzzy
+msgid "invalid quote character"
+msgstr "netaisyklingas kabuÄių simbolis"
+
+#: catgets/gencat.c:576
+#, c-format
+msgid "unknown directive `%s': line ignored"
+msgstr "nežinoma direktyva „%s“: eilutė ignoruota"
+
+#: catgets/gencat.c:621
+msgid "duplicated message number"
+msgstr "pakartotas pranešimo numeris"
+
+#: catgets/gencat.c:674
+msgid "duplicated message identifier"
+msgstr "pakartotas pranešimo identifikatorius"
+
+#: catgets/gencat.c:731
+#, fuzzy
+msgid "invalid character: message ignored"
+msgstr "netaisyklingas simbolis: pranešimas ignoruotas"
+
+#: catgets/gencat.c:774
+#, fuzzy
+msgid "invalid line"
+msgstr "nekorektiška eilutė"
+
+#: catgets/gencat.c:828
+msgid "malformed line ignored"
+msgstr "nekorektiška eilutė ignoruota"
+
+#: catgets/gencat.c:992 catgets/gencat.c:1033 nss/makedb.c:183
+#, fuzzy, c-format
+msgid "cannot open output file `%s'"
+msgstr "%s: nepavyko atverti laikinojo failo: %s"
+
+#: catgets/gencat.c:1195 locale/programs/linereader.c:560
+#, fuzzy
+msgid "invalid escape sequence"
+msgstr "netaisyklingas naudotojas"
+
+#: catgets/gencat.c:1217
+msgid "unterminated message"
+msgstr "neužbaigtas pranešimas"
+
+#: catgets/gencat.c:1241
+#, fuzzy, c-format
+msgid "while opening old catalog file"
+msgstr "rašant duomenų bazės failą"
+
+#: catgets/gencat.c:1332
+#, fuzzy, c-format
+msgid "conversion modules not available"
+msgstr "RPC programa nerasta"
+
+#: catgets/gencat.c:1358
+#, c-format
+msgid "cannot determine escape character"
+msgstr ""
+
+#: debug/pcprofiledump.c:53
+msgid "Don't buffer output"
+msgstr ""
+
+#: debug/pcprofiledump.c:58
+msgid "Dump information generated by PC profiling."
+msgstr ""
+
+#: debug/pcprofiledump.c:61
+msgid "[FILE]"
+msgstr "[FAILAS]"
+
+#: debug/pcprofiledump.c:104
+#, fuzzy, c-format
+msgid "cannot open input file"
+msgstr "%s: nepavyko atverti laikinojo failo: %s"
+
+#: debug/pcprofiledump.c:111
+#, c-format
+msgid "cannot read header"
+msgstr "nepavyko perskaityti antraštės"
+
+#: debug/pcprofiledump.c:175
+#, fuzzy, c-format
+msgid "invalid pointer size"
+msgstr "netaisyklingas naudotojas"
+
+#: debug/xtrace.sh:27 debug/xtrace.sh:45
+msgid "Usage: xtrace [OPTION]... PROGRAM [PROGRAMOPTION]...\\n"
+msgstr ""
+
+#: debug/xtrace.sh:33
+#, fuzzy
+msgid "Try \\`xtrace --help' for more information.\\n"
+msgstr "Pabandykite „memusage --help“, jei norite gauti daugiau informacijos."
+
+#: debug/xtrace.sh:39
+#, fuzzy
+msgid "xtrace: option \\`$1' requires an argument.\\n"
+msgstr "memusage: parametrui „$1“ reikia argumento"
+
+#: debug/xtrace.sh:46
+msgid ""
+"Trace execution of program by printing currently executed function.\n"
+"\n"
+" --data=FILE Don't run the program, just print the data from FILE.\n"
+"\n"
+" -?,--help Print this help and exit\n"
+" --usage Give a short usage message\n"
+" -V,--version Print version information and exit\n"
+"\n"
+"Mandatory arguments to long options are also mandatory for any corresponding\n"
+"short options.\n"
+"\n"
+"For bug reporting instructions, please see:\n"
+"<http://www.gnu.org/software/libc/bugs.html>.\\n"
+msgstr ""
+
+#: debug/xtrace.sh:125
+#, fuzzy
+msgid "xtrace: unrecognized option \\`$1'\\n"
+msgstr "%s: neatpažintas parametras „--%s“\n"
+
+#: debug/xtrace.sh:138
+msgid "No program name given\\n"
+msgstr "Nenurodytas programos vardas\\n"
+
+#: debug/xtrace.sh:146
+#, sh-format
+msgid "executable \\`$program' not found\\n"
+msgstr ""
+
+#: debug/xtrace.sh:150
+#, sh-format
+msgid "\\`$program' is no executable\\n"
+msgstr ""
+
+#: dlfcn/dlinfo.c:64
+msgid "RTLD_SELF used in code not dynamically loaded"
+msgstr "RTLD_SELF panaudotas ne dinamiškai įkeltame kode"
+
+#: dlfcn/dlinfo.c:73
+msgid "unsupported dlinfo request"
+msgstr "nepalaikoma dlinfo užklausa"
+
+#: dlfcn/dlmopen.c:64
+#, fuzzy
+msgid "invalid namespace"
+msgstr "netaisyklingas kvietÄ—jas"
+
+#: dlfcn/dlmopen.c:69
+msgid "invalid mode"
+msgstr "netaisyklinga veiksena"
+
+#: dlfcn/dlopen.c:64
+#, fuzzy
+msgid "invalid mode parameter"
+msgstr "netaisyklinga veiksena"
+
+#: elf/cache.c:69
+#, fuzzy
+msgid "unknown"
+msgstr "%s: adresas nežinomas"
+
+#: elf/cache.c:112
+msgid "Unknown OS"
+msgstr "Nežinoma OS"
+
+#: elf/cache.c:117
+#, c-format
+msgid ", OS ABI: %s %d.%d.%d"
+msgstr ""
+
+#: elf/cache.c:134 elf/ldconfig.c:1270
+#, c-format
+msgid "Can't open cache file %s\n"
+msgstr "Nepavyko atverti podÄ—lio failo %s\n"
+
+#: elf/cache.c:148
+#, fuzzy, c-format
+msgid "mmap of cache file failed.\n"
+msgstr "Nepavyko atverti podÄ—lio failo %s\n"
+
+#: elf/cache.c:152 elf/cache.c:166
+#, c-format
+msgid "File is not a cache file.\n"
+msgstr "Failas nÄ—ra podÄ—lio failas.\n"
+
+#: elf/cache.c:199 elf/cache.c:209
+#, c-format
+msgid "%d libs found in cache `%s'\n"
+msgstr "Rasta %d bibliotekų podėlyje „%s“\n"
+
+#: elf/cache.c:403
+#, fuzzy, c-format
+msgid "Can't create temporary cache file %s"
+msgstr "Nepavyko atverti podÄ—lio failo %s\n"
+
+#: elf/cache.c:411 elf/cache.c:421 elf/cache.c:425 elf/cache.c:430
+#, c-format
+msgid "Writing of cache data failed"
+msgstr ""
+
+#: elf/cache.c:435
+#, fuzzy, c-format
+msgid "Changing access rights of %s to %#o failed"
+msgstr "%s pervardinimas į %s nesėkmingas"
+
+#: elf/cache.c:440
+#, c-format
+msgid "Renaming of %s to %s failed"
+msgstr "%s pervardinimas į %s nesėkmingas"
+
+#: elf/dl-close.c:378 elf/dl-open.c:460
+#, fuzzy
+msgid "cannot create scope list"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: elf/dl-close.c:724
+msgid "shared object not open"
+msgstr "bendrasis objektas neatvertas"
+
+#: elf/dl-deps.c:114
+msgid "DST not allowed in SUID/SGID programs"
+msgstr "DST neleidžiamas SUID/SGID programose"
+
+#: elf/dl-deps.c:127 elf/dl-open.c:282
+msgid "empty dynamic string token substitution"
+msgstr ""
+
+#: elf/dl-deps.c:133
+#, c-format
+msgid "cannot load auxiliary `%s' because of empty dynamic string token substitution\n"
+msgstr ""
+
+#: elf/dl-deps.c:474
+#, fuzzy
+msgid "cannot allocate dependency list"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: elf/dl-deps.c:510 elf/dl-deps.c:565
+#, fuzzy
+msgid "cannot allocate symbol search list"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: elf/dl-deps.c:550
+msgid "Filters not supported with LD_TRACE_PRELINKING"
+msgstr ""
+
+#: elf/dl-error.c:77
+msgid "DYNAMIC LINKER BUG!!!"
+msgstr ""
+
+#: elf/dl-error.c:124
+msgid "error while loading shared libraries"
+msgstr "klaida įkeliant bendrąsias bibliotekas"
+
+#: elf/dl-fptr.c:88
+msgid "cannot map pages for fdesc table"
+msgstr ""
+
+#: elf/dl-fptr.c:192
+msgid "cannot map pages for fptr table"
+msgstr ""
+
+#: elf/dl-fptr.c:221
+msgid "internal error: symidx out of range of fptr table"
+msgstr ""
+
+#: elf/dl-load.c:372
+#, fuzzy
+msgid "cannot allocate name record"
+msgstr "Nepavyko išskirti atminties"
+
+#: elf/dl-load.c:474 elf/dl-load.c:582 elf/dl-load.c:667 elf/dl-load.c:780
+#, fuzzy
+msgid "cannot create cache for search path"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: elf/dl-load.c:565
+msgid "cannot create RUNPATH/RPATH copy"
+msgstr ""
+
+#: elf/dl-load.c:653
+#, fuzzy
+msgid "cannot create search path array"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: elf/dl-load.c:864
+#, fuzzy
+msgid "cannot stat shared object"
+msgstr "nepavyko atverti bendrojo objekto failo"
+
+#: elf/dl-load.c:934
+#, fuzzy
+msgid "cannot open zero fill device"
+msgstr "nepavyko atverti duomenų failo „%s“"
+
+#: elf/dl-load.c:979 elf/dl-load.c:2224
+#, fuzzy
+msgid "cannot create shared object descriptor"
+msgstr "nepavyko užverti failo deskriptoriaus"
+
+#: elf/dl-load.c:998 elf/dl-load.c:1656 elf/dl-load.c:1748
+msgid "cannot read file data"
+msgstr "nepavyko nuskaityti failo duomenų"
+
+#: elf/dl-load.c:1042
+msgid "ELF load command alignment not page-aligned"
+msgstr ""
+
+#: elf/dl-load.c:1049
+msgid "ELF load command address/offset not properly aligned"
+msgstr ""
+
+#: elf/dl-load.c:1132
+msgid "cannot allocate TLS data structures for initial thread"
+msgstr ""
+
+#: elf/dl-load.c:1155
+msgid "cannot handle TLS data"
+msgstr "nepavyko apdoroti TLS duomenų"
+
+#: elf/dl-load.c:1174
+msgid "object file has no loadable segments"
+msgstr "objektiniame faile nėra įkeliamų segmentų"
+
+#: elf/dl-load.c:1210
+msgid "failed to map segment from shared object"
+msgstr ""
+
+#: elf/dl-load.c:1236
+#, fuzzy
+msgid "cannot dynamically load executable"
+msgstr "\tne dinaminis paleidžiamasis failas"
+
+#: elf/dl-load.c:1298
+#, fuzzy
+msgid "cannot change memory protections"
+msgstr "nepavyko išskirti atminties programos antraštei"
+
+#: elf/dl-load.c:1317
+msgid "cannot map zero-fill pages"
+msgstr ""
+
+#: elf/dl-load.c:1331
+msgid "object file has no dynamic section"
+msgstr "objektiniame faile nÄ—ra dinaminÄ—s sekcijos"
+
+#: elf/dl-load.c:1354
+msgid "shared object cannot be dlopen()ed"
+msgstr "bendrasis objektas negali būti atvertas su dlopen()"
+
+#: elf/dl-load.c:1367
+msgid "cannot allocate memory for program header"
+msgstr "nepavyko išskirti atminties programos antraštei"
+
+#: elf/dl-load.c:1384 elf/dl-open.c:218
+#, fuzzy
+msgid "invalid caller"
+msgstr "netaisyklingas kvietÄ—jas"
+
+#: elf/dl-load.c:1423
+msgid "cannot enable executable stack as shared object requires"
+msgstr ""
+
+#: elf/dl-load.c:1436
+msgid "cannot close file descriptor"
+msgstr "nepavyko užverti failo deskriptoriaus"
+
+#: elf/dl-load.c:1478
+msgid "cannot create searchlist"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: elf/dl-load.c:1656
+msgid "file too short"
+msgstr "failas per trumpas"
+
+#: elf/dl-load.c:1685
+msgid "invalid ELF header"
+msgstr "netaisyklinga ELF antraštė"
+
+#: elf/dl-load.c:1697
+#, fuzzy
+msgid "ELF file data encoding not big-endian"
+msgstr "ELF failo duomenų koduotė ne big-endian"
+
+#: elf/dl-load.c:1699
+#, fuzzy
+msgid "ELF file data encoding not little-endian"
+msgstr "ELF failo duomenų koduotė ne big-endian"
+
+#: elf/dl-load.c:1703
+msgid "ELF file version ident does not match current one"
+msgstr "ELF failo versijos identifikatorius neatitinka esamo"
+
+#: elf/dl-load.c:1707
+msgid "ELF file OS ABI invalid"
+msgstr "ELF failo OS ABI netaisyklingas"
+
+#: elf/dl-load.c:1709
+msgid "ELF file ABI version invalid"
+msgstr "ELF failo ABI versioja netaisyklinga"
+
+#: elf/dl-load.c:1712
+#, fuzzy
+msgid "internal error"
+msgstr "Vardų paieškos vidinė klaida"
+
+#: elf/dl-load.c:1719
+msgid "ELF file version does not match current one"
+msgstr "ELF failo versija neatitinka esamos"
+
+#: elf/dl-load.c:1727
+msgid "only ET_DYN and ET_EXEC can be loaded"
+msgstr ""
+
+#: elf/dl-load.c:1733
+msgid "ELF file's phentsize not the expected size"
+msgstr ""
+
+#: elf/dl-load.c:2240
+msgid "wrong ELF class: ELFCLASS64"
+msgstr "klaidinga ELF klasÄ—: ELFCLASS64"
+
+#: elf/dl-load.c:2241
+msgid "wrong ELF class: ELFCLASS32"
+msgstr "klaidinga ELF klasÄ—: ELFCLASS32"
+
+#: elf/dl-load.c:2244
+#, fuzzy
+msgid "cannot open shared object file"
+msgstr "nepavyko atverti bendrojo objekto failo"
+
+#: elf/dl-lookup.c:356
+msgid "relocation error"
+msgstr "relokacijos klaida"
+
+#: elf/dl-lookup.c:384
+msgid "symbol lookup error"
+msgstr "simbolio paieškos klaida"
+
+#: elf/dl-open.c:114
+msgid "cannot extend global scope"
+msgstr ""
+
+#: elf/dl-open.c:512
+msgid "TLS generation counter wrapped! Please report this."
+msgstr "TLS kartų skaitiklis persivertė! Prašytume apie tai pranešti."
+
+#: elf/dl-open.c:549
+#, fuzzy
+msgid "invalid mode for dlopen()"
+msgstr "netaisyklinga veiksena dlopen()"
+
+#: elf/dl-open.c:566
+msgid "no more namespaces available for dlmopen()"
+msgstr ""
+
+#: elf/dl-open.c:579
+#, fuzzy
+msgid "invalid target namespace in dlmopen()"
+msgstr "netaisyklinga veiksena dlopen()"
+
+#: elf/dl-reloc.c:54
+#, fuzzy
+msgid "cannot allocate memory in static TLS block"
+msgstr "Nepavyko išskirti atminties"
+
+#: elf/dl-reloc.c:196
+msgid "cannot make segment writable for relocation"
+msgstr ""
+
+#: elf/dl-reloc.c:277
+#, c-format
+msgid "%s: no PLTREL found in object %s\n"
+msgstr "%s: objekte %s nerasta PLTREL\n"
+
+#: elf/dl-reloc.c:288
+#, c-format
+msgid "%s: out of memory to store relocation results for %s\n"
+msgstr ""
+
+#: elf/dl-reloc.c:304
+msgid "cannot restore segment prot after reloc"
+msgstr ""
+
+#: elf/dl-reloc.c:329
+msgid "cannot apply additional memory protection after relocation"
+msgstr ""
+
+#: elf/dl-sym.c:162
+#, fuzzy
+msgid "RTLD_NEXT used in code not dynamically loaded"
+msgstr "RTLD_SELF panaudotas ne dinamiškai įkeltame kode"
+
+#: elf/dl-sysdep.c:469 elf/dl-sysdep.c:481
+#, fuzzy
+msgid "cannot create capability list"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: elf/dl-tls.c:825
+#, fuzzy
+msgid "cannot create TLS data structures"
+msgstr "nepavyko apdoroti TLS duomenų"
+
+#: elf/dl-version.c:303
+#, fuzzy
+msgid "cannot allocate version reference table"
+msgstr "nepavyko išskirti atminties programos antraštei"
+
+#: elf/ldconfig.c:138
+msgid "Print cache"
+msgstr "Spausdinti podėlį"
+
+#: elf/ldconfig.c:139
+msgid "Generate verbose messages"
+msgstr "Generuoti išsamius pranešimus"
+
+#: elf/ldconfig.c:140
+msgid "Don't build cache"
+msgstr "Nekurti podÄ—lio"
+
+#: elf/ldconfig.c:141
+msgid "Don't generate links"
+msgstr "Nekurti nuorodų"
+
+#: elf/ldconfig.c:142
+msgid "Change to and use ROOT as root directory"
+msgstr "Naudoti ŠAKNĮ kaip šakninį aplanką"
+
+#: elf/ldconfig.c:142
+msgid "ROOT"
+msgstr "Å AKNIS"
+
+#: elf/ldconfig.c:143
+msgid "CACHE"
+msgstr "PODÄ–LIS"
+
+#: elf/ldconfig.c:143
+msgid "Use CACHE as cache file"
+msgstr "Naudoti PODÄ–LÄ® kaip podÄ—lio failÄ…"
+
+#: elf/ldconfig.c:144
+msgid "CONF"
+msgstr "KONF"
+
+#: elf/ldconfig.c:144
+msgid "Use CONF as configuration file"
+msgstr "Naudoti KONF kaip konfigūracijos failą"
+
+#: elf/ldconfig.c:145
+msgid "Only process directories specified on the command line. Don't build cache."
+msgstr "Apdoroti tik aplankus, nurodytus komandų eilutėje. Nekurti podėlio."
+
+#: elf/ldconfig.c:146
+msgid "Manually link individual libraries."
+msgstr "Rankiniu būdu susaistyti (link) atskiras bibliotekas."
+
+#: elf/ldconfig.c:147
+msgid "FORMAT"
+msgstr "FORMATAS"
+
+#: elf/ldconfig.c:147
+msgid "Format to use: new, old or compat (default)"
+msgstr "Formatas: new (naujas), old (senas) arba compat (numatytasis)"
+
+#: elf/ldconfig.c:148
+msgid "Ignore auxiliary cache file"
+msgstr "Ignoruoti pagalbinį podėlio failą"
+
+#: elf/ldconfig.c:156
+msgid "Configure Dynamic Linker Run Time Bindings."
+msgstr ""
+
+#: elf/ldconfig.c:319
+#, fuzzy, c-format
+msgid "Path `%s' given more than once"
+msgstr "%s: laukas „%s“ apibrėžtas daugiau negu vieną kartą"
+
+#: elf/ldconfig.c:359
+#, c-format
+msgid "%s is not a known library type"
+msgstr "%s nėra žinomas bibliotekos tipas"
+
+#: elf/ldconfig.c:384
+#, fuzzy, c-format
+msgid "Can't stat %s"
+msgstr "Nepavyko rasti %s"
+
+#: elf/ldconfig.c:458
+#, fuzzy, c-format
+msgid "Can't stat %s\n"
+msgstr "Nepavyko susaistyti (link) %s su %s"
+
+#: elf/ldconfig.c:468
+#, fuzzy, c-format
+msgid "%s is not a symbolic link\n"
+msgstr "simbolinÄ— nuoroda"
+
+#: elf/ldconfig.c:487
+#, fuzzy, c-format
+msgid "Can't unlink %s"
+msgstr "Nepavyko rasti %s"
+
+#: elf/ldconfig.c:493
+#, c-format
+msgid "Can't link %s to %s"
+msgstr "Nepavyko susaistyti (link) %s su %s"
+
+#: elf/ldconfig.c:499
+msgid " (changed)\n"
+msgstr " (pakeista)\n"
+
+#: elf/ldconfig.c:501
+msgid " (SKIPPED)\n"
+msgstr " (PRALEISTA)\n"
+
+#: elf/ldconfig.c:556
+#, c-format
+msgid "Can't find %s"
+msgstr "Nepavyko rasti %s"
+
+#: elf/ldconfig.c:572 elf/ldconfig.c:745 elf/ldconfig.c:793 elf/ldconfig.c:827
+#, fuzzy, c-format
+msgid "Cannot lstat %s"
+msgstr "%s: nepavyko perskaityti: %s"
+
+#: elf/ldconfig.c:579
+#, fuzzy, c-format
+msgid "Ignored file %s since it is not a regular file."
+msgstr "ne paprastas failas"
+
+#: elf/ldconfig.c:588
+#, c-format
+msgid "No link created since soname could not be found for %s"
+msgstr ""
+
+#: elf/ldconfig.c:671
+#, c-format
+msgid "Can't open directory %s"
+msgstr "Nepavyko atverti aplanko %s"
+
+#: elf/ldconfig.c:759
+#, fuzzy, c-format
+msgid "Cannot stat %s"
+msgstr "%s: nepavyko perskaityti: %s"
+
+#: elf/ldconfig.c:814 elf/readlib.c:91
+#, fuzzy, c-format
+msgid "Input file %s not found.\n"
+msgstr "Duomenų failas %s nerastas.\n"
+
+#: elf/ldconfig.c:888
+#, c-format
+msgid "libc5 library %s in wrong directory"
+msgstr "libc5 biblioteka %s ne tame aplanke"
+
+#: elf/ldconfig.c:891
+#, c-format
+msgid "libc6 library %s in wrong directory"
+msgstr "libc6 biblioteka %s ne tame aplanke"
+
+#: elf/ldconfig.c:894
+#, c-format
+msgid "libc4 library %s in wrong directory"
+msgstr "libc4 biblioteka %s ne tame aplanke"
+
+#: elf/ldconfig.c:922
+#, c-format
+msgid "libraries %s and %s in directory %s have same soname but different type."
+msgstr ""
+
+#: elf/ldconfig.c:1031
+#, c-format
+msgid "Can't open configuration file %s"
+msgstr "Nepavyko atverti konfigūracijos failo %s"
+
+#: elf/ldconfig.c:1095
+#, c-format
+msgid "%s:%u: bad syntax in hwcap line"
+msgstr "%s:%u: klaidinga sintaksÄ— hwcap eilutÄ—je"
+
+#: elf/ldconfig.c:1101
+#, c-format
+msgid "%s:%u: hwcap index %lu above maximum %u"
+msgstr ""
+
+#: elf/ldconfig.c:1108 elf/ldconfig.c:1116
+#, c-format
+msgid "%s:%u: hwcap index %lu already defined as %s"
+msgstr ""
+
+#: elf/ldconfig.c:1119
+#, c-format
+msgid "%s:%u: duplicate hwcap %lu %s"
+msgstr ""
+
+#: elf/ldconfig.c:1141
+#, c-format
+msgid "need absolute file name for configuration file when using -r"
+msgstr ""
+
+#: elf/ldconfig.c:1148 locale/programs/xmalloc.c:70 malloc/obstack.c:434
+#: malloc/obstack.c:436 posix/getconf.c:985 posix/getconf.c:1163
+#, c-format
+msgid "memory exhausted"
+msgstr "baigÄ—si atmintis"
+
+#: elf/ldconfig.c:1178
+#, fuzzy, c-format
+msgid "%s:%u: cannot read directory %s"
+msgstr "nepavyko atverti aplanko %s"
+
+#: elf/ldconfig.c:1223
+#, c-format
+msgid "relative path `%s' used to build cache"
+msgstr ""
+
+#: elf/ldconfig.c:1249
+#, fuzzy, c-format
+msgid "Can't chdir to /"
+msgstr "Nepavyko susaistyti (link) %s su %s"
+
+#: elf/ldconfig.c:1291
+#, c-format
+msgid "Can't open cache file directory %s\n"
+msgstr "Nepavyko atverti podÄ—lio failo aplanko %s\n"
+
+#: elf/ldd.bash.in:43
+msgid "Written by %s and %s.\n"
+msgstr "Parašė %s ir %s.\n"
+
+#: elf/ldd.bash.in:48
+msgid ""
+"Usage: ldd [OPTION]... FILE...\n"
+" --help print this help and exit\n"
+" --version print version information and exit\n"
+" -d, --data-relocs process data relocations\n"
+" -r, --function-relocs process data and function relocations\n"
+" -u, --unused print unused direct dependencies\n"
+" -v, --verbose print all information\n"
+"For bug reporting instructions, please see:\n"
+"<http://www.gnu.org/software/libc/bugs.html>."
+msgstr ""
+
+#: elf/ldd.bash.in:80
+msgid "ldd: option \\`$1' is ambiguous"
+msgstr "ldd: parametras „$1“ dviprasmis"
+
+#: elf/ldd.bash.in:87
+msgid "unrecognized option"
+msgstr "neatpažintas parametras"
+
+#: elf/ldd.bash.in:88 elf/ldd.bash.in:126
+#, fuzzy
+msgid "Try \\`ldd --help' for more information."
+msgstr "Pabandykite „memusage --help“, jei norite gauti daugiau informacijos."
+
+#: elf/ldd.bash.in:125
+msgid "missing file arguments"
+msgstr "trūksta failo argumento"
+
+#. TRANS No such file or directory. This is a ``file doesn't exist'' error
+#. TRANS for ordinary files that are referenced in contexts where they are
+#. TRANS expected to already exist.
+#: elf/ldd.bash.in:148 sysdeps/gnu/errlist.c:36
+msgid "No such file or directory"
+msgstr "Toks failas ar aplankas neegzistuoja"
+
+#: elf/ldd.bash.in:151 inet/rcmd.c:483
+#, fuzzy
+msgid "not regular file"
+msgstr "paprastas failas"
+
+#: elf/ldd.bash.in:154
+msgid "warning: you do not have execution permission for"
+msgstr "įspėjimas: neturite teisės paleisti"
+
+#: elf/ldd.bash.in:183
+msgid "\tnot a dynamic executable"
+msgstr "\tne dinaminis paleidžiamasis failas"
+
+#: elf/ldd.bash.in:191
+msgid "exited with unknown exit code"
+msgstr "išėjo su nežinomu išėjimo kodu"
+
+#: elf/ldd.bash.in:196
+msgid "error: you do not have read permission for"
+msgstr "klaida: neturite skaitymo teisių"
+
+#: elf/readelflib.c:35
+#, c-format
+msgid "file %s is truncated\n"
+msgstr ""
+
+#: elf/readelflib.c:67
+#, c-format
+msgid "%s is a 32 bit ELF file.\n"
+msgstr "%s yra 32 bitų ELF failas.\n"
+
+#: elf/readelflib.c:69
+#, c-format
+msgid "%s is a 64 bit ELF file.\n"
+msgstr "%s yra 64 bitų ELF failas.\n"
+
+#: elf/readelflib.c:71
+#, c-format
+msgid "Unknown ELFCLASS in file %s.\n"
+msgstr "Netaisyklinga ELFCLASS faile %s.\n"
+
+#: elf/readelflib.c:78
+#, c-format
+msgid "%s is not a shared object file (Type: %d).\n"
+msgstr ""
+
+#: elf/readelflib.c:109
+#, c-format
+msgid "more than one dynamic segment\n"
+msgstr "daugiau negu vienas dinaminis segmentas\n"
+
+#: elf/readlib.c:97
+#, fuzzy, c-format
+msgid "Cannot fstat file %s.\n"
+msgstr "%s: nepavyko atverti laikinojo failo: %s"
+
+#: elf/readlib.c:108
+#, c-format
+msgid "File %s is empty, not checked."
+msgstr "Failas %s tuÅ¡Äias, todÄ—l netikrintas."
+
+#: elf/readlib.c:114
+#, c-format
+msgid "File %s is too small, not checked."
+msgstr "Failas %s per mažas, todėl netikrintas."
+
+#: elf/readlib.c:124
+#, fuzzy, c-format
+msgid "Cannot mmap file %s.\n"
+msgstr "%s: nepavyko atverti laikinojo failo: %s"
+
+#: elf/readlib.c:162
+#, c-format
+msgid "%s is not an ELF file - it has the wrong magic bytes at the start.\n"
+msgstr "%s nėra ELF failas - magiškieji baitai failo pradžioje neteisingi.\n"
+
+#: elf/sprof.c:77
+msgid "Output selection:"
+msgstr ""
+
+#: elf/sprof.c:79
+msgid "print list of count paths and their number of use"
+msgstr ""
+
+#: elf/sprof.c:81
+msgid "generate flat profile with counts and ticks"
+msgstr ""
+
+#: elf/sprof.c:82
+msgid "generate call graph"
+msgstr ""
+
+#: elf/sprof.c:89
+msgid ""
+"Read and display shared object profiling data.\vFor bug reporting instructions, please see:\n"
+"<http://www.gnu.org/software/libc/bugs.html>.\n"
+msgstr ""
+
+#: elf/sprof.c:94
+msgid "SHOBJ [PROFDATA]"
+msgstr ""
+
+#: elf/sprof.c:400
+#, fuzzy, c-format
+msgid "failed to load shared object `%s'"
+msgstr "nepavyko atverti bendrojo objekto failo"
+
+#: elf/sprof.c:409
+#, fuzzy, c-format
+msgid "cannot create internal descriptors"
+msgstr "nepavyko užverti failo deskriptoriaus"
+
+#: elf/sprof.c:528
+#, fuzzy, c-format
+msgid "Reopening shared object `%s' failed"
+msgstr "nepavyko atverti bendrojo objekto failo"
+
+#: elf/sprof.c:535 elf/sprof.c:629
+#, fuzzy, c-format
+msgid "reading of section headers failed"
+msgstr "%s pervardinimas į %s nesėkmingas"
+
+#: elf/sprof.c:543 elf/sprof.c:637
+#, c-format
+msgid "reading of section header string table failed"
+msgstr ""
+
+#: elf/sprof.c:569
+#, c-format
+msgid "*** Cannot read debuginfo file name: %m\n"
+msgstr ""
+
+#: elf/sprof.c:589
+#, fuzzy, c-format
+msgid "cannot determine file name"
+msgstr "nepavyko nuskaityti failo duomenų"
+
+#: elf/sprof.c:622
+#, fuzzy, c-format
+msgid "reading of ELF header failed"
+msgstr "%s pervardinimas į %s nesėkmingas"
+
+#: elf/sprof.c:658
+#, c-format
+msgid "*** The file `%s' is stripped: no detailed analysis possible\n"
+msgstr ""
+
+#: elf/sprof.c:688
+#, fuzzy, c-format
+msgid "failed to load symbol data"
+msgstr "failas per trumpas"
+
+#: elf/sprof.c:755
+#, fuzzy, c-format
+msgid "cannot load profiling data"
+msgstr "nepavyko nuskaityti failo duomenų"
+
+#: elf/sprof.c:764
+#, fuzzy, c-format
+msgid "while stat'ing profiling data file"
+msgstr "rašant duomenų bazės failą"
+
+#: elf/sprof.c:772
+#, c-format
+msgid "profiling data file `%s' does not match shared object `%s'"
+msgstr ""
+
+#: elf/sprof.c:783
+#, c-format
+msgid "failed to mmap the profiling data file"
+msgstr ""
+
+#: elf/sprof.c:791
+#, fuzzy, c-format
+msgid "error while closing the profiling data file"
+msgstr "klaida užveriant išvedimo failą"
+
+#: elf/sprof.c:800 elf/sprof.c:870
+#, fuzzy, c-format
+msgid "cannot create internal descriptor"
+msgstr "nepavyko užverti failo deskriptoriaus"
+
+#: elf/sprof.c:846
+#, c-format
+msgid "`%s' is no correct profile data file for `%s'"
+msgstr ""
+
+#: elf/sprof.c:1027 elf/sprof.c:1085
+#, fuzzy, c-format
+msgid "cannot allocate symbol data"
+msgstr "Nepavyko išskirti atminties"
+
+#: iconv/iconv_charmap.c:176 iconv/iconv_prog.c:316
+#, fuzzy, c-format
+msgid "error while closing input `%s'"
+msgstr "klaida užveriant išvedimo failą"
+
+#: iconv/iconv_charmap.c:450
+#, c-format
+msgid "illegal input sequence at position %Zd"
+msgstr ""
+
+#: iconv/iconv_charmap.c:469 iconv/iconv_prog.c:526
+#, c-format
+msgid "incomplete character or shift sequence at end of buffer"
+msgstr ""
+
+#: iconv/iconv_charmap.c:514 iconv/iconv_charmap.c:550 iconv/iconv_prog.c:569
+#: iconv/iconv_prog.c:605
+#, fuzzy, c-format
+msgid "error while reading the input"
+msgstr "klaida įkeliant bendrąsias bibliotekas"
+
+#: iconv/iconv_charmap.c:532 iconv/iconv_prog.c:587
+#, c-format
+msgid "unable to allocate buffer for input"
+msgstr ""
+
+#: iconv/iconv_prog.c:60
+msgid "Input/Output format specification:"
+msgstr ""
+
+#: iconv/iconv_prog.c:61
+msgid "encoding of original text"
+msgstr "originalaus teksto koduotÄ—"
+
+#: iconv/iconv_prog.c:62
+#, fuzzy
+msgid "encoding for output"
+msgstr "originalaus teksto koduotÄ—"
+
+#: iconv/iconv_prog.c:63
+msgid "Information:"
+msgstr "Informacija:"
+
+#: iconv/iconv_prog.c:64
+msgid "list all known coded character sets"
+msgstr ""
+
+#: iconv/iconv_prog.c:65 locale/programs/localedef.c:127
+msgid "Output control:"
+msgstr ""
+
+#: iconv/iconv_prog.c:66
+msgid "omit invalid characters from output"
+msgstr ""
+
+#: iconv/iconv_prog.c:67
+#, fuzzy
+msgid "output file"
+msgstr "Išvesti į failą duotu PAVADINIMU"
+
+#: iconv/iconv_prog.c:68
+#, fuzzy
+msgid "suppress warnings"
+msgstr "įspėjimas: "
+
+#: iconv/iconv_prog.c:69
+#, fuzzy
+msgid "print progress information"
+msgstr "Spausdinti daugiau informacijos"
+
+#: iconv/iconv_prog.c:74
+msgid "Convert encoding of given files from one encoding to another."
+msgstr ""
+
+#: iconv/iconv_prog.c:78
+msgid "[FILE...]"
+msgstr "[FAILAS...]"
+
+#: iconv/iconv_prog.c:200
+#, fuzzy, c-format
+msgid "cannot open output file"
+msgstr "%s: nepavyko atverti laikinojo failo: %s"
+
+#: iconv/iconv_prog.c:242
+#, c-format
+msgid "conversions from `%s' and to `%s' are not supported"
+msgstr ""
+
+#: iconv/iconv_prog.c:247
+#, fuzzy, c-format
+msgid "conversion from `%s' is not supported"
+msgstr "Operacija nepalaikoma"
+
+#: iconv/iconv_prog.c:254
+#, fuzzy, c-format
+msgid "conversion to `%s' is not supported"
+msgstr "Protokolas nepalaikomas"
+
+#: iconv/iconv_prog.c:258
+#, c-format
+msgid "conversion from `%s' to `%s' is not supported"
+msgstr ""
+
+#: iconv/iconv_prog.c:268
+#, c-format
+msgid "failed to start conversion processing"
+msgstr ""
+
+#: iconv/iconv_prog.c:362
+#, c-format
+msgid "error while closing output file"
+msgstr "klaida užveriant išvedimo failą"
+
+#: iconv/iconv_prog.c:471 iconv/iconv_prog.c:497
+#, c-format
+msgid "conversion stopped due to problem in writing the output"
+msgstr ""
+
+#: iconv/iconv_prog.c:522
+#, c-format
+msgid "illegal input sequence at position %ld"
+msgstr ""
+
+#: iconv/iconv_prog.c:530
+#, c-format
+msgid "internal error (illegal descriptor)"
+msgstr "vidinė klaida (nekorektiškas deskriptorius)"
+
+#: iconv/iconv_prog.c:533
+#, fuzzy, c-format
+msgid "unknown iconv() error %d"
+msgstr "nežinoma iconv() klaida %d"
+
+#: iconv/iconv_prog.c:779
+msgid ""
+"The following list contain all the coded character sets known. This does\n"
+"not necessarily mean that all combinations of these names can be used for\n"
+"the FROM and TO command line parameters. One coded character set can be\n"
+"listed with several different names (aliases).\n"
+"\n"
+" "
+msgstr ""
+
+#: iconv/iconvconfig.c:110
+#, fuzzy
+msgid "Create fastloading iconv module configuration file."
+msgstr "Nepavyko atverti konfigūracijos failo %s"
+
+#: iconv/iconvconfig.c:114
+#, fuzzy
+msgid "[DIR...]"
+msgstr "[FAILAS...]"
+
+#: iconv/iconvconfig.c:127
+msgid "Prefix used for all file accesses"
+msgstr ""
+
+#: iconv/iconvconfig.c:128
+msgid "Put output in FILE instead of installed location (--prefix does not apply to FILE)"
+msgstr ""
+
+#: iconv/iconvconfig.c:132
+msgid "Do not search standard directories, only those on the command line"
+msgstr ""
+
+#: iconv/iconvconfig.c:301
+#, c-format
+msgid "Directory arguments required when using --nostdlib"
+msgstr ""
+
+#: iconv/iconvconfig.c:343 locale/programs/localedef.c:291
+#, c-format
+msgid "no output file produced because warnings were issued"
+msgstr ""
+
+#: iconv/iconvconfig.c:429
+#, c-format
+msgid "while inserting in search tree"
+msgstr ""
+
+#: iconv/iconvconfig.c:1238
+#, fuzzy, c-format
+msgid "cannot generate output file"
+msgstr "%s: nepavyko atverti laikinojo failo: %s"
+
+#: inet/rcmd.c:157
+#, fuzzy
+msgid "rcmd: Cannot allocate memory\n"
+msgstr "Nepavyko išskirti atminties"
+
+#: inet/rcmd.c:172
+msgid "rcmd: socket: All ports in use\n"
+msgstr ""
+
+#: inet/rcmd.c:200
+#, c-format
+msgid "connect to address %s: "
+msgstr "jungtis prie adreso %s: "
+
+#: inet/rcmd.c:213
+#, c-format
+msgid "Trying %s...\n"
+msgstr "Bandoma %s...\n"
+
+#: inet/rcmd.c:249
+#, c-format
+msgid "rcmd: write (setting up stderr): %m\n"
+msgstr ""
+
+#: inet/rcmd.c:265
+#, c-format
+msgid "rcmd: poll (setting up stderr): %m\n"
+msgstr ""
+
+#: inet/rcmd.c:268
+msgid "poll: protocol failure in circuit setup\n"
+msgstr ""
+
+#: inet/rcmd.c:301
+msgid "socket: protocol failure in circuit setup\n"
+msgstr ""
+
+#: inet/rcmd.c:325
+#, c-format
+msgid "rcmd: %s: short read"
+msgstr ""
+
+#: inet/rcmd.c:481
+msgid "lstat failed"
+msgstr ""
+
+#: inet/rcmd.c:488
+#, fuzzy
+msgid "cannot open"
+msgstr "nepavyko atverti"
+
+#: inet/rcmd.c:490
+msgid "fstat failed"
+msgstr ""
+
+#: inet/rcmd.c:492
+#, fuzzy
+msgid "bad owner"
+msgstr "blogas jungtukas"
+
+#: inet/rcmd.c:494
+msgid "writeable by other than owner"
+msgstr ""
+
+#: inet/rcmd.c:496
+msgid "hard linked somewhere"
+msgstr ""
+
+#: inet/ruserpass.c:170 inet/ruserpass.c:193
+msgid "out of memory"
+msgstr "baigÄ—si atmintis"
+
+#: inet/ruserpass.c:184
+msgid "Error: .netrc file is readable by others."
+msgstr ""
+
+#: inet/ruserpass.c:185
+msgid "Remove password or make file unreadable by others."
+msgstr ""
+
+#: inet/ruserpass.c:277
+#, fuzzy, c-format
+msgid "Unknown .netrc keyword %s"
+msgstr "Nežinoma klaida "
+
+#: libidn/nfkc.c:464
+#, fuzzy
+msgid "Character out of range for UTF-8"
+msgstr "Kanalo numeris už ribų"
+
+#: locale/programs/charmap-dir.c:59
+#, fuzzy, c-format
+msgid "cannot read character map directory `%s'"
+msgstr "nepavyko atverti aplanko %s"
+
+#: locale/programs/charmap.c:138
+#, fuzzy, c-format
+msgid "character map file `%s' not found"
+msgstr "Duomenų failas %s nerastas.\n"
+
+#: locale/programs/charmap.c:195
+#, c-format
+msgid "default character map file `%s' not found"
+msgstr ""
+
+#: locale/programs/charmap.c:258
+#, c-format
+msgid "character map `%s' is not ASCII compatible, locale not ISO C compliant\n"
+msgstr ""
+
+#: locale/programs/charmap.c:337
+#, c-format
+msgid "%s: <mb_cur_max> must be greater than <mb_cur_min>\n"
+msgstr ""
+
+#: locale/programs/charmap.c:357 locale/programs/charmap.c:374
+#: locale/programs/repertoire.c:174
+#, fuzzy, c-format
+msgid "syntax error in prolog: %s"
+msgstr "sintaksÄ—s klaida prologe: %s"
+
+#: locale/programs/charmap.c:358
+#, fuzzy
+msgid "invalid definition"
+msgstr "%s: netaisyklingas parametras --%c\n"
+
+#: locale/programs/charmap.c:375 locale/programs/locfile.c:126
+#: locale/programs/locfile.c:153 locale/programs/repertoire.c:175
+#, fuzzy
+msgid "bad argument"
+msgstr "blogas argumentas"
+
+#: locale/programs/charmap.c:403
+#, c-format
+msgid "duplicate definition of <%s>"
+msgstr "kartotinis <%s> apibrėžimas"
+
+#: locale/programs/charmap.c:410
+#, c-format
+msgid "value for <%s> must be 1 or greater"
+msgstr "<%s> reikšmė turi būti 1 arba didesnė"
+
+#: locale/programs/charmap.c:422
+#, c-format
+msgid "value of <%s> must be greater or equal than the value of <%s>"
+msgstr "<%s> reikšmė turi būti lygi arba didesnė už <%s> reikšmę"
+
+#: locale/programs/charmap.c:445 locale/programs/repertoire.c:183
+#, c-format
+msgid "argument to <%s> must be a single character"
+msgstr "<%s> argumentas turi būti vienas simbolis"
+
+#: locale/programs/charmap.c:471
+msgid "character sets with locking states are not supported"
+msgstr ""
+
+#: locale/programs/charmap.c:498 locale/programs/charmap.c:552
+#: locale/programs/charmap.c:584 locale/programs/charmap.c:678
+#: locale/programs/charmap.c:733 locale/programs/charmap.c:774
+#: locale/programs/charmap.c:815
+#, fuzzy, c-format
+msgid "syntax error in %s definition: %s"
+msgstr "sintaksÄ—s klaida prologe: %s"
+
+#: locale/programs/charmap.c:499 locale/programs/charmap.c:679
+#: locale/programs/charmap.c:775 locale/programs/repertoire.c:230
+msgid "no symbolic name given"
+msgstr "neduotas joks simbolinis vardas"
+
+#: locale/programs/charmap.c:553
+msgid "invalid encoding given"
+msgstr "nurodyta netaisyklinga koduotÄ—"
+
+#: locale/programs/charmap.c:562
+msgid "too few bytes in character encoding"
+msgstr "per mažai baitų simbolio koduotėje"
+
+#: locale/programs/charmap.c:564
+msgid "too many bytes in character encoding"
+msgstr "per daug baitų simbolio koduotėje"
+
+#: locale/programs/charmap.c:586 locale/programs/charmap.c:734
+#: locale/programs/charmap.c:817 locale/programs/repertoire.c:296
+#, fuzzy
+msgid "no symbolic name given for end of range"
+msgstr "neduotas joks simbolinis vardas"
+
+#: locale/programs/charmap.c:610 locale/programs/ld-address.c:600
+#: locale/programs/ld-collate.c:2767 locale/programs/ld-collate.c:3924
+#: locale/programs/ld-ctype.c:2232 locale/programs/ld-ctype.c:2984
+#: locale/programs/ld-identification.c:452
+#: locale/programs/ld-measurement.c:238 locale/programs/ld-messages.c:332
+#: locale/programs/ld-monetary.c:943 locale/programs/ld-name.c:307
+#: locale/programs/ld-numeric.c:368 locale/programs/ld-paper.c:241
+#: locale/programs/ld-telephone.c:313 locale/programs/ld-time.c:1221
+#: locale/programs/repertoire.c:313
+#, c-format
+msgid "%1$s: definition does not end with `END %1$s'"
+msgstr "%1$s: apibrėžimas neužbaigtas „END %1$s“"
+
+#: locale/programs/charmap.c:643
+msgid "only WIDTH definitions are allowed to follow the CHARMAP definition"
+msgstr ""
+
+#: locale/programs/charmap.c:651 locale/programs/charmap.c:714
+#, c-format
+msgid "value for %s must be an integer"
+msgstr "%s reikÅ¡mÄ— turi bÅ«ti sveikasis skaiÄius"
+
+#: locale/programs/charmap.c:842
+#, c-format
+msgid "%s: error in state machine"
+msgstr "%s: klaida būsenų automate"
+
+#: locale/programs/charmap.c:850 locale/programs/ld-address.c:616
+#: locale/programs/ld-collate.c:2764 locale/programs/ld-collate.c:4115
+#: locale/programs/ld-ctype.c:2229 locale/programs/ld-ctype.c:3001
+#: locale/programs/ld-identification.c:468
+#: locale/programs/ld-measurement.c:254 locale/programs/ld-messages.c:348
+#: locale/programs/ld-monetary.c:959 locale/programs/ld-name.c:323
+#: locale/programs/ld-numeric.c:384 locale/programs/ld-paper.c:257
+#: locale/programs/ld-telephone.c:329 locale/programs/ld-time.c:1237
+#: locale/programs/locfile.c:826 locale/programs/repertoire.c:324
+#, fuzzy, c-format
+msgid "%s: premature end of file"
+msgstr "%s: failo pabaiga"
+
+#: locale/programs/charmap.c:869 locale/programs/charmap.c:880
+#, c-format
+msgid "unknown character `%s'"
+msgstr "nežinomas simbolis „%s“"
+
+#: locale/programs/charmap.c:888
+#, c-format
+msgid "number of bytes for byte sequence of beginning and end of range not the same: %d vs %d"
+msgstr ""
+
+#: locale/programs/charmap.c:993 locale/programs/ld-collate.c:3047
+#: locale/programs/repertoire.c:419
+#, fuzzy
+msgid "invalid names for character range"
+msgstr "netaisyklingas kabuÄių simbolis"
+
+#: locale/programs/charmap.c:1005 locale/programs/repertoire.c:431
+msgid "hexadecimal range format should use only capital characters"
+msgstr ""
+
+#: locale/programs/charmap.c:1023 locale/programs/repertoire.c:449
+#, c-format
+msgid "<%s> and <%s> are invalid names for range"
+msgstr ""
+
+#: locale/programs/charmap.c:1029 locale/programs/repertoire.c:456
+msgid "upper limit in range is smaller than lower limit"
+msgstr "viršutinė riba mažesnė už apatinę ribą"
+
+#: locale/programs/charmap.c:1087
+msgid "resulting bytes for range not representable."
+msgstr ""
+
+#: locale/programs/ld-address.c:133 locale/programs/ld-collate.c:1556
+#: locale/programs/ld-ctype.c:420 locale/programs/ld-identification.c:133
+#: locale/programs/ld-measurement.c:94 locale/programs/ld-messages.c:97
+#: locale/programs/ld-monetary.c:194 locale/programs/ld-name.c:94
+#: locale/programs/ld-numeric.c:98 locale/programs/ld-paper.c:91
+#: locale/programs/ld-telephone.c:94 locale/programs/ld-time.c:159
+#, c-format
+msgid "No definition for %s category found"
+msgstr "Nerastas %s kategorijos apibrėžimas"
+
+#: locale/programs/ld-address.c:144 locale/programs/ld-address.c:182
+#: locale/programs/ld-address.c:200 locale/programs/ld-address.c:229
+#: locale/programs/ld-address.c:301 locale/programs/ld-address.c:320
+#: locale/programs/ld-address.c:333 locale/programs/ld-identification.c:146
+#: locale/programs/ld-measurement.c:105 locale/programs/ld-monetary.c:206
+#: locale/programs/ld-monetary.c:250 locale/programs/ld-monetary.c:266
+#: locale/programs/ld-monetary.c:278 locale/programs/ld-name.c:105
+#: locale/programs/ld-name.c:142 locale/programs/ld-numeric.c:112
+#: locale/programs/ld-numeric.c:126 locale/programs/ld-paper.c:102
+#: locale/programs/ld-paper.c:111 locale/programs/ld-telephone.c:105
+#: locale/programs/ld-telephone.c:162 locale/programs/ld-time.c:175
+#: locale/programs/ld-time.c:196
+#, fuzzy, c-format
+msgid "%s: field `%s' not defined"
+msgstr "simbolis „%s“ neapibrėžtas"
+
+#: locale/programs/ld-address.c:156 locale/programs/ld-address.c:208
+#: locale/programs/ld-address.c:238 locale/programs/ld-address.c:276
+#: locale/programs/ld-name.c:117 locale/programs/ld-telephone.c:117
+#, c-format
+msgid "%s: field `%s' must not be empty"
+msgstr ""
+
+#: locale/programs/ld-address.c:168
+#, c-format
+msgid "%s: invalid escape `%%%c' sequence in field `%s'"
+msgstr ""
+
+#: locale/programs/ld-address.c:219
+#, fuzzy, c-format
+msgid "%s: terminology language code `%s' not defined"
+msgstr "simbolis „%s“ neapibrėžtas"
+
+#: locale/programs/ld-address.c:244
+#, fuzzy, c-format
+msgid "%s: field `%s' must not be defined"
+msgstr "simbolis „%s“ neapibrėžtas"
+
+#: locale/programs/ld-address.c:258 locale/programs/ld-address.c:287
+#, fuzzy, c-format
+msgid "%s: language abbreviation `%s' not defined"
+msgstr "simbolis „%s“ neapibrėžtas"
+
+#: locale/programs/ld-address.c:265 locale/programs/ld-address.c:293
+#: locale/programs/ld-address.c:327 locale/programs/ld-address.c:339
+#, c-format
+msgid "%s: `%s' value does not match `%s' value"
+msgstr ""
+
+#: locale/programs/ld-address.c:312
+#, c-format
+msgid "%s: numeric country code `%d' not valid"
+msgstr ""
+
+#: locale/programs/ld-address.c:508 locale/programs/ld-address.c:545
+#: locale/programs/ld-address.c:583 locale/programs/ld-ctype.c:2608
+#: locale/programs/ld-identification.c:364
+#: locale/programs/ld-measurement.c:221 locale/programs/ld-messages.c:301
+#: locale/programs/ld-monetary.c:701 locale/programs/ld-monetary.c:736
+#: locale/programs/ld-monetary.c:777 locale/programs/ld-name.c:280
+#: locale/programs/ld-numeric.c:263 locale/programs/ld-paper.c:224
+#: locale/programs/ld-telephone.c:288 locale/programs/ld-time.c:1126
+#: locale/programs/ld-time.c:1168
+#, c-format
+msgid "%s: field `%s' declared more than once"
+msgstr "%s: laukas „%s“ apibrėžtas daugiau negu vieną kartą"
+
+#: locale/programs/ld-address.c:512 locale/programs/ld-address.c:550
+#: locale/programs/ld-identification.c:368 locale/programs/ld-messages.c:311
+#: locale/programs/ld-monetary.c:705 locale/programs/ld-monetary.c:740
+#: locale/programs/ld-name.c:284 locale/programs/ld-numeric.c:267
+#: locale/programs/ld-telephone.c:292 locale/programs/ld-time.c:1020
+#: locale/programs/ld-time.c:1089 locale/programs/ld-time.c:1131
+#, c-format
+msgid "%s: unknown character in field `%s'"
+msgstr "%s: nežinomas simbolis lauke „%s“"
+
+#: locale/programs/ld-address.c:597 locale/programs/ld-collate.c:3922
+#: locale/programs/ld-ctype.c:2981 locale/programs/ld-identification.c:449
+#: locale/programs/ld-measurement.c:235 locale/programs/ld-messages.c:330
+#: locale/programs/ld-monetary.c:941 locale/programs/ld-name.c:305
+#: locale/programs/ld-numeric.c:366 locale/programs/ld-paper.c:239
+#: locale/programs/ld-telephone.c:311 locale/programs/ld-time.c:1219
+#, c-format
+msgid "%s: incomplete `END' line"
+msgstr "%s: nepilna „END“ eilutė"
+
+#: locale/programs/ld-address.c:607 locale/programs/ld-collate.c:542
+#: locale/programs/ld-collate.c:594 locale/programs/ld-collate.c:890
+#: locale/programs/ld-collate.c:903 locale/programs/ld-collate.c:2733
+#: locale/programs/ld-collate.c:2754 locale/programs/ld-collate.c:4105
+#: locale/programs/ld-ctype.c:1960 locale/programs/ld-ctype.c:2219
+#: locale/programs/ld-ctype.c:2806 locale/programs/ld-ctype.c:2992
+#: locale/programs/ld-identification.c:459
+#: locale/programs/ld-measurement.c:245 locale/programs/ld-messages.c:339
+#: locale/programs/ld-monetary.c:950 locale/programs/ld-name.c:314
+#: locale/programs/ld-numeric.c:375 locale/programs/ld-paper.c:248
+#: locale/programs/ld-telephone.c:320 locale/programs/ld-time.c:1228
+#, c-format
+msgid "%s: syntax error"
+msgstr "%s: sintaksÄ—s klaida"
+
+#: locale/programs/ld-collate.c:417
+#, c-format
+msgid "`%.*s' already defined in charmap"
+msgstr ""
+
+#: locale/programs/ld-collate.c:426
+#, c-format
+msgid "`%.*s' already defined in repertoire"
+msgstr ""
+
+#: locale/programs/ld-collate.c:433
+#, c-format
+msgid "`%.*s' already defined as collating symbol"
+msgstr ""
+
+#: locale/programs/ld-collate.c:440
+#, c-format
+msgid "`%.*s' already defined as collating element"
+msgstr ""
+
+#: locale/programs/ld-collate.c:471 locale/programs/ld-collate.c:497
+#, c-format
+msgid "%s: `forward' and `backward' are mutually excluding each other"
+msgstr ""
+
+#: locale/programs/ld-collate.c:481 locale/programs/ld-collate.c:507
+#: locale/programs/ld-collate.c:523
+#, c-format
+msgid "%s: `%s' mentioned more than once in definition of weight %d"
+msgstr ""
+
+#: locale/programs/ld-collate.c:579
+#, c-format
+msgid "%s: too many rules; first entry only had %d"
+msgstr ""
+
+#: locale/programs/ld-collate.c:615
+#, c-format
+msgid "%s: not enough sorting rules"
+msgstr ""
+
+#: locale/programs/ld-collate.c:780
+#, c-format
+msgid "%s: empty weight string not allowed"
+msgstr ""
+
+#: locale/programs/ld-collate.c:875
+#, c-format
+msgid "%s: weights must use the same ellipsis symbol as the name"
+msgstr ""
+
+#: locale/programs/ld-collate.c:931
+#, fuzzy, c-format
+msgid "%s: too many values"
+msgstr "%s: Per daug argumentų\n"
+
+#: locale/programs/ld-collate.c:1051 locale/programs/ld-collate.c:1226
+#, c-format
+msgid "order for `%.*s' already defined at %s:%Zu"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1101
+#, c-format
+msgid "%s: the start and the end symbol of a range must stand for characters"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1128
+#, c-format
+msgid "%s: byte sequences of first and last character must have the same length"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1170
+#, c-format
+msgid "%s: byte sequence of first character of range is not lower than that of the last character"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1295
+#, c-format
+msgid "%s: symbolic range ellipsis must not directly follow `order_start'"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1299
+#, c-format
+msgid "%s: symbolic range ellipsis must not be directly followed by `order_end'"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1319 locale/programs/ld-ctype.c:1477
+#, c-format
+msgid "`%s' and `%.*s' are not valid names for symbolic range"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1369 locale/programs/ld-collate.c:3858
+#, c-format
+msgid "%s: order for `%.*s' already defined at %s:%Zu"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1378
+#, fuzzy, c-format
+msgid "%s: `%s' must be a character"
+msgstr "„%s“: trūksta formato simbolio"
+
+#: locale/programs/ld-collate.c:1573
+#, c-format
+msgid "%s: `position' must be used for a specific level in all sections or none"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1598
+#, c-format
+msgid "symbol `%s' not defined"
+msgstr "simbolis „%s“ neapibrėžtas"
+
+#: locale/programs/ld-collate.c:1674 locale/programs/ld-collate.c:1780
+#, c-format
+msgid "symbol `%s' has the same encoding as"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1678 locale/programs/ld-collate.c:1784
+#, c-format
+msgid "symbol `%s'"
+msgstr "simbolis „%s“"
+
+#: locale/programs/ld-collate.c:1826
+#, c-format
+msgid "no definition of `UNDEFINED'"
+msgstr ""
+
+#: locale/programs/ld-collate.c:1855
+#, c-format
+msgid "too many errors; giving up"
+msgstr "per daug klaidų; pasiduodu"
+
+#: locale/programs/ld-collate.c:2659 locale/programs/ld-collate.c:4044
+#, fuzzy, c-format
+msgid "%s: nested conditionals not supported"
+msgstr "Operacija nepalaikoma"
+
+#: locale/programs/ld-collate.c:2677
+#, c-format
+msgid "%s: more then one 'else'"
+msgstr ""
+
+#: locale/programs/ld-collate.c:2852
+#, fuzzy, c-format
+msgid "%s: duplicate definition of `%s'"
+msgstr "kartotinis <%s> apibrėžimas"
+
+#: locale/programs/ld-collate.c:2888
+#, fuzzy, c-format
+msgid "%s: duplicate declaration of section `%s'"
+msgstr "kartotinis <%s> apibrėžimas"
+
+#: locale/programs/ld-collate.c:3027
+#, fuzzy, c-format
+msgid "%s: unknown character in collating symbol name"
+msgstr "%s: nežinomas simbolis lauke „%s“"
+
+#: locale/programs/ld-collate.c:3159
+#, fuzzy, c-format
+msgid "%s: unknown character in equivalent definition name"
+msgstr "%s: nežinomas simbolis lauke „%s“"
+
+#: locale/programs/ld-collate.c:3172
+#, fuzzy, c-format
+msgid "%s: unknown character in equivalent definition value"
+msgstr "%s: nežinomas simbolis lauke „%s“"
+
+#: locale/programs/ld-collate.c:3182
+#, c-format
+msgid "%s: unknown symbol `%s' in equivalent definition"
+msgstr ""
+
+#: locale/programs/ld-collate.c:3191
+#, fuzzy
+msgid "error while adding equivalent collating symbol"
+msgstr "klaida įkeliant bendrąsias bibliotekas"
+
+#: locale/programs/ld-collate.c:3221
+#, fuzzy, c-format
+msgid "duplicate definition of script `%s'"
+msgstr "kartotinis <%s> apibrėžimas"
+
+#: locale/programs/ld-collate.c:3269
+#, fuzzy, c-format
+msgid "%s: unknown section name `%.*s'"
+msgstr "„%s“: nežinomas funkcijos pavadinimas"
+
+#: locale/programs/ld-collate.c:3298
+#, c-format
+msgid "%s: multiple order definitions for section `%s'"
+msgstr ""
+
+#: locale/programs/ld-collate.c:3326
+#, fuzzy, c-format
+msgid "%s: invalid number of sorting rules"
+msgstr "%s: netaisyklingas argumentas"
+
+#: locale/programs/ld-collate.c:3353
+#, c-format
+msgid "%s: multiple order definitions for unnamed section"
+msgstr ""
+
+#: locale/programs/ld-collate.c:3407 locale/programs/ld-collate.c:3537
+#: locale/programs/ld-collate.c:3900
+#, fuzzy, c-format
+msgid "%s: missing `order_end' keyword"
+msgstr "%s: trūksta dvitaškio skirtuko"
+
+#: locale/programs/ld-collate.c:3470
+#, c-format
+msgid "%s: order for collating symbol %.*s not yet defined"
+msgstr ""
+
+#: locale/programs/ld-collate.c:3488
+#, c-format
+msgid "%s: order for collating element %.*s not yet defined"
+msgstr ""
+
+#: locale/programs/ld-collate.c:3499
+#, c-format
+msgid "%s: cannot reorder after %.*s: symbol not known"
+msgstr ""
+
+#: locale/programs/ld-collate.c:3551 locale/programs/ld-collate.c:3912
+#, fuzzy, c-format
+msgid "%s: missing `reorder-end' keyword"
+msgstr "%s: trūksta dvitaškio skirtuko"
+
+#: locale/programs/ld-collate.c:3585 locale/programs/ld-collate.c:3783
+#, fuzzy, c-format
+msgid "%s: section `%.*s' not known"
+msgstr "Duomenų failas %s nerastas.\n"
+
+#: locale/programs/ld-collate.c:3650
+#, c-format
+msgid "%s: bad symbol <%.*s>"
+msgstr ""
+
+#: locale/programs/ld-collate.c:3846
+#, c-format
+msgid "%s: cannot have `%s' as end of ellipsis range"
+msgstr ""
+
+#: locale/programs/ld-collate.c:3896
+#, c-format
+msgid "%s: empty category description not allowed"
+msgstr ""
+
+#: locale/programs/ld-collate.c:3915
+#, c-format
+msgid "%s: missing `reorder-sections-end' keyword"
+msgstr ""
+
+#: locale/programs/ld-collate.c:4077
+#, c-format
+msgid "%s: '%s' without matching 'ifdef' or 'ifndef'"
+msgstr ""
+
+#: locale/programs/ld-collate.c:4095
+#, c-format
+msgid "%s: 'endif' without matching 'ifdef' or 'ifndef'"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:439
+#, c-format
+msgid "No character set name specified in charmap"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:468
+#, c-format
+msgid "character L'\\u%0*x' in class `%s' must be in class `%s'"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:483
+#, c-format
+msgid "character L'\\u%0*x' in class `%s' must not be in class `%s'"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:497 locale/programs/ld-ctype.c:555
+#, c-format
+msgid "internal error in %s, line %u"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:526
+#, c-format
+msgid "character '%s' in class `%s' must be in class `%s'"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:542
+#, c-format
+msgid "character '%s' in class `%s' must not be in class `%s'"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:572 locale/programs/ld-ctype.c:610
+#, c-format
+msgid "<SP> character not in class `%s'"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:584 locale/programs/ld-ctype.c:621
+#, c-format
+msgid "<SP> character must not be in class `%s'"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:599
+#, c-format
+msgid "character <SP> not defined in character map"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:714
+#, c-format
+msgid "`digit' category has not entries in groups of ten"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:763
+#, c-format
+msgid "no input digits defined and none of the standard names in the charmap"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:828
+#, c-format
+msgid "not all characters used in `outdigit' are available in the charmap"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:845
+#, c-format
+msgid "not all characters used in `outdigit' are available in the repertoire"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:1245
+#, c-format
+msgid "character class `%s' already defined"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:1251
+#, c-format
+msgid "implementation limit: no more than %Zd character classes allowed"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:1277
+#, c-format
+msgid "character map `%s' already defined"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:1283
+#, c-format
+msgid "implementation limit: no more than %d character maps allowed"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:1548 locale/programs/ld-ctype.c:1673
+#: locale/programs/ld-ctype.c:1779 locale/programs/ld-ctype.c:2471
+#: locale/programs/ld-ctype.c:3467
+#, fuzzy, c-format
+msgid "%s: field `%s' does not contain exactly ten entries"
+msgstr "%s: laukas „%s“ apibrėžtas daugiau negu vieną kartą"
+
+#: locale/programs/ld-ctype.c:1576 locale/programs/ld-ctype.c:2150
+#, c-format
+msgid "to-value <U%0*X> of range is smaller than from-value <U%0*X>"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:1703
+msgid "start and end character sequence of range must have the same length"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:1710
+msgid "to-value character sequence is smaller than from-value sequence"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:2070 locale/programs/ld-ctype.c:2121
+msgid "premature end of `translit_ignore' definition"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:2076 locale/programs/ld-ctype.c:2127
+#: locale/programs/ld-ctype.c:2169
+msgid "syntax error"
+msgstr "sintaksÄ—s klaida"
+
+#: locale/programs/ld-ctype.c:2303
+#, fuzzy, c-format
+msgid "%s: syntax error in definition of new character class"
+msgstr "sintaksės klaida %s aprašyme: %s"
+
+#: locale/programs/ld-ctype.c:2318
+#, c-format
+msgid "%s: syntax error in definition of new character map"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:2493
+msgid "ellipsis range must be marked by two operands of same type"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:2502
+msgid "with symbolic name range values the absolute ellipsis `...' must not be used"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:2517
+msgid "with UCS range values one must use the hexadecimal symbolic ellipsis `..'"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:2531
+msgid "with character code range values one must use the absolute ellipsis `...'"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:2682
+#, fuzzy, c-format
+msgid "duplicated definition for mapping `%s'"
+msgstr "kartotinis <%s> apibrėžimas"
+
+#: locale/programs/ld-ctype.c:2768 locale/programs/ld-ctype.c:2912
+#, fuzzy, c-format
+msgid "%s: `translit_start' section does not end with `translit_end'"
+msgstr "%1$s: apibrėžimas neužbaigtas „END %1$s“"
+
+#: locale/programs/ld-ctype.c:2863
+#, fuzzy, c-format
+msgid "%s: duplicate `default_missing' definition"
+msgstr "pakartotinis rinkinio apibrėžimas"
+
+#: locale/programs/ld-ctype.c:2868
+msgid "previous definition was here"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:2890
+#, c-format
+msgid "%s: no representable `default_missing' definition found"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:3043 locale/programs/ld-ctype.c:3127
+#: locale/programs/ld-ctype.c:3147 locale/programs/ld-ctype.c:3168
+#: locale/programs/ld-ctype.c:3189 locale/programs/ld-ctype.c:3210
+#: locale/programs/ld-ctype.c:3231 locale/programs/ld-ctype.c:3271
+#: locale/programs/ld-ctype.c:3292 locale/programs/ld-ctype.c:3359
+#: locale/programs/ld-ctype.c:3401 locale/programs/ld-ctype.c:3426
+#, c-format
+msgid "%s: character `%s' not defined while needed as default value"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:3048 locale/programs/ld-ctype.c:3132
+#: locale/programs/ld-ctype.c:3152 locale/programs/ld-ctype.c:3173
+#: locale/programs/ld-ctype.c:3194 locale/programs/ld-ctype.c:3215
+#: locale/programs/ld-ctype.c:3236 locale/programs/ld-ctype.c:3276
+#: locale/programs/ld-ctype.c:3297 locale/programs/ld-ctype.c:3364
+#, c-format
+msgid "%s: character `%s' in charmap not representable with one byte"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:3408 locale/programs/ld-ctype.c:3433
+#, c-format
+msgid "%s: character `%s' needed as default value not representable with one byte"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:3489
+#, c-format
+msgid "no output digits defined and none of the standard names in the charmap"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:3780
+#, c-format
+msgid "%s: transliteration data from locale `%s' not available"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:3881
+#, c-format
+msgid "%s: table for class \"%s\": %lu bytes\n"
+msgstr ""
+
+#: locale/programs/ld-ctype.c:3950
+#, fuzzy, c-format
+msgid "%s: table for map \"%s\": %lu bytes\n"
+msgstr "%s: nepavyko atverti %s: %m\n"
+
+#: locale/programs/ld-ctype.c:4083
+#, c-format
+msgid "%s: table for width: %lu bytes\n"
+msgstr ""
+
+#: locale/programs/ld-identification.c:170
+#, fuzzy, c-format
+msgid "%s: no identification for category `%s'"
+msgstr "Nerastas %s kategorijos apibrėžimas"
+
+#: locale/programs/ld-identification.c:435
+#, fuzzy, c-format
+msgid "%s: duplicate category version definition"
+msgstr "pakartotinis rinkinio apibrėžimas"
+
+#: locale/programs/ld-measurement.c:113
+#, fuzzy, c-format
+msgid "%s: invalid value for field `%s'"
+msgstr "%s: per mažai reikšmių laukui „%s“"
+
+#: locale/programs/ld-messages.c:114 locale/programs/ld-messages.c:148
+#, fuzzy, c-format
+msgid "%s: field `%s' undefined"
+msgstr "simbolis „%s“ neapibrėžtas"
+
+#: locale/programs/ld-messages.c:121 locale/programs/ld-messages.c:155
+#: locale/programs/ld-monetary.c:256 locale/programs/ld-numeric.c:118
+#, fuzzy, c-format
+msgid "%s: value for field `%s' must not be an empty string"
+msgstr "%s reikÅ¡mÄ— turi bÅ«ti sveikasis skaiÄius"
+
+#: locale/programs/ld-messages.c:137 locale/programs/ld-messages.c:171
+#, fuzzy, c-format
+msgid "%s: no correct regular expression for field `%s': %s"
+msgstr "%s: nežinomas simbolis lauke „%s“"
+
+#: locale/programs/ld-monetary.c:224
+#, c-format
+msgid "%s: value of field `int_curr_symbol' has wrong length"
+msgstr ""
+
+#: locale/programs/ld-monetary.c:237
+#, c-format
+msgid "%s: value of field `int_curr_symbol' does not correspond to a valid name in ISO 4217"
+msgstr ""
+
+#: locale/programs/ld-monetary.c:285 locale/programs/ld-monetary.c:315
+#, fuzzy, c-format
+msgid "%s: value for field `%s' must be in range %d...%d"
+msgstr "%s reikÅ¡mÄ— turi bÅ«ti sveikasis skaiÄius"
+
+#: locale/programs/ld-monetary.c:747 locale/programs/ld-numeric.c:274
+#, fuzzy, c-format
+msgid "%s: value for field `%s' must be a single character"
+msgstr "<%s> argumentas turi būti vienas simbolis"
+
+#: locale/programs/ld-monetary.c:844 locale/programs/ld-numeric.c:318
+#, c-format
+msgid "%s: `-1' must be last entry in `%s' field"
+msgstr ""
+
+#: locale/programs/ld-monetary.c:866 locale/programs/ld-numeric.c:335
+#, fuzzy, c-format
+msgid "%s: values for field `%s' must be smaller than 127"
+msgstr "%s: per mažai reikšmių laukui „%s“"
+
+#: locale/programs/ld-monetary.c:909
+msgid "conversion rate value cannot be zero"
+msgstr ""
+
+#: locale/programs/ld-name.c:129 locale/programs/ld-telephone.c:126
+#: locale/programs/ld-telephone.c:149
+#, fuzzy, c-format
+msgid "%s: invalid escape sequence in field `%s'"
+msgstr "%s: nežinomas simbolis lauke „%s“"
+
+#: locale/programs/ld-time.c:247
+#, c-format
+msgid "%s: direction flag in string %Zd in `era' field is not '+' nor '-'"
+msgstr ""
+
+#: locale/programs/ld-time.c:258
+#, c-format
+msgid "%s: direction flag in string %Zd in `era' field is not a single character"
+msgstr ""
+
+#: locale/programs/ld-time.c:271
+#, c-format
+msgid "%s: invalid number for offset in string %Zd in `era' field"
+msgstr ""
+
+#: locale/programs/ld-time.c:279
+#, c-format
+msgid "%s: garbage at end of offset value in string %Zd in `era' field"
+msgstr ""
+
+#: locale/programs/ld-time.c:330
+#, c-format
+msgid "%s: invalid starting date in string %Zd in `era' field"
+msgstr ""
+
+#: locale/programs/ld-time.c:339
+#, c-format
+msgid "%s: garbage at end of starting date in string %Zd in `era' field "
+msgstr ""
+
+#: locale/programs/ld-time.c:358
+#, c-format
+msgid "%s: starting date is invalid in string %Zd in `era' field"
+msgstr ""
+
+#: locale/programs/ld-time.c:407
+#, c-format
+msgid "%s: invalid stopping date in string %Zd in `era' field"
+msgstr ""
+
+#: locale/programs/ld-time.c:416
+#, c-format
+msgid "%s: garbage at end of stopping date in string %Zd in `era' field"
+msgstr ""
+
+#: locale/programs/ld-time.c:435
+#, c-format
+msgid "%s: stopping date is invalid in string %Zd in `era' field"
+msgstr ""
+
+#: locale/programs/ld-time.c:444
+#, c-format
+msgid "%s: missing era name in string %Zd in `era' field"
+msgstr ""
+
+#: locale/programs/ld-time.c:456
+#, c-format
+msgid "%s: missing era format in string %Zd in `era' field"
+msgstr ""
+
+#: locale/programs/ld-time.c:497
+#, c-format
+msgid "%s: third operand for value of field `%s' must not be larger than %d"
+msgstr ""
+
+#: locale/programs/ld-time.c:505 locale/programs/ld-time.c:513
+#: locale/programs/ld-time.c:521
+#, fuzzy, c-format
+msgid "%s: values for field `%s' must not be larger than %d"
+msgstr "%s reikÅ¡mÄ— turi bÅ«ti sveikasis skaiÄius"
+
+#: locale/programs/ld-time.c:1004
+#, c-format
+msgid "%s: too few values for field `%s'"
+msgstr "%s: per mažai reikšmių laukui „%s“"
+
+#: locale/programs/ld-time.c:1049
+msgid "extra trailing semicolon"
+msgstr "papildomas kabliataškis pabaigoje"
+
+#: locale/programs/ld-time.c:1052
+#, fuzzy, c-format
+msgid "%s: too many values for field `%s'"
+msgstr "%s: per mažai reikšmių laukui „%s“"
+
+#: locale/programs/linereader.c:130
+msgid "trailing garbage at end of line"
+msgstr "šiukšlės eilutės pabaigoje"
+
+#: locale/programs/linereader.c:298
+msgid "garbage at end of number"
+msgstr "Å¡iukÅ¡lÄ—s skaiÄiaus pabaigoje"
+
+#: locale/programs/linereader.c:410
+msgid "garbage at end of character code specification"
+msgstr ""
+
+#: locale/programs/linereader.c:496
+#, fuzzy
+msgid "unterminated symbolic name"
+msgstr "neužbaigtas pranešimas"
+
+#: locale/programs/linereader.c:623
+msgid "illegal escape sequence at end of string"
+msgstr ""
+
+#: locale/programs/linereader.c:627 locale/programs/linereader.c:855
+#, fuzzy
+msgid "unterminated string"
+msgstr "neužbaigtas pranešimas"
+
+#: locale/programs/linereader.c:669
+msgid "non-symbolic character value should not be used"
+msgstr ""
+
+#: locale/programs/linereader.c:816
+#, fuzzy, c-format
+msgid "symbol `%.*s' not in charmap"
+msgstr "simbolis „%s“ neapibrėžtas"
+
+#: locale/programs/linereader.c:837
+#, fuzzy, c-format
+msgid "symbol `%.*s' not in repertoire map"
+msgstr "simbolis „%s“ neapibrėžtas"
+
+#: locale/programs/locale.c:74
+msgid "System information:"
+msgstr "Sistemos informacija:"
+
+#: locale/programs/locale.c:76
+msgid "Write names of available locales"
+msgstr ""
+
+#: locale/programs/locale.c:78
+msgid "Write names of available charmaps"
+msgstr ""
+
+#: locale/programs/locale.c:79
+msgid "Modify output format:"
+msgstr ""
+
+#: locale/programs/locale.c:80
+msgid "Write names of selected categories"
+msgstr ""
+
+#: locale/programs/locale.c:81
+msgid "Write names of selected keywords"
+msgstr ""
+
+#: locale/programs/locale.c:82
+msgid "Print more information"
+msgstr "Spausdinti daugiau informacijos"
+
+#: locale/programs/locale.c:87
+msgid ""
+"Get locale-specific information.\vFor bug reporting instructions, please see:\n"
+"<http://www.gnu.org/software/libc/bugs.html>.\n"
+msgstr ""
+
+#: locale/programs/locale.c:92
+msgid ""
+"NAME\n"
+"[-a|-m]"
+msgstr ""
+
+#: locale/programs/locale.c:193
+#, c-format
+msgid "Cannot set LC_CTYPE to default locale"
+msgstr "Nepavyko nustatyti LC_CTYPE į numatytąją lokalę"
+
+#: locale/programs/locale.c:195
+#, c-format
+msgid "Cannot set LC_MESSAGES to default locale"
+msgstr "Nepavyko nustatyti LC_MESSAGES į numatytąją lokalę"
+
+#: locale/programs/locale.c:208
+#, c-format
+msgid "Cannot set LC_COLLATE to default locale"
+msgstr "Nepavyko nustatyti LC_COLLATE į numatytąją lokalę"
+
+#: locale/programs/locale.c:224
+#, c-format
+msgid "Cannot set LC_ALL to default locale"
+msgstr "Nepavyko nustatyti LC_ALL į numatytąją lokalę"
+
+#: locale/programs/locale.c:500
+#, fuzzy, c-format
+msgid "while preparing output"
+msgstr "skaitant duomenų bazę"
+
+#: locale/programs/localedef.c:120
+msgid "Input Files:"
+msgstr ""
+
+#: locale/programs/localedef.c:122
+msgid "Symbolic character names defined in FILE"
+msgstr ""
+
+#: locale/programs/localedef.c:123
+#, fuzzy
+msgid "Source definitions are found in FILE"
+msgstr "Nerastas %s kategorijos apibrėžimas"
+
+#: locale/programs/localedef.c:125
+msgid "FILE contains mapping from symbolic names to UCS4 values"
+msgstr ""
+
+#: locale/programs/localedef.c:129
+msgid "Create output even if warning messages were issued"
+msgstr ""
+
+#: locale/programs/localedef.c:130
+msgid "Create old-style tables"
+msgstr ""
+
+#: locale/programs/localedef.c:131
+#, fuzzy
+msgid "Optional output file prefix"
+msgstr "netaisyklinga grupÄ—"
+
+#: locale/programs/localedef.c:132
+msgid "Be strictly POSIX conform"
+msgstr ""
+
+#: locale/programs/localedef.c:134
+msgid "Suppress warnings and information messages"
+msgstr ""
+
+#: locale/programs/localedef.c:135
+#, fuzzy
+msgid "Print more messages"
+msgstr "neužbaigtas pranešimas"
+
+#: locale/programs/localedef.c:136
+msgid "Archive control:"
+msgstr ""
+
+#: locale/programs/localedef.c:138
+msgid "Don't add new data to archive"
+msgstr ""
+
+#: locale/programs/localedef.c:140
+msgid "Add locales named by parameters to archive"
+msgstr ""
+
+#: locale/programs/localedef.c:141
+msgid "Replace existing archive content"
+msgstr ""
+
+#: locale/programs/localedef.c:143
+msgid "Remove locales named by parameters from archive"
+msgstr ""
+
+#: locale/programs/localedef.c:144
+msgid "List content of archive"
+msgstr ""
+
+#: locale/programs/localedef.c:146
+msgid "locale.alias file to consult when making archive"
+msgstr ""
+
+#: locale/programs/localedef.c:151
+#, fuzzy
+msgid "Compile locale specification"
+msgstr "%s: nÄ—ra baigimo specifikacijos"
+
+#: locale/programs/localedef.c:154
+msgid ""
+"NAME\n"
+"[--add-to-archive|--delete-from-archive] FILE...\n"
+"--list-archive [FILE]"
+msgstr ""
+
+#: locale/programs/localedef.c:232
+#, fuzzy, c-format
+msgid "cannot create directory for output files"
+msgstr "nepavyko atverti aplanko %s"
+
+#: locale/programs/localedef.c:243
+#, c-format
+msgid "FATAL: system does not define `_POSIX2_LOCALEDEF'"
+msgstr ""
+
+#: locale/programs/localedef.c:257 locale/programs/localedef.c:273
+#: locale/programs/localedef.c:599 locale/programs/localedef.c:619
+#, fuzzy, c-format
+msgid "cannot open locale definition file `%s'"
+msgstr "%s: nepavyko atverti laikinojo failo: %s"
+
+#: locale/programs/localedef.c:285
+#, fuzzy, c-format
+msgid "cannot write output files to `%s'"
+msgstr "%s: nepavyko atverti laikinojo failo: %s"
+
+#: locale/programs/localedef.c:366
+#, c-format
+msgid ""
+"System's directory for character maps : %s\n"
+" repertoire maps: %s\n"
+" locale path : %s\n"
+"%s"
+msgstr ""
+
+#: locale/programs/localedef.c:567
+#, c-format
+msgid "circular dependencies between locale definitions"
+msgstr ""
+
+#: locale/programs/localedef.c:573
+#, c-format
+msgid "cannot add already read locale `%s' a second time"
+msgstr ""
+
+#: locale/programs/locarchive.c:88 locale/programs/locarchive.c:261
+#, c-format
+msgid "cannot create temporary file"
+msgstr ""
+
+#: locale/programs/locarchive.c:118 locale/programs/locarchive.c:307
+#, c-format
+msgid "cannot initialize archive file"
+msgstr ""
+
+#: locale/programs/locarchive.c:125 locale/programs/locarchive.c:314
+#, fuzzy, c-format
+msgid "cannot resize archive file"
+msgstr "%s: nepavyko perskaityti: %s"
+
+#: locale/programs/locarchive.c:134 locale/programs/locarchive.c:323
+#: locale/programs/locarchive.c:527
+#, fuzzy, c-format
+msgid "cannot map archive header"
+msgstr "nepavyko perskaityti antraštės"
+
+#: locale/programs/locarchive.c:156
+#, c-format
+msgid "failed to create new locale archive"
+msgstr ""
+
+#: locale/programs/locarchive.c:168
+#, c-format
+msgid "cannot change mode of new locale archive"
+msgstr ""
+
+#: locale/programs/locarchive.c:255
+#, c-format
+msgid "cannot map locale archive file"
+msgstr ""
+
+#: locale/programs/locarchive.c:331
+#, fuzzy, c-format
+msgid "cannot lock new archive"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: locale/programs/locarchive.c:396
+#, fuzzy, c-format
+msgid "cannot extend locale archive file"
+msgstr "nepavyko atverti duomenų failo"
+
+#: locale/programs/locarchive.c:405
+#, c-format
+msgid "cannot change mode of resized locale archive"
+msgstr ""
+
+#: locale/programs/locarchive.c:413
+#, fuzzy, c-format
+msgid "cannot rename new archive"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: locale/programs/locarchive.c:466
+#, fuzzy, c-format
+msgid "cannot open locale archive \"%s\""
+msgstr "Nepavyko atverti podÄ—lio failo %s\n"
+
+#: locale/programs/locarchive.c:471
+#, fuzzy, c-format
+msgid "cannot stat locale archive \"%s\""
+msgstr "%s: nepavyko perskaityti: %s"
+
+#: locale/programs/locarchive.c:490
+#, fuzzy, c-format
+msgid "cannot lock locale archive \"%s\""
+msgstr "%s: nepavyko perskaityti: %s"
+
+#: locale/programs/locarchive.c:513
+#, fuzzy, c-format
+msgid "cannot read archive header"
+msgstr "nepavyko perskaityti antraštės"
+
+#: locale/programs/locarchive.c:573
+#, c-format
+msgid "locale '%s' already exists"
+msgstr ""
+
+#: locale/programs/locarchive.c:804 locale/programs/locarchive.c:819
+#: locale/programs/locarchive.c:831 locale/programs/locarchive.c:843
+#: locale/programs/locfile.c:344
+#, fuzzy, c-format
+msgid "cannot add to locale archive"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: locale/programs/locarchive.c:998
+#, fuzzy, c-format
+msgid "locale alias file `%s' not found"
+msgstr "Duomenų failas %s nerastas.\n"
+
+#: locale/programs/locarchive.c:1142
+#, fuzzy, c-format
+msgid "Adding %s\n"
+msgstr "skaitomas %s"
+
+#: locale/programs/locarchive.c:1148
+#, c-format
+msgid "stat of \"%s\" failed: %s: ignored"
+msgstr ""
+
+#: locale/programs/locarchive.c:1154
+#, fuzzy, c-format
+msgid "\"%s\" is no directory; ignored"
+msgstr "Aplankas"
+
+#: locale/programs/locarchive.c:1161
+#, fuzzy, c-format
+msgid "cannot open directory \"%s\": %s: ignored"
+msgstr "nepavyko atverti aplanko %s"
+
+#: locale/programs/locarchive.c:1233
+#, c-format
+msgid "incomplete set of locale files in \"%s\""
+msgstr ""
+
+#: locale/programs/locarchive.c:1297
+#, fuzzy, c-format
+msgid "cannot read all files in \"%s\": ignored"
+msgstr "nepavyko nuskaityti failo duomenų"
+
+#: locale/programs/locarchive.c:1367
+#, c-format
+msgid "locale \"%s\" not in archive"
+msgstr ""
+
+#: locale/programs/locfile.c:132
+#, fuzzy, c-format
+msgid "argument to `%s' must be a single character"
+msgstr "<%s> argumentas turi būti vienas simbolis"
+
+#: locale/programs/locfile.c:252
+#, fuzzy
+msgid "syntax error: not inside a locale definition section"
+msgstr "sintaksės klaida %s aprašyme: %s"
+
+#: locale/programs/locfile.c:626
+#, fuzzy, c-format
+msgid "cannot open output file `%s' for category `%s'"
+msgstr "nepavyko atverti duomenų bazės failo „%s“: %s"
+
+#: locale/programs/locfile.c:650
+#, c-format
+msgid "failure while writing data for category `%s'"
+msgstr ""
+
+#: locale/programs/locfile.c:746
+#, fuzzy, c-format
+msgid "cannot create output file `%s' for category `%s'"
+msgstr "nepavyko sukurti laikino failo „here“ dokumentui: %s"
+
+#: locale/programs/locfile.c:782
+#, fuzzy
+msgid "expect string argument for `copy'"
+msgstr "„%s“ trūksta parametro"
+
+#: locale/programs/locfile.c:786
+msgid "locale name should consist only of portable characters"
+msgstr ""
+
+#: locale/programs/locfile.c:805
+msgid "no other keyword shall be specified when `copy' is used"
+msgstr ""
+
+#: locale/programs/locfile.c:819
+#, fuzzy, c-format
+msgid "`%1$s' definition does not end with `END %1$s'"
+msgstr "%1$s: apibrėžimas neužbaigtas „END %1$s“"
+
+#: locale/programs/repertoire.c:229 locale/programs/repertoire.c:270
+#: locale/programs/repertoire.c:295
+#, fuzzy, c-format
+msgid "syntax error in repertoire map definition: %s"
+msgstr "sintaksÄ—s klaida prologe: %s"
+
+#: locale/programs/repertoire.c:271
+msgid "no <Uxxxx> or <Uxxxxxxxx> value given"
+msgstr ""
+
+#: locale/programs/repertoire.c:331
+#, c-format
+msgid "cannot save new repertoire map"
+msgstr ""
+
+#: locale/programs/repertoire.c:342
+#, fuzzy, c-format
+msgid "repertoire map file `%s' not found"
+msgstr "Duomenų failas %s nerastas.\n"
+
+#: login/programs/pt_chown.c:74
+#, c-format
+msgid "Set the owner, group and access permission of the slave pseudo terminal corresponding to the master pseudo terminal passed on file descriptor `%d'. This is the helper program for the `grantpt' function. It is not intended to be run directly from the command line.\n"
+msgstr ""
+
+#: login/programs/pt_chown.c:84
+#, c-format
+msgid ""
+"The owner is set to the current user, the group is set to `%s', and the access permission is set to `%o'.\n"
+"\n"
+"%s"
+msgstr ""
+
+#: login/programs/pt_chown.c:161
+#, c-format
+msgid "too many arguments"
+msgstr "per daug argumentų"
+
+#: login/programs/pt_chown.c:169
+#, c-format
+msgid "needs to be installed setuid `root'"
+msgstr "turi būti instaliuota setuid „root“"
+
+#: malloc/mcheck.c:330
+msgid "memory is consistent, library is buggy\n"
+msgstr "atminties turinys korektiškas, bibliotekoje yra klaida\n"
+
+#: malloc/mcheck.c:333
+msgid "memory clobbered before allocated block\n"
+msgstr ""
+
+#: malloc/mcheck.c:336
+msgid "memory clobbered past end of allocated block\n"
+msgstr ""
+
+#: malloc/mcheck.c:339
+msgid "block freed twice\n"
+msgstr "blokas atlaisvintas du kartus\n"
+
+#: malloc/mcheck.c:342
+#, fuzzy
+msgid "bogus mcheck_status, library is buggy\n"
+msgstr "atminties turinys korektiškas, bibliotekoje yra klaida\n"
+
+#: malloc/memusage.sh:27
+msgid "Try \\`memusage --help' for more information."
+msgstr "Pabandykite „memusage --help“, jei norite gauti daugiau informacijos."
+
+#: malloc/memusage.sh:33
+msgid "memusage: option \\`$1' requires an argument"
+msgstr "memusage: parametrui „$1“ reikia argumento"
+
+#: malloc/memusage.sh:39
+msgid ""
+"Usage: memusage [OPTION]... PROGRAM [PROGRAMOPTION]...\n"
+"Profile memory usage of PROGRAM.\n"
+"\n"
+" -n,--progname=NAME Name of the program file to profile\n"
+" -p,--png=FILE Generate PNG graphic and store it in FILE\n"
+" -d,--data=FILE Generate binary data file and store it in FILE\n"
+" -u,--unbuffered Don't buffer output\n"
+" -b,--buffer=SIZE Collect SIZE entries before writing them out\n"
+" --no-timer Don't collect additional information through timer\n"
+" -m,--mmap Also trace mmap & friends\n"
+"\n"
+" -?,--help Print this help and exit\n"
+" --usage Give a short usage message\n"
+" -V,--version Print version information and exit\n"
+"\n"
+" The following options only apply when generating graphical output:\n"
+" -t,--time-based Make graph linear in time\n"
+" -T,--total Also draw graph of total memory use\n"
+" --title=STRING Use STRING as title of the graph\n"
+" -x,--x-size=SIZE Make graphic SIZE pixels wide\n"
+" -y,--y-size=SIZE Make graphic SIZE pixels high\n"
+"\n"
+"Mandatory arguments to long options are also mandatory for any corresponding\n"
+"short options.\n"
+"\n"
+"For bug reporting instructions, please see:\n"
+"<http://www.gnu.org/software/libc/bugs.html>."
+msgstr ""
+
+#: malloc/memusage.sh:99
+msgid ""
+"Syntax: memusage [--data=FILE] [--progname=NAME] [--png=FILE] [--unbuffered]\n"
+" [--buffer=SIZE] [--no-timer] [--time-based] [--total]\n"
+" [--title=STRING] [--x-size=SIZE] [--y-size=SIZE]\n"
+" PROGRAM [PROGRAMOPTION]..."
+msgstr ""
+
+#: malloc/memusage.sh:191
+#, fuzzy
+msgid "memusage: option \\`${1##*=}' is ambiguous"
+msgstr "ldd: parametras „$1“ dviprasmis"
+
+#: malloc/memusage.sh:200
+#, fuzzy
+msgid "memusage: unrecognized option \\`$1'"
+msgstr "%s: neatpažintas parametras „--%s“\n"
+
+#: malloc/memusage.sh:213
+msgid "No program name given"
+msgstr "Nenurodytas programos vardas"
+
+#: malloc/memusagestat.c:54
+#, fuzzy
+msgid "Name output file"
+msgstr "Išvesti į failą duotu PAVADINIMU"
+
+#: malloc/memusagestat.c:55
+msgid "Title string used in output graphic"
+msgstr ""
+
+#: malloc/memusagestat.c:56
+msgid "Generate output linear to time (default is linear to number of function calls)"
+msgstr ""
+
+#: malloc/memusagestat.c:58
+msgid "Also draw graph for total memory consumption"
+msgstr ""
+
+#: malloc/memusagestat.c:59
+msgid "Make output graphic VALUE pixels wide"
+msgstr ""
+
+#: malloc/memusagestat.c:60
+msgid "Make output graphic VALUE pixels high"
+msgstr ""
+
+#: malloc/memusagestat.c:65
+msgid "Generate graphic from memory profiling data"
+msgstr ""
+
+#: malloc/memusagestat.c:68
+msgid "DATAFILE [OUTFILE]"
+msgstr ""
+
+#: misc/error.c:118 timezone/zic.c:417
+msgid "Unknown system error"
+msgstr ""
+
+#: nis/nis_callback.c:189
+#, fuzzy
+msgid "unable to free arguments"
+msgstr "per daug argumentų"
+
+#: nis/nis_error.h:1 nis/ypclnt.c:822 nis/ypclnt.c:910 posix/regcomp.c:132
+#: sysdeps/gnu/errlist.c:20
+msgid "Success"
+msgstr "SÄ—kmÄ—"
+
+#: nis/nis_error.h:2
+#, fuzzy
+msgid "Probable success"
+msgstr "DalinÄ— sÄ—kmÄ—"
+
+#: nis/nis_error.h:3
+#, fuzzy
+msgid "Not found"
+msgstr "Duomenų failas %s nerastas.\n"
+
+#: nis/nis_error.h:4
+#, fuzzy
+msgid "Probably not found"
+msgstr "Duomenų failas %s nerastas.\n"
+
+#: nis/nis_error.h:5
+#, fuzzy
+msgid "Cache expired"
+msgstr "BaigÄ—si rakto galiojimo laikas"
+
+#: nis/nis_error.h:6
+#, fuzzy
+msgid "NIS+ servers unreachable"
+msgstr "Tinklas neprieinamas"
+
+#: nis/nis_error.h:7
+#, fuzzy
+msgid "Unknown object"
+msgstr "Nežinomas serveris"
+
+#: nis/nis_error.h:8
+msgid "Server busy, try again"
+msgstr ""
+
+#: nis/nis_error.h:9
+msgid "Generic system error"
+msgstr ""
+
+#: nis/nis_error.h:10
+msgid "First/next chain broken"
+msgstr ""
+
+#. TRANS Permission denied; the file permissions do not allow the attempted operation.
+#: nis/nis_error.h:11 nis/ypclnt.c:867 sysdeps/gnu/errlist.c:157
+#, fuzzy
+msgid "Permission denied"
+msgstr "Priėjimas uždraustas"
+
+#: nis/nis_error.h:12
+msgid "Not owner"
+msgstr ""
+
+#: nis/nis_error.h:13
+msgid "Name not served by this server"
+msgstr ""
+
+#: nis/nis_error.h:14
+#, fuzzy
+msgid "Server out of memory"
+msgstr "baigÄ—si atmintis"
+
+#: nis/nis_error.h:15
+msgid "Object with same name exists"
+msgstr ""
+
+#: nis/nis_error.h:16
+msgid "Not master server for this domain"
+msgstr ""
+
+#: nis/nis_error.h:17
+#, fuzzy
+msgid "Invalid object for operation"
+msgstr "netaisyklinga veiksena dlopen()"
+
+#: nis/nis_error.h:18
+#, fuzzy
+msgid "Malformed name, or illegal name"
+msgstr "nekorektiška eilutė ignoruota"
+
+#: nis/nis_error.h:19
+msgid "Unable to create callback"
+msgstr ""
+
+#: nis/nis_error.h:20
+msgid "Results sent to callback proc"
+msgstr ""
+
+#: nis/nis_error.h:21
+msgid "Not found, no such name"
+msgstr ""
+
+#: nis/nis_error.h:22
+msgid "Name/entry isn't unique"
+msgstr ""
+
+#: nis/nis_error.h:23
+#, fuzzy
+msgid "Modification failed"
+msgstr "Atminties išskyrimo klaida"
+
+#: nis/nis_error.h:24
+msgid "Database for table does not exist"
+msgstr ""
+
+#: nis/nis_error.h:25
+msgid "Entry/table type mismatch"
+msgstr ""
+
+#: nis/nis_error.h:26
+msgid "Link points to illegal name"
+msgstr ""
+
+#: nis/nis_error.h:27
+msgid "Partial success"
+msgstr "DalinÄ— sÄ—kmÄ—"
+
+#: nis/nis_error.h:28
+msgid "Too many attributes"
+msgstr "Per daug atributų"
+
+#: nis/nis_error.h:29
+msgid "Error in RPC subsystem"
+msgstr ""
+
+#: nis/nis_error.h:30
+msgid "Missing or malformed attribute"
+msgstr ""
+
+#: nis/nis_error.h:31
+#, fuzzy
+msgid "Named object is not searchable"
+msgstr "bendrasis objektas neatvertas"
+
+#: nis/nis_error.h:32
+msgid "Error while talking to callback proc"
+msgstr ""
+
+#: nis/nis_error.h:33
+msgid "Non NIS+ namespace encountered"
+msgstr ""
+
+#: nis/nis_error.h:34
+msgid "Illegal object type for operation"
+msgstr ""
+
+#: nis/nis_error.h:35
+msgid "Passed object is not the same object on server"
+msgstr ""
+
+#: nis/nis_error.h:36
+#, fuzzy
+msgid "Modify operation failed"
+msgstr "Atminties išskyrimo klaida"
+
+#: nis/nis_error.h:37
+msgid "Query illegal for named table"
+msgstr ""
+
+#: nis/nis_error.h:38
+msgid "Attempt to remove a non-empty table"
+msgstr ""
+
+#: nis/nis_error.h:39
+msgid "Error in accessing NIS+ cold start file. Is NIS+ installed?"
+msgstr ""
+
+#: nis/nis_error.h:40
+#, fuzzy
+msgid "Full resync required for directory"
+msgstr "Toks failas ar aplankas neegzistuoja"
+
+#: nis/nis_error.h:41
+#, fuzzy
+msgid "NIS+ operation failed"
+msgstr "Operacija nutraukta"
+
+#: nis/nis_error.h:42
+msgid "NIS+ service is unavailable or not installed"
+msgstr ""
+
+#: nis/nis_error.h:43
+msgid "Yes, 42 is the meaning of life"
+msgstr ""
+
+#: nis/nis_error.h:44
+msgid "Unable to authenticate NIS+ server"
+msgstr ""
+
+#: nis/nis_error.h:45
+msgid "Unable to authenticate NIS+ client"
+msgstr ""
+
+#: nis/nis_error.h:46
+#, fuzzy
+msgid "No file space on server"
+msgstr "Įrenginyje neliko vietos"
+
+#: nis/nis_error.h:47
+msgid "Unable to create process on server"
+msgstr ""
+
+#: nis/nis_error.h:48
+msgid "Master server busy, full dump rescheduled."
+msgstr ""
+
+#: nis/nis_local_names.c:122
+#, c-format
+msgid "LOCAL entry for UID %d in directory %s not unique\n"
+msgstr ""
+
+#: nis/nis_print.c:51
+msgid "UNKNOWN"
+msgstr "NEŽINOMA"
+
+#: nis/nis_print.c:109
+msgid "BOGUS OBJECT\n"
+msgstr ""
+
+#: nis/nis_print.c:112
+msgid "NO OBJECT\n"
+msgstr ""
+
+#: nis/nis_print.c:115
+msgid "DIRECTORY\n"
+msgstr ""
+
+#: nis/nis_print.c:118
+msgid "GROUP\n"
+msgstr ""
+
+#: nis/nis_print.c:121
+msgid "TABLE\n"
+msgstr ""
+
+#: nis/nis_print.c:124
+msgid "ENTRY\n"
+msgstr ""
+
+#: nis/nis_print.c:127
+msgid "LINK\n"
+msgstr ""
+
+#: nis/nis_print.c:130
+msgid "PRIVATE\n"
+msgstr ""
+
+#: nis/nis_print.c:133
+#, fuzzy
+msgid "(Unknown object)\n"
+msgstr "Nežinomas serveris"
+
+#: nis/nis_print.c:167
+#, c-format
+msgid "Name : `%s'\n"
+msgstr ""
+
+#: nis/nis_print.c:168
+#, c-format
+msgid "Type : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:173
+msgid "Master Server :\n"
+msgstr ""
+
+#: nis/nis_print.c:175
+msgid "Replicate :\n"
+msgstr ""
+
+#: nis/nis_print.c:176
+#, c-format
+msgid "\tName : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:177
+msgid "\tPublic Key : "
+msgstr ""
+
+#: nis/nis_print.c:181
+msgid "None.\n"
+msgstr ""
+
+#: nis/nis_print.c:184
+#, c-format
+msgid "Diffie-Hellmann (%d bits)\n"
+msgstr ""
+
+#: nis/nis_print.c:189
+#, c-format
+msgid "RSA (%d bits)\n"
+msgstr ""
+
+#: nis/nis_print.c:192
+msgid "Kerberos.\n"
+msgstr ""
+
+#: nis/nis_print.c:195
+#, c-format
+msgid "Unknown (type = %d, bits = %d)\n"
+msgstr ""
+
+#: nis/nis_print.c:206
+#, c-format
+msgid "\tUniversal addresses (%u)\n"
+msgstr ""
+
+#: nis/nis_print.c:228
+msgid "Time to live : "
+msgstr ""
+
+#: nis/nis_print.c:230
+msgid "Default Access rights :\n"
+msgstr ""
+
+#: nis/nis_print.c:239
+#, c-format
+msgid "\tType : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:240
+msgid "\tAccess rights: "
+msgstr ""
+
+#: nis/nis_print.c:254
+msgid "Group Flags :"
+msgstr ""
+
+#: nis/nis_print.c:257
+msgid ""
+"\n"
+"Group Members :\n"
+msgstr ""
+
+#: nis/nis_print.c:269
+#, c-format
+msgid "Table Type : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:270
+#, c-format
+msgid "Number of Columns : %d\n"
+msgstr ""
+
+#: nis/nis_print.c:271
+#, c-format
+msgid "Character Separator : %c\n"
+msgstr ""
+
+#: nis/nis_print.c:272
+#, c-format
+msgid "Search Path : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:273
+msgid "Columns :\n"
+msgstr ""
+
+#: nis/nis_print.c:276
+#, c-format
+msgid "\t[%d]\tName : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:278
+msgid "\t\tAttributes : "
+msgstr ""
+
+#: nis/nis_print.c:280
+msgid "\t\tAccess Rights : "
+msgstr ""
+
+#: nis/nis_print.c:290
+msgid "Linked Object Type : "
+msgstr ""
+
+#: nis/nis_print.c:292
+#, c-format
+msgid "Linked to : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:302
+#, c-format
+msgid "\tEntry data of type %s\n"
+msgstr ""
+
+#: nis/nis_print.c:305
+#, c-format
+msgid "\t[%u] - [%u bytes] "
+msgstr ""
+
+#: nis/nis_print.c:308
+msgid "Encrypted data\n"
+msgstr ""
+
+#: nis/nis_print.c:310
+msgid "Binary data\n"
+msgstr ""
+
+#: nis/nis_print.c:326
+#, c-format
+msgid "Object Name : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:327
+#, c-format
+msgid "Directory : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:328
+#, c-format
+msgid "Owner : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:329
+#, c-format
+msgid "Group : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:330
+msgid "Access Rights : "
+msgstr ""
+
+#: nis/nis_print.c:332
+#, c-format
+msgid ""
+"\n"
+"Time to Live : "
+msgstr ""
+
+#: nis/nis_print.c:335
+#, c-format
+msgid "Creation Time : %s"
+msgstr ""
+
+#: nis/nis_print.c:337
+#, c-format
+msgid "Mod. Time : %s"
+msgstr ""
+
+#: nis/nis_print.c:338
+msgid "Object Type : "
+msgstr ""
+
+#: nis/nis_print.c:358
+#, c-format
+msgid " Data Length = %u\n"
+msgstr ""
+
+#: nis/nis_print.c:372
+#, c-format
+msgid "Status : %s\n"
+msgstr ""
+
+#: nis/nis_print.c:373
+#, c-format
+msgid "Number of objects : %u\n"
+msgstr ""
+
+#: nis/nis_print.c:377
+#, c-format
+msgid "Object #%d:\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:117
+#, c-format
+msgid "Group entry for \"%s.%s\" group:\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:125
+msgid " Explicit members:\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:130
+msgid " No explicit members\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:133
+msgid " Implicit members:\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:138
+msgid " No implicit members\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:141
+msgid " Recursive members:\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:146
+msgid " No recursive members\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:149
+msgid " Explicit nonmembers:\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:154
+msgid " No explicit nonmembers\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:157
+msgid " Implicit nonmembers:\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:162
+msgid " No implicit nonmembers\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:165
+msgid " Recursive nonmembers:\n"
+msgstr ""
+
+#: nis/nis_print_group_entry.c:170
+msgid " No recursive nonmembers\n"
+msgstr ""
+
+#: nis/nss_nisplus/nisplus-publickey.c:101
+#: nis/nss_nisplus/nisplus-publickey.c:183
+#, c-format
+msgid "DES entry for netname %s not unique\n"
+msgstr ""
+
+#: nis/nss_nisplus/nisplus-publickey.c:220
+#, c-format
+msgid "netname2user: missing group id list in `%s'"
+msgstr ""
+
+#: nis/nss_nisplus/nisplus-publickey.c:302
+#: nis/nss_nisplus/nisplus-publickey.c:308
+#: nis/nss_nisplus/nisplus-publickey.c:373
+#: nis/nss_nisplus/nisplus-publickey.c:382
+#, c-format
+msgid "netname2user: (nis+ lookup): %s\n"
+msgstr ""
+
+#: nis/nss_nisplus/nisplus-publickey.c:321
+#, c-format
+msgid "netname2user: DES entry for %s in directory %s not unique"
+msgstr ""
+
+#: nis/nss_nisplus/nisplus-publickey.c:339
+#, c-format
+msgid "netname2user: principal name `%s' too long"
+msgstr ""
+
+#: nis/nss_nisplus/nisplus-publickey.c:395
+#, c-format
+msgid "netname2user: LOCAL entry for %s in directory %s not unique"
+msgstr ""
+
+#: nis/nss_nisplus/nisplus-publickey.c:402
+msgid "netname2user: should not have uid 0"
+msgstr ""
+
+#: nis/ypclnt.c:825
+#, fuzzy
+msgid "Request arguments bad"
+msgstr "Užklausa nenutraukta"
+
+#: nis/ypclnt.c:828
+msgid "RPC failure on NIS operation"
+msgstr ""
+
+#: nis/ypclnt.c:831
+msgid "Can't bind to server which serves this domain"
+msgstr ""
+
+#: nis/ypclnt.c:834
+msgid "No such map in server's domain"
+msgstr ""
+
+#: nis/ypclnt.c:837
+#, fuzzy
+msgid "No such key in map"
+msgstr "Tokio įrenginio nėra"
+
+#: nis/ypclnt.c:840
+#, fuzzy
+msgid "Internal NIS error"
+msgstr "Vardų paieškos vidinė klaida"
+
+#: nis/ypclnt.c:843
+#, fuzzy
+msgid "Local resource allocation failure"
+msgstr "Sistemos resursų išskyrimo sutrikimas"
+
+#: nis/ypclnt.c:846
+#, fuzzy
+msgid "No more records in map database"
+msgstr "skaitant duomenų bazę"
+
+#: nis/ypclnt.c:849
+msgid "Can't communicate with portmapper"
+msgstr ""
+
+#: nis/ypclnt.c:852
+msgid "Can't communicate with ypbind"
+msgstr ""
+
+#: nis/ypclnt.c:855
+msgid "Can't communicate with ypserv"
+msgstr ""
+
+#: nis/ypclnt.c:858
+msgid "Local domain name not set"
+msgstr ""
+
+#: nis/ypclnt.c:861
+#, fuzzy
+msgid "NIS map database is bad"
+msgstr "Duomenų bazė užimta"
+
+#: nis/ypclnt.c:864
+msgid "NIS client/server version mismatch - can't supply service"
+msgstr ""
+
+#: nis/ypclnt.c:870
+msgid "Database is busy"
+msgstr "Duomenų bazė užimta"
+
+#: nis/ypclnt.c:873
+#, fuzzy
+msgid "Unknown NIS error code"
+msgstr "Nežinoma klaida "
+
+#: nis/ypclnt.c:913
+msgid "Internal ypbind error"
+msgstr ""
+
+#: nis/ypclnt.c:916
+#, fuzzy
+msgid "Domain not bound"
+msgstr "%s: komanda nerasta"
+
+#: nis/ypclnt.c:919
+msgid "System resource allocation failure"
+msgstr "Sistemos resursų išskyrimo sutrikimas"
+
+#: nis/ypclnt.c:922
+#, fuzzy
+msgid "Unknown ypbind error"
+msgstr "Nežinoma klaida"
+
+#: nis/ypclnt.c:963
+msgid "yp_update: cannot convert host to netname\n"
+msgstr ""
+
+#: nis/ypclnt.c:981
+msgid "yp_update: cannot get server address\n"
+msgstr ""
+
+#: nscd/aicache.c:77 nscd/hstcache.c:468
+#, c-format
+msgid "Haven't found \"%s\" in hosts cache!"
+msgstr ""
+
+#: nscd/aicache.c:79 nscd/hstcache.c:470
+#, c-format
+msgid "Reloading \"%s\" in hosts cache!"
+msgstr ""
+
+#: nscd/cache.c:146
+#, c-format
+msgid "add new entry \"%s\" of type %s for %s to cache%s"
+msgstr ""
+
+#: nscd/cache.c:148
+msgid " (first)"
+msgstr ""
+
+#: nscd/cache.c:256 nscd/connections.c:810
+#, fuzzy, c-format
+msgid "cannot stat() file `%s': %s"
+msgstr "nepavyko atverti duomenų bazės failo „%s“: %s"
+
+#: nscd/cache.c:285
+#, c-format
+msgid "pruning %s cache; time %ld"
+msgstr ""
+
+#: nscd/cache.c:312
+#, c-format
+msgid "considering %s entry \"%s\", timeout %<PRIu64>"
+msgstr ""
+
+#: nscd/connections.c:521 nscd/connections.c:533 nscd/connections.c:545
+#: nscd/connections.c:564
+#, fuzzy, c-format
+msgid "invalid persistent database file \"%s\": %s"
+msgstr "nepavyko atverti duomenų bazės failo „%s“: %s"
+
+#: nscd/connections.c:535
+msgid "header size does not match"
+msgstr ""
+
+#: nscd/connections.c:547
+#, fuzzy
+msgid "file size does not match"
+msgstr "ELF failo versija neatitinka esamos"
+
+#: nscd/connections.c:566
+#, fuzzy
+msgid "verification failed"
+msgstr "Operacija nutraukta"
+
+#: nscd/connections.c:580
+#, c-format
+msgid "suggested size of table for database %s larger than the persistent database's table"
+msgstr ""
+
+#: nscd/connections.c:591 nscd/connections.c:673
+#, c-format
+msgid "cannot create read-only descriptor for \"%s\"; no mmap"
+msgstr ""
+
+#: nscd/connections.c:652
+#, c-format
+msgid "database for %s corrupted or simultaneously used; remove %s manually if necessary and restart"
+msgstr ""
+
+#: nscd/connections.c:659
+#, c-format
+msgid "cannot create %s; no persistent database used"
+msgstr ""
+
+#: nscd/connections.c:662
+#, fuzzy, c-format
+msgid "cannot create %s; no sharing possible"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: nscd/connections.c:733
+#, fuzzy, c-format
+msgid "cannot write to database file %s: %s"
+msgstr "nepavyko atverti duomenų bazės failo „%s“: %s"
+
+#: nscd/connections.c:772
+#, c-format
+msgid "cannot set socket to close on exec: %s; disabling paranoia mode"
+msgstr ""
+
+#: nscd/connections.c:823
+#, fuzzy, c-format
+msgid "cannot open socket: %s"
+msgstr "nepavyko atverti bendrojo objekto failo"
+
+#: nscd/connections.c:840
+#, c-format
+msgid "cannot change socket to nonblocking mode: %s"
+msgstr ""
+
+#: nscd/connections.c:848
+#, fuzzy, c-format
+msgid "cannot set socket to close on exec: %s"
+msgstr "nepavyko sukurti laikino failo „here“ dokumentui: %s"
+
+#: nscd/connections.c:859
+#, c-format
+msgid "cannot enable socket to accept connections: %s"
+msgstr ""
+
+#: nscd/connections.c:955
+#, c-format
+msgid "provide access to FD %d, for %s"
+msgstr ""
+
+#: nscd/connections.c:967
+#, c-format
+msgid "cannot handle old request version %d; current version is %d"
+msgstr ""
+
+#: nscd/connections.c:1009 nscd/connections.c:1062
+#, fuzzy, c-format
+msgid "cannot write result: %s"
+msgstr "%s:%u: nepavyko perskaityti aplanko %s"
+
+#: nscd/connections.c:1145
+#, fuzzy, c-format
+msgid "error getting caller's id: %s"
+msgstr "rašomas %s"
+
+#: nscd/connections.c:1204
+#, c-format
+msgid "cannot open /proc/self/cmdline: %s; disabling paranoia mode"
+msgstr ""
+
+#: nscd/connections.c:1218
+#, c-format
+msgid "cannot read /proc/self/cmdline: %s; disabling paranoia mode"
+msgstr ""
+
+#: nscd/connections.c:1258
+#, c-format
+msgid "cannot change to old UID: %s; disabling paranoia mode"
+msgstr ""
+
+#: nscd/connections.c:1268
+#, c-format
+msgid "cannot change to old GID: %s; disabling paranoia mode"
+msgstr ""
+
+#: nscd/connections.c:1281
+#, c-format
+msgid "cannot change to old working directory: %s; disabling paranoia mode"
+msgstr ""
+
+#: nscd/connections.c:1310
+#, c-format
+msgid "re-exec failed: %s; disabling paranoia mode"
+msgstr ""
+
+#: nscd/connections.c:1319
+#, fuzzy, c-format
+msgid "cannot change current working directory to \"/\": %s"
+msgstr "<nÄ—ra esamo aplanko>"
+
+#: nscd/connections.c:1437
+#, fuzzy, c-format
+msgid "short read while reading request: %s"
+msgstr "problemos skaitant „%s“"
+
+#: nscd/connections.c:1468
+#, c-format
+msgid "key length in request too long: %d"
+msgstr ""
+
+#: nscd/connections.c:1481
+#, c-format
+msgid "short read while reading request key: %s"
+msgstr ""
+
+#: nscd/connections.c:1490
+#, c-format
+msgid "handle_request: request received (Version = %d) from PID %ld"
+msgstr ""
+
+#: nscd/connections.c:1495
+#, c-format
+msgid "handle_request: request received (Version = %d)"
+msgstr ""
+
+#: nscd/connections.c:1856
+#, c-format
+msgid "could only start %d threads; terminating"
+msgstr ""
+
+#: nscd/connections.c:1904 nscd/connections.c:1905 nscd/connections.c:1922
+#: nscd/connections.c:1931 nscd/connections.c:1949 nscd/connections.c:1960
+#: nscd/connections.c:1971
+#, c-format
+msgid "Failed to run nscd as user '%s'"
+msgstr ""
+
+#: nscd/connections.c:1923
+#, c-format
+msgid "initial getgrouplist failed"
+msgstr ""
+
+#: nscd/connections.c:1932
+#, c-format
+msgid "getgrouplist failed"
+msgstr ""
+
+#: nscd/connections.c:1950
+#, c-format
+msgid "setgroups failed"
+msgstr ""
+
+#: nscd/grpcache.c:402 nscd/hstcache.c:418 nscd/initgrcache.c:412
+#: nscd/pwdcache.c:397 nscd/servicescache.c:343
+#, fuzzy, c-format
+msgid "short write in %s: %s"
+msgstr "%s: Klaida rašant %s\n"
+
+#: nscd/grpcache.c:445 nscd/initgrcache.c:78
+#, c-format
+msgid "Haven't found \"%s\" in group cache!"
+msgstr ""
+
+#: nscd/grpcache.c:447 nscd/initgrcache.c:80
+#, c-format
+msgid "Reloading \"%s\" in group cache!"
+msgstr ""
+
+#: nscd/grpcache.c:524
+#, fuzzy, c-format
+msgid "Invalid numeric gid \"%s\"!"
+msgstr "nekorektiška eilutė"
+
+#: nscd/mem.c:383
+#, c-format
+msgid "freed %zu bytes in %s cache"
+msgstr ""
+
+#: nscd/mem.c:512
+#, c-format
+msgid "no more memory for database '%s'"
+msgstr ""
+
+#: nscd/nscd.c:98
+msgid "Read configuration data from NAME"
+msgstr ""
+
+#: nscd/nscd.c:100
+msgid "Do not fork and display messages on the current tty"
+msgstr ""
+
+#: nscd/nscd.c:101
+#, fuzzy
+msgid "NUMBER"
+msgstr "PAVADINIMAS"
+
+#: nscd/nscd.c:101
+msgid "Start NUMBER threads"
+msgstr ""
+
+#: nscd/nscd.c:102
+msgid "Shut the server down"
+msgstr ""
+
+#: nscd/nscd.c:103
+#, fuzzy
+msgid "Print current configuration statistic"
+msgstr "Nepavyko atverti konfigūracijos failo %s"
+
+#: nscd/nscd.c:104
+msgid "TABLE"
+msgstr ""
+
+#: nscd/nscd.c:105
+#, fuzzy
+msgid "Invalidate the specified cache"
+msgstr "%s: netaisyklingas parametras --%c\n"
+
+#: nscd/nscd.c:106
+msgid "TABLE,yes"
+msgstr ""
+
+#: nscd/nscd.c:107
+msgid "Use separate cache for each user"
+msgstr ""
+
+#: nscd/nscd.c:112
+msgid "Name Service Cache Daemon."
+msgstr ""
+
+#: nscd/nscd.c:144 nss/getent.c:858 nss/makedb.c:123
+#, fuzzy, c-format
+msgid "wrong number of arguments"
+msgstr "per daug argumentų"
+
+#: nscd/nscd.c:154
+#, c-format
+msgid "failure while reading configuration file; this is fatal"
+msgstr ""
+
+#: nscd/nscd.c:163
+#, c-format
+msgid "already running"
+msgstr ""
+
+#: nscd/nscd.c:178 nscd/nscd.c:233
+#, c-format
+msgid "cannot fork"
+msgstr ""
+
+#: nscd/nscd.c:241
+#, fuzzy, c-format
+msgid "cannot change current working directory to \"/\""
+msgstr "<nÄ—ra esamo aplanko>"
+
+#: nscd/nscd.c:249
+msgid "Could not create log file"
+msgstr ""
+
+#: nscd/nscd.c:302 nscd/nscd.c:327 nscd/nscd_stat.c:172
+#, c-format
+msgid "Only root is allowed to use this option!"
+msgstr ""
+
+#: nscd/nscd.c:364 nscd/nscd_stat.c:191
+#, c-format
+msgid "write incomplete"
+msgstr ""
+
+#: nscd/nscd.c:375
+#, fuzzy, c-format
+msgid "cannot read invalidate ACK"
+msgstr "nepavyko nuskaityti failo duomenų"
+
+#: nscd/nscd.c:381
+#, fuzzy, c-format
+msgid "invalidation failed"
+msgstr "netinkamas mÄ—nesio pavadinimas"
+
+#: nscd/nscd.c:391
+#, c-format
+msgid "secure services not implemented anymore"
+msgstr ""
+
+#: nscd/nscd_conf.c:57
+#, fuzzy, c-format
+msgid "database %s is not supported"
+msgstr "Duomenų bazės %s formatas yra %s.\n"
+
+#: nscd/nscd_conf.c:108
+#, fuzzy, c-format
+msgid "Parse error: %s"
+msgstr "vidinÄ— klaida"
+
+#: nscd/nscd_conf.c:193
+#, c-format
+msgid "Must specify user name for server-user option"
+msgstr ""
+
+#: nscd/nscd_conf.c:200
+#, c-format
+msgid "Must specify user name for stat-user option"
+msgstr ""
+
+#: nscd/nscd_conf.c:244
+#, c-format
+msgid "invalid value for 'reload-count': %u"
+msgstr ""
+
+#: nscd/nscd_conf.c:259
+#, c-format
+msgid "Must specify value for restart-interval option"
+msgstr ""
+
+#: nscd/nscd_conf.c:273
+#, c-format
+msgid "Unknown option: %s %s %s"
+msgstr ""
+
+#: nscd/nscd_conf.c:286
+#, c-format
+msgid "cannot get current working directory: %s; disabling paranoia mode"
+msgstr ""
+
+#: nscd/nscd_conf.c:306
+#, c-format
+msgid "maximum file size for %s database too small"
+msgstr ""
+
+#: nscd/nscd_stat.c:141
+#, fuzzy, c-format
+msgid "cannot write statistics: %s"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: nscd/nscd_stat.c:156
+msgid "yes"
+msgstr ""
+
+#: nscd/nscd_stat.c:157
+msgid "no"
+msgstr ""
+
+#: nscd/nscd_stat.c:168
+#, c-format
+msgid "Only root or %s is allowed to use this option!"
+msgstr ""
+
+#: nscd/nscd_stat.c:179
+#, c-format
+msgid "nscd not running!\n"
+msgstr ""
+
+#: nscd/nscd_stat.c:203
+#, fuzzy, c-format
+msgid "cannot read statistics data"
+msgstr "nepavyko nuskaityti failo duomenų"
+
+#: nscd/nscd_stat.c:206
+#, c-format
+msgid ""
+"nscd configuration:\n"
+"\n"
+"%15d server debug level\n"
+msgstr ""
+
+#: nscd/nscd_stat.c:230
+#, c-format
+msgid "%3ud %2uh %2um %2lus server runtime\n"
+msgstr ""
+
+#: nscd/nscd_stat.c:233
+#, c-format
+msgid " %2uh %2um %2lus server runtime\n"
+msgstr ""
+
+#: nscd/nscd_stat.c:235
+#, c-format
+msgid " %2um %2lus server runtime\n"
+msgstr ""
+
+#: nscd/nscd_stat.c:237
+#, c-format
+msgid " %2lus server runtime\n"
+msgstr ""
+
+#: nscd/nscd_stat.c:239
+#, c-format
+msgid ""
+"%15d current number of threads\n"
+"%15d maximum number of threads\n"
+"%15lu number of times clients had to wait\n"
+"%15s paranoia mode enabled\n"
+"%15lu restart internal\n"
+msgstr ""
+
+#: nscd/nscd_stat.c:273
+#, c-format
+msgid ""
+"\n"
+"%s cache:\n"
+"\n"
+"%15s cache is enabled\n"
+"%15s cache is persistent\n"
+"%15s cache is shared\n"
+"%15zu suggested size\n"
+"%15zu total data pool size\n"
+"%15zu used data pool size\n"
+"%15lu seconds time to live for positive entries\n"
+"%15lu seconds time to live for negative entries\n"
+"%15<PRIuMAX> cache hits on positive entries\n"
+"%15<PRIuMAX> cache hits on negative entries\n"
+"%15<PRIuMAX> cache misses on positive entries\n"
+"%15<PRIuMAX> cache misses on negative entries\n"
+"%15lu%% cache hit rate\n"
+"%15zu current number of cached values\n"
+"%15zu maximum number of cached values\n"
+"%15zu maximum chain length searched\n"
+"%15<PRIuMAX> number of delays on rdlock\n"
+"%15<PRIuMAX> number of delays on wrlock\n"
+"%15<PRIuMAX> memory allocations failed\n"
+"%15s check /etc/%s for changes\n"
+msgstr ""
+
+#: nscd/pwdcache.c:440
+#, c-format
+msgid "Haven't found \"%s\" in password cache!"
+msgstr ""
+
+#: nscd/pwdcache.c:442
+#, c-format
+msgid "Reloading \"%s\" in password cache!"
+msgstr ""
+
+#: nscd/pwdcache.c:520
+#, fuzzy, c-format
+msgid "Invalid numeric uid \"%s\"!"
+msgstr "nekorektiška eilutė"
+
+#: nscd/selinux.c:156
+#, c-format
+msgid "Failed opening connection to the audit subsystem: %m"
+msgstr ""
+
+#: nscd/selinux.c:177
+msgid "Failed to set keep-capabilities"
+msgstr ""
+
+#: nscd/selinux.c:178 nscd/selinux.c:241
+#, c-format
+msgid "prctl(KEEPCAPS) failed"
+msgstr ""
+
+#: nscd/selinux.c:192
+msgid "Failed to initialize drop of capabilities"
+msgstr ""
+
+#: nscd/selinux.c:193
+#, c-format
+msgid "cap_init failed"
+msgstr ""
+
+#: nscd/selinux.c:214 nscd/selinux.c:231
+msgid "Failed to drop capabilities"
+msgstr ""
+
+#: nscd/selinux.c:215 nscd/selinux.c:232
+#, c-format
+msgid "cap_set_proc failed"
+msgstr ""
+
+#: nscd/selinux.c:240
+msgid "Failed to unset keep-capabilities"
+msgstr ""
+
+#: nscd/selinux.c:256
+msgid "Failed to determine if kernel supports SELinux"
+msgstr ""
+
+#: nscd/selinux.c:271
+#, c-format
+msgid "Failed to start AVC thread"
+msgstr ""
+
+#: nscd/selinux.c:293
+#, c-format
+msgid "Failed to create AVC lock"
+msgstr ""
+
+#: nscd/selinux.c:333
+#, fuzzy, c-format
+msgid "Failed to start AVC"
+msgstr "failas per trumpas"
+
+#: nscd/selinux.c:335
+msgid "Access Vector Cache (AVC) started"
+msgstr ""
+
+#: nscd/selinux.c:356
+msgid "Error getting context of socket peer"
+msgstr ""
+
+#: nscd/selinux.c:361
+msgid "Error getting context of nscd"
+msgstr ""
+
+#: nscd/selinux.c:367
+msgid "Error getting sid from context"
+msgstr ""
+
+#: nscd/selinux.c:399
+#, c-format
+msgid ""
+"\n"
+"SELinux AVC Statistics:\n"
+"\n"
+"%15u entry lookups\n"
+"%15u entry hits\n"
+"%15u entry misses\n"
+"%15u entry discards\n"
+"%15u CAV lookups\n"
+"%15u CAV hits\n"
+"%15u CAV probes\n"
+"%15u CAV misses\n"
+msgstr ""
+
+#: nscd/servicescache.c:390
+#, c-format
+msgid "Haven't found \"%s\" in services cache!"
+msgstr ""
+
+#: nscd/servicescache.c:392
+#, c-format
+msgid "Reloading \"%s\" in services cache!"
+msgstr ""
+
+#: nss/getent.c:52
+msgid "database [key ...]"
+msgstr ""
+
+#: nss/getent.c:57
+msgid "Service configuration to be used"
+msgstr ""
+
+#: nss/getent.c:62
+msgid ""
+"Get entries from administrative database.\vFor bug reporting instructions, please see:\n"
+"<http://www.gnu.org/software/libc/bugs.html>.\n"
+msgstr ""
+
+#: nss/getent.c:145 nss/getent.c:394
+#, fuzzy, c-format
+msgid "Enumeration not supported on %s\n"
+msgstr "Operacija nepalaikoma"
+
+#: nss/getent.c:782
+#, c-format
+msgid "Unknown database name"
+msgstr "Nežinomas duomenų bazės vardas"
+
+#: nss/getent.c:808
+msgid "Supported databases:\n"
+msgstr "Palaikomos duomenų bazės:\n"
+
+#: nss/getent.c:868
+#, c-format
+msgid "Unknown database: %s\n"
+msgstr "Nežinoma duomenų bazė: %s\n"
+
+#: nss/makedb.c:60
+msgid "Convert key to lower case"
+msgstr ""
+
+#: nss/makedb.c:63
+msgid "Do not print messages while building database"
+msgstr ""
+
+#: nss/makedb.c:65
+msgid "Print content of database file, one entry a line"
+msgstr ""
+
+#: nss/makedb.c:70
+msgid "Create simple DB database from textual input."
+msgstr ""
+
+#: nss/makedb.c:73
+#, fuzzy
+msgid ""
+"INPUT-FILE OUTPUT-FILE\n"
+"-o OUTPUT-FILE INPUT-FILE\n"
+"-u INPUT-FILE"
+msgstr ""
+"-o IŠVEDIMO-FAILAS [DUOMENŲ-FAILAS]...\n"
+"[IŠVEDIMO-FAILAS [DUOMENŲ-FAILAS]...]"
+
+#: nss/makedb.c:142
+#, c-format
+msgid "No usable database library found."
+msgstr ""
+
+#: nss/makedb.c:149
+#, c-format
+msgid "cannot open database file `%s': %s"
+msgstr "nepavyko atverti duomenų bazės failo „%s“: %s"
+
+#: nss/makedb.c:151
+msgid "incorrectly formatted file"
+msgstr "netaisyklingas failo formatas"
+
+#: nss/makedb.c:331
+msgid "duplicate key"
+msgstr ""
+
+#: nss/makedb.c:337
+#, c-format
+msgid "while writing database file"
+msgstr "rašant duomenų bazės failą"
+
+#: nss/makedb.c:348
+#, c-format
+msgid "problems while reading `%s'"
+msgstr "problemos skaitant „%s“"
+
+#: nss/makedb.c:368 nss/makedb.c:385
+#, c-format
+msgid "while reading database"
+msgstr "skaitant duomenų bazę"
+
+#: posix/getconf.c:945
+#, c-format
+msgid "Usage: %s [-v specification] variable_name [pathname]\n"
+msgstr ""
+
+#: posix/getconf.c:948
+#, c-format
+msgid " %s -a [pathname]\n"
+msgstr ""
+
+#: posix/getconf.c:1067
+#, fuzzy, c-format
+msgid "unknown specification \"%s\""
+msgstr "nežinomas predikatas „%s“"
+
+#: posix/getconf.c:1095
+#, c-format
+msgid "Couldn't execute %s"
+msgstr "Nepavyko paleisti %s"
+
+#: posix/getconf.c:1135 posix/getconf.c:1151
+msgid "undefined"
+msgstr "neapibrėžta"
+
+#: posix/getconf.c:1173
+#, c-format
+msgid "Unrecognized variable `%s'"
+msgstr "Neatpažintas kintamasis „%s“"
+
+#: posix/getopt.c:571 posix/getopt.c:587
+#, c-format
+msgid "%s: option `%s' is ambiguous\n"
+msgstr "%s: parametras „%s“ dviprasmis\n"
+
+#: posix/getopt.c:620 posix/getopt.c:624
+#, c-format
+msgid "%s: option `--%s' doesn't allow an argument\n"
+msgstr "%s: parametras „--%s“ neleidžia argumento\n"
+
+#: posix/getopt.c:633 posix/getopt.c:638
+#, c-format
+msgid "%s: option `%c%s' doesn't allow an argument\n"
+msgstr "%s: parametras „%c%s“ neleidžia argumento\n"
+
+#: posix/getopt.c:681 posix/getopt.c:700 posix/getopt.c:1016
+#: posix/getopt.c:1035
+#, c-format
+msgid "%s: option `%s' requires an argument\n"
+msgstr ""
+
+#: posix/getopt.c:738 posix/getopt.c:741
+#, c-format
+msgid "%s: unrecognized option `--%s'\n"
+msgstr "%s: neatpažintas parametras „--%s“\n"
+
+#: posix/getopt.c:749 posix/getopt.c:752
+#, c-format
+msgid "%s: unrecognized option `%c%s'\n"
+msgstr "%s: neatpažintas parametras „%c%s“\n"
+
+#: posix/getopt.c:804 posix/getopt.c:807
+#, c-format
+msgid "%s: illegal option -- %c\n"
+msgstr "%s: netinkamas parametras -- %c\n"
+
+#: posix/getopt.c:813 posix/getopt.c:816
+#, c-format
+msgid "%s: invalid option -- %c\n"
+msgstr ""
+
+#: posix/getopt.c:868 posix/getopt.c:884 posix/getopt.c:1088
+#: posix/getopt.c:1106
+#, c-format
+msgid "%s: option requires an argument -- %c\n"
+msgstr "%s: parametrui reikia argumento -- %c\n"
+
+#: posix/getopt.c:937 posix/getopt.c:953
+#, c-format
+msgid "%s: option `-W %s' is ambiguous\n"
+msgstr "%s: parametras „-W %s“ dviprasmis\n"
+
+#: posix/getopt.c:977 posix/getopt.c:995
+#, c-format
+msgid "%s: option `-W %s' doesn't allow an argument\n"
+msgstr "%s: parametras „-W %s“ neleidžia argumento\n"
+
+#: posix/regcomp.c:135
+msgid "No match"
+msgstr ""
+
+#: posix/regcomp.c:138
+msgid "Invalid regular expression"
+msgstr "Netaisyklinga reguliarioji išraiška"
+
+#: posix/regcomp.c:141
+msgid "Invalid collation character"
+msgstr ""
+
+#: posix/regcomp.c:144
+msgid "Invalid character class name"
+msgstr ""
+
+#: posix/regcomp.c:147
+msgid "Trailing backslash"
+msgstr ""
+
+#: posix/regcomp.c:150
+msgid "Invalid back reference"
+msgstr ""
+
+#: posix/regcomp.c:153
+msgid "Unmatched [ or [^"
+msgstr ""
+
+#: posix/regcomp.c:156
+msgid "Unmatched ( or \\("
+msgstr ""
+
+#: posix/regcomp.c:159
+msgid "Unmatched \\{"
+msgstr ""
+
+#: posix/regcomp.c:162
+msgid "Invalid content of \\{\\}"
+msgstr ""
+
+#: posix/regcomp.c:165
+msgid "Invalid range end"
+msgstr ""
+
+#: posix/regcomp.c:168
+msgid "Memory exhausted"
+msgstr "BaigÄ—si atmintis"
+
+#: posix/regcomp.c:171
+msgid "Invalid preceding regular expression"
+msgstr ""
+
+#: posix/regcomp.c:174
+msgid "Premature end of regular expression"
+msgstr ""
+
+#: posix/regcomp.c:177
+msgid "Regular expression too big"
+msgstr ""
+
+#: posix/regcomp.c:180
+msgid "Unmatched ) or \\)"
+msgstr "Nesuderintas ) arba \\)"
+
+#: posix/regcomp.c:660
+msgid "No previous regular expression"
+msgstr ""
+
+#: posix/wordexp.c:1798
+#, fuzzy
+msgid "parameter null or not set"
+msgstr "%s: parametras tuÅ¡Äias arba nenustatytas"
+
+#: resolv/herror.c:68
+msgid "Resolver Error 0 (no error)"
+msgstr "Paieškos klaida 0 (jokios klaidos)"
+
+#: resolv/herror.c:69
+msgid "Unknown host"
+msgstr "Nežinomas serveris"
+
+#: resolv/herror.c:70
+msgid "Host name lookup failure"
+msgstr "Adreso paieškos sutrikimas"
+
+#: resolv/herror.c:71
+msgid "Unknown server error"
+msgstr "Nežinoma serverio klaida"
+
+#: resolv/herror.c:72
+msgid "No address associated with name"
+msgstr "Su vardu susietų adresų nėra"
+
+#: resolv/herror.c:107
+msgid "Resolver internal error"
+msgstr "Vardų paieškos vidinė klaida"
+
+#: resolv/herror.c:110
+msgid "Unknown resolver error"
+msgstr "Nežinoma vardų paieškos klaida"
+
+#: resolv/res_hconf.c:124
+#, fuzzy, c-format
+msgid "%s: line %d: cannot specify more than %d trim domains"
+msgstr "%s: apribota: negalima naudoti „/“ komandų pavadinimuose"
+
+#: resolv/res_hconf.c:145
+#, c-format
+msgid "%s: line %d: list delimiter not followed by domain"
+msgstr ""
+
+#: resolv/res_hconf.c:204
+#, fuzzy, c-format
+msgid "%s: line %d: expected `on' or `off', found `%s'\n"
+msgstr "%s: eilutė %d: bloga komanda „%s“\n"
+
+#: resolv/res_hconf.c:247
+#, c-format
+msgid "%s: line %d: bad command `%s'\n"
+msgstr "%s: eilutė %d: bloga komanda „%s“\n"
+
+#: resolv/res_hconf.c:282
+#, c-format
+msgid "%s: line %d: ignoring trailing garbage `%s'\n"
+msgstr ""
+
+#: stdio-common/psignal.c:51
+#, c-format
+msgid "%s%sUnknown signal %d\n"
+msgstr "%s%sNežinomas signalas %d\n"
+
+#: stdio-common/psignal.c:52
+msgid "Unknown signal"
+msgstr "Nežinomas signalas"
+
+#: string/_strerror.c:45 sysdeps/mach/_strerror.c:87
+msgid "Unknown error "
+msgstr "Nežinoma klaida "
+
+#: string/strerror.c:43
+msgid "Unknown error"
+msgstr "Nežinoma klaida"
+
+#: string/strsignal.c:65
+#, fuzzy, c-format
+msgid "Real-time signal %d"
+msgstr "%s: nutrauktas signalo %d"
+
+#: string/strsignal.c:69
+#, c-format
+msgid "Unknown signal %d"
+msgstr "Nežinomas signalas %d"
+
+#: sunrpc/auth_unix.c:114
+msgid "authunix_create: out of memory\n"
+msgstr ""
+
+#: sunrpc/auth_unix.c:350
+msgid "auth_unix.c: Fatal marshalling problem"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:118 sunrpc/clnt_perr.c:139
+#, c-format
+msgid "; low version = %lu, high version = %lu"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:125
+msgid "; why = "
+msgstr "; kodÄ—l ="
+
+#: sunrpc/clnt_perr.c:132
+#, c-format
+msgid "(unknown authentication error - %d)"
+msgstr "(nežinoma autentikacijos klaida - %d)"
+
+#: sunrpc/clnt_perr.c:172
+msgid "RPC: Success"
+msgstr "RPC: SÄ—kmÄ—s"
+
+#: sunrpc/clnt_perr.c:175
+msgid "RPC: Can't encode arguments"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:179
+msgid "RPC: Can't decode result"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:183
+msgid "RPC: Unable to send"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:187
+msgid "RPC: Unable to receive"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:191
+msgid "RPC: Timed out"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:195
+msgid "RPC: Incompatible versions of RPC"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:199
+#, fuzzy
+msgid "RPC: Authentication error"
+msgstr "Autentikacijos klaida"
+
+#: sunrpc/clnt_perr.c:203
+#, fuzzy
+msgid "RPC: Program unavailable"
+msgstr "RPC: Programa neregistruota"
+
+#: sunrpc/clnt_perr.c:207
+#, fuzzy
+msgid "RPC: Program/version mismatch"
+msgstr "netinkama RPC programos versija"
+
+#: sunrpc/clnt_perr.c:211
+#, fuzzy
+msgid "RPC: Procedure unavailable"
+msgstr "Reikalingas raktas nerastas"
+
+#: sunrpc/clnt_perr.c:215
+msgid "RPC: Server can't decode arguments"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:219
+#, fuzzy
+msgid "RPC: Remote system error"
+msgstr "Nutolusio įvedimo/išvedimo klaida"
+
+#: sunrpc/clnt_perr.c:223
+msgid "RPC: Unknown host"
+msgstr "RPC: Nežinomas serveris"
+
+#: sunrpc/clnt_perr.c:227
+#, fuzzy
+msgid "RPC: Unknown protocol"
+msgstr "RPC: Nežinomas serveris"
+
+#: sunrpc/clnt_perr.c:231
+#, fuzzy
+msgid "RPC: Port mapper failure"
+msgstr "Elektros maitinimo sutrikimas"
+
+#: sunrpc/clnt_perr.c:235
+msgid "RPC: Program not registered"
+msgstr "RPC: Programa neregistruota"
+
+#: sunrpc/clnt_perr.c:239
+#, fuzzy
+msgid "RPC: Failed (unspecified error)"
+msgstr "NesÄ—kmÄ— (nenurodyta klaida)"
+
+#: sunrpc/clnt_perr.c:280
+#, fuzzy
+msgid "RPC: (unknown error code)"
+msgstr "Nežinoma klaida "
+
+#: sunrpc/clnt_perr.c:342
+msgid "Authentication OK"
+msgstr "Autentikacija sÄ—kminga"
+
+#: sunrpc/clnt_perr.c:345
+msgid "Invalid client credential"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:349
+msgid "Server rejected credential"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:353
+#, fuzzy
+msgid "Invalid client verifier"
+msgstr "netaisyklingas naudotojas"
+
+#: sunrpc/clnt_perr.c:357
+msgid "Server rejected verifier"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:361
+msgid "Client credential too weak"
+msgstr ""
+
+#: sunrpc/clnt_perr.c:365
+#, fuzzy
+msgid "Invalid server verifier"
+msgstr "nekorektiška eilutė"
+
+#: sunrpc/clnt_perr.c:369
+msgid "Failed (unspecified error)"
+msgstr "NesÄ—kmÄ— (nenurodyta klaida)"
+
+#: sunrpc/clnt_raw.c:117
+msgid "clnt_raw.c: fatal header serialization error"
+msgstr ""
+
+#: sunrpc/clnt_tcp.c:131
+#, fuzzy
+msgid "clnttcp_create: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/clnt_udp.c:139
+#, fuzzy
+msgid "clntudp_create: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/clnt_unix.c:128
+msgid "clntunix_create: out of memory\n"
+msgstr ""
+
+#: sunrpc/pm_getmaps.c:83
+msgid "pmap_getmaps.c: rpc problem"
+msgstr ""
+
+#: sunrpc/pmap_clnt.c:129
+msgid "Cannot register service"
+msgstr "Nepavyko užregistruoti tarnybos"
+
+#: sunrpc/pmap_rmt.c:248
+#, fuzzy
+msgid "Cannot create socket for broadcast rpc"
+msgstr "nepavyko sukurti paieškos sąrašo"
+
+#: sunrpc/pmap_rmt.c:255
+msgid "Cannot set socket option SO_BROADCAST"
+msgstr ""
+
+#: sunrpc/pmap_rmt.c:307
+msgid "Cannot send broadcast packet"
+msgstr ""
+
+#: sunrpc/pmap_rmt.c:332
+msgid "Broadcast poll problem"
+msgstr ""
+
+#: sunrpc/pmap_rmt.c:345
+msgid "Cannot receive reply to broadcast"
+msgstr ""
+
+#: sunrpc/rpc_main.c:286
+#, c-format
+msgid "%s: output would overwrite %s\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:293
+#, c-format
+msgid "%s: unable to open %s: %m\n"
+msgstr "%s: nepavyko atverti %s: %m\n"
+
+#: sunrpc/rpc_main.c:305
+#, fuzzy, c-format
+msgid "%s: while writing output %s: %m"
+msgstr "%s: nepavyko atverti %s: %m\n"
+
+#: sunrpc/rpc_main.c:340
+#, fuzzy, c-format
+msgid "cannot find C preprocessor: %s \n"
+msgstr "nepavyko atverti bendrojo objekto failo"
+
+#: sunrpc/rpc_main.c:348
+msgid "cannot find any C preprocessor (cpp)\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:417
+#, c-format
+msgid "%s: C preprocessor failed with signal %d\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:420
+#, c-format
+msgid "%s: C preprocessor failed with exit code %d\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:460
+#, c-format
+msgid "illegal nettype: `%s'\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1122
+#, c-format
+msgid "rpcgen: too many defines\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1134
+#, c-format
+msgid "rpcgen: arglist coding error\n"
+msgstr ""
+
+#. TRANS: the file will not be removed; this is an
+#. TRANS: informative message.
+#: sunrpc/rpc_main.c:1167
+#, c-format
+msgid "file `%s' already exists and may be overwritten\n"
+msgstr "failas „%s“ jau egzistuoja ir gali būti perrašytas\n"
+
+#: sunrpc/rpc_main.c:1212
+#, fuzzy, c-format
+msgid "Cannot specify more than one input file!\n"
+msgstr "Kelias „%s“ nurodytas daugiau negu vieną kartą"
+
+#: sunrpc/rpc_main.c:1382
+msgid "This implementation doesn't support newstyle or MT-safe code!\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1391
+#, c-format
+msgid "Cannot use netid flag with inetd flag!\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1403
+msgid "Cannot use netid flag without TIRPC!\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1410
+msgid "Cannot use table flags with newstyle!\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1429
+#, c-format
+msgid "\"infile\" is required for template generation flags.\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1434
+#, fuzzy, c-format
+msgid "Cannot have more than one file generation flag!\n"
+msgstr "Kelias „%s“ nurodytas daugiau negu vieną kartą"
+
+#: sunrpc/rpc_main.c:1443
+#, c-format
+msgid "usage: %s infile\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1444
+#, c-format
+msgid "\t%s [-abkCLNTM][-Dname[=value]] [-i size] [-I [-K seconds]] [-Y path] infile\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1446
+#, c-format
+msgid "\t%s [-c | -h | -l | -m | -t | -Sc | -Ss | -Sm] [-o outfile] [infile]\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1448
+#, c-format
+msgid "\t%s [-s nettype]* [-o outfile] [infile]\n"
+msgstr ""
+
+#: sunrpc/rpc_main.c:1449
+#, c-format
+msgid "\t%s [-n netid]* [-o outfile] [infile]\n"
+msgstr ""
+
+#: sunrpc/rpc_scan.c:114
+msgid "constant or identifier expected"
+msgstr ""
+
+#: sunrpc/rpc_scan.c:310
+msgid "illegal character in file: "
+msgstr "netaisyklingas simbolis faile: "
+
+#: sunrpc/rpc_scan.c:349 sunrpc/rpc_scan.c:375
+#, fuzzy
+msgid "unterminated string constant"
+msgstr "neužbaigtas pranešimas"
+
+#: sunrpc/rpc_scan.c:381
+msgid "empty char string"
+msgstr "tuÅ¡Äia simbolių eilutÄ—"
+
+#: sunrpc/rpc_scan.c:523 sunrpc/rpc_scan.c:533
+#, fuzzy
+msgid "preprocessor error"
+msgstr "relokacijos klaida"
+
+#: sunrpc/rpcinfo.c:237 sunrpc/rpcinfo.c:383
+#, fuzzy, c-format
+msgid "program %lu is not available\n"
+msgstr "RPC programa nerasta"
+
+#: sunrpc/rpcinfo.c:264 sunrpc/rpcinfo.c:310 sunrpc/rpcinfo.c:333
+#: sunrpc/rpcinfo.c:407 sunrpc/rpcinfo.c:453 sunrpc/rpcinfo.c:476
+#: sunrpc/rpcinfo.c:510
+#, c-format
+msgid "program %lu version %lu is not available\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:515
+#, c-format
+msgid "program %lu version %lu ready and waiting\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:556 sunrpc/rpcinfo.c:563
+msgid "rpcinfo: can't contact portmapper"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:570
+#, fuzzy
+msgid "No remote programs registered.\n"
+msgstr "RPC: Programa neregistruota"
+
+#: sunrpc/rpcinfo.c:574
+msgid " program vers proto port\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:613
+msgid "(unknown)"
+msgstr "(nežinoma)"
+
+#: sunrpc/rpcinfo.c:637
+#, c-format
+msgid "rpcinfo: broadcast failed: %s\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:658
+msgid "Sorry. You are not root\n"
+msgstr "Atsiprašome. Jūs nesate administratorius\n"
+
+#: sunrpc/rpcinfo.c:665
+#, c-format
+msgid "rpcinfo: Could not delete registration for prog %s version %s\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:674
+msgid "Usage: rpcinfo [ -n portnum ] -u host prognum [ versnum ]\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:676
+msgid " rpcinfo [ -n portnum ] -t host prognum [ versnum ]\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:678
+msgid " rpcinfo -p [ host ]\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:679
+msgid " rpcinfo -b prognum versnum\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:680
+msgid " rpcinfo -d prognum versnum\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:695
+#, c-format
+msgid "rpcinfo: %s is unknown service\n"
+msgstr ""
+
+#: sunrpc/rpcinfo.c:732
+#, c-format
+msgid "rpcinfo: %s is unknown host\n"
+msgstr ""
+
+#: sunrpc/svc_run.c:70
+#, fuzzy
+msgid "svc_run: - out of memory"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/svc_run.c:90
+msgid "svc_run: - poll failed"
+msgstr ""
+
+#: sunrpc/svc_simple.c:87
+#, c-format
+msgid "can't reassign procedure number %ld\n"
+msgstr ""
+
+#: sunrpc/svc_simple.c:97
+msgid "couldn't create an rpc server\n"
+msgstr ""
+
+#: sunrpc/svc_simple.c:105
+#, c-format
+msgid "couldn't register prog %ld vers %ld\n"
+msgstr ""
+
+#: sunrpc/svc_simple.c:113
+#, fuzzy
+msgid "registerrpc: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/svc_simple.c:173
+#, c-format
+msgid "trouble replying to prog %d\n"
+msgstr ""
+
+#: sunrpc/svc_simple.c:182
+#, c-format
+msgid "never registered prog %d\n"
+msgstr ""
+
+#: sunrpc/svc_tcp.c:155
+msgid "svc_tcp.c - tcp socket creation problem"
+msgstr ""
+
+#: sunrpc/svc_tcp.c:170
+msgid "svc_tcp.c - cannot getsockname or listen"
+msgstr ""
+
+#: sunrpc/svc_tcp.c:179
+#, fuzzy
+msgid "svctcp_create: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/svc_tcp.c:218
+msgid "svc_tcp: makefd_xprt: out of memory\n"
+msgstr ""
+
+#: sunrpc/svc_udp.c:128
+msgid "svcudp_create: socket creation problem"
+msgstr ""
+
+#: sunrpc/svc_udp.c:142
+msgid "svcudp_create - cannot getsockname"
+msgstr ""
+
+#: sunrpc/svc_udp.c:152
+#, fuzzy
+msgid "svcudp_create: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/svc_udp.c:174
+msgid "svcudp_create: xp_pad is too small for IP_PKTINFO\n"
+msgstr ""
+
+#: sunrpc/svc_udp.c:474
+msgid "enablecache: cache already enabled"
+msgstr ""
+
+#: sunrpc/svc_udp.c:480
+msgid "enablecache: could not allocate cache"
+msgstr ""
+
+#: sunrpc/svc_udp.c:489
+msgid "enablecache: could not allocate cache data"
+msgstr ""
+
+#: sunrpc/svc_udp.c:497
+msgid "enablecache: could not allocate cache fifo"
+msgstr ""
+
+#: sunrpc/svc_udp.c:532
+#, fuzzy
+msgid "cache_set: victim not found"
+msgstr "%s: komanda nerasta"
+
+#: sunrpc/svc_udp.c:543
+msgid "cache_set: victim alloc failed"
+msgstr ""
+
+#: sunrpc/svc_udp.c:550
+msgid "cache_set: could not allocate new rpc_buffer"
+msgstr ""
+
+#: sunrpc/svc_unix.c:150
+msgid "svc_unix.c - AF_UNIX socket creation problem"
+msgstr ""
+
+#: sunrpc/svc_unix.c:166
+msgid "svc_unix.c - cannot getsockname or listen"
+msgstr ""
+
+#: sunrpc/svc_unix.c:176
+#, fuzzy
+msgid "svcunix_create: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/svc_unix.c:215
+msgid "svc_unix: makefd_xprt: out of memory\n"
+msgstr ""
+
+#: sunrpc/xdr.c:566
+#, fuzzy
+msgid "xdr_bytes: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/xdr.c:718
+#, fuzzy
+msgid "xdr_string: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/xdr_array.c:106
+#, fuzzy
+msgid "xdr_array: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/xdr_rec.c:156
+#, fuzzy
+msgid "xdrrec_create: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sunrpc/xdr_ref.c:86
+#, fuzzy
+msgid "xdr_reference: out of memory\n"
+msgstr "baigÄ—si atmintis"
+
+#: sysdeps/generic/siglist.h:29 sysdeps/unix/siglist.c:27
+msgid "Hangup"
+msgstr ""
+
+#: sysdeps/generic/siglist.h:30 sysdeps/unix/siglist.c:28
+msgid "Interrupt"
+msgstr "Pertraukimas"
+
+#: sysdeps/generic/siglist.h:31 sysdeps/unix/siglist.c:29
+msgid "Quit"
+msgstr "IÅ¡eita"
+
+#: sysdeps/generic/siglist.h:32 sysdeps/unix/siglist.c:30
+msgid "Illegal instruction"
+msgstr "Netaisyklinga instrukcija"
+
+#: sysdeps/generic/siglist.h:33 sysdeps/unix/siglist.c:31
+msgid "Trace/breakpoint trap"
+msgstr ""
+
+#: sysdeps/generic/siglist.h:34
+msgid "Aborted"
+msgstr ""
+
+#: sysdeps/generic/siglist.h:35 sysdeps/unix/siglist.c:34
+msgid "Floating point exception"
+msgstr "Slankaus kablelio klaida"
+
+#: sysdeps/generic/siglist.h:36 sysdeps/unix/siglist.c:35
+msgid "Killed"
+msgstr "Nutraukta"
+
+#: sysdeps/generic/siglist.h:37 sysdeps/unix/siglist.c:36
+msgid "Bus error"
+msgstr "MagistralÄ—s klaida"
+
+#: sysdeps/generic/siglist.h:38 sysdeps/unix/siglist.c:37
+msgid "Segmentation fault"
+msgstr "Segmentavimo klaida"
+
+#. TRANS Broken pipe; there is no process reading from the other end of a pipe.
+#. TRANS Every library function that returns this error code also generates a
+#. TRANS @code{SIGPIPE} signal; this signal terminates the program if not handled
+#. TRANS or blocked. Thus, your program will never actually see @code{EPIPE}
+#. TRANS unless it has handled or blocked @code{SIGPIPE}.
+#: sysdeps/generic/siglist.h:39 sysdeps/gnu/errlist.c:359
+#: sysdeps/unix/siglist.c:39
+msgid "Broken pipe"
+msgstr ""
+
+#: sysdeps/generic/siglist.h:40 sysdeps/unix/siglist.c:40
+msgid "Alarm clock"
+msgstr "Žadintuvas"
+
+#: sysdeps/generic/siglist.h:41 sysdeps/unix/siglist.c:41
+#, fuzzy
+msgid "Terminated"
+msgstr "Užbaigta"
+
+#: sysdeps/generic/siglist.h:42 sysdeps/unix/siglist.c:42
+msgid "Urgent I/O condition"
+msgstr ""
+
+#: sysdeps/generic/siglist.h:43 sysdeps/unix/siglist.c:43
+msgid "Stopped (signal)"
+msgstr "Sustabdyta (signalas)"
+
+#: sysdeps/generic/siglist.h:44 sysdeps/unix/siglist.c:44
+msgid "Stopped"
+msgstr "Sustabdyta"
+
+#: sysdeps/generic/siglist.h:45 sysdeps/unix/siglist.c:45
+msgid "Continued"
+msgstr "Pratęsta"
+
+#: sysdeps/generic/siglist.h:46 sysdeps/unix/siglist.c:46
+#, fuzzy
+msgid "Child exited"
+msgstr "Failas jau egzistuoja"
+
+#: sysdeps/generic/siglist.h:47 sysdeps/unix/siglist.c:47
+#, fuzzy
+msgid "Stopped (tty input)"
+msgstr "Sustabdyta (signalas)"
+
+#: sysdeps/generic/siglist.h:48 sysdeps/unix/siglist.c:48
+msgid "Stopped (tty output)"
+msgstr ""
+
+#: sysdeps/generic/siglist.h:49 sysdeps/unix/siglist.c:49
+msgid "I/O possible"
+msgstr ""
+
+#: sysdeps/generic/siglist.h:50 sysdeps/unix/siglist.c:50
+msgid "CPU time limit exceeded"
+msgstr "Viršyta CPU laiko riba"
+
+#: sysdeps/generic/siglist.h:51 sysdeps/unix/siglist.c:51
+msgid "File size limit exceeded"
+msgstr "Viršyta failo dydžio riba"
+
+#: sysdeps/generic/siglist.h:52 sysdeps/unix/siglist.c:52
+msgid "Virtual timer expired"
+msgstr ""
+
+#: sysdeps/generic/siglist.h:53 sysdeps/unix/siglist.c:53
+msgid "Profiling timer expired"
+msgstr ""
+
+#: sysdeps/generic/siglist.h:54 sysdeps/unix/siglist.c:54
+msgid "Window changed"
+msgstr "Langas pasikeitÄ—"
+
+#: sysdeps/generic/siglist.h:55 sysdeps/unix/siglist.c:56
+msgid "User defined signal 1"
+msgstr "Naudotojo apibrėžtas signalas 1"
+
+#: sysdeps/generic/siglist.h:56 sysdeps/unix/siglist.c:57
+msgid "User defined signal 2"
+msgstr "Naudotojo apibrėžtas signalas 2"
+
+#: sysdeps/generic/siglist.h:60 sysdeps/unix/siglist.c:33
+msgid "EMT trap"
+msgstr "EMT gaudyklÄ—"
+
+#: sysdeps/generic/siglist.h:63 sysdeps/unix/siglist.c:38
+msgid "Bad system call"
+msgstr "Blogas sisteminis kvietimas"
+
+#: sysdeps/generic/siglist.h:66
+msgid "Stack fault"
+msgstr "Steko klaida"
+
+#: sysdeps/generic/siglist.h:69
+msgid "Information request"
+msgstr "Informacijos užklausa"
+
+#: sysdeps/generic/siglist.h:71
+msgid "Power failure"
+msgstr "Elektros maitinimo sutrikimas"
+
+#: sysdeps/generic/siglist.h:74 sysdeps/unix/siglist.c:55
+msgid "Resource lost"
+msgstr "Resursas prarastas"
+
+#. TRANS Operation not permitted; only the owner of the file (or other resource)
+#. TRANS or processes with special privileges can perform the operation.
+#: sysdeps/gnu/errlist.c:25
+msgid "Operation not permitted"
+msgstr "Operacija neleidžiama"
+
+#. TRANS No process matches the specified process ID.
+#: sysdeps/gnu/errlist.c:45
+msgid "No such process"
+msgstr "Tokio proceso nÄ—ra"
+
+#. TRANS Interrupted function call; an asynchronous signal occurred and prevented
+#. TRANS completion of the call. When this happens, you should try the call
+#. TRANS again.
+#. TRANS
+#. TRANS You can choose to have functions resume after a signal that is handled,
+#. TRANS rather than failing with @code{EINTR}; see @ref{Interrupted
+#. TRANS Primitives}.
+#: sysdeps/gnu/errlist.c:60
+msgid "Interrupted system call"
+msgstr "Nutrauktas sistemos iškvietimas"
+
+#. TRANS Input/output error; usually used for physical read or write errors.
+#: sysdeps/gnu/errlist.c:69
+msgid "Input/output error"
+msgstr "Įvedimo/išvedimo klaida"
+
+#. TRANS No such device or address. The system tried to use the device
+#. TRANS represented by a file you specified, and it couldn't find the device.
+#. TRANS This can mean that the device file was installed incorrectly, or that
+#. TRANS the physical device is missing or not correctly attached to the
+#. TRANS computer.
+#: sysdeps/gnu/errlist.c:82
+msgid "No such device or address"
+msgstr "Nėra tokio įrenginio ar adreso"
+
+#. TRANS Argument list too long; used when the arguments passed to a new program
+#. TRANS being executed with one of the @code{exec} functions (@pxref{Executing a
+#. TRANS File}) occupy too much memory space. This condition never arises in the
+#. TRANS GNU system.
+#: sysdeps/gnu/errlist.c:94
+msgid "Argument list too long"
+msgstr "Argumentų sąrašas per ilgas"
+
+#. TRANS Invalid executable file format. This condition is detected by the
+#. TRANS @code{exec} functions; see @ref{Executing a File}.
+#: sysdeps/gnu/errlist.c:104
+#, fuzzy
+msgid "Exec format error"
+msgstr "relokacijos klaida"
+
+#. TRANS Bad file descriptor; for example, I/O on a descriptor that has been
+#. TRANS closed or reading from a descriptor open only for writing (or vice
+#. TRANS versa).
+#: sysdeps/gnu/errlist.c:115
+#, fuzzy
+msgid "Bad file descriptor"
+msgstr "nepavyko užverti failo deskriptoriaus"
+
+#. TRANS There are no child processes. This error happens on operations that are
+#. TRANS supposed to manipulate child processes, when there aren't any processes
+#. TRANS to manipulate.
+#: sysdeps/gnu/errlist.c:126
+#, fuzzy
+msgid "No child processes"
+msgstr "Tokio proceso nÄ—ra"
+
+#. TRANS Deadlock avoided; allocating a system resource would have resulted in a
+#. TRANS deadlock situation. The system does not guarantee that it will notice
+#. TRANS all such situations. This error means you got lucky and the system
+#. TRANS noticed; it might just hang. @xref{File Locks}, for an example.
+#: sysdeps/gnu/errlist.c:138
+msgid "Resource deadlock avoided"
+msgstr ""
+
+#. TRANS No memory available. The system cannot allocate more virtual memory
+#. TRANS because its capacity is full.
+#: sysdeps/gnu/errlist.c:148
+msgid "Cannot allocate memory"
+msgstr "Nepavyko išskirti atminties"
+
+#. TRANS Bad address; an invalid pointer was detected.
+#. TRANS In the GNU system, this error never happens; you get a signal instead.
+#: sysdeps/gnu/errlist.c:167
+msgid "Bad address"
+msgstr "Blogas adresas"
+
+#. TRANS A file that isn't a block special file was given in a situation that
+#. TRANS requires one. For example, trying to mount an ordinary file as a file
+#. TRANS system in Unix gives this error.
+#: sysdeps/gnu/errlist.c:178
+msgid "Block device required"
+msgstr "Reikalingas blokinis įrenginys"
+
+#. TRANS Resource busy; a system resource that can't be shared is already in use.
+#. TRANS For example, if you try to delete a file that is the root of a currently
+#. TRANS mounted filesystem, you get this error.
+#: sysdeps/gnu/errlist.c:189
+msgid "Device or resource busy"
+msgstr "Įrenginys ar resursas užimtas"
+
+#. TRANS File exists; an existing file was specified in a context where it only
+#. TRANS makes sense to specify a new file.
+#: sysdeps/gnu/errlist.c:199
+msgid "File exists"
+msgstr "Failas jau egzistuoja"
+
+#. TRANS An attempt to make an improper link across file systems was detected.
+#. TRANS This happens not only when you use @code{link} (@pxref{Hard Links}) but
+#. TRANS also when you rename a file with @code{rename} (@pxref{Renaming Files}).
+#: sysdeps/gnu/errlist.c:210
+#, fuzzy
+msgid "Invalid cross-device link"
+msgstr "netaisyklingas naudotojas"
+
+#. TRANS The wrong type of device was given to a function that expects a
+#. TRANS particular sort of device.
+#: sysdeps/gnu/errlist.c:220
+msgid "No such device"
+msgstr "Tokio įrenginio nėra"
+
+#. TRANS A file that isn't a directory was specified when a directory is required.
+#: sysdeps/gnu/errlist.c:229
+#, fuzzy
+msgid "Not a directory"
+msgstr "Ne aplankas"
+
+#. TRANS File is a directory; you cannot open a directory for writing,
+#. TRANS or create or remove hard links to it.
+#: sysdeps/gnu/errlist.c:239
+#, fuzzy
+msgid "Is a directory"
+msgstr "Aplankas"
+
+#. TRANS Invalid argument. This is used to indicate various kinds of problems
+#. TRANS with passing the wrong argument to a library function.
+#: sysdeps/gnu/errlist.c:249
+#, fuzzy
+msgid "Invalid argument"
+msgstr "Galimi argumentai:"
+
+#. TRANS The current process has too many files open and can't open any more.
+#. TRANS Duplicate descriptors do count toward this limit.
+#. TRANS
+#. TRANS In BSD and GNU, the number of open files is controlled by a resource
+#. TRANS limit that can usually be increased. If you get this error, you might
+#. TRANS want to increase the @code{RLIMIT_NOFILE} limit or make it unlimited;
+#. TRANS @pxref{Limits on Resources}.
+#: sysdeps/gnu/errlist.c:264
+msgid "Too many open files"
+msgstr "Per daug atvertų failų"
+
+#. TRANS There are too many distinct file openings in the entire system. Note
+#. TRANS that any number of linked channels count as just one file opening; see
+#. TRANS @ref{Linked Channels}. This error never occurs in the GNU system.
+#: sysdeps/gnu/errlist.c:275
+msgid "Too many open files in system"
+msgstr "Sistemoje per daug atvertų failų"
+
+#. TRANS Inappropriate I/O control operation, such as trying to set terminal
+#. TRANS modes on an ordinary file.
+#: sysdeps/gnu/errlist.c:285
+#, fuzzy
+msgid "Inappropriate ioctl for device"
+msgstr "Netinkamas failo tipas ar formatas"
+
+#. TRANS An attempt to execute a file that is currently open for writing, or
+#. TRANS write to a file that is currently being executed. Often using a
+#. TRANS debugger to run a program is considered having it open for writing and
+#. TRANS will cause this error. (The name stands for ``text file busy''.) This
+#. TRANS is not an error in the GNU system; the text is copied as necessary.
+#: sysdeps/gnu/errlist.c:298
+msgid "Text file busy"
+msgstr "Tekstinis failas užimtas"
+
+#. TRANS File too big; the size of a file would be larger than allowed by the system.
+#: sysdeps/gnu/errlist.c:307
+#, fuzzy
+msgid "File too large"
+msgstr "Failas per didelis"
+
+#. TRANS No space left on device; write operation on a file failed because the
+#. TRANS disk is full.
+#: sysdeps/gnu/errlist.c:317
+msgid "No space left on device"
+msgstr "Įrenginyje neliko vietos"
+
+#. TRANS Invalid seek operation (such as on a pipe).
+#: sysdeps/gnu/errlist.c:326
+msgid "Illegal seek"
+msgstr ""
+
+#. TRANS An attempt was made to modify something on a read-only file system.
+#: sysdeps/gnu/errlist.c:335
+msgid "Read-only file system"
+msgstr "Failų sistema tik skaitymui"
+
+#. TRANS Too many links; the link count of a single file would become too large.
+#. TRANS @code{rename} can cause this error if the file being renamed already has
+#. TRANS as many links as it can take (@pxref{Renaming Files}).
+#: sysdeps/gnu/errlist.c:346
+msgid "Too many links"
+msgstr "Per daug nuorodų"
+
+#. TRANS Domain error; used by mathematical functions when an argument value does
+#. TRANS not fall into the domain over which the function is defined.
+#: sysdeps/gnu/errlist.c:369
+msgid "Numerical argument out of domain"
+msgstr "Skaitinis argumentas už apibrėžimo srities"
+
+#. TRANS Range error; used by mathematical functions when the result value is
+#. TRANS not representable because of overflow or underflow.
+#: sysdeps/gnu/errlist.c:379
+msgid "Numerical result out of range"
+msgstr "Skaitinis rezultatas už ribų"
+
+#. TRANS Resource temporarily unavailable; the call might work if you try again
+#. TRANS later. The macro @code{EWOULDBLOCK} is another name for @code{EAGAIN};
+#. TRANS they are always the same in the GNU C library.
+#. TRANS
+#. TRANS This error can happen in a few different situations:
+#. TRANS
+#. TRANS @itemize @bullet
+#. TRANS @item
+#. TRANS An operation that would block was attempted on an object that has
+#. TRANS non-blocking mode selected. Trying the same operation again will block
+#. TRANS until some external condition makes it possible to read, write, or
+#. TRANS connect (whatever the operation). You can use @code{select} to find out
+#. TRANS when the operation will be possible; @pxref{Waiting for I/O}.
+#. TRANS
+#. TRANS @strong{Portability Note:} In many older Unix systems, this condition
+#. TRANS was indicated by @code{EWOULDBLOCK}, which was a distinct error code
+#. TRANS different from @code{EAGAIN}. To make your program portable, you should
+#. TRANS check for both codes and treat them the same.
+#. TRANS
+#. TRANS @item
+#. TRANS A temporary resource shortage made an operation impossible. @code{fork}
+#. TRANS can return this error. It indicates that the shortage is expected to
+#. TRANS pass, so your program can try the call again later and it may succeed.
+#. TRANS It is probably a good idea to delay for a few seconds before trying it
+#. TRANS again, to allow time for other processes to release scarce resources.
+#. TRANS Such shortages are usually fairly serious and affect the whole system,
+#. TRANS so usually an interactive program should report the error to the user
+#. TRANS and return to its command loop.
+#. TRANS @end itemize
+#: sysdeps/gnu/errlist.c:416
+msgid "Resource temporarily unavailable"
+msgstr "Resursas laikinai neprieinamas"
+
+#. TRANS In the GNU C library, this is another name for @code{EAGAIN} (above).
+#. TRANS The values are always the same, on every operating system.
+#. TRANS
+#. TRANS C libraries in many older Unix systems have @code{EWOULDBLOCK} as a
+#. TRANS separate error code.
+#: sysdeps/gnu/errlist.c:429
+msgid "Operation would block"
+msgstr "Operacija blokuotųsi"
+
+#. TRANS An operation that cannot complete immediately was initiated on an object
+#. TRANS that has non-blocking mode selected. Some functions that must always
+#. TRANS block (such as @code{connect}; @pxref{Connecting}) never return
+#. TRANS @code{EAGAIN}. Instead, they return @code{EINPROGRESS} to indicate that
+#. TRANS the operation has begun and will take some time. Attempts to manipulate
+#. TRANS the object before the call completes return @code{EALREADY}. You can
+#. TRANS use the @code{select} function to find out when the pending operation
+#. TRANS has completed; @pxref{Waiting for I/O}.
+#: sysdeps/gnu/errlist.c:445
+msgid "Operation now in progress"
+msgstr "Operacija dabar vykdoma"
+
+#. TRANS An operation is already in progress on an object that has non-blocking
+#. TRANS mode selected.
+#: sysdeps/gnu/errlist.c:455
+msgid "Operation already in progress"
+msgstr "Operacija jau vykdoma"
+
+#. TRANS A file that isn't a socket was specified when a socket is required.
+#: sysdeps/gnu/errlist.c:464
+msgid "Socket operation on non-socket"
+msgstr "Lizdo operacija taikoma ne lizdui"
+
+#. TRANS The size of a message sent on a socket was larger than the supported
+#. TRANS maximum size.
+#: sysdeps/gnu/errlist.c:474
+msgid "Message too long"
+msgstr "Pranešimas per ilgas"
+
+#. TRANS The socket type does not support the requested communications protocol.
+#: sysdeps/gnu/errlist.c:483
+msgid "Protocol wrong type for socket"
+msgstr ""
+
+#. TRANS You specified a socket option that doesn't make sense for the
+#. TRANS particular protocol being used by the socket. @xref{Socket Options}.
+#: sysdeps/gnu/errlist.c:493
+#, fuzzy
+msgid "Protocol not available"
+msgstr "Protokolas nepalaikomas"
+
+#. TRANS The socket domain does not support the requested communications protocol
+#. TRANS (perhaps because the requested protocol is completely invalid).
+#. TRANS @xref{Creating a Socket}.
+#: sysdeps/gnu/errlist.c:504
+msgid "Protocol not supported"
+msgstr "Protokolas nepalaikomas"
+
+#. TRANS The socket type is not supported.
+#: sysdeps/gnu/errlist.c:513
+msgid "Socket type not supported"
+msgstr "Lizdo tipas nepalaikomas"
+
+#. TRANS The operation you requested is not supported. Some socket functions
+#. TRANS don't make sense for all types of sockets, and others may not be
+#. TRANS implemented for all communications protocols. In the GNU system, this
+#. TRANS error can happen for many calls when the object does not support the
+#. TRANS particular operation; it is a generic indication that the server knows
+#. TRANS nothing to do for that call.
+#: sysdeps/gnu/errlist.c:527
+#, fuzzy
+msgid "Operation not supported"
+msgstr "Operacija neleidžiama"
+
+#. TRANS The socket communications protocol family you requested is not supported.
+#: sysdeps/gnu/errlist.c:536
+msgid "Protocol family not supported"
+msgstr "Protokolo Å¡eima nepalaikoma"
+
+#. TRANS The address family specified for a socket is not supported; it is
+#. TRANS inconsistent with the protocol being used on the socket. @xref{Sockets}.
+#: sysdeps/gnu/errlist.c:546
+msgid "Address family not supported by protocol"
+msgstr "Adreso Å¡eima nepalaikoma protokolo"
+
+#. TRANS The requested socket address is already in use. @xref{Socket Addresses}.
+#: sysdeps/gnu/errlist.c:555
+msgid "Address already in use"
+msgstr "Adresas jau naudojamas"
+
+#. TRANS The requested socket address is not available; for example, you tried
+#. TRANS to give a socket a name that doesn't match the local host name.
+#. TRANS @xref{Socket Addresses}.
+#: sysdeps/gnu/errlist.c:566
+msgid "Cannot assign requested address"
+msgstr "Nepavyko priskirti prašomo adreso"
+
+#. TRANS A socket operation failed because the network was down.
+#: sysdeps/gnu/errlist.c:575
+msgid "Network is down"
+msgstr "Tinklas išjungtas"
+
+#. TRANS A socket operation failed because the subnet containing the remote host
+#. TRANS was unreachable.
+#: sysdeps/gnu/errlist.c:585
+msgid "Network is unreachable"
+msgstr "Tinklas neprieinamas"
+
+#. TRANS A network connection was reset because the remote host crashed.
+#: sysdeps/gnu/errlist.c:594
+msgid "Network dropped connection on reset"
+msgstr ""
+
+#. TRANS A network connection was aborted locally.
+#: sysdeps/gnu/errlist.c:603
+msgid "Software caused connection abort"
+msgstr ""
+
+#. TRANS A network connection was closed for reasons outside the control of the
+#. TRANS local host, such as by the remote machine rebooting or an unrecoverable
+#. TRANS protocol violation.
+#: sysdeps/gnu/errlist.c:614
+msgid "Connection reset by peer"
+msgstr "Prisijungimas nutrauktas kito serverio"
+
+#. TRANS The kernel's buffers for I/O operations are all in use. In GNU, this
+#. TRANS error is always synonymous with @code{ENOMEM}; you may get one or the
+#. TRANS other from network operations.
+#: sysdeps/gnu/errlist.c:625
+msgid "No buffer space available"
+msgstr "NÄ—ra vietos buferyje"
+
+#. TRANS You tried to connect a socket that is already connected.
+#. TRANS @xref{Connecting}.
+#: sysdeps/gnu/errlist.c:635
+msgid "Transport endpoint is already connected"
+msgstr "Transporto galinis taškas jau prijungtas"
+
+#. TRANS The socket is not connected to anything. You get this error when you
+#. TRANS try to transmit data over a socket, without first specifying a
+#. TRANS destination for the data. For a connectionless socket (for datagram
+#. TRANS protocols, such as UDP), you get @code{EDESTADDRREQ} instead.
+#: sysdeps/gnu/errlist.c:647
+msgid "Transport endpoint is not connected"
+msgstr "Transporto galinis taškas neprijungtas"
+
+#. TRANS No default destination address was set for the socket. You get this
+#. TRANS error when you try to transmit data over a connectionless socket,
+#. TRANS without first specifying a destination for the data with @code{connect}.
+#: sysdeps/gnu/errlist.c:658
+msgid "Destination address required"
+msgstr "Reikia paskirties adreso"
+
+#. TRANS The socket has already been shut down.
+#: sysdeps/gnu/errlist.c:667
+msgid "Cannot send after transport endpoint shutdown"
+msgstr "Negalima siųsti po transporto galinio taško išjungimo (shutdown)"
+
+#. TRANS ???
+#: sysdeps/gnu/errlist.c:676
+#, fuzzy
+msgid "Too many references: cannot splice"
+msgstr "Per daug nuorodų: negalima skaidyti"
+
+#. TRANS A socket operation with a specified timeout received no response during
+#. TRANS the timeout period.
+#: sysdeps/gnu/errlist.c:686
+msgid "Connection timed out"
+msgstr "BaigÄ—si prisijungimo laukimo laikas"
+
+#. TRANS A remote host refused to allow the network connection (typically because
+#. TRANS it is not running the requested service).
+#: sysdeps/gnu/errlist.c:696
+msgid "Connection refused"
+msgstr "Prisijungimas atmestas"
+
+#. TRANS Too many levels of symbolic links were encountered in looking up a file name.
+#. TRANS This often indicates a cycle of symbolic links.
+#: sysdeps/gnu/errlist.c:706
+msgid "Too many levels of symbolic links"
+msgstr "Per daug simbolinių nuorodų lygmenų"
+
+#. TRANS Filename too long (longer than @code{PATH_MAX}; @pxref{Limits for
+#. TRANS Files}) or host name too long (in @code{gethostname} or
+#. TRANS @code{sethostname}; @pxref{Host Identification}).
+#: sysdeps/gnu/errlist.c:717
+msgid "File name too long"
+msgstr "Failo vardas per ilgas"
+
+#. TRANS The remote host for a requested network connection is down.
+#: sysdeps/gnu/errlist.c:726
+msgid "Host is down"
+msgstr "Serveris neveikia"
+
+#. TRANS The remote host for a requested network connection is not reachable.
+#: sysdeps/gnu/errlist.c:735
+msgid "No route to host"
+msgstr "NÄ—ra kelio iki serverio"
+
+#. TRANS Directory not empty, where an empty directory was expected. Typically,
+#. TRANS this error occurs when you are trying to delete a directory.
+#: sysdeps/gnu/errlist.c:745
+msgid "Directory not empty"
+msgstr "Aplankas netuÅ¡Äias"
+
+#. TRANS This means that the per-user limit on new process would be exceeded by
+#. TRANS an attempted @code{fork}. @xref{Limits on Resources}, for details on
+#. TRANS the @code{RLIMIT_NPROC} limit.
+#: sysdeps/gnu/errlist.c:756
+msgid "Too many processes"
+msgstr "Per daug procesų"
+
+#. TRANS The file quota system is confused because there are too many users.
+#. TRANS @c This can probably happen in a GNU system when using NFS.
+#: sysdeps/gnu/errlist.c:766
+msgid "Too many users"
+msgstr "Per daug naudotojų"
+
+#. TRANS The user's disk quota was exceeded.
+#: sysdeps/gnu/errlist.c:775
+msgid "Disk quota exceeded"
+msgstr "Viršyta disko kvota"
+
+#. TRANS Stale NFS file handle. This indicates an internal confusion in the NFS
+#. TRANS system which is due to file system rearrangements on the server host.
+#. TRANS Repairing this condition usually requires unmounting and remounting
+#. TRANS the NFS file system on the local host.
+#: sysdeps/gnu/errlist.c:787
+msgid "Stale NFS file handle"
+msgstr ""
+
+#. TRANS An attempt was made to NFS-mount a remote file system with a file name that
+#. TRANS already specifies an NFS-mounted file.
+#. TRANS (This is an error on some operating systems, but we expect it to work
+#. TRANS properly on the GNU system, making this error code impossible.)
+#: sysdeps/gnu/errlist.c:799
+msgid "Object is remote"
+msgstr "Objektas nutolęs"
+
+#. TRANS ???
+#: sysdeps/gnu/errlist.c:808
+msgid "RPC struct is bad"
+msgstr "bloga RPC struktūra"
+
+#. TRANS ???
+#: sysdeps/gnu/errlist.c:817
+msgid "RPC version wrong"
+msgstr "netinkama RPC versija"
+
+#. TRANS ???
+#: sysdeps/gnu/errlist.c:826
+#, fuzzy
+msgid "RPC program not available"
+msgstr "RPC: Programa neregistruota"
+
+#. TRANS ???
+#: sysdeps/gnu/errlist.c:835
+msgid "RPC program version wrong"
+msgstr "netinkama RPC programos versija"
+
+#. TRANS ???
+#: sysdeps/gnu/errlist.c:844
+msgid "RPC bad procedure for program"
+msgstr ""
+
+#. TRANS No locks available. This is used by the file locking facilities; see
+#. TRANS @ref{File Locks}. This error is never generated by the GNU system, but
+#. TRANS it can result from an operation to an NFS server running another
+#. TRANS operating system.
+#: sysdeps/gnu/errlist.c:856
+#, fuzzy
+msgid "No locks available"
+msgstr "NÄ—ra vietos buferyje"
+
+#. TRANS Inappropriate file type or format. The file was the wrong type for the
+#. TRANS operation, or a data file had the wrong format.
+#. TRANS
+#. TRANS On some systems @code{chmod} returns this error if you try to set the
+#. TRANS sticky bit on a non-directory file; @pxref{Setting Permissions}.
+#: sysdeps/gnu/errlist.c:869
+msgid "Inappropriate file type or format"
+msgstr "Netinkamas failo tipas ar formatas"
+
+#. TRANS ???
+#: sysdeps/gnu/errlist.c:878
+msgid "Authentication error"
+msgstr "Autentikacijos klaida"
+
+#. TRANS ???
+#: sysdeps/gnu/errlist.c:887
+#, fuzzy
+msgid "Need authenticator"
+msgstr "Autentikacijos klaida"
+
+#. TRANS Function not implemented. This indicates that the function called is
+#. TRANS not implemented at all, either in the C library itself or in the
+#. TRANS operating system. When you get this error, you can be sure that this
+#. TRANS particular function will always fail with @code{ENOSYS} unless you
+#. TRANS install a new version of the C library or the operating system.
+#: sysdeps/gnu/errlist.c:900
+msgid "Function not implemented"
+msgstr "Funkcija nerealizuota"
+
+#. TRANS Not supported. A function returns this error when certain parameter
+#. TRANS values are valid, but the functionality they request is not available.
+#. TRANS This can mean that the function does not implement a particular command
+#. TRANS or option value or flag bit at all. For functions that operate on some
+#. TRANS object given in a parameter, such as a file descriptor or a port, it
+#. TRANS might instead mean that only @emph{that specific object} (file
+#. TRANS descriptor, port, etc.) is unable to support the other parameters given;
+#. TRANS different file descriptors might support different ranges of parameter
+#. TRANS values.
+#. TRANS
+#. TRANS If the entire function is not available at all in the implementation,
+#. TRANS it returns @code{ENOSYS} instead.
+#: sysdeps/gnu/errlist.c:920
+msgid "Not supported"
+msgstr "Nepalaikoma"
+
+#. TRANS While decoding a multibyte character the function came along an invalid
+#. TRANS or an incomplete sequence of bytes or the given wide character is invalid.
+#: sysdeps/gnu/errlist.c:930
+msgid "Invalid or incomplete multibyte or wide character"
+msgstr "Netaisyklingas arba nepilnas daugiabaitis simbolis"
+
+#. TRANS In the GNU system, servers supporting the @code{term} protocol return
+#. TRANS this error for certain operations when the caller is not in the
+#. TRANS foreground process group of the terminal. Users do not usually see this
+#. TRANS error because functions such as @code{read} and @code{write} translate
+#. TRANS it into a @code{SIGTTIN} or @code{SIGTTOU} signal. @xref{Job Control},
+#. TRANS for information on process groups and these signals.
+#: sysdeps/gnu/errlist.c:944
+msgid "Inappropriate operation for background process"
+msgstr ""
+
+#. TRANS In the GNU system, opening a file returns this error when the file is
+#. TRANS translated by a program and the translator program dies while starting
+#. TRANS up, before it has connected to the file.
+#: sysdeps/gnu/errlist.c:955
+msgid "Translator died"
+msgstr ""
+
+#. TRANS The experienced user will know what is wrong.
+#. TRANS @c This error code is a joke. Its perror text is part of the joke.
+#. TRANS @c Don't change it.
+#: sysdeps/gnu/errlist.c:966
+msgid "?"
+msgstr "?"
+
+#. TRANS You did @strong{what}?
+#: sysdeps/gnu/errlist.c:975
+msgid "You really blew it this time"
+msgstr "Šįkart susimovei kaip reikiant"
+
+#. TRANS Go home and have a glass of warm, dairy-fresh milk.
+#: sysdeps/gnu/errlist.c:984
+msgid "Computer bought the farm"
+msgstr "Kompiuteris nupirko fermÄ…"
+
+#. TRANS This error code has no purpose.
+#: sysdeps/gnu/errlist.c:993
+#, fuzzy
+msgid "Gratuitous error"
+msgstr "relokacijos klaida"
+
+#: sysdeps/gnu/errlist.c:1001
+#, fuzzy
+msgid "Bad message"
+msgstr "neužbaigtas pranešimas"
+
+#: sysdeps/gnu/errlist.c:1009
+msgid "Identifier removed"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1017
+msgid "Multihop attempted"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1025
+#, fuzzy
+msgid "No data available"
+msgstr "NÄ—ra vietos buferyje"
+
+#: sysdeps/gnu/errlist.c:1033
+#, fuzzy
+msgid "Link has been severed"
+msgstr "Raktas atšauktas"
+
+#: sysdeps/gnu/errlist.c:1041
+msgid "No message of desired type"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1049
+msgid "Out of streams resources"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1057
+msgid "Device not a stream"
+msgstr "Įrenginys nėra srautas"
+
+#: sysdeps/gnu/errlist.c:1065
+msgid "Value too large for defined data type"
+msgstr "Reikšmė per didelė apibrėžtam duomenų tipui"
+
+#: sysdeps/gnu/errlist.c:1073
+msgid "Protocol error"
+msgstr "Protokolo klaida"
+
+#: sysdeps/gnu/errlist.c:1081
+#, fuzzy
+msgid "Timer expired"
+msgstr "BaigÄ—si rakto galiojimo laikas"
+
+#. TRANS Operation canceled; an asynchronous operation was canceled before it
+#. TRANS completed. @xref{Asynchronous I/O}. When you call @code{aio_cancel},
+#. TRANS the normal result is for the operations affected to complete with this
+#. TRANS error; @pxref{Cancel AIO Operations}.
+#: sysdeps/gnu/errlist.c:1093
+msgid "Operation canceled"
+msgstr "Operacija nutraukta"
+
+#: sysdeps/gnu/errlist.c:1101
+msgid "Interrupted system call should be restarted"
+msgstr "Pertrauktas sistemos iškvietimas turėtų būti įvykdytas iš naujo"
+
+#: sysdeps/gnu/errlist.c:1109
+msgid "Channel number out of range"
+msgstr "Kanalo numeris už ribų"
+
+#: sysdeps/gnu/errlist.c:1117
+msgid "Level 2 not synchronized"
+msgstr "2 lygmuo nesinchonizuotas"
+
+#: sysdeps/gnu/errlist.c:1125
+msgid "Level 3 halted"
+msgstr "3 lygmuo sustabdytas"
+
+#: sysdeps/gnu/errlist.c:1133
+#, fuzzy
+msgid "Level 3 reset"
+msgstr "3 lygmuo sustabdytas"
+
+#: sysdeps/gnu/errlist.c:1141
+#, fuzzy
+msgid "Link number out of range"
+msgstr "%s: eilutės numeris už ribų"
+
+#: sysdeps/gnu/errlist.c:1149
+#, fuzzy
+msgid "Protocol driver not attached"
+msgstr "Protokolas nepalaikomas"
+
+#: sysdeps/gnu/errlist.c:1157
+#, fuzzy
+msgid "No CSI structure available"
+msgstr "NÄ—ra vietos buferyje"
+
+#: sysdeps/gnu/errlist.c:1165
+msgid "Level 2 halted"
+msgstr "2 lygmuo sustabdytas"
+
+#: sysdeps/gnu/errlist.c:1173
+#, fuzzy
+msgid "Invalid exchange"
+msgstr "netaisyklingas kvietÄ—jas"
+
+#: sysdeps/gnu/errlist.c:1181
+#, fuzzy
+msgid "Invalid request descriptor"
+msgstr "Blogas failo deskriptorius"
+
+#: sysdeps/gnu/errlist.c:1189
+msgid "Exchange full"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1197
+msgid "No anode"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1205
+#, fuzzy
+msgid "Invalid request code"
+msgstr "Visos užklausos baigtos"
+
+#: sysdeps/gnu/errlist.c:1213
+#, fuzzy
+msgid "Invalid slot"
+msgstr "netaisyklingas kvietÄ—jas"
+
+#: sysdeps/gnu/errlist.c:1221
+msgid "File locking deadlock error"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1229
+msgid "Bad font file format"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1237
+msgid "Machine is not on the network"
+msgstr "Kompiuterio nÄ—ra tinkle"
+
+#: sysdeps/gnu/errlist.c:1245
+msgid "Package not installed"
+msgstr "Paketas neįdiegtas"
+
+#: sysdeps/gnu/errlist.c:1253
+#, fuzzy
+msgid "Advertise error"
+msgstr "vidinÄ— klaida"
+
+#: sysdeps/gnu/errlist.c:1261
+#, fuzzy
+msgid "Srmount error"
+msgstr "Protokolo klaida"
+
+#: sysdeps/gnu/errlist.c:1269
+msgid "Communication error on send"
+msgstr "Komunikacijos klaida siunÄiant"
+
+#: sysdeps/gnu/errlist.c:1277
+msgid "RFS specific error"
+msgstr "RFS specifinÄ— klaida"
+
+#: sysdeps/gnu/errlist.c:1285
+msgid "Name not unique on network"
+msgstr "Vardas tinkle neunikalus"
+
+#: sysdeps/gnu/errlist.c:1293
+#, fuzzy
+msgid "File descriptor in bad state"
+msgstr "Failo deskriptorius nekorektiškoje būsenoje"
+
+#: sysdeps/gnu/errlist.c:1301
+msgid "Remote address changed"
+msgstr "Nutolęs adresas pasikeitė"
+
+#: sysdeps/gnu/errlist.c:1309
+msgid "Can not access a needed shared library"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1317
+msgid "Accessing a corrupted shared library"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1325
+msgid ".lib section in a.out corrupted"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1333
+#, fuzzy
+msgid "Attempting to link in too many shared libraries"
+msgstr "klaida įkeliant bendrąsias bibliotekas"
+
+#: sysdeps/gnu/errlist.c:1341
+msgid "Cannot exec a shared library directly"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1349
+msgid "Streams pipe error"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1357
+msgid "Structure needs cleaning"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1365
+msgid "Not a XENIX named type file"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1373
+#, fuzzy
+msgid "No XENIX semaphores available"
+msgstr "NÄ—ra vietos buferyje"
+
+#: sysdeps/gnu/errlist.c:1381
+msgid "Is a named type file"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1389
+msgid "Remote I/O error"
+msgstr "Nutolusio įvedimo/išvedimo klaida"
+
+#: sysdeps/gnu/errlist.c:1397
+#, fuzzy
+msgid "No medium found"
+msgstr "Nerasta laikmena"
+
+#: sysdeps/gnu/errlist.c:1405
+msgid "Wrong medium type"
+msgstr "Netinkamas laikmenos tipas"
+
+#: sysdeps/gnu/errlist.c:1413
+msgid "Required key not available"
+msgstr "Reikalingas raktas nerastas"
+
+#: sysdeps/gnu/errlist.c:1421
+msgid "Key has expired"
+msgstr "BaigÄ—si rakto galiojimo laikas"
+
+#: sysdeps/gnu/errlist.c:1429
+msgid "Key has been revoked"
+msgstr "Raktas atšauktas"
+
+#: sysdeps/gnu/errlist.c:1437
+msgid "Key was rejected by service"
+msgstr "Raktas atmestas tarnybos"
+
+#: sysdeps/gnu/errlist.c:1445
+msgid "Owner died"
+msgstr ""
+
+#: sysdeps/gnu/errlist.c:1453
+msgid "State not recoverable"
+msgstr ""
+
+#: sysdeps/mach/_strerror.c:57
+msgid "Error in unknown error system: "
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:1
+msgid "Address family for hostname not supported"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:2
+msgid "Temporary failure in name resolution"
+msgstr "Laikinas vardų paieškos sutrikimas"
+
+#: sysdeps/posix/gai_strerror-strs.h:3
+msgid "Bad value for ai_flags"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:4
+msgid "Non-recoverable failure in name resolution"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:5
+msgid "ai_family not supported"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:6
+msgid "Memory allocation failure"
+msgstr "Atminties išskyrimo klaida"
+
+#: sysdeps/posix/gai_strerror-strs.h:7
+msgid "No address associated with hostname"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:8
+msgid "Name or service not known"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:9
+msgid "Servname not supported for ai_socktype"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:10
+msgid "ai_socktype not supported"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:11
+msgid "System error"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:12
+msgid "Processing request in progress"
+msgstr ""
+
+#: sysdeps/posix/gai_strerror-strs.h:13
+msgid "Request canceled"
+msgstr "Užklausa nutraukta"
+
+#: sysdeps/posix/gai_strerror-strs.h:14
+msgid "Request not canceled"
+msgstr "Užklausa nenutraukta"
+
+#: sysdeps/posix/gai_strerror-strs.h:15
+msgid "All requests done"
+msgstr "Visos užklausos baigtos"
+
+#: sysdeps/posix/gai_strerror-strs.h:16
+msgid "Interrupted by a signal"
+msgstr "Nutraukta signalo"
+
+#: sysdeps/posix/gai_strerror-strs.h:17
+msgid "Parameter string not correctly encoded"
+msgstr ""
+
+#: sysdeps/unix/siglist.c:26
+msgid "Signal 0"
+msgstr ""
+
+#: sysdeps/unix/siglist.c:32
+#, fuzzy
+msgid "IOT trap"
+msgstr "EMT gaudyklÄ—"
+
+#: sysdeps/unix/sysv/linux/i386/readelflib.c:49
+#, fuzzy, c-format
+msgid "%s is for unknown machine %d.\n"
+msgstr "Rasta %d bibliotekų podėlyje „%s“\n"
+
+#: sysdeps/unix/sysv/linux/ia64/makecontext.c:63
+#, c-format
+msgid "makecontext: does not know how to handle more than 8 arguments\n"
+msgstr ""
+
+#: sysdeps/unix/sysv/linux/lddlibc4.c:64
+#, fuzzy, c-format
+msgid "cannot open `%s'"
+msgstr "nepavyko atverti"
+
+#: sysdeps/unix/sysv/linux/lddlibc4.c:68
+#, fuzzy, c-format
+msgid "cannot read header from `%s'"
+msgstr "nepavyko perskaityti antraštės"
+
+#: timezone/zdump.c:211
+#, fuzzy
+msgid "lacks alphabetic at start"
+msgstr "laiko zonos santrumpos pradžioje nėra raidės"
+
+#: timezone/zdump.c:213
+#, fuzzy
+msgid "has fewer than 3 alphabetics"
+msgstr "laiko zonos santrumpoje yra daugiau negu 3 raidÄ—s"
+
+#: timezone/zdump.c:215
+#, fuzzy
+msgid "has more than 6 alphabetics"
+msgstr "laiko zonos santrumpoje yra daugiau negu 3 raidÄ—s"
+
+#: timezone/zdump.c:223
+msgid "differs from POSIX standard"
+msgstr ""
+
+#: timezone/zdump.c:229
+#, c-format
+msgid "%s: warning: zone \"%s\" abbreviation \"%s\" %s\n"
+msgstr ""
+
+#: timezone/zdump.c:280
+#, c-format
+msgid "%s: usage is %s [ --version ] [ -v ] [ -c [loyear,]hiyear ] zonename ...\n"
+msgstr ""
+
+#: timezone/zdump.c:297
+#, fuzzy, c-format
+msgid "%s: wild -c argument %s\n"
+msgstr "%s: Per daug argumentų\n"
+
+#: timezone/zdump.c:388
+#, fuzzy
+msgid "Error writing to standard output"
+msgstr "standartinis išvedimas"
+
+#: timezone/zdump.c:411
+#, c-format
+msgid "%s: use of -v on system with floating time_t other than float or double\n"
+msgstr ""
+
+#: timezone/zic.c:392
+#, fuzzy, c-format
+msgid "%s: Memory exhausted: %s\n"
+msgstr "BaigÄ—si atmintis"
+
+#: timezone/zic.c:451
+#, c-format
+msgid "\"%s\", line %d: %s"
+msgstr ""
+
+#: timezone/zic.c:454
+#, c-format
+msgid " (rule from \"%s\", line %d)"
+msgstr ""
+
+#: timezone/zic.c:466
+#, fuzzy
+msgid "warning: "
+msgstr "įspėjimas: "
+
+#: timezone/zic.c:476
+#, c-format
+msgid ""
+"%s: usage is %s [ --version ] [ -v ] [ -l localtime ] [ -p posixrules ] \\\n"
+"\t[ -d directory ] [ -L leapseconds ] [ -y yearistype ] [ filename ... ]\n"
+msgstr ""
+
+#: timezone/zic.c:511
+#, fuzzy
+msgid "wild compilation-time specification of zic_t"
+msgstr "%s: nÄ—ra baigimo specifikacijos"
+
+#: timezone/zic.c:528
+#, fuzzy, c-format
+msgid "%s: More than one -d option specified\n"
+msgstr "%s: nÄ—ra baigimo specifikacijos"
+
+#: timezone/zic.c:538
+#, fuzzy, c-format
+msgid "%s: More than one -l option specified\n"
+msgstr "%s: nÄ—ra baigimo specifikacijos"
+
+#: timezone/zic.c:548
+#, fuzzy, c-format
+msgid "%s: More than one -p option specified\n"
+msgstr "%s: nÄ—ra baigimo specifikacijos"
+
+#: timezone/zic.c:558
+#, fuzzy, c-format
+msgid "%s: More than one -y option specified\n"
+msgstr "%s: nÄ—ra baigimo specifikacijos"
+
+#: timezone/zic.c:568
+#, fuzzy, c-format
+msgid "%s: More than one -L option specified\n"
+msgstr "%s: nÄ—ra baigimo specifikacijos"
+
+#: timezone/zic.c:617
+msgid "link to link"
+msgstr ""
+
+#: timezone/zic.c:682
+msgid "hard link failed, symbolic link used"
+msgstr ""
+
+#: timezone/zic.c:690
+#, fuzzy, c-format
+msgid "%s: Can't link from %s to %s: %s\n"
+msgstr "Nepavyko susaistyti (link) %s su %s"
+
+#: timezone/zic.c:762 timezone/zic.c:764
+msgid "same rule name in multiple files"
+msgstr ""
+
+#: timezone/zic.c:805
+msgid "unruly zone"
+msgstr ""
+
+#: timezone/zic.c:812
+#, c-format
+msgid "%s in ruleless zone"
+msgstr ""
+
+#: timezone/zic.c:833
+msgid "standard input"
+msgstr ""
+
+#: timezone/zic.c:838
+#, fuzzy, c-format
+msgid "%s: Can't open %s: %s\n"
+msgstr "nepavyko atverti"
+
+#: timezone/zic.c:849
+#, fuzzy
+msgid "line too long"
+msgstr "Failo vardas per ilgas"
+
+#: timezone/zic.c:869
+msgid "input line of unknown type"
+msgstr ""
+
+#: timezone/zic.c:885
+#, c-format
+msgid "%s: Leap line in non leap seconds file %s\n"
+msgstr ""
+
+#: timezone/zic.c:892 timezone/zic.c:1329 timezone/zic.c:1351
+#, c-format
+msgid "%s: panic: Invalid l_value %d\n"
+msgstr ""
+
+#: timezone/zic.c:900
+#, fuzzy, c-format
+msgid "%s: Error reading %s\n"
+msgstr "%s: Klaida rašant %s\n"
+
+#: timezone/zic.c:907
+#, fuzzy, c-format
+msgid "%s: Error closing %s: %s\n"
+msgstr "%s: Klaida rašant %s\n"
+
+#: timezone/zic.c:912
+msgid "expected continuation line not found"
+msgstr ""
+
+#: timezone/zic.c:956 timezone/zic.c:2489 timezone/zic.c:2508
+msgid "time overflow"
+msgstr ""
+
+#: timezone/zic.c:960
+msgid "24:00 not handled by pre-1998 versions of zic"
+msgstr ""
+
+#: timezone/zic.c:963
+msgid "values over 24 hours not handled by pre-2007 versions of zic"
+msgstr ""
+
+#: timezone/zic.c:976
+msgid "wrong number of fields on Rule line"
+msgstr ""
+
+#: timezone/zic.c:980
+msgid "nameless rule"
+msgstr ""
+
+#: timezone/zic.c:985
+#, fuzzy
+msgid "invalid saved time"
+msgstr "netaisyklingas kvietÄ—jas"
+
+#: timezone/zic.c:1006
+msgid "wrong number of fields on Zone line"
+msgstr ""
+
+#: timezone/zic.c:1012
+#, c-format
+msgid "\"Zone %s\" line and -l option are mutually exclusive"
+msgstr ""
+
+#: timezone/zic.c:1020
+#, c-format
+msgid "\"Zone %s\" line and -p option are mutually exclusive"
+msgstr ""
+
+#: timezone/zic.c:1032
+#, c-format
+msgid "duplicate zone name %s (file \"%s\", line %d)"
+msgstr ""
+
+#: timezone/zic.c:1048
+msgid "wrong number of fields on Zone continuation line"
+msgstr ""
+
+#: timezone/zic.c:1088
+#, fuzzy
+msgid "invalid UTC offset"
+msgstr "netaisyklingas kvietÄ—jas"
+
+#: timezone/zic.c:1091
+#, fuzzy
+msgid "invalid abbreviation format"
+msgstr "netinkamas mÄ—nesio pavadinimas"
+
+#: timezone/zic.c:1120
+msgid "Zone continuation line end time is not after end time of previous line"
+msgstr ""
+
+#: timezone/zic.c:1148
+msgid "wrong number of fields on Leap line"
+msgstr ""
+
+#: timezone/zic.c:1157
+#, fuzzy
+msgid "invalid leaping year"
+msgstr "nurodyta netaisyklinga koduotÄ—"
+
+#: timezone/zic.c:1177 timezone/zic.c:1283
+#, fuzzy
+msgid "invalid month name"
+msgstr "netaisyklinga veiksena"
+
+#: timezone/zic.c:1190 timezone/zic.c:1396 timezone/zic.c:1410
+msgid "invalid day of month"
+msgstr "netinkama mÄ—nesio diena"
+
+#: timezone/zic.c:1195
+msgid "time before zero"
+msgstr ""
+
+#: timezone/zic.c:1199
+msgid "time too small"
+msgstr ""
+
+#: timezone/zic.c:1203
+#, fuzzy
+msgid "time too large"
+msgstr "Failas per didelis"
+
+#: timezone/zic.c:1207 timezone/zic.c:1312
+#, fuzzy
+msgid "invalid time of day"
+msgstr "netaisyklinga veiksena"
+
+#: timezone/zic.c:1226
+msgid "illegal CORRECTION field on Leap line"
+msgstr ""
+
+#: timezone/zic.c:1231
+msgid "illegal Rolling/Stationary field on Leap line"
+msgstr ""
+
+#: timezone/zic.c:1247
+msgid "wrong number of fields on Link line"
+msgstr ""
+
+#: timezone/zic.c:1251
+msgid "blank FROM field on Link line"
+msgstr ""
+
+#: timezone/zic.c:1255
+msgid "blank TO field on Link line"
+msgstr ""
+
+#: timezone/zic.c:1333
+#, fuzzy
+msgid "invalid starting year"
+msgstr "netaisyklingas naudotojas"
+
+#: timezone/zic.c:1355
+#, fuzzy
+msgid "invalid ending year"
+msgstr "nurodyta netaisyklinga koduotÄ—"
+
+#: timezone/zic.c:1359
+msgid "starting year greater than ending year"
+msgstr ""
+
+#: timezone/zic.c:1366
+msgid "typed single year"
+msgstr ""
+
+#: timezone/zic.c:1401
+#, fuzzy
+msgid "invalid weekday name"
+msgstr "netinkamas mÄ—nesio pavadinimas"
+
+#: timezone/zic.c:1579
+#, fuzzy, c-format
+msgid "%s: Can't remove %s: %s\n"
+msgstr "%s:%u: nepavyko perskaityti aplanko %s"
+
+#: timezone/zic.c:1589
+#, fuzzy, c-format
+msgid "%s: Can't create %s: %s\n"
+msgstr "%s:%u: nepavyko perskaityti aplanko %s"
+
+#: timezone/zic.c:1739
+#, c-format
+msgid "%s: Error writing %s\n"
+msgstr "%s: Klaida rašant %s\n"
+
+#: timezone/zic.c:2031
+msgid "no POSIX environment variable for zone"
+msgstr ""
+
+#: timezone/zic.c:2185
+msgid "can't determine time zone abbreviation to use just after until time"
+msgstr ""
+
+#: timezone/zic.c:2231
+#, fuzzy
+msgid "too many transitions?!"
+msgstr "per daug keliamųjų sekundžių"
+
+#: timezone/zic.c:2250
+msgid "internal error - addtype called with bad isdst"
+msgstr ""
+
+#: timezone/zic.c:2254
+msgid "internal error - addtype called with bad ttisstd"
+msgstr ""
+
+#: timezone/zic.c:2258
+msgid "internal error - addtype called with bad ttisgmt"
+msgstr ""
+
+#: timezone/zic.c:2277
+msgid "too many local time types"
+msgstr "per daug lokalaus laiko tipų"
+
+#: timezone/zic.c:2281
+#, fuzzy
+msgid "UTC offset out of range"
+msgstr "UTC poslinkis už ribų"
+
+#: timezone/zic.c:2309
+msgid "too many leap seconds"
+msgstr "per daug keliamųjų sekundžių"
+
+#: timezone/zic.c:2315
+msgid "repeated leap second moment"
+msgstr "Pakartotinis keliamosios sekundÄ—s momentas"
+
+#: timezone/zic.c:2367
+msgid "Wild result from command execution"
+msgstr ""
+
+#: timezone/zic.c:2368
+#, c-format
+msgid "%s: command was '%s', result was %d\n"
+msgstr ""
+
+#: timezone/zic.c:2466
+msgid "Odd number of quotation marks"
+msgstr "Nelyginis kabuÄių skaiÄius"
+
+#: timezone/zic.c:2555
+msgid "use of 2/29 in non leap-year"
+msgstr "vasario 29 d. nekeliamuosiuose metuose"
+
+#: timezone/zic.c:2590
+msgid "rule goes past start/end of month--will not work with pre-2004 versions of zic"
+msgstr ""
+
+#: timezone/zic.c:2622
+msgid "time zone abbreviation lacks alphabetic at start"
+msgstr "laiko zonos santrumpos pradžioje nėra raidės"
+
+#: timezone/zic.c:2624
+msgid "time zone abbreviation has more than 3 alphabetics"
+msgstr "laiko zonos santrumpoje yra daugiau negu 3 raidÄ—s"
+
+#: timezone/zic.c:2626
+#, fuzzy
+msgid "time zone abbreviation has too many alphabetics"
+msgstr "laiko zonos santrumpoje yra daugiau negu 3 raidÄ—s"
+
+#: timezone/zic.c:2636
+#, fuzzy
+msgid "time zone abbreviation differs from POSIX standard"
+msgstr "laiko zonos santrumpos pradžioje nėra raidės"
+
+#: timezone/zic.c:2648
+msgid "too many, or too long, time zone abbreviations"
+msgstr ""
+
+#: timezone/zic.c:2689
+#, fuzzy, c-format
+msgid "%s: Can't create directory %s: %s\n"
+msgstr "Nepavyko atverti aplanko %s"
+
+#: timezone/zic.c:2711
+#, c-format
+msgid "%s: %d did not sign extend correctly\n"
+msgstr ""
+
+#~ msgid "%s: first non-whitespace character is not `\"'"
+#~ msgstr "%s: pirmas ne tarpo simbolis nėra „\"“"
+
+#~ msgid "no closing `%c' in %s"
+#~ msgstr "nÄ—ra uždaranÄiojo „%c“ %s"
+
+#, fuzzy
+#~ msgid "%s: cannot read: %s"
+#~ msgstr "%s:%u: nepavyko perskaityti aplanko %s"
+
+#~ msgid "%s is not bound to any keys.\n"
+#~ msgstr "%s nėra priskirtas jokiam klavišui.\n"
+
+#~ msgid "%s can be invoked via "
+#~ msgstr "%s gali būti iškviestas su"
+
+#~ msgid "only meaningful in a `for', `while', or `until' loop"
+#~ msgstr "prasminga tik „for“, „while“ arba „until“ cikle"
+
+#~ msgid " "
+#~ msgstr " "
+
+#~ msgid "HOME not set"
+#~ msgstr "HOME nenustatytas"
+
+#~ msgid "OLDPWD not set"
+#~ msgstr "OLDPWD nenustatytas"
+
+#, fuzzy
+#~ msgid "%s: option requires an argument"
+#~ msgstr "%s: parametrui „%s“ reikia argumento\n"
+
+#~ msgid "%s: numeric argument required"
+#~ msgstr "%s: reikia skaitinio argumento"
+
+#, fuzzy
+#~ msgid "%s: invalid option name"
+#~ msgstr "%s: netaisyklingas parametras --%c\n"
+
+#~ msgid "`%s': not a valid identifier"
+#~ msgstr "`%s': netaisyklingas identifikatorius"
+
+#, fuzzy
+#~ msgid "%s: invalid number"
+#~ msgstr "nekorektiška eilutė"
+
+#, fuzzy
+#~ msgid "%s: invalid signal specification"
+#~ msgstr "netaisyklingas apibrėžimas"
+
+#~ msgid "`%s': not a pid or valid job spec"
+#~ msgstr "„%s“: ne pid'as ar taisyklinga darbo specifikacija"
+
+#~ msgid "%s: readonly variable"
+#~ msgstr "%s: kintamasis tik skaitymui"
+
+#, fuzzy
+#~ msgid "%s: %s out of range"
+#~ msgstr "UTC poslinkis už ribų"
+
+#~ msgid "%s: no such job"
+#~ msgstr "%s: nÄ—ra tokio darbo"
+
+#~ msgid "%s: no job control"
+#~ msgstr "%s: nėra darbų valdymo"
+
+#~ msgid "no job control"
+#~ msgstr "nėra darbų valdymo"
+
+#~ msgid "%s: restricted"
+#~ msgstr "%s: apribota"
+
+#, fuzzy
+#~ msgid "%s: not a shell builtin"
+#~ msgstr "%s nÄ—ra simbolinÄ— nuoroda\n"
+
+#, fuzzy
+#~ msgid "%s: error retrieving current directory: %s: %s\n"
+#~ msgstr "%s: Nepavyko sukurti aplanko %s: %s\n"
+
+#~ msgid "%s: ambiguous job spec"
+#~ msgstr "%s: dviprasmis darbo aprašymas"
+
+#~ msgid "warning: -F option may not work as you expect"
+#~ msgstr "įspėjimas: parametras -F gali neveikti taip, kaip tikitės"
+
+#~ msgid "warning: -C option may not work as you expect"
+#~ msgstr "įspėjimas: parametras -C gali neveikti taip, kaip tikitės"
+
+#~ msgid "can only be used in a function"
+#~ msgstr "galima naudoti tik funkcijoje"
+
+#~ msgid "cannot use `-f' to make functions"
+#~ msgstr "negalima naudoti „-f“ funkcijoms kurti"
+
+#~ msgid "%s: readonly function"
+#~ msgstr "%s: funkcija tik skaitymui"
+
+#~ msgid "%s: cannot destroy array variables in this way"
+#~ msgstr "%s: negalima tokiu būdu sunaikinti masyvų kintamųjų"
+
+#, fuzzy
+#~ msgid "%s: not dynamically loaded"
+#~ msgstr "nepavyko dinamiškai įkelti paleidžiamojo failo"
+
+#, fuzzy
+#~ msgid "%s: cannot delete: %s"
+#~ msgstr "%s:%u: nepavyko perskaityti aplanko %s"
+
+#~ msgid "There are stopped jobs.\n"
+#~ msgstr "Yra sustabdytų darbų.\n"
+
+#~ msgid "%s: hash table empty\n"
+#~ msgstr "%s: maiÅ¡os lentelÄ— tuÅ¡Äia\n"
+
+#~ msgid "no help topics match `%s'. Try `help help' or `man -k %s' or `info %s'."
+#~ msgstr "nÄ—ra žinyno temų, atitinkanÄių „%s“. Bandykite „help help“, „man -k %s“ arba „info %s“."
+
+#~ msgid "missing hex digit for \\x"
+#~ msgstr "trūksta šešioliktainio skaitmens išraiškoje \\x"
+
+#, fuzzy
+#~ msgid "no other directory"
+#~ msgstr "Ne aplankas"
+
+#, fuzzy
+#~ msgid "<no current directory>"
+#~ msgstr "Ne aplankas"
+
+#, fuzzy
+#~ msgid "%s: invalid file descriptor specification"
+#~ msgstr "Blogas failo deskriptorius"
+
+#~ msgid "read error: %d: %s"
+#~ msgstr "skaitymo klaida: %d: %s"
+
+#~ msgid "can only `return' from a function or sourced script"
+#~ msgstr "galima grįžti (return) tik iš funkcijos ar scenarijaus"
+
+#, fuzzy
+#~ msgid "%s: cannot unset: readonly %s"
+#~ msgstr "%s:%u: nepavyko perskaityti aplanko %s"
+
+#~ msgid "%s: not an array variable"
+#~ msgstr "%s: ne masyvo kintamasis"
+
+#~ msgid "%s: not a function"
+#~ msgstr "%s: ne funkcija"
+
+#~ msgid "shift count"
+#~ msgstr "postÅ«mių skaiÄius"
+
+#, fuzzy
+#~ msgid "%s: invalid shell option name"
+#~ msgstr "%s: netaisyklingas parametras --%c\n"
+
+#~ msgid "filename argument required"
+#~ msgstr "reikia failo pavadinimo argumento"
+
+#, fuzzy
+#~ msgid "cannot suspend a login shell"
+#~ msgstr "nepavyko atverti duomenų failo"
+
+#~ msgid "%s is aliased to `%s'\n"
+#~ msgstr "%s yra „%s“ sinonimas\n"
+
+#~ msgid "%s is a shell keyword\n"
+#~ msgstr "%s yra aplinkos raktinis žodis\n"
+
+#~ msgid "%s is a function\n"
+#~ msgstr "%s yra funkcija\n"
+
+#, fuzzy
+#~ msgid "%s is a shell builtin\n"
+#~ msgstr "%s nÄ—ra simbolinÄ— nuoroda\n"
+
+#~ msgid "%s is %s\n"
+#~ msgstr "%s yra %s\n"
+
+#, fuzzy
+#~ msgid "%s: invalid limit argument"
+#~ msgstr "Netaisyklingas argumentas"
+
+#~ msgid "`%c': bad command"
+#~ msgstr "`%c': bloga komanda"
+
+#, fuzzy
+#~ msgid "%s: cannot get limit: %s"
+#~ msgstr "%s:%u: nepavyko perskaityti aplanko %s"
+
+#, fuzzy
+#~ msgid "%s: cannot modify limit: %s"
+#~ msgstr "%s:%u: nepavyko perskaityti aplanko %s"
+
+#, fuzzy
+#~ msgid "octal number"
+#~ msgstr "netaisyklingas rinkinio numeris"
+
+#, fuzzy
+#~ msgid "`%c': invalid symbolic mode character"
+#~ msgstr "netaisyklingas kabuÄių simbolis"
+
+#~ msgid "last command: %s\n"
+#~ msgstr "paskutinÄ— komanda: %s\n"
+
+#~ msgid "Aborting..."
+#~ msgstr "Nutraukiama..."
+
+#~ msgid "bad command type"
+#~ msgstr "blogas komandos tipas"
+
+#, fuzzy
+#~ msgid "bad jump"
+#~ msgstr "blogas argumentas"
+
+#~ msgid "%s: unbound variable"
+#~ msgstr "%s: nepriskirtas kintamasis"
+
+#~ msgid "\atimed out waiting for input: auto-logout\n"
+#~ msgstr "\alaukiant įvedimo baigėsi laikas: automatiškai atsijungta\n"
+
+#, fuzzy
+#~ msgid "TIMEFORMAT: `%c': invalid format character"
+#~ msgstr "netaisyklingas kabuÄių simbolis"
+
+#~ msgid "%s: %s: bad interpreter"
+#~ msgstr "%s: %s: blogas interpretatorius"
+
+#~ msgid "expression recursion level exceeded"
+#~ msgstr "viršytas išraiškos rekursijos lygis"
+
+#~ msgid "recursion stack underflow"
+#~ msgstr "rekursijos steko atvirkštinis perpildymas"
+
+#~ msgid "attempted assignment to non-variable"
+#~ msgstr "bandymas priskirti ne kintamajam"
+
+#~ msgid "division by 0"
+#~ msgstr "dalyba iš 0"
+
+#~ msgid "bug: bad expassign token"
+#~ msgstr "klaida: bloga expassign leksema"
+
+#~ msgid "`:' expected for conditional expression"
+#~ msgstr "sąlygos išraiškoje tikėtasi „:“"
+
+#~ msgid "exponent less than 0"
+#~ msgstr "eksponentas mažesnis už 0"
+
+#~ msgid "missing `)'"
+#~ msgstr "Trūksta „)“"
+
+#~ msgid "syntax error: operand expected"
+#~ msgstr "sintaksÄ—s klaida: tikÄ—tasi operando"
+
+#~ msgid "syntax error: invalid arithmetic operator"
+#~ msgstr "sintaksÄ—s klaida: netaisyklingas aritmetinis operatorius"
+
+#, fuzzy
+#~ msgid "invalid arithmetic base"
+#~ msgstr "netaisyklinga vardų sritis"
+
+#~ msgid "value too great for base"
+#~ msgstr "per didelė pagrindo reikšmė"
+
+#~ msgid "getcwd: cannot access parent directories"
+#~ msgstr "getcwd: nepavyko pasiekti aukštesnių aplankų"
+
+#~ msgid "describe_pid: %ld: no such pid"
+#~ msgstr "describe_pid: %ld: tokio pid nÄ—ra"
+
+#~ msgid "wait_for: No record of process %ld"
+#~ msgstr "wait_for: nėra proceso %ld įrašo"
+
+#~ msgid "wait_for_job: job %d is stopped"
+#~ msgstr "wait_for_job: darbas %d yra sustabdytas"
+
+#~ msgid "%s: job has terminated"
+#~ msgstr "%s: darbas baigtas"
+
+#~ msgid "%s: job %d already in background"
+#~ msgstr "%s: darbas %d jau fone"
+
+#~ msgid "no job control in this shell"
+#~ msgstr "šioje aplinkoje nėra darbų valdymo"
+
+#~ msgid "malloc: failed assertion: %s\n"
+#~ msgstr "malloc: pažeista prielaida: %s\n"
+
+#~ msgid ""
+#~ "\r\n"
+#~ "malloc: %s:%d: assertion botched\r\n"
+#~ msgstr ""
+#~ "\r\n"
+#~ "malloc: %s:%d: prielaida pažeista\r\n"
+
+#~ msgid "allocated"
+#~ msgstr "išskirta"
+
+#~ msgid "freed"
+#~ msgstr "atlaisvinta"
+
+#~ msgid "requesting resize"
+#~ msgstr "prašoma dydžio keitimo"
+
+#~ msgid "just resized"
+#~ msgstr "tik kÄ… pakeistas dydis"
+
+#, fuzzy
+#~ msgid "bug: unknown operation"
+#~ msgstr "RPC: Nežinomas protokolas"
+
+#, fuzzy
+#~ msgid "%s: host unknown"
+#~ msgstr "nežinoma"
+
+#~ msgid "%s: bad network path specification"
+#~ msgstr "%s: netaisyklingas tinklo kelias"
+
+#~ msgid "You have mail in $_"
+#~ msgstr "Turite laiškų $_"
+
+#~ msgid "You have new mail in $_"
+#~ msgstr "Turite naujų laiškų $_"
+
+#~ msgid "The mail in %s has been read\n"
+#~ msgstr "Paštas %s perskaitytas\n"
+
+#~ msgid "syntax error: arithmetic expression required"
+#~ msgstr "sintaksės klaida: reikia aritmetinės išraiškos"
+
+#~ msgid "syntax error: `;' unexpected"
+#~ msgstr "sintaksės klaida: netikėtas „;“"
+
+#, fuzzy
+#~ msgid "syntax error: `((%s))'"
+#~ msgstr "sintaksÄ—s klaida prologe: %s"
+
+#~ msgid "make_here_document: bad instruction type %d"
+#~ msgstr "make_here_document: blogas instrukcijos tipas %d"
+
+#~ msgid "make_redirection: redirection instruction `%d' out of range"
+#~ msgstr "make_redirection: nukreipimo instrukcija „%d“ už ribų"
+
+#~ msgid "unexpected EOF while looking for matching `%c'"
+#~ msgstr "netikėta failo pabaiga ieškant atitinkamo „%c“"
+
+#~ msgid "unexpected EOF while looking for `]]'"
+#~ msgstr "netikėta failo pabaiga ieškant „]]“"
+
+#~ msgid "syntax error in conditional expression: unexpected token `%s'"
+#~ msgstr "sintaksės klaida sąlygos išraiškoje: netikėta leksema „%s“"
+
+#~ msgid "unexpected token `%s', expected `)'"
+#~ msgstr "netikėta leksema „%s“, tikėtasi „)“"
+
+#~ msgid "expected `)'"
+#~ msgstr "tikėtasi „)“"
+
+#~ msgid "unexpected argument `%s' to conditional unary operator"
+#~ msgstr "netikėtas argumentas „%s“ sąlygos unariniam operatoriui"
+
+#~ msgid "unexpected argument to conditional unary operator"
+#~ msgstr "netikÄ—tas argumentas sÄ…lygos unariniam operatoriui"
+
+#~ msgid "unexpected token `%s', conditional binary operator expected"
+#~ msgstr "netikėta leksema „%s“, tikėtasi sąlyginio binarinio operatoriaus"
+
+#~ msgid "conditional binary operator expected"
+#~ msgstr "tikÄ—tasi sÄ…lygos binarinio operatoriaus"
+
+#~ msgid "unexpected argument `%s' to conditional binary operator"
+#~ msgstr "netikėtas argumentas „%s“ sąlygos binariniam operatoriui"
+
+#~ msgid "unexpected argument to conditional binary operator"
+#~ msgstr "netikÄ—tas argumentas sÄ…lygos binariniam operatoriui"
+
+#~ msgid "unexpected token `%c' in conditional command"
+#~ msgstr "netikėta leksema „%c“ sąlygos komandoje"
+
+#~ msgid "unexpected token `%s' in conditional command"
+#~ msgstr "netikėta leksema „%s“ sąlygos komandoje"
+
+#~ msgid "unexpected token %d in conditional command"
+#~ msgstr "netikÄ—ta leksema %d sÄ…lygos komandoje"
+
+#, fuzzy
+#~ msgid "syntax error near unexpected token `%s'"
+#~ msgstr "sintaksÄ—s klaida prologe: %s"
+
+#, fuzzy
+#~ msgid "syntax error: unexpected end of file"
+#~ msgstr "%s: per ankstyva failo pabaiga"
+
+#~ msgid "Use \"%s\" to leave the shell.\n"
+#~ msgstr "Naudokite „%s“, jei norite išeiti iš ap.\n"
+
+#~ msgid "unexpected EOF while looking for matching `)'"
+#~ msgstr "netikėta failo pabaiga ieškant atitinkamo „)“"
+
+#~ msgid "progcomp_insert: %s: NULL COMPSPEC"
+#~ msgstr "progcomp_insert: %s: NULL COMPSPEC"
+
+#~ msgid "print_command: bad connector `%d'"
+#~ msgstr "print_command: blogas jungtukas  „%d“"
+
+#, fuzzy
+#~ msgid "cprintf: `%c': invalid format character"
+#~ msgstr "netaisyklingas kabuÄių simbolis"
+
+#~ msgid "%s: ambiguous redirect"
+#~ msgstr "%s: ambiguous redirect"
+
+#, fuzzy
+#~ msgid "%s: cannot overwrite existing file"
+#~ msgstr "nepavyko atverti duomenų failo"
+
+#, fuzzy
+#~ msgid "%s: restricted: cannot redirect output"
+#~ msgstr "%s:%u: nepavyko perskaityti aplanko %s"
+
+#~ msgid "/dev/(tcp|udp)/host/port not supported without networking"
+#~ msgstr "/dev/(tcp|udp)/komp/prievadas nepalaikoma be tinklo"
+
+#~ msgid "redirection error: cannot duplicate fd"
+#~ msgstr "nukreipimo klaida: nepavyko dublikuoti fd"
+
+#~ msgid "could not find /tmp, please create!"
+#~ msgstr "nepavyko rasti /tmp, sukurkite šį aplanką!"
+
+#~ msgid "/tmp must be a valid directory name"
+#~ msgstr "/tmp turi būti taisyklingas aplanko pavadinimas"
+
+#, fuzzy
+#~ msgid "%c%c: invalid option"
+#~ msgstr "%s: netaisyklingas parametras --%c\n"
+
+#~ msgid "I have no name!"
+#~ msgstr "Neturiu vardo!"
+
+#, fuzzy
+#~ msgid "Type `%s -c \"help set\"' for more information about shell options.\n"
+#~ msgstr "Bandykite „%s --help“ arba „%s --usage“, jei norite gauti daugiau informacijos.\n"
+
+#, fuzzy
+#~ msgid "Type `%s -c help' for more information about shell builtin commands.\n"
+#~ msgstr "Bandykite „ldd --help“, jei norite daugiau informacijos."
+
+#~ msgid "sigprocmask: %d: invalid operation"
+#~ msgstr "sigprocmask: %d: netaisyklinga operacija"
+
+#, fuzzy
+#~ msgid "cannot duplicate named pipe %s as fd %d"
+#~ msgstr "nepavyko išskirti vardo įrašo"
+
+#~ msgid "$%s: cannot assign in this way"
+#~ msgstr "$%s: negalima tokiu būdu priskirti"
+
+#, fuzzy
+#~ msgid "no match: %s"
+#~ msgstr "Atitikmenų nėra"
+
+#~ msgid "argument expected"
+#~ msgstr "tikÄ—tasi argumento"
+
+#~ msgid "%s: integer expression expected"
+#~ msgstr "%s: tikėtasi skaitinės išraiškos"
+
+#~ msgid "`)' expected"
+#~ msgstr "tikėtasi „)“"
+
+#~ msgid "`)' expected, found %s"
+#~ msgstr "tikėtasi „)“, rasta %s"
+
+#~ msgid "%s: unary operator expected"
+#~ msgstr "%s: tikÄ—tasi unarinio operatoriaus"
+
+#~ msgid "%s: binary operator expected"
+#~ msgstr "%s: tikÄ—tasi binarinio operatoriaus"
+
+#~ msgid "missing `]'"
+#~ msgstr "trūksta „]“"
+
+#, fuzzy
+#~ msgid "invalid signal number"
+#~ msgstr "netaisyklingas kvietÄ—jas"
+
+#~ msgid "run_pending_traps: bad value in trap_list[%d]: %p"
+#~ msgstr "run_pending_traps: bloga trap_list[%d] reikšmė: %p"
+
+#~ msgid "trap_handler: bad signal %d"
+#~ msgstr "trap_handler: blogas signalas %d"
+
+#~ msgid "error importing function definition for `%s'"
+#~ msgstr "klaida importuojant funkcijos apibrėžimą „%s“"
+
+#, fuzzy
+#~ msgid "make_local_variable: no function context at current scope"
+#~ msgstr "make_local_variable: "
+
+#~ msgid "Copyright (C) 2006 Free Software Foundation, Inc.\n"
+#~ msgstr "AutorinÄ—s teisÄ—s (C) 2006 Free Software Foundation, Inc.\n"
+
+#~ msgid "xmalloc: cannot allocate %lu bytes (%lu bytes allocated)"
+#~ msgstr "xmalloc: nepavyko išskirti %lu baitų (%lu baitų išskirta)"
+
+#~ msgid "xmalloc: cannot allocate %lu bytes"
+#~ msgstr "xmalloc: nepavyko išskirti %lu baitų"
+
+#~ msgid "xrealloc: cannot allocate %lu bytes"
+#~ msgstr "xrealloc: nepavyko išskirti %lu baitų"
+
+#~ msgid "xmalloc: %s:%d: cannot allocate %lu bytes"
+#~ msgstr "xmalloc: %s:%d: nepavyko išskirti %lu baitų"
+
+#~ msgid "xrealloc: %s:%d: cannot allocate %lu bytes"
+#~ msgstr "xrealloc: %s:%d: nepavyko išskirti %lu baitų"
diff --git a/libc/po/nl.po b/libc/po/nl.po
index 1011af9c9..9fbc5e4c8 100644
--- a/libc/po/nl.po
+++ b/libc/po/nl.po
@@ -1,14 +1,15 @@
-# Translation of libc-2.7 to Dutch.
-# Copyright (C) 2004, 2006, 2007 Free Software Foundation, Inc.
+# Dutch translations for libc.
+# Copyright (C) 2007 Free Software Foundation, Inc.
+# This file is distributed under the same license as the glibc package.
#
# Elros Cyriatan <cyriatan@fastmail.fm>, 2004.
-# Benno Schulenberg <benno@vertaalt.nl>, 2006, 2007.
+# Benno Schulenberg <benno@vertaalt.nl>, 2006, 2007, 2008.
msgid ""
msgstr ""
"Project-Id-Version: libc-2.7\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2007-10-15 21:18-0700\n"
-"PO-Revision-Date: 2008-03-30 20:00+0200\n"
+"PO-Revision-Date: 2008-04-05 22:04+0200\n"
"Last-Translator: Benno Schulenberg <benno@vertaalt.nl>\n"
"Language-Team: Dutch <vertaling@vrijschrift.org>\n"
"MIME-Version: 1.0\n"
@@ -322,7 +323,7 @@ msgstr ""
"\n"
" -?,--help deze hulptekst tonen\n"
" --usage een korte gebruikssamenvatting tonen\n"
-" -V,--version versie-informatie tonen\n"
+" -V,--version programmaversie tonen\n"
"\n"
"Voor het rapporteren van gebreken in dit programma, zie:\n"
" <http://www.gnu.org/software/libc/bugs.html>.\\n"
@@ -940,7 +941,7 @@ msgstr ""
" -u, --unused ongebruikte directe afhankelijkheden tonen\n"
" -v, --verbose breedsprakige uitvoer\n"
"\n"
-" --version versie-informatie tonen\n"
+" --version programmaversie tonen\n"
" --help deze hulptekst tonen\n"
"\n"
"Voor het rapporteren van fouten, zie:\n"
@@ -1442,23 +1443,23 @@ msgstr "Teken ligt buiten bereik voor UTF-8"
#: locale/programs/charmap-dir.c:59
#, c-format
msgid "cannot read character map directory `%s'"
-msgstr "kan tekenskaartmap '%s' niet lezen"
+msgstr "kan tekensetdefinitiesmap '%s' niet lezen"
#: locale/programs/charmap.c:138
#, c-format
msgid "character map file `%s' not found"
-msgstr "kan tekenskaartbestand '%s' niet vinden"
+msgstr "kan tekensetdefinitiebestand '%s' niet vinden"
#: locale/programs/charmap.c:195
#, c-format
msgid "default character map file `%s' not found"
-msgstr "kan standaard-tekenskaartbestand '%s' niet vinden"
+msgstr "kan standaard tekensetdefinitiebestand '%s' niet vinden"
#: locale/programs/charmap.c:258
#, c-format
msgid "character map `%s' is not ASCII compatible, locale not ISO C compliant\n"
msgstr ""
-"tekenskaart '%s' is niet ASCII-compatibel;\n"
+"tekensetdefinitie '%s' is niet ASCII-compatibel;\n"
"de taalregio voldoet niet aan ISO C\n"
#: locale/programs/charmap.c:337
@@ -1722,7 +1723,7 @@ msgstr "%s: syntaxfout"
#: locale/programs/ld-collate.c:417
#, c-format
msgid "`%.*s' already defined in charmap"
-msgstr "'%.*s' is al gedefinieerd in tekenskaart"
+msgstr "'%.*s' is al gedefinieerd in tekensetdefinitie"
#: locale/programs/ld-collate.c:426
#, c-format
@@ -1983,7 +1984,7 @@ msgstr "%s: 'endif' zonder bijpassende 'ifdef' of 'ifndef'"
#: locale/programs/ld-ctype.c:439
#, c-format
msgid "No character set name specified in charmap"
-msgstr "Geen tekensetnaam aangegeven in tekenskaart"
+msgstr "Geen tekensetnaam aangegeven in tekensetdefinitie"
#: locale/programs/ld-ctype.c:468
#, c-format
@@ -2023,7 +2024,7 @@ msgstr "<SP>-teken mag niet in klasse '%s' zitten"
#: locale/programs/ld-ctype.c:599
#, c-format
msgid "character <SP> not defined in character map"
-msgstr "<SP>-teken is niet gedefinieerd in tekenskaart"
+msgstr "<SP>-teken is niet gedefinieerd in tekensetdefinitie"
#: locale/programs/ld-ctype.c:714
#, c-format
@@ -2033,12 +2034,12 @@ msgstr "het aantal items in de cijferscategorie is geen veelvoud van tien"
#: locale/programs/ld-ctype.c:763
#, c-format
msgid "no input digits defined and none of the standard names in the charmap"
-msgstr "er zijn geen invoercijfers gedefinieerd en geen van de standaardnamen zit in de tekenskaart"
+msgstr "er zijn geen invoercijfers gedefinieerd en geen van de standaardnamen zit in de tekensetdefinitie"
#: locale/programs/ld-ctype.c:828
#, c-format
msgid "not all characters used in `outdigit' are available in the charmap"
-msgstr "niet alle tekens gebruikt in 'outdigit' zijn beschikbaar in de tekenskaart"
+msgstr "niet alle tekens in 'outdigit' zijn beschikbaar in de tekensetdefinitie"
#: locale/programs/ld-ctype.c:845
#, c-format
@@ -2058,12 +2059,12 @@ msgstr "implementatiegrens: er zijn niet meer dan %Zd tekenklasses toegestaan"
#: locale/programs/ld-ctype.c:1277
#, c-format
msgid "character map `%s' already defined"
-msgstr "tekenskaart '%s' is al gedefinieerd"
+msgstr "tekensetdefinitie '%s' is al gedefinieerd"
#: locale/programs/ld-ctype.c:1283
#, c-format
msgid "implementation limit: no more than %d character maps allowed"
-msgstr "implementatiegrens: er zijn niet meer dan %d tekenskaarten toegestaan"
+msgstr "implementatiegrens: er zijn niet meer dan %d tekensetdefinities toegestaan"
#: locale/programs/ld-ctype.c:1548 locale/programs/ld-ctype.c:1673
#: locale/programs/ld-ctype.c:1779 locale/programs/ld-ctype.c:2471
@@ -2102,7 +2103,7 @@ msgstr "%s: syntaxfout in definitie van nieuwe tekenklasse"
#: locale/programs/ld-ctype.c:2318
#, c-format
msgid "%s: syntax error in definition of new character map"
-msgstr "%s: syntaxfout in definitie van nieuwe tekenskaart"
+msgstr "%s: syntaxfout in nieuwe tekensetdefinitie"
#: locale/programs/ld-ctype.c:2493
msgid "ellipsis range must be marked by two operands of same type"
@@ -2161,7 +2162,7 @@ msgstr "%s: teken '%s' is niet gedefinieerd maar is nodig als standaardwaarde"
#: locale/programs/ld-ctype.c:3297 locale/programs/ld-ctype.c:3364
#, c-format
msgid "%s: character `%s' in charmap not representable with one byte"
-msgstr "%s: teken '%s' in de tekenskaart is niet te representeren met één byte"
+msgstr "%s: teken '%s' in de tekensetdefinitie is niet te representeren met één byte"
#: locale/programs/ld-ctype.c:3408 locale/programs/ld-ctype.c:3433
#, c-format
@@ -2171,7 +2172,7 @@ msgstr "%s: teken '%s' is nodig als standaardwaarde maar niet te representeren m
#: locale/programs/ld-ctype.c:3489
#, c-format
msgid "no output digits defined and none of the standard names in the charmap"
-msgstr "er zijn geen uitvoercijfers gedefinieerd en geen van de standaardnamen zit in de tekenskaart"
+msgstr "er zijn geen uitvoercijfers gedefinieerd en geen van de standaardnamen zit in de tekensetdefinitie"
#: locale/programs/ld-ctype.c:3780
#, c-format
@@ -2380,7 +2381,7 @@ msgstr "niet-symbolische tekenwaarden zouden niet gebruikt moeten worden"
#: locale/programs/linereader.c:816
#, c-format
msgid "symbol `%.*s' not in charmap"
-msgstr "symbool '%.*s' zit niet in de tekenskaart"
+msgstr "symbool '%.*s' zit niet in de tekensetdefinitie"
#: locale/programs/linereader.c:837
#, c-format
@@ -2393,11 +2394,11 @@ msgstr "Systeeminformatie:"
#: locale/programs/locale.c:76
msgid "Write names of available locales"
-msgstr "namen van de beschikbare taalregio's tonen"
+msgstr "namen van beschikbare taalregio's tonen"
#: locale/programs/locale.c:78
msgid "Write names of available charmaps"
-msgstr "namen van de beschikbare tekenskaarten tonen"
+msgstr "namen van beschikbare tekensetdefinities tonen"
#: locale/programs/locale.c:79
msgid "Modify output format:"
@@ -2570,9 +2571,9 @@ msgid ""
" locale path : %s\n"
"%s"
msgstr ""
-"Systeemmap voor tekenskaarten: %s\n"
-" voor repertoirekaarten: %s\n"
-" en het taalregiopad is: %s\n"
+"Systeemmap voor tekensetdefinities: %s\n"
+" voor repertoirekaarten: %s\n"
+" en het taalregiopad is: %s\n"
"\n"
"%s"
@@ -2880,7 +2881,7 @@ msgstr ""
"\n"
" -?,--help deze hulptekst tonen\n"
" --usage een korte gebruikssamenvatting tonen\n"
-" -V,--version versie-informatie tonen\n"
+" -V,--version programmaversie tonen\n"
"\n"
" De volgende opties zijn alleen bij grafische uitvoer van toepassing:\n"
" -t,--time-based de grafiek lineair in de tijd maken\n"
diff --git a/libc/posix/glob.c b/libc/posix/glob.c
index 464859a75..ae1b6f6e0 100644
--- a/libc/posix/glob.c
+++ b/libc/posix/glob.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991-2002, 2003, 2004, 2005, 2006, 2007
+/* Copyright (C) 1991-2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -1080,8 +1080,7 @@ globfree (pglob)
{
size_t i;
for (i = 0; i < pglob->gl_pathc; ++i)
- if (pglob->gl_pathv[pglob->gl_offs + i] != NULL)
- free (pglob->gl_pathv[pglob->gl_offs + i]);
+ free (pglob->gl_pathv[pglob->gl_offs + i]);
free (pglob->gl_pathv);
pglob->gl_pathv = NULL;
}
diff --git a/libc/posix/globtest.sh b/libc/posix/globtest.sh
index a1c38b8ac..235b4d0d4 100755
--- a/libc/posix/globtest.sh
+++ b/libc/posix/globtest.sh
@@ -746,8 +746,9 @@ cat <<"EOF" | $CMP - $testout >> $logfile || failed=1
`dir6/fil*[a'
`nondir\/'
EOF
-HOME="$testdir" \
-${run_program_prefix} \
+${cross_test_wrapper} \
+env HOME="$testdir" \
+${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \
${common_objpfx}posix/globtest -ct "$testdir" \
'~/dir1/file1_1' '~/dir1/file1_9' '~/dir3\*/file1' '~/dir3\*/file2' \
'~\/dir1/file1_2' |
diff --git a/libc/posix/regcomp.c b/libc/posix/regcomp.c
index 5049da401..0701e49be 100644
--- a/libc/posix/regcomp.c
+++ b/libc/posix/regcomp.c
@@ -1046,7 +1046,9 @@ optimize_utf8 (re_dfa_t *dfa)
case BUF_LAST:
break;
default:
- /* Word anchors etc. cannot be handled. */
+ /* Word anchors etc. cannot be handled. It's okay to test
+ opr.ctx_type since constraints (for all DFA nodes) are
+ created by ORing one or more opr.ctx_type values. */
return;
}
break;
@@ -1326,6 +1328,8 @@ calc_first (void *extra, bin_tree_t *node)
node->node_idx = re_dfa_add_node (dfa, node->token);
if (BE (node->node_idx == -1, 0))
return REG_ESPACE;
+ if (node->token.type == ANCHOR)
+ dfa->nodes[node->node_idx].constraint = node->token.opr.ctx_type;
}
return REG_NOERROR;
}
@@ -1454,22 +1458,17 @@ duplicate_node_closure (re_dfa_t *dfa, int top_org_node, int top_clone_node,
destination. */
org_dest = dfa->edests[org_node].elems[0];
re_node_set_empty (dfa->edests + clone_node);
- if (dfa->nodes[org_node].type == ANCHOR)
+ /* If the node is root_node itself, it means the epsilon clsoure
+ has a loop. Then tie it to the destination of the root_node. */
+ if (org_node == root_node && clone_node != org_node)
{
- /* In case of the node has another constraint, append it. */
- if (org_node == root_node && clone_node != org_node)
- {
- /* ...but if the node is root_node itself, it means the
- epsilon closure have a loop, then tie it to the
- destination of the root_node. */
- ret = re_node_set_insert (dfa->edests + clone_node,
- org_dest);
- if (BE (ret < 0, 0))
- return REG_ESPACE;
- break;
- }
- constraint |= dfa->nodes[org_node].opr.ctx_type;
+ ret = re_node_set_insert (dfa->edests + clone_node, org_dest);
+ if (BE (ret < 0, 0))
+ return REG_ESPACE;
+ break;
}
+ /* In case of the node has another constraint, add it. */
+ constraint |= dfa->nodes[org_node].constraint;
clone_dest = duplicate_node (dfa, org_dest, constraint);
if (BE (clone_dest == -1, 0))
return REG_ESPACE;
@@ -1487,7 +1486,7 @@ duplicate_node_closure (re_dfa_t *dfa, int top_org_node, int top_clone_node,
clone_dest = search_duplicated_node (dfa, org_dest, constraint);
if (clone_dest == -1)
{
- /* There are no such a duplicated node, create a new one. */
+ /* There is no such duplicated node, create a new one. */
reg_errcode_t err;
clone_dest = duplicate_node (dfa, org_dest, constraint);
if (BE (clone_dest == -1, 0))
@@ -1502,7 +1501,7 @@ duplicate_node_closure (re_dfa_t *dfa, int top_org_node, int top_clone_node,
}
else
{
- /* There are a duplicated node which satisfy the constraint,
+ /* There is a duplicated node which satisfies the constraint,
use it to avoid infinite loop. */
ret = re_node_set_insert (dfa->edests + clone_node, clone_dest);
if (BE (ret < 0, 0))
@@ -1551,8 +1550,7 @@ duplicate_node (re_dfa_t *dfa, int org_idx, unsigned int constraint)
if (BE (dup_idx != -1, 1))
{
dfa->nodes[dup_idx].constraint = constraint;
- if (dfa->nodes[org_idx].type == ANCHOR)
- dfa->nodes[dup_idx].constraint |= dfa->nodes[org_idx].opr.ctx_type;
+ dfa->nodes[dup_idx].constraint |= dfa->nodes[org_idx].constraint;
dfa->nodes[dup_idx].duplicated = 1;
/* Store the index of the original node. */
@@ -1632,7 +1630,6 @@ static reg_errcode_t
calc_eclosure_iter (re_node_set *new_set, re_dfa_t *dfa, int node, int root)
{
reg_errcode_t err;
- unsigned int constraint;
int i, incomplete;
re_node_set eclosure;
incomplete = 0;
@@ -1644,15 +1641,14 @@ calc_eclosure_iter (re_node_set *new_set, re_dfa_t *dfa, int node, int root)
We reference this value to avoid infinite loop. */
dfa->eclosures[node].nelem = -1;
- constraint = ((dfa->nodes[node].type == ANCHOR)
- ? dfa->nodes[node].opr.ctx_type : 0);
- /* If the current node has constraints, duplicate all nodes.
- Since they must inherit the constraints. */
- if (constraint
+ /* If the current node has constraints, duplicate all nodes
+ since they must inherit the constraints. */
+ if (dfa->nodes[node].constraint
&& dfa->edests[node].nelem
&& !dfa->nodes[dfa->edests[node].elems[0]].duplicated)
{
- err = duplicate_node_closure (dfa, node, node, node, constraint);
+ err = duplicate_node_closure (dfa, node, node, node,
+ dfa->nodes[node].constraint);
if (BE (err != REG_NOERROR, 0))
return err;
}
diff --git a/libc/posix/regex_internal.c b/libc/posix/regex_internal.c
index 08c8cca24..9b3bc8b01 100644
--- a/libc/posix/regex_internal.c
+++ b/libc/posix/regex_internal.c
@@ -1666,11 +1666,9 @@ create_cd_newstate (const re_dfa_t *dfa, const re_node_set *nodes,
for (i = 0 ; i < nodes->nelem ; i++)
{
- unsigned int constraint = 0;
re_token_t *node = dfa->nodes + nodes->elems[i];
re_token_type_t type = node->type;
- if (node->constraint)
- constraint = node->constraint;
+ unsigned int constraint = node->constraint;
if (type == CHARACTER && !constraint)
continue;
@@ -1683,8 +1681,6 @@ create_cd_newstate (const re_dfa_t *dfa, const re_node_set *nodes,
newstate->halt = 1;
else if (type == OP_BACK_REF)
newstate->has_backref = 1;
- else if (type == ANCHOR)
- constraint = node->opr.ctx_type;
if (constraint)
{
diff --git a/libc/posix/tst-regex.c b/libc/posix/tst-regex.c
index 6a71e1239..a7fba698f 100644
--- a/libc/posix/tst-regex.c
+++ b/libc/posix/tst-regex.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2001, 2003 Free Software Foundation, Inc.
+/* Copyright (C) 2001, 2003, 2008 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
@@ -55,8 +55,8 @@ static int run_test_backwards (const char *expr, const char *mem,
size_t memlen, int icase, int expected);
-int
-main (int argc, char *argv[])
+static int
+do_test (void)
{
const char *file;
int fd;
@@ -66,16 +66,9 @@ main (int argc, char *argv[])
char *outmem;
size_t inlen;
size_t outlen;
- static const struct option options[] =
- {
- {"timing",no_argument, &timing, 1 },
- {NULL, 0, NULL, 0 }
- };
mtrace ();
- while (getopt_long (argc, argv, "", options, NULL) >= 0);
-
/* Make the content of the file available in memory. */
file = "../ChangeLog.8";
fd = open (file, O_RDONLY);
@@ -506,3 +499,10 @@ run_test_backwards (const char *expr, const char *mem, size_t memlen,
expect. */
return cnt != expected;
}
+
+/* If --timing is used we will need a larger timout. */
+#define TIMEOUT 50
+#define CMDLINE_OPTIONS \
+ {"timing", no_argument, &timing, 1 },
+#define TEST_FUNCTION do_test ()
+#include "../test-skeleton.c"
diff --git a/libc/posix/tst-rfc3484-2.c b/libc/posix/tst-rfc3484-2.c
index 56c0277b1..c85fdd074 100644
--- a/libc/posix/tst-rfc3484-2.c
+++ b/libc/posix/tst-rfc3484-2.c
@@ -18,24 +18,35 @@ __check_pf (bool *p1, bool *p2, struct in6addrinfo **in6ai, size_t *in6ailen)
*in6ai = NULL;
*in6ailen = 0;
}
+
void
attribute_hidden
__check_native (uint32_t a1_index, int *a1_native,
uint32_t a2_index, int *a2_native)
{
}
+
int
+attribute_hidden
__idna_to_ascii_lz (const char *input, char **output, int flags)
{
return 0;
}
+
int
+attribute_hidden
__idna_to_unicode_lzlz (const char *input, char **output, int flags)
{
*output = NULL;
return 0;
}
+void
+attribute_hidden
+_res_hconf_init (void)
+{
+}
+
#include "../sysdeps/posix/getaddrinfo.c"
service_user *__nss_hosts_database attribute_hidden;
diff --git a/libc/posix/tst-rfc3484-3.c b/libc/posix/tst-rfc3484-3.c
index 616722eb1..3aa4563c0 100644
--- a/libc/posix/tst-rfc3484-3.c
+++ b/libc/posix/tst-rfc3484-3.c
@@ -18,24 +18,35 @@ __check_pf (bool *p1, bool *p2, struct in6addrinfo **in6ai, size_t *in6ailen)
*in6ai = NULL;
*in6ailen = 0;
}
+
void
attribute_hidden
__check_native (uint32_t a1_index, int *a1_native,
uint32_t a2_index, int *a2_native)
{
}
+
int
+attribute_hidden
__idna_to_ascii_lz (const char *input, char **output, int flags)
{
return 0;
}
+
int
+attribute_hidden
__idna_to_unicode_lzlz (const char *input, char **output, int flags)
{
*output = NULL;
return 0;
}
+void
+attribute_hidden
+_res_hconf_init (void)
+{
+}
+
#include "../sysdeps/posix/getaddrinfo.c"
service_user *__nss_hosts_database attribute_hidden;
diff --git a/libc/posix/tst-rfc3484.c b/libc/posix/tst-rfc3484.c
index 4df5b2951..15d0c94a5 100644
--- a/libc/posix/tst-rfc3484.c
+++ b/libc/posix/tst-rfc3484.c
@@ -18,24 +18,35 @@ __check_pf (bool *p1, bool *p2, struct in6addrinfo **in6ai, size_t *in6ailen)
*in6ai = NULL;
*in6ailen = 0;
}
+
void
attribute_hidden
__check_native (uint32_t a1_index, int *a1_native,
uint32_t a2_index, int *a2_native)
{
}
+
int
+attribute_hidden
__idna_to_ascii_lz (const char *input, char **output, int flags)
{
return 0;
}
+
int
+attribute_hidden
__idna_to_unicode_lzlz (const char *input, char **output, int flags)
{
*output = NULL;
return 0;
}
+void
+attribute_hidden
+_res_hconf_init (void)
+{
+}
+
#include "../sysdeps/posix/getaddrinfo.c"
service_user *__nss_hosts_database attribute_hidden;
diff --git a/libc/posix/unistd.h b/libc/posix/unistd.h
index 01ac3f8b4..96bb02dff 100644
--- a/libc/posix/unistd.h
+++ b/libc/posix/unistd.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991-2006, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 1991-2006, 2007, 2008 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
@@ -383,6 +383,12 @@ extern ssize_t pwrite64 (int __fd, __const void *__buf, size_t __n,
Returns 0 if successful, -1 if not. */
extern int pipe (int __pipedes[2]) __THROW __wur;
+#ifdef __USE_GNU
+/* Same as pipe but apply flags passed in FLAGS to the new file
+ descriptors. */
+extern int pipe2 (int __pipedes[2], int __flags) __THROW __wur;
+#endif
+
/* Schedule an alarm. In SECONDS seconds, the process will get a SIGALRM.
If SECONDS is zero, any currently scheduled alarm will be cancelled.
The function returns the number of seconds remaining until the last
@@ -492,6 +498,12 @@ extern int dup (int __fd) __THROW __wur;
/* Duplicate FD to FD2, closing FD2 and making it open on the same file. */
extern int dup2 (int __fd, int __fd2) __THROW;
+#ifdef __USE_GNU
+/* Duplicate FD to FD2, closing FD2 and making it open on the same
+ file while setting flags according to FLAGS. */
+extern int dup3 (int __fd, int __fd2, int __flags) __THROW;
+#endif
+
/* NULL-terminated array of "NAME=VALUE" environment variables. */
extern char **__environ;
#ifdef __USE_GNU
diff --git a/libc/posix/wordexp.c b/libc/posix/wordexp.c
index 765d14d81..058a7cfbe 100644
--- a/libc/posix/wordexp.c
+++ b/libc/posix/wordexp.c
@@ -1,5 +1,5 @@
/* POSIX.2 wordexp implementation.
- Copyright (C) 1997-2002, 2003, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1997-2003, 2005, 2006, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Tim Waugh <tim@cyberelk.demon.co.uk>.
@@ -42,6 +42,7 @@
# include <wchar.h>
#endif
#include <wordexp.h>
+#include <kernel-features.h>
#include <bits/libc-lock.h>
#include <stdio-common/_itoa.h>
@@ -824,17 +825,30 @@ exec_comm_child (char *comm, int *fildes, int showerr, int noexec)
args[1] = "-nc";
/* Redirect output. */
- __dup2 (fildes[1], STDOUT_FILENO);
- __close (fildes[1]);
+ if (__builtin_expect (fildes[1] != STDOUT_FILENO, 1))
+ {
+ __dup2 (fildes[1], STDOUT_FILENO);
+ __close (fildes[1]);
+ }
+ else
+ {
+#ifdef O_CLOEXEC
+ /* Reset the close-on-exec flag (if necessary). */
+# ifndef __ASSUME_PIPE2
+ if (__have_pipe2 > 0)
+# endif
+ __fcntl (fildes[1], F_SETFD, 0);
+#endif
+ }
/* Redirect stderr to /dev/null if we have to. */
if (showerr == 0)
{
struct stat64 st;
int fd;
- __close (2);
+ __close (STDERR_FILENO);
fd = __open (_PATH_DEVNULL, O_WRONLY);
- if (fd >= 0 && fd != 2)
+ if (fd >= 0 && fd != STDERR_FILENO)
{
__dup2 (fd, STDERR_FILENO);
__close (fd);
@@ -885,18 +899,38 @@ exec_comm (char *comm, char **word, size_t *word_length, size_t *max_length,
if (!comm || !*comm)
return 0;
- if (__pipe (fildes))
- /* Bad */
- return WRDE_NOSPACE;
+#ifdef O_CLOEXEC
+# ifndef __ASSUME_PIPE2
+ if (__have_pipe2 >= 0)
+# endif
+ {
+ int r = __pipe2 (fildes, O_CLOEXEC);
+# ifndef __ASSUME_PIPE2
+ if (__have_pipe2 == 0)
+ __have_pipe2 = r != -1 || errno != ENOSYS ? 1 : -1;
+
+ if (__have_pipe2 > 0)
+# endif
+ if (r < 0)
+ /* Bad */
+ return WRDE_NOSPACE;
+ }
+#endif
+#ifndef __ASSUME_PIPE2
+# ifdef O_CLOEXEC
+ if (__have_pipe2 < 0)
+# endif
+ if (__pipe (fildes) < 0)
+ /* Bad */
+ return WRDE_NOSPACE;
+#endif
again:
if ((pid = __fork ()) < 0)
{
/* Bad */
- if (fildes[0] != -1)
- __close (fildes[0]);
- if (fildes[1] != -1)
- __close (fildes[1]);
+ __close (fildes[0]);
+ __close (fildes[1]);
return WRDE_NOSPACE;
}
diff --git a/libc/resolv/Makefile b/libc/resolv/Makefile
index 3575e0e28..cc2739eae 100644
--- a/libc/resolv/Makefile
+++ b/libc/resolv/Makefile
@@ -1,5 +1,4 @@
-# Copyright (C) 1994,1995,1996,1997,1998,1999,2000,2001,2003,2004,2007
-# Free Software Foundation, Inc.
+# Copyright (C) 1994-2001,2003,2004,2007,2008 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
@@ -52,7 +51,7 @@ libresolv-routines := gethnamaddr res_comp res_debug \
res_data res_mkquery res_query res_send \
inet_net_ntop inet_net_pton inet_neta base64 \
ns_parse ns_name ns_netint ns_ttl ns_print \
- ns_samedomain
+ ns_samedomain ns_date
libanl-routines := gai_cancel gai_error gai_misc gai_notify gai_suspend \
getaddrinfo_a
diff --git a/libc/resolv/Versions b/libc/resolv/Versions
index fc2111a1c..4b2e5e9db 100644
--- a/libc/resolv/Versions
+++ b/libc/resolv/Versions
@@ -74,6 +74,19 @@ libresolv {
GLIBC_2.3.2 {
__p_rcode;
}
+ GLIBC_2.9 {
+ ns_msg_getflag;
+ ns_get16; ns_get32; ns_put16; ns_put32;
+ ns_initparse; ns_skiprr; ns_parserr;
+ ns_sprintrr; ns_sprintrrf;
+ ns_format_ttl; ns_parse_ttl;
+ ns_datetosecs;
+ ns_name_ntol; ns_name_ntop; ns_name_pton;
+ ns_name_unpack; ns_name_pack;
+ ns_name_uncompress; ns_name_compress;
+ ns_name_skip; ns_name_rollback;
+ ns_samedomain; ns_subdomain; ns_makecanon; ns_samename;
+ }
GLIBC_PRIVATE {
# Needed in libnss_dns.
__ns_name_unpack; __ns_name_ntop;
@@ -89,6 +102,7 @@ libnss_dns {
_nss_dns_gethostbyname_r; _nss_dns_getnetbyaddr_r;
_nss_dns_getnetbyname_r; _nss_dns_getcanonname_r;
_nss_dns_gethostbyaddr2_r;
+ _nss_dns_gethostbyname4_r;
}
}
diff --git a/libc/resolv/arpa/nameser.h b/libc/resolv/arpa/nameser.h
index a164221df..7979b3d4d 100644
--- a/libc/resolv/arpa/nameser.h
+++ b/libc/resolv/arpa/nameser.h
@@ -28,6 +28,7 @@
*/
/*
+ * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 1996-1999 by Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -51,6 +52,8 @@
#ifndef _ARPA_NAMESER_H_
#define _ARPA_NAMESER_H_
+/*! \file */
+
#define BIND_4_COMPAT
#include <sys/param.h>
@@ -61,7 +64,7 @@
#endif
#include <sys/cdefs.h>
-/*
+/*%
* Revision information. This is the release date in YYYYMMDD format.
* It can change every day so the right thing to do with it is use it
* in preprocessor commands such as "#if (__NAMESER > 19931104)". Do not
@@ -69,42 +72,41 @@
* contains a new enough lib/nameser/ to support the feature you need.
*/
-#define __NAMESER 19991006 /* New interface version stamp. */
-
+#define __NAMESER 19991006 /*%< New interface version stamp. */
/*
* Define constants based on RFC 883, RFC 1034, RFC 1035
*/
-#define NS_PACKETSZ 512 /* maximum packet size */
-#define NS_MAXDNAME 1025 /* maximum domain name */
-#define NS_MAXCDNAME 255 /* maximum compressed domain name */
-#define NS_MAXLABEL 63 /* maximum length of domain label */
-#define NS_HFIXEDSZ 12 /* #/bytes of fixed data in header */
-#define NS_QFIXEDSZ 4 /* #/bytes of fixed data in query */
-#define NS_RRFIXEDSZ 10 /* #/bytes of fixed data in r record */
-#define NS_INT32SZ 4 /* #/bytes of data in a u_int32_t */
-#define NS_INT16SZ 2 /* #/bytes of data in a u_int16_t */
-#define NS_INT8SZ 1 /* #/bytes of data in a u_int8_t */
-#define NS_INADDRSZ 4 /* IPv4 T_A */
-#define NS_IN6ADDRSZ 16 /* IPv6 T_AAAA */
-#define NS_CMPRSFLGS 0xc0 /* Flag bits indicating name compression. */
-#define NS_DEFAULTPORT 53 /* For both TCP and UDP. */
-
+#define NS_PACKETSZ 512 /*%< default UDP packet size */
+#define NS_MAXDNAME 1025 /*%< maximum domain name */
+#define NS_MAXMSG 65535 /*%< maximum message size */
+#define NS_MAXCDNAME 255 /*%< maximum compressed domain name */
+#define NS_MAXLABEL 63 /*%< maximum length of domain label */
+#define NS_HFIXEDSZ 12 /*%< #/bytes of fixed data in header */
+#define NS_QFIXEDSZ 4 /*%< #/bytes of fixed data in query */
+#define NS_RRFIXEDSZ 10 /*%< #/bytes of fixed data in r record */
+#define NS_INT32SZ 4 /*%< #/bytes of data in a u_int32_t */
+#define NS_INT16SZ 2 /*%< #/bytes of data in a u_int16_t */
+#define NS_INT8SZ 1 /*%< #/bytes of data in a u_int8_t */
+#define NS_INADDRSZ 4 /*%< IPv4 T_A */
+#define NS_IN6ADDRSZ 16 /*%< IPv6 T_AAAA */
+#define NS_CMPRSFLGS 0xc0 /*%< Flag bits indicating name compression. */
+#define NS_DEFAULTPORT 53 /*%< For both TCP and UDP. */
/*
* These can be expanded with synonyms, just keep ns_parse.c:ns_parserecord()
* in synch with it.
*/
typedef enum __ns_sect {
- ns_s_qd = 0, /* Query: Question. */
- ns_s_zn = 0, /* Update: Zone. */
- ns_s_an = 1, /* Query: Answer. */
- ns_s_pr = 1, /* Update: Prerequisites. */
- ns_s_ns = 2, /* Query: Name servers. */
- ns_s_ud = 2, /* Update: Update. */
- ns_s_ar = 3, /* Query|Update: Additional records. */
+ ns_s_qd = 0, /*%< Query: Question. */
+ ns_s_zn = 0, /*%< Update: Zone. */
+ ns_s_an = 1, /*%< Query: Answer. */
+ ns_s_pr = 1, /*%< Update: Prerequisites. */
+ ns_s_ns = 2, /*%< Query: Name servers. */
+ ns_s_ud = 2, /*%< Update: Update. */
+ ns_s_ar = 3, /*%< Query|Update: Additional records. */
ns_s_max = 4
} ns_sect;
-/*
+/*%
* This is a message handle. It is caller allocated and has no dynamic data.
* This structure is intended to be opaque to all but ns_parse.c, thus the
* leading _'s on the member names. Use the accessor functions, not the _'s.
@@ -115,25 +117,22 @@ typedef struct __ns_msg {
const u_char *_sections[ns_s_max];
ns_sect _sect;
int _rrnum;
- const u_char *_ptr;
+ const u_char *_msg_ptr;
} ns_msg;
/* Private data structure - do not use from outside library. */
struct _ns_flagdata { int mask, shift; };
-extern struct _ns_flagdata _ns_flagdata[];
+extern const struct _ns_flagdata _ns_flagdata[];
/* Accessor macros - this is part of the public interface. */
-#define ns_msg_getflag(handle, flag) ( \
- ((handle)._flags & _ns_flagdata[flag].mask) \
- >> _ns_flagdata[flag].shift \
- )
+
#define ns_msg_id(handle) ((handle)._id + 0)
#define ns_msg_base(handle) ((handle)._msg + 0)
#define ns_msg_end(handle) ((handle)._eom + 0)
#define ns_msg_size(handle) ((handle)._eom - (handle)._msg)
#define ns_msg_count(handle, section) ((handle)._counts[section] + 0)
-/*
+/*%
* This is a parsed record. It is caller allocated and has no dynamic data.
*/
typedef struct __ns_rr {
@@ -153,56 +152,58 @@ typedef struct __ns_rr {
#define ns_rr_rdlen(rr) ((rr).rdlength + 0)
#define ns_rr_rdata(rr) ((rr).rdata + 0)
-/*
+/*%
* These don't have to be in the same order as in the packet flags word,
* and they can even overlap in some cases, but they will need to be kept
* in synch with ns_parse.c:ns_flagdata[].
*/
typedef enum __ns_flag {
- ns_f_qr, /* Question/Response. */
- ns_f_opcode, /* Operation code. */
- ns_f_aa, /* Authoritative Answer. */
- ns_f_tc, /* Truncation occurred. */
- ns_f_rd, /* Recursion Desired. */
- ns_f_ra, /* Recursion Available. */
- ns_f_z, /* MBZ. */
- ns_f_ad, /* Authentic Data (DNSSEC). */
- ns_f_cd, /* Checking Disabled (DNSSEC). */
- ns_f_rcode, /* Response code. */
+ ns_f_qr, /*%< Question/Response. */
+ ns_f_opcode, /*%< Operation code. */
+ ns_f_aa, /*%< Authoritative Answer. */
+ ns_f_tc, /*%< Truncation occurred. */
+ ns_f_rd, /*%< Recursion Desired. */
+ ns_f_ra, /*%< Recursion Available. */
+ ns_f_z, /*%< MBZ. */
+ ns_f_ad, /*%< Authentic Data (DNSSEC). */
+ ns_f_cd, /*%< Checking Disabled (DNSSEC). */
+ ns_f_rcode, /*%< Response code. */
ns_f_max
} ns_flag;
-/*
+/*%
* Currently defined opcodes.
*/
typedef enum __ns_opcode {
- ns_o_query = 0, /* Standard query. */
- ns_o_iquery = 1, /* Inverse query (deprecated/unsupported). */
- ns_o_status = 2, /* Name server status query (unsupported). */
+ ns_o_query = 0, /*%< Standard query. */
+ ns_o_iquery = 1, /*%< Inverse query (deprecated/unsupported). */
+ ns_o_status = 2, /*%< Name server status query (unsupported). */
/* Opcode 3 is undefined/reserved. */
- ns_o_notify = 4, /* Zone change notification. */
- ns_o_update = 5, /* Zone update message. */
+ ns_o_notify = 4, /*%< Zone change notification. */
+ ns_o_update = 5, /*%< Zone update message. */
ns_o_max = 6
} ns_opcode;
-/*
+/*%
* Currently defined response codes.
*/
typedef enum __ns_rcode {
- ns_r_noerror = 0, /* No error occurred. */
- ns_r_formerr = 1, /* Format error. */
- ns_r_servfail = 2, /* Server failure. */
- ns_r_nxdomain = 3, /* Name error. */
- ns_r_notimpl = 4, /* Unimplemented. */
- ns_r_refused = 5, /* Operation refused. */
+ ns_r_noerror = 0, /*%< No error occurred. */
+ ns_r_formerr = 1, /*%< Format error. */
+ ns_r_servfail = 2, /*%< Server failure. */
+ ns_r_nxdomain = 3, /*%< Name error. */
+ ns_r_notimpl = 4, /*%< Unimplemented. */
+ ns_r_refused = 5, /*%< Operation refused. */
/* these are for BIND_UPDATE */
- ns_r_yxdomain = 6, /* Name exists */
- ns_r_yxrrset = 7, /* RRset exists */
- ns_r_nxrrset = 8, /* RRset does not exist */
- ns_r_notauth = 9, /* Not authoritative for zone */
- ns_r_notzone = 10, /* Zone of record different from zone section */
+ ns_r_yxdomain = 6, /*%< Name exists */
+ ns_r_yxrrset = 7, /*%< RRset exists */
+ ns_r_nxrrset = 8, /*%< RRset does not exist */
+ ns_r_notauth = 9, /*%< Not authoritative for zone */
+ ns_r_notzone = 10, /*%< Zone of record different from zone section */
ns_r_max = 11,
- /* The following are TSIG extended errors */
+ /* The following are EDNS extended rcodes */
+ ns_r_badvers = 16,
+ /* The following are TSIG errors */
ns_r_badsig = 16,
ns_r_badkey = 17,
ns_r_badtime = 18
@@ -215,7 +216,7 @@ typedef enum __ns_update_operation {
ns_uop_max = 2
} ns_update_operation;
-/*
+/*%
* This structure is used for TSIG authenticated messages
*/
struct ns_tsig_key {
@@ -225,7 +226,7 @@ struct ns_tsig_key {
};
typedef struct ns_tsig_key ns_tsig_key;
-/*
+/*%
* This structure is used for TSIG authenticated TCP messages
*/
struct ns_tcp_tsig_state {
@@ -245,59 +246,61 @@ typedef struct ns_tcp_tsig_state ns_tcp_tsig_state;
#define NS_TSIG_ERROR_NO_SPACE -11
#define NS_TSIG_ERROR_FORMERR -12
-/*
+/*%
* Currently defined type values for resources and queries.
*/
typedef enum __ns_type {
- ns_t_invalid = 0, /* Cookie. */
- ns_t_a = 1, /* Host address. */
- ns_t_ns = 2, /* Authoritative server. */
- ns_t_md = 3, /* Mail destination. */
- ns_t_mf = 4, /* Mail forwarder. */
- ns_t_cname = 5, /* Canonical name. */
- ns_t_soa = 6, /* Start of authority zone. */
- ns_t_mb = 7, /* Mailbox domain name. */
- ns_t_mg = 8, /* Mail group member. */
- ns_t_mr = 9, /* Mail rename name. */
- ns_t_null = 10, /* Null resource record. */
- ns_t_wks = 11, /* Well known service. */
- ns_t_ptr = 12, /* Domain name pointer. */
- ns_t_hinfo = 13, /* Host information. */
- ns_t_minfo = 14, /* Mailbox information. */
- ns_t_mx = 15, /* Mail routing information. */
- ns_t_txt = 16, /* Text strings. */
- ns_t_rp = 17, /* Responsible person. */
- ns_t_afsdb = 18, /* AFS cell database. */
- ns_t_x25 = 19, /* X_25 calling address. */
- ns_t_isdn = 20, /* ISDN calling address. */
- ns_t_rt = 21, /* Router. */
- ns_t_nsap = 22, /* NSAP address. */
- ns_t_nsap_ptr = 23, /* Reverse NSAP lookup (deprecated). */
- ns_t_sig = 24, /* Security signature. */
- ns_t_key = 25, /* Security key. */
- ns_t_px = 26, /* X.400 mail mapping. */
- ns_t_gpos = 27, /* Geographical position (withdrawn). */
- ns_t_aaaa = 28, /* Ip6 Address. */
- ns_t_loc = 29, /* Location Information. */
- ns_t_nxt = 30, /* Next domain (security). */
- ns_t_eid = 31, /* Endpoint identifier. */
- ns_t_nimloc = 32, /* Nimrod Locator. */
- ns_t_srv = 33, /* Server Selection. */
- ns_t_atma = 34, /* ATM Address */
- ns_t_naptr = 35, /* Naming Authority PoinTeR */
- ns_t_kx = 36, /* Key Exchange */
- ns_t_cert = 37, /* Certification record */
- ns_t_a6 = 38, /* IPv6 address (deprecated, use ns_t_aaaa) */
- ns_t_dname = 39, /* Non-terminal DNAME (for IPv6) */
- ns_t_sink = 40, /* Kitchen sink (experimentatl) */
- ns_t_opt = 41, /* EDNS0 option (meta-RR) */
- ns_t_tsig = 250, /* Transaction signature. */
- ns_t_ixfr = 251, /* Incremental zone transfer. */
- ns_t_axfr = 252, /* Transfer zone of authority. */
- ns_t_mailb = 253, /* Transfer mailbox records. */
- ns_t_maila = 254, /* Transfer mail agent records. */
- ns_t_any = 255, /* Wildcard match. */
- ns_t_zxfr = 256, /* BIND-specific, nonstandard. */
+ ns_t_invalid = 0, /*%< Cookie. */
+ ns_t_a = 1, /*%< Host address. */
+ ns_t_ns = 2, /*%< Authoritative server. */
+ ns_t_md = 3, /*%< Mail destination. */
+ ns_t_mf = 4, /*%< Mail forwarder. */
+ ns_t_cname = 5, /*%< Canonical name. */
+ ns_t_soa = 6, /*%< Start of authority zone. */
+ ns_t_mb = 7, /*%< Mailbox domain name. */
+ ns_t_mg = 8, /*%< Mail group member. */
+ ns_t_mr = 9, /*%< Mail rename name. */
+ ns_t_null = 10, /*%< Null resource record. */
+ ns_t_wks = 11, /*%< Well known service. */
+ ns_t_ptr = 12, /*%< Domain name pointer. */
+ ns_t_hinfo = 13, /*%< Host information. */
+ ns_t_minfo = 14, /*%< Mailbox information. */
+ ns_t_mx = 15, /*%< Mail routing information. */
+ ns_t_txt = 16, /*%< Text strings. */
+ ns_t_rp = 17, /*%< Responsible person. */
+ ns_t_afsdb = 18, /*%< AFS cell database. */
+ ns_t_x25 = 19, /*%< X_25 calling address. */
+ ns_t_isdn = 20, /*%< ISDN calling address. */
+ ns_t_rt = 21, /*%< Router. */
+ ns_t_nsap = 22, /*%< NSAP address. */
+ ns_t_nsap_ptr = 23, /*%< Reverse NSAP lookup (deprecated). */
+ ns_t_sig = 24, /*%< Security signature. */
+ ns_t_key = 25, /*%< Security key. */
+ ns_t_px = 26, /*%< X.400 mail mapping. */
+ ns_t_gpos = 27, /*%< Geographical position (withdrawn). */
+ ns_t_aaaa = 28, /*%< Ip6 Address. */
+ ns_t_loc = 29, /*%< Location Information. */
+ ns_t_nxt = 30, /*%< Next domain (security). */
+ ns_t_eid = 31, /*%< Endpoint identifier. */
+ ns_t_nimloc = 32, /*%< Nimrod Locator. */
+ ns_t_srv = 33, /*%< Server Selection. */
+ ns_t_atma = 34, /*%< ATM Address */
+ ns_t_naptr = 35, /*%< Naming Authority PoinTeR */
+ ns_t_kx = 36, /*%< Key Exchange */
+ ns_t_cert = 37, /*%< Certification record */
+ ns_t_a6 = 38, /*%< IPv6 address (deprecated, use ns_t_aaaa) */
+ ns_t_dname = 39, /*%< Non-terminal DNAME (for IPv6) */
+ ns_t_sink = 40, /*%< Kitchen sink (experimentatl) */
+ ns_t_opt = 41, /*%< EDNS0 option (meta-RR) */
+ ns_t_apl = 42, /*%< Address prefix list (RFC3123) */
+ ns_t_tkey = 249, /*%< Transaction key */
+ ns_t_tsig = 250, /*%< Transaction signature. */
+ ns_t_ixfr = 251, /*%< Incremental zone transfer. */
+ ns_t_axfr = 252, /*%< Transfer zone of authority. */
+ ns_t_mailb = 253, /*%< Transfer mailbox records. */
+ ns_t_maila = 254, /*%< Transfer mail agent records. */
+ ns_t_any = 255, /*%< Wildcard match. */
+ ns_t_zxfr = 256, /*%< BIND-specific, nonstandard. */
ns_t_max = 65536
} ns_type;
@@ -312,61 +315,61 @@ typedef enum __ns_type {
#define ns_t_xfr_p(t) ((t) == ns_t_axfr || (t) == ns_t_ixfr || \
(t) == ns_t_zxfr)
-/*
+/*%
* Values for class field
*/
typedef enum __ns_class {
- ns_c_invalid = 0, /* Cookie. */
- ns_c_in = 1, /* Internet. */
- ns_c_2 = 2, /* unallocated/unsupported. */
- ns_c_chaos = 3, /* MIT Chaos-net. */
- ns_c_hs = 4, /* MIT Hesiod. */
+ ns_c_invalid = 0, /*%< Cookie. */
+ ns_c_in = 1, /*%< Internet. */
+ ns_c_2 = 2, /*%< unallocated/unsupported. */
+ ns_c_chaos = 3, /*%< MIT Chaos-net. */
+ ns_c_hs = 4, /*%< MIT Hesiod. */
/* Query class values which do not appear in resource records */
- ns_c_none = 254, /* for prereq. sections in update requests */
- ns_c_any = 255, /* Wildcard match. */
+ ns_c_none = 254, /*%< for prereq. sections in update requests */
+ ns_c_any = 255, /*%< Wildcard match. */
ns_c_max = 65536
} ns_class;
/* DNSSEC constants. */
typedef enum __ns_key_types {
- ns_kt_rsa = 1, /* key type RSA/MD5 */
- ns_kt_dh = 2, /* Diffie Hellman */
- ns_kt_dsa = 3, /* Digital Signature Standard (MANDATORY) */
- ns_kt_private = 254 /* Private key type starts with OID */
+ ns_kt_rsa = 1, /*%< key type RSA/MD5 */
+ ns_kt_dh = 2, /*%< Diffie Hellman */
+ ns_kt_dsa = 3, /*%< Digital Signature Standard (MANDATORY) */
+ ns_kt_private = 254 /*%< Private key type starts with OID */
} ns_key_types;
typedef enum __ns_cert_types {
- cert_t_pkix = 1, /* PKIX (X.509v3) */
- cert_t_spki = 2, /* SPKI */
- cert_t_pgp = 3, /* PGP */
- cert_t_url = 253, /* URL private type */
- cert_t_oid = 254 /* OID private type */
+ cert_t_pkix = 1, /*%< PKIX (X.509v3) */
+ cert_t_spki = 2, /*%< SPKI */
+ cert_t_pgp = 3, /*%< PGP */
+ cert_t_url = 253, /*%< URL private type */
+ cert_t_oid = 254 /*%< OID private type */
} ns_cert_types;
/* Flags field of the KEY RR rdata. */
-#define NS_KEY_TYPEMASK 0xC000 /* Mask for "type" bits */
-#define NS_KEY_TYPE_AUTH_CONF 0x0000 /* Key usable for both */
-#define NS_KEY_TYPE_CONF_ONLY 0x8000 /* Key usable for confidentiality */
-#define NS_KEY_TYPE_AUTH_ONLY 0x4000 /* Key usable for authentication */
-#define NS_KEY_TYPE_NO_KEY 0xC000 /* No key usable for either; no key */
+#define NS_KEY_TYPEMASK 0xC000 /*%< Mask for "type" bits */
+#define NS_KEY_TYPE_AUTH_CONF 0x0000 /*%< Key usable for both */
+#define NS_KEY_TYPE_CONF_ONLY 0x8000 /*%< Key usable for confidentiality */
+#define NS_KEY_TYPE_AUTH_ONLY 0x4000 /*%< Key usable for authentication */
+#define NS_KEY_TYPE_NO_KEY 0xC000 /*%< No key usable for either; no key */
/* The type bits can also be interpreted independently, as single bits: */
-#define NS_KEY_NO_AUTH 0x8000 /* Key unusable for authentication */
-#define NS_KEY_NO_CONF 0x4000 /* Key unusable for confidentiality */
+#define NS_KEY_NO_AUTH 0x8000 /*%< Key unusable for authentication */
+#define NS_KEY_NO_CONF 0x4000 /*%< Key unusable for confidentiality */
#define NS_KEY_RESERVED2 0x2000 /* Security is *mandatory* if bit=0 */
-#define NS_KEY_EXTENDED_FLAGS 0x1000 /* reserved - must be zero */
-#define NS_KEY_RESERVED4 0x0800 /* reserved - must be zero */
-#define NS_KEY_RESERVED5 0x0400 /* reserved - must be zero */
-#define NS_KEY_NAME_TYPE 0x0300 /* these bits determine the type */
-#define NS_KEY_NAME_USER 0x0000 /* key is assoc. with user */
-#define NS_KEY_NAME_ENTITY 0x0200 /* key is assoc. with entity eg host */
-#define NS_KEY_NAME_ZONE 0x0100 /* key is zone key */
-#define NS_KEY_NAME_RESERVED 0x0300 /* reserved meaning */
-#define NS_KEY_RESERVED8 0x0080 /* reserved - must be zero */
-#define NS_KEY_RESERVED9 0x0040 /* reserved - must be zero */
-#define NS_KEY_RESERVED10 0x0020 /* reserved - must be zero */
-#define NS_KEY_RESERVED11 0x0010 /* reserved - must be zero */
-#define NS_KEY_SIGNATORYMASK 0x000F /* key can sign RR's of same name */
+#define NS_KEY_EXTENDED_FLAGS 0x1000 /*%< reserved - must be zero */
+#define NS_KEY_RESERVED4 0x0800 /*%< reserved - must be zero */
+#define NS_KEY_RESERVED5 0x0400 /*%< reserved - must be zero */
+#define NS_KEY_NAME_TYPE 0x0300 /*%< these bits determine the type */
+#define NS_KEY_NAME_USER 0x0000 /*%< key is assoc. with user */
+#define NS_KEY_NAME_ENTITY 0x0200 /*%< key is assoc. with entity eg host */
+#define NS_KEY_NAME_ZONE 0x0100 /*%< key is zone key */
+#define NS_KEY_NAME_RESERVED 0x0300 /*%< reserved meaning */
+#define NS_KEY_RESERVED8 0x0080 /*%< reserved - must be zero */
+#define NS_KEY_RESERVED9 0x0040 /*%< reserved - must be zero */
+#define NS_KEY_RESERVED10 0x0020 /*%< reserved - must be zero */
+#define NS_KEY_RESERVED11 0x0010 /*%< reserved - must be zero */
+#define NS_KEY_SIGNATORYMASK 0x000F /*%< key can sign RR's of same name */
#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED2 | \
NS_KEY_RESERVED4 | \
NS_KEY_RESERVED5 | \
@@ -374,16 +377,14 @@ typedef enum __ns_cert_types {
NS_KEY_RESERVED9 | \
NS_KEY_RESERVED10 | \
NS_KEY_RESERVED11 )
-#define NS_KEY_RESERVED_BITMASK2 0xFFFF /* no bits defined here */
-
+#define NS_KEY_RESERVED_BITMASK2 0xFFFF /*%< no bits defined here */
/* The Algorithm field of the KEY and SIG RR's is an integer, {1..254} */
-#define NS_ALG_MD5RSA 1 /* MD5 with RSA */
-#define NS_ALG_DH 2 /* Diffie Hellman KEY */
-#define NS_ALG_DSA 3 /* DSA KEY */
+#define NS_ALG_MD5RSA 1 /*%< MD5 with RSA */
+#define NS_ALG_DH 2 /*%< Diffie Hellman KEY */
+#define NS_ALG_DSA 3 /*%< DSA KEY */
#define NS_ALG_DSS NS_ALG_DSA
-#define NS_ALG_EXPIRE_ONLY 253 /* No alg, no security */
-#define NS_ALG_PRIVATE_OID 254 /* Key begins with OID giving alg */
-
+#define NS_ALG_EXPIRE_ONLY 253 /*%< No alg, no security */
+#define NS_ALG_PRIVATE_OID 254 /*%< Key begins with OID giving alg */
/* Protocol values */
/* value 0 is reserved */
#define NS_KEY_PROT_TLS 1
@@ -393,8 +394,8 @@ typedef enum __ns_cert_types {
#define NS_KEY_PROT_ANY 255
/* Signatures */
-#define NS_MD5RSA_MIN_BITS 512 /* Size of a mod or exp in bits */
-#define NS_MD5RSA_MAX_BITS 2552
+#define NS_MD5RSA_MIN_BITS 512 /*%< Size of a mod or exp in bits */
+#define NS_MD5RSA_MAX_BITS 4096
/* Total of binary mod and exp */
#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3)
/* Max length of text sig block */
@@ -407,15 +408,14 @@ typedef enum __ns_cert_types {
#define NS_DSA_MAX_BYTES 405
/* Offsets into SIG record rdata to find various values */
-#define NS_SIG_TYPE 0 /* Type flags */
-#define NS_SIG_ALG 2 /* Algorithm */
-#define NS_SIG_LABELS 3 /* How many labels in name */
-#define NS_SIG_OTTL 4 /* Original TTL */
-#define NS_SIG_EXPIR 8 /* Expiration time */
-#define NS_SIG_SIGNED 12 /* Signature time */
-#define NS_SIG_FOOT 16 /* Key footprint */
-#define NS_SIG_SIGNER 18 /* Domain name of who signed it */
-
+#define NS_SIG_TYPE 0 /*%< Type flags */
+#define NS_SIG_ALG 2 /*%< Algorithm */
+#define NS_SIG_LABELS 3 /*%< How many labels in name */
+#define NS_SIG_OTTL 4 /*%< Original TTL */
+#define NS_SIG_EXPIR 8 /*%< Expiration time */
+#define NS_SIG_SIGNED 12 /*%< Signature time */
+#define NS_SIG_FOOT 16 /*%< Key footprint */
+#define NS_SIG_SIGNER 18 /*%< Domain name of who signed it */
/* How RR types are represented as bit-flags in NXT records */
#define NS_NXT_BITS 8
#define NS_NXT_BIT_SET( n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS)))
@@ -423,16 +423,17 @@ typedef enum __ns_cert_types {
#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS)))
#define NS_NXT_MAX 127
-/*
- * EDNS0 extended flags, host order.
+/*%
+ * EDNS0 extended flags and option codes, host order.
*/
#define NS_OPT_DNSSEC_OK 0x8000U
+#define NS_OPT_NSID 3
-/*
+/*%
* Inline versions of get/put short/long. Pointer is advanced.
*/
#define NS_GET16(s, cp) do { \
- register u_char *t_cp = (u_char *)(cp); \
+ register const u_char *t_cp = (const u_char *)(cp); \
(s) = ((u_int16_t)t_cp[0] << 8) \
| ((u_int16_t)t_cp[1]) \
; \
@@ -440,7 +441,7 @@ typedef enum __ns_cert_types {
} while (0)
#define NS_GET32(l, cp) do { \
- register u_char *t_cp = (u_char *)(cp); \
+ register const u_char *t_cp = (const u_char *)(cp); \
(l) = ((u_int32_t)t_cp[0] << 24) \
| ((u_int32_t)t_cp[1] << 16) \
| ((u_int32_t)t_cp[2] << 8) \
@@ -467,43 +468,8 @@ typedef enum __ns_cert_types {
(cp) += NS_INT32SZ; \
} while (0)
-/*
- * ANSI C identifier hiding for bind's lib/nameser.
- */
-#define ns_get16 __ns_get16
-#define ns_get32 __ns_get32
-#define ns_put16 __ns_put16
-#define ns_put32 __ns_put32
-#define ns_initparse __ns_initparse
-#define ns_skiprr __ns_skiprr
-#define ns_parserr __ns_parserr
-#define ns_sprintrr __ns_sprintrr
-#define ns_sprintrrf __ns_sprintrrf
-#define ns_format_ttl __ns_format_ttl
-#define ns_parse_ttl __ns_parse_ttl
-#define ns_datetosecs __ns_datetosecs
-#define ns_name_ntol __ns_name_ntol
-#define ns_name_ntop __ns_name_ntop
-#define ns_name_pton __ns_name_pton
-#define ns_name_unpack __ns_name_unpack
-#define ns_name_pack __ns_name_pack
-#define ns_name_compress __ns_name_compress
-#define ns_name_uncompress __ns_name_uncompress
-#define ns_name_skip __ns_name_skip
-#define ns_name_rollback __ns_name_rollback
-#define ns_sign __ns_sign
-#define ns_sign_tcp __ns_sign_tcp
-#define ns_sign_tcp_init __ns_sign_tcp_init
-#define ns_find_tsig __ns_find_tsig
-#define ns_verify __ns_verify
-#define ns_verify_tcp __ns_verify_tcp
-#define ns_verify_tcp_init __ns_verify_tcp_init
-#define ns_samedomain __ns_samedomain
-#define ns_subdomain __ns_subdomain
-#define ns_makecanon __ns_makecanon
-#define ns_samename __ns_samename
-
__BEGIN_DECLS
+int ns_msg_getflag (ns_msg, int) __THROW;
u_int ns_get16 (const u_char *) __THROW;
u_long ns_get32 (const u_char *) __THROW;
void ns_put16 (u_int, u_char *) __THROW;
@@ -538,8 +504,14 @@ void ns_name_rollback (const u_char *, const u_char **,
const u_char **) __THROW;
int ns_sign (u_char *, int *, int, int, void *,
const u_char *, int, u_char *, int *, time_t) __THROW;
+int ns_sign2 (u_char *, int *, int, int, void *,
+ const u_char *, int, u_char *, int *, time_t,
+ u_char **, u_char **) __THROW;
int ns_sign_tcp (u_char *, int *, int, int,
ns_tcp_tsig_state *, int) __THROW;
+int ns_sign_tcp2 (u_char *, int *, int, int,
+ ns_tcp_tsig_state *, int,
+ u_char **, u_char **) __THROW;
int ns_sign_tcp_init (void *, const u_char *, int,
ns_tcp_tsig_state *) __THROW;
u_char *ns_find_tsig (u_char *, u_char *) __THROW;
@@ -560,3 +532,4 @@ __END_DECLS
#endif
#endif /* !_ARPA_NAMESER_H_ */
+/*! \file */
diff --git a/libc/resolv/arpa/nameser_compat.h b/libc/resolv/arpa/nameser_compat.h
index 43bcd3aff..d59c9e41b 100644
--- a/libc/resolv/arpa/nameser_compat.h
+++ b/libc/resolv/arpa/nameser_compat.h
@@ -1,6 +1,6 @@
/* Copyright (c) 1983, 1989
* The Regents of the University of California. All rights reserved.
- *
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
@@ -12,7 +12,7 @@
* 4. Neither the name of the University nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
- *
+ *
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -26,7 +26,7 @@
* SUCH DAMAGE.
*/
-/*
+/*%
* from nameser.h 8.1 (Berkeley) 6/2/93
* $BINDId: nameser_compat.h,v 8.11 1999/01/02 08:00:58 vixie Exp $
*/
@@ -34,11 +34,11 @@
#ifndef _ARPA_NAMESER_COMPAT_
#define _ARPA_NAMESER_COMPAT_
-#define __BIND 19950621 /* (DEAD) interface version stamp. */
+#define __BIND 19950621 /*%< (DEAD) interface version stamp. */
#include <endian.h>
-/*
+/*%
* Structure for query header. The order of the fields is machine- and
* compiler-dependent, depending on the byte/bit order and the layout
* of bit fields. We use bit fields only in int variables, as this
@@ -46,40 +46,40 @@
*/
typedef struct {
- unsigned id :16; /* query identification number */
+ unsigned id :16; /*%< query identification number */
#if BYTE_ORDER == BIG_ENDIAN
/* fields in third byte */
- unsigned qr: 1; /* response flag */
- unsigned opcode: 4; /* purpose of message */
- unsigned aa: 1; /* authoritive answer */
- unsigned tc: 1; /* truncated message */
- unsigned rd: 1; /* recursion desired */
+ unsigned qr: 1; /*%< response flag */
+ unsigned opcode: 4; /*%< purpose of message */
+ unsigned aa: 1; /*%< authoritive answer */
+ unsigned tc: 1; /*%< truncated message */
+ unsigned rd: 1; /*%< recursion desired */
/* fields in fourth byte */
- unsigned ra: 1; /* recursion available */
- unsigned unused :1; /* unused bits (MBZ as of 4.9.3a3) */
- unsigned ad: 1; /* authentic data from named */
- unsigned cd: 1; /* checking disabled by resolver */
- unsigned rcode :4; /* response code */
+ unsigned ra: 1; /*%< recursion available */
+ unsigned unused :1; /*%< unused bits (MBZ as of 4.9.3a3) */
+ unsigned ad: 1; /*%< authentic data from named */
+ unsigned cd: 1; /*%< checking disabled by resolver */
+ unsigned rcode :4; /*%< response code */
#endif
#if BYTE_ORDER == LITTLE_ENDIAN || BYTE_ORDER == PDP_ENDIAN
/* fields in third byte */
- unsigned rd :1; /* recursion desired */
- unsigned tc :1; /* truncated message */
- unsigned aa :1; /* authoritive answer */
- unsigned opcode :4; /* purpose of message */
- unsigned qr :1; /* response flag */
+ unsigned rd :1; /*%< recursion desired */
+ unsigned tc :1; /*%< truncated message */
+ unsigned aa :1; /*%< authoritive answer */
+ unsigned opcode :4; /*%< purpose of message */
+ unsigned qr :1; /*%< response flag */
/* fields in fourth byte */
- unsigned rcode :4; /* response code */
- unsigned cd: 1; /* checking disabled by resolver */
- unsigned ad: 1; /* authentic data from named */
- unsigned unused :1; /* unused bits (MBZ as of 4.9.3a3) */
- unsigned ra :1; /* recursion available */
+ unsigned rcode :4; /*%< response code */
+ unsigned cd: 1; /*%< checking disabled by resolver */
+ unsigned ad: 1; /*%< authentic data from named */
+ unsigned unused :1; /*%< unused bits (MBZ as of 4.9.3a3) */
+ unsigned ra :1; /*%< recursion available */
#endif
/* remaining bytes */
- unsigned qdcount :16; /* number of question entries */
- unsigned ancount :16; /* number of answer entries */
- unsigned nscount :16; /* number of authority entries */
- unsigned arcount :16; /* number of resource entries */
+ unsigned qdcount :16; /*%< number of question entries */
+ unsigned ancount :16; /*%< number of answer entries */
+ unsigned nscount :16; /*%< number of authority entries */
+ unsigned arcount :16; /*%< number of resource entries */
} HEADER;
#define PACKETSZ NS_PACKETSZ
@@ -91,6 +91,7 @@ typedef struct {
#define RRFIXEDSZ NS_RRFIXEDSZ
#define INT32SZ NS_INT32SZ
#define INT16SZ NS_INT16SZ
+#define INT8SZ NS_INT8SZ
#define INADDRSZ NS_INADDRSZ
#define IN6ADDRSZ NS_IN6ADDRSZ
#define INDIR_MASK NS_CMPRSFLGS
@@ -161,6 +162,8 @@ typedef struct {
#define T_SRV ns_t_srv
#define T_ATMA ns_t_atma
#define T_NAPTR ns_t_naptr
+#define T_A6 ns_t_a6
+#define T_DNAME ns_t_dname
#define T_TSIG ns_t_tsig
#define T_IXFR ns_t_ixfr
#define T_AXFR ns_t_axfr
@@ -181,3 +184,4 @@ typedef struct {
#define PUTLONG NS_PUT32
#endif /* _ARPA_NAMESER_COMPAT_ */
+/*! \file */
diff --git a/libc/resolv/gethnamaddr.c b/libc/resolv/gethnamaddr.c
index 7be23158d..5cf660a8d 100644
--- a/libc/resolv/gethnamaddr.c
+++ b/libc/resolv/gethnamaddr.c
@@ -621,7 +621,7 @@ gethostbyname2(name, af)
buf.buf = origbuf = (querybuf *) alloca (1024);
if ((n = __libc_res_nsearch(&_res, name, C_IN, type, buf.buf->buf, 1024,
- &buf.ptr)) < 0) {
+ &buf.ptr, NULL, NULL, NULL)) < 0) {
if (buf.buf != origbuf)
free (buf.buf);
Dprintf("res_nsearch failed (%d)\n", n);
@@ -716,12 +716,12 @@ gethostbyaddr(addr, len, af)
buf.buf = orig_buf = (querybuf *) alloca (1024);
n = __libc_res_nquery(&_res, qbuf, C_IN, T_PTR, buf.buf->buf, 1024,
- &buf.ptr);
+ &buf.ptr, NULL, NULL, NULL);
if (n < 0 && af == AF_INET6 && (_res.options & RES_NOIP6DOTINT) == 0) {
strcpy(qp, "ip6.int");
n = __libc_res_nquery(&_res, qbuf, C_IN, T_PTR, buf.buf->buf,
buf.buf != orig_buf ? MAXPACKET : 1024,
- &buf.ptr);
+ &buf.ptr, NULL, NULL, NULL);
}
if (n < 0) {
if (buf.buf != orig_buf)
diff --git a/libc/resolv/ns_date.c b/libc/resolv/ns_date.c
new file mode 100644
index 000000000..3fee9b7b5
--- /dev/null
+++ b/libc/resolv/ns_date.c
@@ -0,0 +1,121 @@
+/*
+ * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
+ * Copyright (c) 1999 by Internet Software Consortium.
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
+ * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ */
+
+#if !defined(_LIBC) && !defined(lint)
+static const char rcsid[] = "$Id: ns_date.c,v 1.1 2008/08/01 17:15:09 drepper Exp $";
+#endif
+
+/* Import. */
+
+#include <arpa/nameser.h>
+
+#include <ctype.h>
+#include <errno.h>
+#include <stdio.h>
+#include <string.h>
+#include <time.h>
+
+#define SPRINTF(x) ((size_t)sprintf x)
+
+/* Forward. */
+
+static int datepart(const char *, int, int, int, int *);
+
+/* Public. */
+
+/*%
+ * Convert a date in ASCII into the number of seconds since
+ * 1 January 1970 (GMT assumed). Format is yyyymmddhhmmss, all
+ * digits required, no spaces allowed.
+ */
+
+u_int32_t
+ns_datetosecs(const char *cp, int *errp) {
+ struct tm time;
+ u_int32_t result;
+ int mdays, i;
+ static const int days_per_month[12] =
+ {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31};
+
+ if (strlen(cp) != 14U) {
+ *errp = 1;
+ return (0);
+ }
+ *errp = 0;
+
+ memset(&time, 0, sizeof time);
+ time.tm_year = datepart(cp + 0, 4, 1990, 9999, errp) - 1900;
+ time.tm_mon = datepart(cp + 4, 2, 01, 12, errp) - 1;
+ time.tm_mday = datepart(cp + 6, 2, 01, 31, errp);
+ time.tm_hour = datepart(cp + 8, 2, 00, 23, errp);
+ time.tm_min = datepart(cp + 10, 2, 00, 59, errp);
+ time.tm_sec = datepart(cp + 12, 2, 00, 59, errp);
+ if (*errp) /*%< Any parse errors? */
+ return (0);
+
+ /*
+ * OK, now because timegm() is not available in all environments,
+ * we will do it by hand. Roll up sleeves, curse the gods, begin!
+ */
+
+#define SECS_PER_DAY ((u_int32_t)24*60*60)
+#define isleap(y) ((((y) % 4) == 0 && ((y) % 100) != 0) || ((y) % 400) == 0)
+
+ result = time.tm_sec; /*%< Seconds */
+ result += time.tm_min * 60; /*%< Minutes */
+ result += time.tm_hour * (60*60); /*%< Hours */
+ result += (time.tm_mday - 1) * SECS_PER_DAY; /*%< Days */
+ /* Months are trickier. Look without leaping, then leap */
+ mdays = 0;
+ for (i = 0; i < time.tm_mon; i++)
+ mdays += days_per_month[i];
+ result += mdays * SECS_PER_DAY; /*%< Months */
+ if (time.tm_mon > 1 && isleap(1900+time.tm_year))
+ result += SECS_PER_DAY; /*%< Add leapday for this year */
+ /* First figure years without leapdays, then add them in. */
+ /* The loop is slow, FIXME, but simple and accurate. */
+ result += (time.tm_year - 70) * (SECS_PER_DAY*365); /*%< Years */
+ for (i = 70; i < time.tm_year; i++)
+ if (isleap(1900+i))
+ result += SECS_PER_DAY; /*%< Add leapday for prev year */
+ return (result);
+}
+
+/* Private. */
+
+/*%
+ * Parse part of a date. Set error flag if any error.
+ * Don't reset the flag if there is no error.
+ */
+static int
+datepart(const char *buf, int size, int min, int max, int *errp) {
+ int result = 0;
+ int i;
+
+ for (i = 0; i < size; i++) {
+ if (!isdigit((unsigned char)(buf[i])))
+ *errp = 1;
+ result = (result * 10) + buf[i] - '0';
+ }
+ if (result < min)
+ *errp = 1;
+ if (result > max)
+ *errp = 1;
+ return (result);
+}
+
+/*! \file */
diff --git a/libc/resolv/ns_name.c b/libc/resolv/ns_name.c
index ed361915d..adf64bbd9 100644
--- a/libc/resolv/ns_name.c
+++ b/libc/resolv/ns_name.c
@@ -1,18 +1,18 @@
/*
+ * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 1996,1999 by Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
- * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
- * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
- * CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
- * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
- * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
- * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
- * SOFTWARE.
+ * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
+ * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#if !defined(_LIBC) && !defined(lint)
@@ -24,16 +24,41 @@ static const char rcsid[] = "$BINDId: ns_name.c,v 8.15 2000/03/30 22:53:46 vixie
#include <netinet/in.h>
#include <arpa/nameser.h>
-#include <ctype.h>
#include <errno.h>
#include <resolv.h>
#include <string.h>
#include <ctype.h>
+#include <stdlib.h>
+#include <limits.h>
+
+# define SPRINTF(x) ((size_t)sprintf x)
+
+#define NS_TYPE_ELT 0x40 /*%< EDNS0 extended label type */
+#define DNS_LABELTYPE_BITSTRING 0x41
/* Data. */
static const char digits[] = "0123456789";
+static const char digitvalue[256] = {
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /*16*/
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /*32*/
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /*48*/
+ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, -1, -1, -1, -1, -1, -1, /*64*/
+ -1, 10, 11, 12, 13, 14, 15, -1, -1, -1, -1, -1, -1, -1, -1, -1, /*80*/
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /*96*/
+ -1, 10, 11, 12, 13, 14, 15, -1, -1, -1, -1, -1, -1, -1, -1, -1, /*112*/
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /*128*/
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /*256*/
+};
+
/* Forward. */
static int special(int);
@@ -41,31 +66,40 @@ static int printable(int);
static int dn_find(const u_char *, const u_char *,
const u_char * const *,
const u_char * const *);
+static int encode_bitstring(const char **, const char *,
+ unsigned char **, unsigned char **,
+ unsigned const char *);
+static int labellen(const u_char *);
+static int decode_bitstring(const unsigned char **,
+ char *, const char *);
/* Public. */
-/*
- * ns_name_ntop(src, dst, dstsiz)
+/*%
* Convert an encoded domain name to printable ascii as per RFC1035.
+
* return:
- * Number of bytes written to buffer, or -1 (with errno set)
+ *\li Number of bytes written to buffer, or -1 (with errno set)
+ *
* notes:
- * The root is returned as "."
- * All other domains are returned in non absolute form
+ *\li The root is returned as "."
+ *\li All other domains are returned in non absolute form
*/
int
-ns_name_ntop(const u_char *src, char *dst, size_t dstsiz) {
+ns_name_ntop(const u_char *src, char *dst, size_t dstsiz)
+{
const u_char *cp;
char *dn, *eom;
u_char c;
u_int n;
+ int l;
cp = src;
dn = dst;
eom = dst + dstsiz;
while ((n = *cp++) != 0) {
- if ((n & NS_CMPRSFLGS) != 0 && n != 0x41) {
+ if ((n & NS_CMPRSFLGS) == NS_CMPRSFLGS) {
/* Some kind of compression pointer. */
__set_errno (EMSGSIZE);
return (-1);
@@ -77,34 +111,31 @@ ns_name_ntop(const u_char *src, char *dst, size_t dstsiz) {
}
*dn++ = '.';
}
+ if ((l = labellen(cp - 1)) < 0) {
+ __set_errno (EMSGSIZE);
+ return(-1);
+ }
+ if (dn + l >= eom) {
+ __set_errno (EMSGSIZE);
+ return (-1);
+ }
+ if ((n & NS_CMPRSFLGS) == NS_TYPE_ELT) {
+ int m;
- if (n == 0x41) {
- n = *cp++ / 8;
- if (dn + n * 2 + 4 >= eom) {
- __set_errno (EMSGSIZE);
- return (-1);
+ if (n != DNS_LABELTYPE_BITSTRING) {
+ /* XXX: labellen should reject this case */
+ __set_errno (EINVAL);
+ return(-1);
}
- *dn++ = '\\';
- *dn++ = '[';
- *dn++ = 'x';
-
- while (n-- > 0) {
- c = *cp++;
- unsigned u = c >> 4;
- *dn++ = u > 9 ? 'a' + u - 10 : '0' + u;
- u = c & 0xf;
- *dn++ = u > 9 ? 'a' + u - 10 : '0' + u;
+ if ((m = decode_bitstring(&cp, dn, eom)) < 0)
+ {
+ __set_errno (EMSGSIZE);
+ return(-1);
}
-
- *dn++ = ']';
+ dn += m;
continue;
}
-
- if (dn + n >= eom) {
- __set_errno (EMSGSIZE);
- return (-1);
- }
- for ((void)NULL; n > 0; n--) {
+ for ((void)NULL; l > 0; l--) {
c = *cp++;
if (special(c)) {
if (dn + 1 >= eom) {
@@ -146,22 +177,26 @@ ns_name_ntop(const u_char *src, char *dst, size_t dstsiz) {
return (dn - dst);
}
libresolv_hidden_def (ns_name_ntop)
+strong_alias (ns_name_ntop, __ns_name_ntop)
-/*
- * ns_name_pton(src, dst, dstsiz)
+/*%
* Convert a ascii string into an encoded domain name as per RFC1035.
+ *
* return:
- * -1 if it fails
- * 1 if string was fully qualified
- * 0 is string was not fully qualified
+ *
+ *\li -1 if it fails
+ *\li 1 if string was fully qualified
+ *\li 0 is string was not fully qualified
+ *
* notes:
- * Enforces label and domain length limits.
+ *\li Enforces label and domain length limits.
*/
int
-ns_name_pton(const char *src, u_char *dst, size_t dstsiz) {
+ns_name_pton(const char *src, u_char *dst, size_t dstsiz)
+{
u_char *label, *bp, *eom;
- int c, n, escaped;
+ int c, n, escaped, e = 0;
char *cp;
escaped = 0;
@@ -171,7 +206,28 @@ ns_name_pton(const char *src, u_char *dst, size_t dstsiz) {
while ((c = *src++) != 0) {
if (escaped) {
- if ((cp = strchr(digits, c)) != NULL) {
+ if (c == '[') { /*%< start a bit string label */
+ if ((cp = strchr(src, ']')) == NULL) {
+ __set_errno (EINVAL);
+ return(-1);
+ }
+ if ((e = encode_bitstring(&src, cp + 2,
+ &label, &bp, eom))
+ != 0) {
+ __set_errno (e);
+ return(-1);
+ }
+ escaped = 0;
+ label = bp++;
+ if ((c = *src++) == 0)
+ goto done;
+ else if (c != '.') {
+ __set_errno (EINVAL);
+ return(-1);
+ }
+ continue;
+ }
+ else if ((cp = strchr(digits, c)) != NULL) {
n = (cp - digits) * 100;
if ((c = *src++) == 0 ||
(cp = strchr(digits, c)) == NULL) {
@@ -190,41 +246,6 @@ ns_name_pton(const char *src, u_char *dst, size_t dstsiz) {
return (-1);
}
c = n;
- } else if (c == '[' && label == bp - 1 && *src == 'x') {
- /* Theoretically we would have to handle \[o
- as well but we do not since we do not need
- it internally. */
- *label = 0x41;
- label = bp++;
- ++src;
- while (isxdigit (*src)) {
- n = *src > '9' ? *src - 'a' + 10 : *src - '0';
- ++src;
- if (! isxdigit(*src)) {
- __set_errno (EMSGSIZE);
- return (-1);
- }
- n <<= 4;
- n += *src > '9' ? *src - 'a' + 10 : *src - '0';
- if (bp + 1 >= eom) {
- __set_errno (EMSGSIZE);
- return (-1);
- }
- *bp++ = n;
- ++src;
- }
- *label = (bp - label - 1) * 8;
- if (*src++ != ']' || *src++ != '.') {
- __set_errno (EMSGSIZE);
- return (-1);
- }
- escaped = 0;
- label = bp++;
- if (bp >= eom) {
- __set_errno (EMSGSIZE);
- return (-1);
- }
- continue;
}
escaped = 0;
} else if (c == '\\') {
@@ -232,7 +253,7 @@ ns_name_pton(const char *src, u_char *dst, size_t dstsiz) {
continue;
} else if (c == '.') {
c = (bp - label - 1);
- if ((c & NS_CMPRSFLGS) != 0) { /* Label too big. */
+ if ((c & NS_CMPRSFLGS) != 0) { /*%< Label too big. */
__set_errno (EMSGSIZE);
return (-1);
}
@@ -270,10 +291,11 @@ ns_name_pton(const char *src, u_char *dst, size_t dstsiz) {
*bp++ = (u_char)c;
}
c = (bp - label - 1);
- if ((c & NS_CMPRSFLGS) != 0) { /* Label too big. */
+ if ((c & NS_CMPRSFLGS) != 0) { /*%< Label too big. */
__set_errno (EMSGSIZE);
return (-1);
}
+ done:
if (label >= eom) {
__set_errno (EMSGSIZE);
return (-1);
@@ -286,45 +308,57 @@ ns_name_pton(const char *src, u_char *dst, size_t dstsiz) {
}
*bp++ = 0;
}
- if ((bp - dst) > MAXCDNAME) { /* src too big */
+ if ((bp - dst) > MAXCDNAME) { /*%< src too big */
__set_errno (EMSGSIZE);
return (-1);
}
return (0);
}
+libresolv_hidden_def (ns_name_pton)
-/*
- * ns_name_ntol(src, dst, dstsiz)
+/*%
* Convert a network strings labels into all lowercase.
+ *
* return:
- * Number of bytes written to buffer, or -1 (with errno set)
+ *\li Number of bytes written to buffer, or -1 (with errno set)
+ *
* notes:
- * Enforces label and domain length limits.
+ *\li Enforces label and domain length limits.
*/
int
-ns_name_ntol(const u_char *src, u_char *dst, size_t dstsiz) {
+ns_name_ntol(const u_char *src, u_char *dst, size_t dstsiz)
+{
const u_char *cp;
u_char *dn, *eom;
u_char c;
u_int n;
+ int l;
cp = src;
dn = dst;
eom = dst + dstsiz;
+ if (dn >= eom) {
+ __set_errno (EMSGSIZE);
+ return (-1);
+ }
while ((n = *cp++) != 0) {
- if ((n & NS_CMPRSFLGS) != 0) {
+ if ((n & NS_CMPRSFLGS) == NS_CMPRSFLGS) {
/* Some kind of compression pointer. */
__set_errno (EMSGSIZE);
return (-1);
}
*dn++ = n;
- if (dn + n >= eom) {
+ if ((l = labellen(cp - 1)) < 0) {
__set_errno (EMSGSIZE);
return (-1);
}
- for ((void)NULL; n > 0; n--) {
+ if (dn + l >= eom) {
+ __set_errno (EMSGSIZE);
+ return (-1);
+ }
+ for ((void)NULL; l > 0; l--) {
c = *cp++;
if (isupper(c))
*dn++ = tolower(c);
@@ -336,11 +370,11 @@ ns_name_ntol(const u_char *src, u_char *dst, size_t dstsiz) {
return (dn - dst);
}
-/*
- * ns_name_unpack(msg, eom, src, dst, dstsiz)
+/*%
* Unpack a domain name from a message, source may be compressed.
+ *
* return:
- * -1 if it fails, or consumed octets if it succeeds.
+ *\li -1 if it fails, or consumed octets if it succeeds.
*/
int
ns_name_unpack(const u_char *msg, const u_char *eom, const u_char *src,
@@ -348,7 +382,7 @@ ns_name_unpack(const u_char *msg, const u_char *eom, const u_char *src,
{
const u_char *srcp, *dstlim;
u_char *dstp;
- int n, len, checked;
+ int n, len, checked, l;
len = -1;
checked = 0;
@@ -363,29 +397,22 @@ ns_name_unpack(const u_char *msg, const u_char *eom, const u_char *src,
while ((n = *srcp++) != 0) {
/* Check for indirection. */
switch (n & NS_CMPRSFLGS) {
- case 0x40:
- if (n == 0x41) {
- if (dstp + 1 >= dstlim) {
- __set_errno (EMSGSIZE);
- return (-1);
- }
- *dstp++ = 0x41;
- n = *srcp++ / 8;
- ++checked;
- } else {
- __set_errno (EMSGSIZE);
- return (-1); /* flag error */
- }
- /* FALLTHROUGH */
case 0:
+ case NS_TYPE_ELT:
/* Limit checks. */
- if (dstp + n + 1 >= dstlim || srcp + n >= eom) {
+ if ((l = labellen(srcp - 1)) < 0) {
+ __set_errno (EMSGSIZE);
+ return(-1);
+ }
+ if (dstp + l + 1 >= dstlim || srcp + l >= eom) {
__set_errno (EMSGSIZE);
return (-1);
}
- checked += n + 1;
- dstp = mempcpy(dstp, srcp - 1, n + 1);
- srcp += n;
+ checked += l + 1;
+ *dstp++ = n;
+ memcpy(dstp, srcp, l);
+ dstp += l;
+ srcp += l;
break;
case NS_CMPRSFLGS:
@@ -396,7 +423,7 @@ ns_name_unpack(const u_char *msg, const u_char *eom, const u_char *src,
if (len < 0)
len = srcp - src + 1;
srcp = msg + (((n & 0x3f) << 8) | (*srcp & 0xff));
- if (srcp < msg || srcp >= eom) { /* Out of range. */
+ if (srcp < msg || srcp >= eom) { /*%< Out of range. */
__set_errno (EMSGSIZE);
return (-1);
}
@@ -414,7 +441,7 @@ ns_name_unpack(const u_char *msg, const u_char *eom, const u_char *src,
default:
__set_errno (EMSGSIZE);
- return (-1); /* flag error */
+ return (-1); /*%< flag error */
}
}
*dstp = '\0';
@@ -423,20 +450,23 @@ ns_name_unpack(const u_char *msg, const u_char *eom, const u_char *src,
return (len);
}
libresolv_hidden_def (ns_name_unpack)
+strong_alias (ns_name_unpack, __ns_name_unpack)
-/*
- * ns_name_pack(src, dst, dstsiz, dnptrs, lastdnptr)
+/*%
* Pack domain name 'domain' into 'comp_dn'.
+ *
* return:
- * Size of the compressed name, or -1.
+ *\li Size of the compressed name, or -1.
+ *
* notes:
- * 'dnptrs' is an array of pointers to previous compressed names.
- * dnptrs[0] is a pointer to the beginning of the message. The array
+ *\li 'dnptrs' is an array of pointers to previous compressed names.
+ *\li dnptrs[0] is a pointer to the beginning of the message. The array
* ends with NULL.
- * 'lastdnptr' is a pointer to the end of the array pointed to
+ *\li 'lastdnptr' is a pointer to the end of the array pointed to
* by 'dnptrs'.
+ *
* Side effects:
- * The list of pointers in dnptrs is updated for labels inserted into
+ *\li The list of pointers in dnptrs is updated for labels inserted into
* the message as we compress the name. If 'dnptr' is NULL, we don't
* try to compress names. If 'lastdnptr' is NULL, we don't update the
* list.
@@ -458,7 +488,7 @@ ns_name_pack(const u_char *src, u_char *dst, int dstsiz,
if ((msg = *dnptrs++) != NULL) {
for (cpp = dnptrs; *cpp != NULL; cpp++)
(void)NULL;
- lpp = cpp; /* end of list to search */
+ lpp = cpp; /*%< end of list to search */
}
} else
msg = NULL;
@@ -466,19 +496,23 @@ ns_name_pack(const u_char *src, u_char *dst, int dstsiz,
/* make sure the domain we are about to add is legal */
l = 0;
do {
+ int l0;
+
n = *srcp;
- if ((n & NS_CMPRSFLGS) != 0 && n != 0x41) {
+ if ((n & NS_CMPRSFLGS) == NS_CMPRSFLGS) {
__set_errno (EMSGSIZE);
return (-1);
}
- if (n == 0x41)
- n = *++srcp / 8;
- l += n + 1;
+ if ((l0 = labellen(srcp)) < 0) {
+ __set_errno (EINVAL);
+ return(-1);
+ }
+ l += l0 + 1;
if (l > MAXCDNAME) {
__set_errno (EMSGSIZE);
return (-1);
}
- srcp += n + 1;
+ srcp += l0 + 1;
} while (n != 0);
/* from here on we need to reset compression pointer array on error */
@@ -486,7 +520,7 @@ ns_name_pack(const u_char *src, u_char *dst, int dstsiz,
do {
/* Look to see if we can use pointers. */
n = *srcp;
- if (n != 0 && n != 0x41 && msg != NULL) {
+ if (n != 0 && msg != NULL) {
l = dn_find(srcp, msg, (const u_char * const *)dnptrs,
(const u_char * const *)lpp);
if (l >= 0) {
@@ -506,15 +540,11 @@ ns_name_pack(const u_char *src, u_char *dst, int dstsiz,
}
}
/* copy label to buffer */
- if ((n & NS_CMPRSFLGS) != 0 && n != 0x41) { /* Should not happen. */
+ if ((n & NS_CMPRSFLGS) == NS_CMPRSFLGS) {
+ /* Should not happen. */
goto cleanup;
}
- if (n == 0x41) {
- n = *++srcp / 8;
- if (dstp + 1 >= eob)
- goto cleanup;
- *dstp++ = 0x41;
- }
+ n = labellen(srcp);
if (dstp + 1 + n >= eob) {
goto cleanup;
}
@@ -532,14 +562,16 @@ cleanup:
}
return (dstp - dst);
}
+libresolv_hidden_def (ns_name_pack)
-/*
- * ns_name_uncompress(msg, eom, src, dst, dstsiz)
+/*%
* Expand compressed domain name to presentation format.
+ *
* return:
- * Number of bytes read out of `src', or -1 (with errno set).
+ *\li Number of bytes read out of `src', or -1 (with errno set).
+ *
* note:
- * Root domain returns as "." not "".
+ *\li Root domain returns as "." not "".
*/
int
ns_name_uncompress(const u_char *msg, const u_char *eom, const u_char *src,
@@ -554,19 +586,21 @@ ns_name_uncompress(const u_char *msg, const u_char *eom, const u_char *src,
return (-1);
return (n);
}
+libresolv_hidden_def (ns_name_uncompress)
-/*
- * ns_name_compress(src, dst, dstsiz, dnptrs, lastdnptr)
+/*%
* Compress a domain name into wire format, using compression pointers.
+ *
* return:
- * Number of bytes consumed in `dst' or -1 (with errno set).
+ *\li Number of bytes consumed in `dst' or -1 (with errno set).
+ *
* notes:
- * 'dnptrs' is an array of pointers to previous compressed names.
- * dnptrs[0] is a pointer to the beginning of the message.
- * The list ends with NULL. 'lastdnptr' is a pointer to the end of the
+ *\li 'dnptrs' is an array of pointers to previous compressed names.
+ *\li dnptrs[0] is a pointer to the beginning of the message.
+ *\li The list ends with NULL. 'lastdnptr' is a pointer to the end of the
* array pointed to by 'dnptrs'. Side effect is to update the list of
* pointers for labels inserted into the message as we compress the name.
- * If 'dnptr' is NULL, we don't try to compress names. If 'lastdnptr'
+ *\li If 'dnptr' is NULL, we don't try to compress names. If 'lastdnptr'
* is NULL, we don't update the list.
*/
int
@@ -579,8 +613,9 @@ ns_name_compress(const char *src, u_char *dst, size_t dstsiz,
return (-1);
return (ns_name_pack(tmp, dst, dstsiz, dnptrs, lastdnptr));
}
+libresolv_hidden_def (ns_name_compress)
-/*
+/*%
* Reset dnptrs so that there are no active references to pointers at or
* after src.
*/
@@ -597,28 +632,37 @@ ns_name_rollback(const u_char *src, const u_char **dnptrs,
}
}
-/*
- * ns_name_skip(ptrptr, eom)
+/*%
* Advance *ptrptr to skip over the compressed name it points at.
+ *
* return:
- * 0 on success, -1 (with errno set) on failure.
+ *\li 0 on success, -1 (with errno set) on failure.
*/
int
-ns_name_skip(const u_char **ptrptr, const u_char *eom) {
+ns_name_skip(const u_char **ptrptr, const u_char *eom)
+{
const u_char *cp;
u_int n;
+ int l;
cp = *ptrptr;
while (cp < eom && (n = *cp++) != 0) {
/* Check for indirection. */
switch (n & NS_CMPRSFLGS) {
- case 0: /* normal case, n == len */
+ case 0: /*%< normal case, n == len */
cp += n;
continue;
- case NS_CMPRSFLGS: /* indirection */
+ case NS_TYPE_ELT: /*%< EDNS0 extended label */
+ if ((l = labellen(cp - 1)) < 0) {
+ __set_errno (EMSGSIZE);
+ return(-1);
+ }
+ cp += l;
+ continue;
+ case NS_CMPRSFLGS: /*%< indirection */
cp++;
break;
- default: /* illegal type */
+ default: /*%< illegal type */
__set_errno (EMSGSIZE);
return (-1);
}
@@ -631,45 +675,48 @@ ns_name_skip(const u_char **ptrptr, const u_char *eom) {
*ptrptr = cp;
return (0);
}
+libresolv_hidden_def (ns_name_skip)
/* Private. */
-/*
- * special(ch)
+/*%
* Thinking in noninternationalized USASCII (per the DNS spec),
* is this characted special ("in need of quoting") ?
+ *
* return:
- * boolean.
+ *\li boolean.
*/
static int
special(int ch) {
switch (ch) {
- case 0x22: /* '"' */
- case 0x2E: /* '.' */
- case 0x3B: /* ';' */
- case 0x5C: /* '\\' */
+ case 0x22: /*%< '"' */
+ case 0x2E: /*%< '.' */
+ case 0x3B: /*%< ';' */
+ case 0x5C: /*%< '\\' */
+ case 0x28: /*%< '(' */
+ case 0x29: /*%< ')' */
/* Special modifiers in zone files. */
- case 0x40: /* '@' */
- case 0x24: /* '$' */
+ case 0x40: /*%< '@' */
+ case 0x24: /*%< '$' */
return (1);
default:
return (0);
}
}
-/*
- * printable(ch)
+/*%
* Thinking in noninternationalized USASCII (per the DNS spec),
* is this character visible and not a space when printed ?
+ *
* return:
- * boolean.
+ *\li boolean.
*/
static int
printable(int ch) {
return (ch > 0x20 && ch < 0x7f);
}
-/*
+/*%
* Thinking in noninternationalized USASCII (per the DNS spec),
* convert this character to lower case if it's upper case.
*/
@@ -680,14 +727,15 @@ mklower(int ch) {
return (ch);
}
-/*
- * dn_find(domain, msg, dnptrs, lastdnptr)
+/*%
* Search for the counted-label name in an array of compressed names.
+ *
* return:
- * offset from msg if found, or -1.
+ *\li offset from msg if found, or -1.
+ *
* notes:
- * dnptrs is the pointer to the first name on the list,
- * not the pointer to the start of the message.
+ *\li dnptrs is the pointer to the first name on the list,
+ *\li not the pointer to the start of the message.
*/
static int
dn_find(const u_char *domain, const u_char *msg,
@@ -715,9 +763,11 @@ dn_find(const u_char *domain, const u_char *msg,
* check for indirection
*/
switch (n & NS_CMPRSFLGS) {
- case 0: /* normal case, n == len */
+ case 0: /*%< normal case, n == len */
+ n = labellen(cp - 1); /*%< XXX */
if (n != *dn++)
goto next;
+
for ((void)NULL; n > 0; n--)
if (mklower(*dn++) !=
mklower(*cp++))
@@ -728,20 +778,197 @@ dn_find(const u_char *domain, const u_char *msg,
if (*dn)
continue;
goto next;
-
- case NS_CMPRSFLGS: /* indirection */
+ case NS_CMPRSFLGS: /*%< indirection */
cp = msg + (((n & 0x3f) << 8) | *cp);
break;
- default: /* illegal type */
+ default: /*%< illegal type */
__set_errno (EMSGSIZE);
return (-1);
}
}
- next:
+ next: ;
sp += *sp + 1;
}
}
__set_errno (ENOENT);
return (-1);
}
+
+static int
+decode_bitstring(const unsigned char **cpp, char *dn, const char *eom)
+{
+ const unsigned char *cp = *cpp;
+ char *beg = dn, tc;
+ int b, blen, plen, i;
+
+ if ((blen = (*cp & 0xff)) == 0)
+ blen = 256;
+ plen = (blen + 3) / 4;
+ plen += sizeof("\\[x/]") + (blen > 99 ? 3 : (blen > 9) ? 2 : 1);
+ if (dn + plen >= eom)
+ return(-1);
+
+ cp++;
+ i = SPRINTF((dn, "\\[x"));
+ if (i < 0)
+ return (-1);
+ dn += i;
+ for (b = blen; b > 7; b -= 8, cp++) {
+ i = SPRINTF((dn, "%02x", *cp & 0xff));
+ if (i < 0)
+ return (-1);
+ dn += i;
+ }
+ if (b > 4) {
+ tc = *cp++;
+ i = SPRINTF((dn, "%02x", tc & (0xff << (8 - b))));
+ if (i < 0)
+ return (-1);
+ dn += i;
+ } else if (b > 0) {
+ tc = *cp++;
+ i = SPRINTF((dn, "%1x",
+ ((tc >> 4) & 0x0f) & (0x0f << (4 - b))));
+ if (i < 0)
+ return (-1);
+ dn += i;
+ }
+ i = SPRINTF((dn, "/%d]", blen));
+ if (i < 0)
+ return (-1);
+ dn += i;
+
+ *cpp = cp;
+ return(dn - beg);
+}
+
+static int
+encode_bitstring(const char **bp, const char *end, unsigned char **labelp,
+ unsigned char ** dst, unsigned const char *eom)
+{
+ int afterslash = 0;
+ const char *cp = *bp;
+ unsigned char *tp;
+ char c;
+ const char *beg_blen;
+ char *end_blen = NULL;
+ int value = 0, count = 0, tbcount = 0, blen = 0;
+
+ beg_blen = end_blen = NULL;
+
+ /* a bitstring must contain at least 2 characters */
+ if (end - cp < 2)
+ return(EINVAL);
+
+ /* XXX: currently, only hex strings are supported */
+ if (*cp++ != 'x')
+ return(EINVAL);
+ if (!isxdigit((*cp) & 0xff)) /*%< reject '\[x/BLEN]' */
+ return(EINVAL);
+
+ for (tp = *dst + 1; cp < end && tp < eom; cp++) {
+ switch((c = *cp)) {
+ case ']': /*%< end of the bitstring */
+ if (afterslash) {
+ if (beg_blen == NULL)
+ return(EINVAL);
+ blen = (int)strtol(beg_blen, &end_blen, 10);
+ if (*end_blen != ']')
+ return(EINVAL);
+ }
+ if (count)
+ *tp++ = ((value << 4) & 0xff);
+ cp++; /*%< skip ']' */
+ goto done;
+ case '/':
+ afterslash = 1;
+ break;
+ default:
+ if (afterslash) {
+ if (!isdigit(c&0xff))
+ return(EINVAL);
+ if (beg_blen == NULL) {
+
+ if (c == '0') {
+ /* blen never begings with 0 */
+ return(EINVAL);
+ }
+ beg_blen = cp;
+ }
+ } else {
+ if (!isxdigit(c&0xff))
+ return(EINVAL);
+ value <<= 4;
+ value += digitvalue[(int)c];
+ count += 4;
+ tbcount += 4;
+ if (tbcount > 256)
+ return(EINVAL);
+ if (count == 8) {
+ *tp++ = value;
+ count = 0;
+ }
+ }
+ break;
+ }
+ }
+ done:
+ if (cp >= end || tp >= eom)
+ return(EMSGSIZE);
+
+ /*
+ * bit length validation:
+ * If a <length> is present, the number of digits in the <bit-data>
+ * MUST be just sufficient to contain the number of bits specified
+ * by the <length>. If there are insignificant bits in a final
+ * hexadecimal or octal digit, they MUST be zero.
+ * RFC2673, Section 3.2.
+ */
+ if (blen > 0) {
+ int traillen;
+
+ if (((blen + 3) & ~3) != tbcount)
+ return(EINVAL);
+ traillen = tbcount - blen; /*%< between 0 and 3 */
+ if (((value << (8 - traillen)) & 0xff) != 0)
+ return(EINVAL);
+ }
+ else
+ blen = tbcount;
+ if (blen == 256)
+ blen = 0;
+
+ /* encode the type and the significant bit fields */
+ **labelp = DNS_LABELTYPE_BITSTRING;
+ **dst = blen;
+
+ *bp = cp;
+ *dst = tp;
+
+ return(0);
+}
+
+static int
+labellen(const u_char *lp)
+{
+ int bitlen;
+ u_char l = *lp;
+
+ if ((l & NS_CMPRSFLGS) == NS_CMPRSFLGS) {
+ /* should be avoided by the caller */
+ return(-1);
+ }
+
+ if ((l & NS_CMPRSFLGS) == NS_TYPE_ELT) {
+ if (l == DNS_LABELTYPE_BITSTRING) {
+ if ((bitlen = *(lp + 1)) == 0)
+ bitlen = 256;
+ return((bitlen + 7 ) / 8 + 1);
+ }
+ return(-1); /*%< unknwon ELT */
+ }
+ return(l);
+}
+
+/*! \file */
diff --git a/libc/resolv/ns_netint.c b/libc/resolv/ns_netint.c
index 20ecf626d..4318f1887 100644
--- a/libc/resolv/ns_netint.c
+++ b/libc/resolv/ns_netint.c
@@ -1,18 +1,18 @@
/*
+ * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 1996,1999 by Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
- * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
- * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
- * CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
- * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
- * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
- * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
- * SOFTWARE.
+ * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
+ * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#if !defined(_LIBC) && !defined(lint)
@@ -34,6 +34,7 @@ ns_get16(const u_char *src) {
return (dst);
}
libresolv_hidden_def (ns_get16)
+strong_alias (ns_get16, __ns_get16)
u_long
ns_get32(const u_char *src) {
@@ -43,13 +44,18 @@ ns_get32(const u_char *src) {
return (dst);
}
libresolv_hidden_def (ns_get32)
+strong_alias (ns_get32, __ns_get32)
void
ns_put16(u_int src, u_char *dst) {
NS_PUT16(src, dst);
}
+libresolv_hidden_def (ns_put16)
void
ns_put32(u_long src, u_char *dst) {
NS_PUT32(src, dst);
}
+libresolv_hidden_def (ns_put32)
+
+/*! \file */
diff --git a/libc/resolv/ns_parse.c b/libc/resolv/ns_parse.c
index d305eae53..712469be1 100644
--- a/libc/resolv/ns_parse.c
+++ b/libc/resolv/ns_parse.c
@@ -1,18 +1,18 @@
/*
+ * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 1996,1999 by Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
- * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
- * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
- * CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
- * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
- * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
- * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
- * SOFTWARE.
+ * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
+ * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#if !defined(_LIBC) && !defined(lint)
@@ -41,25 +41,30 @@ static void setsection(ns_msg *msg, ns_sect sect);
/* Public. */
/* These need to be in the same order as the nres.h:ns_flag enum. */
-struct _ns_flagdata _ns_flagdata[16] = {
- { 0x8000, 15 }, /* qr. */
- { 0x7800, 11 }, /* opcode. */
- { 0x0400, 10 }, /* aa. */
- { 0x0200, 9 }, /* tc. */
- { 0x0100, 8 }, /* rd. */
- { 0x0080, 7 }, /* ra. */
- { 0x0040, 6 }, /* z. */
- { 0x0020, 5 }, /* ad. */
- { 0x0010, 4 }, /* cd. */
- { 0x000f, 0 }, /* rcode. */
- { 0x0000, 0 }, /* expansion (1/6). */
- { 0x0000, 0 }, /* expansion (2/6). */
- { 0x0000, 0 }, /* expansion (3/6). */
- { 0x0000, 0 }, /* expansion (4/6). */
- { 0x0000, 0 }, /* expansion (5/6). */
- { 0x0000, 0 }, /* expansion (6/6). */
+const struct _ns_flagdata _ns_flagdata[16] = {
+ { 0x8000, 15 }, /*%< qr. */
+ { 0x7800, 11 }, /*%< opcode. */
+ { 0x0400, 10 }, /*%< aa. */
+ { 0x0200, 9 }, /*%< tc. */
+ { 0x0100, 8 }, /*%< rd. */
+ { 0x0080, 7 }, /*%< ra. */
+ { 0x0040, 6 }, /*%< z. */
+ { 0x0020, 5 }, /*%< ad. */
+ { 0x0010, 4 }, /*%< cd. */
+ { 0x000f, 0 }, /*%< rcode. */
+ { 0x0000, 0 }, /*%< expansion (1/6). */
+ { 0x0000, 0 }, /*%< expansion (2/6). */
+ { 0x0000, 0 }, /*%< expansion (3/6). */
+ { 0x0000, 0 }, /*%< expansion (4/6). */
+ { 0x0000, 0 }, /*%< expansion (5/6). */
+ { 0x0000, 0 }, /*%< expansion (6/6). */
};
+#undef ns_msg_getflag
+int ns_msg_getflag(ns_msg handle, int flag) {
+ return(((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift);
+}
+
int
ns_skiprr(const u_char *ptr, const u_char *eom, ns_sect section, int count) {
const u_char *optr = ptr;
@@ -83,6 +88,7 @@ ns_skiprr(const u_char *ptr, const u_char *eom, ns_sect section, int count) {
RETERR(EMSGSIZE);
return (ptr - optr);
}
+libresolv_hidden_def (ns_skiprr)
int
ns_initparse(const u_char *msg, int msglen, ns_msg *handle) {
@@ -120,13 +126,16 @@ ns_initparse(const u_char *msg, int msglen, ns_msg *handle) {
setsection(handle, ns_s_max);
return (0);
}
+libresolv_hidden_def (ns_initparse)
int
ns_parserr(ns_msg *handle, ns_sect section, int rrnum, ns_rr *rr) {
int b;
+ int tmp;
/* Make section right. */
- if (section < 0 || section >= ns_s_max)
+ tmp = section;
+ if (tmp < 0 || section >= ns_s_max)
RETERR(ENODEV);
if (section != handle->_sect)
setsection(handle, section);
@@ -139,38 +148,38 @@ ns_parserr(ns_msg *handle, ns_sect section, int rrnum, ns_rr *rr) {
if (rrnum < handle->_rrnum)
setsection(handle, section);
if (rrnum > handle->_rrnum) {
- b = ns_skiprr(handle->_ptr, handle->_eom, section,
+ b = ns_skiprr(handle->_msg_ptr, handle->_eom, section,
rrnum - handle->_rrnum);
if (b < 0)
return (-1);
- handle->_ptr += b;
+ handle->_msg_ptr += b;
handle->_rrnum = rrnum;
}
/* Do the parse. */
b = dn_expand(handle->_msg, handle->_eom,
- handle->_ptr, rr->name, NS_MAXDNAME);
+ handle->_msg_ptr, rr->name, NS_MAXDNAME);
if (b < 0)
return (-1);
- handle->_ptr += b;
- if (handle->_ptr + NS_INT16SZ + NS_INT16SZ > handle->_eom)
+ handle->_msg_ptr += b;
+ if (handle->_msg_ptr + NS_INT16SZ + NS_INT16SZ > handle->_eom)
RETERR(EMSGSIZE);
- NS_GET16(rr->type, handle->_ptr);
- NS_GET16(rr->rr_class, handle->_ptr);
+ NS_GET16(rr->type, handle->_msg_ptr);
+ NS_GET16(rr->rr_class, handle->_msg_ptr);
if (section == ns_s_qd) {
rr->ttl = 0;
rr->rdlength = 0;
rr->rdata = NULL;
} else {
- if (handle->_ptr + NS_INT32SZ + NS_INT16SZ > handle->_eom)
+ if (handle->_msg_ptr + NS_INT32SZ + NS_INT16SZ > handle->_eom)
RETERR(EMSGSIZE);
- NS_GET32(rr->ttl, handle->_ptr);
- NS_GET16(rr->rdlength, handle->_ptr);
- if (handle->_ptr + rr->rdlength > handle->_eom)
+ NS_GET32(rr->ttl, handle->_msg_ptr);
+ NS_GET16(rr->rdlength, handle->_msg_ptr);
+ if (handle->_msg_ptr + rr->rdlength > handle->_eom)
RETERR(EMSGSIZE);
- rr->rdata = handle->_ptr;
- handle->_ptr += rr->rdlength;
+ rr->rdata = handle->_msg_ptr;
+ handle->_msg_ptr += rr->rdlength;
}
if (++handle->_rrnum > handle->_counts[(int)section])
setsection(handle, (ns_sect)((int)section + 1));
@@ -178,6 +187,7 @@ ns_parserr(ns_msg *handle, ns_sect section, int rrnum, ns_rr *rr) {
/* All done. */
return (0);
}
+libresolv_hidden_def (ns_parserr)
/* Private. */
@@ -186,9 +196,11 @@ setsection(ns_msg *msg, ns_sect sect) {
msg->_sect = sect;
if (sect == ns_s_max) {
msg->_rrnum = -1;
- msg->_ptr = NULL;
+ msg->_msg_ptr = NULL;
} else {
msg->_rrnum = 0;
- msg->_ptr = msg->_sections[(int)sect];
+ msg->_msg_ptr = msg->_sections[(int)sect];
}
}
+
+/*! \file */
diff --git a/libc/resolv/ns_print.c b/libc/resolv/ns_print.c
index b0b7a1046..36d39784a 100644
--- a/libc/resolv/ns_print.c
+++ b/libc/resolv/ns_print.c
@@ -1,4 +1,5 @@
/*
+ * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 1996-1999 by Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -34,11 +35,7 @@ static const char rcsid[] = "$BINDId: ns_print.c,v 8.18 2000/02/29 05:48:12 vixi
#include <string.h>
#include <ctype.h>
-#ifdef SPRINTF_CHAR
-# define SPRINTF(x) strlen(sprintf/**/x)
-#else
-# define SPRINTF(x) ((size_t)sprintf x)
-#endif
+#define SPRINTF(x) ((size_t)sprintf x)
/* Forward. */
@@ -54,11 +51,7 @@ static int addstr(const char *src, size_t len,
static int addtab(size_t len, size_t target, int spaced,
char **buf, size_t *buflen);
-/* Proto. */
-
-#ifndef _LIBC
-u_int16_t dst_s_dns_key_id(const u_char *, const int);
-#endif
+static u_int16_t dst_s_dns_key_id(const u_char *, const int);
/* Macros. */
@@ -70,12 +63,11 @@ u_int16_t dst_s_dns_key_id(const u_char *, const int);
/* Public. */
-/*
- * int
- * ns_sprintrr(handle, rr, name_ctx, origin, buf, buflen)
+/*%
* Convert an RR to presentation format.
+ *
* return:
- * Number of characters written to buf, or -1 (check errno).
+ *\li Number of characters written to buf, or -1 (check errno).
*/
int
ns_sprintrr(const ns_msg *handle, const ns_rr *rr,
@@ -90,14 +82,13 @@ ns_sprintrr(const ns_msg *handle, const ns_rr *rr,
name_ctx, origin, buf, buflen);
return (n);
}
+libresolv_hidden_def (ns_sprintrr)
-/*
- * int
- * ns_sprintrrf(msg, msglen, name, class, type, ttl, rdata, rdlen,
- * name_ctx, origin, buf, buflen)
+/*%
* Convert the fields of an RR into presentation format.
+ *
* return:
- * Number of characters written to buf, or -1 (check errno).
+ *\li Number of characters written to buf, or -1 (check errno).
*/
int
ns_sprintrrf(const u_char *msg, size_t msglen,
@@ -122,14 +113,17 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
T(addstr("\t\t\t", 3, &buf, &buflen));
} else {
len = prune_origin(name, origin);
- if (len == 0) {
+ if (*name == '\0') {
+ goto root;
+ } else if (len == 0) {
T(addstr("@\t\t\t", 4, &buf, &buflen));
} else {
T(addstr(name, len, &buf, &buflen));
/* Origin not used or not root, and no trailing dot? */
if (((origin == NULL || origin[0] == '\0') ||
- (origin[0] != '.' && origin[1] != '\0' &&
- name[len] == '\0')) && name[len - 1] != '.') {
+ (origin[0] != '.' && origin[1] != '\0' &&
+ name[len] == '\0')) && name[len - 1] != '.') {
+ root:
T(addstr(".", 1, &buf, &buflen));
len++;
}
@@ -151,7 +145,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
*/
switch (type) {
case ns_t_a:
- if (rdlen != NS_INADDRSZ)
+ if (rdlen != (size_t)NS_INADDRSZ)
goto formerr;
(void) inet_ntop(AF_INET, rdata, buf, buflen);
addlen(strlen(buf), &buf, &buflen);
@@ -163,6 +157,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
case ns_t_mr:
case ns_t_ns:
case ns_t_ptr:
+ case ns_t_dname:
T(addname(msg, msglen, &rdata, origin, &buf, &buflen));
break;
@@ -254,7 +249,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
case ns_t_rt: {
u_int t;
- if (rdlen < NS_INT16SZ)
+ if (rdlen < (size_t)NS_INT16SZ)
goto formerr;
/* Priority. */
@@ -272,7 +267,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
case ns_t_px: {
u_int t;
- if (rdlen < NS_INT16SZ)
+ if (rdlen < (size_t)NS_INT16SZ)
goto formerr;
/* Priority. */
@@ -310,9 +305,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
break;
case ns_t_nsap: {
- /* 2*255 for hex digits, 128 for '.' and '\0', 2 for
- 0x if inet_nsap_ntoa starts using it. */
- char t[255*2 + 128 + 2];
+ char t[2+255*3];
(void) inet_nsap_ntoa(rdlen, rdata, t);
T(addstr(t, strlen(t), &buf, &buflen));
@@ -320,7 +313,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
}
case ns_t_aaaa:
- if (rdlen != NS_IN6ADDRSZ)
+ if (rdlen != (size_t)NS_IN6ADDRSZ)
goto formerr;
(void) inet_ntop(AF_INET6, rdata, buf, buflen);
addlen(strlen(buf), &buf, &buflen);
@@ -339,7 +332,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
u_int order, preference;
char t[50];
- if (rdlen < 2*NS_INT16SZ)
+ if (rdlen < 2U*NS_INT16SZ)
goto formerr;
/* Order, Precedence. */
@@ -380,7 +373,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
u_int priority, weight, port;
char t[50];
- if (rdlen < NS_INT16SZ*3)
+ if (rdlen < 3U*NS_INT16SZ)
goto formerr;
/* Priority, Weight, Port. */
@@ -409,7 +402,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
case ns_t_wks: {
int n, lcnt;
- if (rdlen < NS_INT32SZ + 1)
+ if (rdlen < 1U + NS_INT32SZ)
goto formerr;
/* Address. */
@@ -448,13 +441,12 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
}
case ns_t_key: {
-#ifndef _LIBC
char base64_key[NS_MD5RSA_MAX_BASE64];
u_int keyflags, protocol, algorithm, key_id;
const char *leader;
int n;
- if (rdlen < NS_INT16SZ + NS_INT8SZ + NS_INT8SZ)
+ if (rdlen < 0U + NS_INT16SZ + NS_INT8SZ + NS_INT8SZ)
goto formerr;
/* Key flags, Protocol, Algorithm. */
@@ -486,20 +478,18 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
T(addstr(" )", 2, &buf, &buflen));
n = SPRINTF((tmp, " ; key_tag= %u", key_id));
T(addstr(tmp, n, &buf, &buflen));
-#endif /* !_LIBC */
break;
}
case ns_t_sig: {
-#ifndef _LIBC
char base64_key[NS_MD5RSA_MAX_BASE64];
u_int type, algorithm, labels, footprint;
const char *leader;
u_long t;
int n;
- if (rdlen < 22)
+ if (rdlen < 22U)
goto formerr;
/* Type covered, Algorithm, Label count, Original TTL. */
@@ -549,7 +539,6 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
}
if (len > 15)
T(addstr(" )", 2, &buf, &buflen));
-#endif /* !_LIBC */
break;
}
@@ -571,8 +560,10 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
case ns_t_cert: {
u_int c_type, key_tag, alg;
- int n, siz;
- char base64_cert[8192], *leader, tmp[40];
+ int n;
+ unsigned int siz;
+ char base64_cert[8192], tmp[40];
+ const char *leader;
c_type = ns_get16(rdata); rdata += NS_INT16SZ;
key_tag = ns_get16(rdata); rdata += NS_INT16SZ;
@@ -582,7 +573,7 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
T(addstr(tmp, len, &buf, &buflen));
siz = (edata-rdata)*4/3 + 4; /* "+4" accounts for trailing \0 */
if (siz > sizeof(base64_cert) * 3/4) {
- char *str = "record too long to print";
+ const char *str = "record too long to print";
T(addstr(str, strlen(str), &buf, &buflen));
}
else {
@@ -610,16 +601,47 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
break;
}
+ case ns_t_tkey: {
+ /* KJD - need to complete this */
+ u_long t;
+ int mode, err, keysize;
+
+ /* Algorithm name. */
+ T(addname(msg, msglen, &rdata, origin, &buf, &buflen));
+ T(addstr(" ", 1, &buf, &buflen));
+
+ /* Inception. */
+ t = ns_get32(rdata); rdata += NS_INT32SZ;
+ len = SPRINTF((tmp, "%s ", p_secstodate(t)));
+ T(addstr(tmp, len, &buf, &buflen));
+
+ /* Experation. */
+ t = ns_get32(rdata); rdata += NS_INT32SZ;
+ len = SPRINTF((tmp, "%s ", p_secstodate(t)));
+ T(addstr(tmp, len, &buf, &buflen));
+
+ /* Mode , Error, Key Size. */
+ /* Priority, Weight, Port. */
+ mode = ns_get16(rdata); rdata += NS_INT16SZ;
+ err = ns_get16(rdata); rdata += NS_INT16SZ;
+ keysize = ns_get16(rdata); rdata += NS_INT16SZ;
+ len = SPRINTF((tmp, "%u %u %u ", mode, err, keysize));
+ T(addstr(tmp, len, &buf, &buflen));
+
+ /* XXX need to dump key, print otherdata length & other data */
+ break;
+ }
+
case ns_t_tsig: {
/* BEW - need to complete this */
int n;
T(len = addname(msg, msglen, &rdata, origin, &buf, &buflen));
T(addstr(" ", 1, &buf, &buflen));
- rdata += 8; /* time */
+ rdata += 8; /*%< time */
n = ns_get16(rdata); rdata += INT16SZ;
- rdata += n; /* sig */
- n = ns_get16(rdata); rdata += INT16SZ; /* original id */
+ rdata += n; /*%< sig */
+ n = ns_get16(rdata); rdata += INT16SZ; /*%< original id */
sprintf(buf, "%d", ns_get16(rdata));
rdata += INT16SZ;
addlen(strlen(buf), &buf, &buflen);
@@ -677,7 +699,8 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
int n, m;
char *p;
- len = SPRINTF((tmp, "\\#(\t\t; %s", comment));
+ len = SPRINTF((tmp, "\\# %u%s\t; %s", (unsigned)(edata - rdata),
+ rdlen != 0U ? " (" : "", comment));
T(addstr(tmp, len, &buf, &buflen));
while (rdata < edata) {
p = tmp;
@@ -703,10 +726,11 @@ ns_sprintrrf(const u_char *msg, size_t msglen,
return (buf - obuf);
}
}
+libresolv_hidden_def (ns_sprintrrf)
/* Private. */
-/*
+/*%
* size_t
* prune_origin(name, origin)
* Find out if the name is at or under the current origin.
@@ -739,7 +763,7 @@ prune_origin(const char *name, const char *origin) {
return (name - oname);
}
-/*
+/*%
* int
* charstr(rdata, edata, buf, buflen)
* Format a <character-string> into the presentation buffer.
@@ -795,9 +819,11 @@ addname(const u_char *msg, size_t msglen,
n = dn_expand(msg, msg + msglen, *pp, *buf, *buflen);
if (n < 0)
- goto enospc; /* Guess. */
+ goto enospc; /*%< Guess. */
newlen = prune_origin(*buf, origin);
- if (newlen == 0) {
+ if (**buf == '\0') {
+ goto root;
+ } else if (newlen == 0U) {
/* Use "@" instead of name. */
if (newlen + 2 > *buflen)
goto enospc; /* No room for "@\0". */
@@ -808,6 +834,7 @@ addname(const u_char *msg, size_t msglen,
(origin[0] != '.' && origin[1] != '\0' &&
(*buf)[newlen] == '\0')) && (*buf)[newlen - 1] != '.') {
/* No trailing dot. */
+ root:
if (newlen + 2 > *buflen)
goto enospc; /* No room for ".\0". */
(*buf)[newlen++] = '.';
@@ -864,3 +891,81 @@ addtab(size_t len, size_t target, int spaced, char **buf, size_t *buflen) {
}
return (spaced);
}
+
+/* DST algorithm codes */
+#define KEY_RSA 1
+#define KEY_HMAC_MD5 157
+
+/*%
+ * calculates a checksum used in dst for an id.
+ * takes an array of bytes and a length.
+ * returns a 16 bit checksum.
+ */
+static u_int16_t
+dst_s_id_calc(const u_char *key, const int keysize)
+{
+ u_int32_t ac;
+ const u_char *kp = key;
+ int size = keysize;
+
+ if (!key || (keysize <= 0))
+ return (0xffffU);
+
+ for (ac = 0; size > 1; size -= 2, kp += 2)
+ ac += ((*kp) << 8) + *(kp + 1);
+
+ if (size > 0)
+ ac += ((*kp) << 8);
+ ac += (ac >> 16) & 0xffff;
+
+ return (ac & 0xffff);
+}
+
+/*%
+ * dst_s_get_int16
+ * This routine extracts a 16 bit integer from a two byte character
+ * string. The character string is assumed to be in network byte
+ * order and may be unaligned. The number returned is in host order.
+ * Parameter
+ * buf A two byte character string.
+ * Return
+ * The converted integer value.
+ */
+
+static u_int16_t
+dst_s_get_int16(const u_char *buf)
+{
+ register u_int16_t a = 0;
+ a = ((u_int16_t)(buf[0] << 8)) | ((u_int16_t)(buf[1]));
+ return (a);
+}
+
+/*%
+ * dst_s_dns_key_id() Function to calculate DNSSEC footprint from KEY record
+ * rdata
+ * Input:
+ * dns_key_rdata: the raw data in wire format
+ * rdata_len: the size of the input data
+ * Output:
+ * the key footprint/id calculated from the key data
+ */
+static u_int16_t
+dst_s_dns_key_id(const u_char *dns_key_rdata, const int rdata_len)
+{
+ if (!dns_key_rdata)
+ return 0;
+
+ /* compute id */
+ if (dns_key_rdata[3] == KEY_RSA) /*%< Algorithm RSA */
+ return dst_s_get_int16((const u_char *)
+ &dns_key_rdata[rdata_len - 3]);
+ else if (dns_key_rdata[3] == KEY_HMAC_MD5)
+ /* compatibility */
+ return 0;
+ else
+ /* compute a checksum on the key part of the key rr */
+ return dst_s_id_calc(dns_key_rdata, rdata_len);
+}
+
+
+/*! \file */
diff --git a/libc/resolv/ns_samedomain.c b/libc/resolv/ns_samedomain.c
index 1fb1c552d..44b843a74 100644
--- a/libc/resolv/ns_samedomain.c
+++ b/libc/resolv/ns_samedomain.c
@@ -1,4 +1,5 @@
/*
+ * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 1995,1999 by Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -24,21 +25,22 @@ static const char rcsid[] = "$BINDId: ns_samedomain.c,v 8.9 1999/10/15 21:06:51
#include <errno.h>
#include <string.h>
-/*
- * int
- * ns_samedomain(a, b)
+/*%
* Check whether a name belongs to a domain.
+ *
* Inputs:
- * a - the domain whose ancestory is being verified
- * b - the potential ancestor we're checking against
+ *\li a - the domain whose ancestory is being verified
+ *\li b - the potential ancestor we're checking against
+ *
* Return:
- * boolean - is a at or below b?
+ *\li boolean - is a at or below b?
+ *
* Notes:
- * Trailing dots are first removed from name and domain.
+ *\li Trailing dots are first removed from name and domain.
* Always compare complete subdomains, not only whether the
* domain name is the trailing string of the given name.
*
- * "host.foobar.top" lies in "foobar.top" and in "top" and in ""
+ *\li "host.foobar.top" lies in "foobar.top" and in "top" and in ""
* but NOT in "bar.top"
*/
@@ -52,7 +54,7 @@ ns_samedomain(const char *a, const char *b) {
lb = strlen(b);
/* Ignore a trailing label separator (i.e. an unescaped dot) in 'a'. */
- if (la != 0 && a[la - 1] == '.') {
+ if (la != 0U && a[la - 1] == '.') {
escaped = 0;
/* Note this loop doesn't get executed if la==1. */
for (i = la - 2; i >= 0; i--)
@@ -68,7 +70,7 @@ ns_samedomain(const char *a, const char *b) {
}
/* Ignore a trailing label separator (i.e. an unescaped dot) in 'b'. */
- if (lb != 0 && b[lb - 1] == '.') {
+ if (lb != 0U && b[lb - 1] == '.') {
escaped = 0;
/* note this loop doesn't get executed if lb==1 */
for (i = lb - 2; i >= 0; i--)
@@ -84,7 +86,7 @@ ns_samedomain(const char *a, const char *b) {
}
/* lb == 0 means 'b' is the root domain, so 'a' must be in 'b'. */
- if (lb == 0)
+ if (lb == 0U)
return (1);
/* 'b' longer than 'a' means 'a' can't be in 'b'. */
@@ -121,24 +123,23 @@ ns_samedomain(const char *a, const char *b) {
*/
escaped = 0;
for (i = diff - 2; i >= 0; i--)
- if (a[i] == '\\')
+ if (a[i] == '\\') {
if (escaped)
escaped = 0;
else
escaped = 1;
- else
+ } else
break;
if (escaped)
return (0);
-
+
/* Now compare aligned trailing substring. */
cp = a + diff;
return (strncasecmp(cp, b, lb) == 0);
}
+libresolv_hidden_def (ns_samedomain)
-/*
- * int
- * ns_subdomain(a, b)
+/*%
* is "a" a subdomain of "b"?
*/
int
@@ -146,30 +147,31 @@ ns_subdomain(const char *a, const char *b) {
return (ns_samename(a, b) != 1 && ns_samedomain(a, b));
}
-/*
- * int
- * ns_makecanon(src, dst, dstsize)
+/*%
* make a canonical copy of domain name "src"
+ *
* notes:
+ * \code
* foo -> foo.
* foo. -> foo.
* foo.. -> foo.
* foo\. -> foo\..
* foo\\. -> foo\\.
+ * \endcode
*/
int
ns_makecanon(const char *src, char *dst, size_t dstsize) {
size_t n = strlen(src);
- if (n + sizeof "." > dstsize) {
+ if (n + sizeof "." > dstsize) { /*%< Note: sizeof == 2 */
__set_errno (EMSGSIZE);
return (-1);
}
strcpy(dst, src);
- while (n > 0 && dst[n - 1] == '.') /* Ends in "." */
- if (n > 1 && dst[n - 2] == '\\' && /* Ends in "\." */
- (n < 2 || dst[n - 3] != '\\')) /* But not "\\." */
+ while (n >= 1U && dst[n - 1] == '.') /*%< Ends in "." */
+ if (n >= 2U && dst[n - 2] == '\\' && /*%< Ends in "\." */
+ (n < 3U || dst[n - 3] != '\\')) /*%< But not "\\." */
break;
else
dst[--n] = '\0';
@@ -177,15 +179,15 @@ ns_makecanon(const char *src, char *dst, size_t dstsize) {
dst[n] = '\0';
return (0);
}
+libresolv_hidden_def (ns_makecanon)
-/*
- * int
- * ns_samename(a, b)
+/*%
* determine whether domain name "a" is the same as domain name "b"
+ *
* return:
- * -1 on error
- * 0 if names differ
- * 1 if names are the same
+ *\li -1 on error
+ *\li 0 if names differ
+ *\li 1 if names are the same
*/
int
@@ -200,3 +202,6 @@ ns_samename(const char *a, const char *b) {
else
return (0);
}
+libresolv_hidden_def (ns_samename)
+
+/*! \file */
diff --git a/libc/resolv/ns_ttl.c b/libc/resolv/ns_ttl.c
index 0f74178bb..d4c98bcf3 100644
--- a/libc/resolv/ns_ttl.c
+++ b/libc/resolv/ns_ttl.c
@@ -1,4 +1,5 @@
/*
+ * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 1996,1999 by Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -88,8 +89,8 @@ ns_format_ttl(u_long src, char *dst, size_t dstlen) {
return (dst - odst);
}
+libresolv_hidden_def (ns_format_ttl)
-#ifndef SHARED
// Seems not to be needed. It's not exported from the DSO. Some libresolv.a
// might depend on it so we let it in.
int
@@ -132,7 +133,8 @@ ns_parse_ttl(const char *src, u_long *dst) {
goto einval;
else
ttl += tmp;
- }
+ } else if (!dirty)
+ goto einval;
*dst = ttl;
return (0);
@@ -140,7 +142,6 @@ ns_parse_ttl(const char *src, u_long *dst) {
__set_errno (EINVAL);
return (-1);
}
-#endif
/* Private. */
@@ -157,3 +158,5 @@ fmt1(int t, char s, char **buf, size_t *buflen) {
*buflen -= len;
return (0);
}
+
+/*! \file */
diff --git a/libc/resolv/nss_dns/dns-canon.c b/libc/resolv/nss_dns/dns-canon.c
index fca6cd899..50a0fc026 100644
--- a/libc/resolv/nss_dns/dns-canon.c
+++ b/libc/resolv/nss_dns/dns-canon.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2004, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 2004, 2006, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2004.
@@ -61,7 +61,8 @@ _nss_dns_getcanonname_r (const char *name, char *buffer, size_t buflen,
for (int i = 0; i < nqtypes; ++i)
{
int r = __libc_res_nquery (&_res, name, ns_c_in, qtypes[i],
- buf, sizeof (buf), &ansp.ptr);
+ buf, sizeof (buf), &ansp.ptr, NULL, NULL,
+ NULL);
if (r > 0)
{
/* We need to decode the response. Just one question record.
@@ -133,14 +134,14 @@ _nss_dns_getcanonname_r (const char *name, char *buffer, size_t buflen,
if (type != ns_t_cname)
goto unavail;
- if (ns_get16 (ptr) != ns_c_in)
+ if (__ns_get16 (ptr) != ns_c_in)
goto unavail;
/* Also skip over the TTL. */
ptr += sizeof (uint16_t) + sizeof (uint32_t);
/* Skip over the data length and data. */
- ptr += sizeof (uint16_t) + ns_get16 (ptr);
+ ptr += sizeof (uint16_t) + __ns_get16 (ptr);
}
}
}
diff --git a/libc/resolv/nss_dns/dns-host.c b/libc/resolv/nss_dns/dns-host.c
index dfdf9c5dc..4d43dec94 100644
--- a/libc/resolv/nss_dns/dns-host.c
+++ b/libc/resolv/nss_dns/dns-host.c
@@ -71,6 +71,7 @@
* --Copyright--
*/
+#include <assert.h>
#include <ctype.h>
#include <errno.h>
#include <netdb.h>
@@ -127,6 +128,14 @@ static enum nss_status getanswer_r (const querybuf *answer, int anslen,
size_t buflen, int *errnop, int *h_errnop,
int map, int32_t *ttlp, char **canonp);
+static enum nss_status gaih_getanswer (const querybuf *answer1, int anslen1,
+ const querybuf *answer2, int anslen2,
+ const char *qname,
+ struct gaih_addrtuple **pat,
+ char *buffer, size_t buflen,
+ int *errnop, int *h_errnop,
+ int32_t *ttlp);
+
extern enum nss_status _nss_dns_gethostbyname3_r (const char *name, int af,
struct hostent *result,
char *buffer, size_t buflen,
@@ -186,11 +195,11 @@ _nss_dns_gethostbyname3_r (const char *name, int af, struct hostent *result,
host_buffer.buf = orig_host_buffer = (querybuf *) alloca (1024);
n = __libc_res_nsearch (&_res, name, C_IN, type, host_buffer.buf->buf,
- 1024, &host_buffer.ptr);
+ 1024, &host_buffer.ptr, NULL, NULL, NULL);
if (n < 0)
{
- enum nss_status status = (errno == ECONNREFUSED
- ? NSS_STATUS_UNAVAIL : NSS_STATUS_NOTFOUND);
+ status = (errno == ECONNREFUSED
+ ? NSS_STATUS_UNAVAIL : NSS_STATUS_NOTFOUND);
*h_errnop = h_errno;
if (h_errno == TRY_AGAIN)
*errnop = EAGAIN;
@@ -203,7 +212,8 @@ _nss_dns_gethostbyname3_r (const char *name, int af, struct hostent *result,
if (af == AF_INET6 && (_res.options & RES_USE_INET6))
n = __libc_res_nsearch (&_res, name, C_IN, T_A, host_buffer.buf->buf,
host_buffer.buf != orig_host_buffer
- ? MAXPACKET : 1024, &host_buffer.ptr);
+ ? MAXPACKET : 1024, &host_buffer.ptr,
+ NULL, NULL, NULL);
if (n < 0)
{
@@ -255,6 +265,70 @@ _nss_dns_gethostbyname_r (const char *name, struct hostent *result,
}
+enum nss_status
+_nss_dns_gethostbyname4_r (const char *name, struct gaih_addrtuple **pat,
+ char *buffer, size_t buflen, int *errnop,
+ int *herrnop, int32_t *ttlp)
+{
+ if (__res_maybe_init (&_res, 0) == -1)
+ return NSS_STATUS_UNAVAIL;
+
+ /*
+ * if there aren't any dots, it could be a user-level alias.
+ * this is also done in res_query() since we are not the only
+ * function that looks up host names.
+ */
+ if (strchr (name, '.') == NULL)
+ {
+ char *tmp = alloca (NS_MAXDNAME);
+ const char *cp = res_hostalias (&_res, name, tmp, NS_MAXDNAME);
+ if (cp != NULL)
+ name = cp;
+ }
+
+ union
+ {
+ querybuf *buf;
+ u_char *ptr;
+ } host_buffer;
+ querybuf *orig_host_buffer;
+ host_buffer.buf = orig_host_buffer = (querybuf *) alloca (2048);
+ u_char *ans2p = NULL;
+ int nans2p = 0;
+ int resplen2 = 0;
+
+ int olderr = errno;
+ enum nss_status status;
+ int n = __libc_res_nsearch (&_res, name, C_IN, T_UNSPEC,
+ host_buffer.buf->buf, 2048, &host_buffer.ptr,
+ &ans2p, &nans2p, &resplen2);
+ if (n < 0)
+ {
+ status = (errno == ECONNREFUSED
+ ? NSS_STATUS_UNAVAIL : NSS_STATUS_NOTFOUND);
+ *herrnop = h_errno;
+ if (h_errno == TRY_AGAIN)
+ *errnop = EAGAIN;
+ else
+ __set_errno (olderr);
+
+ if (host_buffer.buf != orig_host_buffer)
+ free (host_buffer.buf);
+
+ return status;
+ }
+
+ status = gaih_getanswer(host_buffer.buf, n, (const querybuf *) ans2p,
+ resplen2, name, pat, buffer, buflen,
+ errnop, herrnop, ttlp);
+
+ if (host_buffer.buf != orig_host_buffer)
+ free (host_buffer.buf);
+
+ return status;
+}
+
+
extern enum nss_status _nss_dns_gethostbyaddr2_r (const void *addr,
socklen_t len, int af,
struct hostent *result,
@@ -342,7 +416,8 @@ _nss_dns_gethostbyaddr2_r (const void *addr, socklen_t len, int af,
qp += sprintf (qp, "%02hhx", uaddr[n]);
strcpy (qp, "].ip6.arpa");
n = __libc_res_nquery (&_res, qbuf, C_IN, T_PTR,
- host_buffer.buf->buf, 1024, &host_buffer.ptr);
+ host_buffer.buf->buf, 1024, &host_buffer.ptr,
+ NULL, NULL, NULL);
if (n >= 0)
goto got_it_already;
}
@@ -363,13 +438,14 @@ _nss_dns_gethostbyaddr2_r (const void *addr, socklen_t len, int af,
}
n = __libc_res_nquery (&_res, qbuf, C_IN, T_PTR, host_buffer.buf->buf,
- 1024, &host_buffer.ptr);
+ 1024, &host_buffer.ptr, NULL, NULL, NULL);
if (n < 0 && af == AF_INET6 && (_res.options & RES_NOIP6DOTINT) == 0)
{
strcpy (qp, "ip6.int");
n = __libc_res_nquery (&_res, qbuf, C_IN, T_PTR, host_buffer.buf->buf,
host_buffer.buf != orig_host_buffer
- ? MAXPACKET : 1024, &host_buffer.ptr);
+ ? MAXPACKET : 1024, &host_buffer.ptr,
+ NULL, NULL, NULL);
}
if (n < 0)
{
@@ -555,7 +631,8 @@ getanswer_r (const querybuf *answer, int anslen, const char *qname, int qtype,
if (n > 0 && bp[0] == '.')
bp[0] = '\0';
- if (n < 0 || (*name_ok) (bp) == 0)
+ if (__builtin_expect (n < 0 || ((*name_ok) (bp) == 0 && (errno = EBADMSG)),
+ 0))
{
*errnop = errno;
*h_errnop = NO_RECOVERY;
@@ -608,33 +685,40 @@ getanswer_r (const querybuf *answer, int anslen, const char *qname, int qtype,
n = -1;
}
- if (n < 0 || (*name_ok) (bp) == 0)
+ if (__builtin_expect (n < 0 || (*name_ok) (bp) == 0, 0))
{
++had_error;
continue;
}
cp += n; /* name */
- type = ns_get16 (cp);
+
+ if (__builtin_expect (cp + 10 > end_of_message, 0))
+ {
+ ++had_error;
+ continue;
+ }
+
+ type = __ns_get16 (cp);
cp += INT16SZ; /* type */
- class = ns_get16 (cp);
+ class = __ns_get16 (cp);
cp += INT16SZ; /* class */
- ttl = ns_get32 (cp);
+ ttl = __ns_get32 (cp);
cp += INT32SZ; /* TTL */
- n = ns_get16 (cp);
+ n = __ns_get16 (cp);
cp += INT16SZ; /* len */
- if (class != C_IN)
+ if (__builtin_expect (class != C_IN, 0))
{
/* XXX - debug? syslog? */
cp += n;
continue; /* XXX - had_error++ ? */
}
- if ((qtype ==T_A || qtype == T_AAAA) && type == T_CNAME)
+ if ((qtype == T_A || qtype == T_AAAA) && type == T_CNAME)
{
if (ap >= &host_data->aliases[MAX_NR_ALIASES - 1])
continue;
n = dn_expand (answer->buf, end_of_message, cp, tbuf, sizeof tbuf);
- if (n < 0 || (*name_ok) (tbuf) == 0)
+ if (__builtin_expect (n < 0 || (*name_ok) (tbuf) == 0, 0))
{
++had_error;
continue;
@@ -668,7 +752,7 @@ getanswer_r (const querybuf *answer, int anslen, const char *qname, int qtype,
if (qtype == T_PTR && type == T_CNAME)
{
n = dn_expand (answer->buf, end_of_message, cp, tbuf, sizeof tbuf);
- if (n < 0 || res_dnok (tbuf) == 0)
+ if (__builtin_expect (n < 0 || res_dnok (tbuf) == 0, 0))
{
++had_error;
continue;
@@ -715,7 +799,7 @@ getanswer_r (const querybuf *answer, int anslen, const char *qname, int qtype,
switch (type)
{
case T_PTR:
- if (__strcasecmp (tname, bp) != 0)
+ if (__builtin_expect (__strcasecmp (tname, bp) != 0, 0))
{
syslog (LOG_NOTICE | LOG_AUTH, AskedForGot, qname, bp);
cp += n;
@@ -732,7 +816,7 @@ getanswer_r (const querybuf *answer, int anslen, const char *qname, int qtype,
n = -1;
}
- if (n < 0 || res_hnok (bp) == 0)
+ if (__builtin_expect (n < 0 || res_hnok (bp) == 0, 0))
{
++had_error;
break;
@@ -762,7 +846,7 @@ getanswer_r (const querybuf *answer, int anslen, const char *qname, int qtype,
if (have_to_map)
{
n = strlen (bp) + 1; /* for the \0 */
- if (n >= MAXHOSTNAMELEN)
+ if (__builtin_expect (n >= MAXHOSTNAMELEN, 0))
{
++had_error;
break;
@@ -857,3 +941,268 @@ getanswer_r (const querybuf *answer, int anslen, const char *qname, int qtype,
return ((qtype == T_A || qtype == T_AAAA) && ap != host_data->aliases
? NSS_STATUS_NOTFOUND : NSS_STATUS_TRYAGAIN);
}
+
+
+static enum nss_status
+gaih_getanswer_slice (const querybuf *answer, int anslen, const char *qname,
+ struct gaih_addrtuple ***patp,
+ char **bufferp, size_t *buflenp,
+ int *errnop, int *h_errnop, int32_t *ttlp, int *firstp)
+{
+ char *buffer = *bufferp;
+ size_t buflen = *buflenp;
+
+ struct gaih_addrtuple **pat = *patp;
+ const HEADER *hp = &answer->hdr;
+ int ancount = ntohs (hp->ancount);
+ int qdcount = ntohs (hp->qdcount);
+ const u_char *cp = answer->buf + HFIXEDSZ;
+ const u_char *end_of_message = answer->buf + anslen;
+ if (__builtin_expect (qdcount != 1, 0))
+ {
+ *h_errnop = NO_RECOVERY;
+ return NSS_STATUS_UNAVAIL;
+ }
+
+ u_char packtmp[NS_MAXCDNAME];
+ int n = __ns_name_unpack (answer->buf, end_of_message, cp,
+ packtmp, sizeof packtmp);
+ /* We unpack the name to check it for validity. But we do not need
+ it later. */
+ if (n != -1 && __ns_name_ntop (packtmp, buffer, buflen) == -1)
+ {
+ if (__builtin_expect (errno, 0) == EMSGSIZE)
+ {
+ too_small:
+ *errnop = ERANGE;
+ *h_errnop = NETDB_INTERNAL;
+ return NSS_STATUS_TRYAGAIN;
+ }
+
+ n = -1;
+ }
+
+ if (__builtin_expect (n < 0 || (res_hnok (buffer) == 0
+ && (errno = EBADMSG)), 0))
+ {
+ *errnop = errno;
+ *h_errnop = NO_RECOVERY;
+ return NSS_STATUS_UNAVAIL;
+ }
+ cp += n + QFIXEDSZ;
+
+ int haveanswer = 0;
+ int had_error = 0;
+ char *canon = NULL;
+ char *h_name = NULL;
+ int h_namelen = 0;
+
+ if (ancount == 0)
+ return NSS_STATUS_NOTFOUND;
+
+ while (ancount-- > 0 && cp < end_of_message && had_error == 0)
+ {
+ n = __ns_name_unpack (answer->buf, end_of_message, cp,
+ packtmp, sizeof packtmp);
+ if (n != -1 &&
+ (h_namelen = __ns_name_ntop (packtmp, buffer, buflen)) == -1)
+ {
+ if (__builtin_expect (errno, 0) == EMSGSIZE)
+ goto too_small;
+
+ n = -1;
+ }
+ if (__builtin_expect (n < 0 || res_hnok (buffer) == 0, 0))
+ {
+ ++had_error;
+ continue;
+ }
+ if (*firstp)
+ {
+ h_name = buffer;
+ buffer += h_namelen;
+ buflen -= h_namelen;
+ }
+
+ cp += n; /* name */
+
+ if (__builtin_expect (cp + 10 > end_of_message, 0))
+ {
+ ++had_error;
+ continue;
+ }
+
+ int type = __ns_get16 (cp);
+ cp += INT16SZ; /* type */
+ int class = __ns_get16 (cp);
+ cp += INT16SZ; /* class */
+ int32_t ttl = __ns_get32 (cp);
+ cp += INT32SZ; /* TTL */
+ n = __ns_get16 (cp);
+ cp += INT16SZ; /* len */
+
+ if (class != C_IN)
+ {
+ cp += n;
+ continue;
+ }
+
+ if (type == T_CNAME)
+ {
+ char tbuf[MAXDNAME];
+ n = dn_expand (answer->buf, end_of_message, cp, tbuf, sizeof tbuf);
+ if (__builtin_expect (n < 0 || res_hnok (tbuf) == 0, 0))
+ {
+ ++had_error;
+ continue;
+ }
+ cp += n;
+
+ if (*firstp)
+ {
+ /* Reclaim buffer space. */
+ if (h_name + h_namelen == buffer)
+ {
+ buffer = h_name;
+ buflen += h_namelen;
+ }
+
+ n = strlen (tbuf) + 1;
+ if (__builtin_expect (n > buflen, 0))
+ goto too_small;
+ if (__builtin_expect (n >= MAXHOSTNAMELEN, 0))
+ {
+ ++had_error;
+ continue;
+ }
+
+ canon = buffer;
+ buffer = __mempcpy (buffer, tbuf, n);
+ buflen -= n;
+ h_namelen = 0;
+ }
+ continue;
+ }
+ if (__builtin_expect (type == T_SIG, 0)
+ || __builtin_expect (type == T_KEY, 0)
+ || __builtin_expect (type == T_NXT, 0)
+ || __builtin_expect (type == T_PTR, 0)
+ || __builtin_expect (type == T_DNAME, 0))
+ {
+ /* We don't support DNSSEC yet. For now, ignore the record
+ and send a low priority message to syslog.
+
+ We also don't expect T_PTR or T_DNAME messages. */
+ syslog (LOG_DEBUG | LOG_AUTH,
+ "getaddrinfo*.gaih_getanswer: got type \"%s\"",
+ p_type (type));
+ cp += n;
+ continue;
+ }
+ if (type != T_A && type != T_AAAA)
+ abort ();
+
+ if (*pat == NULL)
+ {
+ uintptr_t pad = (-(uintptr_t) buffer
+ % __alignof__ (struct gaih_addrtuple));
+ buffer += pad;
+ buflen = buflen > pad ? buflen - pad : 0;
+
+ if (__builtin_expect (buflen < sizeof (struct gaih_addrtuple),
+ 0))
+ goto too_small;
+
+ *pat = (struct gaih_addrtuple *) buffer;
+ buffer += sizeof (struct gaih_addrtuple);
+ buflen -= sizeof (struct gaih_addrtuple);
+ }
+
+ (*pat)->name = NULL;
+ (*pat)->next = NULL;
+
+ if (*firstp)
+ {
+ if (ttl != 0 && ttlp != NULL)
+ *ttlp = ttl;
+
+ if (canon != NULL)
+ {
+ (*pat)->name = canon;
+
+ /* Reclaim buffer space. */
+ if (h_name + h_namelen == buffer)
+ {
+ buffer = h_name;
+ buflen += h_namelen;
+ }
+ }
+ else
+ (*pat)->name = h_name;
+
+ *firstp = 0;
+ }
+
+ (*pat)->family = type == T_A ? AF_INET : AF_INET6;
+ if (__builtin_expect ((type == T_A && n != INADDRSZ)
+ || (type == T_AAAA && n != IN6ADDRSZ), 0))
+ {
+ ++had_error;
+ continue;
+ }
+ memcpy ((*pat)->addr, cp, n);
+ cp += n;
+ (*pat)->scopeid = 0;
+
+ pat = &((*pat)->next);
+
+ haveanswer = 1;
+ }
+
+ if (haveanswer)
+ {
+ *patp = pat;
+ *bufferp = buffer;
+ *buflenp = buflen;
+
+ *h_errnop = NETDB_SUCCESS;
+ return NSS_STATUS_SUCCESS;
+ }
+
+ /* Special case here: if the resolver sent a result but it only
+ contains a CNAME while we are looking for a T_A or T_AAAA record,
+ we fail with NOTFOUND instead of TRYAGAIN. */
+ return canon == NULL ? NSS_STATUS_TRYAGAIN : NSS_STATUS_NOTFOUND;
+}
+
+
+static enum nss_status
+gaih_getanswer (const querybuf *answer1, int anslen1, const querybuf *answer2,
+ int anslen2, const char *qname,
+ struct gaih_addrtuple **pat, char *buffer, size_t buflen,
+ int *errnop, int *h_errnop, int32_t *ttlp)
+{
+ int first = 1;
+
+ enum nss_status status = NSS_STATUS_NOTFOUND;
+
+ if (anslen1 > 0)
+ status = gaih_getanswer_slice(answer1, anslen1, qname,
+ &pat, &buffer, &buflen,
+ errnop, h_errnop, ttlp,
+ &first);
+ if ((status == NSS_STATUS_SUCCESS || status == NSS_STATUS_NOTFOUND
+ || (status == NSS_STATUS_TRYAGAIN
+ && (errno != ERANGE || *h_errnop != NO_RECOVERY)))
+ && answer2 != NULL && anslen2 > 0)
+ {
+ enum nss_status status2 = gaih_getanswer_slice(answer2, anslen2, qname,
+ &pat, &buffer, &buflen,
+ errnop, h_errnop, ttlp,
+ &first);
+ if (status != NSS_STATUS_SUCCESS && status2 != NSS_STATUS_NOTFOUND)
+ status = status2;
+ }
+
+ return status;
+}
diff --git a/libc/resolv/nss_dns/dns-network.c b/libc/resolv/nss_dns/dns-network.c
index 4552b5b67..c9969e08d 100644
--- a/libc/resolv/nss_dns/dns-network.c
+++ b/libc/resolv/nss_dns/dns-network.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996, 1997, 1998, 1999, 2002, 2004, 2007
+/* Copyright (C) 1996, 1997, 1998, 1999, 2002, 2004, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
Extended from original form by Ulrich Drepper <drepper@cygnus.com>, 1996.
@@ -130,7 +130,7 @@ _nss_dns_getnetbyname_r (const char *name, struct netent *result,
net_buffer.buf = orig_net_buffer = (querybuf *) alloca (1024);
anslen = __libc_res_nsearch (&_res, qbuf, C_IN, T_PTR, net_buffer.buf->buf,
- 1024, &net_buffer.ptr);
+ 1024, &net_buffer.ptr, NULL, NULL, NULL);
if (anslen < 0)
{
/* Nothing found. */
@@ -206,7 +206,7 @@ _nss_dns_getnetbyaddr_r (uint32_t net, int type, struct netent *result,
net_buffer.buf = orig_net_buffer = (querybuf *) alloca (1024);
anslen = __libc_res_nquery (&_res, qbuf, C_IN, T_PTR, net_buffer.buf->buf,
- 1024, &net_buffer.ptr);
+ 1024, &net_buffer.ptr, NULL, NULL, NULL);
if (anslen < 0)
{
/* Nothing found. */
diff --git a/libc/resolv/res_debug.c b/libc/resolv/res_debug.c
index cd69d4f4d..c38de640a 100644
--- a/libc/resolv/res_debug.c
+++ b/libc/resolv/res_debug.c
@@ -439,6 +439,7 @@ const struct res_sym __p_type_syms[] = {
{ns_t_nimloc, "NIMLOC", "NIMROD locator (unimplemented)"},
{ns_t_srv, "SRV", "server selection"},
{ns_t_atma, "ATMA", "ATM address (unimplemented)"},
+ {ns_t_dname, "DNAME", "Non-terminal DNAME (for IPv6)"},
{ns_t_tsig, "TSIG", "transaction signature"},
{ns_t_ixfr, "IXFR", "incremental zone transfer"},
{ns_t_axfr, "AXFR", "zone transfer"},
@@ -1023,6 +1024,7 @@ dn_count_labels(const char *name) {
count++;
return (count);
}
+libresolv_hidden_def (__dn_count_labels)
/*
@@ -1050,3 +1052,4 @@ p_secstodate (u_long secs) {
time->tm_hour, time->tm_min, time->tm_sec);
return (output);
}
+libresolv_hidden_def (__p_secstodate)
diff --git a/libc/resolv/res_init.c b/libc/resolv/res_init.c
index d1a5681a9..a2840968f 100644
--- a/libc/resolv/res_init.c
+++ b/libc/resolv/res_init.c
@@ -69,22 +69,22 @@ static const char sccsid[] = "@(#)res_init.c 8.1 (Berkeley) 6/7/93";
static const char rcsid[] = "$BINDId: res_init.c,v 8.16 2000/05/09 07:10:12 vixie Exp $";
#endif /* LIBC_SCCS and not lint */
-#include <sys/types.h>
-#include <sys/param.h>
-#include <sys/socket.h>
-#include <sys/time.h>
-
-#include <netinet/in.h>
-#include <arpa/inet.h>
-#include <arpa/nameser.h>
-
#include <ctype.h>
+#include <netdb.h>
#include <resolv.h>
#include <stdio.h>
#include <stdio_ext.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
+#include <arpa/inet.h>
+#include <arpa/nameser.h>
+#include <net/if.h>
+#include <netinet/in.h>
+#include <sys/param.h>
+#include <sys/socket.h>
+#include <sys/time.h>
+#include <sys/types.h>
#include <not-cancel.h>
@@ -327,15 +327,41 @@ __res_vinit(res_state statp, int preinit) {
if ((el = strchr(cp, '\n')) != NULL)
*el = '\0';
+ if ((el = strchr(cp, SCOPE_DELIMITER)) != NULL)
+ *el = '\0';
if ((*cp != '\0') &&
(inet_pton(AF_INET6, cp, &a6) > 0)) {
struct sockaddr_in6 *sa6;
sa6 = malloc(sizeof(*sa6));
if (sa6 != NULL) {
- sa6->sin6_addr = a6;
sa6->sin6_family = AF_INET6;
sa6->sin6_port = htons(NAMESERVER_PORT);
+ sa6->sin6_flowinfo = 0;
+ sa6->sin6_addr = a6;
+
+ if (__builtin_expect (el == NULL, 1))
+ sa6->sin6_scope_id = 0;
+ else {
+ int try_numericscope = 1;
+ if (IN6_IS_ADDR_LINKLOCAL (&a6)
+ || IN6_IS_ADDR_MC_LINKLOCAL (&a6)) {
+ sa6->sin6_scope_id
+ = if_nametoindex (el + 1);
+ if (sa6->sin6_scope_id != 0)
+ try_numericscope = 0;
+ }
+
+ if (try_numericscope) {
+ char *end;
+ sa6->sin6_scope_id
+ = (uint32_t) strtoul (el + 1, &end,
+ 10);
+ if (*end != '\0')
+ sa6->sin6_scope_id = 0;
+ }
+ }
+
statp->_u._ext.nsaddrs[nservall] = sa6;
statp->_u._ext.nssocks[nservall] = -1;
statp->_u._ext.nsmap[nservall] = MAXNS + 1;
diff --git a/libc/resolv/res_mkquery.c b/libc/resolv/res_mkquery.c
index 3fa597fec..ae0cdb417 100644
--- a/libc/resolv/res_mkquery.c
+++ b/libc/resolv/res_mkquery.c
@@ -160,7 +160,10 @@ res_nmkquery(res_state statp,
if ((buflen -= QFIXEDSZ) < 0)
return (-1);
compose:
- if ((n = dn_comp(dname, cp, buflen, dnptrs, lastdnptr)) < 0)
+ n = ns_name_compress(dname, cp, buflen,
+ (const u_char **) dnptrs,
+ (const u_char **) lastdnptr);
+ if (n < 0)
return (-1);
cp += n;
buflen -= n;
@@ -172,7 +175,9 @@ res_nmkquery(res_state statp,
/*
* Make an additional record for completion domain.
*/
- n = dn_comp((char *)data, cp, buflen, dnptrs, lastdnptr);
+ n = ns_name_compress((char *)data, cp, buflen,
+ (const u_char **) dnptrs,
+ (const u_char **) lastdnptr);
if (__builtin_expect (n < 0, 0))
return (-1);
cp += n;
@@ -238,17 +243,13 @@ __res_nopt(res_state statp,
*cp++ = 0; /* "." */
- ns_put16(T_OPT, cp); /* TYPE */
- cp += INT16SZ;
- ns_put16(anslen & 0xffff, cp); /* CLASS = UDP payload size */
- cp += INT16SZ;
+ NS_PUT16(T_OPT, cp); /* TYPE */
+ NS_PUT16(anslen & 0xffff, cp); /* CLASS = UDP payload size */
*cp++ = NOERROR; /* extended RCODE */
*cp++ = 0; /* EDNS version */
/* XXX Once we support DNSSEC we change the flag value here. */
- ns_put16(flags, cp);
- cp += INT16SZ;
- ns_put16(0, cp); /* RDLEN */
- cp += INT16SZ;
+ NS_PUT16(flags, cp);
+ NS_PUT16(0, cp); /* RDLEN */
hp->arcount = htons(ntohs(hp->arcount) + 1);
return cp - buf;
diff --git a/libc/resolv/res_query.c b/libc/resolv/res_query.c
index 4371af5b0..7102ba948 100644
--- a/libc/resolv/res_query.c
+++ b/libc/resolv/res_query.c
@@ -97,7 +97,8 @@ static const char rcsid[] = "$BINDId: res_query.c,v 8.20 2000/02/29 05:39:12 vix
static int
__libc_res_nquerydomain(res_state statp, const char *name, const char *domain,
int class, int type, u_char *answer, int anslen,
- u_char **answerp);
+ u_char **answerp, u_char **answerp2, int *nanswerp2,
+ int *resplen2);
/*
* Formulate a normal query, send, and await answer.
@@ -115,15 +116,21 @@ __libc_res_nquery(res_state statp,
int class, int type, /* class and type of query */
u_char *answer, /* buffer to put answer */
int anslen, /* size of answer buffer */
- u_char **answerp) /* if buffer needs to be enlarged */
+ u_char **answerp, /* if buffer needs to be enlarged */
+ u_char **answerp2,
+ int *nanswerp2,
+ int *resplen2)
{
- u_char *buf;
HEADER *hp = (HEADER *) answer;
int n, use_malloc = 0;
u_int oflags = statp->_flags;
- size_t bufsize = QUERYSIZE;
- buf = alloca (bufsize);
+ size_t bufsize = (type == T_UNSPEC ? 2 : 1) * QUERYSIZE;
+ u_char *buf = alloca (bufsize);
+ u_char *query1 = buf;
+ int nquery1 = -1;
+ u_char *query2 = NULL;
+ int nquery2 = 0;
again:
hp->rcode = NOERROR; /* default */
@@ -133,18 +140,63 @@ __libc_res_nquery(res_state statp,
printf(";; res_query(%s, %d, %d)\n", name, class, type);
#endif
- n = res_nmkquery(statp, QUERY, name, class, type, NULL, 0, NULL,
- buf, bufsize);
- if (n > 0
- && (oflags & RES_F_EDNS0ERR) == 0
- && (statp->options & RES_USE_EDNS0) != 0)
- n = __res_nopt(statp, n, buf, bufsize, anslen);
+ if (type == T_UNSPEC)
+ {
+ n = res_nmkquery(statp, QUERY, name, class, T_A, NULL, 0, NULL,
+ query1, bufsize);
+ if (n > 0)
+ {
+ if ((oflags & RES_F_EDNS0ERR) == 0
+ && (statp->options & RES_USE_EDNS0) != 0)
+ {
+ n = __res_nopt(statp, n, query1, bufsize, anslen / 2);
+ if (n < 0)
+ goto unspec_nomem;
+ }
+
+ nquery1 = n;
+ /* Align the buffer. */
+ int npad = ((nquery1 + __alignof__ (HEADER) - 1)
+ & ~(__alignof__ (HEADER) - 1)) - nquery1;
+ if (n > bufsize - npad)
+ {
+ n = -1;
+ goto unspec_nomem;
+ }
+ int nused = n + npad;
+ query2 = buf + nused;
+ n = res_nmkquery(statp, QUERY, name, class, T_AAAA, NULL, 0,
+ NULL, query2, bufsize - nused);
+ if (n > 0
+ && (oflags & RES_F_EDNS0ERR) == 0
+ && (statp->options & RES_USE_EDNS0) != 0)
+ n = __res_nopt(statp, n, query2, bufsize - nused - n,
+ anslen / 2);
+ nquery2 = n;
+ }
+
+ unspec_nomem:;
+ }
+ else
+ {
+ n = res_nmkquery(statp, QUERY, name, class, type, NULL, 0, NULL,
+ query1, bufsize);
+
+ if (n > 0
+ && (oflags & RES_F_EDNS0ERR) == 0
+ && (statp->options & RES_USE_EDNS0) != 0)
+ n = __res_nopt(statp, n, query1, bufsize, anslen);
+
+ nquery1 = n;
+ }
+
if (__builtin_expect (n <= 0, 0) && !use_malloc) {
/* Retry just in case res_nmkquery failed because of too
short buffer. Shouldn't happen. */
- bufsize = MAXPACKET;
+ bufsize = (type == T_UNSPEC ? 2 : 1) * MAXPACKET;
buf = malloc (bufsize);
if (buf != NULL) {
+ query1 = buf;
use_malloc = 1;
goto again;
}
@@ -154,8 +206,10 @@ __libc_res_nquery(res_state statp,
if ((statp->options & RES_USE_EDNS0) != 0
&& ((oflags ^ statp->_flags) & RES_F_EDNS0ERR) != 0) {
statp->_flags |= RES_F_EDNS0ERR;
+#ifdef DEBUG
if (statp->options & RES_DEBUG)
printf(";; res_nquery: retry without EDNS0\n");
+#endif
goto again;
}
#ifdef DEBUG
@@ -168,7 +222,8 @@ __libc_res_nquery(res_state statp,
return (n);
}
assert (answerp == NULL || (void *) *answerp == (void *) answer);
- n = __libc_res_nsend(statp, buf, n, answer, anslen, answerp);
+ n = __libc_res_nsend(statp, query1, nquery1, query2, nquery2, answer,
+ anslen, answerp, answerp2, nanswerp2, resplen2);
if (use_malloc)
free (buf);
if (n < 0) {
@@ -184,20 +239,52 @@ __libc_res_nquery(res_state statp,
/* __libc_res_nsend might have reallocated the buffer. */
hp = (HEADER *) *answerp;
- if (hp->rcode != NOERROR || ntohs(hp->ancount) == 0) {
+ /* We simplify the following tests by assigning HP to HP2. It
+ is easy to verify that this is the same as ignoring all
+ tests of HP2. */
+ HEADER *hp2 = answerp2 ? (HEADER *) *answerp2 : hp;
+
+ if (n < sizeof (HEADER) && nanswerp2 != NULL
+ && *nanswerp2 > sizeof (HEADER))
+ {
+ /* Special case of partial answer. */
+ assert (hp != hp2);
+ hp = hp2;
+ }
+ else if (nanswerp2 != NULL
+ && *nanswerp2 < sizeof (HEADER) && n > sizeof (HEADER))
+ {
+ /* Special case of partial answer. */
+ assert (hp != hp2);
+ hp2 = hp;
+ }
+
+ if ((hp->rcode != NOERROR || ntohs(hp->ancount) == 0)
+ && (hp2->rcode != NOERROR || ntohs(hp2->ancount) == 0)) {
#ifdef DEBUG
- if (statp->options & RES_DEBUG)
+ if (statp->options & RES_DEBUG) {
printf(";; rcode = %d, ancount=%d\n", hp->rcode,
ntohs(hp->ancount));
+ if (hp != hp2)
+ printf(";; rcode2 = %d, ancount2=%d\n", hp2->rcode,
+ ntohs(hp2->ancount));
+ }
#endif
- switch (hp->rcode) {
+ switch (hp->rcode == NOERROR ? hp2->rcode : hp->rcode) {
case NXDOMAIN:
+ if ((hp->rcode == NOERROR && ntohs (hp->ancount) != 0)
+ || (hp2->rcode == NOERROR
+ && ntohs (hp2->ancount) != 0))
+ goto success;
RES_SET_H_ERRNO(statp, HOST_NOT_FOUND);
break;
case SERVFAIL:
RES_SET_H_ERRNO(statp, TRY_AGAIN);
break;
case NOERROR:
+ if (ntohs (hp->ancount) != 0
+ || ntohs (hp2->ancount) != 0)
+ goto success;
RES_SET_H_ERRNO(statp, NO_DATA);
break;
case FORMERR:
@@ -209,6 +296,7 @@ __libc_res_nquery(res_state statp,
}
return (-1);
}
+ success:
return (n);
}
libresolv_hidden_def (__libc_res_nquery)
@@ -221,7 +309,7 @@ res_nquery(res_state statp,
int anslen) /* size of answer buffer */
{
return __libc_res_nquery(statp, name, class, type, answer, anslen,
- NULL);
+ NULL, NULL, NULL, NULL);
}
libresolv_hidden_def (res_nquery)
@@ -233,11 +321,14 @@ libresolv_hidden_def (res_nquery)
*/
int
__libc_res_nsearch(res_state statp,
- const char *name, /* domain name */
- int class, int type, /* class and type of query */
- u_char *answer, /* buffer to put answer */
- int anslen, /* size of answer */
- u_char **answerp)
+ const char *name, /* domain name */
+ int class, int type, /* class and type of query */
+ u_char *answer, /* buffer to put answer */
+ int anslen, /* size of answer */
+ u_char **answerp,
+ u_char **answerp2,
+ int *nanswerp2,
+ int *resplen2)
{
const char *cp, * const *domain;
HEADER *hp = (HEADER *) answer;
@@ -260,7 +351,8 @@ __libc_res_nsearch(res_state statp,
/* If there aren't any dots, it could be a user-level alias. */
if (!dots && (cp = res_hostalias(statp, name, tmp, sizeof tmp))!= NULL)
return (__libc_res_nquery(statp, cp, class, type, answer,
- anslen, answerp));
+ anslen, answerp, answerp2,
+ nanswerp2, resplen2));
#ifdef DEBUG
if (statp->options & RES_DEBUG)
@@ -276,7 +368,8 @@ __libc_res_nsearch(res_state statp,
saved_herrno = -1;
if (dots >= statp->ndots || trailing_dot) {
ret = __libc_res_nquerydomain(statp, name, NULL, class, type,
- answer, anslen, answerp);
+ answer, anslen, answerp,
+ answerp2, nanswerp2, resplen2);
if (ret > 0 || trailing_dot)
return (ret);
saved_herrno = h_errno;
@@ -285,6 +378,12 @@ __libc_res_nsearch(res_state statp,
answer = *answerp;
anslen = MAXPACKET;
}
+ if (answerp2
+ && (*answerp2 < answer || *answerp2 >= answer + anslen))
+ {
+ free (*answerp2);
+ *answerp2 = NULL;
+ }
}
/*
@@ -307,7 +406,9 @@ __libc_res_nsearch(res_state statp,
ret = __libc_res_nquerydomain(statp, name, *domain,
class, type,
- answer, anslen, answerp);
+ answer, anslen, answerp,
+ answerp2, nanswerp2,
+ resplen2);
if (ret > 0)
return (ret);
@@ -315,6 +416,13 @@ __libc_res_nsearch(res_state statp,
answer = *answerp;
anslen = MAXPACKET;
}
+ if (answerp2
+ && (*answerp2 < answer
+ || *answerp2 >= answer + anslen))
+ {
+ free (*answerp2);
+ *answerp2 = NULL;
+ }
/*
* If no server present, give up.
@@ -368,7 +476,8 @@ __libc_res_nsearch(res_state statp,
*/
if (dots && !(tried_as_is || root_on_list)) {
ret = __libc_res_nquerydomain(statp, name, NULL, class, type,
- answer, anslen, answerp);
+ answer, anslen, answerp,
+ answerp2, nanswerp2, resplen2);
if (ret > 0)
return (ret);
}
@@ -380,6 +489,11 @@ __libc_res_nsearch(res_state statp,
* else send back meaningless H_ERRNO, that being the one from
* the last DNSRCH we did.
*/
+ if (answerp2 && (*answerp2 < answer || *answerp2 >= answer + anslen))
+ {
+ free (*answerp2);
+ *answerp2 = NULL;
+ }
if (saved_herrno != -1)
RES_SET_H_ERRNO(statp, saved_herrno);
else if (got_nodata)
@@ -398,7 +512,7 @@ res_nsearch(res_state statp,
int anslen) /* size of answer */
{
return __libc_res_nsearch(statp, name, class, type, answer,
- anslen, NULL);
+ anslen, NULL, NULL, NULL, NULL);
}
libresolv_hidden_def (res_nsearch)
@@ -408,12 +522,15 @@ libresolv_hidden_def (res_nsearch)
*/
static int
__libc_res_nquerydomain(res_state statp,
- const char *name,
- const char *domain,
- int class, int type, /* class and type of query */
- u_char *answer, /* buffer to put answer */
- int anslen, /* size of answer */
- u_char **answerp)
+ const char *name,
+ const char *domain,
+ int class, int type, /* class and type of query */
+ u_char *answer, /* buffer to put answer */
+ int anslen, /* size of answer */
+ u_char **answerp,
+ u_char **answerp2,
+ int *nanswerp2,
+ int *resplen2)
{
char nbuf[MAXDNAME];
const char *longname = nbuf;
@@ -450,7 +567,8 @@ __libc_res_nquerydomain(res_state statp,
sprintf(nbuf, "%s.%s", name, domain);
}
return (__libc_res_nquery(statp, longname, class, type, answer,
- anslen, answerp));
+ anslen, answerp, answerp2, nanswerp2,
+ resplen2));
}
int
@@ -462,7 +580,7 @@ res_nquerydomain(res_state statp,
int anslen) /* size of answer */
{
return __libc_res_nquerydomain(statp, name, domain, class, type,
- answer, anslen, NULL);
+ answer, anslen, NULL, NULL, NULL, NULL);
}
libresolv_hidden_def (res_nquerydomain)
diff --git a/libc/resolv/res_send.c b/libc/resolv/res_send.c
index 23306a2fb..3130f6428 100644
--- a/libc/resolv/res_send.c
+++ b/libc/resolv/res_send.c
@@ -176,10 +176,14 @@ evNowTime(struct timespec *res) {
/* Forward. */
static int send_vc(res_state, const u_char *, int,
- u_char **, int *, int *, int, u_char **);
+ const u_char *, int,
+ u_char **, int *, int *, int, u_char **,
+ u_char **, int *, int *);
static int send_dg(res_state, const u_char *, int,
+ const u_char *, int,
u_char **, int *, int *, int,
- int *, int *, u_char **);
+ int *, int *, u_char **,
+ u_char **, int *, int *);
#ifdef DEBUG
static void Aerror(const res_state, FILE *, const char *, int,
const struct sockaddr *);
@@ -190,7 +194,6 @@ static int sock_eq(struct sockaddr_in6 *, struct sockaddr_in6 *);
/* Reachover. */
static void convaddr4to6(struct sockaddr_in6 *sa);
-void res_pquery(const res_state, const u_char *, int, FILE *);
/* Public. */
@@ -334,33 +337,41 @@ libresolv_hidden_def (res_queriesmatch)
int
__libc_res_nsend(res_state statp, const u_char *buf, int buflen,
- u_char *ans, int anssiz, u_char **ansp)
+ const u_char *buf2, int buflen2,
+ u_char *ans, int anssiz, u_char **ansp, u_char **ansp2,
+ int *nansp2, int *resplen2)
{
- int gotsomewhere, terrno, try, v_circuit, resplen, ns, n;
+ int gotsomewhere, terrno, try, v_circuit, resplen, ns, n;
if (statp->nscount == 0) {
__set_errno (ESRCH);
return (-1);
}
- if (anssiz < HFIXEDSZ) {
+ if (anssiz < (buf2 == NULL ? 1 : 2) * HFIXEDSZ) {
__set_errno (EINVAL);
return (-1);
}
- if ((statp->qhook || statp->rhook) && anssiz < MAXPACKET && ansp) {
- u_char *buf = malloc (MAXPACKET);
- if (buf == NULL)
- return (-1);
- memcpy (buf, ans, HFIXEDSZ);
- *ansp = buf;
- ans = buf;
- anssiz = MAXPACKET;
+#ifdef USE_HOOKS
+ if (__builtin_expect (statp->qhook || statp->rhook, 0)) {
+ if (anssiz < MAXPACKET && ansp) {
+ u_char *buf = malloc (MAXPACKET);
+ if (buf == NULL)
+ return (-1);
+ memcpy (buf, ans, HFIXEDSZ);
+ *ansp = buf;
+ ans = buf;
+ anssiz = MAXPACKET;
+ }
}
+#endif
DprintQ((statp->options & RES_DEBUG) || (statp->pfcode & RES_PRF_QUERY),
(stdout, ";; res_send()\n"), buf, buflen);
- v_circuit = (statp->options & RES_USEVC) || buflen > PACKETSZ;
+ v_circuit = ((statp->options & RES_USEVC)
+ || buflen > PACKETSZ
+ || buflen2 > PACKETSZ);
gotsomewhere = 0;
terrno = ETIMEDOUT;
@@ -442,7 +453,7 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
* Some resolvers want to even out the load on their nameservers.
* Note that RES_BLAST overrides RES_ROTATE.
*/
- if ((statp->options & RES_ROTATE) != 0 &&
+ if (__builtin_expect ((statp->options & RES_ROTATE) != 0, 0) &&
(statp->options & RES_BLAST) == 0) {
struct sockaddr_in6 *ina;
unsigned int map;
@@ -479,8 +490,9 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
if (nsap == NULL)
goto next_ns;
- same_ns:
- if (statp->qhook) {
+ same_ns:
+#ifdef USE_HOOKS
+ if (__builtin_expect (statp->qhook != NULL, 0)) {
int done = 0, loops = 0;
do {
@@ -512,6 +524,7 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
}
} while (!done);
}
+#endif
#ifdef DEBUG
char tmpbuf[40];
@@ -521,29 +534,34 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
ns + 1, inet_ntop(AF_INET6, &nsap->sin6_addr,
tmpbuf, sizeof (tmpbuf))));
- if (v_circuit) {
+ if (__builtin_expect (v_circuit, 0)) {
/* Use VC; at most one attempt per server. */
try = statp->retry;
- n = send_vc(statp, buf, buflen, &ans, &anssiz, &terrno,
- ns, ansp);
+ n = send_vc(statp, buf, buflen, buf2, buflen2,
+ &ans, &anssiz, &terrno,
+ ns, ansp, ansp2, nansp2, resplen2);
if (n < 0)
return (-1);
if (n == 0)
goto next_ns;
- resplen = n;
} else {
/* Use datagrams. */
- n = send_dg(statp, buf, buflen, &ans, &anssiz, &terrno,
- ns, &v_circuit, &gotsomewhere, ansp);
+ n = send_dg(statp, buf, buflen, buf2, buflen2,
+ &ans, &anssiz, &terrno,
+ ns, &v_circuit, &gotsomewhere, ansp,
+ ansp2, nansp2, resplen2);
if (n < 0)
return (-1);
if (n == 0)
goto next_ns;
if (v_circuit)
+ // XXX Check whether both requests failed or
+ // XXX whether one has been answered successfully
goto same_ns;
- resplen = n;
}
+ resplen = n;
+
Dprint((statp->options & RES_DEBUG) ||
((statp->pfcode & RES_PRF_REPLY) &&
(statp->pfcode & RES_PRF_HEAD1)),
@@ -553,6 +571,11 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
(statp->pfcode & RES_PRF_REPLY),
(stdout, "%s", ""),
ans, (resplen > anssiz) ? anssiz : resplen);
+ if (buf2 != NULL)
+ DprintQ((statp->options & RES_DEBUG) ||
+ (statp->pfcode & RES_PRF_REPLY),
+ (stdout, "%s", ""),
+ *ansp2, (*resplen2 > *nansp2) ? *nansp2 : *resplen2);
/*
* If we have temporarily opened a virtual circuit,
@@ -563,7 +586,8 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
(statp->options & RES_STAYOPEN) == 0) {
__res_iclose(statp, false);
}
- if (statp->rhook) {
+#ifdef USE_HOOKS
+ if (__builtin_expect (statp->rhook, 0)) {
int done = 0, loops = 0;
do {
@@ -593,6 +617,7 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
} while (!done);
}
+#endif
return (resplen);
next_ns: ;
} /*foreach ns*/
@@ -612,7 +637,8 @@ int
res_nsend(res_state statp,
const u_char *buf, int buflen, u_char *ans, int anssiz)
{
- return __libc_res_nsend(statp, buf, buflen, ans, anssiz, NULL);
+ return __libc_res_nsend(statp, buf, buflen, NULL, 0, ans, anssiz,
+ NULL, NULL, NULL, NULL);
}
libresolv_hidden_def (res_nsend)
@@ -620,19 +646,27 @@ libresolv_hidden_def (res_nsend)
static int
send_vc(res_state statp,
- const u_char *buf, int buflen, u_char **ansp, int *anssizp,
- int *terrno, int ns, u_char **anscp)
+ const u_char *buf, int buflen, const u_char *buf2, int buflen2,
+ u_char **ansp, int *anssizp,
+ int *terrno, int ns, u_char **anscp, u_char **ansp2, int *anssizp2,
+ int *resplen2)
{
const HEADER *hp = (HEADER *) buf;
+ const HEADER *hp2 = (HEADER *) buf2;
u_char *ans = *ansp;
- int anssiz = *anssizp;
+ int orig_anssizp = *anssizp;
+ // XXX REMOVE
+ // int anssiz = *anssizp;
HEADER *anhp = (HEADER *) ans;
struct sockaddr_in6 *nsap = EXT(statp).nsaddrs[ns];
int truncating, connreset, resplen, n;
- struct iovec iov[2];
+ struct iovec iov[4];
u_short len;
+ u_short len2;
u_char *cp;
+ if (resplen2 != NULL)
+ *resplen2 = 0;
connreset = 0;
same_ns:
truncating = 0;
@@ -677,11 +711,19 @@ send_vc(res_state statp,
/*
* Send length & message
*/
- ns_put16((u_short)buflen, (u_char*)&len);
+ len = htons ((u_short) buflen);
evConsIovec(&len, INT16SZ, &iov[0]);
evConsIovec((void*)buf, buflen, &iov[1]);
- if (TEMP_FAILURE_RETRY (writev(statp->_vcsock, iov, 2))
- != (INT16SZ + buflen)) {
+ int niov = 2;
+ ssize_t explen = INT16SZ + buflen;
+ if (buf2 != NULL) {
+ len2 = htons ((u_short) buflen2);
+ evConsIovec(&len2, INT16SZ, &iov[2]);
+ evConsIovec((void*)buf2, buflen2, &iov[3]);
+ niov = 4;
+ explen += INT16SZ + buflen2;
+ }
+ if (TEMP_FAILURE_RETRY (writev(statp->_vcsock, iov, niov)) != explen) {
*terrno = errno;
Perror(statp, stderr, "write failed", errno);
__res_iclose(statp, false);
@@ -690,10 +732,13 @@ send_vc(res_state statp,
/*
* Receive length & response
*/
+ int recvresp1 = 0;
+ int recvresp2 = buf2 == NULL;
read_len:
cp = ans;
- len = INT16SZ;
- while ((n = TEMP_FAILURE_RETRY (read(statp->_vcsock, (char *)cp,
+ uint16_t rlen16;
+ len = sizeof(rlen16);
+ while ((n = TEMP_FAILURE_RETRY (read(statp->_vcsock, &rlen16,
(int)len))) > 0) {
cp += n;
if ((len -= n) <= 0)
@@ -718,31 +763,63 @@ send_vc(res_state statp,
}
return (0);
}
- resplen = ns_get16(ans);
- if (resplen > anssiz) {
- if (anscp) {
- ans = malloc (MAXPACKET);
- if (ans == NULL) {
+ int rlen = ntohs (rlen16);
+
+ int *thisanssizp;
+ u_char **thisansp;
+ int *thisresplenp;
+ if ((recvresp1 | recvresp2) == 0 || buf2 == NULL) {
+ thisanssizp = anssizp;
+ thisansp = anscp ?: ansp;
+ assert (anscp != NULL || ansp2 == NULL);
+ thisresplenp = &resplen;
+ } else {
+ if (*anssizp != MAXPACKET) {
+ /* No buffer allocated for the first
+ reply. We can try to use the rest
+ of the user-provided buffer. */
+ *anssizp2 = orig_anssizp - resplen;
+ *ansp2 = *ansp + resplen;
+ } else {
+ /* The first reply did not fit into the
+ user-provided buffer. Maybe the second
+ answer will. */
+ *anssizp2 = orig_anssizp;
+ *ansp2 = *ansp;
+ }
+
+ thisanssizp = anssizp2;
+ thisansp = ansp2;
+ thisresplenp = resplen2;
+ }
+ anhp = (HEADER *) *thisansp;
+
+ *thisresplenp = rlen;
+ if (rlen > *thisanssizp) {
+ /* Yes, we test ANSCP here. If we have two buffers
+ both will be allocatable. */
+ if (__builtin_expect (anscp != NULL, 1)) {
+ u_char *newp = malloc (MAXPACKET);
+ if (newp == NULL) {
*terrno = ENOMEM;
__res_iclose(statp, false);
return (0);
}
- anssiz = MAXPACKET;
- *anssizp = MAXPACKET;
- *ansp = ans;
- *anscp = ans;
- anhp = (HEADER *) ans;
- len = resplen;
+ *thisanssizp = MAXPACKET;
+ *thisansp = newp;
+ anhp = (HEADER *) newp;
+ len = rlen;
} else {
Dprint(statp->options & RES_DEBUG,
(stdout, ";; response truncated\n")
);
truncating = 1;
- len = anssiz;
+ len = *thisanssizp;
}
} else
- len = resplen;
- if (len < HFIXEDSZ) {
+ len = rlen;
+
+ if (__builtin_expect (len < HFIXEDSZ, 0)) {
/*
* Undersized message.
*/
@@ -752,23 +829,24 @@ send_vc(res_state statp,
__res_iclose(statp, false);
return (0);
}
- cp = ans;
+
+ cp = *thisansp;
while (len != 0 && (n = read(statp->_vcsock, (char *)cp, (int)len)) > 0){
cp += n;
len -= n;
}
- if (n <= 0) {
+ if (__builtin_expect (n <= 0, 0)) {
*terrno = errno;
Perror(statp, stderr, "read(vc)", errno);
__res_iclose(statp, false);
return (0);
}
- if (truncating) {
+ if (__builtin_expect (truncating, 0)) {
/*
* Flush rest of answer so connection stays in synch.
*/
anhp->tc = 1;
- len = resplen - anssiz;
+ len = rlen - *thisanssizp;
while (len != 0) {
char junk[PACKETSZ];
@@ -787,36 +865,48 @@ send_vc(res_state statp,
* itself confused, then drop the packet and
* wait for the correct one.
*/
- if (hp->id != anhp->id) {
+ if ((recvresp1 || hp->id != anhp->id)
+ && (recvresp2 || hp2->id != anhp->id)) {
DprintQ((statp->options & RES_DEBUG) ||
(statp->pfcode & RES_PRF_REPLY),
(stdout, ";; old answer (unexpected):\n"),
- ans, (resplen > anssiz) ? anssiz: resplen);
+ *thisansp,
+ (rlen > *thisanssiz) ? *thisanssiz: rlen);
goto read_len;
}
+ /* Mark which reply we received. */
+ if (recvresp1 == 0 && hp->id == anhp->id)
+ recvresp1 = 1;
+ else
+ recvresp2 = 1;
+ /* Repeat waiting if we have a second answer to arrive. */
+ if ((recvresp1 & recvresp2) == 0)
+ goto read_len;
+
/*
* All is well, or the error is fatal. Signal that the
* next nameserver ought not be tried.
*/
- return (resplen);
+ return resplen;
}
static int
send_dg(res_state statp,
- const u_char *buf, int buflen, u_char **ansp, int *anssizp,
- int *terrno, int ns, int *v_circuit, int *gotsomewhere, u_char **anscp)
+ const u_char *buf, int buflen, const u_char *buf2, int buflen2,
+ u_char **ansp, int *anssizp,
+ int *terrno, int ns, int *v_circuit, int *gotsomewhere, u_char **anscp,
+ u_char **ansp2, int *anssizp2, int *resplen2)
{
const HEADER *hp = (HEADER *) buf;
+ const HEADER *hp2 = (HEADER *) buf2;
u_char *ans = *ansp;
- int anssiz = *anssizp;
- HEADER *anhp = (HEADER *) ans;
+ int orig_anssizp = *anssizp;
struct sockaddr_in6 *nsap = EXT(statp).nsaddrs[ns];
struct timespec now, timeout, finish;
struct pollfd pfd[1];
int ptimeout;
struct sockaddr_in6 from;
- socklen_t fromlen;
int resplen, seconds, n;
if (EXT(statp).nssocks[ns] == -1) {
@@ -879,8 +969,12 @@ send_dg(res_state statp,
evAddTime(&finish, &now, &timeout);
int need_recompute = 0;
int nwritten = 0;
+ int recvresp1 = 0;
+ int recvresp2 = buf2 == NULL;
pfd[0].fd = EXT(statp).nssocks[ns];
pfd[0].events = POLLOUT;
+ if (resplen2 != NULL)
+ *resplen2 = 0;
wait:
if (need_recompute) {
recompute_resend:
@@ -905,8 +999,13 @@ send_dg(res_state statp,
need_recompute = 1;
}
if (n == 0) {
- Dprint(statp->options & RES_DEBUG, (stdout,
- ";; timeout sending\n"));
+ Dprint(statp->options & RES_DEBUG, (stdout, ";; timeout\n"));
+ if (recvresp1 || (buf2 != NULL && recvresp2))
+ {
+ *resplen2 = 1;
+ return resplen;
+ }
+
*gotsomewhere = 1;
return (0);
}
@@ -918,35 +1017,73 @@ send_dg(res_state statp,
}
__set_errno (0);
if (pfd[0].revents & POLLOUT) {
- if (send (pfd[0].fd, buf, buflen, MSG_NOSIGNAL) != buflen) {
+ ssize_t sr;
+ if (nwritten != 0)
+ sr = send (pfd[0].fd, buf2, buflen2, MSG_NOSIGNAL);
+ else
+ sr = send (pfd[0].fd, buf, buflen, MSG_NOSIGNAL);
+
+ if (sr != buflen) {
if (errno == EINTR || errno == EAGAIN)
goto recompute_resend;
Perror(statp, stderr, "send", errno);
goto err_out;
}
- pfd[0].events = POLLIN;
+ if (nwritten != 0 || buf2 == NULL)
+ pfd[0].events = POLLIN;
+ else
+ pfd[0].events = POLLIN | POLLOUT;
++nwritten;
goto wait;
} else if (pfd[0].revents & POLLIN) {
- fromlen = sizeof(struct sockaddr_in6);
- if (anssiz < MAXPACKET
+ int *thisanssizp;
+ u_char **thisansp;
+ int *thisresplenp;
+
+ if ((recvresp1 | recvresp2) == 0 || buf2 == NULL) {
+ thisanssizp = anssizp;
+ thisansp = anscp ?: ansp;
+ assert (anscp != NULL || ansp2 == NULL);
+ thisresplenp = &resplen;
+ } else {
+ if (*anssizp != MAXPACKET) {
+ /* No buffer allocated for the first
+ reply. We can try to use the rest
+ of the user-provided buffer. */
+ *anssizp2 = orig_anssizp - resplen;
+ *ansp2 = *ansp + resplen;
+ } else {
+ /* The first reply did not fit into the
+ user-provided buffer. Maybe the second
+ answer will. */
+ *anssizp2 = orig_anssizp;
+ *ansp2 = *ansp;
+ }
+
+ thisanssizp = anssizp2;
+ thisansp = ansp2;
+ thisresplenp = resplen2;
+ }
+
+ if (*thisanssizp < MAXPACKET
+ /* Yes, we test ANSCP here. If we have two buffers
+ both will be allocatable. */
&& anscp
- && (ioctl (pfd[0].fd, FIONREAD, &resplen) < 0
- || anssiz < resplen)) {
- ans = malloc (MAXPACKET);
- if (ans == NULL)
- ans = *ansp;
- else {
- anssiz = MAXPACKET;
+ && (ioctl (pfd[0].fd, FIONREAD, thisresplenp) < 0
+ || *thisanssizp < *thisresplenp)) {
+ u_char *newp = malloc (MAXPACKET);
+ if (newp != NULL) {
*anssizp = MAXPACKET;
- *ansp = ans;
- *anscp = ans;
- anhp = (HEADER *) ans;
+ *thisansp = ans = newp;
}
}
- resplen = recvfrom(pfd[0].fd, (char*)ans, anssiz,0,
- (struct sockaddr *)&from, &fromlen);
- if (resplen <= 0) {
+ HEADER *anhp = (HEADER *) *thisansp;
+ socklen_t fromlen = sizeof(struct sockaddr_in6);
+ assert (sizeof(from) <= fromlen);
+ *thisresplenp = recvfrom(pfd[0].fd, (char*)*thisansp,
+ *thisanssizp, 0,
+ (struct sockaddr *)&from, &fromlen);
+ if (__builtin_expect (*thisresplenp <= 0, 0)) {
if (errno == EINTR || errno == EAGAIN) {
need_recompute = 1;
goto wait;
@@ -955,17 +1092,18 @@ send_dg(res_state statp,
goto err_out;
}
*gotsomewhere = 1;
- if (resplen < HFIXEDSZ) {
+ if (__builtin_expect (*thisresplenp < HFIXEDSZ, 0)) {
/*
* Undersized message.
*/
Dprint(statp->options & RES_DEBUG,
(stdout, ";; undersized: %d\n",
- resplen));
+ *thisresplen));
*terrno = EMSGSIZE;
goto err_out;
}
- if (hp->id != anhp->id) {
+ if ((recvresp1 || hp->id != anhp->id)
+ && (recvresp2 || hp2->id != anhp->id)) {
/*
* response from old query, ignore it.
* XXX - potential security hazard could
@@ -974,7 +1112,9 @@ send_dg(res_state statp,
DprintQ((statp->options & RES_DEBUG) ||
(statp->pfcode & RES_PRF_REPLY),
(stdout, ";; old answer:\n"),
- ans, (resplen > anssiz) ? anssiz : resplen);
+ thisansp,
+ (*thisresplen > *thisanssiz)
+ ? *thisanssiz : *thisresplen);
goto wait;
}
if (!(statp->options & RES_INSECURE1) &&
@@ -987,14 +1127,16 @@ send_dg(res_state statp,
DprintQ((statp->options & RES_DEBUG) ||
(statp->pfcode & RES_PRF_REPLY),
(stdout, ";; not our server:\n"),
- ans, (resplen > anssiz) ? anssiz : resplen);
+ thisansp,
+ (*thisresplen > *thisanssiz)
+ ? *thisanssiz : *thisresplen);
goto wait;
}
#ifdef RES_USE_EDNS0
if (anhp->rcode == FORMERR
&& (statp->options & RES_USE_EDNS0) != 0U) {
/*
- * Do not retry if the server do not understand
+ * Do not retry if the server does not understand
* EDNS0. The case has to be captured here, as
* FORMERR packet do not carry query section, hence
* res_queriesmatch() returns 0.
@@ -1002,15 +1144,23 @@ send_dg(res_state statp,
DprintQ(statp->options & RES_DEBUG,
(stdout,
"server rejected query with EDNS0:\n"),
- ans, (resplen > anssiz) ? anssiz : resplen);
+ thisans,
+ (*thisresplen > *thisanssiz)
+ ? *thisanssiz : *thisresplen);
/* record the error */
statp->_flags |= RES_F_EDNS0ERR;
goto err_out;
}
#endif
- if (!(statp->options & RES_INSECURE2) &&
- !res_queriesmatch(buf, buf + buflen,
- ans, ans + anssiz)) {
+ if (!(statp->options & RES_INSECURE2)
+ && (recvresp1 || !res_queriesmatch(buf, buf + buflen,
+ *thisansp,
+ *thisansp
+ + *thisanssizp))
+ && (recvresp2 || !res_queriesmatch(buf2, buf2 + buflen2,
+ *thisansp,
+ *thisansp
+ + *thisanssizp))) {
/*
* response contains wrong query? ignore it.
* XXX - potential security hazard could
@@ -1019,7 +1169,9 @@ send_dg(res_state statp,
DprintQ((statp->options & RES_DEBUG) ||
(statp->pfcode & RES_PRF_REPLY),
(stdout, ";; wrong query name:\n"),
- ans, (resplen > anssiz) ? anssiz : resplen);
+ thisansp,
+ (*thisresplen > *thisanssiz)
+ ? *thisanssiz : *thisresplen);
goto wait;
}
if (anhp->rcode == SERVFAIL ||
@@ -1027,7 +1179,27 @@ send_dg(res_state statp,
anhp->rcode == REFUSED) {
DprintQ(statp->options & RES_DEBUG,
(stdout, "server rejected query:\n"),
- ans, (resplen > anssiz) ? anssiz : resplen);
+ thisansp,
+ (*thisresplen > *thisanssiz)
+ ? *thisanssiz : *thisresplen);
+
+ if (recvresp1 || (buf2 != NULL && recvresp2))
+ {
+ *resplen2 = 1;
+ return resplen;
+ }
+ if (buf2 != NULL)
+ {
+ /* We are waiting for a possible second reply. */
+ resplen = 1;
+ if (hp->id == anhp->id)
+ recvresp1 = 1;
+ else
+ recvresp2 = 1;
+
+ goto wait;
+ }
+
next_ns:
__res_iclose(statp, false);
/* don't retry if called from dig */
@@ -1038,7 +1210,9 @@ send_dg(res_state statp,
&& anhp->aa == 0 && anhp->ra == 0 && anhp->arcount == 0) {
DprintQ(statp->options & RES_DEBUG,
(stdout, "referred query:\n"),
- ans, (resplen > anssiz) ? anssiz : resplen);
+ thisansp,
+ (*thisresplen > *thisanssiz)
+ ? *thisanssiz : *thisresplen);
goto next_ns;
}
if (!(statp->options & RES_IGNTC) && anhp->tc) {
@@ -1050,8 +1224,18 @@ send_dg(res_state statp,
(stdout, ";; truncated answer\n"));
*v_circuit = 1;
__res_iclose(statp, false);
+ // XXX if we have received one reply we could
+ // XXX use it and not repeat it over TCP...
return (1);
}
+ /* Mark which reply we received. */
+ if (recvresp1 == 0 && hp->id == anhp->id)
+ recvresp1 = 1;
+ else
+ recvresp2 = 1;
+ /* Repeat waiting if we have a second answer to arrive. */
+ if ((recvresp1 & recvresp2) == 0)
+ goto wait;
/*
* All is well, or the error is fatal. Signal that the
* next nameserver ought not be tried.
diff --git a/libc/scripts/abi-versions.awk b/libc/scripts/abi-versions.awk
index ab98d78e5..06fa14833 100644
--- a/libc/scripts/abi-versions.awk
+++ b/libc/scripts/abi-versions.awk
@@ -30,6 +30,9 @@ $2 == "=" {
printf "#define ABI_%s_%s\tABI_%s_%s\n", libid, oldid, libid, newid;
printf "#define VERSION_%s_%s\t%s\n", libid, oldid, new;
+
+ if ("GLIBC_" oldest_abi == old)
+ oldest_abi = "default";
next;
}
diff --git a/libc/scripts/data/localplt-powerpc64-linux-gnu.data b/libc/scripts/data/localplt-powerpc64-linux-gnu.data
new file mode 100644
index 000000000..2219aa904
--- /dev/null
+++ b/libc/scripts/data/localplt-powerpc64-linux-gnu.data
@@ -0,0 +1,6 @@
+libc.so: calloc
+libc.so: free
+libc.so: malloc
+libc.so: memalign
+libc.so: realloc
+libm.so: matherr
diff --git a/libc/scripts/data/localplt-sparc-linux-gnu.data b/libc/scripts/data/localplt-sparc-linux-gnu.data
new file mode 100644
index 000000000..5ceed16c9
--- /dev/null
+++ b/libc/scripts/data/localplt-sparc-linux-gnu.data
@@ -0,0 +1,18 @@
+libc.so: _Q_add
+libc.so: _Q_div
+libc.so: _Q_feq
+libc.so: _Q_fge
+libc.so: _Q_fle
+libc.so: _Q_flt
+libc.so: _Q_fne
+libc.so: _Q_itoq
+libc.so: _Q_mul
+libc.so: _Q_sub
+libc.so: _Unwind_Find_FDE
+libc.so: calloc
+libc.so: ffs
+libc.so: free
+libc.so: malloc
+libc.so: memalign
+libc.so: realloc
+libm.so: matherr
diff --git a/libc/scripts/data/localplt-sparc64-linux-gnu.data b/libc/scripts/data/localplt-sparc64-linux-gnu.data
new file mode 100644
index 000000000..5e6e42d67
--- /dev/null
+++ b/libc/scripts/data/localplt-sparc64-linux-gnu.data
@@ -0,0 +1,20 @@
+libc.so: _Qp_add
+libc.so: _Qp_div
+libc.so: _Qp_feq
+libc.so: _Qp_fge
+libc.so: _Qp_fle
+libc.so: _Qp_flt
+libc.so: _Qp_fne
+libc.so: _Qp_itoq
+libc.so: _Qp_mul
+libc.so: _Qp_qtod
+libc.so: _Qp_sub
+libc.so: _Qp_xtoq
+libc.so: _Unwind_Find_FDE
+libc.so: calloc
+libc.so: ffs
+libc.so: free
+libc.so: malloc
+libc.so: memalign
+libc.so: realloc
+libm.so: matherr
diff --git a/libc/scripts/gen-as-const.awk b/libc/scripts/gen-as-const.awk
index bc3c47fb7..20d18c12a 100644
--- a/libc/scripts/gen-as-const.awk
+++ b/libc/scripts/gen-as-const.awk
@@ -14,12 +14,22 @@ BEGIN { started = 0 }
NF >= 1 && !started {
if (test) {
+ print "\n#include <inttypes.h>";
print "\n#include <stdio.h>";
+ print "\n#if __WORDSIZE__ == 64";
+ print "\ntypedef uint64_t c_t;";
+ print "\n#define U(n) UINT64_C (n)";
+ print "\n#define PRI PRId64";
+ print "\n#else";
+ print "\ntypedef uint32_t c_t;";
+ print "\n#define U(n) UINT32_C (n)";
+ print "\n#define PRI PRId32";
+ print "\n#endif";
print "\nstatic int do_test (void)\n{\n int bad = 0, good = 0;\n";
print "#define TEST(name, source, expr) \\\n" \
- " if (asconst_##name != (expr)) { ++bad;" \
- " fprintf (stderr, \"%s: %s is %ld but %s is %ld\\n\"," \
- " source, #name, (long int) asconst_##name, #expr, (long int) (expr));" \
+ " if (U (asconst_##name) != (c_t) (expr)) { ++bad;" \
+ " fprintf (stderr, \"%s: %s is %\" PRI \" but %s is %\"PRI \"\\n\"," \
+ " source, #name, U (asconst_##name), #expr, (c_t) (expr));" \
" } else ++good;\n";
}
else
diff --git a/libc/scripts/soversions.awk b/libc/scripts/soversions.awk
index 32ce076ba..55577ccc7 100644
--- a/libc/scripts/soversions.awk
+++ b/libc/scripts/soversions.awk
@@ -18,6 +18,16 @@ $2 ~ /WORDSIZE[3264]/ {
next;
}
+$2 == "ABI" {
+ if ((config ~ thiscf) && !abiname) {
+ abiname = $3;
+ sub(/@CPU@/, cpu, abiname);
+ sub(/@VENDOR@/, vendor, abiname);
+ sub(/@OS@/, os, abiname);
+ }
+ next;
+}
+
# Obey the first matching DEFAULT line.
$2 == "DEFAULT" {
$1 = $2 = "";
@@ -66,6 +76,9 @@ END {
}
}
}
+ if (abiname) {
+ print "ABI", abiname
+ }
for (c in lines) {
print lines[c]
}
diff --git a/libc/shlib-versions b/libc/shlib-versions
index 9a10fc056..65e772bbb 100644
--- a/libc/shlib-versions
+++ b/libc/shlib-versions
@@ -43,6 +43,11 @@ powerpc.*-.*-.* WORDSIZE64 powerpc64-@VENDOR@-@OS@
sparc64.*-.*-.* WORDSIZE32 sparc-@VENDOR@-@OS@
sparc.*-.*-.* WORDSIZE64 sparc64-@VENDOR@-@OS@
+# Configuration ABI Identifier for ABI data files
+# ------------- ---------- -----------------------------
+sparc64.*-.*-.* ABI sparc64-@OS@
+sparc.*-.*-.* ABI sparc-@OS@
+
# Configuration Library=version Earliest symbol set (optional)
# ------------- --------------- ------------------------------
diff --git a/libc/socket/Makefile b/libc/socket/Makefile
index aa0776e5b..e7fa589e6 100644
--- a/libc/socket/Makefile
+++ b/libc/socket/Makefile
@@ -1,4 +1,4 @@
-# Copyright (C) 1991,1995-2001,2005 Free Software Foundation, Inc.
+# Copyright (C) 1991,1995-2001,2005,2008 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
@@ -27,7 +27,9 @@ headers := sys/socket.h sys/un.h bits/sockaddr.h bits/socket.h \
routines := accept bind connect getpeername getsockname getsockopt \
listen recv recvfrom recvmsg send sendmsg sendto \
setsockopt shutdown socket socketpair isfdtype opensock \
- sockatmark
+ sockatmark paccept
+
+aux := have_sock_cloexec
distribute := ifreq.h
diff --git a/libc/socket/Versions b/libc/socket/Versions
index d282eff79..9764227c3 100644
--- a/libc/socket/Versions
+++ b/libc/socket/Versions
@@ -31,4 +31,7 @@ libc {
# Addition from P1003.1-200x
sockatmark;
}
+ GLIBC_2.9 {
+ paccept;
+ }
}
diff --git a/libc/socket/have_sock_cloexec.c b/libc/socket/have_sock_cloexec.c
new file mode 100644
index 000000000..22dccdf72
--- /dev/null
+++ b/libc/socket/have_sock_cloexec.c
@@ -0,0 +1,24 @@
+/* Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sys/socket.h>
+#include <kernel-features.h>
+
+#if defined SOCK_CLOEXEC && !defined __ASSUME_SOCK_CLOEXEC
+int __have_sock_cloexec;
+#endif
diff --git a/libc/socket/paccept.c b/libc/socket/paccept.c
new file mode 100644
index 000000000..777dd8c30
--- /dev/null
+++ b/libc/socket/paccept.c
@@ -0,0 +1,43 @@
+/* Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <errno.h>
+#include <sys/socket.h>
+
+/* Await a connection on socket FD.
+ When a connection arrives, open a new socket to communicate with it,
+ set *ADDR (which is *ADDR_LEN bytes long) to the address of the connecting
+ peer and *ADDR_LEN to the address's actual length, and return the
+ new socket's descriptor, or -1 for errors. SS is installed as
+ the thread's signal mask and FLAGS are additional flags. */
+int
+paccept (fd, addr, addr_len, ss, flags)
+ int fd;
+ __SOCKADDR_ARG addr;
+ socklen_t *addr_len;
+ const __sigset_t *ss;
+ int flags;
+{
+ __set_errno (ENOSYS);
+ return -1;
+}
+libc_hidden_def (paccept)
+
+
+stub_warning (paccept)
+#include <stub-tag.h>
diff --git a/libc/socket/sys/socket.h b/libc/socket/sys/socket.h
index 6d9eab7f9..ea4123d28 100644
--- a/libc/socket/sys/socket.h
+++ b/libc/socket/sys/socket.h
@@ -1,5 +1,5 @@
/* Declarations of socket constants, types, and functions.
- Copyright (C) 1991,92,1994-2001,2003,2005,2007
+ Copyright (C) 1991,92,1994-2001,2003,2005,2007,2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -28,6 +28,10 @@ __BEGIN_DECLS
#include <sys/uio.h>
#define __need_size_t
#include <stddef.h>
+#ifdef __USE_GNU
+/* Get the __sigset_t definition. */
+# include <bits/sigset.h>
+#endif
/* This operating system-specific header file defines the SOCK_*, PF_*,
@@ -210,6 +214,18 @@ extern int listen (int __fd, int __n) __THROW;
extern int accept (int __fd, __SOCKADDR_ARG __addr,
socklen_t *__restrict __addr_len);
+#ifdef __USE_GNU
+/* Variant of the accept function which takes additional parameters. The
+ MASK parameter allows to change the thread signal mask for the duration
+ of the call. The FLAGS parameter allows to pass additional flags.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern int paccept (int __fd, __SOCKADDR_ARG __addr,
+ socklen_t *__restrict __addr_len,
+ __const __sigset_t *__restrict __ss, int __flags);
+#endif
+
/* Shut down all or part of the connection open on socket FD.
HOW determines what to shut down:
SHUT_RD = No more receptions;
diff --git a/libc/stdio-common/Makefile b/libc/stdio-common/Makefile
index d4525c33f..deeac91ce 100644
--- a/libc/stdio-common/Makefile
+++ b/libc/stdio-common/Makefile
@@ -1,4 +1,4 @@
-# Copyright (C) 1991-2006, 2007 Free Software Foundation, Inc.
+# Copyright (C) 1991-2006, 2007, 2008 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
@@ -65,7 +65,8 @@ tests := tstscanf test_rdwr test-popen tstgetln test-fseek \
tst-sprintf tst-rndseek tst-fdopen tst-fphex \
tst-popen tst-unlockedio tst-fmemopen2 tst-put-error tst-fgets \
tst-fwrite bug16 bug17 tst-sprintf2 bug18 \
- bug19 tst-popen2 scanf14 scanf15 bug21 bug22
+ bug19 tst-popen2 scanf14 scanf15 bug21 bug22 scanf16 scanf17 \
+ tst-setvbuf1
tests-$(OPTION_EGLIBC_LOCALE_CODE) \
+= tst-sscanf tst-swprintf bug15 test-vfprintf bug14 scanf13
tests-$(OPTION_POSIX_WIDE_CHAR_DEVICE_IO) \
@@ -123,11 +124,13 @@ CFLAGS-isoc99_scanf.c += $(exceptions)
CFLAGS-errlist.c = $(fno-unit-at-a-time)
CFLAGS-siglist.c = $(fno-unit-at-a-time)
-# The following is a hack since we must compile scanf15.c without any
+# The following is a hack since we must compile scanf1{5,7}.c without any
# GNU extension. The latter are needed, though, when internal headers
# are used. So made sure we see the installed headers first.
CFLAGS-scanf15.c = -I../libio -I../stdlib -I../wcsmbs -I../time -I../string \
-I../wctype
+CFLAGS-scanf17.c = -I../libio -I../stdlib -I../wcsmbs -I../time -I../string \
+ -I../wctype
# We know the test has a format string problem.
CFLAGS-tst-sprintf.c = -Wno-format
@@ -141,3 +144,7 @@ bug15-ENV = LOCPATH=$(common-objpfx)localedata
ifneq (,$(filter %REENTRANT, $(defines)))
CPPFLAGS += -D_IO_MTSAFE_IO
endif
+
+$(objpfx)tst-setvbuf1.out: tst-setvbuf1.expect $(objpfx)tst-setvbuf1
+ $(built-program-cmd) > $@ 2>&1
+ cmp tst-setvbuf1.expect $@
diff --git a/libc/stdio-common/_i18n_number.h b/libc/stdio-common/_i18n_number.h
index bd6adf80d..7fb29ae68 100644
--- a/libc/stdio-common/_i18n_number.h
+++ b/libc/stdio-common/_i18n_number.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2000, 2004 Free Software Foundation, Inc.
+/* Copyright (C) 2000, 2004, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@gnu.org>, 2000.
@@ -27,7 +27,7 @@
#if __OPTION_EGLIBC_LOCALE_CODE
static CHAR_T *
-_i18n_number_rewrite (CHAR_T *w, CHAR_T *rear_ptr)
+_i18n_number_rewrite (CHAR_T *w, CHAR_T *rear_ptr, CHAR_T *end)
{
#ifdef COMPILE_WPRINTF
# define decimal NULL
@@ -61,10 +61,23 @@ _i18n_number_rewrite (CHAR_T *w, CHAR_T *rear_ptr)
#endif
/* Copy existing string so that nothing gets overwritten. */
- CHAR_T *src = (CHAR_T *) alloca ((rear_ptr - w) * sizeof (CHAR_T));
+ CHAR_T *src;
+ bool use_alloca = __libc_use_alloca ((rear_ptr - w) * sizeof (CHAR_T));
+ if (__builtin_expect (use_alloca, true))
+ src = (CHAR_T *) alloca ((rear_ptr - w) * sizeof (CHAR_T));
+ else
+ {
+ src = (CHAR_T *) malloc ((rear_ptr - w) * sizeof (CHAR_T));
+ if (src == NULL)
+ /* If we cannot allocate the memory don't rewrite the string.
+ It is better than nothing. */
+ return w;
+ }
+
CHAR_T *s = (CHAR_T *) __mempcpy (src, w,
(rear_ptr - w) * sizeof (CHAR_T));
- w = rear_ptr;
+
+ w = end;
/* Process all characters in the string. */
while (--s >= src)
@@ -94,6 +107,9 @@ _i18n_number_rewrite (CHAR_T *w, CHAR_T *rear_ptr)
}
}
+ if (! use_alloca)
+ free (src);
+
return w;
}
diff --git a/libc/stdio-common/printf_fp.c b/libc/stdio-common/printf_fp.c
index f5a423b0b..83d5bdfdf 100644
--- a/libc/stdio-common/printf_fp.c
+++ b/libc/stdio-common/printf_fp.c
@@ -1,5 +1,5 @@
/* Floating point output for `printf'.
- Copyright (C) 1995-2003, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1995-2003, 2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
@@ -40,6 +40,8 @@
#include <stdlib.h>
#include <wchar.h>
#include <gnu/option-groups.h>
+#include <fpu_control.h> /* for getting the rounding mode */
+
#ifdef COMPILE_WPRINTF
# define CHAR_T wchar_t
@@ -965,15 +967,30 @@ ___printf_fp (FILE *fp,
}
}
+
+{ int roundmode;
+ wchar_t rounddigit;
+ _FPU_GETCW (roundmode);
+ roundmode &= _FPU_RC_NEAREST|_FPU_RC_DOWN|_FPU_RC_UP|_FPU_RC_ZERO;
+ switch (roundmode)
+ {
+ case _FPU_RC_NEAREST: rounddigit = L'4'; break;
+ case _FPU_RC_DOWN: rounddigit = is_neg ? L'0'-1: L'9'; break;
+ case _FPU_RC_UP: rounddigit = is_neg ? L'9': L'0'-1; break;
+ case _FPU_RC_ZERO: rounddigit = L'9'; break;
+ default: rounddigit = L'4'; break;
+ }
+
/* Do rounding. */
digit = hack_digit ();
- if (digit > L'4')
+ if (digit > rounddigit)
{
wchar_t *wtp = wcp;
- if (digit == L'5'
+ if (digit == (rounddigit + 1)
&& ((*(wcp - 1) != decimalwc && (*(wcp - 1) & 1) == 0)
- || ((*(wcp - 1) == decimalwc && (*(wcp - 2) & 1) == 0))))
+ || ((*(wcp - 1) == decimalwc && (*(wcp - 2) & 1) == 0))
+ || (roundmode == _FPU_RC_UP || roundmode == _FPU_RC_DOWN)))
{
/* This is the critical case. */
if (fracsize == 1 && frac[0] == 0)
@@ -1086,6 +1103,7 @@ ___printf_fp (FILE *fp,
}
}
}
+}
do_expo:
/* Now remove unnecessary '0' at the end of the string. */
@@ -1170,6 +1188,7 @@ ___printf_fp (FILE *fp,
{
char *buffer = NULL;
+ char *buffer_end = NULL;
char *cp = NULL;
char *tmpptr;
@@ -1179,6 +1198,9 @@ ___printf_fp (FILE *fp,
size_t decimal_len;
size_t thousands_sep_len;
wchar_t *copywc;
+ size_t factor = (info->i18n
+ ? _NL_CURRENT_WORD (LC_CTYPE, _NL_CTYPE_MB_CUR_MAX)
+ : 1);
decimal_len = strlen (decimal);
@@ -1187,10 +1209,11 @@ ___printf_fp (FILE *fp,
else
thousands_sep_len = strlen (thousands_sep);
+ size_t nbuffer = (2 + chars_needed * factor + decimal_len
+ + ngroups * thousands_sep_len);
if (__builtin_expect (buffer_malloced, 0))
{
- buffer = (char *) malloc (2 + chars_needed + decimal_len
- + ngroups * thousands_sep_len);
+ buffer = (char *) malloc (nbuffer);
if (buffer == NULL)
{
/* Signal an error to the caller. */
@@ -1199,8 +1222,8 @@ ___printf_fp (FILE *fp,
}
}
else
- buffer = (char *) alloca (2 + chars_needed + decimal_len
- + ngroups * thousands_sep_len);
+ buffer = (char *) alloca (nbuffer);
+ buffer_end = buffer + nbuffer;
/* Now copy the wide character string. Since the character
(except for the decimal point and thousands separator) must
@@ -1219,9 +1242,17 @@ ___printf_fp (FILE *fp,
if (__builtin_expect (info->i18n, 0))
{
#ifdef COMPILE_WPRINTF
- wstartp = _i18n_number_rewrite (wstartp, wcp);
+ wstartp = _i18n_number_rewrite (wstartp, wcp,
+ wbuffer + wbuffer_to_alloc);
+ wcp = wbuffer + wbuffer_to_alloc;
+ assert ((uintptr_t) wbuffer <= (uintptr_t) wstartp);
+ assert ((uintptr_t) wstartp
+ < (uintptr_t) wbuffer + wbuffer_to_alloc);
#else
- tmpptr = _i18n_number_rewrite (tmpptr, cp);
+ tmpptr = _i18n_number_rewrite (tmpptr, cp, buffer_end);
+ cp = buffer_end;
+ assert ((uintptr_t) buffer <= (uintptr_t) tmpptr);
+ assert ((uintptr_t) tmpptr < (uintptr_t) buffer_end);
#endif
}
diff --git a/libc/stdio-common/scanf14.c b/libc/stdio-common/scanf14.c
index b31505c0d..575b849b6 100644
--- a/libc/stdio-common/scanf14.c
+++ b/libc/stdio-common/scanf14.c
@@ -62,5 +62,58 @@ main (void)
else if (d != 5.25 || memcmp (c, " x", 2) != 0)
FAIL ();
+ const char *tmpdir = getenv ("TMPDIR");
+ if (tmpdir == NULL || tmpdir[0] == '\0')
+ tmpdir = "/tmp";
+
+ char fname[strlen (tmpdir) + sizeof "/tst-scanf14.XXXXXX"];
+ sprintf (fname, "%s/tst-scanf14.XXXXXX", tmpdir);
+ if (fname == NULL)
+ FAIL ();
+
+ /* Create a temporary file. */
+ int fd = mkstemp (fname);
+ if (fd == -1)
+ FAIL ();
+
+ FILE *fp = fdopen (fd, "w+");
+ if (fp == NULL)
+ FAIL ();
+ else
+ {
+ if (fputs (" 1.25s x", fp) == EOF)
+ FAIL ();
+ if (fseek (fp, 0, SEEK_SET) != 0)
+ FAIL ();
+ if (fscanf (fp, "%as%2c", &sp, c) != 2)
+ FAIL ();
+ else
+ {
+ if (strcmp (sp, "1.25s") != 0 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ memset (sp, 'x', sizeof "1.25s");
+ free (sp);
+ }
+
+ if (freopen (fname, "r", stdin) == NULL)
+ FAIL ();
+ else
+ {
+ if (scanf ("%as%2c", &sp, c) != 2)
+ FAIL ();
+ else
+ {
+ if (strcmp (sp, "1.25s") != 0 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ memset (sp, 'x', sizeof "1.25s");
+ free (sp);
+ }
+ }
+
+ fclose (fp);
+ }
+
+ remove (fname);
+
return result;
}
diff --git a/libc/stdio-common/scanf15.c b/libc/stdio-common/scanf15.c
index cc8aa2e6a..c56715c48 100644
--- a/libc/stdio-common/scanf15.c
+++ b/libc/stdio-common/scanf15.c
@@ -50,5 +50,48 @@ main (void)
else if (d != 5.25 || memcmp (c, " x", 2) != 0)
FAIL ();
+ const char *tmpdir = getenv ("TMPDIR");
+ if (tmpdir == NULL || tmpdir[0] == '\0')
+ tmpdir = "/tmp";
+
+ char fname[strlen (tmpdir) + sizeof "/tst-scanf15.XXXXXX"];
+ sprintf (fname, "%s/tst-scanf15.XXXXXX", tmpdir);
+ if (fname == NULL)
+ FAIL ();
+
+ /* Create a temporary file. */
+ int fd = mkstemp (fname);
+ if (fd == -1)
+ FAIL ();
+
+ FILE *fp = fdopen (fd, "w+");
+ if (fp == NULL)
+ FAIL ();
+ else
+ {
+ if (fputs (" 1.25s x", fp) == EOF)
+ FAIL ();
+ if (fseek (fp, 0, SEEK_SET) != 0)
+ FAIL ();
+ if (fscanf (fp, "%as%2c", &f, c) != 2)
+ FAIL ();
+ else if (f != 1.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+
+ if (freopen (fname, "r", stdin) == NULL)
+ FAIL ();
+ else
+ {
+ if (scanf ("%as%2c", &f, c) != 2)
+ FAIL ();
+ else if (f != 1.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ }
+
+ fclose (fp);
+ }
+
+ remove (fname);
+
return result;
}
diff --git a/libc/stdio-common/scanf16.c b/libc/stdio-common/scanf16.c
new file mode 100644
index 000000000..3e3cb417f
--- /dev/null
+++ b/libc/stdio-common/scanf16.c
@@ -0,0 +1,147 @@
+#include <stdarg.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <wchar.h>
+
+#define FAIL() \
+ do { \
+ result = 1; \
+ printf ("test at line %d failed\n", __LINE__); \
+ } while (0)
+
+static int
+xsscanf (const char *str, const char *fmt, ...)
+{
+ va_list ap;
+ va_start (ap, fmt);
+ int ret = vsscanf (str, fmt, ap);
+ va_end (ap);
+ return ret;
+}
+
+static int
+xscanf (const char *fmt, ...)
+{
+ va_list ap;
+ va_start (ap, fmt);
+ int ret = vscanf (fmt, ap);
+ va_end (ap);
+ return ret;
+}
+
+static int
+xfscanf (FILE *f, const char *fmt, ...)
+{
+ va_list ap;
+ va_start (ap, fmt);
+ int ret = vfscanf (f, fmt, ap);
+ va_end (ap);
+ return ret;
+}
+
+int
+main (void)
+{
+ wchar_t *lsp;
+ char *sp;
+ float f;
+ double d;
+ char c[8];
+ int result = 0;
+
+ if (xsscanf (" 0.25s x", "%e%3c", &f, c) != 2)
+ FAIL ();
+ else if (f != 0.25 || memcmp (c, "s x", 3) != 0)
+ FAIL ();
+ if (xsscanf (" 1.25s x", "%as%2c", &sp, c) != 2)
+ FAIL ();
+ else
+ {
+ if (strcmp (sp, "1.25s") != 0 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ memset (sp, 'x', sizeof "1.25s");
+ free (sp);
+ }
+ if (xsscanf (" 2.25s x", "%las%2c", &d, c) != 2)
+ FAIL ();
+ else if (d != 2.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ if (xsscanf (" 3.25S x", "%4aS%3c", &lsp, c) != 2)
+ FAIL ();
+ else
+ {
+ if (wcscmp (lsp, L"3.25") != 0 || memcmp (c, "S x", 3) != 0)
+ FAIL ();
+ memset (lsp, 'x', sizeof L"3.25");
+ free (lsp);
+ }
+ if (xsscanf ("4.25[0-9.] x", "%a[0-9.]%8c", &sp, c) != 2)
+ FAIL ();
+ else
+ {
+ if (strcmp (sp, "4.25") != 0 || memcmp (c, "[0-9.] x", 8) != 0)
+ FAIL ();
+ memset (sp, 'x', sizeof "4.25");
+ free (sp);
+ }
+ if (xsscanf ("5.25[0-9.] x", "%la[0-9.]%2c", &d, c) != 2)
+ FAIL ();
+ else if (d != 5.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+
+ const char *tmpdir = getenv ("TMPDIR");
+ if (tmpdir == NULL || tmpdir[0] == '\0')
+ tmpdir = "/tmp";
+
+ char fname[strlen (tmpdir) + sizeof "/tst-scanf16.XXXXXX"];
+ sprintf (fname, "%s/tst-scanf16.XXXXXX", tmpdir);
+ if (fname == NULL)
+ FAIL ();
+
+ /* Create a temporary file. */
+ int fd = mkstemp (fname);
+ if (fd == -1)
+ FAIL ();
+
+ FILE *fp = fdopen (fd, "w+");
+ if (fp == NULL)
+ FAIL ();
+ else
+ {
+ if (fputs (" 1.25s x", fp) == EOF)
+ FAIL ();
+ if (fseek (fp, 0, SEEK_SET) != 0)
+ FAIL ();
+ if (xfscanf (fp, "%as%2c", &sp, c) != 2)
+ FAIL ();
+ else
+ {
+ if (strcmp (sp, "1.25s") != 0 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ memset (sp, 'x', sizeof "1.25s");
+ free (sp);
+ }
+
+ if (freopen (fname, "r", stdin) == NULL)
+ FAIL ();
+ else
+ {
+ if (xscanf ("%as%2c", &sp, c) != 2)
+ FAIL ();
+ else
+ {
+ if (strcmp (sp, "1.25s") != 0 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ memset (sp, 'x', sizeof "1.25s");
+ free (sp);
+ }
+ }
+
+ fclose (fp);
+ }
+
+ remove (fname);
+
+ return result;
+}
diff --git a/libc/stdio-common/scanf17.c b/libc/stdio-common/scanf17.c
new file mode 100644
index 000000000..ee9024f9b
--- /dev/null
+++ b/libc/stdio-common/scanf17.c
@@ -0,0 +1,128 @@
+#undef _GNU_SOURCE
+#define _XOPEN_SOURCE 600
+/* The following macro definitions are a hack. They word around disabling
+ the GNU extension while still using a few internal headers. */
+#define u_char unsigned char
+#define u_short unsigned short
+#define u_int unsigned int
+#define u_long unsigned long
+#include <stdarg.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <wchar.h>
+
+#define FAIL() \
+ do { \
+ result = 1; \
+ printf ("test at line %d failed\n", __LINE__); \
+ } while (0)
+
+static int
+xsscanf (const char *str, const char *fmt, ...)
+{
+ va_list ap;
+ va_start (ap, fmt);
+ int ret = vsscanf (str, fmt, ap);
+ va_end (ap);
+ return ret;
+}
+
+static int
+xscanf (const char *fmt, ...)
+{
+ va_list ap;
+ va_start (ap, fmt);
+ int ret = vscanf (fmt, ap);
+ va_end (ap);
+ return ret;
+}
+
+static int
+xfscanf (FILE *f, const char *fmt, ...)
+{
+ va_list ap;
+ va_start (ap, fmt);
+ int ret = vfscanf (f, fmt, ap);
+ va_end (ap);
+ return ret;
+}
+
+int
+main (void)
+{
+ float f;
+ double d;
+ char c[8];
+ int result = 0;
+
+ if (xsscanf (" 0.25s x", "%e%3c", &f, c) != 2)
+ FAIL ();
+ else if (f != 0.25 || memcmp (c, "s x", 3) != 0)
+ FAIL ();
+ if (xsscanf (" 1.25s x", "%as%2c", &f, c) != 2)
+ FAIL ();
+ else if (f != 1.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ if (xsscanf (" 2.25s x", "%las%2c", &d, c) != 2)
+ FAIL ();
+ else if (d != 2.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ if (xsscanf (" 3.25S x", "%4aS%2c", &f, c) != 2)
+ FAIL ();
+ else if (f != 3.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ if (xsscanf (" 4.25[0-9.] x", "%a[0-9.]%2c", &f, c) != 2)
+ FAIL ();
+ else if (f != 4.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ if (xsscanf (" 5.25[0-9.] x", "%la[0-9.]%2c", &d, c) != 2)
+ FAIL ();
+ else if (d != 5.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+
+ const char *tmpdir = getenv ("TMPDIR");
+ if (tmpdir == NULL || tmpdir[0] == '\0')
+ tmpdir = "/tmp";
+
+ char fname[strlen (tmpdir) + sizeof "/tst-scanf17.XXXXXX"];
+ sprintf (fname, "%s/tst-scanf17.XXXXXX", tmpdir);
+ if (fname == NULL)
+ FAIL ();
+
+ /* Create a temporary file. */
+ int fd = mkstemp (fname);
+ if (fd == -1)
+ FAIL ();
+
+ FILE *fp = fdopen (fd, "w+");
+ if (fp == NULL)
+ FAIL ();
+ else
+ {
+ if (fputs (" 1.25s x", fp) == EOF)
+ FAIL ();
+ if (fseek (fp, 0, SEEK_SET) != 0)
+ FAIL ();
+ if (xfscanf (fp, "%as%2c", &f, c) != 2)
+ FAIL ();
+ else if (f != 1.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+
+ if (freopen (fname, "r", stdin) == NULL)
+ FAIL ();
+ else
+ {
+ if (xscanf ("%as%2c", &f, c) != 2)
+ FAIL ();
+ else if (f != 1.25 || memcmp (c, " x", 2) != 0)
+ FAIL ();
+ }
+
+ fclose (fp);
+ }
+
+ remove (fname);
+
+ return result;
+}
diff --git a/libc/stdio-common/tst-setvbuf1.c b/libc/stdio-common/tst-setvbuf1.c
new file mode 100644
index 000000000..22410939c
--- /dev/null
+++ b/libc/stdio-common/tst-setvbuf1.c
@@ -0,0 +1,19 @@
+#include <stdio.h>
+
+static int
+do_test (void)
+{
+ if (setvbuf (stderr, NULL, _IOFBF, BUFSIZ) != 0)
+ {
+ puts ("Set full buffer error.");
+ return 1;
+ }
+
+ fprintf (stderr, "Output #1 <stderr>.\n");
+ printf ("Output #2 <stdout>.\n");
+
+ return 0;
+}
+
+#define TEST_FUNCTION do_test ()
+#include "../test-skeleton.c"
diff --git a/libc/stdio-common/tst-setvbuf1.expect b/libc/stdio-common/tst-setvbuf1.expect
new file mode 100644
index 000000000..281c18ca1
--- /dev/null
+++ b/libc/stdio-common/tst-setvbuf1.expect
@@ -0,0 +1,2 @@
+Output #2 <stdout>.
+Output #1 <stderr>.
diff --git a/libc/stdio-common/vfprintf.c b/libc/stdio-common/vfprintf.c
index be91bc002..56352f152 100644
--- a/libc/stdio-common/vfprintf.c
+++ b/libc/stdio-common/vfprintf.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991-2002, 2003, 2004, 2005, 2006, 2007
+/* Copyright (C) 1991-2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -711,7 +711,7 @@ IFDEF__STDC_DEC_FP__(, \
thousands_sep); \
\
if (use_outdigits && base == 10) \
- string = _i18n_number_rewrite (string, workend); \
+ string = _i18n_number_rewrite (string, workend, workend); \
} \
/* Simplify further test for num != 0. */ \
number.word = number.longlong != 0; \
@@ -769,7 +769,7 @@ IFDEF__STDC_DEC_FP__(, \
thousands_sep); \
\
if (use_outdigits && base == 10) \
- string = _i18n_number_rewrite (string, workend); \
+ string = _i18n_number_rewrite (string, workend, workend); \
} \
} \
\
@@ -2248,6 +2248,11 @@ _IO_helper_overflow (_IO_FILE *s, int c)
{
_IO_size_t written = _IO_sputn (target, s->_wide_data->_IO_write_base,
used);
+ if (written == 0 || written == WEOF)
+ return WEOF;
+ __wmemmove (s->_wide_data->_IO_write_base,
+ s->_wide_data->_IO_write_base + written,
+ used - written);
s->_wide_data->_IO_write_ptr -= written;
}
#else
@@ -2255,6 +2260,10 @@ _IO_helper_overflow (_IO_FILE *s, int c)
if (used)
{
_IO_size_t written = _IO_sputn (target, s->_IO_write_base, used);
+ if (written == 0 || written == EOF)
+ return EOF;
+ memmove (s->_IO_write_base, s->_IO_write_base + written,
+ used - written);
s->_IO_write_ptr -= written;
}
#endif
diff --git a/libc/stdlib/canonicalize.c b/libc/stdlib/canonicalize.c
index 19808b50d..67e4d0553 100644
--- a/libc/stdlib/canonicalize.c
+++ b/libc/stdlib/canonicalize.c
@@ -1,5 +1,5 @@
/* Return the canonical absolute name of a given file.
- Copyright (C) 1996-2002, 2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1996-2002,2004,2005,2006,2008 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
@@ -173,7 +173,7 @@ __realpath (const char *name, char *resolved)
goto error;
}
- n = __readlink (rpath, buf, path_max);
+ n = __readlink (rpath, buf, path_max - 1);
if (n < 0)
goto error;
buf[n] = '\0';
diff --git a/libc/stdlib/mbtowc.c b/libc/stdlib/mbtowc.c
index 744b2b6c0..ee8850bbc 100644
--- a/libc/stdlib/mbtowc.c
+++ b/libc/stdlib/mbtowc.c
@@ -1,4 +1,5 @@
-/* Copyright (C) 1991, 1992, 1995-1999, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1991, 1992, 1995-1999, 2002, 2008
+ 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
@@ -23,9 +24,6 @@
#include <wcsmbs/wcsmbsload.h>
-/* Common state for all non-restartable conversion functions. */
-mbstate_t __no_r_state attribute_hidden;
-
/* Convert the multibyte character at S, which is no longer
than N characters, to its `wchar_t' representation, placing
this n *PWC and returning its length.
@@ -38,6 +36,7 @@ int
mbtowc (wchar_t *pwc, const char *s, size_t n)
{
int result;
+ static mbstate_t state;
/* If S is NULL the function has to return null or not null
depending on the encoding having a state depending encoding or
@@ -51,7 +50,7 @@ mbtowc (wchar_t *pwc, const char *s, size_t n)
/* This is an extension in the Unix standard which does not directly
violate ISO C. */
- memset (&__no_r_state, '\0', sizeof __no_r_state);
+ memset (&state, '\0', sizeof state);
result = fcts->towc->__stateful;
}
@@ -63,7 +62,7 @@ mbtowc (wchar_t *pwc, const char *s, size_t n)
}
else
{
- result = __mbrtowc (pwc, s, n, &__no_r_state);
+ result = __mbrtowc (pwc, s, n, &state);
/* The `mbrtowc' functions tell us more than we need. Fold the -1
and -2 result into -1. */
diff --git a/libc/stdlib/tst-makecontext.c b/libc/stdlib/tst-makecontext.c
index 1451efa56..00f8f1990 100644
--- a/libc/stdlib/tst-makecontext.c
+++ b/libc/stdlib/tst-makecontext.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2006, 2007, 2008 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
@@ -25,10 +25,13 @@ ucontext_t ucp;
char st1[8192];
__thread int thr;
+int somevar = -76;
+long othervar = -78L;
+
void
cf (int i)
{
- if (i != 78 || thr != 94)
+ if (i != othervar || thr != 94)
{
printf ("i %d thr %d\n", i, thr);
exit (1);
@@ -54,7 +57,7 @@ do_test (void)
ucp.uc_link = NULL;
ucp.uc_stack.ss_sp = st1;
ucp.uc_stack.ss_size = sizeof st1;
- makecontext (&ucp, (void (*) (void)) cf, 1, 78);
+ makecontext (&ucp, (void (*) (void)) cf, 1, somevar - 2);
if (setcontext (&ucp) != 0)
{
puts ("setcontext failed");
diff --git a/libc/stdlib/tst-setcontext.c b/libc/stdlib/tst-setcontext.c
index 28bf23026..51296f74a 100644
--- a/libc/stdlib/tst-setcontext.c
+++ b/libc/stdlib/tst-setcontext.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2001,2002,2004,2006 Free Software Foundation, Inc.
+/* Copyright (C) 2001,2002,2004,2006,2007,2008 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
@@ -21,6 +21,7 @@
#include <stdlib.h>
#include <string.h>
#include <ucontext.h>
+#include <unistd.h>
static ucontext_t ctx[3];
@@ -149,7 +150,10 @@ main (void)
if (getcontext (&ctx[1]) != 0)
{
if (errno == ENOSYS)
- exit (0);
+ {
+ back_in_main = 1;
+ exit (0);
+ }
printf ("%s: getcontext: %m\n", __FUNCTION__);
exit (1);
diff --git a/libc/stdlib/wctomb.c b/libc/stdlib/wctomb.c
index 49872f5c6..3ba8a3e2a 100644
--- a/libc/stdlib/wctomb.c
+++ b/libc/stdlib/wctomb.c
@@ -1,4 +1,5 @@
-/* Copyright (C) 1991, 1992, 1995-1999, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1991, 1992, 1995-1999, 2002, 2008
+ 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
@@ -23,7 +24,8 @@
#include <wcsmbs/wcsmbsload.h>
-extern mbstate_t __no_r_state attribute_hidden; /* Defined in mbtowc.c. */
+/* Shared with __wctomb_chk. */
+mbstate_t __wctomb_state attribute_hidden;
/* Convert WCHAR into its multibyte character representation,
putting this in S and returning its length.
@@ -47,11 +49,11 @@ wctomb (char *s, wchar_t wchar)
/* This is an extension in the Unix standard which does not directly
violate ISO C. */
- memset (&__no_r_state, '\0', sizeof __no_r_state);
+ memset (&__wctomb_state, '\0', sizeof __wctomb_state);
return fcts->tomb->__stateful;
}
- return __wcrtomb (s, wchar, &__no_r_state);
+ return __wcrtomb (s, wchar, &__wctomb_state);
}
libc_hidden_def (wctomb)
diff --git a/libc/string/Makefile b/libc/string/Makefile
index 18a5d5b2c..36325e7ae 100644
--- a/libc/string/Makefile
+++ b/libc/string/Makefile
@@ -1,4 +1,4 @@
-# Copyright (C) 1991-2002, 2005, 2006, 2007 Free Software Foundation, Inc.
+# Copyright (C) 1991-2002, 2005-2007, 2008 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
@@ -52,17 +52,18 @@ o-objects.ob := memcpy.o memset.o memchr.o
strop-tests := memchr memcmp memcpy memmove mempcpy memset memccpy \
stpcpy stpncpy strcat strchr strcmp strcpy strcspn \
- strlen strncmp strncpy strpbrk strrchr strspn
+ strlen strncmp strncpy strpbrk strrchr strspn memmem
tests := tester inl-tester noinl-tester testcopy test-ffs \
tst-strlen stratcliff tst-svc tst-inlcall \
bug-strncat1 bug-strspn1 bug-strpbrk1 tst-bswap \
tst-strtok tst-strfry \
bug-strtok1 $(addprefix test-,$(strop-tests)) \
- tst-strxfrm2
+ tst-strxfrm2 tst-endian
tests-$(OPTION_EGLIBC_ENVZ) += bug-envz1
tests-$(OPTION_EGLIBC_LOCALE_CODE) \
+= tst-strxfrm bug-strcoll1
-distribute := memcopy.h pagecopy.h tst-svc.expect test-string.h
+distribute := memcopy.h pagecopy.h tst-svc.expect test-string.h \
+ str-two-way.h
include ../Rules
diff --git a/libc/string/endian.h b/libc/string/endian.h
index 2f7bce100..37d030a25 100644
--- a/libc/string/endian.h
+++ b/libc/string/endian.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992, 1996, 1997, 2000 Free Software Foundation, Inc.
+/* Copyright (C) 1992, 1996, 1997, 2000, 2008 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
@@ -55,4 +55,42 @@
# define __LONG_LONG_PAIR(HI, LO) HI, LO
#endif
+
+#ifdef __USE_BSD
+/* Conversion interfaces. */
+# include <bits/byteswap.h>
+
+# if __BYTE_ORDER == __LITTLE_ENDIAN
+# define htobe16(x) __bswap_16 (x)
+# define htole16(x) (x)
+# define be16toh(x) __bswap_16 (x)
+# define le16toh(x) (x)
+
+# define htobe32(x) __bswap_32 (x)
+# define htole32(x) (x)
+# define be32toh(x) __bswap_32 (x)
+# define le32toh(x) (x)
+
+# define htobe64(x) __bswap_64 (x)
+# define htole64(x) (x)
+# define be64toh(x) __bswap_64 (x)
+# define le64toh(x) (x)
+# else
+# define htobe16(x) (x)
+# define htole16(x) __bswap_16 (x)
+# define be16toh(x) (x)
+# define le16toh(x) __bswap_16 (x)
+
+# define htobe32(x) (x)
+# define htole32(x) __bswap_32 (x)
+# define be32toh(x) (x)
+# define le32toh(x) __bswap_32 (x)
+
+# define htobe64(x) (x)
+# define htole64(x) __bswap_64 (x)
+# define be64toh(x) (x)
+# define le64toh(x) __bswap_64 (x)
+# endif
+#endif
+
#endif /* endian.h */
diff --git a/libc/string/memmem.c b/libc/string/memmem.c
index c40462104..3176ab775 100644
--- a/libc/string/memmem.c
+++ b/libc/string/memmem.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991,92,93,94,96,97,98,2000,2004 Free Software Foundation, Inc.
+/* Copyright (C) 1991,92,93,94,96,97,98,2000,2004,2008 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,26 +16,36 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#include <stddef.h>
+/* This particular implementation was written by Eric Blake, 2008. */
+
+#ifndef _LIBC
+# include <config.h>
+#endif
+
+/* Specification of memmem. */
#include <string.h>
#ifndef _LIBC
# define __builtin_expect(expr, val) (expr)
#endif
+#define RETURN_TYPE void *
+#define AVAILABLE(h, h_l, j, n_l) ((j) <= (h_l) - (n_l))
+#include "str-two-way.h"
+
#undef memmem
-/* Return the first occurrence of NEEDLE in HAYSTACK. */
+/* Return the first occurrence of NEEDLE in HAYSTACK. Return HAYSTACK
+ if NEEDLE_LEN is 0, otherwise NULL if NEEDLE is not found in
+ HAYSTACK. */
void *
-memmem (haystack, haystack_len, needle, needle_len)
- const void *haystack;
- size_t haystack_len;
- const void *needle;
- size_t needle_len;
+memmem (const void *haystack_start, size_t haystack_len,
+ const void *needle_start, size_t needle_len)
{
- const char *begin;
- const char *const last_possible
- = (const char *) haystack + haystack_len - needle_len;
+ /* Abstract memory is considered to be an array of 'unsigned char' values,
+ not an array of 'char' values. See ISO C 99 section 6.2.6.1. */
+ const unsigned char *haystack = (const unsigned char *) haystack_start;
+ const unsigned char *needle = (const unsigned char *) needle_start;
if (needle_len == 0)
/* The first occurrence of the empty string is deemed to occur at
@@ -47,12 +57,22 @@ memmem (haystack, haystack_len, needle, needle_len)
if (__builtin_expect (haystack_len < needle_len, 0))
return NULL;
- for (begin = (const char *) haystack; begin <= last_possible; ++begin)
- if (begin[0] == ((const char *) needle)[0] &&
- !memcmp ((const void *) &begin[1],
- (const void *) ((const char *) needle + 1),
- needle_len - 1))
- return (void *) begin;
-
- return NULL;
+ /* Use optimizations in memchr when possible, to reduce the search
+ size of haystack using a linear algorithm with a smaller
+ coefficient. However, avoid memchr for long needles, since we
+ can often achieve sublinear performance. */
+ if (needle_len < LONG_NEEDLE_THRESHOLD)
+ {
+ haystack = memchr (haystack, *needle, haystack_len);
+ if (!haystack || __builtin_expect (needle_len == 1, 0))
+ return (void *) haystack;
+ haystack_len -= haystack - (const unsigned char *) haystack_start;
+ if (haystack_len < needle_len)
+ return NULL;
+ return two_way_short_needle (haystack, haystack_len, needle, needle_len);
+ }
+ else
+ return two_way_long_needle (haystack, haystack_len, needle, needle_len);
}
+
+#undef LONG_NEEDLE_THRESHOLD
diff --git a/libc/string/str-two-way.h b/libc/string/str-two-way.h
new file mode 100644
index 000000000..87ed8a036
--- /dev/null
+++ b/libc/string/str-two-way.h
@@ -0,0 +1,430 @@
+/* Byte-wise substring search, using the Two-Way algorithm.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Written by Eric Blake <ebb9@byu.net>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+/* Before including this file, you need to include <string.h> (and
+ <config.h> before that, if not part of libc), and define:
+ RESULT_TYPE A macro that expands to the return type.
+ AVAILABLE(h, h_l, j, n_l)
+ A macro that returns nonzero if there are
+ at least N_L bytes left starting at H[J].
+ H is 'unsigned char *', H_L, J, and N_L
+ are 'size_t'; H_L is an lvalue. For
+ NUL-terminated searches, H_L can be
+ modified each iteration to avoid having
+ to compute the end of H up front.
+
+ For case-insensitivity, you may optionally define:
+ CMP_FUNC(p1, p2, l) A macro that returns 0 iff the first L
+ characters of P1 and P2 are equal.
+ CANON_ELEMENT(c) A macro that canonicalizes an element right after
+ it has been fetched from one of the two strings.
+ The argument is an 'unsigned char'; the result
+ must be an 'unsigned char' as well.
+
+ This file undefines the macros documented above, and defines
+ LONG_NEEDLE_THRESHOLD.
+*/
+
+#include <limits.h>
+#include <stdint.h>
+
+/* We use the Two-Way string matching algorithm, which guarantees
+ linear complexity with constant space. Additionally, for long
+ needles, we also use a bad character shift table similar to the
+ Boyer-Moore algorithm to achieve improved (potentially sub-linear)
+ performance.
+
+ See http://www-igm.univ-mlv.fr/~lecroq/string/node26.html#SECTION00260
+ and http://en.wikipedia.org/wiki/Boyer-Moore_string_search_algorithm
+*/
+
+/* Point at which computing a bad-byte shift table is likely to be
+ worthwhile. Small needles should not compute a table, since it
+ adds (1 << CHAR_BIT) + NEEDLE_LEN computations of preparation for a
+ speedup no greater than a factor of NEEDLE_LEN. The larger the
+ needle, the better the potential performance gain. On the other
+ hand, on non-POSIX systems with CHAR_BIT larger than eight, the
+ memory required for the table is prohibitive. */
+#if CHAR_BIT < 10
+# define LONG_NEEDLE_THRESHOLD 32U
+#else
+# define LONG_NEEDLE_THRESHOLD SIZE_MAX
+#endif
+
+#ifndef MAX
+# define MAX(a, b) ((a < b) ? (b) : (a))
+#endif
+
+#ifndef CANON_ELEMENT
+# define CANON_ELEMENT(c) c
+#endif
+#ifndef CMP_FUNC
+# define CMP_FUNC memcmp
+#endif
+
+/* Perform a critical factorization of NEEDLE, of length NEEDLE_LEN.
+ Return the index of the first byte in the right half, and set
+ *PERIOD to the global period of the right half.
+
+ The global period of a string is the smallest index (possibly its
+ length) at which all remaining bytes in the string are repetitions
+ of the prefix (the last repetition may be a subset of the prefix).
+
+ When NEEDLE is factored into two halves, a local period is the
+ length of the smallest word that shares a suffix with the left half
+ and shares a prefix with the right half. All factorizations of a
+ non-empty NEEDLE have a local period of at least 1 and no greater
+ than NEEDLE_LEN.
+
+ A critical factorization has the property that the local period
+ equals the global period. All strings have at least one critical
+ factorization with the left half smaller than the global period.
+
+ Given an ordered alphabet, a critical factorization can be computed
+ in linear time, with 2 * NEEDLE_LEN comparisons, by computing the
+ larger of two ordered maximal suffixes. The ordered maximal
+ suffixes are determined by lexicographic comparison of
+ periodicity. */
+static size_t
+critical_factorization (const unsigned char *needle, size_t needle_len,
+ size_t *period)
+{
+ /* Index of last byte of left half, or SIZE_MAX. */
+ size_t max_suffix, max_suffix_rev;
+ size_t j; /* Index into NEEDLE for current candidate suffix. */
+ size_t k; /* Offset into current period. */
+ size_t p; /* Intermediate period. */
+ unsigned char a, b; /* Current comparison bytes. */
+
+ /* Invariants:
+ 0 <= j < NEEDLE_LEN - 1
+ -1 <= max_suffix{,_rev} < j (treating SIZE_MAX as if it were signed)
+ min(max_suffix, max_suffix_rev) < global period of NEEDLE
+ 1 <= p <= global period of NEEDLE
+ p == global period of the substring NEEDLE[max_suffix{,_rev}+1...j]
+ 1 <= k <= p
+ */
+
+ /* Perform lexicographic search. */
+ max_suffix = SIZE_MAX;
+ j = 0;
+ k = p = 1;
+ while (j + k < needle_len)
+ {
+ a = CANON_ELEMENT (needle[j + k]);
+ b = CANON_ELEMENT (needle[max_suffix + k]);
+ if (a < b)
+ {
+ /* Suffix is smaller, period is entire prefix so far. */
+ j += k;
+ k = 1;
+ p = j - max_suffix;
+ }
+ else if (a == b)
+ {
+ /* Advance through repetition of the current period. */
+ if (k != p)
+ ++k;
+ else
+ {
+ j += p;
+ k = 1;
+ }
+ }
+ else /* b < a */
+ {
+ /* Suffix is larger, start over from current location. */
+ max_suffix = j++;
+ k = p = 1;
+ }
+ }
+ *period = p;
+
+ /* Perform reverse lexicographic search. */
+ max_suffix_rev = SIZE_MAX;
+ j = 0;
+ k = p = 1;
+ while (j + k < needle_len)
+ {
+ a = CANON_ELEMENT (needle[j + k]);
+ b = CANON_ELEMENT (needle[max_suffix_rev + k]);
+ if (b < a)
+ {
+ /* Suffix is smaller, period is entire prefix so far. */
+ j += k;
+ k = 1;
+ p = j - max_suffix_rev;
+ }
+ else if (a == b)
+ {
+ /* Advance through repetition of the current period. */
+ if (k != p)
+ ++k;
+ else
+ {
+ j += p;
+ k = 1;
+ }
+ }
+ else /* a < b */
+ {
+ /* Suffix is larger, start over from current location. */
+ max_suffix_rev = j++;
+ k = p = 1;
+ }
+ }
+
+ /* Choose the longer suffix. Return the first byte of the right
+ half, rather than the last byte of the left half. */
+ if (max_suffix_rev + 1 < max_suffix + 1)
+ return max_suffix + 1;
+ *period = p;
+ return max_suffix_rev + 1;
+}
+
+/* Return the first location of non-empty NEEDLE within HAYSTACK, or
+ NULL. HAYSTACK_LEN is the minimum known length of HAYSTACK. This
+ method is optimized for NEEDLE_LEN < LONG_NEEDLE_THRESHOLD.
+ Performance is guaranteed to be linear, with an initialization cost
+ of 2 * NEEDLE_LEN comparisons.
+
+ If AVAILABLE does not modify HAYSTACK_LEN (as in memmem), then at
+ most 2 * HAYSTACK_LEN - NEEDLE_LEN comparisons occur in searching.
+ If AVAILABLE modifies HAYSTACK_LEN (as in strstr), then at most 3 *
+ HAYSTACK_LEN - NEEDLE_LEN comparisons occur in searching. */
+static RETURN_TYPE
+two_way_short_needle (const unsigned char *haystack, size_t haystack_len,
+ const unsigned char *needle, size_t needle_len)
+{
+ size_t i; /* Index into current byte of NEEDLE. */
+ size_t j; /* Index into current window of HAYSTACK. */
+ size_t period; /* The period of the right half of needle. */
+ size_t suffix; /* The index of the right half of needle. */
+
+ /* Factor the needle into two halves, such that the left half is
+ smaller than the global period, and the right half is
+ periodic (with a period as large as NEEDLE_LEN - suffix). */
+ suffix = critical_factorization (needle, needle_len, &period);
+
+ /* Perform the search. Each iteration compares the right half
+ first. */
+ if (CMP_FUNC (needle, needle + period, suffix) == 0)
+ {
+ /* Entire needle is periodic; a mismatch can only advance by the
+ period, so use memory to avoid rescanning known occurrences
+ of the period. */
+ size_t memory = 0;
+ j = 0;
+ while (AVAILABLE (haystack, haystack_len, j, needle_len))
+ {
+ /* Scan for matches in right half. */
+ i = MAX (suffix, memory);
+ while (i < needle_len && (CANON_ELEMENT (needle[i])
+ == CANON_ELEMENT (haystack[i + j])))
+ ++i;
+ if (needle_len <= i)
+ {
+ /* Scan for matches in left half. */
+ i = suffix - 1;
+ while (memory < i + 1 && (CANON_ELEMENT (needle[i])
+ == CANON_ELEMENT (haystack[i + j])))
+ --i;
+ if (i + 1 < memory + 1)
+ return (RETURN_TYPE) (haystack + j);
+ /* No match, so remember how many repetitions of period
+ on the right half were scanned. */
+ j += period;
+ memory = needle_len - period;
+ }
+ else
+ {
+ j += i - suffix + 1;
+ memory = 0;
+ }
+ }
+ }
+ else
+ {
+ /* The two halves of needle are distinct; no extra memory is
+ required, and any mismatch results in a maximal shift. */
+ period = MAX (suffix, needle_len - suffix) + 1;
+ j = 0;
+ while (AVAILABLE (haystack, haystack_len, j, needle_len))
+ {
+ /* Scan for matches in right half. */
+ i = suffix;
+ while (i < needle_len && (CANON_ELEMENT (needle[i])
+ == CANON_ELEMENT (haystack[i + j])))
+ ++i;
+ if (needle_len <= i)
+ {
+ /* Scan for matches in left half. */
+ i = suffix - 1;
+ while (i != SIZE_MAX && (CANON_ELEMENT (needle[i])
+ == CANON_ELEMENT (haystack[i + j])))
+ --i;
+ if (i == SIZE_MAX)
+ return (RETURN_TYPE) (haystack + j);
+ j += period;
+ }
+ else
+ j += i - suffix + 1;
+ }
+ }
+ return NULL;
+}
+
+/* Return the first location of non-empty NEEDLE within HAYSTACK, or
+ NULL. HAYSTACK_LEN is the minimum known length of HAYSTACK. This
+ method is optimized for LONG_NEEDLE_THRESHOLD <= NEEDLE_LEN.
+ Performance is guaranteed to be linear, with an initialization cost
+ of 3 * NEEDLE_LEN + (1 << CHAR_BIT) operations.
+
+ If AVAILABLE does not modify HAYSTACK_LEN (as in memmem), then at
+ most 2 * HAYSTACK_LEN - NEEDLE_LEN comparisons occur in searching,
+ and sublinear performance O(HAYSTACK_LEN / NEEDLE_LEN) is possible.
+ If AVAILABLE modifies HAYSTACK_LEN (as in strstr), then at most 3 *
+ HAYSTACK_LEN - NEEDLE_LEN comparisons occur in searching, and
+ sublinear performance is not possible. */
+static RETURN_TYPE
+two_way_long_needle (const unsigned char *haystack, size_t haystack_len,
+ const unsigned char *needle, size_t needle_len)
+{
+ size_t i; /* Index into current byte of NEEDLE. */
+ size_t j; /* Index into current window of HAYSTACK. */
+ size_t period; /* The period of the right half of needle. */
+ size_t suffix; /* The index of the right half of needle. */
+ size_t shift_table[1U << CHAR_BIT]; /* See below. */
+
+ /* Factor the needle into two halves, such that the left half is
+ smaller than the global period, and the right half is
+ periodic (with a period as large as NEEDLE_LEN - suffix). */
+ suffix = critical_factorization (needle, needle_len, &period);
+
+ /* Populate shift_table. For each possible byte value c,
+ shift_table[c] is the distance from the last occurrence of c to
+ the end of NEEDLE, or NEEDLE_LEN if c is absent from the NEEDLE.
+ shift_table[NEEDLE[NEEDLE_LEN - 1]] contains the only 0. */
+ for (i = 0; i < 1U << CHAR_BIT; i++)
+ shift_table[i] = needle_len;
+ for (i = 0; i < needle_len; i++)
+ shift_table[CANON_ELEMENT (needle[i])] = needle_len - i - 1;
+
+ /* Perform the search. Each iteration compares the right half
+ first. */
+ if (CMP_FUNC (needle, needle + period, suffix) == 0)
+ {
+ /* Entire needle is periodic; a mismatch can only advance by the
+ period, so use memory to avoid rescanning known occurrences
+ of the period. */
+ size_t memory = 0;
+ size_t shift;
+ j = 0;
+ while (AVAILABLE (haystack, haystack_len, j, needle_len))
+ {
+ /* Check the last byte first; if it does not match, then
+ shift to the next possible match location. */
+ shift = shift_table[CANON_ELEMENT (haystack[j + needle_len - 1])];
+ if (0 < shift)
+ {
+ if (memory && shift < period)
+ {
+ /* Since needle is periodic, but the last period has
+ a byte out of place, there can be no match until
+ after the mismatch. */
+ shift = needle_len - period;
+ memory = 0;
+ }
+ j += shift;
+ continue;
+ }
+ /* Scan for matches in right half. The last byte has
+ already been matched, by virtue of the shift table. */
+ i = MAX (suffix, memory);
+ while (i < needle_len - 1 && (CANON_ELEMENT (needle[i])
+ == CANON_ELEMENT (haystack[i + j])))
+ ++i;
+ if (needle_len - 1 <= i)
+ {
+ /* Scan for matches in left half. */
+ i = suffix - 1;
+ while (memory < i + 1 && (CANON_ELEMENT (needle[i])
+ == CANON_ELEMENT (haystack[i + j])))
+ --i;
+ if (i + 1 < memory + 1)
+ return (RETURN_TYPE) (haystack + j);
+ /* No match, so remember how many repetitions of period
+ on the right half were scanned. */
+ j += period;
+ memory = needle_len - period;
+ }
+ else
+ {
+ j += i - suffix + 1;
+ memory = 0;
+ }
+ }
+ }
+ else
+ {
+ /* The two halves of needle are distinct; no extra memory is
+ required, and any mismatch results in a maximal shift. */
+ size_t shift;
+ period = MAX (suffix, needle_len - suffix) + 1;
+ j = 0;
+ while (AVAILABLE (haystack, haystack_len, j, needle_len))
+ {
+ /* Check the last byte first; if it does not match, then
+ shift to the next possible match location. */
+ shift = shift_table[CANON_ELEMENT (haystack[j + needle_len - 1])];
+ if (0 < shift)
+ {
+ j += shift;
+ continue;
+ }
+ /* Scan for matches in right half. The last byte has
+ already been matched, by virtue of the shift table. */
+ i = suffix;
+ while (i < needle_len - 1 && (CANON_ELEMENT (needle[i])
+ == CANON_ELEMENT (haystack[i + j])))
+ ++i;
+ if (needle_len - 1 <= i)
+ {
+ /* Scan for matches in left half. */
+ i = suffix - 1;
+ while (i != SIZE_MAX && (CANON_ELEMENT (needle[i])
+ == CANON_ELEMENT (haystack[i + j])))
+ --i;
+ if (i == SIZE_MAX)
+ return (RETURN_TYPE) (haystack + j);
+ j += period;
+ }
+ else
+ j += i - suffix + 1;
+ }
+ }
+ return NULL;
+}
+
+#undef AVAILABLE
+#undef CANON_ELEMENT
+#undef CMP_FUNC
+#undef MAX
+#undef RETURN_TYPE
diff --git a/libc/string/strcasestr.c b/libc/string/strcasestr.c
index 1dde43c60..92f2eac7c 100644
--- a/libc/string/strcasestr.c
+++ b/libc/string/strcasestr.c
@@ -1,5 +1,5 @@
/* Return the offset of one string within another.
- Copyright (C) 1994, 1996-2000, 2004 Free Software Foundation, Inc.
+ Copyright (C) 1994, 1996-2000, 2004, 2008 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
@@ -30,113 +30,71 @@
# include <config.h>
#endif
+/* Specification. */
+#include <string.h>
+
#include <ctype.h>
+#include <stdbool.h>
+#include <strings.h>
-#if defined _LIBC || defined HAVE_STRING_H
-# include <string.h>
-#endif
+#define TOLOWER(Ch) (isupper (Ch) ? tolower (Ch) : (Ch))
-#ifdef _LIBC
-# include <locale/localeinfo.h>
-# define TOLOWER(c) __tolower_l ((unsigned char) c, loc)
-#else
-# define TOLOWER(c) _tolower (c)
-#endif
-
-typedef unsigned chartype;
+/* Two-Way algorithm. */
+#define RETURN_TYPE char *
+#define AVAILABLE(h, h_l, j, n_l) \
+ (!memchr ((h) + (h_l), '\0', (j) + (n_l) - (h_l)) \
+ && ((h_l) = (j) + (n_l)))
+#define CANON_ELEMENT(c) TOLOWER (c)
+#define CMP_FUNC(p1, p2, l) \
+ __strncasecmp ((const char *) (p1), (const char *) (p2), l)
+#include "str-two-way.h"
#undef strcasestr
#undef __strcasestr
+/* Find the first occurrence of NEEDLE in HAYSTACK, using
+ case-insensitive comparison. This function gives unspecified
+ results in multibyte locales. */
char *
-__strcasestr (phaystack, pneedle)
- const char *phaystack;
- const char *pneedle;
+__strcasestr (const char *haystack_start, const char *needle_start)
{
- register const unsigned char *haystack, *needle;
- register chartype b, c;
-#ifdef _LIBC
- __locale_t loc = _NL_CURRENT_LOCALE;
-#endif
-
- haystack = (const unsigned char *) phaystack;
- needle = (const unsigned char *) pneedle;
-
- b = TOLOWER (*needle);
- if (b != '\0')
+ const char *haystack = haystack_start;
+ const char *needle = needle_start;
+ size_t needle_len; /* Length of NEEDLE. */
+ size_t haystack_len; /* Known minimum length of HAYSTACK. */
+ bool ok = true; /* True if NEEDLE is prefix of HAYSTACK. */
+
+ /* Determine length of NEEDLE, and in the process, make sure
+ HAYSTACK is at least as long (no point processing all of a long
+ NEEDLE if HAYSTACK is too short). */
+ while (*haystack && *needle)
{
- haystack--; /* possible ANSI violation */
- do
- {
- c = *++haystack;
- if (c == '\0')
- goto ret0;
- }
- while (TOLOWER (c) != (int) b);
-
- c = TOLOWER (*++needle);
- if (c == '\0')
- goto foundneedle;
- ++needle;
- goto jin;
-
- for (;;)
- {
- register chartype a;
- register const unsigned char *rhaystack, *rneedle;
-
- do
- {
- a = *++haystack;
- if (a == '\0')
- goto ret0;
- if (TOLOWER (a) == (int) b)
- break;
- a = *++haystack;
- if (a == '\0')
- goto ret0;
-shloop:
- ;
- }
- while (TOLOWER (a) != (int) b);
-
-jin: a = *++haystack;
- if (a == '\0')
- goto ret0;
-
- if (TOLOWER (a) != (int) c)
- goto shloop;
-
- rhaystack = haystack-- + 1;
- rneedle = needle;
- a = TOLOWER (*rneedle);
-
- if (TOLOWER (*rhaystack) == (int) a)
- do
- {
- if (a == '\0')
- goto foundneedle;
- ++rhaystack;
- a = TOLOWER (*++needle);
- if (TOLOWER (*rhaystack) != (int) a)
- break;
- if (a == '\0')
- goto foundneedle;
- ++rhaystack;
- a = TOLOWER (*++needle);
- }
- while (TOLOWER (*rhaystack) == (int) a);
-
- needle = rneedle; /* took the register-poor approach */
-
- if (a == '\0')
- break;
- }
+ ok &= (TOLOWER ((unsigned char) *haystack)
+ == TOLOWER ((unsigned char) *needle));
+ haystack++;
+ needle++;
}
-foundneedle:
- return (char*) haystack;
-ret0:
- return 0;
+ if (*needle)
+ return NULL;
+ if (ok)
+ return (char *) haystack_start;
+ needle_len = needle - needle_start;
+ haystack = haystack_start + 1;
+ haystack_len = needle_len - 1;
+
+ /* Perform the search. Abstract memory is considered to be an array
+ of 'unsigned char' values, not an array of 'char' values. See
+ ISO C 99 section 6.2.6.1. */
+ if (needle_len < LONG_NEEDLE_THRESHOLD)
+ return two_way_short_needle ((const unsigned char *) haystack,
+ haystack_len,
+ (const unsigned char *) needle_start,
+ needle_len);
+ return two_way_long_needle ((const unsigned char *) haystack, haystack_len,
+ (const unsigned char *) needle_start,
+ needle_len);
}
+#undef LONG_NEEDLE_THRESHOLD
+
weak_alias (__strcasestr, strcasestr)
diff --git a/libc/string/strstr.c b/libc/string/strstr.c
index fce1f2a75..a9dc31299 100644
--- a/libc/string/strstr.c
+++ b/libc/string/strstr.c
@@ -1,5 +1,5 @@
/* Return the offset of one string within another.
- Copyright (C) 1994,1996,1997,2000,2001,2003 Free Software Foundation, Inc.
+ Copyright (C) 1994,1996,1997,2000,2001,2003,2008 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,107 +17,71 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-/*
- * My personal strstr() implementation that beats most other algorithms.
- * Until someone tells me otherwise, I assume that this is the
- * fastest implementation of strstr() in C.
- * I deliberately chose not to comment it. You should have at least
- * as much fun trying to understand it, as I had to write it :-).
- *
- * Stephen R. van den Berg, berg@pool.informatik.rwth-aachen.de */
+/* This particular implementation was written by Eric Blake, 2008. */
-#if HAVE_CONFIG_H
+#ifndef _LIBC
# include <config.h>
#endif
-#if defined _LIBC || defined HAVE_STRING_H
-# include <string.h>
+/* Specification of strstr. */
+#include <string.h>
+
+#include <stdbool.h>
+
+#ifndef _LIBC
+# define __builtin_expect(expr, val) (expr)
#endif
-typedef unsigned chartype;
+#define RETURN_TYPE char *
+#define AVAILABLE(h, h_l, j, n_l) \
+ (!memchr ((h) + (h_l), '\0', (j) + (n_l) - (h_l)) \
+ && ((h_l) = (j) + (n_l)))
+#include "str-two-way.h"
#undef strstr
+/* Return the first occurrence of NEEDLE in HAYSTACK. Return HAYSTACK
+ if NEEDLE is empty, otherwise NULL if NEEDLE is not found in
+ HAYSTACK. */
char *
-strstr (phaystack, pneedle)
- const char *phaystack;
- const char *pneedle;
+strstr (const char *haystack_start, const char *needle_start)
{
- const unsigned char *haystack, *needle;
- chartype b;
- const unsigned char *rneedle;
-
- haystack = (const unsigned char *) phaystack;
+ const char *haystack = haystack_start;
+ const char *needle = needle_start;
+ size_t needle_len; /* Length of NEEDLE. */
+ size_t haystack_len; /* Known minimum length of HAYSTACK. */
+ bool ok = true; /* True if NEEDLE is prefix of HAYSTACK. */
- if ((b = *(needle = (const unsigned char *) pneedle)))
- {
- chartype c;
- haystack--; /* possible ANSI violation */
+ /* Determine length of NEEDLE, and in the process, make sure
+ HAYSTACK is at least as long (no point processing all of a long
+ NEEDLE if HAYSTACK is too short). */
+ while (*haystack && *needle)
+ ok &= *haystack++ == *needle++;
+ if (*needle)
+ return NULL;
+ if (ok)
+ return (char *) haystack_start;
- {
- chartype a;
- do
- if (!(a = *++haystack))
- goto ret0;
- while (a != b);
- }
+ /* Reduce the size of haystack using strchr, since it has a smaller
+ linear coefficient than the Two-Way algorithm. */
+ needle_len = needle - needle_start;
+ haystack = strchr (haystack_start + 1, *needle_start);
+ if (!haystack || __builtin_expect (needle_len == 1, 0))
+ return (char *) haystack;
+ needle -= needle_len;
+ haystack_len = (haystack > haystack_start + needle_len ? 1
+ : needle_len + haystack_start - haystack);
- if (!(c = *++needle))
- goto foundneedle;
- ++needle;
- goto jin;
-
- for (;;)
- {
- {
- chartype a;
- if (0)
- jin:{
- if ((a = *++haystack) == c)
- goto crest;
- }
- else
- a = *++haystack;
- do
- {
- for (; a != b; a = *++haystack)
- {
- if (!a)
- goto ret0;
- if ((a = *++haystack) == b)
- break;
- if (!a)
- goto ret0;
- }
- }
- while ((a = *++haystack) != c);
- }
- crest:
- {
- chartype a;
- {
- const unsigned char *rhaystack;
- if (*(rhaystack = haystack-- + 1) == (a = *(rneedle = needle)))
- do
- {
- if (!a)
- goto foundneedle;
- if (*++rhaystack != (a = *++needle))
- break;
- if (!a)
- goto foundneedle;
- }
- while (*++rhaystack == (a = *++needle));
- needle = rneedle; /* took the register-poor aproach */
- }
- if (!a)
- break;
- }
- }
- }
-foundneedle:
- return (char *) haystack;
-ret0:
- return 0;
+ /* Perform the search. Abstract memory is considered to be an array
+ of 'unsigned char' values, not an array of 'char' values. See
+ ISO C 99 section 6.2.6.1. */
+ if (needle_len < LONG_NEEDLE_THRESHOLD)
+ return two_way_short_needle ((const unsigned char *) haystack,
+ haystack_len,
+ (const unsigned char *) needle, needle_len);
+ return two_way_long_needle ((const unsigned char *) haystack, haystack_len,
+ (const unsigned char *) needle, needle_len);
}
libc_hidden_builtin_def (strstr)
+
+#undef LONG_NEEDLE_THRESHOLD
diff --git a/libc/string/test-memmem.c b/libc/string/test-memmem.c
new file mode 100644
index 000000000..91b661b16
--- /dev/null
+++ b/libc/string/test-memmem.c
@@ -0,0 +1,185 @@
+/* Test and measure memmem functions.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Written by Ulrich Drepper <drepper@redhat.com>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#define TEST_MAIN
+#define BUF1PAGES 20
+#define ITERATIONS 500
+#include "test-string.h"
+
+typedef char *(*proto_t) (const void *, size_t, const void *, size_t);
+void *simple_memmem (const void *, size_t, const void *, size_t);
+
+IMPL (simple_memmem, 0)
+IMPL (memmem, 1)
+
+void *
+simple_memmem (const void *haystack, size_t haystack_len, const void *needle,
+ size_t needle_len)
+{
+ const char *begin;
+ const char *const last_possible
+ = (const char *) haystack + haystack_len - needle_len;
+
+ if (needle_len == 0)
+ /* The first occurrence of the empty string is deemed to occur at
+ the beginning of the string. */
+ return (void *) haystack;
+
+ /* Sanity check, otherwise the loop might search through the whole
+ memory. */
+ if (__builtin_expect (haystack_len < needle_len, 0))
+ return NULL;
+
+ for (begin = (const char *) haystack; begin <= last_possible; ++begin)
+ if (begin[0] == ((const char *) needle)[0] &&
+ !memcmp ((const void *) &begin[1],
+ (const void *) ((const char *) needle + 1),
+ needle_len - 1))
+ return (void *) begin;
+
+ return NULL;
+}
+
+static void
+do_one_test (impl_t *impl, const void *haystack, size_t haystack_len,
+ const void *needle, size_t needle_len, const void *expected)
+{
+ void *res;
+
+ res = CALL (impl, haystack, haystack_len, needle, needle_len);
+ if (res != expected)
+ {
+ error (0, 0, "Wrong result in function %s %p %p", impl->name,
+ res, expected);
+ ret = 1;
+ return;
+ }
+
+ if (HP_TIMING_AVAIL)
+ {
+ hp_timing_t start __attribute ((unused));
+ hp_timing_t stop __attribute ((unused));
+ hp_timing_t best_time = ~ (hp_timing_t) 0;
+ size_t i;
+
+ for (i = 0; i < 32; ++i)
+ {
+ HP_TIMING_NOW (start);
+ CALL (impl, haystack, haystack_len, needle, needle_len);
+ HP_TIMING_NOW (stop);
+ HP_TIMING_BEST (best_time, start, stop);
+ }
+
+ printf ("\t%zd", (size_t) best_time);
+ }
+}
+
+static void
+do_test (const char *str, size_t len, size_t idx)
+{
+ char tmpbuf[len];
+
+ memcpy (tmpbuf, buf1 + idx, len);
+ memcpy (buf1 + idx, str, len);
+
+ if (HP_TIMING_AVAIL)
+ printf ("String %s, offset %zd:", str, idx);
+
+ FOR_EACH_IMPL (impl, 0)
+ do_one_test (impl, buf1, BUF1PAGES * page_size, str, len, buf1 + idx);
+
+ memcpy (buf1 + idx, tmpbuf, len);
+
+ if (HP_TIMING_AVAIL)
+ putchar ('\n');
+}
+
+static void
+do_random_tests (void)
+{
+ for (size_t n = 0; n < ITERATIONS; ++n)
+ {
+ char tmpbuf[32];
+
+ size_t shift = random () % 11;
+ size_t rel = random () % ((2 << (shift + 1)) * 64);
+ size_t idx = MIN ((2 << shift) * 64 + rel, BUF1PAGES * page_size - 2);
+ size_t len = random () % (sizeof (tmpbuf) - 1) + 1;
+ len = MIN (len, BUF1PAGES * page_size - idx - 1);
+ memcpy (tmpbuf, buf1 + idx, len);
+ for (size_t i = random () % len / 2 + 1; i > 0; --i)
+ {
+ size_t off = random () % len;
+ char ch = '0' + random () % 10;
+
+ buf1[idx + off] = ch;
+ }
+
+ if (HP_TIMING_AVAIL)
+ printf ("String %.*s, offset %zd:", (int) len, buf1 + idx, idx);
+
+ FOR_EACH_IMPL (impl, 0)
+ do_one_test (impl, buf1, BUF1PAGES * page_size, buf1 + idx, len,
+ buf1 + idx);
+
+ if (HP_TIMING_AVAIL)
+ putchar ('\n');
+
+ memcpy (buf1 + idx, tmpbuf, len);
+ }
+}
+
+
+static const char *const strs[] =
+ {
+ "00000", "00112233", "0123456789", "0000111100001111",
+ "00000111110000022222", "012345678901234567890",
+ "abc0", "aaaa0", "abcabc0"
+ };
+
+
+int
+test_main (void)
+{
+ size_t i;
+
+ test_init ();
+
+ printf ("%23s", "");
+ FOR_EACH_IMPL (impl, 0)
+ printf ("\t%s", impl->name);
+ putchar ('\n');
+
+ for (i = 0; i < BUF1PAGES * page_size; ++i)
+ buf1[i] = 60 + random () % 32;
+
+ for (i = 0; i < sizeof (strs) / sizeof (strs[0]); ++i)
+ for (size_t j = 0; j < 120; j += 7)
+ {
+ size_t len = strlen (strs[i]);
+
+ do_test (strs[i], len, j);
+ }
+
+ do_random_tests ();
+ return ret;
+}
+
+#include "../test-skeleton.c"
diff --git a/libc/string/test-string.h b/libc/string/test-string.h
index 381c140d9..1aea4c9cb 100644
--- a/libc/string/test-string.h
+++ b/libc/string/test-string.h
@@ -1,5 +1,5 @@
/* Test and measure string and memory functions.
- Copyright (C) 1999, 2002, 2004 Free Software Foundation, Inc.
+ Copyright (C) 1999, 2002, 2004, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Written by Jakub Jelinek <jakub@redhat.com>, 1999.
@@ -118,6 +118,10 @@ size_t iterations = 100000;
} \
while (0)
+#ifndef BUF1PAGES
+# define BUF1PAGES 1
+#endif
+
static void
test_init (void)
{
@@ -126,11 +130,11 @@ test_init (void)
if (page_size < MIN_PAGE_SIZE)
page_size = MIN_PAGE_SIZE;
#endif
- buf1 = mmap (0, 2 * page_size, PROT_READ | PROT_WRITE,
+ buf1 = mmap (0, (BUF1PAGES + 1) * page_size, PROT_READ | PROT_WRITE,
MAP_PRIVATE | MAP_ANON, -1, 0);
if (buf1 == MAP_FAILED)
error (EXIT_FAILURE, errno, "mmap failed");
- if (mprotect (buf1 + page_size, page_size, PROT_NONE))
+ if (mprotect (buf1 + BUF1PAGES * page_size, page_size, PROT_NONE))
error (EXIT_FAILURE, errno, "mprotect failed");
buf2 = mmap (0, 2 * page_size, PROT_READ | PROT_WRITE,
MAP_PRIVATE | MAP_ANON, -1, 0);
@@ -145,7 +149,7 @@ test_init (void)
srandom (seed);
}
- memset (buf1, 0xa5, page_size);
+ memset (buf1, 0xa5, BUF1PAGES * page_size);
memset (buf2, 0x5a, page_size);
}
diff --git a/libc/string/tester.c b/libc/string/tester.c
index 1c0efe07d..773e969a3 100644
--- a/libc/string/tester.c
+++ b/libc/string/tester.c
@@ -985,15 +985,33 @@ test_strsep (void)
static void
test_memcmp (void)
{
+ int cnt = 1;
+ char one[21];
+ char two[21];
+
it = "memcmp";
- check(memcmp("a", "a", 1) == 0, 1); /* Identity. */
- check(memcmp("abc", "abc", 3) == 0, 2); /* Multicharacter. */
- check(memcmp("abcd", "abce", 4) < 0, 3); /* Honestly unequal. */
- check(memcmp("abce", "abcd", 4) > 0, 4);
- check(memcmp("alph", "beta", 4) < 0, 5);
- check(memcmp("a\203", "a\003", 2) > 0, 6);
- check(memcmp("abce", "abcd", 3) == 0, 7); /* Count limited. */
- check(memcmp("abc", "def", 0) == 0, 8); /* Zero count. */
+ check(memcmp("a", "a", 1) == 0, cnt++); /* Identity. */
+ check(memcmp("abc", "abc", 3) == 0, cnt++); /* Multicharacter. */
+ check(memcmp("abcd", "abcf", 4) < 0, cnt++); /* Honestly unequal. */
+ check(memcmp("abcf", "abcd", 4) > 0, cnt++);
+ check(memcmp("alph", "cold", 4) < 0, cnt++);
+ check(memcmp("a\203", "a\003", 2) > 0, cnt++);
+ check(memcmp("a\003", "a\203", 2) < 0, cnt++);
+ check(memcmp("a\003bc", "a\203bc", 2) < 0, cnt++);
+ check(memcmp("abc\203", "abc\003", 4) > 0, cnt++);
+ check(memcmp("abc\003", "abc\203", 4) < 0, cnt++);
+ check(memcmp("abcf", "abcd", 3) == 0, cnt++); /* Count limited. */
+ check(memcmp("abc", "def", 0) == 0, cnt++); /* Zero count. */
+ /* Comparisons with shifting 4-byte boundaries. */
+ for (int i = 0; i < 4; ++i)
+ {
+ char *a = one + i;
+ char *b = two + i;
+ strncpy(a, "--------11112222", 16);
+ strncpy(b, "--------33334444", 16);
+ check(memcmp(b, a, 16) > 0, cnt++);
+ check(memcmp(a, b, 16) < 0, cnt++);
+ }
}
static void
diff --git a/libc/string/tst-endian.c b/libc/string/tst-endian.c
new file mode 100644
index 000000000..c34dc456a
--- /dev/null
+++ b/libc/string/tst-endian.c
@@ -0,0 +1,112 @@
+#include <byteswap.h>
+#include <endian.h>
+#include <inttypes.h>
+#include <stdio.h>
+
+
+static int
+do_test (void)
+{
+ int result = 0;
+
+ for (uint64_t i = 0; i < (~UINT64_C (0)) >> 2; i = (i << 1) + 3)
+ {
+ if (i < UINT64_C (65536))
+ {
+ if (htobe16 (be16toh (i)) != i)
+ {
+ printf ("htobe16 (be16toh (%" PRIx64 ")) == %" PRIx16 "\n",
+ i, (uint16_t) htobe16 (be16toh (i)));
+ result = 1;
+ }
+ if (htole16 (le16toh (i)) != i)
+ {
+ printf ("htole16 (le16toh (%" PRIx64 ")) == %" PRIx16 "\n",
+ i, (uint16_t) htole16 (le16toh (i)));
+ result = 1;
+ }
+
+ uint16_t n[2];
+ n[__BYTE_ORDER == __LITTLE_ENDIAN] = bswap_16 (i);
+ n[__BYTE_ORDER == __BIG_ENDIAN] = i;
+ if (htole16 (i) != n[0])
+ {
+ printf ("htole16 (%" PRIx64 ") == %" PRIx16 " != %" PRIx16 "\n",
+ i, (uint16_t) htole16 (i), n[0]);
+ result = 1;
+ }
+ if (htobe16 (i) != n[1])
+ {
+ printf ("htobe16 (%" PRIx64 ") == %" PRIx16 " != %" PRIx16 "\n",
+ i, (uint16_t) htobe16 (i), n[1]);
+ result = 1;
+ }
+ }
+
+ if (i < UINT64_C (4294967296))
+ {
+ if (htobe32 (be32toh (i)) != i)
+ {
+ printf ("htobe32 (be32toh (%" PRIx64 ")) == %" PRIx32 "\n",
+ i, (uint32_t) htobe32 (be32toh (i)));
+ result = 1;
+ }
+ if (htole32 (le32toh (i)) != i)
+ {
+ printf ("htole32 (le32toh (%" PRIx64 ")) == %" PRIx32 "\n",
+ i, (uint32_t) htole32 (le32toh (i)));
+ result = 1;
+ }
+
+ uint32_t n[2];
+ n[__BYTE_ORDER == __LITTLE_ENDIAN] = bswap_32 (i);
+ n[__BYTE_ORDER == __BIG_ENDIAN] = i;
+ if (htole32 (i) != n[0])
+ {
+ printf ("htole32 (%" PRIx64 ") == %" PRIx32 " != %" PRIx32 "\n",
+ i, (uint32_t) htole32 (i), n[0]);
+ result = 1;
+ }
+ if (htobe32 (i) != n[1])
+ {
+ printf ("htobe32 (%" PRIx64 ") == %" PRIx32 " != %" PRIx32 "\n",
+ i, (uint32_t) htobe32 (i), n[1]);
+ result = 1;
+ }
+ }
+
+ if (htobe64 (be64toh (i)) != i)
+ {
+ printf ("htobe64 (be64toh (%" PRIx64 ")) == %" PRIx64 "\n",
+ i, htobe64 (be64toh (i)));
+ result = 1;
+ }
+ if (htole64 (le64toh (i)) != i)
+ {
+ printf ("htole64 (le64toh (%" PRIx64 ")) == %" PRIx64 "\n",
+ i, htole64 (le64toh (i)));
+ result = 1;
+ }
+
+ uint64_t n[2];
+ n[__BYTE_ORDER == __LITTLE_ENDIAN] = bswap_64 (i);
+ n[__BYTE_ORDER == __BIG_ENDIAN] = i;
+ if (htole64 (i) != n[0])
+ {
+ printf ("htole64 (%" PRIx64 ") == %" PRIx64 " != %" PRIx64 "\n",
+ i, htole64 (i), n[0]);
+ result = 1;
+ }
+ if (htobe64 (i) != n[1])
+ {
+ printf ("htobe64 (%" PRIx64 ") == %" PRIx64 " != %" PRIx64 "\n",
+ i, htobe64 (i), n[1]);
+ result = 1;
+ }
+ }
+
+ return result;
+}
+
+#define TEST_FUNCTION do_test ()
+#include "../test-skeleton.c"
diff --git a/libc/sunrpc/Makefile b/libc/sunrpc/Makefile
index f76d8c78f..c5d7eeaa5 100644
--- a/libc/sunrpc/Makefile
+++ b/libc/sunrpc/Makefile
@@ -105,9 +105,7 @@ otherlibs += $(nssobjdir)/libnss_files.a $(resolvobjdir)/libnss_dns.a \
$(resolvobjdir)/libresolv.a
endif
-ifeq (no,$(cross-compiling))
ifneq (yes,$(install-bootstrap-headers))
-# We can only build this library if we can run the rpcgen we build.
headers += $(rpcsvc:%.x=rpcsvc/%.h)
extra-libs-$(OPTION_EGLIBC_SUNRPC) += librpcsvc
# Make it in `others' pass, not `lib' pass.
@@ -116,7 +114,6 @@ librpcsvc-routines = $(rpcsvc:%.x=x%)
librpcsvc-inhibit-o = .os # Build no shared rpcsvc library.
omit-deps = $(librpcsvc-routines)
endif
-endif
CFLAGS-xbootparam_prot.c = -Wno-unused $(PIC-ccflag)
CFLAGS-xnlm_prot.c = -Wno-unused $(PIC-ccflag)
@@ -146,13 +143,30 @@ $(objpfx)rpcgen: $(addprefix $(objpfx),$(rpcgen-objs)) \
$(addprefix $(csu-objpfx),start.o) $(+preinit) $(+postinit)
$(+link)
+$(addprefix $(objpfx)cross-,$(rpcgen-objs)): $(objpfx)cross-%.o: %.c
+ gcc $< -c -D_RPC_THREAD_SAFE_ -D_CROSS_RPCGEN_ \
+ $(OUTPUT_OPTION) $(compile-mkdep-flags)
+
+$(objpfx)cross-rpcgen: $(addprefix $(objpfx)cross-,$(rpcgen-objs))
+ gcc $^ -o $@
+
# This makes sure -DNOT_IN_libc is passed for all these modules.
cpp-srcs-left := $(rpcgen-objs:.o=.c)
lib := nonlib
include $(patsubst %,$(..)cppflags-iterator.mk,$(cpp-srcs-left))
+ifeq (no,$(cross-compiling))
# Tell rpcgen where to find the C preprocessor.
rpcgen-cmd = CPP='$(CC) -E -x c-header' $(built-program-cmd) -Y ../scripts
+# Depend rpcsvc headers and sources on rpcgen.
+rpcgen-dep = $(objpfx)rpcgen
+else
+# Tell rpcgen where to find the C preprocessor.
+rpcgen-cmd = CPP='$(CC) -E -x c-header' $(objpfx)cross-rpcgen -Y ../scripts
+# Depend rpcsvc headers and sources on cross-rpcgen and rpcgen (to trigger
+# its build).
+rpcgen-dep = $(objpfx)rpcgen $(objpfx)cross-rpcgen
+endif
# Install the rpc data base file.
$(inst_sysconfdir)/rpc: etc.rpc $(+force)
@@ -163,7 +177,7 @@ $(inst_sysconfdir)/rpc: etc.rpc $(+force)
# relinked.
$(rpcsvc:%.x=$(objpfx)rpcsvc/%.h): $(objpfx)rpcsvc/%.h: $(objpfx)rpcsvc/%.stmp
@:
-$(objpfx)rpcsvc/%.stmp: rpcsvc/%.x $(objpfx)rpcgen
+$(objpfx)rpcsvc/%.stmp: rpcsvc/%.x $(rpcgen-dep)
$(make-target-directory)
-@rm -f ${@:stmp=T} $@
$(rpcgen-cmd) -h $< -o ${@:stmp=T}
@@ -173,7 +187,7 @@ $(objpfx)rpcsvc/%.stmp: rpcsvc/%.x $(objpfx)rpcgen
# Generate the rpcsvc XDR functions with rpcgen.
$(rpcsvc:%.x=$(objpfx)x%.c): $(objpfx)x%.c: $(objpfx)x%.stmp
@:
-$(objpfx)x%.stmp: rpcsvc/%.x $(objpfx)rpcgen
+$(objpfx)x%.stmp: rpcsvc/%.x $(rpcgen-dep)
-@rm -f ${@:stmp=T} $@
$(rpcgen-cmd) -c $< -o ${@:stmp=T}
$(move-if-change) $(@:stmp=T) $(@:stmp=c)
diff --git a/libc/sunrpc/Versions b/libc/sunrpc/Versions
index cddf18876..d2d8e81ac 100644
--- a/libc/sunrpc/Versions
+++ b/libc/sunrpc/Versions
@@ -116,4 +116,7 @@ libc {
GLIBC_2.3.4 {
xdr_quad_t; xdr_u_quad_t;
}
+ GLIBC_PRIVATE {
+ __libc_clntudp_bufcreate;
+ }
}
diff --git a/libc/sunrpc/clnt_udp.c b/libc/sunrpc/clnt_udp.c
index 634313211..548c987e6 100644
--- a/libc/sunrpc/clnt_udp.c
+++ b/libc/sunrpc/clnt_udp.c
@@ -54,12 +54,15 @@ static char sccsid[] = "@(#)clnt_udp.c 1.39 87/08/11 Copyr 1984 Sun Micro";
#ifdef USE_IN_LIBIO
# include <wchar.h>
#endif
+#include <fcntl.h>
#ifdef IP_RECVERR
#include <errqueue.h>
#include <sys/uio.h>
#endif
+#include <kernel-features.h>
+
extern bool_t xdr_opaque_auth (XDR *, struct opaque_auth *);
extern u_long _create_xid (void);
@@ -121,9 +124,9 @@ struct cu_data
* sent and received.
*/
CLIENT *
-clntudp_bufcreate (struct sockaddr_in *raddr, u_long program, u_long version,
- struct timeval wait, int *sockp, u_int sendsz,
- u_int recvsz)
+__libc_clntudp_bufcreate (struct sockaddr_in *raddr, u_long program,
+ u_long version, struct timeval wait, int *sockp,
+ u_int sendsz, u_int recvsz, int flags)
{
CLIENT *cl;
struct cu_data *cu = NULL;
@@ -178,8 +181,32 @@ clntudp_bufcreate (struct sockaddr_in *raddr, u_long program, u_long version,
{
int dontblock = 1;
- *sockp = __socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP);
- if (*sockp < 0)
+#ifdef SOCK_NONBLOCK
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec >= 0)
+# endif
+ {
+ *sockp = __socket (AF_INET, SOCK_DGRAM|SOCK_NONBLOCK|flags,
+ IPPROTO_UDP);
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec == 0)
+ __have_sock_cloexec = *sockp >= 0 || errno != EINVAL ? 1 : -1;
+# endif
+ }
+#endif
+#ifndef __ASSUME_SOCK_CLOEXEC
+# ifdef SOCK_CLOEXEC
+ if (__have_sock_cloexec < 0)
+# endif
+ {
+ *sockp = __socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP);
+# ifdef SOCK_CLOEXEC
+ if (flags & SOCK_CLOEXEC)
+ __fcntl (*sockp, F_SETFD, FD_CLOEXEC);
+# endif
+ }
+#endif
+ if (__builtin_expect (*sockp < 0, 0))
{
struct rpc_createerr *ce = &get_rpc_createerr ();
ce->cf_stat = RPC_SYSTEMERROR;
@@ -188,8 +215,13 @@ clntudp_bufcreate (struct sockaddr_in *raddr, u_long program, u_long version,
}
/* attempt to bind to prov port */
(void) bindresvport (*sockp, (struct sockaddr_in *) 0);
- /* the sockets rpc controls are non-blocking */
- (void) __ioctl (*sockp, FIONBIO, (char *) &dontblock);
+#ifndef __ASSUME_SOCK_CLOEXEC
+# ifdef SOCK_CLOEXEC
+ if (__have_sock_cloexec < 0)
+# endif
+ /* the sockets rpc controls are non-blocking */
+ (void) __ioctl (*sockp, FIONBIO, (char *) &dontblock);
+#endif
#ifdef IP_RECVERR
{
int on = 1;
@@ -212,6 +244,16 @@ fooy:
mem_free ((caddr_t) cl, sizeof (CLIENT));
return (CLIENT *) NULL;
}
+INTDEF (__libc_clntudp_bufcreate)
+
+CLIENT *
+clntudp_bufcreate (struct sockaddr_in *raddr, u_long program, u_long version,
+ struct timeval wait, int *sockp, u_int sendsz,
+ u_int recvsz)
+{
+ return INTUSE(__libc_clntudp_bufcreate) (raddr, program, version, wait,
+ sockp, sendsz, recvsz, 0);
+}
INTDEF (clntudp_bufcreate)
CLIENT *
@@ -222,8 +264,8 @@ clntudp_create (raddr, program, version, wait, sockp)
struct timeval wait;
int *sockp;
{
- return INTUSE(clntudp_bufcreate) (raddr, program, version, wait, sockp,
- UDPMSGSIZE, UDPMSGSIZE);
+ return INTUSE(__libc_clntudp_bufcreate) (raddr, program, version, wait,
+ sockp, UDPMSGSIZE, UDPMSGSIZE, 0);
}
INTDEF (clntudp_create)
diff --git a/libc/sunrpc/key_call.c b/libc/sunrpc/key_call.c
index 611c37256..319d8017e 100644
--- a/libc/sunrpc/key_call.c
+++ b/libc/sunrpc/key_call.c
@@ -462,7 +462,7 @@ getkeyserv_handle (int vers)
clnt_control (kcp->client, CLSET_RETRY_TIMEOUT,
(char *)&wait_time);
if (clnt_control (kcp->client, CLGET_FD, (char *)&fd))
- __fcntl (fd, F_SETFD, 1); /* make it "close on exec" */
+ __fcntl (fd, F_SETFD, FD_CLOEXEC); /* make it "close on exec" */
return kcp->client;
}
diff --git a/libc/sunrpc/proto.h b/libc/sunrpc/proto.h
index 3e1ecd1f2..7c0412b70 100644
--- a/libc/sunrpc/proto.h
+++ b/libc/sunrpc/proto.h
@@ -50,3 +50,24 @@ void crash(void) __attribute__ ((noreturn));
void tabify(FILE *f, int tab);
char *make_argname(const char *pname, const char *vname);
void add_type(int len, const char *type);
+
+/* This header is the last one included in all rpc_*.c files,
+ so we define stuff for cross-rpcgen here to avoid conflicts with
+ $build's C library and $host's GLIBC. */
+#ifdef _CROSS_RPCGEN_
+
+/* Rather then defining _GNU_SOURCE before including $build's <string.h>
+ we just declare stpcpy here. */
+extern char *stpcpy (char *, const char *);
+
+/* Use $build's i18n support as we can't use $host's. */
+#define _(X) (gettext (X))
+
+/* rpcgen sources check for __GNU_LIBRARY__ to tweak for GLIBC code
+ that rpcgen generates. The proper fix would be to rename all those checks
+ to something like '#if defined(TWEAK_FOR_GLIBC) || 1'. */
+#ifndef __GNU_LIBRARY__
+#define __GNU_LIBRARY__
+#endif
+
+#endif
diff --git a/libc/sysdeps/generic/ldsodefs.h b/libc/sysdeps/generic/ldsodefs.h
index 9d1ebdf61..4d857404a 100644
--- a/libc/sysdeps/generic/ldsodefs.h
+++ b/libc/sysdeps/generic/ldsodefs.h
@@ -38,6 +38,7 @@
#include <bits/libc-lock.h>
#include <hp-timing.h>
#include <tls.h>
+#include <kernel-features.h>
__BEGIN_DECLS
diff --git a/libc/sysdeps/i386/Makefile b/libc/sysdeps/i386/Makefile
index ddd3d04e0..ef45ce6e7 100644
--- a/libc/sysdeps/i386/Makefile
+++ b/libc/sysdeps/i386/Makefile
@@ -65,3 +65,13 @@ endif
ifneq (,$(filter -mno-tls-direct-seg-refs,$(CFLAGS)))
defines += -DNO_TLS_DIRECT_SEG_REFS
endif
+
+ifeq ($(subdir),elf)
+sysdep-dl-routines += tlsdesc dl-tlsdesc
+sysdep_routines += tlsdesc dl-tlsdesc
+sysdep-rtld-routines += tlsdesc dl-tlsdesc
+endif
+
+ifeq ($(subdir),csu)
+gen-as-const-headers += tlsdesc.sym
+endif
diff --git a/libc/sysdeps/i386/bits/byteswap.h b/libc/sysdeps/i386/bits/byteswap.h
index 7f2ddc2dc..1f3fc5e52 100644
--- a/libc/sysdeps/i386/bits/byteswap.h
+++ b/libc/sysdeps/i386/bits/byteswap.h
@@ -1,5 +1,5 @@
/* Macros to swap the order of bytes in integer values.
- Copyright (C) 1997, 1998, 2000, 2002, 2003, 2006, 2007
+ Copyright (C) 1997, 1998, 2000, 2002, 2003, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -18,7 +18,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#if !defined _BYTESWAP_H && !defined _NETINET_IN_H
+#if !defined _BYTESWAP_H && !defined _NETINET_IN_H && !defined _ENDIAN_H
# error "Never use <bits/byteswap.h> directly; include <byteswap.h> instead."
#endif
diff --git a/libc/sysdeps/i386/bits/linkmap.h b/libc/sysdeps/i386/bits/linkmap.h
index 3be9b7eae..978d52621 100644
--- a/libc/sysdeps/i386/bits/linkmap.h
+++ b/libc/sysdeps/i386/bits/linkmap.h
@@ -2,4 +2,5 @@ struct link_map_machine
{
Elf32_Addr plt; /* Address of .plt + 0x16 */
Elf32_Addr gotplt; /* Address of .got + 0x0c */
+ void *tlsdesc_table; /* Address of TLS descriptor hash table. */
};
diff --git a/libc/sysdeps/i386/dl-lookupcfg.h b/libc/sysdeps/i386/dl-lookupcfg.h
new file mode 100644
index 000000000..2af2b9e8f
--- /dev/null
+++ b/libc/sysdeps/i386/dl-lookupcfg.h
@@ -0,0 +1,28 @@
+/* Configuration of lookup functions.
+ Copyright (C) 2005, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#define DL_UNMAP_IS_SPECIAL
+
+#include_next <dl-lookupcfg.h>
+
+struct link_map;
+
+extern void internal_function _dl_unmap (struct link_map *map);
+
+#define DL_UNMAP(map) _dl_unmap (map)
diff --git a/libc/sysdeps/i386/dl-machine.h b/libc/sysdeps/i386/dl-machine.h
index 04296d2a9..e3342d8e1 100644
--- a/libc/sysdeps/i386/dl-machine.h
+++ b/libc/sysdeps/i386/dl-machine.h
@@ -25,6 +25,7 @@
#include <sys/param.h>
#include <sysdep.h>
#include <tls.h>
+#include <dl-tlsdesc.h>
/* Return nonzero iff ELF header is compatible with the running host. */
static inline int __attribute__ ((unused))
@@ -246,7 +247,7 @@ _dl_start_user:\n\
# define elf_machine_type_class(type) \
((((type) == R_386_JMP_SLOT || (type) == R_386_TLS_DTPMOD32 \
|| (type) == R_386_TLS_DTPOFF32 || (type) == R_386_TLS_TPOFF32 \
- || (type) == R_386_TLS_TPOFF) \
+ || (type) == R_386_TLS_TPOFF || (type) == R_386_TLS_DESC) \
* ELF_RTYPE_CLASS_PLT) \
| (((type) == R_386_COPY) * ELF_RTYPE_CLASS_COPY))
#else
@@ -373,6 +374,38 @@ elf_machine_rel (struct link_map *map, const Elf32_Rel *reloc,
*reloc_addr = sym->st_value;
# endif
break;
+ case R_386_TLS_DESC:
+ {
+ struct tlsdesc volatile *td =
+ (struct tlsdesc volatile *)reloc_addr;
+
+# ifndef RTLD_BOOTSTRAP
+ if (! sym)
+ td->entry = _dl_tlsdesc_undefweak;
+ else
+# endif
+ {
+# ifndef RTLD_BOOTSTRAP
+# ifndef SHARED
+ CHECK_STATIC_TLS (map, sym_map);
+# else
+ if (!TRY_STATIC_TLS (map, sym_map))
+ {
+ td->arg = _dl_make_tlsdesc_dynamic
+ (sym_map, sym->st_value + (ElfW(Word))td->arg);
+ td->entry = _dl_tlsdesc_dynamic;
+ }
+ else
+# endif
+# endif
+ {
+ td->arg = (void*)(sym->st_value - sym_map->l_tls_offset
+ + (ElfW(Word))td->arg);
+ td->entry = _dl_tlsdesc_return;
+ }
+ }
+ break;
+ }
case R_386_TLS_TPOFF32:
/* The offset is positive, backward from the thread pointer. */
# ifdef RTLD_BOOTSTRAP
@@ -485,6 +518,41 @@ elf_machine_rela (struct link_map *map, const Elf32_Rela *reloc,
Therefore the offset is already correct. */
*reloc_addr = (sym == NULL ? 0 : sym->st_value) + reloc->r_addend;
break;
+ case R_386_TLS_DESC:
+ {
+ struct tlsdesc volatile *td =
+ (struct tlsdesc volatile *)reloc_addr;
+
+# ifndef RTLD_BOOTSTRAP
+ if (!sym)
+ {
+ td->arg = (void*)reloc->r_addend;
+ td->entry = _dl_tlsdesc_undefweak;
+ }
+ else
+# endif
+ {
+# ifndef RTLD_BOOTSTRAP
+# ifndef SHARED
+ CHECK_STATIC_TLS (map, sym_map);
+# else
+ if (!TRY_STATIC_TLS (map, sym_map))
+ {
+ td->arg = _dl_make_tlsdesc_dynamic
+ (sym_map, sym->st_value + reloc->r_addend);
+ td->entry = _dl_tlsdesc_dynamic;
+ }
+ else
+# endif
+# endif
+ {
+ td->arg = (void*)(sym->st_value - sym_map->l_tls_offset
+ + reloc->r_addend);
+ td->entry = _dl_tlsdesc_return;
+ }
+ }
+ }
+ break;
case R_386_TLS_TPOFF32:
/* The offset is positive, backward from the thread pointer. */
/* We know the offset of object the symbol is contained in.
@@ -578,6 +646,53 @@ elf_machine_lazy_rel (struct link_map *map,
*reloc_addr = (map->l_mach.plt
+ (((Elf32_Addr) reloc_addr) - map->l_mach.gotplt) * 4);
}
+ else if (__builtin_expect (r_type == R_386_TLS_DESC, 1))
+ {
+ struct tlsdesc volatile * __attribute__((__unused__)) td =
+ (struct tlsdesc volatile *)reloc_addr;
+
+ /* Handle relocations that reference the local *ABS* in a simple
+ way, so as to preserve a potential addend. */
+ if (ELF32_R_SYM (reloc->r_info) == 0)
+ td->entry = _dl_tlsdesc_resolve_abs_plus_addend;
+ /* Given a known-zero addend, we can store a pointer to the
+ reloc in the arg position. */
+ else if (td->arg == 0)
+ {
+ td->arg = (void*)reloc;
+ td->entry = _dl_tlsdesc_resolve_rel;
+ }
+ else
+ {
+ /* We could handle non-*ABS* relocations with non-zero addends
+ by allocating dynamically an arg to hold a pointer to the
+ reloc, but that sounds pointless. */
+ const Elf32_Rel *const r = reloc;
+ /* The code below was borrowed from elf_dynamic_do_rel(). */
+ const ElfW(Sym) *const symtab =
+ (const void *) D_PTR (map, l_info[DT_SYMTAB]);
+
+#ifdef RTLD_BOOTSTRAP
+ /* The dynamic linker always uses versioning. */
+ assert (map->l_info[VERSYMIDX (DT_VERSYM)] != NULL);
+#else
+ if (map->l_info[VERSYMIDX (DT_VERSYM)])
+#endif
+ {
+ const ElfW(Half) *const version =
+ (const void *) D_PTR (map, l_info[VERSYMIDX (DT_VERSYM)]);
+ ElfW(Half) ndx = version[ELFW(R_SYM) (r->r_info)] & 0x7fff;
+ elf_machine_rel (map, r, &symtab[ELFW(R_SYM) (r->r_info)],
+ &map->l_versions[ndx],
+ (void *) (l_addr + r->r_offset));
+ }
+#ifndef RTLD_BOOTSTRAP
+ else
+ elf_machine_rel (map, r, &symtab[ELFW(R_SYM) (r->r_info)], NULL,
+ (void *) (l_addr + r->r_offset));
+#endif
+ }
+ }
else
_dl_reloc_bad_type (map, r_type, 1);
}
@@ -589,6 +704,20 @@ __attribute__ ((always_inline))
elf_machine_lazy_rela (struct link_map *map,
Elf32_Addr l_addr, const Elf32_Rela *reloc)
{
+ Elf32_Addr *const reloc_addr = (void *) (l_addr + reloc->r_offset);
+ const unsigned int r_type = ELF32_R_TYPE (reloc->r_info);
+ if (__builtin_expect (r_type == R_386_JMP_SLOT, 1))
+ ;
+ else if (__builtin_expect (r_type == R_386_TLS_DESC, 1))
+ {
+ struct tlsdesc volatile * __attribute__((__unused__)) td =
+ (struct tlsdesc volatile *)reloc_addr;
+
+ td->arg = (void*)reloc;
+ td->entry = _dl_tlsdesc_resolve_rela;
+ }
+ else
+ _dl_reloc_bad_type (map, r_type, 1);
}
#endif /* !RTLD_BOOTSTRAP */
diff --git a/libc/sysdeps/i386/dl-tls.h b/libc/sysdeps/i386/dl-tls.h
index a1707197c..58705c778 100644
--- a/libc/sysdeps/i386/dl-tls.h
+++ b/libc/sysdeps/i386/dl-tls.h
@@ -19,7 +19,7 @@
/* Type used for the representation of TLS information in the GOT. */
-typedef struct
+typedef struct dl_tls_index
{
unsigned long int ti_module;
unsigned long int ti_offset;
diff --git a/libc/sysdeps/i386/dl-tlsdesc.S b/libc/sysdeps/i386/dl-tlsdesc.S
new file mode 100644
index 000000000..db5005d9f
--- /dev/null
+++ b/libc/sysdeps/i386/dl-tlsdesc.S
@@ -0,0 +1,290 @@
+/* Thread-local storage handling in the ELF dynamic linker. i386 version.
+ Copyright (C) 2004, 2005, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <tls.h>
+#include "tlsdesc.h"
+
+ .text
+
+ /* This function is used to compute the TP offset for symbols in
+ Static TLS, i.e., whose TP offset is the same for all
+ threads.
+
+ The incoming %eax points to the TLS descriptor, such that
+ 0(%eax) points to _dl_tlsdesc_return itself, and 4(%eax) holds
+ the TP offset of the symbol corresponding to the object
+ denoted by the argument. */
+
+ .hidden _dl_tlsdesc_return
+ .global _dl_tlsdesc_return
+ .type _dl_tlsdesc_return,@function
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_return:
+ movl 4(%eax), %eax
+ ret
+ cfi_endproc
+ .size _dl_tlsdesc_return, .-_dl_tlsdesc_return
+
+ /* This function is used for undefined weak TLS symbols, for
+ which the base address (i.e., disregarding any addend) should
+ resolve to NULL.
+
+ %eax points to the TLS descriptor, such that 0(%eax) points to
+ _dl_tlsdesc_undefweak itself, and 4(%eax) holds the addend.
+ We return the addend minus the TP, such that, when the caller
+ adds TP, it gets the addend back. If that's zero, as usual,
+ that's most likely a NULL pointer. */
+
+ .hidden _dl_tlsdesc_undefweak
+ .global _dl_tlsdesc_undefweak
+ .type _dl_tlsdesc_undefweak,@function
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_undefweak:
+ movl 4(%eax), %eax
+ subl %gs:0, %eax
+ ret
+ cfi_endproc
+ .size _dl_tlsdesc_undefweak, .-_dl_tlsdesc_undefweak
+
+#ifdef SHARED
+ .hidden _dl_tlsdesc_dynamic
+ .global _dl_tlsdesc_dynamic
+ .type _dl_tlsdesc_dynamic,@function
+
+ /* This function is used for symbols that need dynamic TLS.
+
+ %eax points to the TLS descriptor, such that 0(%eax) points to
+ _dl_tlsdesc_dynamic itself, and 4(%eax) points to a struct
+ tlsdesc_dynamic_arg object. It must return in %eax the offset
+ between the thread pointer and the object denoted by the
+ argument, without clobbering any registers.
+
+ The assembly code that follows is a rendition of the following
+ C code, hand-optimized a little bit.
+
+ptrdiff_t
+__attribute__ ((__regparm__ (1)))
+_dl_tlsdesc_dynamic (struct tlsdesc *tdp)
+{
+ struct tlsdesc_dynamic_arg *td = tdp->arg;
+ dtv_t *dtv = *(dtv_t **)((char *)__thread_pointer + DTV_OFFSET);
+ if (__builtin_expect (td->gen_count <= dtv[0].counter
+ && (dtv[td->tlsinfo.ti_module].pointer.val
+ != TLS_DTV_UNALLOCATED),
+ 1))
+ return dtv[td->tlsinfo.ti_module].pointer.val + td->tlsinfo.ti_offset
+ - __thread_pointer;
+
+ return ___tls_get_addr (&td->tlsinfo) - __thread_pointer;
+}
+*/
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_dynamic:
+ /* Like all TLS resolvers, preserve call-clobbered registers.
+ We need two scratch regs anyway. */
+ subl $28, %esp
+ cfi_adjust_cfa_offset (28)
+ movl %ecx, 20(%esp)
+ movl %edx, 24(%esp)
+ movl TLSDESC_ARG(%eax), %eax
+ movl %gs:DTV_OFFSET, %edx
+ movl TLSDESC_GEN_COUNT(%eax), %ecx
+ cmpl (%edx), %ecx
+ ja .Lslow
+ movl TLSDESC_MODID(%eax), %ecx
+ movl (%edx,%ecx,8), %edx
+ cmpl $-1, %edx
+ je .Lslow
+ movl TLSDESC_MODOFF(%eax), %eax
+ addl %edx, %eax
+.Lret:
+ movl 20(%esp), %ecx
+ subl %gs:0, %eax
+ movl 24(%esp), %edx
+ addl $28, %esp
+ cfi_adjust_cfa_offset (-28)
+ ret
+ .p2align 4,,7
+.Lslow:
+ cfi_adjust_cfa_offset (28)
+ movl %ebx, 16(%esp)
+ call __i686.get_pc_thunk.bx
+ addl $_GLOBAL_OFFSET_TABLE_, %ebx
+ call ___tls_get_addr@PLT
+ movl 16(%esp), %ebx
+ jmp .Lret
+ cfi_endproc
+ .size _dl_tlsdesc_dynamic, .-_dl_tlsdesc_dynamic
+#endif /* SHARED */
+
+ /* This function is a wrapper for a lazy resolver for TLS_DESC
+ REL relocations that reference the *ABS* segment in their own
+ link maps. %ebx points to the caller's GOT. %eax points to a
+ TLS descriptor, such that 0(%eax) holds the address of the
+ resolver wrapper itself (unless some other thread beat us to
+ it) and 4(%eax) holds the addend in the relocation.
+
+ When the actual resolver returns, it will have adjusted the
+ TLS descriptor such that we can tail-call it for it to return
+ the TP offset of the symbol. */
+
+ .hidden _dl_tlsdesc_resolve_abs_plus_addend
+ .global _dl_tlsdesc_resolve_abs_plus_addend
+ .type _dl_tlsdesc_resolve_abs_plus_addend,@function
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_resolve_abs_plus_addend:
+0:
+ pushl %eax
+ cfi_adjust_cfa_offset (4)
+ pushl %ecx
+ cfi_adjust_cfa_offset (4)
+ pushl %edx
+ cfi_adjust_cfa_offset (4)
+ movl $1f - 0b, %ecx
+ movl 4(%ebx), %edx
+ call _dl_tlsdesc_resolve_abs_plus_addend_fixup
+1:
+ popl %edx
+ cfi_adjust_cfa_offset (-4)
+ popl %ecx
+ cfi_adjust_cfa_offset (-4)
+ popl %eax
+ cfi_adjust_cfa_offset (-4)
+ jmp *(%eax)
+ cfi_endproc
+ .size _dl_tlsdesc_resolve_abs_plus_addend, .-_dl_tlsdesc_resolve_abs_plus_addend
+
+ /* This function is a wrapper for a lazy resolver for TLS_DESC
+ REL relocations that had zero addends. %ebx points to the
+ caller's GOT. %eax points to a TLS descriptor, such that
+ 0(%eax) holds the address of the resolver wrapper itself
+ (unless some other thread beat us to it) and 4(%eax) holds a
+ pointer to the relocation.
+
+ When the actual resolver returns, it will have adjusted the
+ TLS descriptor such that we can tail-call it for it to return
+ the TP offset of the symbol. */
+
+ .hidden _dl_tlsdesc_resolve_rel
+ .global _dl_tlsdesc_resolve_rel
+ .type _dl_tlsdesc_resolve_rel,@function
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_resolve_rel:
+0:
+ pushl %eax
+ cfi_adjust_cfa_offset (4)
+ pushl %ecx
+ cfi_adjust_cfa_offset (4)
+ pushl %edx
+ cfi_adjust_cfa_offset (4)
+ movl $1f - 0b, %ecx
+ movl 4(%ebx), %edx
+ call _dl_tlsdesc_resolve_rel_fixup
+1:
+ popl %edx
+ cfi_adjust_cfa_offset (-4)
+ popl %ecx
+ cfi_adjust_cfa_offset (-4)
+ popl %eax
+ cfi_adjust_cfa_offset (-4)
+ jmp *(%eax)
+ cfi_endproc
+ .size _dl_tlsdesc_resolve_rel, .-_dl_tlsdesc_resolve_rel
+
+ /* This function is a wrapper for a lazy resolver for TLS_DESC
+ RELA relocations. %ebx points to the caller's GOT. %eax
+ points to a TLS descriptor, such that 0(%eax) holds the
+ address of the resolver wrapper itself (unless some other
+ thread beat us to it) and 4(%eax) holds a pointer to the
+ relocation.
+
+ When the actual resolver returns, it will have adjusted the
+ TLS descriptor such that we can tail-call it for it to return
+ the TP offset of the symbol. */
+
+ .hidden _dl_tlsdesc_resolve_rela
+ .global _dl_tlsdesc_resolve_rela
+ .type _dl_tlsdesc_resolve_rela,@function
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_resolve_rela:
+0:
+ pushl %eax
+ cfi_adjust_cfa_offset (4)
+ pushl %ecx
+ cfi_adjust_cfa_offset (4)
+ pushl %edx
+ cfi_adjust_cfa_offset (4)
+ movl $1f - 0b, %ecx
+ movl 4(%ebx), %edx
+ call _dl_tlsdesc_resolve_rela_fixup
+1:
+ popl %edx
+ cfi_adjust_cfa_offset (-4)
+ popl %ecx
+ cfi_adjust_cfa_offset (-4)
+ popl %eax
+ cfi_adjust_cfa_offset (-4)
+ jmp *(%eax)
+ cfi_endproc
+ .size _dl_tlsdesc_resolve_rela, .-_dl_tlsdesc_resolve_rela
+
+ /* This function is a placeholder for lazy resolving of TLS
+ relocations. Once some thread starts resolving a TLS
+ relocation, it sets up the TLS descriptor to use this
+ resolver, such that other threads that would attempt to
+ resolve it concurrently may skip the call to the original lazy
+ resolver and go straight to a condition wait.
+
+ When the actual resolver returns, it will have adjusted the
+ TLS descriptor such that we can tail-call it for it to return
+ the TP offset of the symbol. */
+
+ .hidden _dl_tlsdesc_resolve_hold
+ .global _dl_tlsdesc_resolve_hold
+ .type _dl_tlsdesc_resolve_hold,@function
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_resolve_hold:
+0:
+ pushl %eax
+ cfi_adjust_cfa_offset (4)
+ pushl %ecx
+ cfi_adjust_cfa_offset (4)
+ pushl %edx
+ cfi_adjust_cfa_offset (4)
+ movl $1f - 0b, %ecx
+ movl 4(%ebx), %edx
+ call _dl_tlsdesc_resolve_hold_fixup
+1:
+ popl %edx
+ cfi_adjust_cfa_offset (-4)
+ popl %ecx
+ cfi_adjust_cfa_offset (-4)
+ popl %eax
+ cfi_adjust_cfa_offset (-4)
+ jmp *(%eax)
+ cfi_endproc
+ .size _dl_tlsdesc_resolve_hold, .-_dl_tlsdesc_resolve_hold
diff --git a/libc/sysdeps/i386/dl-tlsdesc.h b/libc/sysdeps/i386/dl-tlsdesc.h
new file mode 100644
index 000000000..df4a646fe
--- /dev/null
+++ b/libc/sysdeps/i386/dl-tlsdesc.h
@@ -0,0 +1,61 @@
+/* Thread-local storage descriptor handling in the ELF dynamic linker.
+ i386 version.
+ Copyright (C) 2005, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _I386_DL_TLSDESC_H
+# define _I386_DL_TLSDESC_H 1
+
+/* Type used to represent a TLS descriptor in the GOT. */
+struct tlsdesc
+{
+ ptrdiff_t __attribute__ ((regparm (1))) (*entry) (struct tlsdesc *);
+ void *arg;
+};
+
+typedef struct dl_tls_index
+{
+ unsigned long int ti_module;
+ unsigned long int ti_offset;
+} tls_index;
+
+/* Type used as the argument in a TLS descriptor for a symbol that
+ needs dynamic TLS offsets. */
+struct tlsdesc_dynamic_arg
+{
+ tls_index tlsinfo;
+ size_t gen_count;
+};
+
+extern ptrdiff_t attribute_hidden __attribute__ ((regparm (1)))
+ _dl_tlsdesc_return (struct tlsdesc *),
+ _dl_tlsdesc_undefweak (struct tlsdesc *),
+ _dl_tlsdesc_resolve_abs_plus_addend (struct tlsdesc *),
+ _dl_tlsdesc_resolve_rel (struct tlsdesc *),
+ _dl_tlsdesc_resolve_rela (struct tlsdesc *),
+ _dl_tlsdesc_resolve_hold (struct tlsdesc *);
+
+# ifdef SHARED
+extern void *internal_function _dl_make_tlsdesc_dynamic (struct link_map *map,
+ size_t ti_offset);
+
+extern ptrdiff_t attribute_hidden __attribute__ ((regparm (1)))
+ _dl_tlsdesc_dynamic (struct tlsdesc *);
+# endif
+
+#endif
diff --git a/libc/sysdeps/i386/fpu/s_expm1l.S b/libc/sysdeps/i386/fpu/s_expm1l.S
index 2dc379b79..b69b22bc6 100644
--- a/libc/sysdeps/i386/fpu/s_expm1l.S
+++ b/libc/sysdeps/i386/fpu/s_expm1l.S
@@ -1,5 +1,5 @@
/* ix87 specific implementation of exp(x)-1.
- Copyright (C) 1996, 1997, 2002, 2005 Free Software Foundation, Inc.
+ Copyright (C) 1996, 1997, 2002, 2005, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
Based on code by John C. Bowman <bowman@ipp-garching.mpg.de>.
@@ -48,6 +48,11 @@ l2e: .tfloat 1.442695040888963407359924681002
.text
ENTRY(__expm1l)
+ movzwl 4+8(%esp), %eax // load sign bit and 15-bit exponent
+ xorb $0x80, %ah // invert sign bit (now 1 is "positive")
+ cmpl $0xc006, %eax // is num positive and exp >= 6 (number is >= 128.0)?
+ jae __ieee754_expl // (if num is denormal, it is at least >= 64.0)
+
fldt 4(%esp) // x
fxam // Is NaN or +-Inf?
fstsw %ax
diff --git a/libc/sysdeps/i386/i686/memcmp.S b/libc/sysdeps/i386/i686/memcmp.S
index 4fa6adea9..24f6804b0 100644
--- a/libc/sysdeps/i386/i686/memcmp.S
+++ b/libc/sysdeps/i386/i686/memcmp.S
@@ -29,8 +29,7 @@
#define ENTRANCE pushl %ebx; cfi_adjust_cfa_offset (4); \
cfi_rel_offset (ebx, 0); ENTER
#define RETURN popl %ebx; cfi_adjust_cfa_offset (-4); \
- cfi_restore (ebx); LEAVE; ret; \
- cfi_adjust_cfa_offset (4); cfi_rel_offset (ebx, 0);
+ cfi_restore (ebx); LEAVE; ret
/* Load an entry in a jump table into EBX. TABLE is a jump table
with relative offsets. INDEX is a register contains the index
@@ -71,6 +70,8 @@ L(bye):
xorl %eax, %eax
RETURN
+ cfi_adjust_cfa_offset (4)
+ cfi_rel_offset (ebx, 0)
L(neq):
sbbl %eax, %eax
sbbl $-1, %eax
diff --git a/libc/sysdeps/i386/i686/memcpy.S b/libc/sysdeps/i386/i686/memcpy.S
index 00e84ec2e..0b2da1ea2 100644
--- a/libc/sysdeps/i386/i686/memcpy.S
+++ b/libc/sysdeps/i386/i686/memcpy.S
@@ -1,7 +1,7 @@
/* Copy memory block and return pointer to beginning of destination block
For Intel 80x86, x>=6.
This file is part of the GNU C Library.
- Copyright (C) 1999, 2000, 2003, 2004 Free Software Foundation, Inc.
+ Copyright (C) 1999, 2000, 2003, 2004, 2008 Free Software Foundation, Inc.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1999.
The GNU C Library is free software; you can redistribute it and/or
@@ -41,29 +41,64 @@ END (__memcpy_chk)
ENTRY (BP_SYM (memcpy))
ENTER
- movl LEN(%esp), %ecx
movl %edi, %eax
movl DEST(%esp), %edi
movl %esi, %edx
movl SRC(%esp), %esi
- CHECK_BOUNDS_BOTH_WIDE (%edi, DEST(%esp), %ecx)
- CHECK_BOUNDS_BOTH_WIDE (%esi, SRC(%esp), %ecx)
+ movl %edi, %ecx
+ xorl %esi, %ecx
+ andl $3, %ecx
+ movl LEN(%esp), %ecx
cld
- shrl $1, %ecx
- jnc 1f
+ jne .Lunaligned
+
+ cmpl $3, %ecx
+ jbe .Lunaligned
+
+ testl $3, %esi
+ je 1f
movsb
-1: shrl $1, %ecx
- jnc 2f
- movsw
-2: rep
+ decl %ecx
+ testl $3, %esi
+ je 1f
+ movsb
+ decl %ecx
+ testl $3, %esi
+ je 1f
+ movsb
+ decl %ecx
+1: pushl %eax
+ movl %ecx, %eax
+ shrl $2, %ecx
+ andl $3, %eax
+ rep
movsl
- movl %eax, %edi
+ movl %eax, %ecx
+ rep
+ movsb
+ popl %eax
+
+.Lend: movl %eax, %edi
movl %edx, %esi
movl DEST(%esp), %eax
RETURN_BOUNDED_POINTER (DEST(%esp))
LEAVE
RET_PTR
+
+ /* When we come here the pointers do not have the same
+ alignment or the length is too short. No need to optimize for
+ aligned memory accesses. */
+.Lunaligned:
+ shrl $1, %ecx
+ jnc 1f
+ movsb
+1: shrl $1, %ecx
+ jnc 2f
+ movsw
+2: rep
+ movsl
+ jmp .Lend
END (BP_SYM (memcpy))
libc_hidden_builtin_def (memcpy)
diff --git a/libc/sysdeps/i386/tlsdesc.c b/libc/sysdeps/i386/tlsdesc.c
new file mode 100644
index 000000000..28287d574
--- /dev/null
+++ b/libc/sysdeps/i386/tlsdesc.c
@@ -0,0 +1,269 @@
+/* Manage TLS descriptors. i386 version.
+ Copyright (C) 2005, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <link.h>
+#include <ldsodefs.h>
+#include <elf/dynamic-link.h>
+#include <tls.h>
+#include <dl-tlsdesc.h>
+#include <tlsdeschtab.h>
+
+/* The following 4 functions take an entry_check_offset argument.
+ It's computed by the caller as an offset between its entry point
+ and the call site, such that by adding the built-in return address
+ that is implicitly passed to the function with this offset, we can
+ easily obtain the caller's entry point to compare with the entry
+ point given in the TLS descriptor. If it's changed, we want to
+ return immediately. */
+
+/* This function is used to lazily resolve TLS_DESC REL relocations
+ that reference the *ABS* segment in their own link maps. The
+ argument is the addend originally stored there. */
+
+void
+__attribute__ ((regparm (3))) attribute_hidden
+_dl_tlsdesc_resolve_abs_plus_addend_fixup (struct tlsdesc volatile *td,
+ struct link_map *l,
+ ptrdiff_t entry_check_offset)
+{
+ ptrdiff_t addend = (ptrdiff_t) td->arg;
+
+ if (_dl_tlsdesc_resolve_early_return_p (td, __builtin_return_address (0)
+ - entry_check_offset))
+ return;
+
+#ifndef SHARED
+ CHECK_STATIC_TLS (l, l);
+#else
+ if (!TRY_STATIC_TLS (l, l))
+ {
+ td->arg = _dl_make_tlsdesc_dynamic (l, addend);
+ td->entry = _dl_tlsdesc_dynamic;
+ }
+ else
+#endif
+ {
+ td->arg = (void*) (addend - l->l_tls_offset);
+ td->entry = _dl_tlsdesc_return;
+ }
+
+ _dl_tlsdesc_wake_up_held_fixups ();
+}
+
+/* This function is used to lazily resolve TLS_DESC REL relocations
+ that originally had zero addends. The argument location, that
+ originally held the addend, is used to hold a pointer to the
+ relocation, but it has to be restored before we call the function
+ that applies relocations. */
+
+void
+__attribute__ ((regparm (3))) attribute_hidden
+_dl_tlsdesc_resolve_rel_fixup (struct tlsdesc volatile *td,
+ struct link_map *l,
+ ptrdiff_t entry_check_offset)
+{
+ const ElfW(Rel) *reloc = td->arg;
+
+ if (_dl_tlsdesc_resolve_early_return_p (td, __builtin_return_address (0)
+ - entry_check_offset))
+ return;
+
+ /* The code below was borrowed from _dl_fixup(),
+ except for checking for STB_LOCAL. */
+ const ElfW(Sym) *const symtab
+ = (const void *) D_PTR (l, l_info[DT_SYMTAB]);
+ const char *strtab = (const void *) D_PTR (l, l_info[DT_STRTAB]);
+ const ElfW(Sym) *sym = &symtab[ELFW(R_SYM) (reloc->r_info)];
+ lookup_t result;
+
+ /* Look up the target symbol. If the normal lookup rules are not
+ used don't look in the global scope. */
+ if (ELFW(ST_BIND) (sym->st_info) != STB_LOCAL
+ && __builtin_expect (ELFW(ST_VISIBILITY) (sym->st_other), 0) == 0)
+ {
+ const struct r_found_version *version = NULL;
+
+ if (l->l_info[VERSYMIDX (DT_VERSYM)] != NULL)
+ {
+ const ElfW(Half) *vernum =
+ (const void *) D_PTR (l, l_info[VERSYMIDX (DT_VERSYM)]);
+ ElfW(Half) ndx = vernum[ELFW(R_SYM) (reloc->r_info)] & 0x7fff;
+ version = &l->l_versions[ndx];
+ if (version->hash == 0)
+ version = NULL;
+ }
+
+ result = _dl_lookup_symbol_x (strtab + sym->st_name, l, &sym,
+ l->l_scope, version, ELF_RTYPE_CLASS_PLT,
+ DL_LOOKUP_ADD_DEPENDENCY, NULL);
+ }
+ else
+ {
+ /* We already found the symbol. The module (and therefore its load
+ address) is also known. */
+ result = l;
+ }
+
+ if (!sym)
+ {
+ td->arg = 0;
+ td->entry = _dl_tlsdesc_undefweak;
+ }
+ else
+ {
+# ifndef SHARED
+ CHECK_STATIC_TLS (l, result);
+# else
+ if (!TRY_STATIC_TLS (l, result))
+ {
+ td->arg = _dl_make_tlsdesc_dynamic (result, sym->st_value);
+ td->entry = _dl_tlsdesc_dynamic;
+ }
+ else
+# endif
+ {
+ td->arg = (void*)(sym->st_value - result->l_tls_offset);
+ td->entry = _dl_tlsdesc_return;
+ }
+ }
+
+ _dl_tlsdesc_wake_up_held_fixups ();
+}
+
+/* This function is used to lazily resolve TLS_DESC RELA relocations.
+ The argument location is used to hold a pointer to the relocation. */
+
+void
+__attribute__ ((regparm (3))) attribute_hidden
+_dl_tlsdesc_resolve_rela_fixup (struct tlsdesc volatile *td,
+ struct link_map *l,
+ ptrdiff_t entry_check_offset)
+{
+ const ElfW(Rela) *reloc = td->arg;
+
+ if (_dl_tlsdesc_resolve_early_return_p (td, __builtin_return_address (0)
+ - entry_check_offset))
+ return;
+
+ /* The code below was borrowed from _dl_fixup(),
+ except for checking for STB_LOCAL. */
+ const ElfW(Sym) *const symtab
+ = (const void *) D_PTR (l, l_info[DT_SYMTAB]);
+ const char *strtab = (const void *) D_PTR (l, l_info[DT_STRTAB]);
+ const ElfW(Sym) *sym = &symtab[ELFW(R_SYM) (reloc->r_info)];
+ lookup_t result;
+
+ /* Look up the target symbol. If the normal lookup rules are not
+ used don't look in the global scope. */
+ if (ELFW(ST_BIND) (sym->st_info) != STB_LOCAL
+ && __builtin_expect (ELFW(ST_VISIBILITY) (sym->st_other), 0) == 0)
+ {
+ const struct r_found_version *version = NULL;
+
+ if (l->l_info[VERSYMIDX (DT_VERSYM)] != NULL)
+ {
+ const ElfW(Half) *vernum =
+ (const void *) D_PTR (l, l_info[VERSYMIDX (DT_VERSYM)]);
+ ElfW(Half) ndx = vernum[ELFW(R_SYM) (reloc->r_info)] & 0x7fff;
+ version = &l->l_versions[ndx];
+ if (version->hash == 0)
+ version = NULL;
+ }
+
+ result = _dl_lookup_symbol_x (strtab + sym->st_name, l, &sym,
+ l->l_scope, version, ELF_RTYPE_CLASS_PLT,
+ DL_LOOKUP_ADD_DEPENDENCY, NULL);
+ }
+ else
+ {
+ /* We already found the symbol. The module (and therefore its load
+ address) is also known. */
+ result = l;
+ }
+
+ if (!sym)
+ {
+ td->arg = (void*) reloc->r_addend;
+ td->entry = _dl_tlsdesc_undefweak;
+ }
+ else
+ {
+# ifndef SHARED
+ CHECK_STATIC_TLS (l, result);
+# else
+ if (!TRY_STATIC_TLS (l, result))
+ {
+ td->arg = _dl_make_tlsdesc_dynamic (result, sym->st_value
+ + reloc->r_addend);
+ td->entry = _dl_tlsdesc_dynamic;
+ }
+ else
+# endif
+ {
+ td->arg = (void*) (sym->st_value - result->l_tls_offset
+ + reloc->r_addend);
+ td->entry = _dl_tlsdesc_return;
+ }
+ }
+
+ _dl_tlsdesc_wake_up_held_fixups ();
+}
+
+/* This function is used to avoid busy waiting for other threads to
+ complete the lazy relocation. Once another thread wins the race to
+ relocate a TLS descriptor, it sets the descriptor up such that this
+ function is called to wait until the resolver releases the
+ lock. */
+
+void
+__attribute__ ((regparm (3))) attribute_hidden
+_dl_tlsdesc_resolve_hold_fixup (struct tlsdesc volatile *td,
+ struct link_map *l __attribute__((__unused__)),
+ ptrdiff_t entry_check_offset)
+{
+ /* Maybe we're lucky and can return early. */
+ if (__builtin_return_address (0) - entry_check_offset != td->entry)
+ return;
+
+ /* Locking here will stop execution until the running resolver runs
+ _dl_tlsdesc_wake_up_held_fixups(), releasing the lock.
+
+ FIXME: We'd be better off waiting on a condition variable, such
+ that we didn't have to hold the lock throughout the relocation
+ processing. */
+ __rtld_lock_lock_recursive (GL(dl_load_lock));
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+}
+
+
+/* Unmap the dynamic object, but also release its TLS descriptor table
+ if there is one. */
+
+void
+internal_function
+_dl_unmap (struct link_map *map)
+{
+ __munmap ((void *) (map)->l_map_start,
+ (map)->l_map_end - (map)->l_map_start);
+
+#if SHARED
+ if (map->l_mach.tlsdesc_table)
+ htab_delete (map->l_mach.tlsdesc_table);
+#endif
+}
diff --git a/libc/sysdeps/i386/tlsdesc.sym b/libc/sysdeps/i386/tlsdesc.sym
new file mode 100644
index 000000000..33854975d
--- /dev/null
+++ b/libc/sysdeps/i386/tlsdesc.sym
@@ -0,0 +1,17 @@
+#include <stddef.h>
+#include <sysdep.h>
+#include <tls.h>
+#include <link.h>
+#include <dl-tlsdesc.h>
+
+--
+
+-- Abuse tls.h macros to derive offsets relative to the thread register.
+
+DTV_OFFSET offsetof(struct pthread, header.dtv)
+
+TLSDESC_ARG offsetof(struct tlsdesc, arg)
+
+TLSDESC_GEN_COUNT offsetof(struct tlsdesc_dynamic_arg, gen_count)
+TLSDESC_MODID offsetof(struct tlsdesc_dynamic_arg, tlsinfo.ti_module)
+TLSDESC_MODOFF offsetof(struct tlsdesc_dynamic_arg, tlsinfo.ti_offset)
diff --git a/libc/sysdeps/ia64/bits/byteswap.h b/libc/sysdeps/ia64/bits/byteswap.h
index 6862aa0b6..d64914f36 100644
--- a/libc/sysdeps/ia64/bits/byteswap.h
+++ b/libc/sysdeps/ia64/bits/byteswap.h
@@ -1,5 +1,5 @@
/* Macros to swap the order of bytes in integer values.
- Copyright (C) 1997, 1998, 2000, 2002, 2003 Free Software Foundation, Inc.
+ Copyright (C) 1997,1998,2000,2002,2003,2008 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,7 +17,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#if !defined _BYTESWAP_H && !defined _NETINET_IN_H
+#if !defined _BYTESWAP_H && !defined _NETINET_IN_H && !defined _ENDIAN_H
# error "Never use <bits/byteswap.h> directly; include <byteswap.h> instead."
#endif
diff --git a/libc/sysdeps/ieee754/ldbl-128/e_j0l.c b/libc/sysdeps/ieee754/ldbl-128/e_j0l.c
index 67ef37115..bcd57e2b0 100644
--- a/libc/sysdeps/ieee754/ldbl-128/e_j0l.c
+++ b/libc/sysdeps/ieee754/ldbl-128/e_j0l.c
@@ -679,7 +679,7 @@ __ieee754_j0l (long double x)
{
long double xx, xinv, z, p, q, c, s, cc, ss;
- if (! finitel (x))
+ if (! __finitel (x))
{
if (x != x)
return x;
@@ -768,16 +768,15 @@ __ieee754_j0l (long double x)
= 1/sqrt(2) * (sin(x) - cos(x))
sin(x) +- cos(x) = -cos(2x)/(sin(x) -+ cos(x))
cf. Fdlibm. */
- c = cosl (xx);
- s = sinl (xx);
+ __sincosl (xx, &s, &c);
ss = s - c;
cc = s + c;
- z = -cosl (xx + xx);
+ z = -__cosl (xx + xx);
if ((s * c) < 0)
cc = z / ss;
else
ss = z / cc;
- z = ONEOSQPI * (p * cc - q * ss) / sqrtl (xx);
+ z = ONEOSQPI * (p * cc - q * ss) / __ieee754_sqrtl (xx);
return z;
}
@@ -817,7 +816,7 @@ long double
{
long double xx, xinv, z, p, q, c, s, cc, ss;
- if (! finitel (x))
+ if (! __finitel (x))
{
if (x != x)
return x;
@@ -836,7 +835,7 @@ long double
/* 0 <= x <= 2 */
z = xx * xx;
p = neval (z, Y0_2N, NY0_2N) / deval (z, Y0_2D, NY0_2D);
- p = TWOOPI * logl(x) * __ieee754_j0l(x) + p;
+ p = TWOOPI * __ieee754_logl (x) * __ieee754_j0l (x) + p;
return p;
}
@@ -908,15 +907,14 @@ long double
= 1/sqrt(2) * (sin(x) - cos(x))
sin(x) +- cos(x) = -cos(2x)/(sin(x) -+ cos(x))
cf. Fdlibm. */
- c = cosl (x);
- s = sinl (x);
+ __sincosl (x, &s, &c);
ss = s - c;
cc = s + c;
- z = -cosl (x + x);
+ z = -__cosl (x + x);
if ((s * c) < 0)
cc = z / ss;
else
ss = z / cc;
- z = ONEOSQPI * (p * ss + q * cc) / sqrtl (x);
+ z = ONEOSQPI * (p * ss + q * cc) / __ieee754_sqrtl (x);
return z;
}
diff --git a/libc/sysdeps/ieee754/ldbl-128/e_j1l.c b/libc/sysdeps/ieee754/ldbl-128/e_j1l.c
index 3a977c2a8..7b73e2e79 100644
--- a/libc/sysdeps/ieee754/ldbl-128/e_j1l.c
+++ b/libc/sysdeps/ieee754/ldbl-128/e_j1l.c
@@ -685,7 +685,7 @@ __ieee754_j1l (long double x)
{
long double xx, xinv, z, p, q, c, s, cc, ss;
- if (! finitel (x))
+ if (! __finitel (x))
{
if (x != x)
return x;
@@ -773,16 +773,15 @@ __ieee754_j1l (long double x)
sin(X) = sin(x) cos(3 pi/4) - cos(x) sin(3 pi/4)
= -1/sqrt(2) * (sin(x) + cos(x))
cf. Fdlibm. */
- c = cosl (xx);
- s = sinl (xx);
+ __sincosl (xx, &s, &c);
ss = -s - c;
cc = s - c;
- z = cosl (xx + xx);
+ z = __cosl (xx + xx);
if ((s * c) > 0)
cc = z / ss;
else
ss = z / cc;
- z = ONEOSQPI * (p * cc - q * ss) / sqrtl (xx);
+ z = ONEOSQPI * (p * cc - q * ss) / __ieee754_sqrtl (xx);
if (x < 0)
z = -z;
return z;
@@ -824,7 +823,7 @@ __ieee754_y1l (long double x)
{
long double xx, xinv, z, p, q, c, s, cc, ss;
- if (! finitel (x))
+ if (! __finitel (x))
{
if (x != x)
return x;
@@ -844,7 +843,7 @@ __ieee754_y1l (long double x)
z = xx * xx;
p = xx * neval (z, Y0_2N, NY0_2N) / deval (z, Y0_2D, NY0_2D);
p = -TWOOPI / xx + p;
- p = TWOOPI * logl(x) * __ieee754_j1l (x) + p;
+ p = TWOOPI * __ieee754_logl (x) * __ieee754_j1l (x) + p;
return p;
}
@@ -915,15 +914,14 @@ __ieee754_y1l (long double x)
sin(X) = sin(x) cos(3 pi/4) - cos(x) sin(3 pi/4)
= -1/sqrt(2) * (sin(x) + cos(x))
cf. Fdlibm. */
- c = cosl (xx);
- s = sinl (xx);
+ __sincosl (xx, &s, &c);
ss = -s - c;
cc = s - c;
- z = cosl (xx + xx);
+ z = __cosl (xx + xx);
if ((s * c) > 0)
cc = z / ss;
else
ss = z / cc;
- z = ONEOSQPI * (p * ss + q * cc) / sqrtl (xx);
+ z = ONEOSQPI * (p * ss + q * cc) / __ieee754_sqrtl (xx);
return z;
}
diff --git a/libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c b/libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
index b9302974c..d08044847 100644
--- a/libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
+++ b/libc/sysdeps/ieee754/ldbl-128/e_lgammal_r.c
@@ -772,6 +772,12 @@ __ieee754_lgammal_r (x, signgamp)
if (! __finitel (x))
return x * x;
+ if (x == 0.0L)
+ {
+ if (__signbitl (x))
+ *signgamp = -1;
+ }
+
if (x < 0.0L)
{
q = -x;
diff --git a/libc/sysdeps/ieee754/ldbl-128/s_expm1l.c b/libc/sysdeps/ieee754/ldbl-128/s_expm1l.c
index f373e1e6a..78bbe65b5 100644
--- a/libc/sysdeps/ieee754/ldbl-128/s_expm1l.c
+++ b/libc/sysdeps/ieee754/ldbl-128/s_expm1l.c
@@ -153,7 +153,7 @@ __expm1l (long double x)
exp(x) - 1 = 2^k (qx + 1) - 1
= 2^k qx + 2^k - 1. */
- px = ldexpl (1.0L, k);
+ px = __ldexpl (1.0L, k);
x = px * qx + (px - 1.0);
return x;
}
diff --git a/libc/sysdeps/ieee754/ldbl-128/s_log1pl.c b/libc/sysdeps/ieee754/ldbl-128/s_log1pl.c
index 64d514613..defbe76f5 100644
--- a/libc/sysdeps/ieee754/ldbl-128/s_log1pl.c
+++ b/libc/sysdeps/ieee754/ldbl-128/s_log1pl.c
@@ -120,13 +120,6 @@ static const long double maxlog = 1.1356523406294143949491931077970764891253E4L;
static const long double big = 2e4932L;
static const long double zero = 0.0L;
-#if 1
-/* Make sure these are prototyped. */
-long double frexpl (long double, int *);
-long double ldexpl (long double, int);
-#endif
-
-
long double
__log1pl (long double xm1)
{
@@ -160,7 +153,7 @@ __log1pl (long double xm1)
/* Separate mantissa from exponent. */
/* Use frexp used so that denormal numbers will be handled properly. */
- x = frexpl (x, &e);
+ x = __frexpl (x, &e);
/* Logarithm using log(x) = z + z^3 P(z^2)/Q(z^2),
where z = 2(x-1)/x+1). */
diff --git a/libc/sysdeps/ieee754/ldbl-128ibm/e_expl.c b/libc/sysdeps/ieee754/ldbl-128ibm/e_expl.c
index 3c4088f75..daf2cba32 100644
--- a/libc/sysdeps/ieee754/ldbl-128ibm/e_expl.c
+++ b/libc/sysdeps/ieee754/ldbl-128ibm/e_expl.c
@@ -1,5 +1,5 @@
/* Quad-precision floating point e^x.
- Copyright (C) 1999,2004,2006 Free Software Foundation, Inc.
+ Copyright (C) 1999,2004,2006, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Jakub Jelinek <jj@ultra.linux.cz>
Partly based on double-precision code
@@ -148,15 +148,15 @@ __ieee754_expl (long double x)
fesetround (FE_TONEAREST);
#endif
- n = roundl(x*M_1_LN2);
+ n = __roundl (x*M_1_LN2);
x = x-n*M_LN2_0;
xl = n*M_LN2_1;
- tval1 = roundl(x*TWO8);
+ tval1 = __roundl (x*TWO8);
x -= __expl_table[T_EXPL_ARG1+2*tval1];
xl -= __expl_table[T_EXPL_ARG1+2*tval1+1];
- tval2 = roundl(x*TWO15);
+ tval2 = __roundl (x*TWO15);
x -= __expl_table[T_EXPL_ARG2+2*tval2];
xl -= __expl_table[T_EXPL_ARG2+2*tval2+1];
diff --git a/libc/sysdeps/ieee754/ldbl-128ibm/s_expm1l.c b/libc/sysdeps/ieee754/ldbl-128ibm/s_expm1l.c
index 4908d4e4f..735006575 100644
--- a/libc/sysdeps/ieee754/ldbl-128ibm/s_expm1l.c
+++ b/libc/sysdeps/ieee754/ldbl-128ibm/s_expm1l.c
@@ -152,7 +152,7 @@ __expm1l (long double x)
exp(x) - 1 = 2^k (qx + 1) - 1
= 2^k qx + 2^k - 1. */
- px = ldexpl (1.0L, k);
+ px = __ldexpl (1.0L, k);
x = px * qx + (px - 1.0);
return x;
}
diff --git a/libc/sysdeps/ieee754/ldbl-128ibm/s_log1pl.c b/libc/sysdeps/ieee754/ldbl-128ibm/s_log1pl.c
index f1863fb68..5ccf541b7 100644
--- a/libc/sysdeps/ieee754/ldbl-128ibm/s_log1pl.c
+++ b/libc/sysdeps/ieee754/ldbl-128ibm/s_log1pl.c
@@ -121,12 +121,6 @@ static const long double maxlog = 1.1356523406294143949491931077970764891253E4L;
static const long double big = 2e300L;
static const long double zero = 0.0L;
-#if 1
-/* Make sure these are prototyped. */
-long double frexpl (long double, int *);
-long double ldexpl (long double, int);
-#endif
-
long double
__log1pl (long double xm1)
@@ -161,7 +155,7 @@ __log1pl (long double xm1)
/* Separate mantissa from exponent. */
/* Use frexp used so that denormal numbers will be handled properly. */
- x = frexpl (x, &e);
+ x = __frexpl (x, &e);
/* Logarithm using log(x) = z + z^3 P(z^2)/Q(z^2),
where z = 2(x-1)/x+1). */
diff --git a/libc/sysdeps/ieee754/ldbl-128ibm/s_nearbyintl.c b/libc/sysdeps/ieee754/ldbl-128ibm/s_nearbyintl.c
index 2561fda32..36c5a164d 100644
--- a/libc/sysdeps/ieee754/ldbl-128ibm/s_nearbyintl.c
+++ b/libc/sysdeps/ieee754/ldbl-128ibm/s_nearbyintl.c
@@ -1,6 +1,6 @@
/* Round to int long double floating-point values without raising inexact.
IBM extended format long double version.
- Copyright (C) 2006 Free Software Foundation, Inc.
+ Copyright (C) 2006, 2008 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
@@ -84,8 +84,8 @@ __nearbyintl (x)
{
/* Else the high double is pre rounded and we need to
adjust for that. */
-
- tau = nextafter (u.dd[0], 0.0);
+
+ tau = __nextafter (u.dd[0], 0.0);
tau = (u.dd[0] - tau) * 2.0;
high = u.dd[0] - tau;
low = u.dd[1] + tau;
@@ -106,7 +106,7 @@ __nearbyintl (x)
{
/* Else the high double is pre rounded and we need to
adjust for that. */
- tau = nextafter (u.dd[0], 0.0);
+ tau = __nextafter (u.dd[0], 0.0);
tau = (u.dd[0] - tau) * 2.0;
high = u.dd[0] - tau;
low = u.dd[1] + tau;
diff --git a/libc/sysdeps/mach/hurd/bits/fcntl.h b/libc/sysdeps/mach/hurd/bits/fcntl.h
index 2f890c1b6..b4147cee5 100644
--- a/libc/sysdeps/mach/hurd/bits/fcntl.h
+++ b/libc/sysdeps/mach/hurd/bits/fcntl.h
@@ -22,6 +22,8 @@
# error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
#endif
+#include <sys/types.h>
+
/* File access modes. These are understood by io servers; they can be
passed in `dir_lookup', and are returned by `io_get_openmodes'.
Consequently they can be passed to `open', `hurd_file_name_lookup', and
diff --git a/libc/sysdeps/mach/hurd/bits/ioctls.h b/libc/sysdeps/mach/hurd/bits/ioctls.h
index c9d313519..8718aacd8 100644
--- a/libc/sysdeps/mach/hurd/bits/ioctls.h
+++ b/libc/sysdeps/mach/hurd/bits/ioctls.h
@@ -25,6 +25,46 @@
/* These macros are also defined in <bits/termios.h> (with numerically
identical values) but this serves to shut up cpp's complaining. */
+
+#ifdef NL0
+# undef NL0
+#endif
+#ifdef NL1
+# undef NL1
+#endif
+#ifdef TAB0
+# undef TAB0
+#endif
+#ifdef TAB1
+# undef TAB1
+#endif
+#ifdef TAB2
+# undef TAB2
+#endif
+#ifdef CR0
+# undef CR0
+#endif
+#ifdef CR1
+# undef CR1
+#endif
+#ifdef CR2
+# undef CR2
+#endif
+#ifdef CR3
+# undef CR3
+#endif
+#ifdef FF0
+# undef FF0
+#endif
+#ifdef FF1
+# undef FF1
+#endif
+#ifdef BS0
+# undef BS0
+#endif
+#ifdef BS1
+# undef BS1
+#endif
#ifdef MDMBUF
# undef MDMBUF
#endif
@@ -284,31 +324,25 @@ enum __ioctl_datum { IOC_8, IOC_16, IOC_32, IOC_64 };
#define ODDP 0x00000040 /* get/send odd parity */
#define EVENP 0x00000080 /* get/send even parity */
#define ANYP 0x000000c0 /* get any parity/send none */
-#define NLDLY 0x00000300 /* \n delay */
-#define NLDELAY NLDLY /* traditional BSD name */
+#define NLDELAY 0x00000300 /* \n delay */
#define NL0 0x00000000
#define NL1 0x00000100 /* tty 37 */
#define NL2 0x00000200 /* vt05 */
#define NL3 0x00000300
-#define TABDLY 0x00000c00 /* horizontal tab delay */
-#define TBDELAY TABDLY /* traditional BSD name */
+#define TBDELAY 0x00000c00 /* horizontal tab delay */
#define TAB0 0x00000000
#define TAB1 0x00000400 /* tty 37 */
#define TAB2 0x00000800
-#define TAB3 0x00000c00
#define XTABS 0x00000c00 /* expand tabs on output */
-#define CRDLY 0x00003000 /* \r delay */
-#define CRDELAY CRDLY /* traditional BSD name */
+#define CRDELAY 0x00003000 /* \r delay */
#define CR0 0x00000000
#define CR1 0x00001000 /* tn 300 */
#define CR2 0x00002000 /* tty 37 */
#define CR3 0x00003000 /* concept 100 */
-#define VTDLY 0x00004000 /* vertical tab delay */
-#define VTDELAY VTDLY /* traditional BSD name */
+#define VTDELAY 0x00004000 /* vertical tab delay */
#define FF0 0x00000000
#define FF1 0x00004000 /* tty 37 */
-#define BSDLY 0x00008000 /* \b delay */
-#define BSDELAY BSDLY /* traditional BSD name */
+#define BSDELAY 0x00008000 /* \b delay */
#define BS0 0x00000000
#define BS1 0x00008000
#define ALLDELAY (NLDELAY|TBDELAY|CRDELAY|VTDELAY|BSDELAY)
diff --git a/libc/sysdeps/mach/hurd/dl-sysdep.c b/libc/sysdeps/mach/hurd/dl-sysdep.c
index 668aaaf8b..244068290 100644
--- a/libc/sysdeps/mach/hurd/dl-sysdep.c
+++ b/libc/sysdeps/mach/hurd/dl-sysdep.c
@@ -367,6 +367,7 @@ __libc_read (int fd, void *buf, size_t nbytes)
mach_msg_type_number_t nread;
data = buf;
+ nread = nbytes;
err = __io_read ((mach_port_t) fd, &data, &nread, -1, nbytes);
if (err)
return __hurd_fail (err);
diff --git a/libc/sysdeps/mach/hurd/open.c b/libc/sysdeps/mach/hurd/open.c
index bdfed5e31..519789f22 100644
--- a/libc/sysdeps/mach/hurd/open.c
+++ b/libc/sysdeps/mach/hurd/open.c
@@ -19,6 +19,7 @@
#include <errno.h>
#include <fcntl.h>
#include <stdarg.h>
+#include <stdio.h>
#include <hurd.h>
#include <hurd/fd.h>
@@ -52,8 +53,20 @@ weak_alias (__libc_open, __open)
libc_hidden_weak (__open)
weak_alias (__libc_open, open)
+int
+__open_2 (file, oflag)
+ const char *file;
+ int oflag;
+{
+ if (oflag & O_CREAT)
+ __fortify_fail ("invalid open call: O_CREAT without mode");
+
+ return __open (file, oflag);
+}
+
/* open64 is just the same as open for us. */
weak_alias (__libc_open, __libc_open64)
weak_alias (__libc_open, __open64)
libc_hidden_weak (_open64)
weak_alias (__libc_open, open64)
+strong_alias (__open_2, __open64_2)
diff --git a/libc/sysdeps/mach/hurd/openat.c b/libc/sysdeps/mach/hurd/openat.c
index 1faf857e1..f0a3404cd 100644
--- a/libc/sysdeps/mach/hurd/openat.c
+++ b/libc/sysdeps/mach/hurd/openat.c
@@ -21,6 +21,7 @@
#include <fcntl.h>
#include <stdarg.h>
#include <stddef.h>
+#include <stdio.h>
#include <sys/stat.h>
#include <hurd.h>
#include <hurd/fd.h>
@@ -56,7 +57,20 @@ __openat (fd, file, oflag)
libc_hidden_def (__openat)
weak_alias (__openat, openat)
+int
+__openat_2 (fd, file, oflag)
+ int fd;
+ const char *file;
+ int oflag;
+{
+ if (oflag & O_CREAT)
+ __fortify_fail ("invalid openat call: O_CREAT without mode");
+
+ return __openat (fd, file, oflag);
+}
+
/* openat64 is just the same as openat for us. */
weak_alias (__openat, __openat64)
libc_hidden_weak (__openat64)
weak_alias (__openat, openat64)
+strong_alias (__openat_2, __openat64_2)
diff --git a/libc/sysdeps/mach/hurd/recv.c b/libc/sysdeps/mach/hurd/recv.c
index b001729d1..0cf6b7ce5 100644
--- a/libc/sysdeps/mach/hurd/recv.c
+++ b/libc/sysdeps/mach/hurd/recv.c
@@ -38,7 +38,7 @@ __recv (fd, buf, n, flags)
char *bufp = buf;
mach_msg_type_number_t nread = n;
mach_port_t *ports;
- mach_msg_type_number_t nports;
+ mach_msg_type_number_t nports = 0;
char *cdata = NULL;
mach_msg_type_number_t clen = 0;
@@ -48,7 +48,7 @@ __recv (fd, buf, n, flags)
&cdata, &clen,
&flags,
n)))
- return __hurd_dfail (fd, err);
+ return __hurd_sockfail (fd, flags, err);
__mach_port_deallocate (__mach_task_self (), addrport);
__vm_deallocate (__mach_task_self (), (vm_address_t) cdata, clen);
diff --git a/libc/sysdeps/mach/hurd/recvfrom.c b/libc/sysdeps/mach/hurd/recvfrom.c
index d5c73f444..2aca5709d 100644
--- a/libc/sysdeps/mach/hurd/recvfrom.c
+++ b/libc/sysdeps/mach/hurd/recvfrom.c
@@ -41,7 +41,7 @@ __recvfrom (fd, buf, n, flags, addrarg, addr_len)
char *bufp = buf;
mach_msg_type_number_t nread = n;
mach_port_t *ports;
- mach_msg_type_number_t nports;
+ mach_msg_type_number_t nports = 0;
char *cdata = NULL;
mach_msg_type_number_t clen = 0;
struct sockaddr *addr = addrarg.__sockaddr__;
@@ -52,7 +52,7 @@ __recvfrom (fd, buf, n, flags, addrarg, addr_len)
&cdata, &clen,
&flags,
n)))
- return __hurd_dfail (fd, err);
+ return __hurd_sockfail (fd, flags, err);
/* Get address data for the returned address port if requested. */
if (addr != NULL)
@@ -74,7 +74,7 @@ __recvfrom (fd, buf, n, flags, addrarg, addr_len)
if (err)
{
__mach_port_deallocate (__mach_task_self (), addrport);
- return __hurd_dfail (fd, err);
+ return __hurd_sockfail (fd, flags, err);
}
if (*addr_len > buflen)
diff --git a/libc/sysdeps/mach/hurd/recvmsg.c b/libc/sysdeps/mach/hurd/recvmsg.c
index c6874e8bd..33897b8ce 100644
--- a/libc/sysdeps/mach/hurd/recvmsg.c
+++ b/libc/sysdeps/mach/hurd/recvmsg.c
@@ -34,7 +34,7 @@ __libc_recvmsg (int fd, struct msghdr *message, int flags)
char *data = NULL;
mach_msg_type_number_t len = 0;
mach_port_t *ports;
- mach_msg_type_number_t nports;
+ mach_msg_type_number_t nports = 0;
char *cdata = NULL;
mach_msg_type_number_t clen = 0;
size_t amount;
@@ -63,7 +63,7 @@ __libc_recvmsg (int fd, struct msghdr *message, int flags)
&ports, &nports,
&cdata, &clen,
&message->msg_flags, amount)))
- return __hurd_dfail (fd, err);
+ return __hurd_sockfail (fd, flags, err);
if (message->msg_name != NULL)
{
@@ -84,7 +84,7 @@ __libc_recvmsg (int fd, struct msghdr *message, int flags)
if (err)
{
__mach_port_deallocate (__mach_task_self (), aport);
- return __hurd_dfail (fd, err);
+ return __hurd_sockfail (fd, flags, err);
}
if (message->msg_namelen > buflen)
diff --git a/libc/sysdeps/mach/hurd/send.c b/libc/sysdeps/mach/hurd/send.c
index 4810cd68c..bb45c5069 100644
--- a/libc/sysdeps/mach/hurd/send.c
+++ b/libc/sysdeps/mach/hurd/send.c
@@ -38,7 +38,7 @@ __send (fd, buf, n, flags)
NULL, MACH_MSG_TYPE_COPY_SEND, 0,
NULL, 0, &wrote));
- return err ? __hurd_dfail (fd, err) : wrote;
+ return err ? __hurd_sockfail (fd, flags, err) : wrote;
}
libc_hidden_def (__send)
weak_alias (__send, send)
diff --git a/libc/sysdeps/mach/hurd/sendmsg.c b/libc/sysdeps/mach/hurd/sendmsg.c
index 5fdfd734e..a9d1c8c1d 100644
--- a/libc/sysdeps/mach/hurd/sendmsg.c
+++ b/libc/sysdeps/mach/hurd/sendmsg.c
@@ -149,7 +149,7 @@ __libc_sendmsg (int fd, const struct msghdr *message, int flags)
if (dealloc)
__vm_deallocate (__mach_task_self (), data.addr, len);
- return err ? __hurd_dfail (fd, err) : amount;
+ return err ? __hurd_sockfail (fd, flags, err) : amount;
}
weak_alias (__libc_sendmsg, sendmsg)
diff --git a/libc/sysdeps/mach/hurd/sendto.c b/libc/sysdeps/mach/hurd/sendto.c
index 0a6912a3b..478a5c9a4 100644
--- a/libc/sysdeps/mach/hurd/sendto.c
+++ b/libc/sysdeps/mach/hurd/sendto.c
@@ -79,7 +79,7 @@ __sendto (int fd,
err;
}));
- return err ? __hurd_dfail (fd, err) : wrote;
+ return err ? __hurd_sockfail (fd, flags, err) : wrote;
}
weak_alias (__sendto, sendto)
diff --git a/libc/sysdeps/mach/i386/machine-lock.h b/libc/sysdeps/mach/i386/machine-lock.h
index d78662817..33602f43a 100644
--- a/libc/sysdeps/mach/i386/machine-lock.h
+++ b/libc/sysdeps/mach/i386/machine-lock.h
@@ -1,5 +1,5 @@
/* Machine-specific definition for spin locks. i386 version.
- Copyright (C) 1994, 1997, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1994,1997,2007,2008 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
@@ -40,7 +40,8 @@ __spin_unlock (__spin_lock_t *__lock)
{
register int __unlocked;
__asm__ __volatile ("xchgl %0, %1"
- : "=&r" (__unlocked), "=m" (*__lock) : "0" (0));
+ : "=&r" (__unlocked), "=m" (*__lock) : "0" (0)
+ : "memory");
}
/* Try to lock LOCK; return nonzero if we locked it, zero if another has. */
@@ -50,7 +51,8 @@ __spin_try_lock (__spin_lock_t *__lock)
{
register int __locked;
__asm__ __volatile ("xchgl %0, %1"
- : "=&r" (__locked), "=m" (*__lock) : "0" (1));
+ : "=&r" (__locked), "=m" (*__lock) : "0" (1)
+ : "memory");
return !__locked;
}
diff --git a/libc/sysdeps/posix/clock_getres.c b/libc/sysdeps/posix/clock_getres.c
index f4dc21f8a..7d7cd05ff 100644
--- a/libc/sysdeps/posix/clock_getres.c
+++ b/libc/sysdeps/posix/clock_getres.c
@@ -1,5 +1,5 @@
/* clock_getres -- Get the resolution of a POSIX clockid_t.
- Copyright (C) 1999, 2000, 2001, 2003, 2004 Free Software Foundation, Inc.
+ Copyright (C) 1999,2000,2001,2003,2004,2008 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
@@ -28,7 +28,7 @@
#if HP_TIMING_AVAIL
static long int nsec; /* Clock frequency of the processor. */
-static inline int
+static int
hp_timing_getres (struct timespec *res)
{
if (__builtin_expect (nsec == 0, 0))
diff --git a/libc/sysdeps/posix/getaddrinfo.c b/libc/sysdeps/posix/getaddrinfo.c
index 9a27efdf8..97f3af993 100644
--- a/libc/sysdeps/posix/getaddrinfo.c
+++ b/libc/sysdeps/posix/getaddrinfo.c
@@ -40,6 +40,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <errno.h>
#include <ifaddrs.h>
#include <netdb.h>
+#include <nss.h>
#include <resolv.h>
#include <stdbool.h>
#include <stdio.h>
@@ -60,6 +61,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <not-cancel.h>
#include <nscd/nscd-client.h>
#include <nscd/nscd_proto.h>
+#include <resolv/res_hconf.h>
#ifdef HAVE_LIBIDN
extern int __idna_to_ascii_lz (const char *input, char **output, int flags);
@@ -91,21 +93,14 @@ struct gaih_servtuple
static const struct gaih_servtuple nullserv;
-struct gaih_addrtuple
- {
- struct gaih_addrtuple *next;
- char *name;
- int family;
- uint32_t addr[4];
- uint32_t scopeid;
- };
struct gaih_typeproto
{
int socktype;
int protocol;
- char name[4];
- int protoflag;
+ uint8_t protoflag;
+ bool defaultflag;
+ char name[8];
};
/* Values for `protoflag'. */
@@ -114,11 +109,21 @@ struct gaih_typeproto
static const struct gaih_typeproto gaih_inet_typeproto[] =
{
- { 0, 0, "", 0 },
- { SOCK_STREAM, IPPROTO_TCP, "tcp", 0 },
- { SOCK_DGRAM, IPPROTO_UDP, "udp", 0 },
- { SOCK_RAW, 0, "raw", GAI_PROTO_PROTOANY|GAI_PROTO_NOSERVICE },
- { 0, 0, "", 0 }
+ { 0, 0, 0, false, "" },
+ { SOCK_STREAM, IPPROTO_TCP, 0, true, "tcp" },
+ { SOCK_DGRAM, IPPROTO_UDP, 0, true, "udp" },
+#if defined SOCK_DCCP && defined IPPROTO_DCCP
+ { SOCK_DCCP, IPPROTO_DCCP, 0, false, "dccp" },
+#endif
+#ifdef IPPROTO_UDPLITE
+ { SOCK_DGRAM, IPPROTO_UDPLITE, 0, false, "udplite" },
+#endif
+#ifdef IPPROTO_SCTP
+ { SOCK_STREAM, IPPROTO_SCTP, 0, false, "sctp" },
+ { SOCK_SEQPACKET, IPPROTO_SCTP, 0, false, "sctp" },
+#endif
+ { SOCK_RAW, 0, GAI_PROTO_PROTOANY|GAI_PROTO_NOSERVICE, true, "raw" },
+ { 0, 0, 0, false, "" }
};
struct gaih
@@ -202,6 +207,7 @@ gaih_inet_serv (const char *servicename, const struct gaih_typeproto *tp,
if (herrno == NETDB_INTERNAL) \
{ \
__set_h_errno (herrno); \
+ _res.options = old_res_options; \
return -EAI_SYSTEM; \
} \
if (herrno == TRY_AGAIN) \
@@ -246,6 +252,10 @@ gaih_inet_serv (const char *servicename, const struct gaih_typeproto *tp,
}
+typedef enum nss_status (*nss_gethostbyname4_r)
+ (const char *name, struct gaih_addrtuple **pat,
+ char *buffer, size_t buflen, int *errnop,
+ int *h_errnop, int32_t *ttlp);
typedef enum nss_status (*nss_gethostbyname3_r)
(const char *name, int af, struct hostent *host,
char *buffer, size_t buflen, int *errnop,
@@ -365,18 +375,19 @@ gaih_inet (const char *name, const struct gaih_service *service,
we know about. */
struct gaih_servtuple **lastp = &st;
for (++tp; tp->name[0]; ++tp)
- {
- struct gaih_servtuple *newp;
+ if (tp->defaultflag)
+ {
+ struct gaih_servtuple *newp;
- newp = __alloca (sizeof (struct gaih_servtuple));
- newp->next = NULL;
- newp->socktype = tp->socktype;
- newp->protocol = tp->protocol;
- newp->port = port;
+ newp = __alloca (sizeof (struct gaih_servtuple));
+ newp->next = NULL;
+ newp->socktype = tp->socktype;
+ newp->protocol = tp->protocol;
+ newp->port = port;
- *lastp = newp;
- lastp = &newp->next;
- }
+ *lastp = newp;
+ lastp = &newp->next;
+ }
}
}
@@ -649,7 +660,10 @@ gaih_inet (const char *name, const struct gaih_service *service,
goto process_list;
}
- else if (err != 0 && __nss_not_use_nscd_hosts == 0)
+ else if (err == 0)
+ /* The database contains a negative entry. */
+ return 0;
+ else if (__nss_not_use_nscd_hosts == 0)
{
if (herrno == NETDB_INTERNAL && errno == ENOMEM)
return -EAI_MEMORY;
@@ -670,6 +684,9 @@ gaih_inet (const char *name, const struct gaih_service *service,
"dns [!UNAVAIL=return] files",
&nip);
+ /* Initialize configurations. */
+ if (__builtin_expect (!_res_hconf.initialized, 0))
+ _res_hconf_init ();
if (__res_maybe_init (&_res, 0) == -1)
no_more = 1;
@@ -680,92 +697,138 @@ gaih_inet (const char *name, const struct gaih_service *service,
old_res_options = _res.options;
_res.options &= ~RES_USE_INET6;
- size_t tmpbuflen = 512;
+ size_t tmpbuflen = 1024;
char *tmpbuf = alloca (tmpbuflen);
while (!no_more)
{
- nss_gethostbyname3_r fct = NULL;
- if (req->ai_flags & AI_CANONNAME)
- /* No need to use this function if we do not look for
- the canonical name. The function does not exist in
- all NSS modules and therefore the lookup would
- often fail. */
- fct = __nss_lookup_function (nip, "gethostbyname3_r");
- if (fct == NULL)
- /* We are cheating here. The gethostbyname2_r function does
- not have the same interface as gethostbyname3_r but the
- extra arguments the latter takes are added at the end.
- So the gethostbyname2_r code will just ignore them. */
- fct = __nss_lookup_function (nip, "gethostbyname2_r");
-
- if (fct != NULL)
+ nss_gethostbyname4_r fct4
+ = __nss_lookup_function (nip, "gethostbyname4_r");
+ if (fct4 != NULL)
{
- if (req->ai_family == AF_INET6
- || req->ai_family == AF_UNSPEC)
+ int herrno;
+
+ while (1)
{
- gethosts (AF_INET6, struct in6_addr);
- no_inet6_data = no_data;
- inet6_status = status;
+ rc = 0;
+ status = DL_CALL_FCT (fct4, (name, pat, tmpbuf,
+ tmpbuflen, &rc, &herrno,
+ NULL));
+ if (status != NSS_STATUS_TRYAGAIN
+ || rc != ERANGE || herrno != NETDB_INTERNAL)
+ {
+ if (herrno == NETDB_INTERNAL)
+ {
+ __set_h_errno (herrno);
+ _res.options = old_res_options;
+ return -EAI_SYSTEM;
+ }
+ if (herrno == TRY_AGAIN)
+ no_data = EAI_AGAIN;
+ else
+ no_data = herrno == NO_DATA;
+ break;
+ }
+ tmpbuf = extend_alloca (tmpbuf,
+ tmpbuflen, 2 * tmpbuflen);
}
- if (req->ai_family == AF_INET
- || req->ai_family == AF_UNSPEC
- || (req->ai_family == AF_INET6
- && (req->ai_flags & AI_V4MAPPED)
- /* Avoid generating the mapped addresses if we
- know we are not going to need them. */
- && ((req->ai_flags & AI_ALL) || !got_ipv6)))
+
+ if (status == NSS_STATUS_SUCCESS)
{
- gethosts (AF_INET, struct in_addr);
+ if ((req->ai_flags & AI_CANONNAME) != 0 && canon == NULL)
+ canon = (*pat)->name;
- if (req->ai_family == AF_INET)
+ while (*pat != NULL)
+ pat = &((*pat)->next);
+ }
+ }
+ else
+ {
+ nss_gethostbyname3_r fct = NULL;
+ if (req->ai_flags & AI_CANONNAME)
+ /* No need to use this function if we do not look for
+ the canonical name. The function does not exist in
+ all NSS modules and therefore the lookup would
+ often fail. */
+ fct = __nss_lookup_function (nip, "gethostbyname3_r");
+ if (fct == NULL)
+ /* We are cheating here. The gethostbyname2_r
+ function does not have the same interface as
+ gethostbyname3_r but the extra arguments the
+ latter takes are added at the end. So the
+ gethostbyname2_r code will just ignore them. */
+ fct = __nss_lookup_function (nip, "gethostbyname2_r");
+
+ if (fct != NULL)
+ {
+ if (req->ai_family == AF_INET6
+ || req->ai_family == AF_UNSPEC)
{
+ gethosts (AF_INET6, struct in6_addr);
no_inet6_data = no_data;
inet6_status = status;
}
- }
-
- /* If we found one address for AF_INET or AF_INET6,
- don't continue the search. */
- if (inet6_status == NSS_STATUS_SUCCESS
- || status == NSS_STATUS_SUCCESS)
- {
- if ((req->ai_flags & AI_CANONNAME) != 0 && canon == NULL)
+ if (req->ai_family == AF_INET
+ || req->ai_family == AF_UNSPEC
+ || (req->ai_family == AF_INET6
+ && (req->ai_flags & AI_V4MAPPED)
+ /* Avoid generating the mapped addresses if we
+ know we are not going to need them. */
+ && ((req->ai_flags & AI_ALL) || !got_ipv6)))
{
- /* If we need the canonical name, get it
- from the same service as the result. */
- nss_getcanonname_r cfct;
- int herrno;
+ gethosts (AF_INET, struct in_addr);
- cfct = __nss_lookup_function (nip, "getcanonname_r");
- if (cfct != NULL)
+ if (req->ai_family == AF_INET)
{
- const size_t max_fqdn_len = 256;
- char *buf = alloca (max_fqdn_len);
- char *s;
-
- if (DL_CALL_FCT (cfct, (at->name ?: name, buf,
- max_fqdn_len, &s, &rc,
- &herrno))
- == NSS_STATUS_SUCCESS)
- canon = s;
- else
- /* Set to name now to avoid using
- gethostbyaddr. */
- canon = name;
+ no_inet6_data = no_data;
+ inet6_status = status;
}
}
- break;
- }
+ /* If we found one address for AF_INET or AF_INET6,
+ don't continue the search. */
+ if (inet6_status == NSS_STATUS_SUCCESS
+ || status == NSS_STATUS_SUCCESS)
+ {
+ if ((req->ai_flags & AI_CANONNAME) != 0
+ && canon == NULL)
+ {
+ /* If we need the canonical name, get it
+ from the same service as the result. */
+ nss_getcanonname_r cfct;
+ int herrno;
+
+ cfct = __nss_lookup_function (nip,
+ "getcanonname_r");
+ if (cfct != NULL)
+ {
+ const size_t max_fqdn_len = 256;
+ char *buf = alloca (max_fqdn_len);
+ char *s;
+
+ if (DL_CALL_FCT (cfct, (at->name ?: name,
+ buf, max_fqdn_len,
+ &s, &rc, &herrno))
+ == NSS_STATUS_SUCCESS)
+ canon = s;
+ else
+ /* Set to name now to avoid using
+ gethostbyaddr. */
+ canon = name;
+ }
+ }
- /* We can have different states for AF_INET and
- AF_INET6. Try to find a useful one for both. */
- if (inet6_status == NSS_STATUS_TRYAGAIN)
- status = NSS_STATUS_TRYAGAIN;
- else if (status == NSS_STATUS_UNAVAIL
- && inet6_status != NSS_STATUS_UNAVAIL)
- status = inet6_status;
+ break;
+ }
+
+ /* We can have different states for AF_INET and
+ AF_INET6. Try to find a useful one for both. */
+ if (inet6_status == NSS_STATUS_TRYAGAIN)
+ status = NSS_STATUS_TRYAGAIN;
+ else if (status == NSS_STATUS_UNAVAIL
+ && inet6_status != NSS_STATUS_UNAVAIL)
+ status = inet6_status;
+ }
}
if (nss_next_action (nip, status) == NSS_ACTION_RETURN)
@@ -823,9 +886,6 @@ gaih_inet (const char *name, const struct gaih_service *service,
}
}
- if (pai == NULL)
- return 0;
-
{
struct gaih_servtuple *st2;
struct gaih_addrtuple *at2 = at;
@@ -897,7 +957,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
return -EAI_IDN_ENCODE;
}
/* In case the output string is the same as the input
- string no new string has been allocated. Otherwise
+ string no new string has been allocated and we
make a copy. */
if (out == canon)
goto make_copy;
@@ -1056,7 +1116,10 @@ get_scope (const struct sockaddr_in6 *in6)
{
if (! IN6_IS_ADDR_MULTICAST (&in6->sin6_addr))
{
- if (IN6_IS_ADDR_LINKLOCAL (&in6->sin6_addr))
+ if (IN6_IS_ADDR_LINKLOCAL (&in6->sin6_addr)
+ /* RFC 4291 2.5.3 says that the loopback address is to be
+ treated like a link-local address. */
+ || IN6_IS_ADDR_LOOPBACK (&in6->sin6_addr))
scope = 2;
else if (IN6_IS_ADDR_SITELOCAL (&in6->sin6_addr))
scope = 5;
@@ -1189,20 +1252,14 @@ match_prefix (const struct sockaddr_in6 *in6,
{
const struct sockaddr_in *in = (const struct sockaddr_in *) in6;
- /* Convert to IPv6 address. */
+ /* Construct a V4-to-6 mapped address. */
in6_mem.sin6_family = PF_INET6;
in6_mem.sin6_port = in->sin_port;
in6_mem.sin6_flowinfo = 0;
- if (in->sin_addr.s_addr == htonl (0x7f000001))
- in6_mem.sin6_addr = (struct in6_addr) IN6ADDR_LOOPBACK_INIT;
- else
- {
- /* Construct a V4-to-6 mapped address. */
- memset (&in6_mem.sin6_addr, '\0', sizeof (in6_mem.sin6_addr));
- in6_mem.sin6_addr.s6_addr16[5] = 0xffff;
- in6_mem.sin6_addr.s6_addr32[3] = in->sin_addr.s_addr;
- in6_mem.sin6_scope_id = 0;
- }
+ memset (&in6_mem.sin6_addr, '\0', sizeof (in6_mem.sin6_addr));
+ in6_mem.sin6_addr.s6_addr16[5] = 0xffff;
+ in6_mem.sin6_addr.s6_addr32[3] = in->sin_addr.s_addr;
+ in6_mem.sin6_scope_id = 0;
in6 = &in6_mem;
}
@@ -2088,11 +2145,7 @@ getaddrinfo (const char *name, const char *service,
else
pservice = NULL;
- struct addrinfo **end;
- if (pai)
- end = &p;
- else
- end = NULL;
+ struct addrinfo **end = &p;
unsigned int naddrs = 0;
if (hints->ai_family == AF_UNSPEC || hints->ai_family == AF_INET
@@ -2106,12 +2159,11 @@ getaddrinfo (const char *name, const char *service,
return -(last_i & GAIH_EAI);
}
- if (end)
- while (*end)
- {
- end = &((*end)->ai_next);
- ++nresults;
- }
+ while (*end)
+ {
+ end = &((*end)->ai_next);
+ ++nresults;
+ }
}
else
{
@@ -2307,9 +2359,6 @@ getaddrinfo (const char *name, const char *service,
return 0;
}
- if (pai == NULL && last_i == 0)
- return 0;
-
return last_i ? -(last_i & GAIH_EAI) : EAI_NONAME;
}
libc_hidden_def (getaddrinfo)
diff --git a/libc/sysdeps/powerpc/bits/fenv.h b/libc/sysdeps/powerpc/bits/fenv.h
index dc70d9117..14447b5f4 100644
--- a/libc/sysdeps/powerpc/bits/fenv.h
+++ b/libc/sysdeps/powerpc/bits/fenv.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997, 1998, 1999, 2004, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 1998, 1999, 2004, 2006,2008 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
@@ -196,6 +196,8 @@ extern const fenv_t __fe_enabled_env;
extern const fenv_t __fe_nonieee_env;
# define FE_NONIEEE_ENV (&__fe_nonieee_env)
+__BEGIN_DECLS
+
/* Floating-point environment with all exceptions enabled. Note that
just evaluating this value does not change the processor exception mode.
Passing this mask to fesetenv will result in a prctl syscall to change
@@ -212,6 +214,9 @@ extern const fenv_t *__fe_nomask_env (void);
this allows the fastest possible floating point execution.*/
extern const fenv_t *__fe_mask_env (void);
# define FE_MASK_ENV FE_DFL_ENV
+
+__END_DECLS
+
#endif
#endif
diff --git a/libc/sysdeps/powerpc/dl-procinfo.c b/libc/sysdeps/powerpc/dl-procinfo.c
index a732e94fa..1c74c2a90 100644
--- a/libc/sysdeps/powerpc/dl-procinfo.c
+++ b/libc/sysdeps/powerpc/dl-procinfo.c
@@ -46,11 +46,12 @@
#if !defined PROCINFO_DECL && defined SHARED
._dl_powerpc_cap_flags
#else
-PROCINFO_CLASS const char _dl_powerpc_cap_flags[23][10]
+PROCINFO_CLASS const char _dl_powerpc_cap_flags[25][10]
#endif
#ifndef PROCINFO_DECL
= {
- "power6x", "dfp", "pa6t",
+ "vsx",
+ "arch_2_06", "power6x", "dfp", "pa6t",
"arch_2_05", "ic_snoop", "smt", "booke",
"cellbe", "power5+", "power5", "power4",
"notb", "efpdouble", "efpsingle", "spe",
@@ -67,7 +68,7 @@ PROCINFO_CLASS const char _dl_powerpc_cap_flags[23][10]
#if !defined PROCINFO_DECL && defined SHARED
._dl_powerpc_platforms
#else
-PROCINFO_CLASS const char _dl_powerpc_platforms[7][12]
+PROCINFO_CLASS const char _dl_powerpc_platforms[8][12]
#endif
#ifndef PROCINFO_DECL
= {
@@ -77,7 +78,8 @@ PROCINFO_CLASS const char _dl_powerpc_platforms[7][12]
[PPC_PLATFORM_POWER5_PLUS] = "power5+",
[PPC_PLATFORM_POWER6] = "power6",
[PPC_PLATFORM_CELL_BE] = "ppc-cell-be",
- [PPC_PLATFORM_POWER6X] = "power6x"
+ [PPC_PLATFORM_POWER6X] = "power6x",
+ [PPC_PLATFORM_POWER7] = "power7"
}
#endif
#if !defined SHARED || defined PROCINFO_DECL
diff --git a/libc/sysdeps/powerpc/dl-procinfo.h b/libc/sysdeps/powerpc/dl-procinfo.h
index 0bf935385..254195a94 100644
--- a/libc/sysdeps/powerpc/dl-procinfo.h
+++ b/libc/sysdeps/powerpc/dl-procinfo.h
@@ -23,15 +23,15 @@
#include <ldsodefs.h>
#include <sysdep.h> /* This defines the PPC_FEATURE_* macros. */
-/* There are 20 bits used, but they are bits 12..31. */
-#define _DL_HWCAP_FIRST 9
+/* There are 25 bits used, but they are bits 7..31. */
+#define _DL_HWCAP_FIRST 7
#define _DL_HWCAP_COUNT 32
/* These bits influence library search. */
#define HWCAP_IMPORTANT (PPC_FEATURE_HAS_ALTIVEC \
+ PPC_FEATURE_HAS_DFP)
-#define _DL_PLATFORMS_COUNT 7
+#define _DL_PLATFORMS_COUNT 8
#define _DL_FIRST_PLATFORM 32
/* Mask to filter out platforms. */
@@ -46,6 +46,7 @@
#define PPC_PLATFORM_POWER6 4
#define PPC_PLATFORM_CELL_BE 5
#define PPC_PLATFORM_POWER6X 6
+#define PPC_PLATFORM_POWER7 7
static inline const char *
__attribute__ ((unused))
@@ -103,6 +104,9 @@ _dl_string_platform (const char *str)
++str;
}
break;
+ case '7':
+ ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER7;
+ break;
default:
return -1;
}
diff --git a/libc/sysdeps/powerpc/fpu/Makefile b/libc/sysdeps/powerpc/fpu/Makefile
index 060c952d1..ce67ff87d 100644
--- a/libc/sysdeps/powerpc/fpu/Makefile
+++ b/libc/sysdeps/powerpc/fpu/Makefile
@@ -1,5 +1,6 @@
ifeq ($(subdir),math)
libm-support += fenv_const fe_nomask fe_mask t_sqrt
+libm-tests += test-powerpc-snan
# libm needs ld.so to access dl_hwcap
$(objpfx)libm.so: $(elfobjdir)/ld.so
diff --git a/libc/sysdeps/powerpc/fpu/bits/mathinline.h b/libc/sysdeps/powerpc/fpu/bits/mathinline.h
index c5d458582..0f3c4a025 100644
--- a/libc/sysdeps/powerpc/fpu/bits/mathinline.h
+++ b/libc/sysdeps/powerpc/fpu/bits/mathinline.h
@@ -1,5 +1,5 @@
/* Inline math functions for powerpc.
- Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2004, 2006, 2007
+ Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2004, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -72,6 +72,14 @@ __NTH (__signbit (double __x))
__extension__ union { double __d; int __i[2]; } __u = { __d: __x };
return __u.__i[0] < 0;
}
+# ifdef __LONG_DOUBLE_128__
+__MATH_INLINE int
+__NTH (__signbitl (long double __x))
+{
+ __extension__ union { long double __d; int __i[4]; } __u = { __d: __x };
+ return __u.__i[0] < 0;
+}
+# endif
# endif
#endif /* __USE_ISOC99 */
diff --git a/libc/sysdeps/powerpc/fpu/e_sqrt.c b/libc/sysdeps/powerpc/fpu/e_sqrt.c
index 540b92465..24e0dd352 100644
--- a/libc/sysdeps/powerpc/fpu/e_sqrt.c
+++ b/libc/sysdeps/powerpc/fpu/e_sqrt.c
@@ -1,5 +1,5 @@
/* Double-precision floating point square root.
- Copyright (C) 1997, 2002, 2003, 2004 Free Software Foundation, Inc.
+ Copyright (C) 1997, 2002, 2003, 2004, 2008 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
@@ -150,7 +150,9 @@ __slow_ieee754_sqrt (x)
FE_INVALID_SQRT. */
#ifdef FE_INVALID_SQRT
feraiseexcept (FE_INVALID_SQRT);
- if (!fetestexcept (FE_INVALID))
+
+ fenv_union_t u = { .fenv = fegetenv_register () };
+ if ((u.l[1] & FE_INVALID) == 0)
#endif
feraiseexcept (FE_INVALID);
x = a_nan.value;
@@ -172,7 +174,7 @@ __ieee754_sqrt (x)
/* If the CPU is 64-bit we can use the optional FP instructions. */
if (__CPU_HAS_FSQRT)
{
- /* Volatile is required to prevent the compiler from moving the
+ /* Volatile is required to prevent the compiler from moving the
fsqrt instruction above the branch. */
__asm __volatile (" fsqrt %0,%1\n"
:"=f" (z):"f" (x));
diff --git a/libc/sysdeps/powerpc/fpu/e_sqrtf.c b/libc/sysdeps/powerpc/fpu/e_sqrtf.c
index b63d31472..8e8138a17 100644
--- a/libc/sysdeps/powerpc/fpu/e_sqrtf.c
+++ b/libc/sysdeps/powerpc/fpu/e_sqrtf.c
@@ -1,5 +1,5 @@
/* Single-precision floating point square root.
- Copyright (C) 1997, 2003, 2004 Free Software Foundation, Inc.
+ Copyright (C) 1997, 2003, 2004, 2008 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
@@ -126,7 +126,9 @@ __slow_ieee754_sqrtf (x)
FE_INVALID_SQRT. */
#ifdef FE_INVALID_SQRT
feraiseexcept (FE_INVALID_SQRT);
- if (!fetestexcept (FE_INVALID))
+
+ fenv_union_t u = { .fenv = fegetenv_register () };
+ if ((u.l[1] & FE_INVALID) == 0)
#endif
feraiseexcept (FE_INVALID);
x = a_nan.value;
@@ -149,7 +151,7 @@ __ieee754_sqrtf (x)
/* If the CPU is 64-bit we can use the optional FP instructions. */
if (__CPU_HAS_FSQRT)
{
- /* Volatile is required to prevent the compiler from moving the
+ /* Volatile is required to prevent the compiler from moving the
fsqrt instruction above the branch. */
__asm __volatile (" fsqrts %0,%1\n"
:"=f" (z):"f" (x));
diff --git a/libc/sysdeps/powerpc/fpu/fe_nomask.c b/libc/sysdeps/powerpc/fpu/fe_nomask.c
index 3cccee1d0..bc18bb8f8 100644
--- a/libc/sysdeps/powerpc/fpu/fe_nomask.c
+++ b/libc/sysdeps/powerpc/fpu/fe_nomask.c
@@ -1,5 +1,5 @@
/* Procedure definition for FE_NOMASK_ENV.
- Copyright (C) 1997 Free Software Foundation, Inc.
+ Copyright (C) 1997, 2008 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,7 +17,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#include <fenv.h>
+#include <fenv_libc.h>
#include <errno.h>
/* This is a generic stub. An OS specific override is required to set
@@ -30,4 +30,5 @@ __fe_nomask_env(void)
__set_errno (ENOSYS);
return FE_ENABLED_ENV;
}
+libm_hidden_def (__fe_nomask_env)
stub_warning (__fe_nomask_env)
diff --git a/libc/sysdeps/powerpc/fpu/fedisblxcpt.c b/libc/sysdeps/powerpc/fpu/fedisblxcpt.c
index 3002b1b4c..9df4bbc7e 100644
--- a/libc/sysdeps/powerpc/fpu/fedisblxcpt.c
+++ b/libc/sysdeps/powerpc/fpu/fedisblxcpt.c
@@ -1,5 +1,5 @@
/* Disable floating-point exceptions.
- Copyright (C) 2000 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Geoffrey Keating <geoffk@geoffk.org>, 2000.
@@ -26,7 +26,7 @@ fedisableexcept (int excepts)
fenv_union_t fe;
int result, new;
- result = fegetexcept ();
+ result = __fegetexcept ();
if ((excepts & FE_ALL_INVALID) == FE_ALL_INVALID)
excepts = (excepts | FE_INVALID) & ~ FE_ALL_INVALID;
@@ -44,7 +44,7 @@ fedisableexcept (int excepts)
fe.l[1] &= ~(1 << (31 - FPSCR_VE));
fesetenv_register (fe.fenv);
- new = fegetexcept ();
+ new = __fegetexcept ();
if (new == 0 && result != 0)
(void)__fe_mask_env ();
diff --git a/libc/sysdeps/powerpc/fpu/feenablxcpt.c b/libc/sysdeps/powerpc/fpu/feenablxcpt.c
index 7bff18b42..4875e95e3 100644
--- a/libc/sysdeps/powerpc/fpu/feenablxcpt.c
+++ b/libc/sysdeps/powerpc/fpu/feenablxcpt.c
@@ -1,5 +1,5 @@
/* Enable floating-point exceptions.
- Copyright (C) 2000 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Geoffrey Keating <geoffk@geoffk.org>, 2000.
@@ -26,7 +26,7 @@ feenableexcept (int excepts)
fenv_union_t fe;
int result, new;
- result = fegetexcept ();
+ result = __fegetexcept ();
if ((excepts & FE_ALL_INVALID) == FE_ALL_INVALID)
excepts = (excepts | FE_INVALID) & ~ FE_ALL_INVALID;
@@ -44,7 +44,7 @@ feenableexcept (int excepts)
fe.l[1] |= (1 << (31 - FPSCR_VE));
fesetenv_register (fe.fenv);
- new = fegetexcept ();
+ new = __fegetexcept ();
if (new != 0 && result == 0)
(void)__fe_nomask_env ();
diff --git a/libc/sysdeps/powerpc/fpu/fegetexcept.c b/libc/sysdeps/powerpc/fpu/fegetexcept.c
index 0b5cebb6d..c85cb1b22 100644
--- a/libc/sysdeps/powerpc/fpu/fegetexcept.c
+++ b/libc/sysdeps/powerpc/fpu/fegetexcept.c
@@ -1,5 +1,5 @@
/* Get floating-point exceptions.
- Copyright (C) 2000 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Geoffrey Keating <geoffk@geoffk.org>, 2000.
@@ -21,13 +21,13 @@
#include <fenv_libc.h>
int
-fegetexcept (void)
+__fegetexcept (void)
{
fenv_union_t fe;
int result = 0;
fe.fenv = fegetenv_register ();
-
+
if (fe.l[1] & (1 << (31 - FPSCR_XE)))
result |= FE_INEXACT;
if (fe.l[1] & (1 << (31 - FPSCR_ZE)))
@@ -41,3 +41,4 @@ fegetexcept (void)
return result;
}
+weak_alias (__fegetexcept, fegetexcept)
diff --git a/libc/sysdeps/powerpc/fpu/fenv_libc.h b/libc/sysdeps/powerpc/fpu/fenv_libc.h
index fd5fc0c76..6f116b60d 100644
--- a/libc/sysdeps/powerpc/fpu/fenv_libc.h
+++ b/libc/sysdeps/powerpc/fpu/fenv_libc.h
@@ -1,5 +1,5 @@
/* Internal libc stuff for floating point environment routines.
- Copyright (C) 1997, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1997, 2006, 2008 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
@@ -22,6 +22,8 @@
#include <fenv.h>
+libm_hidden_proto (__fe_nomask_env)
+
/* The sticky bits in the FPSCR indicating exceptions have occurred. */
#define FPSCR_STICKY_BITS ((FE_ALL_EXCEPT | FE_ALL_INVALID) & ~FE_INVALID)
@@ -137,5 +139,5 @@ enum {
({ float f; asm volatile ("fmuls %0,%1,%2" \
: "=f"(f) \
: "f" (x), "f"((float)1.0)); f; })
-
+
#endif /* fenv_libc.h */
diff --git a/libc/sysdeps/powerpc/fpu/fraiseexcpt.c b/libc/sysdeps/powerpc/fpu/fraiseexcpt.c
index dbe36c3d5..2d983d97c 100644
--- a/libc/sysdeps/powerpc/fpu/fraiseexcpt.c
+++ b/libc/sysdeps/powerpc/fpu/fraiseexcpt.c
@@ -1,5 +1,5 @@
/* Raise given exceptions.
- Copyright (C) 1997,99,2000,01,02 Free Software Foundation, Inc.
+ Copyright (C) 1997,1999-2002, 2008 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
@@ -45,12 +45,15 @@ __feraiseexcept (int excepts)
triggering any appropriate exceptions. */
fesetenv_register (u.fenv);
- if ((excepts & FE_INVALID)
+ if ((excepts & FE_INVALID))
+ {
/* For some reason, some PowerPC chips (the 601, in particular)
don't have FE_INVALID_SOFTWARE implemented. Detect this
case and raise FE_INVALID_SNAN instead. */
- && !fetestexcept (FE_INVALID))
- set_fpscr_bit (FPSCR_VXSNAN);
+ u.fenv = fegetenv_register ();
+ if ((u.l[1] & FE_INVALID) == 0)
+ set_fpscr_bit (FPSCR_VXSNAN);
+ }
/* Success. */
return 0;
diff --git a/libc/sysdeps/powerpc/fpu/test-powerpc-snan.c b/libc/sysdeps/powerpc/fpu/test-powerpc-snan.c
new file mode 100644
index 000000000..93b212abc
--- /dev/null
+++ b/libc/sysdeps/powerpc/fpu/test-powerpc-snan.c
@@ -0,0 +1,385 @@
+/* Test Signalling NaN in isnan, isinf etc functions.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Andreas Jaeger <aj@suse.de>, 2005.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#define _GNU_SOURCE
+#define __USE_GNU
+#include <stdio.h>
+#include <stdlib.h>
+#include <sys/time.h>
+#include <string.h>
+#include <math.h>
+#include <float.h>
+#include <fenv.h>
+#include <signal.h>
+#include <setjmp.h>
+#include <errno.h>
+
+int dest_offset;
+char *dest_address;
+double value = 123.456;
+double zero = 0.0;
+
+float SNANf;
+double SNAN;
+long double SNANl;
+
+static sigjmp_buf sigfpe_buf;
+
+void
+init_signaling_nan()
+{
+ union {
+ double _ld16;
+ double _d8;
+ unsigned int _ui4[4];
+ float _f4;
+ } nan_temp;
+
+ nan_temp._ui4[0] = 0x7fa00000;
+ SNANf = nan_temp._f4;
+
+ nan_temp._ui4[0] = 0x7ff40000;
+ nan_temp._ui4[1] = 0x00000000;
+ SNAN = nan_temp._d8;
+
+ nan_temp._ui4[0] = 0x7ff40000;
+ nan_temp._ui4[1] = 0x00000000;
+ nan_temp._ui4[2] = 0x00000000;
+ nan_temp._ui4[3] = 0x00000000;
+ SNANl = nan_temp._ld16;
+}
+
+static float
+snan_float (void)
+{
+ return SNANf;
+}
+
+static double
+snan_double (void)
+{
+ return SNAN;
+}
+
+typedef long double ldouble;
+
+static ldouble
+snan_ldouble (void)
+{
+ return SNANl;
+}
+
+
+void
+myFPsighandler(int signal,
+ siginfo_t *info,
+ void *context)
+{
+ siglongjmp(sigfpe_buf, 0);
+}
+
+int
+set_sigaction_FP(void)
+{
+ struct sigaction sa;
+ /* register RT signal handler via sigaction */
+ sa.sa_flags = SA_SIGINFO;
+ sa.sa_sigaction = &myFPsighandler;
+ sigemptyset(&sa.sa_mask);
+ sigaction(SIGFPE, &sa, NULL);
+
+ return 0;
+}
+
+int
+remove_sigaction_FP(void)
+{
+ struct sigaction sa;
+ /* restore default RT signal handler via sigaction */
+ sa.sa_flags = SA_SIGINFO;
+ sa.sa_handler = SIG_DFL;
+ sigemptyset(&sa.sa_mask);
+ sigaction(SIGFPE, &sa, NULL);
+
+ return 0;
+}
+
+static int errors = 0;
+
+static void
+check (const char *testname, int result)
+{
+ if (!result) {
+ printf ("Failure: %s\n", testname);
+ errors++;
+ }
+}
+
+#define TEST_FUNC(NAME, FLOAT) \
+static void \
+NAME (void) \
+{ \
+ /* Variables are declared volatile to forbid some compiler \
+ optimizations. */ \
+ volatile FLOAT Inf_var, NaN_var, zero_var, one_var, SNaN_var; \
+ fenv_t saved_fenv; \
+ \
+ zero_var = 0.0; \
+ one_var = 1.0; \
+ NaN_var = zero_var / zero_var; \
+ SNaN_var = snan_##FLOAT (); \
+ Inf_var = one_var / zero_var; \
+ \
+ (void) &zero_var; \
+ (void) &one_var; \
+ (void) &NaN_var; \
+ (void) &SNaN_var; \
+ (void) &Inf_var; \
+ \
+ set_sigaction_FP (); \
+ fegetenv(&saved_fenv); \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isnan(NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isnan (NaN)", isnan (NaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isnan(-NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isnan (-NaN)", isnan (-NaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isnan(SNaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isnan (SNaN)", isnan (SNaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isnan(-SNaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isnan (-SNaN)", isnan (-SNaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isinf(NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isinf (NaN)", !isinf (NaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isinf(-NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isinf (-NaN)", !isinf (-NaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isinf(SNaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isinf (SNaN)", !isinf (SNaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isinf(-SNaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isinf (-SNaN)", !isinf (-SNaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isfinite(NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isfinite (NaN)", !isfinite (NaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isfinite(-NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isfinite (-NaN)", !isfinite (-NaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isfinite(SNaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isfinite (SNaN)", !isfinite (SNaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isfinite(-SNaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isfinite (-SNaN)", !isfinite (-SNaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isnormal(NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isnormal (NaN)", !isnormal (NaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isnormal(-NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isnormal (-NaN)", !isnormal (-NaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isnormal(SNaN) isnormal SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isnormal (SNaN)", !isnormal (SNaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " isnormal(-SNaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " isnormal (-SNaN)", !isnormal (-SNaN_var)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " fpclassify(NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " fpclassify (NaN)", (fpclassify (NaN_var)==FP_NAN)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " fpclassify(-NaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " fpclassify (-NaN)", (fpclassify (-NaN_var)==FP_NAN)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " fpclassify(SNaN) isnormal SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " fpclassify (SNaN)", (fpclassify (SNaN_var)==FP_NAN)); \
+ } \
+ \
+ feclearexcept(FE_ALL_EXCEPT); \
+ feenableexcept (FE_ALL_EXCEPT); \
+ if (sigsetjmp(sigfpe_buf, 0)) \
+ { \
+ printf (#FLOAT " fpclassify(-SNaN) raised SIGFPE\n"); \
+ errors++; \
+ } else { \
+ check (#FLOAT " fpclassify (-SNaN)", (fpclassify (-SNaN_var)==FP_NAN)); \
+ } \
+ \
+ fesetenv(&saved_fenv); /* restore saved fenv */ \
+ remove_sigaction_FP(); \
+}
+
+TEST_FUNC (float_test, float)
+TEST_FUNC (double_test, double)
+#ifndef NO_LONG_DOUBLE
+TEST_FUNC (ldouble_test, ldouble)
+#endif
+
+static int
+do_test (void)
+{
+ init_signaling_nan();
+
+ float_test();
+ double_test();
+#ifndef NO_LONG_DOUBLE
+ ldouble_test();
+#endif
+
+ return errors != 0;
+}
+
+#define TEST_FUNCTION do_test ()
+#include "../test-skeleton.c"
+
diff --git a/libc/sysdeps/powerpc/powerpc32/dl-machine.c b/libc/sysdeps/powerpc/powerpc32/dl-machine.c
index fc2ce7c1d..731d23956 100644
--- a/libc/sysdeps/powerpc/powerpc32/dl-machine.c
+++ b/libc/sysdeps/powerpc/powerpc32/dl-machine.c
@@ -557,11 +557,6 @@ __process_machine_rela (struct link_map *map,
}
break;
-#define CHECK_STATIC_TLS(map, sym_map) \
- do { \
- if (__builtin_expect ((sym_map)->l_tls_offset == NO_TLS_OFFSET, 0)) \
- _dl_allocate_static_tls (sym_map); \
- } while (0)
#define DO_TLS_RELOC(suffix) \
case R_PPC_DTPREL##suffix: \
/* During relocation all TLS symbols are defined and used. \
diff --git a/libc/sysdeps/powerpc/powerpc32/fpu/s_isnan.S b/libc/sysdeps/powerpc/powerpc32/fpu/s_isnan.S
new file mode 100644
index 000000000..6e3f396de
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/fpu/s_isnan.S
@@ -0,0 +1,56 @@
+/* isnan(). PowerPC32 version.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* int __isnan(x) */
+ .machine power4
+EALIGN (__isnan, 4, 0)
+ mffs fp0
+ mtfsb0 4*cr6+lt /* reset_fpscr_bit (FPSCR_VE) */
+ fcmpu cr7,fp1,fp1
+ mtfsf 255,fp0
+ li r3,0
+ beqlr+ cr7 /* (x == x) then not a NAN */
+ li r3,1 /* else must be a NAN */
+ blr
+ END (__isnan)
+
+hidden_def (__isnan)
+weak_alias (__isnan, isnan)
+
+/* It turns out that the 'double' version will also always work for
+ single-precision. */
+strong_alias (__isnan, __isnanf)
+hidden_def (__isnanf)
+weak_alias (__isnanf, isnanf)
+
+#ifdef NO_LONG_DOUBLE
+strong_alias (__isnan, __isnanl)
+weak_alias (__isnan, isnanl)
+#endif
+
+#ifndef IS_IN_libm
+# if LONG_DOUBLE_COMPAT(libc, GLIBC_2_0)
+compat_symbol (libc, __isnan, __isnanl, GLIBC_2_0);
+compat_symbol (libc, isnan, isnanl, GLIBC_2_0);
+# endif
+#endif
+
diff --git a/libc/sysdeps/powerpc/powerpc32/fpu/s_isnan.c b/libc/sysdeps/powerpc/powerpc32/fpu/s_isnan.c
deleted file mode 100644
index 397717ba9..000000000
--- a/libc/sysdeps/powerpc/powerpc32/fpu/s_isnan.c
+++ /dev/null
@@ -1,7 +0,0 @@
-#include <sysdeps/powerpc/fpu/s_isnan.c>
-#ifndef IS_IN_libm
-# if LONG_DOUBLE_COMPAT(libc, GLIBC_2_0)
-compat_symbol (libc, __isnan, __isnanl, GLIBC_2_0);
-compat_symbol (libc, isnan, isnanl, GLIBC_2_0);
-# endif
-#endif
diff --git a/libc/sysdeps/powerpc/powerpc32/fpu/s_lround.S b/libc/sysdeps/powerpc/powerpc32/fpu/s_lround.S
index 9c534ec2b..d73749e13 100644
--- a/libc/sysdeps/powerpc/powerpc32/fpu/s_lround.S
+++ b/libc/sysdeps/powerpc/powerpc32/fpu/s_lround.S
@@ -1,5 +1,5 @@
/* lround function. PowerPC32 version.
- Copyright (C) 2004, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2004, 2006, 2007, 2008 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
@@ -20,13 +20,10 @@
#include <sysdep.h>
#include <math_ldbl_opt.h>
- .section .rodata.cst8,"aM",@progbits,8
+ .section .rodata.cst4,"aM",@progbits,4
.align 2
-.LC0: /* 0.0 */
- .long 0x00000000
-.LC1: /* 0.5 */
+.LC0: /* 0.5 */
.long 0x3f000000
-
.section ".text"
/* long [r3] lround (float x [fp1])
@@ -37,7 +34,10 @@
tie, choose the one that is even (least significant bit o).".
So we can't use the PowerPC "round to Nearest" mode. Instead we set
"round toward Zero" mode and round by adding +-0.5 before rounding
- to the integer value. */
+ to the integer value. It is necessary to detect when x is
+ (+-)0x1.fffffffffffffp-2 because adding +-0.5 in this case will
+ cause an erroneous shift, carry and round. We simply return 0 if
+ 0.5 > x > -0.5. */
ENTRY (__lround)
stwu r1,-16(r1)
@@ -49,40 +49,40 @@ ENTRY (__lround)
bcl 20,31,1f
1: mflr r9
addis r9,r9,.LC0-1b@ha
- addi r9,r9,.LC0-1b@l
+ lfs fp10,.LC0-1b@l(r9)
# else
bl _GLOBAL_OFFSET_TABLE_@local-4
mflr r10
lwz r9,.LC0@got(10)
+ lfs fp10,0(r9)
# endif
mtlr r11
cfi_same_value (lr)
- lfs fp12,0(r9)
#else
lis r9,.LC0@ha
- lfs fp12,.LC0@l(r9)
-#endif
-#ifdef SHARED
- lfs fp10,.LC1-.LC0(r9)
-#else
- lis r9,.LC1@ha
- lfs fp10,.LC1@l(r9)
+ lfs fp10,.LC0@l(r9)
#endif
- fcmpu cr6,fp1,fp12 /* if (x > 0.0) */
- ble- cr6,.L4
- fadd fp1,fp1,fp10 /* x+= 0.5; */
-.L9:
- fctiwz fp2,fp1 /* Convert To Integer DW lround toward 0. */
- stfd fp2,8(r1)
+ fabs fp2, fp1 /* Get the absolute value of x. */
+ fsub fp12,fp10,fp10 /* Compute 0.0. */
+ fcmpu cr6, fp2, fp10 /* if |x| < 0.5 */
+ fcmpu cr7, fp1, fp12 /* x is negative? x < 0.0 */
+ blt- cr6,.Lretzero
+ fadd fp3,fp2,fp10 /* |x|+=0.5 bias to prepare to round. */
+ bge cr7,.Lconvert /* x is positive so don't negate x. */
+ fnabs fp3,fp3 /* -(|x|+=0.5) */
+.Lconvert:
+ fctiwz fp4,fp3 /* Convert to Integer word lround toward 0. */
+ stfd fp4,8(r1)
nop /* Ensure the following load is in a different dispatch */
nop /* group to avoid pipe stall on POWER4&5. */
nop
- lwz r3,12(r1)
+ lwz r3,12(r1) /* Load return as integer. */
+.Lout:
addi r1,r1,16
blr
-.L4:
- fsub fp1,fp1,fp10 /* x-= 0.5; */
- b .L9
+.Lretzero: /* when 0.5 > x > -0.5 */
+ li r3,0 /* return 0. */
+ b .Lout
END (__lround)
weak_alias (__lround, lround)
diff --git a/libc/sysdeps/powerpc/powerpc32/fpu/s_lroundf.S b/libc/sysdeps/powerpc/powerpc32/fpu/s_lroundf.S
index e3c992d77..6289e0be5 100644
--- a/libc/sysdeps/powerpc/powerpc32/fpu/s_lroundf.S
+++ b/libc/sysdeps/powerpc/powerpc32/fpu/s_lroundf.S
@@ -1,2 +1 @@
/* __lroundf is in s_lround.S */
-/* __lroundf is in s_lround.S */
diff --git a/libc/sysdeps/powerpc/powerpc32/power4/fpu/s_llround.S b/libc/sysdeps/powerpc/powerpc32/power4/fpu/s_llround.S
index 952d2aa6a..e10a37977 100644
--- a/libc/sysdeps/powerpc/powerpc32/power4/fpu/s_llround.S
+++ b/libc/sysdeps/powerpc/powerpc32/power4/fpu/s_llround.S
@@ -1,5 +1,5 @@
/* llround function. PowerPC32 on PowerPC64 version.
- Copyright (C) 2004, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2004, 2006, 2007, 2008 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
@@ -20,15 +20,15 @@
#include <sysdep.h>
#include <math_ldbl_opt.h>
- .section .rodata.cst8,"aM",@progbits,8
- .align 2
-.LC0: /* 0.0 */
+ .section .rodata.cst12,"aM",@progbits,12
+ .align 3
+ .LC0: /* 0x1.0000000000000p+52 == 2^52 */
+ .long 0x43300000
.long 0x00000000
-.LC1: /* 0.5 */
- .long 0x3f000000
+ .long 0x3f000000 /* Use this for 0.5 */
.section ".text"
-
+
/* long [r3] lround (float x [fp1])
IEEE 1003.1 lround function. IEEE specifies "round to the nearest
integer value, rounding halfway cases away from zero, regardless of
@@ -37,7 +37,15 @@
tie, choose the one that is even (least significant bit o).".
So we can't use the PowerPC "round to Nearest" mode. Instead we set
"round toward Zero" mode and round by adding +-0.5 before rounding
- to the integer value. */
+ to the integer value.
+
+ It is necessary to detect when x is (+-)0x1.fffffffffffffp-2
+ because adding +-0.5 in this case will cause an erroneous shift,
+ carry and round. We simply return 0 if 0.5 > x > -0.5. Likewise
+ if x is and odd number between +-(2^52 and 2^53-1) a shift and
+ carry will erroneously round if biased with +-0.5. Therefore if x
+ is greater/less than +-2^52 we don't need to bias the number with
+ +-0.5. */
ENTRY (__llround)
stwu r1,-16(r1)
@@ -57,30 +65,41 @@ ENTRY (__llround)
# endif
mtlr r11
cfi_same_value (lr)
- lfs fp12,0(r9)
- lfs fp10,.LC1-.LC0(r9)
+ lfd fp9,0(r9)
+ lfs fp10,8(r9)
#else
- lis r9,.LC0@ha
- lis r10,.LC1@ha
- lfs fp12,.LC0@l(r9)
- lfs fp10,.LC1@l(r10)
+ lis r9,.LC0@ha
+ lfd fp9,.LC0@l(r9) /* Load 2^52 into fpr9. */
+ lfs fp10,.LC0@l+8(r9) /* Load 0.5 into fpr10. */
#endif
- fcmpu cr6,fp1,fp12 /* if (x > 0.0) */
- ble- cr6,.L4
- fadd fp1,fp1,fp10 /* x+= 0.5; */
-.L9:
- fctidz fp2,fp1 /* Convert To Integer DW round toward 0. */
- stfd fp2,8(r1)
- nop /* Ensure the following load is in a different dispatch */
- nop /* group to avoid pipe stall on POWER4&5. */
+ fabs fp2,fp1 /* Get the absolute value of x. */
+ fsub fp12,fp10,fp10 /* Compute 0.0 into fpr12. */
+ fcmpu cr6,fp2,fp10 /* if |x| < 0.5 */
+ fcmpu cr7,fp2,fp9 /* if |x| >= 2^52 */
+ fcmpu cr1,fp1,fp12 /* x is negative? x < 0.0 */
+ blt- cr6,.Lretzero /* 0.5 > x < -0.5 so just return 0. */
+ bge- cr7,.Lnobias /* 2^52 > x < -2^52 just convert with no bias. */
+ fadd fp3,fp2,fp10 /* |x|+=0.5 bias to prepare to round. */
+ bge cr1,.Lconvert /* x is positive so don't negate x. */
+ fnabs fp3,fp3 /* -(|x|+=0.5) */
+.Lconvert:
+ fctidz fp4,fp3 /* Convert to Integer double word round toward 0. */
+ stfd fp4,8(r1)
+ nop
+ nop
nop
- lwz r4,12(r1)
+ lwz r4,12(r1) /* Load return as integer. */
lwz r3,8(r1)
+.Lout:
addi r1,r1,16
blr
-.L4:
- fsub fp1,fp1,fp10 /* x-= 0.5; */
- b .L9
+.Lretzero: /* 0.5 > x > -0.5 */
+ li r3,0 /* return 0. */
+ li r4,0
+ b .Lout
+.Lnobias:
+ fmr fp3,fp1
+ b .Lconvert
END (__llround)
weak_alias (__llround, llround)
diff --git a/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.S b/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.S
new file mode 100644
index 000000000..6aef4e301
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.S
@@ -0,0 +1,119 @@
+/* sqrt function. PowerPC32 version.
+ Copyright (C) 2007 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 1 Franklin Street, Fifth Floor, Boston MA
+ 02110-1301 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* double [fp1] sqrt (double x [fp1])
+ Power4 (ISA V2.0) and above implement sqrt in hardware (not optional).
+ The fsqrt instruction generates the correct value for all inputs and
+ sets the appropriate floating point exceptions. Extented checking is
+ only needed to set errno (via __kernel_standard) if the input value
+ is negative.
+
+ The fsqrt will set FPCC and FU (Floating Point Unordered or NaN
+ to indicated that the input value was negative or NaN. Use Move to
+ Condition Register from FPSCR to copy the FPCC field to cr1. The
+ branch on summary overflow transfers control to w_sqrt to process
+ any error conditions. Otherwise we can return the result directly.
+
+ This part of the function is a leaf routine, so no need to stack a
+ frame or execute prologue/epilogue code. This means it is safe to
+ transfer directly to w_sqrt as long as the input value (f1) is
+ preserved. Putting the the sqrt result into f2 (double parameter 2)
+ allows passing both the input value and sqrt result into the extended
+ wrapper so there is no need to recompute.
+
+ This tactic avoids the overhead of stacking a frame for the normal
+ (non-error) case. Until gcc supports prologue shrink-wrapping
+ this is the best we can do. */
+
+ .section ".text"
+ .machine power4
+EALIGN (__sqrt, 5, 0)
+ fsqrt fp2,fp1
+ mcrfs cr1,4
+ bso- cr1,.Lw_sqrt
+ fmr fp1,fp2
+ blr
+ .align 4
+.Lw_sqrt:
+ mflr r0
+ stwu r1,-16(r1)
+ cfi_adjust_cfa_offset(16)
+ fmr fp12,fp2
+ stw r0,20(r1)
+ stw r30,8(r1)
+ cfi_offset(lr,20)
+ cfi_offset(r30,8)
+#ifdef SHARED
+# ifdef HAVE_ASM_PPC_REL16
+ bcl 20,31,.LCF1
+.LCF1:
+ mflr r30
+ addis r30,r30,_GLOBAL_OFFSET_TABLE_-.LCF1@ha
+ addi r30,r30,_GLOBAL_OFFSET_TABLE_-.LCF1@l
+ lwz r9,_LIB_VERSION@got(30)
+ lwz r0,0(r9)
+# else
+ bl _GLOBAL_OFFSET_TABLE_@local-4
+ mflr r30
+ lwz r9,_LIB_VERSION@got(30)
+ lwz r0,0(r9)
+# endif
+#else
+ lis r9,_LIB_VERSION@ha
+ lwz r0,_LIB_VERSION@l(r9)
+#endif
+/* if (_LIB_VERSION == _IEEE_) return z; */
+ cmpwi cr7,r0,-1
+ beq- cr7,.L4
+/* if (x != x) return z; !isnan*/
+ fcmpu cr7,fp1,fp1
+ bne- cr7,.L4
+/* if (x < 0.0)
+ return __kernel_standard (x, x, 26) */
+ fmr fp2,fp1
+ fabs fp0,fp1
+ li r3,26
+ fcmpu cr7,fp1,fp0
+ bne- cr7,.L11
+.L4:
+ lwz r0,20(r1)
+ fmr fp1,fp12
+ lwz r30,8(r1)
+ addi r1,r1,16
+ mtlr r0
+ blr
+.L11:
+ bl __kernel_standard@plt
+ fmr fp12,fp1
+ b .L4
+ END (__sqrt)
+
+weak_alias (__sqrt, sqrt)
+
+#ifdef NO_LONG_DOUBLE
+weak_alias (__sqrt, sqrtl)
+strong_alias (__sqrt, __sqrtl)
+#endif
+#if LONG_DOUBLE_COMPAT(libm, GLIBC_2_0)
+compat_symbol (libm, __sqrt, sqrtl, GLIBC_2_0)
+#endif
+
diff --git a/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.c b/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.c
deleted file mode 100644
index f59c19393..000000000
--- a/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt.c
+++ /dev/null
@@ -1,62 +0,0 @@
-/* Double-precision floating point square root wrapper.
- Copyright (C) 2004, 2007 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 Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 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
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, write to the Free
- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
- 02111-1307 USA. */
-
-#include <math_ldbl_opt.h>
-#include "math.h"
-#include "math_private.h"
-#include <fenv_libc.h>
-
-#ifdef __STDC__
-double
-__sqrt (double x) /* wrapper sqrt */
-#else
-double
-__sqrt (x) /* wrapper sqrt */
- double x;
-#endif
-{
- double z;
-/* Power4 (ISA V2.0) and above implement sqrt in hardware. */
- __asm __volatile (
- " fsqrt %0,%1\n"
- : "=f" (z)
- : "f" (x));
-#ifdef _IEEE_LIBM
- return z;
-#else
- if (__builtin_expect (_LIB_VERSION == _IEEE_, 0))
- return z;
-
- if (__builtin_expect (x != x, 0))
- return z;
-
- if (__builtin_expect (x < 0.0, 0))
- return __kernel_standard (x, x, 26); /* sqrt(negative) */
- else
- return z;
-#endif
-}
-
-weak_alias (__sqrt, sqrt)
-#ifdef NO_LONG_DOUBLE
- strong_alias (__sqrt, __sqrtl) weak_alias (__sqrt, sqrtl)
-#endif
-#if LONG_DOUBLE_COMPAT(libm, GLIBC_2_0)
-compat_symbol (libm, __sqrt, sqrtl, GLIBC_2_0);
-#endif
diff --git a/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.S b/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.S
new file mode 100644
index 000000000..e5b8b9d56
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.S
@@ -0,0 +1,111 @@
+/* sqrtf function. PowerPC32 version.
+ Copyright (C) 2007 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 1 Franklin Street, Fifth Floor, Boston MA
+ 02110-1301 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* float [fp1] sqrts (float x [fp1])
+ Power4 (ISA V2.0) and above implement sqrt in hardware (not optional).
+ The fsqrts instruction generates the correct value for all inputs and
+ sets the appropriate floating point exceptions. Extented checking is
+ only needed to set errno (via __kernel_standard) if the input value
+ is negative.
+
+ The fsqrts will set FPCC and FU (Floating Point Unordered or NaN
+ to indicated that the input value was negative or NaN. Use Move to
+ Condition Register from FPSCR to copy the FPCC field to cr1. The
+ branch on summary overflow transfers control to w_sqrt to process
+ any error conditions. Otherwise we can return the result directly.
+
+ This part of the function is a leaf routine, so no need to stack a
+ frame or execute prologue/epilogue code. This means it is safe to
+ transfer directly to w_sqrt as long as the input value (f1) is
+ preserved. Putting the the sqrt result into f2 (float parameter 2)
+ allows passing both the input value and sqrt result into the extended
+ wrapper so there is no need to recompute.
+
+ This tactic avoids the overhead of stacking a frame for the normal
+ (non-error) case. Until gcc supports prologue shrink-wrapping
+ this is the best we can do. */
+
+ .section ".text"
+ .machine power4
+EALIGN (__sqrtf, 5, 0)
+ fsqrts fp2,fp1
+ mcrfs cr1,4
+ bso- cr1,.Lw_sqrtf
+ fmr fp1,fp2
+ blr
+ .align 4
+.Lw_sqrtf:
+ mflr r0
+ stwu r1,-16(r1)
+ cfi_adjust_cfa_offset(16)
+ fmr fp12,fp2
+ stw r0,20(r1)
+ stw r30,8(r1)
+ cfi_offset(lr,20)
+ cfi_offset(r30,8)
+#ifdef SHARED
+# ifdef HAVE_ASM_PPC_REL16
+ bcl 20,31,.LCF1
+.LCF1:
+ mflr r30
+ addis r30,r30,_GLOBAL_OFFSET_TABLE_-.LCF1@ha
+ addi r30,r30,_GLOBAL_OFFSET_TABLE_-.LCF1@l
+ lwz r9,_LIB_VERSION@got(30)
+ lwz r0,0(r9)
+# else
+ bl _GLOBAL_OFFSET_TABLE_@local-4
+ mflr r30
+ lwz r9,_LIB_VERSION@got(30)
+ lwz r0,0(r9)
+# endif
+#else
+ lis r9,_LIB_VERSION@ha
+ lwz r0,_LIB_VERSION@l(r9)
+#endif
+/* if (_LIB_VERSION == _IEEE_) return z; */
+ cmpwi cr7,r0,-1
+ beq- cr7,.L4
+/* if (x != x, 0) return z; !isnan */
+ fcmpu cr7,fp1,fp1
+ bne- cr7,.L4
+/* if (x < 0.0)
+ return __kernel_standard (x, x, 126) */
+ fmr fp2,fp1
+ fabs fp0,fp1
+ li r3,126
+ fcmpu cr7,1,0
+ bne- cr7,.L11
+.L4:
+ lwz r0,20(r1)
+ fmr fp1,fp12
+ lwz r30,8(r1)
+ addi r1,r1,16
+ mtlr r0
+ blr
+.L11:
+ bl __kernel_standard@plt
+ fmr fp12,fp1
+ b .L4
+ END (__sqrtf)
+
+weak_alias (__sqrtf, sqrtf)
+
diff --git a/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.c b/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.c
deleted file mode 100644
index 4784869f0..000000000
--- a/libc/sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf.c
+++ /dev/null
@@ -1,60 +0,0 @@
-/* Single-precision floating point square root wrapper.
- Copyright (C) 2004, 2007 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 Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 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
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, write to the Free
- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
- 02111-1307 USA. */
-
-#include "math.h"
-#include "math_private.h"
-#include <fenv_libc.h>
-
-#include <sysdep.h>
-#include <ldsodefs.h>
-
-#ifdef __STDC__
-float
-__sqrtf (float x) /* wrapper sqrtf */
-#else
-float
-__sqrtf (x) /* wrapper sqrtf */
- float x;
-#endif
-{
-#ifdef _IEEE_LIBM
- return __ieee754_sqrtf (x);
-#else
- float z;
-/* Power4 (ISA V2.0) and above implement sqrtf in hardware. */
- __asm __volatile (
- " fsqrts %0,%1\n"
- : "=f" (z)
- : "f" (x));
-
- if (__builtin_expect (_LIB_VERSION == _IEEE_, 0))
- return z;
-
- if (__builtin_expect (x != x, 0))
- return z;
-
- if (__builtin_expect (x < 0.0, 0))
- /* sqrtf(negative) */
- return (float) __kernel_standard ((double) x, (double) x, 126);
- else
- return z;
-#endif
-}
-
-weak_alias (__sqrtf, sqrtf)
diff --git a/libc/sysdeps/powerpc/powerpc32/power4/hp-timing.c b/libc/sysdeps/powerpc/powerpc32/power4/hp-timing.c
new file mode 100644
index 000000000..332fe8af9
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power4/hp-timing.c
@@ -0,0 +1,25 @@
+/* Support for high precision, low overhead timing functions.
+ powerpc64 version.
+ Copyright (C) 2005, 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <hp-timing.h>
+
+/* We have to define the variable for the overhead. */
+hp_timing_t _dl_hp_timing_overhead;
diff --git a/libc/sysdeps/powerpc/powerpc32/power4/hp-timing.h b/libc/sysdeps/powerpc/powerpc32/power4/hp-timing.h
new file mode 100644
index 000000000..5f719dd5a
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power4/hp-timing.h
@@ -0,0 +1,152 @@
+/* High precision, low overhead timing functions. powerpc64 version.
+ Copyright (C) 2005, 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _HP_TIMING_H
+#define _HP_TIMING_H 1
+
+#include <string.h>
+#include <sys/param.h>
+#include <stdio-common/_itoa.h>
+#include <atomic.h>
+
+/* The macros defined here use the powerpc 64-bit time base register.
+ The time base is nominally clocked at 1/8th the CPU clock, but this
+ can vary.
+
+ The list of macros we need includes the following:
+
+ - HP_TIMING_AVAIL: test for availability.
+
+ - HP_TIMING_INLINE: this macro is non-zero if the functionality is not
+ implemented using function calls but instead uses some inlined code
+ which might simply consist of a few assembler instructions. We have to
+ know this since we might want to use the macros here in places where we
+ cannot make function calls.
+
+ - hp_timing_t: This is the type for variables used to store the time
+ values.
+
+ - HP_TIMING_ZERO: clear `hp_timing_t' object.
+
+ - HP_TIMING_NOW: place timestamp for current time in variable given as
+ parameter.
+
+ - HP_TIMING_DIFF_INIT: do whatever is necessary to be able to use the
+ HP_TIMING_DIFF macro.
+
+ - HP_TIMING_DIFF: compute difference between two times and store it
+ in a third. Source and destination might overlap.
+
+ - HP_TIMING_ACCUM: add time difference to another variable. This might
+ be a bit more complicated to implement for some platforms as the
+ operation should be thread-safe and 64bit arithmetic on 32bit platforms
+ is not.
+
+ - HP_TIMING_ACCUM_NT: this is the variant for situations where we know
+ there are no threads involved.
+
+ - HP_TIMING_PRINT: write decimal representation of the timing value into
+ the given string. This operation need not be inline even though
+ HP_TIMING_INLINE is specified.
+
+*/
+
+/* We always assume having the timestamp register. */
+#define HP_TIMING_AVAIL (1)
+
+/* We indeed have inlined functions. */
+#define HP_TIMING_INLINE (1)
+
+/* We use 64bit values for the times. */
+typedef unsigned long long int hp_timing_t;
+
+/* Set timestamp value to zero. */
+#define HP_TIMING_ZERO(Var) (Var) = (0)
+
+/* That's quite simple. Use the `mftb' instruction. Note that the value
+ might not be 100% accurate since there might be some more instructions
+ running in this moment. This could be changed by using a barrier like
+ 'lwsync' right before the `mftb' instruciton. But we are not interested
+ in accurate clock cycles here so we don't do this. */
+
+#define HP_TIMING_NOW(Var) \
+ do { \
+ union { long long ll; long ii[2]; } _var; \
+ long tmp; \
+ __asm__ __volatile__ ( \
+ "1: mfspr %0,269;" \
+ " mfspr %1,268;" \
+ " mfspr %2,269;" \
+ " cmpw %0,%2;" \
+ " bne 1b;" \
+ : "=r" (_var.ii[0]), "=r" (_var.ii[1]) , "=r" (tmp) \
+ : : "cr0" \
+ ); \
+ Var = _var.ll; \
+ } while (0)
+
+
+/* Use two 'mftb' instructions in a row to find out how long it takes.
+ On current POWER4, POWER5, and 970 processors mftb take ~10 cycles. */
+#define HP_TIMING_DIFF_INIT() \
+ do { \
+ if (GLRO(dl_hp_timing_overhead) == 0) \
+ { \
+ int __cnt = 5; \
+ GLRO(dl_hp_timing_overhead) = ~0ull; \
+ do \
+ { \
+ hp_timing_t __t1, __t2; \
+ HP_TIMING_NOW (__t1); \
+ HP_TIMING_NOW (__t2); \
+ if (__t2 - __t1 < GLRO(dl_hp_timing_overhead)) \
+ GLRO(dl_hp_timing_overhead) = __t2 - __t1; \
+ } \
+ while (--__cnt > 0); \
+ } \
+ } while (0)
+
+/* It's simple arithmetic in 64-bit. */
+#define HP_TIMING_DIFF(Diff, Start, End) (Diff) = ((End) - (Start))
+
+/* We need to insure that this add is atomic in threaded environments. We use
+ __arch_atomic_exchange_and_add_64 from atomic.h to get thread safety. */
+#define HP_TIMING_ACCUM(Sum, Diff) \
+ do { \
+ hp_timing_t __diff = (Diff) - GLRO(dl_hp_timing_overhead); \
+ __arch_atomic_exchange_and_add_64 (&(Sum), __diff); \
+ } while (0)
+
+/* No threads, no extra work. */
+#define HP_TIMING_ACCUM_NT(Sum, Diff) (Sum) += (Diff)
+
+/* Print the time value. */
+#define HP_TIMING_PRINT(Buf, Len, Val) \
+ do { \
+ char __buf[20]; \
+ char *__cp = _itoa (Val, __buf + sizeof (__buf), 10, 0); \
+ size_t __len = (Len); \
+ char *__dest = (Buf); \
+ while (__len-- > 0 && __cp < __buf + sizeof (__buf)) \
+ *__dest++ = *__cp++; \
+ memcpy (__dest, " ticks", MIN (__len, sizeof (" ticks"))); \
+ } while (0)
+
+#endif /* hp-timing.h */
diff --git a/libc/sysdeps/powerpc/powerpc32/power5+/fpu/s_llroundf.S b/libc/sysdeps/powerpc/powerpc32/power5+/fpu/s_llroundf.S
index ffe6b7eb3..030d2fdff 100644
--- a/libc/sysdeps/powerpc/powerpc32/power5+/fpu/s_llroundf.S
+++ b/libc/sysdeps/powerpc/powerpc32/power5+/fpu/s_llroundf.S
@@ -1,2 +1 @@
/* __llroundf is in s_llround.S */
-/* __llroundf is in s_llround.S */
diff --git a/libc/sysdeps/powerpc/powerpc32/power5/fpu/s_isnan.S b/libc/sysdeps/powerpc/powerpc32/power5/fpu/s_isnan.S
new file mode 100644
index 000000000..91337483d
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power5/fpu/s_isnan.S
@@ -0,0 +1,62 @@
+/* isnan(). PowerPC32 version.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* int __isnan(x) */
+ .machine power5
+EALIGN (__isnan, 4, 0)
+ stwu r1,-32(r1)
+ cfi_adjust_cfa_offset (32)
+ ori r1,r1,0
+ stfd fp1,24(r1) /* copy FPR to GPR */
+ ori r1,r1,0
+ lwz r4,24(r1)
+ lwz r5,28(r1)
+ lis r0,0x7ff0 /* const long r0 0x7ff00000 00000000 */
+ clrlwi r4,r4,1 /* x = fabs(x) */
+ cmpw cr7,r4,r0 /* if (fabs(x) =< inf) */
+ cmpwi cr6,r5,0
+ li r3,0 /* then return 0 */
+ addi r1,r1,32
+ cfi_adjust_cfa_offset (-32)
+ bltlr+ cr7
+ bgt- cr7,L(NaN)
+ beqlr+ cr6
+L(NaN):
+ li r3,1 /* else return 1 */
+ blr
+ END (__isnan)
+
+hidden_def (__isnan)
+weak_alias (__isnan, isnan)
+
+#ifdef NO_LONG_DOUBLE
+strong_alias (__isnan, __isnanl)
+weak_alias (__isnan, isnanl)
+#endif
+
+#ifndef IS_IN_libm
+# if LONG_DOUBLE_COMPAT(libc, GLIBC_2_0)
+compat_symbol (libc, __isnan, __isnanl, GLIBC_2_0);
+compat_symbol (libc, isnan, isnanl, GLIBC_2_0);
+# endif
+#endif
+
diff --git a/libc/sysdeps/powerpc/powerpc32/power5/fpu/s_isnanf.S b/libc/sysdeps/powerpc/powerpc32/power5/fpu/s_isnanf.S
new file mode 100644
index 000000000..9b1e95f35
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power5/fpu/s_isnanf.S
@@ -0,0 +1,46 @@
+/* isnan(). PowerPC32 version.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* int __isnanf(x) */
+ .machine power5
+EALIGN (__isnanf, 4, 0)
+ stwu r1,-32(r1)
+ cfi_adjust_cfa_offset (32)
+ stfs fp1,28(r1) /* copy FPR to GPR */
+ nop
+ nop
+ lwz r4,28(r1)
+ lis r0,0x7f80 /* const long r0 0x7f800000 */
+ clrlwi r4,r4,1 /* x = fabs(x) */
+ cmpw cr7,r4,r0 /* if (fabs(x) =< inf) */
+ li r3,0 /* then return 0 */
+ addi r1,r1,32
+ cfi_adjust_cfa_offset (-32)
+ blelr+ cr7
+L(NaN):
+ li r3,1 /* else return 1 */
+ blr
+ END (__isnanf)
+
+hidden_def (__isnanf)
+weak_alias (__isnanf, isnanf)
+
diff --git a/libc/sysdeps/powerpc/powerpc32/power5/fpu/w_sqrt.S b/libc/sysdeps/powerpc/powerpc32/power5/fpu/w_sqrt.S
new file mode 100644
index 000000000..925930bf7
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power5/fpu/w_sqrt.S
@@ -0,0 +1,117 @@
+/* sqrt function. PowerPC32 version.
+ Copyright (C) 2007 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 1 Franklin Street, Fifth Floor, Boston MA
+ 02110-1301 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* double [fp1] sqrt (double x [fp1])
+ Power4 (ISA V2.0) and above implement sqrt in hardware (not optional).
+ The fsqrt instruction generates the correct value for all inputs and
+ sets the appropriate floating point exceptions. Extented checking is
+ only needed to set errno (via __kernel_standard) if the input value
+ is negative.
+
+ So compare the input value against the absolute value of itself.
+ This will compare equal unless the value is negative (EDOM) or a NAN,
+ in which case we branch to the extend wrapper. If equal we can return
+ the result directly.
+
+ This part of the function looks like a leaf routine, so no need to
+ stack a frame or execute prologue/epilogue code. It is safe to
+ branch directly to w_sqrt as long as the input value (f1) is
+ preserved. Putting the the sqrt result into f2 (float parameter 2)
+ allows passing both the input value and sqrt result into the extended
+ wrapper so there is no need to recompute.
+
+ This tactic avoids the overhead of stacking a frame for the normal
+ (non-error) case. Until gcc supports prologue shrink-wrapping
+ this is the best we can do. */
+
+ .section ".text"
+ .machine power4
+EALIGN (__sqrt, 5, 0)
+ fabs fp0,fp1
+ fsqrt fp2,fp1
+ fcmpu cr1,fp0,fp1
+ bne- cr1,.Lw_sqrt
+ fmr fp1,fp2
+ blr
+ .align 4
+.Lw_sqrt:
+ mflr r0
+ stwu r1,-16(r1)
+ cfi_adjust_cfa_offset(16)
+ fmr fp12,fp2
+ stw r0,20(r1)
+ stw r30,8(r1)
+ cfi_offset(lr,20)
+ cfi_offset(r30,8)
+#ifdef SHARED
+# ifdef HAVE_ASM_PPC_REL16
+ bcl 20,31,.LCF1
+.LCF1:
+ mflr r30
+ addis r30,r30,_GLOBAL_OFFSET_TABLE_-.LCF1@ha
+ addi r30,r30,_GLOBAL_OFFSET_TABLE_-.LCF1@l
+ lwz r9,_LIB_VERSION@got(30)
+ lwz r0,0(r9)
+# else
+ bl _GLOBAL_OFFSET_TABLE_@local-4
+ mflr r30
+ lwz r9,_LIB_VERSION@got(30)
+ lwz r0,0(r9)
+# endif
+#else
+ lis r9,_LIB_VERSION@ha
+ lwz r0,_LIB_VERSION@l(r9)
+#endif
+/* if (_LIB_VERSION == _IEEE_) return z; */
+ cmpwi cr7,r0,-1
+ beq- cr7,.L4
+/* if (x != x) return z; !isnan*/
+ fcmpu cr7,fp1,fp1
+ bne- cr7,.L4
+/* if (x < 0.0)
+ return __kernel_standard (x, x, 26) */
+ fmr fp2,fp1
+ li r3,26
+ bne- cr1,.L11
+.L4:
+ lwz r0,20(r1)
+ fmr fp1,fp12
+ lwz r30,8(r1)
+ addi r1,r1,16
+ mtlr r0
+ blr
+.L11:
+ bl __kernel_standard@plt
+ fmr fp12,fp1
+ b .L4
+ END (__sqrt)
+
+weak_alias (__sqrt, sqrt)
+
+#ifdef NO_LONG_DOUBLE
+weak_alias (__sqrt, sqrtl)
+strong_alias (__sqrt, __sqrtl)
+#endif
+#if LONG_DOUBLE_COMPAT(libm, GLIBC_2_0)
+compat_symbol (libm, __sqrt, sqrtl, GLIBC_2_0)
+#endif
+
diff --git a/libc/sysdeps/powerpc/powerpc32/power5/fpu/w_sqrtf.S b/libc/sysdeps/powerpc/powerpc32/power5/fpu/w_sqrtf.S
new file mode 100644
index 000000000..891e69c9c
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power5/fpu/w_sqrtf.S
@@ -0,0 +1,109 @@
+/* sqrtf function. PowerPC32 version.
+ Copyright (C) 2007 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 1 Franklin Street, Fifth Floor, Boston MA
+ 02110-1301 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* float [fp1] sqrts (float x [fp1])
+ Power4 (ISA V2.0) and above implement sqrt in hardware (not optional).
+ The fsqrts instruction generates the correct value for all inputs and
+ sets the appropriate floating point exceptions. Extented checking is
+ only needed to set errno (via __kernel_standard) if the input value
+ is negative.
+
+ So compare the input value against the absolute value of itself.
+ This will compare equal unless the value is negative (EDOM) or a NAN,
+ in which case we branch to the extend wrapper. If equal we can return
+ the result directly.
+
+ This part of the function looks like a leaf routine, so no need to
+ stack a frame or execute prologue/epilogue code. It is safe to
+ branch directly to w_sqrt as long as the input value (f1) is
+ preserved. Putting the the sqrt result into f2 (float parameter 2)
+ allows passing both the input value and sqrt result into the extended
+ wrapper so there is no need to recompute.
+
+ This tactic avoids the overhead of stacking a frame for the normal
+ (non-error) case. Until gcc supports prologue shrink-wrapping
+ this is the best we can do. */
+
+ .section ".text"
+ .machine power4
+EALIGN (__sqrtf, 5, 0)
+ fabs fp0,fp1
+ fsqrts fp2,fp1
+ fcmpu cr1,fp0,fp1
+ bne- cr1,.Lw_sqrtf
+ fmr fp1,fp2
+ blr
+ .align 4
+.Lw_sqrtf:
+ mflr r0
+ stwu r1,-16(r1)
+ cfi_adjust_cfa_offset(16)
+ fmr fp12,fp2
+ stw r0,20(r1)
+ stw r30,8(r1)
+ cfi_offset(lr,20)
+ cfi_offset(r30,8)
+#ifdef SHARED
+# ifdef HAVE_ASM_PPC_REL16
+ bcl 20,31,.LCF1
+.LCF1:
+ mflr r30
+ addis r30,r30,_GLOBAL_OFFSET_TABLE_-.LCF1@ha
+ addi r30,r30,_GLOBAL_OFFSET_TABLE_-.LCF1@l
+ lwz r9,_LIB_VERSION@got(30)
+ lwz r0,0(r9)
+# else
+ bl _GLOBAL_OFFSET_TABLE_@local-4
+ mflr r30
+ lwz r9,_LIB_VERSION@got(30)
+ lwz r0,0(r9)
+# endif
+#else
+ lis r9,_LIB_VERSION@ha
+ lwz r0,_LIB_VERSION@l(r9)
+#endif
+/* if (_LIB_VERSION == _IEEE_) return z; */
+ cmpwi cr7,r0,-1
+ beq- cr7,.L4
+/* if (x != x, 0) return z; !isnan */
+ fcmpu cr7,fp1,fp1
+ bne- cr7,.L4
+/* if (x < 0.0)
+ return __kernel_standard (x, x, 126) */
+ fmr fp2,fp1
+ li r3,126
+ bne- cr1,.L11
+.L4:
+ lwz r0,20(r1)
+ fmr fp1,fp12
+ lwz r30,8(r1)
+ addi r1,r1,16
+ mtlr r0
+ blr
+.L11:
+ bl __kernel_standard@plt
+ fmr fp12,fp1
+ b .L4
+ END (__sqrtf)
+
+weak_alias (__sqrtf, sqrtf)
+
diff --git a/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_isnan.S b/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_isnan.S
new file mode 100644
index 000000000..dbaaf1c1a
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_isnan.S
@@ -0,0 +1,62 @@
+/* isnan(). PowerPC32 version.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* int __isnan(x) */
+ .machine power6
+EALIGN (__isnan, 4, 0)
+ stwu r1,-32(r1)
+ cfi_adjust_cfa_offset (32)
+ ori r1,r1,0
+ stfd fp1,24(r1) /* copy FPR to GPR */
+ ori r1,r1,0
+ lwz r4,24(r1)
+ lwz r5,28(r1)
+ lis r0,0x7ff0 /* const long r0 0x7ff00000 00000000 */
+ clrlwi r4,r4,1 /* x = fabs(x) */
+ cmpw cr7,r4,r0 /* if (fabs(x) =< inf) */
+ cmpwi cr6,r5,0
+ li r3,0 /* then return 0 */
+ addi r1,r1,32
+ cfi_adjust_cfa_offset (-32)
+ bltlr+ cr7
+ bgt- cr7,L(NaN)
+ beqlr+ cr6
+L(NaN):
+ li r3,1 /* else return 1 */
+ blr
+ END (__isnan)
+
+hidden_def (__isnan)
+weak_alias (__isnan, isnan)
+
+#ifdef NO_LONG_DOUBLE
+strong_alias (__isnan, __isnanl)
+weak_alias (__isnan, isnanl)
+#endif
+
+#ifndef IS_IN_libm
+# if LONG_DOUBLE_COMPAT(libc, GLIBC_2_0)
+compat_symbol (libc, __isnan, __isnanl, GLIBC_2_0);
+compat_symbol (libc, isnan, isnanl, GLIBC_2_0);
+# endif
+#endif
+
diff --git a/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_isnanf.S b/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_isnanf.S
new file mode 100644
index 000000000..12bf473a8
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_isnanf.S
@@ -0,0 +1,46 @@
+/* isnanf(). PowerPC32 version.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* int __isnanf(x) */
+ .machine power6
+EALIGN (__isnanf, 4, 0)
+ stwu r1,-32(r1)
+ cfi_adjust_cfa_offset (32)
+ ori r1,r1,0
+ stfs fp1,24(r1) /* copy FPR to GPR */
+ ori r1,r1,0
+ lwz r4,24(r1)
+ lis r0,0x7f80 /* const long r0 0x7f800000 */
+ clrlwi r4,r4,1 /* x = fabs(x) */
+ cmpw cr7,r4,r0 /* if (fabs(x) =< inf) */
+ li r3,0 /* then return 0 */
+ addi r1,r1,32
+ cfi_adjust_cfa_offset (-32)
+ blelr+ cr7
+L(NaN):
+ li r3,1 /* else return 1 */
+ blr
+ END (__isnan)
+
+hidden_def (__isnanf)
+weak_alias (__isnanf, isnanf)
+
diff --git a/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_llroundf.S b/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_llroundf.S
index ffe6b7eb3..030d2fdff 100644
--- a/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_llroundf.S
+++ b/libc/sysdeps/powerpc/powerpc32/power6/fpu/s_llroundf.S
@@ -1,2 +1 @@
/* __llroundf is in s_llround.S */
-/* __llroundf is in s_llround.S */
diff --git a/libc/sysdeps/powerpc/powerpc64/dl-machine.h b/libc/sysdeps/powerpc/powerpc64/dl-machine.h
index 89a69e1a2..b674dbef4 100644
--- a/libc/sysdeps/powerpc/powerpc64/dl-machine.h
+++ b/libc/sysdeps/powerpc/powerpc64/dl-machine.h
@@ -1,6 +1,6 @@
/* Machine-dependent ELF dynamic relocation inline functions.
PowerPC64 version.
- Copyright 1995-2005, 2006 Free Software Foundation, Inc.
+ Copyright 1995-2005, 2006, 2008 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
@@ -246,30 +246,35 @@ BODY_PREFIX "_dl_start_user:\n" \
" " END_2(_dl_start_user) "\n" \
" .popsection");
-/* Nonzero iff TYPE should not be allowed to resolve to one of
- the main executable's symbols, as for a COPY reloc. */
-#define elf_machine_lookup_noexec_p(type) ((type) == R_PPC64_COPY)
+/* ELF_RTYPE_CLASS_NOCOPY iff TYPE should not be allowed to resolve to
+ one of the main executable's symbols, as for a COPY reloc.
+
+ To make function pointer comparisons work on most targets, the
+ relevant ABI states that the address of a non-local function in a
+ dynamically linked executable is the address of the PLT entry for
+ that function. This is quite reasonable since using the real
+ function address in a non-PIC executable would typically require
+ dynamic relocations in .text, something to be avoided. For such
+ functions, the linker emits a SHN_UNDEF symbol in the executable
+ with value equal to the PLT entry address. Normally, SHN_UNDEF
+ symbols have a value of zero, so this is a clue to ld.so that it
+ should treat these symbols specially. For relocations not in
+ ELF_RTYPE_CLASS_PLT (eg. those on function pointers), ld.so should
+ use the value of the executable SHN_UNDEF symbol, ie. the PLT entry
+ address. For relocations in ELF_RTYPE_CLASS_PLT (eg. the relocs in
+ the PLT itself), ld.so should use the value of the corresponding
+ defined symbol in the object that defines the function, ie. the
+ real function address. This complicates ld.so in that there are
+ now two possible values for a given symbol, and it gets even worse
+ because protected symbols need yet another set of rules.
+
+ On PowerPC64 we don't need any of this. The linker won't emit
+ SHN_UNDEF symbols with non-zero values. ld.so can make all
+ relocations behave "normally", ie. always use the real address
+ like PLT relocations. So always set ELF_RTYPE_CLASS_PLT. */
-/* Nonzero iff TYPE describes relocation of a PLT entry, so
- PLT entries should not be allowed to define the value. */
-#define elf_machine_lookup_noplt_p(type) ((type) == R_PPC64_JMP_SLOT)
-
-/* ELF_RTYPE_CLASS_PLT iff TYPE describes relocation of a PLT entry, so
- PLT entries should not be allowed to define the value.
- ELF_RTYPE_CLASS_NOCOPY iff TYPE should not be allowed to resolve to one
- of the main executable's symbols, as for a COPY reloc. */
-
-#if !defined RTLD_BOOTSTRAP || USE___THREAD
-#define elf_machine_type_class(type) \
- /* This covers all the TLS relocs, though most won't appear. */ \
- (((((type) >= R_PPC64_DTPMOD64 && (type) <= R_PPC64_TPREL16_HIGHESTA) \
- || (type) == R_PPC64_ADDR24) * ELF_RTYPE_CLASS_PLT) \
- | (((type) == R_PPC64_COPY) * ELF_RTYPE_CLASS_COPY))
-#else
#define elf_machine_type_class(type) \
- ((((type) == R_PPC64_ADDR24) * ELF_RTYPE_CLASS_PLT) \
- | (((type) == R_PPC64_COPY) * ELF_RTYPE_CLASS_COPY))
-#endif
+ (ELF_RTYPE_CLASS_PLT | (((type) == R_PPC64_COPY) * ELF_RTYPE_CLASS_COPY))
/* A reloc type used for ld.so cmdline arg lookups to reject PLT entries. */
#define ELF_MACHINE_JMP_SLOT R_PPC64_JMP_SLOT
@@ -282,6 +287,8 @@ BODY_PREFIX "_dl_start_user:\n" \
#define GLINK_INITIAL_ENTRY_WORDS 8
#define PPC_DCBST(where) asm volatile ("dcbst 0,%0" : : "r"(where) : "memory")
+#define PPC_DCBT(where) asm volatile ("dcbt 0,%0" : : "r"(where) : "memory")
+#define PPC_DCBF(where) asm volatile ("dcbf 0,%0" : : "r"(where) : "memory")
#define PPC_SYNC asm volatile ("sync" : : : "memory")
#define PPC_ISYNC asm volatile ("sync; isync" : : : "memory")
#define PPC_ICBI(where) asm volatile ("icbi 0,%0" : : "r"(where) : "memory")
@@ -403,6 +410,11 @@ elf_machine_fixup_plt (struct link_map *map, lookup_t sym_map,
Elf64_FuncDesc *rel = (Elf64_FuncDesc *) finaladdr;
Elf64_Addr offset = 0;
+ PPC_DCBT (&plt->fd_aux);
+ PPC_DCBT (&plt->fd_func);
+ PPC_DCBT (&rel->fd_aux);
+ PPC_DCBT (&rel->fd_func);
+
/* If sym_map is NULL, it's a weak undefined sym; Leave the plt zero. */
if (sym_map == NULL)
return 0;
@@ -425,13 +437,12 @@ elf_machine_fixup_plt (struct link_map *map, lookup_t sym_map,
plt->fd_aux = rel->fd_aux + offset;
plt->fd_toc = rel->fd_toc + offset;
- PPC_DCBST (&plt->fd_aux);
- PPC_DCBST (&plt->fd_toc);
- PPC_SYNC;
+ PPC_DCBF (&plt->fd_toc);
+ PPC_ISYNC;
plt->fd_func = rel->fd_func + offset;
PPC_DCBST (&plt->fd_func);
- PPC_SYNC;
+ PPC_ISYNC;
return finaladdr;
}
diff --git a/libc/sysdeps/powerpc/powerpc64/fpu/s_isnan.S b/libc/sysdeps/powerpc/powerpc64/fpu/s_isnan.S
new file mode 100644
index 000000000..9963896f2
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc64/fpu/s_isnan.S
@@ -0,0 +1,57 @@
+/* isnan(). PowerPC64 version.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* int __isnan(x) */
+ .machine power4
+EALIGN (__isnan, 4, 0)
+ CALL_MCOUNT 0
+ mffs fp0
+ mtfsb0 4*cr6+lt /* reset_fpscr_bit (FPSCR_VE) */
+ fcmpu cr7,fp1,fp1
+ mtfsf 255,fp0
+ li r3,0
+ beqlr+ cr7 /* (x == x) then not a NAN */
+ li r3,1 /* else must be a NAN */
+ blr
+ END (__isnan)
+
+hidden_def (__isnan)
+weak_alias (__isnan, isnan)
+
+/* It turns out that the 'double' version will also always work for
+ single-precision. */
+strong_alias (__isnan, __isnanf)
+hidden_def (__isnanf)
+weak_alias (__isnanf, isnanf)
+
+#ifdef NO_LONG_DOUBLE
+strong_alias (__isnan, __isnanl)
+weak_alias (__isnan, isnanl)
+#endif
+
+#ifndef IS_IN_libm
+# if LONG_DOUBLE_COMPAT(libc, GLIBC_2_0)
+compat_symbol (libc, __isnan, __isnanl, GLIBC_2_0);
+compat_symbol (libc, isnan, isnanl, GLIBC_2_0);
+# endif
+#endif
+
diff --git a/libc/sysdeps/powerpc/powerpc64/fpu/s_isnan.c b/libc/sysdeps/powerpc/powerpc64/fpu/s_isnan.c
deleted file mode 100644
index 397717ba9..000000000
--- a/libc/sysdeps/powerpc/powerpc64/fpu/s_isnan.c
+++ /dev/null
@@ -1,7 +0,0 @@
-#include <sysdeps/powerpc/fpu/s_isnan.c>
-#ifndef IS_IN_libm
-# if LONG_DOUBLE_COMPAT(libc, GLIBC_2_0)
-compat_symbol (libc, __isnan, __isnanl, GLIBC_2_0);
-compat_symbol (libc, isnan, isnanl, GLIBC_2_0);
-# endif
-#endif
diff --git a/libc/sysdeps/powerpc/powerpc64/fpu/s_llround.S b/libc/sysdeps/powerpc/powerpc64/fpu/s_llround.S
index d023b8f2c..cdfdd02c3 100644
--- a/libc/sysdeps/powerpc/powerpc64/fpu/s_llround.S
+++ b/libc/sysdeps/powerpc/powerpc64/fpu/s_llround.S
@@ -1,5 +1,5 @@
/* llround function. PowerPC64 version.
- Copyright (C) 2004, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2004, 2006, 2007, 2008 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
@@ -21,13 +21,13 @@
#include <math_ldbl_opt.h>
.section ".toc","aw"
-.LC0: /* -0.0 */
- .tc FD_00000000_0[TC],0x0000000000000000
+.LC0: /* 2^52 */
+ .tc FD_43300000_0[TC],0x4330000000000000
.LC1: /* 0.5 */
.tc FD_3fe00000_0[TC],0x3fe0000000000000
.section ".text"
-/* long long [r3] llround (float x [fp1])
+/* long long [r3] llround (double x [fp1])
IEEE 1003.1 llround function. IEEE specifies "round to the nearest
integer value, rounding halfway cases away from zero, regardless of
the current rounding mode." However PowerPC Architecture defines
@@ -35,26 +35,45 @@
tie, choose the one that is even (least significant bit o).".
So we can't use the PowerPC "round to Nearest" mode. Instead we set
"round toward Zero" mode and round by adding +-0.5 before rounding
- to the integer value. */
+ to the integer value.
+
+ It is necessary to detect when x is (+-)0x1.fffffffffffffp-2
+ because adding +-0.5 in this case will cause an erroneous shift,
+ carry and round. We simply return 0 if 0.5 > x > -0.5. Likewise
+ if x is and odd number between +-(2^52 and 2^53-1) a shift and
+ carry will erroneously round if biased with +-0.5. Therefore if x
+ is greater/less than +-2^52 we don't need to bias the number with
+ +-0.5. */
ENTRY (__llround)
CALL_MCOUNT 0
- lfd fp12,.LC0@toc(2)
- lfd fp10,.LC1@toc(2)
- fcmpu cr6,fp1,fp12 /* if (x > 0.0) */
- ble- cr6,.L4
- fadd fp1,fp1,fp10 /* x+= 0.5; */
-.L9:
- fctidz fp2,fp1 /* Convert To Integer DW llround toward 0. */
- stfd fp2,-16(r1)
- nop /* Insure the following load is in a different dispatch group */
- nop /* to avoid pipe stall on POWER4&5. */
+ lfd fp9,.LC0@toc(2) /* Load 2^52 into fpr9. */
+ lfd fp10,.LC1@toc(2)/* Load 0.5 into fpr10. */
+ fabs fp2,fp1 /* Get the absolute value of x. */
+ fsub fp12,fp10,fp10 /* Compute 0.0 into fp12. */
+ fcmpu cr6,fp2,fp10 /* if |x| < 0.5 */
+ fcmpu cr7,fp2,fp9 /* if |x| >= 2^52 */
+ fcmpu cr1,fp1,fp12 /* x is negative? x < 0.0 */
+ blt- cr6,.Lretzero /* 0.5 > x < -0.5 so just return 0. */
+ bge- cr7,.Lnobias /* 2^52 > x < -2^52 just convert with no bias. */
+ fadd fp3,fp2,fp10 /* |x|+=0.5 bias to prepare to round. */
+ bge cr1,.Lconvert /* x is positive so don't negate x. */
+ fnabs fp3,fp3 /* -(|x|+=0.5) */
+.Lconvert:
+ fctidz fp4,fp3 /* Convert to Integer double word round toward 0. */
+ stfd fp4,-16(r1)
+ nop
+ nop
nop
- ld r3,-16(r1)
+ ld r3,-16(r1) /* Load return as integer. */
+.Lout:
blr
-.L4:
- fsub fp1,fp1,fp10 /* x-= 0.5; */
- b .L9
+.Lretzero: /* 0.5 > x > -0.5 */
+ li r3,0 /* return 0. */
+ b .Lout
+.Lnobias:
+ fmr fp3,fp1
+ b .Lconvert
END (__llround)
strong_alias (__llround, __lround)
diff --git a/libc/sysdeps/powerpc/powerpc64/fpu/s_llroundf.S b/libc/sysdeps/powerpc/powerpc64/fpu/s_llroundf.S
index bbbd05492..e617bca44 100644
--- a/libc/sysdeps/powerpc/powerpc64/fpu/s_llroundf.S
+++ b/libc/sysdeps/powerpc/powerpc64/fpu/s_llroundf.S
@@ -1,5 +1,5 @@
/* llroundf function. PowerPC64 version.
- Copyright (C) 2004, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2004, 2006, 2007, 2008 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
@@ -20,8 +20,8 @@
#include <sysdep.h>
.section ".toc","aw"
-.LC0: /* -0.0 */
- .tc FD_00000000_0[TC],0x0000000000000000
+.LC0: /* 2^23 */
+ .tc FD_41600000_0[TC],0x4160000000000000
.LC1: /* 0.5 */
.tc FD_3fe00000_0[TC],0x3fe0000000000000
.section ".text"
@@ -34,24 +34,45 @@
tie, choose the one that is even (least significant bit o).".
So we can't use the PowerPC "round to Nearest" mode. Instead we set
"round toward Zero" mode and round by adding +-0.5 before rounding
- to the integer value. */
+ to the integer value.
+
+ It is necessary to detect when x is (+-)0x1.fffffffffffffp-2
+ because adding +-0.5 in this case will cause an erroneous shift,
+ carry and round. We simply return 0 if 0.5 > x > -0.5. Likewise
+ if x is and odd number between +-(2^23 and 2^24-1) a shift and
+ carry will erroneously round if biased with +-0.5. Therefore if x
+ is greater/less than +-2^23 we don't need to bias the number with
+ +-0.5. */
ENTRY (__llroundf)
CALL_MCOUNT 0
- lfd fp12,.LC0@toc(2)
- lfd fp10,.LC1@toc(2)
- fcmpu cr6,fp1,fp12 /* if (x < 0.0) */
- fsubs fp3,fp1,fp10 /* x-= 0.5; */
- ble- cr6,.L9
- fadds fp3,fp1,fp10 /* x+= 0.5; */
-.L9:
- fctidz fp2,fp3 /* Convert To Integer DW round toward 0. */
- stfd fp2,-16(r1)
- nop /* Insure the following load is in a different dispatch group */
- nop /* to avoid pipe stall on POWER4&5. */
+ lfd fp9,.LC0@toc(2) /* Load 2^23 into fpr9. */
+ lfd fp10,.LC1@toc(2)/* Load 0.5 into fpr10. */
+ fabs fp2,fp1 /* Get the absolute value of x. */
+ fsub fp12,fp10,fp10 /* Compute 0.0 into fp12. */
+ fcmpu cr6,fp2,fp10 /* if |x| < 0.5 */
+ fcmpu cr7,fp2,fp9 /* if |x| >= 2^23 */
+ fcmpu cr1,fp1,fp12 /* x is negative? x < 0.0 */
+ blt- cr6,.Lretzero /* 0.5 > x < -0.5 so just return 0. */
+ bge- cr7,.Lnobias /* 2^23 > x < -2^23 just convert with no bias. */
+ fadd fp3,fp2,fp10 /* |x|+=0.5 bias to prepare to round. */
+ bge cr1,.Lconvert /* x is positive so don't negate x. */
+ fnabs fp3,fp3 /* -(|x|+=0.5) */
+.Lconvert:
+ fctidz fp4,fp3 /* Convert to Integer double word round toward 0. */
+ stfd fp4,-16(r1)
+ nop
+ nop
nop
- ld r3,-16(r1)
+ ld r3,-16(r1) /* Load return as integer. */
+.Lout:
blr
+.Lretzero: /* 0.5 > x > -0.5 */
+ li r3,0 /* return 0. */
+ b .Lout
+.Lnobias:
+ fmr fp3,fp1
+ b .Lconvert
END (__llroundf)
strong_alias (__llroundf, __lroundf)
diff --git a/libc/sysdeps/powerpc/powerpc64/fpu/s_lrint.S b/libc/sysdeps/powerpc/powerpc64/fpu/s_lrint.S
index fe774693b..d3c2fff58 100644
--- a/libc/sysdeps/powerpc/powerpc64/fpu/s_lrint.S
+++ b/libc/sysdeps/powerpc/powerpc64/fpu/s_lrint.S
@@ -1,2 +1 @@
/* __lrint is in s_llrint.c */
-/* __lrint is in s_llrint.c */
diff --git a/libc/sysdeps/powerpc/powerpc64/fpu/s_lround.S b/libc/sysdeps/powerpc/powerpc64/fpu/s_lround.S
index 883bba1c5..4306c405c 100644
--- a/libc/sysdeps/powerpc/powerpc64/fpu/s_lround.S
+++ b/libc/sysdeps/powerpc/powerpc64/fpu/s_lround.S
@@ -1,2 +1 @@
/* __lround is in s_llround.S */
-/* __lround is in s_llround.S */
diff --git a/libc/sysdeps/powerpc/powerpc64/fpu/s_lroundf.S b/libc/sysdeps/powerpc/powerpc64/fpu/s_lroundf.S
index 15506f680..6b2a4e37a 100644
--- a/libc/sysdeps/powerpc/powerpc64/fpu/s_lroundf.S
+++ b/libc/sysdeps/powerpc/powerpc64/fpu/s_lroundf.S
@@ -1,2 +1 @@
/* __lroundf is in s_llroundf.S */
-/* __lroundf is in s_llroundf.S */
diff --git a/libc/sysdeps/powerpc/powerpc64/hp-timing.h b/libc/sysdeps/powerpc/powerpc64/hp-timing.h
index b58cca900..e107a2dd4 100644
--- a/libc/sysdeps/powerpc/powerpc64/hp-timing.h
+++ b/libc/sysdeps/powerpc/powerpc64/hp-timing.h
@@ -1,5 +1,5 @@
/* High precision, low overhead timing functions. powerpc64 version.
- Copyright (C) 2005 Free Software Foundation, Inc.
+ Copyright (C) 2005, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
@@ -85,7 +85,11 @@ typedef unsigned long long int hp_timing_t;
running in this moment. This could be changed by using a barrier like
'lwsync' right before the `mftb' instruciton. But we are not interested
in accurate clock cycles here so we don't do this. */
+#ifdef _ARCH_PWR4
+#define HP_TIMING_NOW(Var) __asm__ __volatile__ ("mfspr %0,268" : "=r" (Var))
+#else
#define HP_TIMING_NOW(Var) __asm__ __volatile__ ("mftb %0" : "=r" (Var))
+#endif
/* Use two 'mftb' instructions in a row to find out how long it takes.
On current POWER4, POWER5, and 970 processors mftb take ~10 cycles. */
diff --git a/libc/sysdeps/powerpc/powerpc64/power5/fpu/s_isnan.S b/libc/sysdeps/powerpc/powerpc64/power5/fpu/s_isnan.S
new file mode 100644
index 000000000..d46d049d4
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc64/power5/fpu/s_isnan.S
@@ -0,0 +1,61 @@
+/* isnan(). PowerPC64 version.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* int __isnan(x) */
+ .machine power5
+EALIGN (__isnan, 4, 0)
+ CALL_MCOUNT 0
+ stfd fp1,-8(r1) /* copy FPR to GPR */
+ lis r0,0x7ff0
+ nop /* insure the following is in a different */
+ nop /* dispatch group */
+ ld r4,-8(r1)
+ sldi r0,r0,32 /* const long r0 0x7ff00000 00000000 */
+ clrldi r4,r4,1 /* x = fabs(x) */
+ cmpd cr7,r4,r0 /* if (fabs(x) <= inf) */
+ li r3,0 /* then return 0 */
+ blelr+ cr7
+ li r3,1 /* else return 1 */
+ blr
+ END (__isnan)
+
+hidden_def (__isnan)
+weak_alias (__isnan, isnan)
+
+/* It turns out that the 'double' version will also always work for
+ single-precision. */
+strong_alias (__isnan, __isnanf)
+hidden_def (__isnanf)
+weak_alias (__isnanf, isnanf)
+
+#ifdef NO_LONG_DOUBLE
+strong_alias (__isnan, __isnanl)
+weak_alias (__isnan, isnanl)
+#endif
+
+#ifndef IS_IN_libm
+# if LONG_DOUBLE_COMPAT(libc, GLIBC_2_0)
+compat_symbol (libc, __isnan, __isnanl, GLIBC_2_0);
+compat_symbol (libc, isnan, isnanl, GLIBC_2_0);
+# endif
+#endif
+
diff --git a/libc/sysdeps/powerpc/powerpc64/power6/fpu/s_isnan.S b/libc/sysdeps/powerpc/powerpc64/power6/fpu/s_isnan.S
new file mode 100644
index 000000000..fe0c56ca8
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc64/power6/fpu/s_isnan.S
@@ -0,0 +1,60 @@
+/* isnan(). PowerPC64 version.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* int __isnan(x) */
+ .machine power6
+EALIGN (__isnan, 4, 0)
+ CALL_MCOUNT 0
+ stfd fp1,-8(r1) /* copy FPR to GPR */
+ ori r1,r1,0
+ ld r4,-8(r1)
+ lis r0,0x7ff0
+ sldi r0,r0,32 /* const long r0 0x7ff00000 00000000 */
+ clrldi r4,r4,1 /* x = fabs(x) */
+ cmpd cr7,r4,r0 /* if (fabs(x) <= inf) */
+ li r3,0 /* then return 0 */
+ blelr+ cr7
+ li r3,1 /* else return 1 */
+ blr
+ END (__isnan)
+
+hidden_def (__isnan)
+weak_alias (__isnan, isnan)
+
+/* It turns out that the 'double' version will also always work for
+ single-precision. */
+strong_alias (__isnan, __isnanf)
+hidden_def (__isnanf)
+weak_alias (__isnanf, isnanf)
+
+#ifdef NO_LONG_DOUBLE
+strong_alias (__isnan, __isnanl)
+weak_alias (__isnan, isnanl)
+#endif
+
+#ifndef IS_IN_libm
+# if LONG_DOUBLE_COMPAT(libc, GLIBC_2_0)
+compat_symbol (libc, __isnan, __isnanl, GLIBC_2_0);
+compat_symbol (libc, isnan, isnanl, GLIBC_2_0);
+# endif
+#endif
+
diff --git a/libc/sysdeps/powerpc/powerpc64/power6x/fpu/s_isnan.S b/libc/sysdeps/powerpc/powerpc64/power6x/fpu/s_isnan.S
new file mode 100644
index 000000000..47dd49a75
--- /dev/null
+++ b/libc/sysdeps/powerpc/powerpc64/power6x/fpu/s_isnan.S
@@ -0,0 +1,59 @@
+/* isnan(). PowerPC64 version.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <math_ldbl_opt.h>
+
+/* int __isnan(x) */
+ .machine power6
+EALIGN (__isnan, 4, 0)
+ CALL_MCOUNT 0
+ mftgpr r4,fp1 /* copy FPR to GPR */
+ lis r0,0x7ff0
+ ori r1,r1,0
+ clrldi r4,r4,1 /* x = fabs(x) */
+ sldi r0,r0,32 /* const long r0 0x7ff00000 00000000 */
+ cmpd cr7,r4,r0 /* if (fabs(x) <= inf) */
+ li r3,0 /* then return 0 */
+ blelr+ cr7
+ li r3,1 /* else return 1 */
+ blr
+ END (__isnan)
+
+hidden_def (__isnan)
+weak_alias (__isnan, isnan)
+
+/* It turns out that the 'double' version will also always work for
+ single-precision. */
+strong_alias (__isnan, __isnanf)
+hidden_def (__isnanf)
+weak_alias (__isnanf, isnanf)
+
+#ifdef NO_LONG_DOUBLE
+strong_alias (__isnan, __isnanl)
+weak_alias (__isnan, isnanl)
+#endif
+
+#ifndef IS_IN_libm
+# if LONG_DOUBLE_COMPAT(libc, GLIBC_2_0)
+compat_symbol (libc, __isnan, __isnanl, GLIBC_2_0);
+compat_symbol (libc, isnan, isnanl, GLIBC_2_0);
+# endif
+#endif
+
diff --git a/libc/sysdeps/powerpc/sysdep.h b/libc/sysdeps/powerpc/sysdep.h
index 2ae52b78c..43edeb71e 100644
--- a/libc/sysdeps/powerpc/sysdep.h
+++ b/libc/sysdeps/powerpc/sysdep.h
@@ -44,6 +44,8 @@
#define PPC_FEATURE_PA6T 0x00000800 /* PA Semi 6T Core */
#define PPC_FEATURE_HAS_DFP 0x00000400 /* Decimal FP Unit */
#define PPC_FEATURE_POWER6_EXT 0x00000200 /* P6 + mffgpr/mftgpr */
+#define PPC_FEATURE_HAS_VSX 0x00000100 /* P7 Vector Extension. */
+#define PPC_FEATURE_ARCH_2_06 0x00000080 /* ISA 2.06 */
#define PPC_FEATURE_970 (PPC_FEATURE_POWER4 + PPC_FEATURE_HAS_ALTIVEC)
#ifdef __ASSEMBLER__
diff --git a/libc/sysdeps/s390/bits/byteswap.h b/libc/sysdeps/s390/bits/byteswap.h
index d0e31b836..4bfd5fa06 100644
--- a/libc/sysdeps/s390/bits/byteswap.h
+++ b/libc/sysdeps/s390/bits/byteswap.h
@@ -1,5 +1,5 @@
/* Macros to swap the order of bytes in integer values. s390 version.
- Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2001, 2002, 2003, 2008 Free Software Foundation, Inc.
Contributed by Martin Schwidefsky (schwidefsky@de.ibm.com).
This file is part of the GNU C Library.
@@ -18,7 +18,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#if !defined _BYTESWAP_H && !defined _NETINET_IN_H
+#if !defined _BYTESWAP_H && !defined _NETINET_IN_H && !defined _ENDIAN_H
# error "Never use <bits/byteswap.h> directly; include <byteswap.h> instead."
#endif
diff --git a/libc/sysdeps/sparc/Makefile b/libc/sysdeps/sparc/Makefile
index 40323a064..73b926554 100644
--- a/libc/sysdeps/sparc/Makefile
+++ b/libc/sysdeps/sparc/Makefile
@@ -1,6 +1,12 @@
# The Sparc `long double' is a distinct type we support.
long-double-fcts = yes
+pie-ccflag = -fPIE
+
+ifeq ($(subdir),gmon)
+sysdep_routines += sparc-mcount
+endif
+
ifeq ($(subdir),db2)
CPPFLAGS += -DHAVE_SPINLOCKS=1 -DHAVE_ASSEM_SPARC_GCC=1
endif
diff --git a/libc/sysdeps/sparc/machine-gmon.h b/libc/sysdeps/sparc/machine-gmon.h
new file mode 100644
index 000000000..296c5ff4d
--- /dev/null
+++ b/libc/sysdeps/sparc/machine-gmon.h
@@ -0,0 +1,33 @@
+/* sparc-specific implementation of profiling support.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by David S. Miller <davem@davemloft.net>, 2008
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+
+/* We must not pollute the global namespace. */
+#define mcount_internal __mcount_internal
+
+extern void mcount_internal (u_long frompc, u_long selfpc) internal_function;
+
+#define _MCOUNT_DECL(frompc, selfpc) \
+void internal_function mcount_internal (u_long frompc, u_long selfpc)
+
+/* Define MCOUNT as empty since we have the implementation in another
+ file. */
+#define MCOUNT
diff --git a/libc/sysdeps/sparc/sparc-mcount.S b/libc/sysdeps/sparc/sparc-mcount.S
new file mode 100644
index 000000000..573b08f51
--- /dev/null
+++ b/libc/sysdeps/sparc/sparc-mcount.S
@@ -0,0 +1,29 @@
+/* sparc-specific implemetation of profiling support.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by David S. Miller <davem@davemloft.net>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+
+ENTRY(_mcount)
+ mov %i7, %o0
+ ba __mcount_internal
+ mov %o7, %o1
+END(_mcount)
+
+weak_alias (_mcount, mcount)
diff --git a/libc/sysdeps/sparc/sparc32/Makefile b/libc/sysdeps/sparc/sparc32/Makefile
index ed4fba741..6529ad897 100644
--- a/libc/sysdeps/sparc/sparc32/Makefile
+++ b/libc/sysdeps/sparc/sparc32/Makefile
@@ -20,6 +20,10 @@ ifeq ($(subdir),gnulib)
sysdep_routines = dotmul umul $(divrem) alloca
endif # gnulib
+ifeq ($(subdir),csu)
+CFLAGS-initfini.s += -mcpu=v7
+endif
+
# We distribute these files, even though they are generated,
# so as to avoid the need for a functioning m4 to build the library.
divrem := sdiv udiv rem urem
diff --git a/libc/sysdeps/sparc/sparc64/Makefile b/libc/sysdeps/sparc/sparc64/Makefile
index c1df31727..3bb023883 100644
--- a/libc/sysdeps/sparc/sparc64/Makefile
+++ b/libc/sysdeps/sparc/sparc64/Makefile
@@ -2,3 +2,7 @@ ifeq ($(subdir),csu)
sysdep_routines += hp-timing
elide-routines.os += hp-timing
endif
+
+ifeq ($(subdir),csu)
+CFLAGS-initfini.s += -mcpu=v9
+endif
diff --git a/libc/sysdeps/sparc/sparc64/backtrace.c b/libc/sysdeps/sparc/sparc64/backtrace.c
new file mode 100644
index 000000000..6d7e429e2
--- /dev/null
+++ b/libc/sysdeps/sparc/sparc64/backtrace.c
@@ -0,0 +1,58 @@
+/* Return backtrace of current program state.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by David S. Miller <davem@davemloft.net>
+
+ 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 <execinfo.h>
+#include <stddef.h>
+#include <bp-checks.h>
+#include <sysdep.h>
+
+struct layout
+{
+ unsigned long locals[8];
+ unsigned long ins[6];
+ unsigned long next;
+ void *__unbounded return_address;
+};
+
+int
+__backtrace (void **array, int size)
+{
+ struct layout *current;
+ unsigned long fp;
+ int count;
+
+ asm volatile ("flushw");
+ asm volatile ("mov %%fp, %0" : "=r"(fp));
+ current = (struct layout *__unbounded) (fp + STACK_BIAS);
+ current = BOUNDED_1 (current);
+
+ for (count = 0; count < size; count++)
+ {
+ array[count] = current->return_address;
+ if (!current->next)
+ break;
+ current = (struct layout *__unbounded) (current->next + STACK_BIAS);
+ current = BOUNDED_1 (current);
+ }
+
+ return count;
+}
+weak_alias (__backtrace, backtrace)
+libc_hidden_def (__backtrace)
diff --git a/libc/sysdeps/sparc/sparc64/elf/configure b/libc/sysdeps/sparc/sparc64/elf/configure
index 46181524c..c94d3ac1b 100644
--- a/libc/sysdeps/sparc/sparc64/elf/configure
+++ b/libc/sysdeps/sparc/sparc64/elf/configure
@@ -1,65 +1,16 @@
# This file is generated from configure.in by Autoconf. DO NOT EDIT!
# Local configure fragment for sysdeps/sparc/sparc64/elf.
-if test "$usetls" != no; then
-# Check for support of thread-local storage handling in assembler and linker.
-echo "$as_me:$LINENO: checking for sparc64 TLS support" >&5
-echo $ECHO_N "checking for sparc64 TLS support... $ECHO_C" >&6
-if test "${libc_cv_sparc64_tls+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat > conftest.s <<\EOF
- .section ".tdata", "awT", @progbits
- .globl foo
-foo: .word 1
- .section ".tbss", "awT", @nobits
- .globl bar
-bar: .skip 4
- .text
- .globl main
-main: sethi %tgd_hi22(foo), %l1
- add %l1, %tgd_lo10(foo), %l1
- add %l7, %l1, %o0, %tgd_add(foo)
- call __tls_get_addr, %tgd_call(foo)
- sethi %tldm_hi22(bar), %l1
- add %l1, %tldm_lo10(bar), %l1
- add %l7, %l1, %o0, %tldm_add(bar)
- call __tls_get_addr, %tldm_call(bar)
- sethi %tldo_hix22(bar), %l1
- xor %l1, %tldo_lox10(bar), %l1
- add %o0, %l1, %l1, %tldo_add(bar)
- sethi %tie_hi22(foo), %l1
- add %l1, %tie_lo10(foo), %l1
- ldx [%l7 + %l1], %l1, %tie_ldx(foo)
- add %g7, %l1, %l1, %tie_add(foo)
- sethi %tle_hix22(foo), %l1
- xor %l1, %tle_lox10(foo), %l1
-EOF
-if { ac_try='${CC-cc} -o conftest.bin $CFLAGS conftest.s 1>&5'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- libc_cv_sparc64_tls=yes
-else
- libc_cv_sparc64_tls=no
-fi
-rm -f conftest*
-fi
-echo "$as_me:$LINENO: result: $libc_cv_sparc64_tls" >&5
-echo "${ECHO_T}$libc_cv_sparc64_tls" >&6
-if test $libc_cv_sparc64_tls = yes; then
- cat >>confdefs.h <<\_ACEOF
+cat >>confdefs.h <<\_ACEOF
#define HAVE_TLS_SUPPORT 1
_ACEOF
-fi
-fi
+libc_cv_sparc64_tls=yes
+
# Check for broken WDISP22 in the linker.
-echo "$as_me:$LINENO: checking for sparc64 ld WDISP22 handling" >&5
-echo $ECHO_N "checking for sparc64 ld WDISP22 handling... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for sparc64 ld WDISP22 handling" >&5
+echo $ECHO_N "checking for sparc64 ld WDISP22 handling... $ECHO_C" >&6; }
if test "${libc_cv_sparc64_wdisp22+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
@@ -80,8 +31,8 @@ if { ac_try='${CC-cc} -nostdlib -shared $CFLAGS conftest1.s conftest2.s -o conft
fi
rm -f conftest*
fi
-echo "$as_me:$LINENO: result: $libc_cv_sparc64_wdisp22" >&5
-echo "${ECHO_T}$libc_cv_sparc64_wdisp22" >&6
+{ echo "$as_me:$LINENO: result: $libc_cv_sparc64_wdisp22" >&5
+echo "${ECHO_T}$libc_cv_sparc64_wdisp22" >&6; }
if test $libc_cv_sparc64_wdisp22 != ok; then
cat >>confdefs.h <<\_ACEOF
#define BROKEN_SPARC_WDISP22 1
diff --git a/libc/sysdeps/sparc/sparc64/elf/configure.in b/libc/sysdeps/sparc/sparc64/elf/configure.in
index fd7e34e90..f6281655a 100644
--- a/libc/sysdeps/sparc/sparc64/elf/configure.in
+++ b/libc/sysdeps/sparc/sparc64/elf/configure.in
@@ -1,49 +1,52 @@
GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
# Local configure fragment for sysdeps/sparc/sparc64/elf.
-if test "$usetls" != no; then
-# Check for support of thread-local storage handling in assembler and linker.
-AC_CACHE_CHECK(for sparc64 TLS support, libc_cv_sparc64_tls, [dnl
-changequote(,)dnl
-cat > conftest.s <<\EOF
- .section ".tdata", "awT", @progbits
- .globl foo
-foo: .word 1
- .section ".tbss", "awT", @nobits
- .globl bar
-bar: .skip 4
- .text
- .globl main
-main: sethi %tgd_hi22(foo), %l1
- add %l1, %tgd_lo10(foo), %l1
- add %l7, %l1, %o0, %tgd_add(foo)
- call __tls_get_addr, %tgd_call(foo)
- sethi %tldm_hi22(bar), %l1
- add %l1, %tldm_lo10(bar), %l1
- add %l7, %l1, %o0, %tldm_add(bar)
- call __tls_get_addr, %tldm_call(bar)
- sethi %tldo_hix22(bar), %l1
- xor %l1, %tldo_lox10(bar), %l1
- add %o0, %l1, %l1, %tldo_add(bar)
- sethi %tie_hi22(foo), %l1
- add %l1, %tie_lo10(foo), %l1
- ldx [%l7 + %l1], %l1, %tie_ldx(foo)
- add %g7, %l1, %l1, %tie_add(foo)
- sethi %tle_hix22(foo), %l1
- xor %l1, %tle_lox10(foo), %l1
-EOF
-changequote([,])dnl
-dnl
-if AC_TRY_COMMAND(${CC-cc} -o conftest.bin $CFLAGS conftest.s 1>&AS_MESSAGE_LOG_FD); then
- libc_cv_sparc64_tls=yes
-else
- libc_cv_sparc64_tls=no
-fi
-rm -f conftest*])
-if test $libc_cv_sparc64_tls = yes; then
- AC_DEFINE(HAVE_TLS_SUPPORT)
-fi
-fi
+AC_DEFINE(HAVE_TLS_SUPPORT)
+libc_cv_sparc64_tls=yes
+
+dnl if test "$usetls" != no; then
+dnl # Check for support of thread-local storage handling in assembler and linker.
+dnl AC_CACHE_CHECK(for sparc64 TLS support, libc_cv_sparc64_tls, [dnl
+dnl changequote(,)dnl
+dnl cat > conftest.s <<\EOF
+dnl .section ".tdata", "awT", @progbits
+dnl .globl foo
+dnl foo: .word 1
+dnl .section ".tbss", "awT", @nobits
+dnl .globl bar
+dnl bar: .skip 4
+dnl .text
+dnl .globl main
+dnl main: sethi %tgd_hi22(foo), %l1
+dnl add %l1, %tgd_lo10(foo), %l1
+dnl add %l7, %l1, %o0, %tgd_add(foo)
+dnl call __tls_get_addr, %tgd_call(foo)
+dnl sethi %tldm_hi22(bar), %l1
+dnl add %l1, %tldm_lo10(bar), %l1
+dnl add %l7, %l1, %o0, %tldm_add(bar)
+dnl call __tls_get_addr, %tldm_call(bar)
+dnl sethi %tldo_hix22(bar), %l1
+dnl xor %l1, %tldo_lox10(bar), %l1
+dnl add %o0, %l1, %l1, %tldo_add(bar)
+dnl sethi %tie_hi22(foo), %l1
+dnl add %l1, %tie_lo10(foo), %l1
+dnl ldx [%l7 + %l1], %l1, %tie_ldx(foo)
+dnl add %g7, %l1, %l1, %tie_add(foo)
+dnl sethi %tle_hix22(foo), %l1
+dnl xor %l1, %tle_lox10(foo), %l1
+dnl EOF
+dnl changequote([,])dnl
+dnl dnl
+dnl if AC_TRY_COMMAND(${CC-cc} -o conftest.bin $CFLAGS conftest.s 1>&AS_MESSAGE_LOG_FD); then
+dnl libc_cv_sparc64_tls=yes
+dnl else
+dnl libc_cv_sparc64_tls=no
+dnl fi
+dnl rm -f conftest*])
+dnl if test $libc_cv_sparc64_tls = yes; then
+dnl AC_DEFINE(HAVE_TLS_SUPPORT)
+dnl fi
+dnl fi
# Check for broken WDISP22 in the linker.
AC_CACHE_CHECK(for sparc64 ld WDISP22 handling, libc_cv_sparc64_wdisp22, [dnl
diff --git a/libc/sysdeps/unix/bsd/bsd4.4/bits/socket.h b/libc/sysdeps/unix/bsd/bsd4.4/bits/socket.h
index 67db4d846..2ccd01d01 100644
--- a/libc/sysdeps/unix/bsd/bsd4.4/bits/socket.h
+++ b/libc/sysdeps/unix/bsd/bsd4.4/bits/socket.h
@@ -171,8 +171,10 @@ enum
#define MSG_CTRUNC MSG_CTRUNC
MSG_WAITALL = 0x40, /* Wait for full request or error. */
#define MSG_WAITALL MSG_WAITALL
- MSG_DONTWAIT = 0x80 /* This message should be nonblocking. */
+ MSG_DONTWAIT = 0x80, /* This message should be nonblocking. */
#define MSG_DONTWAIT MSG_DONTWAIT
+ MSG_NOSIGNAL = 0x0400 /* Do not generate SIGPIPE on EPIPE. */
+#define MSG_NOSIGNAL MSG_NOSIGNAL
};
diff --git a/libc/sysdeps/unix/syscalls.list b/libc/sysdeps/unix/syscalls.list
index 4c963abe5..04ed63c4d 100644
--- a/libc/sysdeps/unix/syscalls.list
+++ b/libc/sysdeps/unix/syscalls.list
@@ -9,6 +9,7 @@ chroot - chroot i:s chroot
close - close Ci:i __libc_close __close close
dup - dup i:i __dup dup
dup2 - dup2 i:ii __dup2 dup2
+dup3 - dup3 i:iii dup3
fchdir - fchdir i:i __fchdir fchdir
fcntl - fcntl Ci:iiF __libc_fcntl __fcntl __fcntl_internal fcntl
fstatfs - fstatfs i:ip __fstatfs fstatfs
diff --git a/libc/sysdeps/unix/sysv/linux/Makefile b/libc/sysdeps/unix/sysv/linux/Makefile
index 3b86e6eb3..aa364df5e 100644
--- a/libc/sysdeps/unix/sysv/linux/Makefile
+++ b/libc/sysdeps/unix/sysv/linux/Makefile
@@ -155,7 +155,7 @@ CFLAGS-mq_receive.c += -fexceptions
endif
ifeq ($(subdir),nscd)
-CFLAGS-connections.c += -DHAVE_EPOLL -DHAVE_SENDFILE
+CFLAGS-connections.c += -DHAVE_EPOLL -DHAVE_SENDFILE -DHAVE_INOTIFY
CFLAGS-pwdcache.c += -DHAVE_SENDFILE
CFLAGS-grpcache.c += -DHAVE_SENDFILE
CFLAGS-hstcache.c += -DHAVE_SENDFILE
diff --git a/libc/sysdeps/unix/sysv/linux/Versions b/libc/sysdeps/unix/sysv/linux/Versions
index af4c293c2..76ecae001 100644
--- a/libc/sysdeps/unix/sysv/linux/Versions
+++ b/libc/sysdeps/unix/sysv/linux/Versions
@@ -135,6 +135,9 @@ libc {
GLIBC_2.8 {
timerfd_create; timerfd_settime; timerfd_gettime;
}
+ GLIBC_2.9 {
+ epoll_create1; inotify_init1;
+ }
GLIBC_PRIVATE {
# functions used in other libraries
__syscall_rt_sigqueueinfo;
diff --git a/libc/sysdeps/unix/sysv/linux/alpha/bits/resource.h b/libc/sysdeps/unix/sysv/linux/alpha/bits/resource.h
index 216374584..92d0199dc 100644
--- a/libc/sysdeps/unix/sysv/linux/alpha/bits/resource.h
+++ b/libc/sysdeps/unix/sysv/linux/alpha/bits/resource.h
@@ -158,8 +158,16 @@ enum __rusage_who
#define RUSAGE_SELF RUSAGE_SELF
/* All of its terminated child processes. */
- RUSAGE_CHILDREN = -1
+ RUSAGE_CHILDREN = -1,
#define RUSAGE_CHILDREN RUSAGE_CHILDREN
+
+#ifdef __USE_GNU
+ /* The calling thread. */
+ RUSAGE_THREAD = 1
+# define RUSAGE_THREAD RUSAGE_THREAD
+ /* Name for the same functionality on Solaris. */
+# define RUSAGE_LWP RUSAGE_THREAD
+#endif
};
#define __need_timeval
diff --git a/libc/sysdeps/unix/sysv/linux/alpha/sys/epoll.h b/libc/sysdeps/unix/sysv/linux/alpha/sys/epoll.h
new file mode 100644
index 000000000..9f983a515
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/alpha/sys/epoll.h
@@ -0,0 +1,143 @@
+/* Copyright (C) 2002-2006, 2007, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_EPOLL_H
+#define _SYS_EPOLL_H 1
+
+#include <stdint.h>
+#include <sys/types.h>
+
+/* Get __sigset_t. */
+#include <bits/sigset.h>
+
+#ifndef __sigset_t_defined
+# define __sigset_t_defined
+typedef __sigset_t sigset_t;
+#endif
+
+
+/* Flags to be passed to epoll_create2. */
+enum
+ {
+ EPOLL_CLOEXEC = 010000000,
+#define EPOLL_CLOEXEC EPOLL_CLOEXEC
+ EPOLL_NONBLOCK = 04
+#define EPOLL_NONBLOCK EPOLL_NONBLOCK
+ };
+
+
+enum EPOLL_EVENTS
+ {
+ EPOLLIN = 0x001,
+#define EPOLLIN EPOLLIN
+ EPOLLPRI = 0x002,
+#define EPOLLPRI EPOLLPRI
+ EPOLLOUT = 0x004,
+#define EPOLLOUT EPOLLOUT
+ EPOLLRDNORM = 0x040,
+#define EPOLLRDNORM EPOLLRDNORM
+ EPOLLRDBAND = 0x080,
+#define EPOLLRDBAND EPOLLRDBAND
+ EPOLLWRNORM = 0x100,
+#define EPOLLWRNORM EPOLLWRNORM
+ EPOLLWRBAND = 0x200,
+#define EPOLLWRBAND EPOLLWRBAND
+ EPOLLMSG = 0x400,
+#define EPOLLMSG EPOLLMSG
+ EPOLLERR = 0x008,
+#define EPOLLERR EPOLLERR
+ EPOLLHUP = 0x010,
+#define EPOLLHUP EPOLLHUP
+ EPOLLRDHUP = 0x2000,
+#define EPOLLRDHUP EPOLLRDHUP
+ EPOLLONESHOT = (1 << 30),
+#define EPOLLONESHOT EPOLLONESHOT
+ EPOLLET = (1 << 31)
+#define EPOLLET EPOLLET
+ };
+
+
+/* Valid opcodes ( "op" parameter ) to issue to epoll_ctl(). */
+#define EPOLL_CTL_ADD 1 /* Add a file descriptor to the interface. */
+#define EPOLL_CTL_DEL 2 /* Remove a file descriptor from the interface. */
+#define EPOLL_CTL_MOD 3 /* Change file descriptor epoll_event structure. */
+
+
+typedef union epoll_data
+{
+ void *ptr;
+ int fd;
+ uint32_t u32;
+ uint64_t u64;
+} epoll_data_t;
+
+struct epoll_event
+{
+ uint32_t events; /* Epoll events */
+ epoll_data_t data; /* User data variable */
+};
+
+
+__BEGIN_DECLS
+
+/* Creates an epoll instance. Returns an fd for the new instance.
+ The "size" parameter is a hint specifying the number of file
+ descriptors to be associated with the new instance. The fd
+ returned by epoll_create() should be closed with close(). */
+extern int epoll_create (int __size) __THROW;
+
+/* Same as epoll_create but with an additional FLAGS parameter. */
+extern int epoll_create2 (int __size, int __flags) __THROW;
+
+
+/* Manipulate an epoll instance "epfd". Returns 0 in case of success,
+ -1 in case of error ( the "errno" variable will contain the
+ specific error code ) The "op" parameter is one of the EPOLL_CTL_*
+ constants defined above. The "fd" parameter is the target of the
+ operation. The "event" parameter describes which events the caller
+ is interested in and any associated user data. */
+extern int epoll_ctl (int __epfd, int __op, int __fd,
+ struct epoll_event *__event) __THROW;
+
+
+/* Wait for events on an epoll instance "epfd". Returns the number of
+ triggered events returned in "events" buffer. Or -1 in case of
+ error with the "errno" variable set to the specific error code. The
+ "events" parameter is a buffer that will contain triggered
+ events. The "maxevents" is the maximum number of events to be
+ returned ( usually size of "events" ). The "timeout" parameter
+ specifies the maximum wait time in milliseconds (-1 == infinite).
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern int epoll_wait (int __epfd, struct epoll_event *__events,
+ int __maxevents, int __timeout);
+
+
+/* Same as epoll_wait, but the thread's signal mask is temporarily
+ and atomically replaced with the one provided as parameter.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern int epoll_pwait (int __epfd, struct epoll_event *__events,
+ int __maxevents, int __timeout,
+ __const __sigset_t *__ss);
+
+__END_DECLS
+
+#endif /* sys/epoll.h */
diff --git a/libc/sysdeps/unix/sysv/linux/alpha/sys/eventfd.h b/libc/sysdeps/unix/sysv/linux/alpha/sys/eventfd.h
new file mode 100644
index 000000000..c8ce55462
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/alpha/sys/eventfd.h
@@ -0,0 +1,52 @@
+/* Copyright (C) 2007, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_EVENTFD_H
+#define _SYS_EVENTFD_H 1
+
+#include <stdint.h>
+
+
+/* Type for event counter. */
+typedef uint64_t eventfd_t;
+
+/* Flags for signalfd. */
+enum
+ {
+ EFD_CLOEXEC = 010000000,
+#define EFD_CLOEXEC EFD_CLOEXEC
+ EFD_NONBLOCK = 04
+#define EFD_NONBLOCK EFD_NONBLOCK
+ };
+
+
+__BEGIN_DECLS
+
+/* Return file descriptor for generic event channel. Set initial
+ value to COUNT. */
+extern int eventfd (int __count, int __flags) __THROW;
+
+/* Read event counter and possibly wait for events. */
+extern int eventfd_read (int __fd, eventfd_t *__value);
+
+/* Increment event counter. */
+extern int eventfd_write (int __fd, eventfd_t value);
+
+__END_DECLS
+
+#endif /* sys/eventfd.h */
diff --git a/libc/sysdeps/unix/sysv/linux/alpha/sys/inotify.h b/libc/sysdeps/unix/sysv/linux/alpha/sys/inotify.h
new file mode 100644
index 000000000..d61c700d5
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/alpha/sys/inotify.h
@@ -0,0 +1,105 @@
+/* Copyright (C) 2005, 2006, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_INOTIFY_H
+#define _SYS_INOTIFY_H 1
+
+#include <stdint.h>
+
+
+/* Flags for the parameter of inotify_init1. */
+enum
+ {
+ IN_CLOEXEC = 010000000,
+#define IN_CLOEXEC IN_CLOEXEC
+ IN_NONBLOCK = 04
+#define IN_NONBLOCK IN_NONBLOCK
+ };
+
+
+/* Structure describing an inotify event. */
+struct inotify_event
+{
+ int wd; /* Watch descriptor. */
+ uint32_t mask; /* Watch mask. */
+ uint32_t cookie; /* Cookie to synchronize two events. */
+ uint32_t len; /* Length (including NULs) of name. */
+ char name __flexarr; /* Name. */
+};
+
+
+/* Supported events suitable for MASK parameter of INOTIFY_ADD_WATCH. */
+#define IN_ACCESS 0x00000001 /* File was accessed. */
+#define IN_MODIFY 0x00000002 /* File was modified. */
+#define IN_ATTRIB 0x00000004 /* Metadata changed. */
+#define IN_CLOSE_WRITE 0x00000008 /* Writtable file was closed. */
+#define IN_CLOSE_NOWRITE 0x00000010 /* Unwrittable file closed. */
+#define IN_CLOSE (IN_CLOSE_WRITE | IN_CLOSE_NOWRITE) /* Close. */
+#define IN_OPEN 0x00000020 /* File was opened. */
+#define IN_MOVED_FROM 0x00000040 /* File was moved from X. */
+#define IN_MOVED_TO 0x00000080 /* File was moved to Y. */
+#define IN_MOVE (IN_MOVED_FROM | IN_MOVED_TO) /* Moves. */
+#define IN_CREATE 0x00000100 /* Subfile was created. */
+#define IN_DELETE 0x00000200 /* Subfile was deleted. */
+#define IN_DELETE_SELF 0x00000400 /* Self was deleted. */
+#define IN_MOVE_SELF 0x00000800 /* Self was moved. */
+
+/* Events sent by the kernel. */
+#define IN_UNMOUNT 0x00002000 /* Backing fs was unmounted. */
+#define IN_Q_OVERFLOW 0x00004000 /* Event queued overflowed. */
+#define IN_IGNORED 0x00008000 /* File was ignored. */
+
+/* Helper events. */
+#define IN_CLOSE (IN_CLOSE_WRITE | IN_CLOSE_NOWRITE) /* Close. */
+#define IN_MOVE (IN_MOVED_FROM | IN_MOVED_TO) /* Moves. */
+
+/* Special flags. */
+#define IN_ONLYDIR 0x01000000 /* Only watch the path if it is a
+ directory. */
+#define IN_DONT_FOLLOW 0x02000000 /* Do not follow a sym link. */
+#define IN_MASK_ADD 0x20000000 /* Add to the mask of an already
+ existing watch. */
+#define IN_ISDIR 0x40000000 /* Event occurred against dir. */
+#define IN_ONESHOT 0x80000000 /* Only send event once. */
+
+/* All events which a program can wait on. */
+#define IN_ALL_EVENTS (IN_ACCESS | IN_MODIFY | IN_ATTRIB | IN_CLOSE_WRITE \
+ | IN_CLOSE_NOWRITE | IN_OPEN | IN_MOVED_FROM \
+ | IN_MOVED_TO | IN_CREATE | IN_DELETE \
+ | IN_DELETE_SELF | IN_MOVE_SELF)
+
+
+__BEGIN_DECLS
+
+/* Create and initialize inotify instance. */
+extern int inotify_init (void) __THROW;
+
+/* Create and initialize inotify instance. */
+extern int inotify_init1 (int __flags) __THROW;
+
+/* Add watch of object NAME to inotify instance FD. Notify about
+ events specified by MASK. */
+extern int inotify_add_watch (int __fd, const char *__name, uint32_t __mask)
+ __THROW;
+
+/* Remove the watch specified by WD from the inotify instance FD. */
+extern int inotify_rm_watch (int __fd, uint32_t __wd) __THROW;
+
+__END_DECLS
+
+#endif /* sys/inotify.h */
diff --git a/libc/sysdeps/unix/sysv/linux/alpha/sys/signalfd.h b/libc/sysdeps/unix/sysv/linux/alpha/sys/signalfd.h
new file mode 100644
index 000000000..a820eafe7
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/alpha/sys/signalfd.h
@@ -0,0 +1,66 @@
+/* Copyright (C) 2007, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_SIGNALFD_H
+#define _SYS_SIGNALFD_H 1
+
+#define __need_sigset_t
+#include <signal.h>
+#include <stdint.h>
+
+
+struct signalfd_siginfo
+{
+ uint32_t ssi_signo;
+ int32_t ssi_errno;
+ int32_t ssi_code;
+ uint32_t ssi_pid;
+ uint32_t ssi_uid;
+ int32_t ssi_fd;
+ uint32_t ssi_tid;
+ uint32_t ssi_band;
+ uint32_t ssi_overrun;
+ uint32_t ssi_trapno;
+ int32_t ssi_status;
+ int32_t ssi_int;
+ uint64_t ssi_ptr;
+ uint64_t ssi_utime;
+ uint64_t ssi_stime;
+ uint64_t ssi_addr;
+ uint8_t __pad[48];
+};
+
+/* Flags for signalfd. */
+enum
+ {
+ SFD_CLOEXEC = 010000000,
+#define SFD_CLOEXEC SFD_CLOEXEC
+ SFD_NONBLOCK = 04
+#define SFD_NONBLOCK SFD_NONBLOCK
+ };
+
+__BEGIN_DECLS
+
+/* Request notification for delivery of signals in MASK to be
+ performed using descriptor FD.*/
+extern int signalfd (int __fd, const sigset_t *__mask, int __flags)
+ __nonnull ((2)) __THROW;
+
+__END_DECLS
+
+#endif /* sys/signalfd.h */
diff --git a/libc/sysdeps/unix/sysv/linux/alpha/sys/timerfd.h b/libc/sysdeps/unix/sysv/linux/alpha/sys/timerfd.h
new file mode 100644
index 000000000..09d6ccf6c
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/alpha/sys/timerfd.h
@@ -0,0 +1,60 @@
+/* Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_TIMERFD_H
+#define _SYS_TIMERFD_H 1
+
+#include <time.h>
+
+
+/* Bits to be set in the FLAGS parameter of `timerfd_create'. */
+enum
+ {
+ TFD_CLOEXEC = 010000000,
+#define TFD_CLOEXEC TFD_CLOEXEC
+ TFD_NONBLOCK = 04
+#define TFD_NONBLOCK TFD_NONBLOCK
+ };
+
+
+/* Bits to be set in the FLAGS parameter of `timerfd_settime'. */
+enum
+ {
+ TFD_TIMER_ABSTIME = 1 << 0
+#define TFD_TIMER_ABSTIME TFD_TIMER_ABSTIME
+ };
+
+
+__BEGIN_DECLS
+
+/* Return file descriptor for new interval timer source. */
+extern int timerfd_create (clockid_t __clock_id, int __flags) __THROW;
+
+/* Set next expiration time of interval timer source UFD to UTMR. If
+ FLAGS has the TFD_TIMER_ABSTIME flag set the timeout value is
+ absolute. Optionally return the old expiration time in OTMR. */
+extern int timerfd_settime (int __ufd, int __flags,
+ __const struct itimerspec *__utmr,
+ struct itimerspec *__otmr) __THROW;
+
+/* Return the next expiration time of UFD. */
+extern int timerfd_gettime (int __ufd, struct itimerspec *__otmr) __THROW;
+
+__END_DECLS
+
+#endif /* sys/timerfd.h */
diff --git a/libc/sysdeps/unix/sysv/linux/bits/in.h b/libc/sysdeps/unix/sysv/linux/bits/in.h
index 433c033c7..b457a1790 100644
--- a/libc/sysdeps/unix/sysv/linux/bits/in.h
+++ b/libc/sysdeps/unix/sysv/linux/bits/in.h
@@ -70,6 +70,7 @@
#define IP_PMTUDISC_DONT 0 /* Never send DF frames. */
#define IP_PMTUDISC_WANT 1 /* Use per route hints. */
#define IP_PMTUDISC_DO 2 /* Always DF. */
+#define IP_PMTUDISC_PROBE 3 /* Ignore dst pmtu. */
/* To select the IP level. */
#define SOL_IP 0
@@ -162,6 +163,7 @@ struct in_pktinfo
#define IPV6_PMTUDISC_DONT 0 /* Never send DF frames. */
#define IPV6_PMTUDISC_WANT 1 /* Use per route hints. */
#define IPV6_PMTUDISC_DO 2 /* Always DF. */
+#define IPV6_PMTUDISC_PROBE 3 /* Ignore dst pmtu. */
/* Socket level values for IPv6. */
#define SOL_IPV6 41
diff --git a/libc/sysdeps/unix/sysv/linux/bits/resource.h b/libc/sysdeps/unix/sysv/linux/bits/resource.h
index 526cdaf53..95d64ed77 100644
--- a/libc/sysdeps/unix/sysv/linux/bits/resource.h
+++ b/libc/sysdeps/unix/sysv/linux/bits/resource.h
@@ -158,8 +158,16 @@ enum __rusage_who
#define RUSAGE_SELF RUSAGE_SELF
/* All of its terminated child processes. */
- RUSAGE_CHILDREN = -1
+ RUSAGE_CHILDREN = -1,
#define RUSAGE_CHILDREN RUSAGE_CHILDREN
+
+#ifdef __USE_GNU
+ /* The calling thread. */
+ RUSAGE_THREAD = 1
+# define RUSAGE_THREAD RUSAGE_THREAD
+ /* Name for the same functionality on Solaris. */
+# define RUSAGE_LWP RUSAGE_THREAD
+#endif
};
#define __need_timeval
diff --git a/libc/sysdeps/unix/sysv/linux/bits/socket.h b/libc/sysdeps/unix/sysv/linux/bits/socket.h
index ceb60133e..87c3b9180 100644
--- a/libc/sysdeps/unix/sysv/linux/bits/socket.h
+++ b/libc/sysdeps/unix/sysv/linux/bits/socket.h
@@ -1,5 +1,5 @@
/* System-specific socket constants and types. Linux version.
- Copyright (C) 1991, 1992, 1994-2001, 2004, 2006, 2007
+ Copyright (C) 1991, 1992, 1994-2001, 2004, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -52,10 +52,22 @@ enum __socket_type
SOCK_SEQPACKET = 5, /* Sequenced, reliable, connection-based,
datagrams of fixed maximum length. */
#define SOCK_SEQPACKET SOCK_SEQPACKET
- SOCK_PACKET = 10 /* Linux specific way of getting packets
+ SOCK_DCCP = 6, /* Datagram Congestion Control Protocol. */
+#define SOCK_DCCP SOCK_DCCP
+ SOCK_PACKET = 10, /* Linux specific way of getting packets
at the dev level. For writing rarp and
other similar things on the user level. */
#define SOCK_PACKET SOCK_PACKET
+
+ /* Flags to be ORed into the type parameter of socket and socketpair and
+ used for the flags parameter of paccept. */
+
+ SOCK_CLOEXEC = 02000000, /* Atomically set close-on-exec flag for the
+ new descriptor(s). */
+#define SOCK_CLOEXEC SOCK_CLOEXEC
+ SOCK_NONBLOCK = 04000 /* Atomically mark descriptor(s) as
+ non-blocking. */
+#define SOCK_NONBLOCK SOCK_NONBLOCK
};
/* Protocol families. */
@@ -90,7 +102,8 @@ enum __socket_type
#define PF_BLUETOOTH 31 /* Bluetooth sockets. */
#define PF_IUCV 32 /* IUCV sockets. */
#define PF_RXRPC 33 /* RxRPC sockets. */
-#define PF_MAX 34 /* For now.. */
+#define PF_ISDN 34 /* mISDN sockets. */
+#define PF_MAX 35 /* For now.. */
/* Address families. */
#define AF_UNSPEC PF_UNSPEC
@@ -124,6 +137,7 @@ enum __socket_type
#define AF_BLUETOOTH PF_BLUETOOTH
#define AF_IUCV PF_IUCV
#define AF_RXRPC PF_RXRPC
+#define AF_ISDN PF_ISDN
#define AF_MAX PF_MAX
/* Socket level values. Others are defined in the appropriate headers.
diff --git a/libc/sysdeps/unix/sysv/linux/clock_getres.c b/libc/sysdeps/unix/sysv/linux/clock_getres.c
index 813d3ebbf..581ff22c7 100644
--- a/libc/sysdeps/unix/sysv/linux/clock_getres.c
+++ b/libc/sysdeps/unix/sysv/linux/clock_getres.c
@@ -1,5 +1,5 @@
/* clock_getres -- Get the resolution of a POSIX clockid_t. Linux version.
- Copyright (C) 2003,2004,2005,2006 Free Software Foundation, Inc.
+ Copyright (C) 2003,2004,2005,2006, 2008 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
@@ -121,7 +121,7 @@ maybe_syscall_getres_cpu (clockid_t clock_id, struct timespec *res)
return 0;
e = INTERNAL_SYSCALL_ERRNO (r, err);
-# ifndef __ASSUME_POSIX_TIMERS
+# ifndef __ASSUME_POSIX_TIMERS
if (e == ENOSYS)
{
__libc_missing_posix_timers = 1;
@@ -129,7 +129,7 @@ maybe_syscall_getres_cpu (clockid_t clock_id, struct timespec *res)
e = EINVAL;
}
else
-# endif
+# endif
{
if (e == EINVAL)
{
diff --git a/libc/sysdeps/unix/sysv/linux/configure b/libc/sysdeps/unix/sysv/linux/configure
index a8a9cc470..3966c3e42 100644
--- a/libc/sysdeps/unix/sysv/linux/configure
+++ b/libc/sysdeps/unix/sysv/linux/configure
@@ -120,7 +120,7 @@ case "$machine" in
arch_minimum_kernel=2.0.10
;;
powerpc/powerpc64)
- arch_minimum_kernel=2.4.19
+ arch_minimum_kernel=2.4.21
;;
s390/s390-32)
libc_cv_gcc_unwind_find_fde=yes
diff --git a/libc/sysdeps/unix/sysv/linux/configure.in b/libc/sysdeps/unix/sysv/linux/configure.in
index 43681f325..5330e98c2 100644
--- a/libc/sysdeps/unix/sysv/linux/configure.in
+++ b/libc/sysdeps/unix/sysv/linux/configure.in
@@ -80,7 +80,7 @@ case "$machine" in
arch_minimum_kernel=2.0.10
;;
powerpc/powerpc64)
- arch_minimum_kernel=2.4.19
+ arch_minimum_kernel=2.4.21
;;
s390/s390-32)
libc_cv_gcc_unwind_find_fde=yes
diff --git a/libc/sysdeps/unix/sysv/linux/dl-osinfo.h b/libc/sysdeps/unix/sysv/linux/dl-osinfo.h
index b13b6cf1d..5271d4e4d 100644
--- a/libc/sysdeps/unix/sysv/linux/dl-osinfo.h
+++ b/libc/sysdeps/unix/sysv/linux/dl-osinfo.h
@@ -19,6 +19,7 @@
#include <kernel-features.h>
#include <dl-sysdep.h>
+#include <fcntl.h>
#include <stdint.h>
#ifndef MIN
diff --git a/libc/sysdeps/unix/sysv/linux/dl-sysdep.h b/libc/sysdeps/unix/sysv/linux/dl-sysdep.h
index f44fa9814..a3c2cb8e7 100644
--- a/libc/sysdeps/unix/sysv/linux/dl-sysdep.h
+++ b/libc/sysdeps/unix/sysv/linux/dl-sysdep.h
@@ -27,9 +27,7 @@
#define NEED_DL_SYSINFO_DSO 1
-/* The _dl_discover_osversion function is so far only needed in sysconf
- to check for kernels later than 2.6.23. */
-#if !defined __ASSEMBLER__ && __LINUX_KERNEL_VERSION < 0x020617
+#ifndef __ASSEMBLER__
/* Get version of the OS. */
extern int _dl_discover_osversion (void) attribute_hidden;
# define HAVE_DL_DISCOVER_OSVERSION 1
diff --git a/libc/sysdeps/unix/sysv/linux/eventfd.c b/libc/sysdeps/unix/sysv/linux/eventfd.c
index 180861aad..6ebfed86f 100644
--- a/libc/sysdeps/unix/sysv/linux/eventfd.c
+++ b/libc/sysdeps/unix/sysv/linux/eventfd.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2007, 2008 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
@@ -24,7 +24,10 @@
int
eventfd (int count, int flags)
{
- /* The system call has no flag parameter which is bad. So we have
+#ifdef __NR_eventfd1
+ return INLINE_SYSCALL (eventfd1, 1, flags);
+#else
+ /* The old system call has no flag parameter which is bad. So we have
to wait until we have to support to pass additional values to the
kernel (sys_indirect) before implementing setting flags like
O_NONBLOCK etc. */
@@ -34,10 +37,11 @@ eventfd (int count, int flags)
return -1;
}
-#ifdef __NR_eventfd
+# ifdef __NR_eventfd
return INLINE_SYSCALL (eventfd, 1, count);
-#else
+# else
__set_errno (ENOSYS);
return -1;
+# endif
#endif
}
diff --git a/libc/sysdeps/unix/sysv/linux/i386/bits/mman.h b/libc/sysdeps/unix/sysv/linux/i386/bits/mman.h
index 00cb98239..2b90c8d7d 100644
--- a/libc/sysdeps/unix/sysv/linux/i386/bits/mman.h
+++ b/libc/sysdeps/unix/sysv/linux/i386/bits/mman.h
@@ -63,6 +63,7 @@
# define MAP_NORESERVE 0x04000 /* Don't check for reservations. */
# define MAP_POPULATE 0x08000 /* Populate (prefault) pagetables. */
# define MAP_NONBLOCK 0x10000 /* Do not block on IO. */
+# define MAP_STACK 0x20000 /* Allocation is for a stack. */
#endif
/* Flags to `msync'. */
diff --git a/libc/sysdeps/unix/sysv/linux/i386/paccept.S b/libc/sysdeps/unix/sysv/linux/i386/paccept.S
new file mode 100644
index 000000000..02ad78dd4
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/i386/paccept.S
@@ -0,0 +1,135 @@
+/* Copyright (C) 1995-1998,2002,2003,2005,2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep-cancel.h>
+#include <socketcall.h>
+#include <tls.h>
+
+#define _NSIG 64
+
+#define P(a, b) P2(a, b)
+#define P2(a, b) a##b
+
+ .text
+/* The socket-oriented system calls are handled unusally in Linux.
+ They are all gated through the single `socketcall' system call number.
+ `socketcall' takes two arguments: the first is the subcode, specifying
+ which socket function is being called; and the second is a pointer to
+ the arguments to the specific function. */
+
+ENTRY(do_paccept)
+#ifdef SOCKOP_paccept
+ subl $6*4, %esp
+ cfi_adjust_cfa_offset(6*4)
+
+ movl (%eax), %ecx
+ movl %ecx, (%esp)
+ movl 4(%eax), %ecx
+ movl %ecx, 4(%esp)
+ movl 8(%eax), %ecx
+ movl %ecx, 8(%esp)
+ movl 12(%eax), %ecx
+ movl %ecx, 12(%esp)
+ movl $(_NSIG / 8), 16(%esp)
+ movl 16(%eax), %ecx
+ movl %ecx, 20(%esp)
+
+ movl $SYS_ify(socketcall), %eax /* System call number in %eax. */
+
+ movl $SOCKOP_paccept, %ebx /* Subcode is first arg to syscall. */
+ movl %esp, %ecx /* Address of args is 2nd arg. */
+
+ /* Do the system call trap. */
+ ENTER_KERNEL
+
+ addl $6*4, %esp
+ cfi_adjust_cfa_offset(-6*4)
+
+ /* %eax is < 0 if there was an error. */
+ cmpl $-125, %eax
+ jae SYSCALL_ERROR_LABEL
+#else
+ movl $-ENOSYS, %eax
+ jmp SYSCALL_ERROR_LABEL
+
+ .section .gnu.glibc-stub.paccept
+ .previous
+ .section .gnu.warning.paccept
+ .string "warning: paccept is not implemented and will always fail"
+ .previous
+#endif
+L(pseudo_end):
+ ret
+PSEUDO_END(do_paccept)
+
+
+ .globl paccept
+ENTRY (paccept)
+#ifdef CENABLE
+ SINGLE_THREAD_P
+ jne 1f
+#endif
+
+ /* Save registers. */
+ movl %ebx, %edx
+ cfi_register (3, 2)
+
+ lea 4(%esp), %eax
+ call do_paccept
+
+ /* Restore registers. */
+ movl %edx, %ebx
+ cfi_restore (3)
+
+ ret
+
+#ifdef CENABLE
+ /* We need one more register. */
+1: pushl %esi
+ cfi_adjust_cfa_offset(4)
+
+ /* Enable asynchronous cancellation. */
+ CENABLE
+ movl %eax, %esi
+ cfi_offset(6, -8) /* %esi */
+
+ /* Save registers. */
+ movl %ebx, %edx
+ cfi_register (3, 2)
+
+ lea 8(%esp), %eax
+ call do_paccept
+
+ /* Restore registers. */
+ movl %edx, %ebx
+ cfi_restore (3)
+
+ /* Restore the cancellation. */
+ xchgl %esi, %eax
+ CDISABLE
+
+ /* Restore registers. */
+ movl %esi, %eax
+ popl %esi
+ cfi_restore (6)
+ cfi_adjust_cfa_offset(-4)
+
+ /* Successful; return the syscall's value. */
+ ret
+#endif
+PSEUDO_END (paccept)
diff --git a/libc/sysdeps/unix/sysv/linux/i386/vfork.S b/libc/sysdeps/unix/sysv/linux/i386/vfork.S
index eefd4b49c..2494d9bef 100644
--- a/libc/sysdeps/unix/sysv/linux/i386/vfork.S
+++ b/libc/sysdeps/unix/sysv/linux/i386/vfork.S
@@ -1,4 +1,4 @@
-/* Copyright (C) 1999, 2002, 2004, 2005 Free Software Foundation, Inc.
+/* Copyright (C) 1999, 2002, 2004, 2005, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Andreas Schwab <schwab@gnu.org>.
@@ -34,6 +34,7 @@ ENTRY (__vfork)
/* Pop the return PC value into ECX. */
popl %ecx
cfi_adjust_cfa_offset (-4)
+ cfi_register (%eip, %ecx)
#ifdef SAVE_PID
SAVE_PID
diff --git a/libc/sysdeps/unix/sysv/linux/ifaddrs.c b/libc/sysdeps/unix/sysv/linux/ifaddrs.c
index 9aa9abac3..150ec8a9b 100644
--- a/libc/sysdeps/unix/sysv/linux/ifaddrs.c
+++ b/libc/sysdeps/unix/sysv/linux/ifaddrs.c
@@ -1,5 +1,5 @@
/* getifaddrs -- get names and addresses of all network interfaces
- Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 2003-2007, 2008 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
@@ -49,6 +49,22 @@ int __no_netlink_support attribute_hidden;
#endif
+/* There is a problem with this type. The address length for
+ Infiniband sockets is much longer than the 8 bytes allocated in the
+ sockaddr_ll definition. Hence we use here a special
+ definition. */
+struct sockaddr_ll_max
+ {
+ unsigned short int sll_family;
+ unsigned short int sll_protocol;
+ int sll_ifindex;
+ unsigned short int sll_hatype;
+ unsigned char sll_pkttype;
+ unsigned char sll_halen;
+ unsigned char sll_addr[24];
+ };
+
+
/* struct to hold the data for one ifaddrs entry, so we can allocate
everything at once. */
struct ifaddrs_storage
@@ -59,7 +75,7 @@ struct ifaddrs_storage
/* Save space for the biggest of the four used sockaddr types and
avoid a lot of casts. */
struct sockaddr sa;
- struct sockaddr_ll sl;
+ struct sockaddr_ll_max sl;
struct sockaddr_in s4;
struct sockaddr_in6 s6;
} addr, netmask, broadaddr;
@@ -307,7 +323,7 @@ map_newlink (int index, struct ifaddrs_storage *ifas, int *map, int max)
/* Create a linked list of `struct ifaddrs' structures, one for each
network interface on the host machine. If successful, store the
- list in *IFAP and return 0. On errors, return -1 and set `errno'. */
+ list in *IFAP and 2004, 2005, 2006, return 0. On errors, return -1 and set `errno'. */
int
getifaddrs (struct ifaddrs **ifap)
{
diff --git a/libc/sysdeps/unix/sysv/linux/kernel-features.h b/libc/sysdeps/unix/sysv/linux/kernel-features.h
index 01baab090..6031eae2d 100644
--- a/libc/sysdeps/unix/sysv/linux/kernel-features.h
+++ b/libc/sysdeps/unix/sysv/linux/kernel-features.h
@@ -1,6 +1,6 @@
/* Set flags signalling availability of kernel features based on given
kernel version number.
- Copyright (C) 1999-2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1999-2006, 2007, 2008 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
@@ -488,7 +488,26 @@
# define __ASSUME_FALLOCATE 1
#endif
+/* Support for various CLOEXEC and NONBLOCK flags was added for x86,
+ x86-64, PPC, IA-64, SPARC< and S390 in 2.6.23. */
+#if __LINUX_KERNEL_VERSION >= 0x020617 \
+ && (defined __i386__ || defined __x86_64__ || defined __powerpc__ \
+ || defined __ia64__ || defined __sparc__ || defined __s390__)
+# define __ASSUME_O_CLOEXEC 1
+#endif
+
/* Support for ADJ_OFFSET_SS_READ was added in 2.6.24. */
#if __LINUX_KERNEL_VERSION >= 0x020618
# define __ASSUME_ADJ_OFFSET_SS_READ 1
#endif
+
+/* Support for various CLOEXEC and NONBLOCK flags was added for x86,
+ x86-64, PPC, IA-64, and SPARC in 2.6.27. */
+#if __LINUX_KERNEL_VERSION >= 0x02061b \
+ && (defined __i386__ || defined __x86_64__ || defined __powerpc__ \
+ || defined __ia64__ || defined __sparc__ || __s390__)
+# define __ASSUME_SOCK_CLOEXEC 1
+# define __ASSUME_IN_NONBLOCK 1
+# define __ASSUME_PIPE2 1
+# define __ASSUME_PACCEPT 1
+#endif
diff --git a/libc/sysdeps/unix/sysv/linux/net/ethernet.h b/libc/sysdeps/unix/sysv/linux/net/ethernet.h
index 7ca8e8348..0242d5899 100644
--- a/libc/sysdeps/unix/sysv/linux/net/ethernet.h
+++ b/libc/sysdeps/unix/sysv/linux/net/ethernet.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997, 1999, 2001 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 1999, 2001, 2008 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
@@ -45,9 +45,17 @@ struct ether_header
/* Ethernet protocol ID's */
#define ETHERTYPE_PUP 0x0200 /* Xerox PUP */
+#define ETHERTYPE_SPRITE 0x0500 /* Sprite */
#define ETHERTYPE_IP 0x0800 /* IP */
#define ETHERTYPE_ARP 0x0806 /* Address resolution */
#define ETHERTYPE_REVARP 0x8035 /* Reverse ARP */
+#define ETHERTYPE_AT 0x809B /* AppleTalk protocol */
+#define ETHERTYPE_AARP 0x80F3 /* AppleTalk ARP */
+#define ETHERTYPE_VLAN 0x8100 /* IEEE 802.1Q VLAN tagging */
+#define ETHERTYPE_IPX 0x8137 /* IPX */
+#define ETHERTYPE_IPV6 0x86dd /* IP protocol version 6 */
+#define ETHERTYPE_LOOPBACK 0x9000 /* used to test interfaces */
+
#define ETHER_ADDR_LEN ETH_ALEN /* size of ethernet addr */
#define ETHER_TYPE_LEN 2 /* bytes in type field */
diff --git a/libc/sysdeps/unix/sysv/linux/opensock.c b/libc/sysdeps/unix/sysv/linux/opensock.c
index 95559eb79..191d72011 100644
--- a/libc/sysdeps/unix/sysv/linux/opensock.c
+++ b/libc/sysdeps/unix/sysv/linux/opensock.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1999, 2001, 2002, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 1999, 2001, 2002, 2007, 2008 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
@@ -22,6 +22,7 @@
#include <string.h>
#include <unistd.h>
#include <sys/socket.h>
+#include <kernel-features.h>
/* Return a socket of any type. The socket can be used in subsequent
ioctl calls to talk to the kernel. */
@@ -70,7 +71,24 @@ __opensock (void)
{
assert (last_type != 0);
- result = __socket (last_family, last_type, 0);
+#ifdef SOCK_CLOEXEC
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec >= 0)
+# endif
+ {
+ result = __socket (last_family, last_type | SOCK_CLOEXEC, 0);
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec == 0)
+ __have_sock_cloexec = result != -1 || errno != EINVAL ? 1 : -1;
+# endif
+ }
+#endif
+#ifndef __ASSUME_SOCK_CLOEXEC
+# ifdef SOCK_CLOEXEC
+ if (__have_sock_cloexec < 0)
+# endif
+ result = __socket (last_family, last_type, 0);
+#endif
if (result != -1 || errno != EAFNOSUPPORT)
/* Maybe the socket type isn't supported anymore (module is
unloaded). In this case again try to find the type. */
@@ -105,7 +123,24 @@ __opensock (void)
if (afs[cnt].family == AF_NETROM || afs[cnt].family == AF_X25)
type = SOCK_SEQPACKET;
- result = __socket (afs[cnt].family, type, 0);
+#ifdef SOCK_CLOEXEC
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec >= 0)
+# endif
+ {
+ result = __socket (afs[cnt].family, type | SOCK_CLOEXEC, 0);
+# ifndef __ASSUME_SOCK_CLOEXEC
+ if (__have_sock_cloexec == 0)
+ __have_sock_cloexec = result != -1 || errno != EINVAL ? 1 : -1;
+# endif
+ }
+#endif
+#ifndef __ASSUME_SOCK_CLOEXEC
+# ifdef SOCK_CLOEXEC
+ if (__have_sock_cloexec < 0)
+# endif
+ result = __socket (afs[cnt].family, type, 0);
+#endif
if (result != -1)
{
/* Found an available family. */
diff --git a/libc/sysdeps/unix/sysv/linux/paccept.c b/libc/sysdeps/unix/sysv/linux/paccept.c
new file mode 100644
index 000000000..cc2979c0e
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/paccept.c
@@ -0,0 +1,54 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Ulrich Drepper <drepper@redhat.com>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <errno.h>
+#include <signal.h>
+#include <sys/socket.h>
+
+#include <sysdep-cancel.h>
+#include <sys/syscall.h>
+
+#ifdef __NR_paccept
+int
+paccept (int fd, __SOCKADDR_ARG addr, socklen_t *addr_len,
+ const __sigset_t *ss, int flags)
+{
+ if (SINGLE_THREAD_P)
+ return INLINE_SYSCALL (paccept, 6, fd, addr.__sockaddr__, addr_len, ss,
+ _NSIG / 8, flags);
+
+ int oldtype = LIBC_CANCEL_ASYNC ();
+
+ int result = INLINE_SYSCALL (paccept, 6, fd, addr.__sockaddr__, addr_len, ss,
+ _NSIG / 8, flags);
+
+ LIBC_CANCEL_RESET (oldtype);
+
+ return result;
+}
+#else
+int
+paccept (int fd, __SOCKADDR_ARG addr, socklen_t *addr_len,
+ const __sigset_t *ss, int flags)
+{
+ __set_errno (ENOSYS);
+ return -1;
+stub_warning (epoll_pwait)
+}
+#endif
diff --git a/libc/sysdeps/unix/sysv/linux/powerpc/bits/mman.h b/libc/sysdeps/unix/sysv/linux/powerpc/bits/mman.h
index e03ab7ff8..d5729a1f1 100644
--- a/libc/sysdeps/unix/sysv/linux/powerpc/bits/mman.h
+++ b/libc/sysdeps/unix/sysv/linux/powerpc/bits/mman.h
@@ -1,5 +1,5 @@
/* Definitions for POSIX memory map interface. Linux/PowerPC version.
- Copyright (C) 1997, 2000, 2003, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1997,2000,2003,2005,2006,2008 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
@@ -34,6 +34,7 @@
#define PROT_WRITE 0x2 /* Page can be written. */
#define PROT_EXEC 0x4 /* Page can be executed. */
#define PROT_NONE 0x0 /* Page can not be accessed. */
+#define PROT_SAO 0x10 /* Strong Access Ordering. */
#define PROT_GROWSDOWN 0x01000000 /* Extend change to start of
growsdown vma (mprotect only). */
#define PROT_GROWSUP 0x02000000 /* Extend change to start of
diff --git a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/fe_nomask.c b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/fe_nomask.c
index 8d3b9ad1f..50071e19e 100644
--- a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/fe_nomask.c
+++ b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/fe_nomask.c
@@ -1,5 +1,5 @@
/* Procedure definition for FE_NOMASK_ENV for Linux/ppc.
- Copyright (C) 2000, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2006, 2008 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,7 +17,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#include <fenv.h>
+#include <fenv_libc.h>
#include <errno.h>
#include <signal.h>
#include <unistd.h>
@@ -66,3 +66,4 @@ __fe_nomask_env (void)
return FE_ENABLED_ENV;
}
+libm_hidden_def (__fe_nomask_env)
diff --git a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_nomask.c b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_nomask.c
index 62f735514..d0cf8596e 100644
--- a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_nomask.c
+++ b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_nomask.c
@@ -1,5 +1,5 @@
/* Procedure definition for FE_NOMASK_ENV for Linux/ppc64.
- Copyright (C) 2003, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2003, 2006, 2008 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,7 +17,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#include <fenv.h>
+#include <fenv_libc.h>
#include <errno.h>
#include <sysdep.h>
#include <sys/syscall.h>
@@ -41,3 +41,4 @@ __fe_nomask_env (void)
#endif
return FE_ENABLED_ENV;
}
+libm_hidden_def (__fe_nomask_env)
diff --git a/libc/sysdeps/unix/sysv/linux/s390/bits/utmp.h b/libc/sysdeps/unix/sysv/linux/s390/bits/utmp.h
new file mode 100644
index 000000000..acb82b0ac
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/bits/utmp.h
@@ -0,0 +1,125 @@
+/* The `struct utmp' type, describing entries in the utmp file. GNU version.
+ Copyright (C) 1993, 1996, 1997, 1998, 1999, 2002, 2008
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _UTMP_H
+# error "Never include <bits/utmp.h> directly; use <utmp.h> instead."
+#endif
+
+#include <paths.h>
+#include <sys/time.h>
+#include <sys/types.h>
+#include <bits/wordsize.h>
+
+
+#define UT_LINESIZE 32
+#define UT_NAMESIZE 32
+#define UT_HOSTSIZE 256
+
+
+/* The structure describing an entry in the database of
+ previous logins. */
+struct lastlog
+ {
+#if __WORDSIZE == 32
+ int64_t ll_time;
+#else
+ __time_t ll_time;
+#endif
+ char ll_line[UT_LINESIZE];
+ char ll_host[UT_HOSTSIZE];
+ };
+
+
+/* The structure describing the status of a terminated process. This
+ type is used in `struct utmp' below. */
+struct exit_status
+ {
+ short int e_termination; /* Process termination status. */
+ short int e_exit; /* Process exit status. */
+ };
+
+
+/* The structure describing an entry in the user accounting database. */
+struct utmp
+{
+ short int ut_type; /* Type of login. */
+ pid_t ut_pid; /* Process ID of login process. */
+ char ut_line[UT_LINESIZE]; /* Devicename. */
+ char ut_id[4]; /* Inittab ID. */
+ char ut_user[UT_NAMESIZE]; /* Username. */
+ char ut_host[UT_HOSTSIZE]; /* Hostname for remote login. */
+ struct exit_status ut_exit; /* Exit status of a process marked
+ as DEAD_PROCESS. */
+/* The ut_session and ut_tv fields must be the same size when compiled
+ 32- and 64-bit. This allows data files and shared memory to be
+ shared between 32- and 64-bit applications. */
+#if __WORDSIZE == 32
+ int64_t ut_session; /* Session ID, used for windowing. */
+ struct
+ {
+ int64_t tv_sec; /* Seconds. */
+ int64_t tv_usec; /* Microseconds. */
+ } ut_tv; /* Time entry was made. */
+#else
+ long int ut_session; /* Session ID, used for windowing. */
+ struct timeval ut_tv; /* Time entry was made. */
+#endif
+
+ int32_t ut_addr_v6[4]; /* Internet address of remote host. */
+ char __unused[20]; /* Reserved for future use. */
+};
+
+/* Backwards compatibility hacks. */
+#define ut_name ut_user
+#ifndef _NO_UT_TIME
+/* We have a problem here: `ut_time' is also used otherwise. Define
+ _NO_UT_TIME if the compiler complains. */
+# define ut_time ut_tv.tv_sec
+#endif
+#define ut_xtime ut_tv.tv_sec
+#define ut_addr ut_addr_v6[0]
+
+
+/* Values for the `ut_type' field of a `struct utmp'. */
+#define EMPTY 0 /* No valid user accounting information. */
+
+#define RUN_LVL 1 /* The system's runlevel. */
+#define BOOT_TIME 2 /* Time of system boot. */
+#define NEW_TIME 3 /* Time after system clock changed. */
+#define OLD_TIME 4 /* Time when system clock changed. */
+
+#define INIT_PROCESS 5 /* Process spawned by the init process. */
+#define LOGIN_PROCESS 6 /* Session leader of a logged in user. */
+#define USER_PROCESS 7 /* Normal process. */
+#define DEAD_PROCESS 8 /* Terminated process. */
+
+#define ACCOUNTING 9
+
+/* Old Linux name for the EMPTY type. */
+#define UT_UNKNOWN EMPTY
+
+
+/* Tell the user that we have a modern system with UT_HOST, UT_PID,
+ UT_TYPE, UT_ID and UT_TV fields. */
+#define _HAVE_UT_TYPE 1
+#define _HAVE_UT_PID 1
+#define _HAVE_UT_ID 1
+#define _HAVE_UT_TV 1
+#define _HAVE_UT_HOST 1
diff --git a/libc/sysdeps/unix/sysv/linux/s390/bits/utmpx.h b/libc/sysdeps/unix/sysv/linux/s390/bits/utmpx.h
new file mode 100644
index 000000000..718e29039
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/bits/utmpx.h
@@ -0,0 +1,104 @@
+/* Structures and definitions for the user accounting database. GNU version.
+ Copyright (C) 1997, 1998, 2000, 2001, 2002, 2008
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _UTMPX_H
+# error "Never include <bits/utmpx.h> directly; use <utmpx.h> instead."
+#endif
+
+#include <bits/types.h>
+#include <sys/time.h>
+#include <bits/wordsize.h>
+
+
+#ifdef __USE_GNU
+# include <paths.h>
+# define _PATH_UTMPX _PATH_UTMP
+# define _PATH_WTMPX _PATH_WTMP
+#endif
+
+
+#define __UT_LINESIZE 32
+#define __UT_NAMESIZE 32
+#define __UT_HOSTSIZE 256
+
+
+/* The structure describing the status of a terminated process. This
+ type is used in `struct utmpx' below. */
+struct __exit_status
+ {
+#ifdef __USE_GNU
+ short int e_termination; /* Process termination status. */
+ short int e_exit; /* Process exit status. */
+#else
+ short int __e_termination; /* Process termination status. */
+ short int __e_exit; /* Process exit status. */
+#endif
+ };
+
+
+/* The structure describing an entry in the user accounting database. */
+struct utmpx
+{
+ short int ut_type; /* Type of login. */
+ __pid_t ut_pid; /* Process ID of login process. */
+ char ut_line[__UT_LINESIZE]; /* Devicename. */
+ char ut_id[4]; /* Inittab ID. */
+ char ut_user[__UT_NAMESIZE]; /* Username. */
+ char ut_host[__UT_HOSTSIZE]; /* Hostname for remote login. */
+ struct __exit_status ut_exit; /* Exit status of a process marked
+ as DEAD_PROCESS. */
+
+/* The fields ut_session and ut_tv must be the same size when compiled
+ 32- and 64-bit. This allows files and shared memory to be shared
+ between 32- and 64-bit applications. */
+#if __WORDSIZE == 32
+ __int64_t ut_session; /* Session ID, used for windowing. */
+ struct
+ {
+ __int64_t tv_sec; /* Seconds. */
+ __int64_t tv_usec; /* Microseconds. */
+ } ut_tv; /* Time entry was made. */
+#else
+ long int ut_session; /* Session ID, used for windowing. */
+ struct timeval ut_tv; /* Time entry was made. */
+#endif
+ __int32_t ut_addr_v6[4]; /* Internet address of remote host. */
+ char __unused[20]; /* Reserved for future use. */
+};
+
+
+/* Values for the `ut_type' field of a `struct utmpx'. */
+#define EMPTY 0 /* No valid user accounting information. */
+
+#ifdef __USE_GNU
+# define RUN_LVL 1 /* The system's runlevel. */
+#endif
+#define BOOT_TIME 2 /* Time of system boot. */
+#define NEW_TIME 3 /* Time after system clock changed. */
+#define OLD_TIME 4 /* Time when system clock changed. */
+
+#define INIT_PROCESS 5 /* Process spawned by the init process. */
+#define LOGIN_PROCESS 6 /* Session leader of a logged in user. */
+#define USER_PROCESS 7 /* Normal process. */
+#define DEAD_PROCESS 8 /* Terminated process. */
+
+#ifdef __USE_GNU
+# define ACCOUNTING 9 /* System accounting. */
+#endif
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/Makefile b/libc/sysdeps/unix/sysv/linux/s390/s390-32/Makefile
index 359c863c0..a509c9312 100644
--- a/libc/sysdeps/unix/sysv/linux/s390/s390-32/Makefile
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/Makefile
@@ -1,3 +1,8 @@
+ifeq ($(subdir),login)
+sysdep_routines += utmp32 utmpx32
+libutil-routines += login32
+endif
+
ifeq ($(subdir),misc)
sysdep_headers += sys/elf.h
endif
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/Versions b/libc/sysdeps/unix/sysv/linux/s390/s390-32/Versions
index 8d6a660cb..b6d608d0a 100644
--- a/libc/sysdeps/unix/sysv/linux/s390/s390-32/Versions
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/Versions
@@ -26,4 +26,27 @@ libc {
GLIBC_2.3.3 {
posix_fadvise64; posix_fallocate64;
}
+ GLIBC_2.9 {
+ getutent;
+ getutid;
+ getutline;
+ pututline;
+ updwtmp;
+ getutent_r;
+ getutid_r;
+ getutline_r;
+ getutxent;
+ getutxid;
+ getutxline;
+ pututxline;
+ updwtmpx;
+ getutmp;
+ getutmpx;
+ }
+}
+
+libutil {
+ GLIBC_2.9 {
+ login;
+ }
}
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutent.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutent.c
new file mode 100644
index 000000000..de3aa3f5b
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutent.c
@@ -0,0 +1,29 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <stdlib.h>
+#include <utmp.h>
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#include "login/getutent.c"
+
+default_symbol_version (__getutent, getutent, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutent_r.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutent_r.c
new file mode 100644
index 000000000..8c4be200c
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutent_r.c
@@ -0,0 +1,35 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <bits/libc-lock.h>
+#include <stdlib.h>
+#include <utmp.h>
+
+#include "utmp-compat.h"
+#include "utmp-private.h"
+
+weak_alias (__setutent, setutent)
+weak_alias (__endutent, endutent)
+
+#undef weak_alias
+#define weak_alias(n,a)
+#include "login/getutent_r.c"
+
+default_symbol_version (__getutent_r, getutent_r, UTMP_COMPAT_BASE);
+default_symbol_version (__pututline, pututline, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutid.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutid.c
new file mode 100644
index 000000000..5285481bb
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutid.c
@@ -0,0 +1,29 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <stdlib.h>
+#include <utmp.h>
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#include "login/getutid.c"
+
+default_symbol_version (__getutid, getutid, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutid_r.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutid_r.c
new file mode 100644
index 000000000..5989726db
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutid_r.c
@@ -0,0 +1,32 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <bits/libc-lock.h>
+#include <errno.h>
+#include <stdlib.h>
+#include <utmp.h>
+
+#include "utmp-compat.h"
+#include "utmp-private.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#include "login/getutid_r.c"
+
+default_symbol_version (__getutid_r, getutid_r, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutline.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutline.c
new file mode 100644
index 000000000..86b1add58
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutline.c
@@ -0,0 +1,29 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <stdlib.h>
+#include <utmp.h>
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#include "login/getutline.c"
+
+default_symbol_version (__getutline, getutline, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutline_r.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutline_r.c
new file mode 100644
index 000000000..6d40adbb9
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutline_r.c
@@ -0,0 +1,31 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <errno.h>
+#include <bits/libc-lock.h>
+#include <utmp.h>
+
+#include "utmp-compat.h"
+#include "utmp-private.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#include "login/getutline_r.c"
+
+default_symbol_version (__getutline_r, getutline_r, UTMP_COMPAT_BASE);;
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutmp.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutmp.c
new file mode 100644
index 000000000..2a14e1238
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutmp.c
@@ -0,0 +1,38 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <string.h>
+#include <utmp.h>
+/* This is an ugly hack but we must not see the getutmpx declaration. */
+#define getutmpx XXXgetutmpx
+#include <utmpx.h>
+#undef getutmpx
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#define getutmp __getutmp
+#define getutmpx __getutmpx
+#include "sysdeps/gnu/getutmp.c"
+#undef getutmp
+#undef getutmpx
+
+default_symbol_version (__getutmp, getutmp, UTMP_COMPAT_BASE);
+default_symbol_version (__getutmpx, getutmpx, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxent.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxent.c
new file mode 100644
index 000000000..38179a216
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxent.c
@@ -0,0 +1,31 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <utmp.h>
+#include <utmpx.h>
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#define getutxent __getutxent
+#include "login/getutxent.c"
+#undef getutxent
+
+default_symbol_version (__getutxent, getutxent, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxid.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxid.c
new file mode 100644
index 000000000..da1950185
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxid.c
@@ -0,0 +1,31 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <utmp.h>
+#include <utmpx.h>
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#define getutxid __getutxid
+#include "login/getutxid.c"
+#undef getutxid
+
+default_symbol_version (__getutxid, getutxid, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxline.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxline.c
new file mode 100644
index 000000000..9336150cf
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/getutxline.c
@@ -0,0 +1,31 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <utmp.h>
+#include <utmpx.h>
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#define getutxline __getutxline
+#include "login/getutxline.c"
+#undef getutxline
+
+default_symbol_version (__getutxline, getutxline, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/login.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/login.c
new file mode 100644
index 000000000..17a21c8d8
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/login.c
@@ -0,0 +1,36 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <assert.h>
+#include <errno.h>
+#include <limits.h>
+#include <string.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <utmp.h>
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#define login __login
+#include "login/login.c"
+#undef login
+
+default_symbol_version (__login, login, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/login32.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/login32.c
new file mode 100644
index 000000000..c9af995f1
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/login32.c
@@ -0,0 +1,37 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sys/types.h>
+#include <utmp.h>
+#include <libc-symbols.h>
+
+#include "utmp32.h"
+#include "utmp-convert.h"
+
+/* Write the given entry into utmp and wtmp. */
+void
+login32 (const struct utmp32 *entry)
+{
+ struct utmp in64;
+
+ utmp_convert32to64 (entry, &in64);
+ login (&in64);
+}
+
+symbol_version (login32, login, GLIBC_2.0);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/pututxline.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/pututxline.c
new file mode 100644
index 000000000..41f93d332
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/pututxline.c
@@ -0,0 +1,31 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <utmp.h>
+#include <utmpx.h>
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#define pututxline __pututxline
+#include "login/pututxline.c"
+#undef pututxline
+
+default_symbol_version (__pututxline, pututxline, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/updwtmp.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/updwtmp.c
new file mode 100644
index 000000000..72e06576a
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/updwtmp.c
@@ -0,0 +1,29 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <utmp.h>
+
+#include "utmp-compat.h"
+#include "utmp-private.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#include "sysdeps/gnu/updwtmp.c"
+
+default_symbol_version (__updwtmp, updwtmp, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/updwtmpx.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/updwtmpx.c
new file mode 100644
index 000000000..0f0b87d8a
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/updwtmpx.c
@@ -0,0 +1,31 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <utmp.h>
+#include <utmpx.h>
+
+#include "utmp-compat.h"
+
+#undef weak_alias
+#define weak_alias(n,a)
+#define updwtmpx __updwtmpx
+#include "login/updwtmpx.c"
+#undef updwtmpx
+
+default_symbol_version (__updwtmpx, updwtmpx, UTMP_COMPAT_BASE);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp-compat.h b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp-compat.h
new file mode 100644
index 000000000..064da5423
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp-compat.h
@@ -0,0 +1,22 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+/* This macro defines the glibc version tag at which the 64 bit struct
+ utmp functions have been added to the 32 bit glibc. */
+#define UTMP_COMPAT_BASE GLIBC_2.9
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp-convert.h b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp-convert.h
new file mode 100644
index 000000000..177da80f0
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp-convert.h
@@ -0,0 +1,17 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c
new file mode 100644
index 000000000..32a5d7137
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c
@@ -0,0 +1,185 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sys/types.h>
+#include <utmp.h>
+#include <errno.h>
+#include <libc-symbols.h>
+
+#include "utmp32.h"
+#include "utmp-convert.h"
+
+/* Allocate a static buffer to be returned to the caller. As well as
+ with the existing version of these functions the caller has to be
+ aware that the contents of this buffer will change with subsequent
+ calls. */
+#define ALLOCATE_UTMP32_OUT(OUT) \
+ static struct utmp32 *OUT = NULL; \
+ \
+ if (OUT == NULL) \
+ { \
+ OUT = malloc (sizeof (struct utmp32)); \
+ if (OUT == NULL) \
+ return NULL; \
+ }
+
+/* Perform a lookup for a utmp entry matching FIELD using function
+ FUNC. FIELD is converted to a 64 bit utmp and the result is
+ converted back to 32 bit utmp. */
+#define ACCESS_UTMP_ENTRY(FUNC, FIELD) \
+ struct utmp in64; \
+ struct utmp *out64; \
+ ALLOCATE_UTMP32_OUT (out32); \
+ \
+ utmp_convert32to64 (FIELD, &in64); \
+ out64 = FUNC (&in64); \
+ \
+ if (out64 == NULL) \
+ return NULL; \
+ \
+ utmp_convert64to32 (out64, out32); \
+ \
+ return out32;
+
+/* Search forward from the current point in the utmp file until the
+ next entry with a ut_type matching ID->ut_type. */
+struct utmp32 *
+getutid32 (const struct utmp32 *id)
+{
+ ACCESS_UTMP_ENTRY (getutid, id)
+}
+symbol_version (getutid32, getutid, GLIBC_2.0);
+
+/* Search forward from the current point in the utmp file until the
+ next entry with a ut_line matching LINE->ut_line. */
+struct utmp32 *
+getutline32 (const struct utmp32 *line)
+{
+ ACCESS_UTMP_ENTRY (getutline, line)
+}
+symbol_version (getutline32, getutline, GLIBC_2.0);
+
+/* Write out entry pointed to by UTMP_PTR into the utmp file. */
+struct utmp32 *
+pututline32 (const struct utmp32 *utmp_ptr)
+{
+ ACCESS_UTMP_ENTRY (pututline, utmp_ptr)
+}
+symbol_version (pututline32, pututline, GLIBC_2.0);
+
+/* Read next entry from a utmp-like file. */
+struct utmp32 *
+getutent32 (void)
+{
+ struct utmp *out64;
+ ALLOCATE_UTMP32_OUT (out32);
+
+ out64 = getutent ();
+ if (!out64)
+ return NULL;
+
+ utmp_convert64to32 (out64, out32);
+ return out32;
+}
+symbol_version (getutent32, getutent, GLIBC_2.0);
+
+/* Reentrant versions of the file for handling utmp files. */
+
+int
+getutent32_r (struct utmp32 *buffer, struct utmp32 **result)
+{
+ struct utmp out64;
+ struct utmp *out64p;
+ int ret;
+
+ ret = getutent_r (&out64, &out64p);
+ if (ret == -1)
+ {
+ *result = NULL;
+ return -1;
+ }
+
+ utmp_convert64to32 (out64p, buffer);
+ *result = buffer;
+
+ return 0;
+}
+symbol_version (getutent32_r, getutent_r, GLIBC_2.0);
+
+int
+getutid32_r (const struct utmp32 *id, struct utmp32 *buffer,
+ struct utmp32 **result)
+{
+ struct utmp in64;
+ struct utmp out64;
+ struct utmp *out64p;
+ int ret;
+
+ utmp_convert32to64 (id, &in64);
+
+ ret = getutid_r (&in64, &out64, &out64p);
+ if (ret == -1)
+ {
+ *result = NULL;
+ return -1;
+ }
+
+ utmp_convert64to32 (out64p, buffer);
+ *result = buffer;
+
+ return 0;
+}
+symbol_version (getutid32_r, getutid_r, GLIBC_2.0);
+
+int
+getutline32_r (const struct utmp32 *line,
+ struct utmp32 *buffer, struct utmp32 **result)
+{
+ struct utmp in64;
+ struct utmp out64;
+ struct utmp *out64p;
+ int ret;
+
+ utmp_convert32to64 (line, &in64);
+
+ ret = getutline_r (&in64, &out64, &out64p);
+ if (ret == -1)
+ {
+ *result = NULL;
+ return -1;
+ }
+
+ utmp_convert64to32 (out64p, buffer);
+ *result = buffer;
+
+ return 0;
+
+}
+symbol_version (getutline32_r, getutline_r, GLIBC_2.0);
+
+/* Append entry UTMP to the wtmp-like file WTMP_FILE. */
+void
+updwtmp32 (const char *wtmp_file, const struct utmp32 *utmp)
+{
+ struct utmp in32;
+
+ utmp_convert32to64 (utmp, &in32);
+ updwtmp (wtmp_file, &in32);
+}
+symbol_version (updwtmp32, updwtmp, GLIBC_2.0);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.h b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.h
new file mode 100644
index 000000000..335bc7fbd
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.h
@@ -0,0 +1,53 @@
+/* The `struct utmp' type, describing entries in the utmp file. GNU version.
+ Copyright (C) 1993, 1996, 1997, 1998, 1999, 2002, 2008
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _UTMP32_H
+#define _UTMP32_H 1
+
+#include <paths.h>
+#include <sys/time.h>
+#include <sys/types.h>
+#include <bits/wordsize.h>
+#include <utmp.h>
+
+/* The structure describing an entry in the user accounting database. */
+struct utmp32
+{
+ short int ut_type; /* Type of login. */
+ pid_t ut_pid; /* Process ID of login process. */
+ char ut_line[UT_LINESIZE]; /* Devicename. */
+ char ut_id[4]; /* Inittab ID. */
+ char ut_user[UT_NAMESIZE]; /* Username. */
+ char ut_host[UT_HOSTSIZE]; /* Hostname for remote login. */
+ struct exit_status ut_exit; /* Exit status of a process marked
+ as DEAD_PROCESS. */
+ int32_t ut_session; /* Session ID, used for windowing. */
+ struct
+ {
+ int32_t tv_sec; /* Seconds. */
+ int32_t tv_usec; /* Microseconds. */
+ } ut_tv; /* Time entry was made. */
+
+ int32_t ut_addr_v6[4]; /* Internet address of remote host. */
+ char __unused[20]; /* Reserved for future use. */
+};
+
+
+#endif /* utmp32.h */
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx-convert.h b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx-convert.h
new file mode 100644
index 000000000..a59989c27
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx-convert.h
@@ -0,0 +1,86 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+
+/* This file provides functions converting between the 32 and 64 bit
+ struct utmp variants. */
+
+#ifndef _UTMPX_CONVERT_H
+#define _UTMPX_CONVERT_H 1
+
+#include <string.h>
+#include "utmpx32.h"
+
+/* Convert the 64 bit struct utmpx value in FROM to the 32 bit version
+ returned in TO. */
+static inline void
+utmpx_convert64to32 (const struct utmpx *from, struct utmpx32 *to)
+{
+#if _HAVE_UT_TYPE - 0
+ to->ut_type = from->ut_type;
+#endif
+#if _HAVE_UT_PID - 0
+ to->ut_pid = from->ut_pid;
+#endif
+ memcpy (to->ut_line, from->ut_line, __UT_LINESIZE);
+ memcpy (to->ut_user, from->ut_user, __UT_NAMESIZE);
+#if _HAVE_UT_ID - 0
+ memcpy (to->ut_id, from->ut_id, 4);
+#endif
+#if _HAVE_UT_HOST - 0
+ memcpy (to->ut_host, from->ut_host, __UT_HOSTSIZE);
+#endif
+ to->ut_exit = from->ut_exit;
+ to->ut_session = (int32_t) from->ut_session;
+#if _HAVE_UT_TV - 0
+ to->ut_tv.tv_sec = (int32_t) from->ut_tv.tv_sec;
+ to->ut_tv.tv_usec = (int32_t) from->ut_tv.tv_usec;
+#endif
+ memcpy (to->ut_addr_v6, from->ut_addr_v6, 4 * 4);
+}
+
+/* Convert the 32 bit struct utmpx value in FROM to the 64 bit version
+ returned in TO. */
+static inline void
+utmpx_convert32to64 (const struct utmpx32 *from, struct utmpx *to)
+{
+#if _HAVE_UT_TYPE - 0
+ to->ut_type = from->ut_type;
+#endif
+#if _HAVE_UT_PID - 0
+ to->ut_pid = from->ut_pid;
+#endif
+ memcpy (to->ut_line, from->ut_line, __UT_LINESIZE);
+ memcpy (to->ut_user, from->ut_user, __UT_NAMESIZE);
+#if _HAVE_UT_ID - 0
+ memcpy (to->ut_id, from->ut_id, 4);
+#endif
+#if _HAVE_UT_HOST - 0
+ memcpy (to->ut_host, from->ut_host, __UT_HOSTSIZE);
+#endif
+ to->ut_exit = from->ut_exit;
+ to->ut_session = (int64_t) from->ut_session;
+#if _HAVE_UT_TV - 0
+ to->ut_tv.tv_sec = (int64_t) from->ut_tv.tv_sec;
+ to->ut_tv.tv_usec = (int64_t) from->ut_tv.tv_usec;
+#endif
+ memcpy (to->ut_addr_v6, from->ut_addr_v6, 4 * 4);
+}
+
+#endif /* utmpx-convert.h */
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c
new file mode 100644
index 000000000..69a1384db
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c
@@ -0,0 +1,140 @@
+/* Copyright (C) 2008 Free Software Foundation, Inc.
+ Contributed by Andreas Krebbel <Andreas.Krebbel@de.ibm.com>.
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sys/types.h>
+#include <utmp.h>
+#include <errno.h>
+#include <libc-symbols.h>
+
+#include "utmp32.h"
+#include "utmp-convert.h"
+
+#include "utmpx32.h"
+#include "utmpx-convert.h"
+
+/* Allocate a static buffer to be returned to the caller. As well as
+ with the existing version of these functions the caller has to be
+ aware that the contents of this buffer will change with subsequent
+ calls. */
+#define ALLOCATE_UTMPX32_OUT(OUT) \
+ static struct utmpx32 *OUT = NULL; \
+ \
+ if (OUT == NULL) \
+ { \
+ OUT = malloc (sizeof (struct utmpx32)); \
+ if (OUT == NULL) \
+ return NULL; \
+ }
+
+/* Perform a lookup for a utmpx entry matching FIELD using function
+ FUNC. FIELD is converted to a 64 bit utmpx and the result is
+ converted back to 32 bit utmpx. */
+#define ACCESS_UTMPX_ENTRY(FUNC, FIELD) \
+ struct utmpx in64; \
+ struct utmpx *out64; \
+ ALLOCATE_UTMPX32_OUT (out32); \
+ \
+ utmpx_convert32to64 (FIELD, &in64); \
+ out64 = FUNC (&in64); \
+ \
+ if (out64 == NULL) \
+ return NULL; \
+ \
+ utmpx_convert64to32 (out64, out32); \
+ \
+ return out32;
+
+
+/* Get the next entry from the user accounting database. */
+struct utmpx32 *
+getutxent32 (void)
+{
+ struct utmpx *out64;
+ ALLOCATE_UTMPX32_OUT (out32);
+
+ out64 = getutxent ();
+ if (!out64)
+ return NULL;
+
+ utmpx_convert64to32 (out64, out32);
+ return out32;
+
+}
+symbol_version (getutxent32, getutxent, GLIBC_2.1);
+
+/* Get the user accounting database entry corresponding to ID. */
+struct utmpx32 *
+getutxid32 (const struct utmpx32 *id)
+{
+ ACCESS_UTMPX_ENTRY (getutxid, id);
+}
+symbol_version (getutxid32, getutxid, GLIBC_2.1);
+
+/* Get the user accounting database entry corresponding to LINE. */
+struct utmpx32 *
+getutxline32 (const struct utmpx32 *line)
+{
+ ACCESS_UTMPX_ENTRY (getutxline, line);
+}
+symbol_version (getutxline32, getutxline, GLIBC_2.1);
+
+/* Write the entry UTMPX into the user accounting database. */
+struct utmpx32 *
+pututxline32 (const struct utmpx32 *utmpx)
+{
+ ACCESS_UTMPX_ENTRY (pututxline, utmpx);
+}
+symbol_version (pututxline32, pututxline, GLIBC_2.1);
+
+/* Append entry UTMP to the wtmpx-like file WTMPX_FILE. */
+void
+updwtmpx32 (const char *wtmpx_file, const struct utmpx32 *utmpx)
+{
+ struct utmpx in64;
+
+ utmpx_convert32to64 (utmpx, &in64);
+ updwtmpx (wtmpx_file, &in64);
+}
+symbol_version (updwtmpx32, updwtmpx, GLIBC_2.1);
+
+/* Copy the information in UTMPX to UTMP. */
+void
+getutmp32 (const struct utmpx32 *utmpx, struct utmp32 *utmp)
+{
+ struct utmpx in64;
+ struct utmp out64;
+
+ utmpx_convert32to64 (utmpx, &in64);
+ getutmp (&in64, &out64);
+ utmp_convert64to32 (&out64, utmp);
+}
+symbol_version (getutmp32, getutmp, GLIBC_2.1.1);
+
+/* Copy the information in UTMP to UTMPX. */
+void
+getutmpx32 (const struct utmp32 *utmp, struct utmpx32 *utmpx)
+{
+ struct utmp in64;
+ struct utmpx out64;
+
+ utmp_convert32to64 (utmp, &in64);
+ getutmpx (&in64, &out64);
+ utmpx_convert64to32 (&out64, utmpx);
+}
+symbol_version (getutmpx32, getutmpx, GLIBC_2.1.1);
diff --git a/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h
new file mode 100644
index 000000000..5f468ed68
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h
@@ -0,0 +1,52 @@
+/* The `struct utmp' type, describing entries in the utmp file. GNU version.
+ Copyright (C) 1993, 1996, 1997, 1998, 1999, 2002, 2008
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _UTMPX32_H
+#define _UTMPX32_H 1
+
+#include <paths.h>
+#include <sys/time.h>
+#include <sys/types.h>
+#include <bits/wordsize.h>
+#include <utmpx.h>
+
+/* The structure describing an entry in the user accounting database. */
+struct utmpx32
+{
+ short int ut_type; /* Type of login. */
+ __pid_t ut_pid; /* Process ID of login process. */
+ char ut_line[__UT_LINESIZE]; /* Devicename. */
+ char ut_id[4]; /* Inittab ID. */
+ char ut_user[__UT_NAMESIZE]; /* Username. */
+ char ut_host[__UT_HOSTSIZE]; /* Hostname for remote login. */
+ struct __exit_status ut_exit; /* Exit status of a process marked
+ as DEAD_PROCESS. */
+ __int64_t ut_session; /* Session ID, used for windowing. */
+ struct
+ {
+ __int64_t tv_sec; /* Seconds. */
+ __int64_t tv_usec; /* Microseconds. */
+ } ut_tv; /* Time entry was made. */
+
+ __int32_t ut_addr_v6[4]; /* Internet address of remote host. */
+ char __unused[20]; /* Reserved for future use. */
+};
+
+#endif /* utmpx32.h */
diff --git a/libc/sysdeps/unix/sysv/linux/signalfd.c b/libc/sysdeps/unix/sysv/linux/signalfd.c
index 09355ecd1..9898f2923 100644
--- a/libc/sysdeps/unix/sysv/linux/signalfd.c
+++ b/libc/sysdeps/unix/sysv/linux/signalfd.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2007, 2008 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
@@ -25,7 +25,10 @@
int
signalfd (int fd, const sigset_t *mask, int flags)
{
- /* The system call has no flag parameter which is bad. So we have
+#ifdef __NR_signalfd4
+ return INLINE_SYSCALL (signalfd4, 4, fd, mask, _NSIG / 8, flags);
+#else
+ /* The old system call has no flag parameter which is bad. So we have
to wait until we have to support to pass additional values to the
kernel (sys_indirect) before implementing setting flags like
O_NONBLOCK etc. */
@@ -35,10 +38,11 @@ signalfd (int fd, const sigset_t *mask, int flags)
return -1;
}
-#ifdef __NR_signalfd
+# ifdef __NR_signalfd
return INLINE_SYSCALL (signalfd, 3, fd, mask, _NSIG / 8);
-#else
+# else
__set_errno (ENOSYS);
return -1;
+# endif
#endif
}
diff --git a/libc/sysdeps/unix/sysv/linux/socketcall.h b/libc/sysdeps/unix/sysv/linux/socketcall.h
index d836534f3..24ec9ee2a 100644
--- a/libc/sysdeps/unix/sysv/linux/socketcall.h
+++ b/libc/sysdeps/unix/sysv/linux/socketcall.h
@@ -1,5 +1,5 @@
/* ID for functions called via socketcall system call.
- Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+ Copyright (C) 1995, 1996, 2008 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
@@ -18,7 +18,6 @@
02111-1307 USA. */
#ifndef _SYS_SOCKETCALL_H
-
#define _SYS_SOCKETCALL_H 1
/* Define unique numbers for the operations permitted on socket. Linux
@@ -44,5 +43,6 @@
#define SOCKOP_getsockopt 15
#define SOCKOP_sendmsg 16
#define SOCKOP_recvmsg 17
+#define SOCKOP_paccept 18
-#endif /* _SYS_SOCKETCALL_H */
+#endif /* sys/socketcall.h */
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/bits/resource.h b/libc/sysdeps/unix/sysv/linux/sparc/bits/resource.h
index 3f2c60014..22c087da4 100644
--- a/libc/sysdeps/unix/sysv/linux/sparc/bits/resource.h
+++ b/libc/sysdeps/unix/sysv/linux/sparc/bits/resource.h
@@ -174,8 +174,16 @@ enum __rusage_who
#define RUSAGE_SELF RUSAGE_SELF
/* All of its terminated child processes. */
- RUSAGE_CHILDREN = -1
+ RUSAGE_CHILDREN = -1,
#define RUSAGE_CHILDREN RUSAGE_CHILDREN
+
+#ifdef __USE_GNU
+ /* The calling thread. */
+ RUSAGE_THREAD = 1
+# define RUSAGE_THREAD RUSAGE_THREAD
+ /* Name for the same functionality on Solaris. */
+# define RUSAGE_LWP RUSAGE_THREAD
+#endif
};
#define __need_timeval
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/bits/socket.h b/libc/sysdeps/unix/sysv/linux/sparc/bits/socket.h
new file mode 100644
index 000000000..d43a3cdf7
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/bits/socket.h
@@ -0,0 +1,393 @@
+/* System-specific socket constants and types. Linux/SPARC version.
+ Copyright (C) 1991, 1992, 1994-2001, 2004, 2006, 2007, 2008
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef __BITS_SOCKET_H
+#define __BITS_SOCKET_H
+
+#ifndef _SYS_SOCKET_H
+# error "Never include <bits/socket.h> directly; use <sys/socket.h> instead."
+#endif
+
+#define __need_size_t
+#include <stddef.h>
+
+#include <sys/types.h>
+
+/* Type for length arguments in socket calls. */
+#ifndef __socklen_t_defined
+typedef __socklen_t socklen_t;
+# define __socklen_t_defined
+#endif
+
+/* Types of sockets. */
+enum __socket_type
+{
+ SOCK_STREAM = 1, /* Sequenced, reliable, connection-based
+ byte streams. */
+#define SOCK_STREAM SOCK_STREAM
+ SOCK_DGRAM = 2, /* Connectionless, unreliable datagrams
+ of fixed maximum length. */
+#define SOCK_DGRAM SOCK_DGRAM
+ SOCK_RAW = 3, /* Raw protocol interface. */
+#define SOCK_RAW SOCK_RAW
+ SOCK_RDM = 4, /* Reliably-delivered messages. */
+#define SOCK_RDM SOCK_RDM
+ SOCK_SEQPACKET = 5, /* Sequenced, reliable, connection-based,
+ datagrams of fixed maximum length. */
+#define SOCK_SEQPACKET SOCK_SEQPACKET
+ SOCK_DCCP = 6, /* Datagram Congestion Control Protocol. */
+#define SOCK_DCCP SOCK_DCCP
+ SOCK_PACKET = 10, /* Linux specific way of getting packets
+ at the dev level. For writing rarp and
+ other similar things on the user level. */
+#define SOCK_PACKET SOCK_PACKET
+
+ /* Flags to be ORed into the type parameter of socket and socketpair. */
+
+ SOCK_CLOEXEC = 0x400000, /* Atomically set close-on-exec flag for the
+ new descriptor(s). */
+#define SOCK_CLOEXEC SOCK_CLOEXEC
+ SOCK_NONBLOCK = 0x4000 /* Atomically mark descriptor(s) as
+ non-blocking. */
+#define SOCK_NONBLOCK SOCK_NONBLOCK
+};
+
+/* Protocol families. */
+#define PF_UNSPEC 0 /* Unspecified. */
+#define PF_LOCAL 1 /* Local to host (pipes and file-domain). */
+#define PF_UNIX PF_LOCAL /* POSIX name for PF_LOCAL. */
+#define PF_FILE PF_LOCAL /* Another non-standard name for PF_LOCAL. */
+#define PF_INET 2 /* IP protocol family. */
+#define PF_AX25 3 /* Amateur Radio AX.25. */
+#define PF_IPX 4 /* Novell Internet Protocol. */
+#define PF_APPLETALK 5 /* Appletalk DDP. */
+#define PF_NETROM 6 /* Amateur radio NetROM. */
+#define PF_BRIDGE 7 /* Multiprotocol bridge. */
+#define PF_ATMPVC 8 /* ATM PVCs. */
+#define PF_X25 9 /* Reserved for X.25 project. */
+#define PF_INET6 10 /* IP version 6. */
+#define PF_ROSE 11 /* Amateur Radio X.25 PLP. */
+#define PF_DECnet 12 /* Reserved for DECnet project. */
+#define PF_NETBEUI 13 /* Reserved for 802.2LLC project. */
+#define PF_SECURITY 14 /* Security callback pseudo AF. */
+#define PF_KEY 15 /* PF_KEY key management API. */
+#define PF_NETLINK 16
+#define PF_ROUTE PF_NETLINK /* Alias to emulate 4.4BSD. */
+#define PF_PACKET 17 /* Packet family. */
+#define PF_ASH 18 /* Ash. */
+#define PF_ECONET 19 /* Acorn Econet. */
+#define PF_ATMSVC 20 /* ATM SVCs. */
+#define PF_SNA 22 /* Linux SNA Project */
+#define PF_IRDA 23 /* IRDA sockets. */
+#define PF_PPPOX 24 /* PPPoX sockets. */
+#define PF_WANPIPE 25 /* Wanpipe API sockets. */
+#define PF_BLUETOOTH 31 /* Bluetooth sockets. */
+#define PF_IUCV 32 /* IUCV sockets. */
+#define PF_RXRPC 33 /* RxRPC sockets. */
+#define PF_ISDN 34 /* mISDN sockets. */
+#define PF_MAX 35 /* For now.. */
+
+/* Address families. */
+#define AF_UNSPEC PF_UNSPEC
+#define AF_LOCAL PF_LOCAL
+#define AF_UNIX PF_UNIX
+#define AF_FILE PF_FILE
+#define AF_INET PF_INET
+#define AF_AX25 PF_AX25
+#define AF_IPX PF_IPX
+#define AF_APPLETALK PF_APPLETALK
+#define AF_NETROM PF_NETROM
+#define AF_BRIDGE PF_BRIDGE
+#define AF_ATMPVC PF_ATMPVC
+#define AF_X25 PF_X25
+#define AF_INET6 PF_INET6
+#define AF_ROSE PF_ROSE
+#define AF_DECnet PF_DECnet
+#define AF_NETBEUI PF_NETBEUI
+#define AF_SECURITY PF_SECURITY
+#define AF_KEY PF_KEY
+#define AF_NETLINK PF_NETLINK
+#define AF_ROUTE PF_ROUTE
+#define AF_PACKET PF_PACKET
+#define AF_ASH PF_ASH
+#define AF_ECONET PF_ECONET
+#define AF_ATMSVC PF_ATMSVC
+#define AF_SNA PF_SNA
+#define AF_IRDA PF_IRDA
+#define AF_PPPOX PF_PPPOX
+#define AF_WANPIPE PF_WANPIPE
+#define AF_BLUETOOTH PF_BLUETOOTH
+#define AF_IUCV PF_IUCV
+#define AF_RXRPC PF_RXRPC
+#define AF_ISDN PF_ISDN
+#define AF_MAX PF_MAX
+
+/* Socket level values. Others are defined in the appropriate headers.
+
+ XXX These definitions also should go into the appropriate headers as
+ far as they are available. */
+#define SOL_RAW 255
+#define SOL_DECNET 261
+#define SOL_X25 262
+#define SOL_PACKET 263
+#define SOL_ATM 264 /* ATM layer (cell level). */
+#define SOL_AAL 265 /* ATM Adaption Layer (packet level). */
+#define SOL_IRDA 266
+
+/* Maximum queue length specifiable by listen. */
+#define SOMAXCONN 128
+
+/* Get the definition of the macro to define the common sockaddr members. */
+#include <bits/sockaddr.h>
+
+/* Structure describing a generic socket address. */
+struct sockaddr
+ {
+ __SOCKADDR_COMMON (sa_); /* Common data: address family and length. */
+ char sa_data[14]; /* Address data. */
+ };
+
+
+/* Structure large enough to hold any socket address (with the historical
+ exception of AF_UNIX). We reserve 128 bytes. */
+#define __ss_aligntype unsigned long int
+#define _SS_SIZE 128
+#define _SS_PADSIZE (_SS_SIZE - (2 * sizeof (__ss_aligntype)))
+
+struct sockaddr_storage
+ {
+ __SOCKADDR_COMMON (ss_); /* Address family, etc. */
+ __ss_aligntype __ss_align; /* Force desired alignment. */
+ char __ss_padding[_SS_PADSIZE];
+ };
+
+
+/* Bits in the FLAGS argument to `send', `recv', et al. */
+enum
+ {
+ MSG_OOB = 0x01, /* Process out-of-band data. */
+#define MSG_OOB MSG_OOB
+ MSG_PEEK = 0x02, /* Peek at incoming messages. */
+#define MSG_PEEK MSG_PEEK
+ MSG_DONTROUTE = 0x04, /* Don't use local routing. */
+#define MSG_DONTROUTE MSG_DONTROUTE
+#ifdef __USE_GNU
+ /* DECnet uses a different name. */
+ MSG_TRYHARD = MSG_DONTROUTE,
+# define MSG_TRYHARD MSG_DONTROUTE
+#endif
+ MSG_CTRUNC = 0x08, /* Control data lost before delivery. */
+#define MSG_CTRUNC MSG_CTRUNC
+ MSG_PROXY = 0x10, /* Supply or ask second address. */
+#define MSG_PROXY MSG_PROXY
+ MSG_TRUNC = 0x20,
+#define MSG_TRUNC MSG_TRUNC
+ MSG_DONTWAIT = 0x40, /* Nonblocking IO. */
+#define MSG_DONTWAIT MSG_DONTWAIT
+ MSG_EOR = 0x80, /* End of record. */
+#define MSG_EOR MSG_EOR
+ MSG_WAITALL = 0x100, /* Wait for a full request. */
+#define MSG_WAITALL MSG_WAITALL
+ MSG_FIN = 0x200,
+#define MSG_FIN MSG_FIN
+ MSG_SYN = 0x400,
+#define MSG_SYN MSG_SYN
+ MSG_CONFIRM = 0x800, /* Confirm path validity. */
+#define MSG_CONFIRM MSG_CONFIRM
+ MSG_RST = 0x1000,
+#define MSG_RST MSG_RST
+ MSG_ERRQUEUE = 0x2000, /* Fetch message from error queue. */
+#define MSG_ERRQUEUE MSG_ERRQUEUE
+ MSG_NOSIGNAL = 0x4000, /* Do not generate SIGPIPE. */
+#define MSG_NOSIGNAL MSG_NOSIGNAL
+ MSG_MORE = 0x8000, /* Sender will send more. */
+#define MSG_MORE MSG_MORE
+
+ MSG_CMSG_CLOEXEC = 0x40000000 /* Set close_on_exit for file
+ descriptor received through
+ SCM_RIGHTS. */
+#define MSG_CMSG_CLOEXEC MSG_CMSG_CLOEXEC
+ };
+
+
+/* Structure describing messages sent by
+ `sendmsg' and received by `recvmsg'. */
+struct msghdr
+ {
+ void *msg_name; /* Address to send to/receive from. */
+ socklen_t msg_namelen; /* Length of address data. */
+
+ struct iovec *msg_iov; /* Vector of data to send/receive into. */
+ size_t msg_iovlen; /* Number of elements in the vector. */
+
+ void *msg_control; /* Ancillary data (eg BSD filedesc passing). */
+ size_t msg_controllen; /* Ancillary data buffer length.
+ !! The type should be socklen_t but the
+ definition of the kernel is incompatible
+ with this. */
+
+ int msg_flags; /* Flags on received message. */
+ };
+
+/* Structure used for storage of ancillary data object information. */
+struct cmsghdr
+ {
+ size_t cmsg_len; /* Length of data in cmsg_data plus length
+ of cmsghdr structure.
+ !! The type should be socklen_t but the
+ definition of the kernel is incompatible
+ with this. */
+ int cmsg_level; /* Originating protocol. */
+ int cmsg_type; /* Protocol specific type. */
+#if (!defined __STRICT_ANSI__ && __GNUC__ >= 2) || __STDC_VERSION__ >= 199901L
+ __extension__ unsigned char __cmsg_data __flexarr; /* Ancillary data. */
+#endif
+ };
+
+/* Ancillary data object manipulation macros. */
+#if (!defined __STRICT_ANSI__ && __GNUC__ >= 2) || __STDC_VERSION__ >= 199901L
+# define CMSG_DATA(cmsg) ((cmsg)->__cmsg_data)
+#else
+# define CMSG_DATA(cmsg) ((unsigned char *) ((struct cmsghdr *) (cmsg) + 1))
+#endif
+#define CMSG_NXTHDR(mhdr, cmsg) __cmsg_nxthdr (mhdr, cmsg)
+#define CMSG_FIRSTHDR(mhdr) \
+ ((size_t) (mhdr)->msg_controllen >= sizeof (struct cmsghdr) \
+ ? (struct cmsghdr *) (mhdr)->msg_control : (struct cmsghdr *) 0)
+#define CMSG_ALIGN(len) (((len) + sizeof (size_t) - 1) \
+ & (size_t) ~(sizeof (size_t) - 1))
+#define CMSG_SPACE(len) (CMSG_ALIGN (len) \
+ + CMSG_ALIGN (sizeof (struct cmsghdr)))
+#define CMSG_LEN(len) (CMSG_ALIGN (sizeof (struct cmsghdr)) + (len))
+
+extern struct cmsghdr *__cmsg_nxthdr (struct msghdr *__mhdr,
+ struct cmsghdr *__cmsg) __THROW;
+#ifdef __USE_EXTERN_INLINES
+# ifndef _EXTERN_INLINE
+# define _EXTERN_INLINE __extern_inline
+# endif
+_EXTERN_INLINE struct cmsghdr *
+__NTH (__cmsg_nxthdr (struct msghdr *__mhdr, struct cmsghdr *__cmsg))
+{
+ if ((size_t) __cmsg->cmsg_len < sizeof (struct cmsghdr))
+ /* The kernel header does this so there may be a reason. */
+ return 0;
+
+ __cmsg = (struct cmsghdr *) ((unsigned char *) __cmsg
+ + CMSG_ALIGN (__cmsg->cmsg_len));
+ if ((unsigned char *) (__cmsg + 1) > ((unsigned char *) __mhdr->msg_control
+ + __mhdr->msg_controllen)
+ || ((unsigned char *) __cmsg + CMSG_ALIGN (__cmsg->cmsg_len)
+ > ((unsigned char *) __mhdr->msg_control + __mhdr->msg_controllen)))
+ /* No more entries. */
+ return 0;
+ return __cmsg;
+}
+#endif /* Use `extern inline'. */
+
+/* Socket level message types. This must match the definitions in
+ <linux/socket.h>. */
+enum
+ {
+ SCM_RIGHTS = 0x01 /* Transfer file descriptors. */
+#define SCM_RIGHTS SCM_RIGHTS
+#ifdef __USE_BSD
+ , SCM_CREDENTIALS = 0x02 /* Credentials passing. */
+# define SCM_CREDENTIALS SCM_CREDENTIALS
+#endif
+ };
+
+#ifdef __USE_GNU
+/* User visible structure for SCM_CREDENTIALS message */
+struct ucred
+{
+ pid_t pid; /* PID of sending process. */
+ uid_t uid; /* UID of sending process. */
+ gid_t gid; /* GID of sending process. */
+};
+#endif
+
+/* Ugly workaround for unclean kernel headers. */
+#if !defined __USE_MISC && !defined __USE_GNU
+# ifndef FIOGETOWN
+# define __SYS_SOCKET_H_undef_FIOGETOWN
+# endif
+# ifndef FIOSETOWN
+# define __SYS_SOCKET_H_undef_FIOSETOWN
+# endif
+# ifndef SIOCATMARK
+# define __SYS_SOCKET_H_undef_SIOCATMARK
+# endif
+# ifndef SIOCGPGRP
+# define __SYS_SOCKET_H_undef_SIOCGPGRP
+# endif
+# ifndef SIOCGSTAMP
+# define __SYS_SOCKET_H_undef_SIOCGSTAMP
+# endif
+# ifndef SIOCGSTAMPNS
+# define __SYS_SOCKET_H_undef_SIOCGSTAMPNS
+# endif
+# ifndef SIOCSPGRP
+# define __SYS_SOCKET_H_undef_SIOCSPGRP
+# endif
+#endif
+
+/* Get socket manipulation related informations from kernel headers. */
+#include <asm/socket.h>
+
+#if !defined __USE_MISC && !defined __USE_GNU
+# ifdef __SYS_SOCKET_H_undef_FIOGETOWN
+# undef __SYS_SOCKET_H_undef_FIOGETOWN
+# undef FIOGETOWN
+# endif
+# ifdef __SYS_SOCKET_H_undef_FIOSETOWN
+# undef __SYS_SOCKET_H_undef_FIOSETOWN
+# undef FIOSETOWN
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCATMARK
+# undef __SYS_SOCKET_H_undef_SIOCATMARK
+# undef SIOCATMARK
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCGPGRP
+# undef __SYS_SOCKET_H_undef_SIOCGPGRP
+# undef SIOCGPGRP
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCGSTAMP
+# undef __SYS_SOCKET_H_undef_SIOCGSTAMP
+# undef SIOCGSTAMP
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCGSTAMPNS
+# undef __SYS_SOCKET_H_undef_SIOCGSTAMPNS
+# undef SIOCGSTAMPNS
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCSPGRP
+# undef __SYS_SOCKET_H_undef_SIOCSPGRP
+# undef SIOCSPGRP
+# endif
+#endif
+
+/* Structure used to manipulate the SO_LINGER option. */
+struct linger
+ {
+ int l_onoff; /* Nonzero to linger on close. */
+ int l_linger; /* Time to linger. */
+ };
+
+#endif /* bits/socket.h */
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/Makefile b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/Makefile
index cd1b3fb79..8f7e76be2 100644
--- a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/Makefile
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/Makefile
@@ -2,6 +2,10 @@ asm-CPPFLAGS = -D__ASSEMBLY__
ASFLAGS-.os += -fPIC
LD += -melf32_sparc
+ifeq ($(subdir),stdlib)
+gen-as-const-headers += ucontext_i.sym
+endif
+
# When I get this to work, this is the right thing
ifeq ($(subdir),elf)
CFLAGS-rtld.c += -mcpu=v8
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/getcontext.S b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/getcontext.S
new file mode 100644
index 000000000..f8664a797
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/getcontext.S
@@ -0,0 +1,85 @@
+/* Save current context.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by David S. Miller <davem@davemloft.net>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+
+#include "ucontext_i.h"
+
+/* int __getcontext (ucontext_t *ucp)
+
+ Saves the machine context in UCP such that when it is activated,
+ it appears as if __getcontext() returned again.
+
+ This implementation is intended to be used for *synchronous* context
+ switches only. Therefore, it does not have to save anything
+ other than the PRESERVED state. */
+
+
+ENTRY(__getcontext)
+ save %sp, -112, %sp
+ st %g0, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_PSR]
+
+ /* In reality, we only use the GREG_PC value when setting
+ or swapping contexts. But we fill in NPC for completeness. */
+ add %i7, 8, %o0
+ st %o0, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_PC]
+ add %o0, 4, %o0
+ st %o0, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_NPC]
+
+ rd %y, %o1
+ st %o1, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_Y]
+
+ st %g1, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G1]
+ st %g2, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G2]
+ st %g3, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G3]
+ st %g4, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G4]
+ st %g5, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G5]
+ st %g6, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G6]
+ st %g7, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G7]
+
+ mov SIG_BLOCK, %o0
+ clr %o1
+ add %i0, UC_SIGMASK, %o2
+ mov 8, %o3
+ mov __NR_rt_sigprocmask, %g1
+ ta 0x10
+
+ /* Zero, success, return value. */
+ st %g0, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O0]
+ st %i1, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O1]
+ st %i2, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O2]
+ st %i3, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O3]
+ st %i4, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O4]
+ st %i5, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O5]
+ st %i6, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O6]
+ st %i7, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O7]
+
+ st %g0, [%i0 + UC_MCONTEXT + MC_GWINS]
+
+ /* Do not save FPU state, it is volatile across calls. */
+ stb %g0, [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_EN]
+
+ st %g0, [%i0 + UC_MCONTEXT + MC_XRS + XRS_ID]
+ st %g0, [%i0 + UC_MCONTEXT + MC_XRS + XRS_PTR]
+ jmpl %i7 + 8, %g0
+ restore %g0, %g0, %o0
+END(__getcontext)
+
+weak_alias (__getcontext, getcontext)
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/makecontext.c b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/makecontext.c
new file mode 100644
index 000000000..9b48dade6
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/makecontext.c
@@ -0,0 +1,93 @@
+/* Create new context.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by David S. Miller <davem@davemloft.net>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <stdarg.h>
+#include <stdint.h>
+#include <ucontext.h>
+
+/* Sets up the outgoing arguments and the program counter for a user
+ context for the requested function call.
+
+ Returning to the correct parent context is pretty simple on
+ Sparc. We only need to link up the register windows correctly.
+ Since global registers are clobbered by calls, we need not be
+ concernred about those, and thus is all could be worked out without
+ using a trampoline.
+
+ Except that we must deal with the signal mask, thus a trampoline
+ is unavoidable. 32-bit stackframe layout:
+ +-----------------------------------------+
+ | 7th and further parameters |
+ +-----------------------------------------+
+ | backup storage for initial 6 parameters |
+ +-----------------------------------------+
+ | struct return pointer |
+ +-----------------------------------------+
+ | 8 incoming registers |
+ +-----------------------------------------+
+ | 8 local registers |
+ %sp --> +-----------------------------------------+
+
+*/
+
+void
+__makecontext (ucontext_t *ucp, void (*func) (void), int argc, ...)
+{
+ extern void __start_context (void);
+ unsigned long int *sp;
+ va_list ap;
+ int i;
+
+ sp = (unsigned long int *) (ucp->uc_stack.ss_sp + ucp->uc_stack.ss_size);
+ sp -= 16 + 7 + argc;
+ sp = (unsigned long int *) (((uintptr_t) sp) & ~(8 - 1));
+
+ for (i = 0; i < 8; i++)
+ sp[i + 8] = ucp->uc_mcontext.gregs[REG_O0 + i];
+
+ /* The struct return pointer is essentially unused, so we can
+ place the link there. */
+ sp[16] = (unsigned long int) ucp->uc_link;
+
+ va_start (ap, argc);
+
+ /* Fill in outgoing arguments, including those which will
+ end up being passed on the stack. */
+ for (i = 0; i < argc; i++)
+ {
+ unsigned long int arg = va_arg (ap, unsigned long int);
+ if (i < 6)
+ ucp->uc_mcontext.gregs[REG_O0 + i] = arg;
+ else
+ sp[i + 23] = arg;
+ }
+
+ va_end (ap);
+
+ ucp->uc_mcontext.gregs[REG_O6] = (unsigned long int) sp;
+
+ ucp->uc_mcontext.gregs[REG_O7] = ((unsigned long int) __start_context) - 8;
+
+ ucp->uc_mcontext.gregs[REG_PC] = (unsigned long int) func;
+ ucp->uc_mcontext.gregs[REG_nPC] = ucp->uc_mcontext.gregs[REG_PC] + 4;
+}
+
+weak_alias (__makecontext, makecontext)
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/setcontext.S b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/setcontext.S
new file mode 100644
index 000000000..a38cd30c0
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/setcontext.S
@@ -0,0 +1,119 @@
+/* Install given context.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by David S. Miller <davem@davemloft.net>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <sys/trap.h>
+
+#include "ucontext_i.h"
+
+
+/* int __setcontext (const ucontext_t *ucp)
+
+ Restores the machine context in UCP and thereby resumes execution
+ in that context.
+
+ This implementation is intended to be used for *synchronous* context
+ switches only. Therefore, it does not have to restore anything
+ other than the PRESERVED state. */
+
+ENTRY(__setcontext)
+ save %sp, -112, %sp
+
+ mov SIG_SETMASK, %o0
+ add %i0, UC_SIGMASK, %o1
+ clr %o2
+ mov 8, %o3
+ mov __NR_rt_sigprocmask, %g1
+ ta 0x10
+
+ /* This is a bit on the expensive side, and we could optimize
+ the unwind similar to how the 32-bit sparc longjmp code
+ does if performance of this routine really matters. */
+ ta ST_FLUSH_WINDOWS
+
+ ldub [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_EN], %g1
+ cmp %g1, 0
+ be 1f
+ nop
+ ld [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_FSR], %fsr
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D0], %f0
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D2], %f2
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D4], %f4
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D6], %f6
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D8], %f8
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D10], %f10
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D12], %f12
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D14], %f14
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D16], %f16
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D18], %f18
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D20], %f20
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D22], %f22
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D24], %f24
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D26], %f26
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D28], %f28
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D30], %f30
+1:
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_Y], %g1
+ wr %g1, 0x0, %y
+
+ /* We specifically do not restore %g1 since we need it here as
+ a temporary. */
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G2], %g2
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G3], %g3
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G4], %g4
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G5], %g5
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G6], %g6
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G7], %g7
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O1], %i1
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O2], %i2
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O3], %i3
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O4], %i4
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O5], %i5
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O6], %i6
+ restore
+ ld [%o0 + UC_MCONTEXT + MC_GREGS + GREG_O7], %o7
+ ld [%o0 + UC_MCONTEXT + MC_GREGS + GREG_PC], %g1
+ jmpl %g1, %g0
+ ld [%o0 + UC_MCONTEXT + MC_GREGS + GREG_O0], %o0
+END(__setcontext)
+
+weak_alias (__setcontext, setcontext)
+
+/* This is the helper code which gets called if a function which is
+ registered with 'makecontext' returns. In this case we have to
+ install the context listed in the uc_link element of the context
+ 'makecontext' manipulated at the time of the 'makecontext' call.
+ If the pointer is NULL the process must terminate. */
+
+ENTRY(__start_context)
+ ld [%sp + (16 * 4)], %g1
+ cmp %g1, 0
+ be,a 1f
+ clr %o0
+ call __setcontext
+ mov %g1, %o0
+ /* If this returns (which can happen if the syscall fails) we'll
+ exit the program with the return error value (-1). */
+1: call HIDDEN_JUMPTARGET(exit)
+ nop
+ /* The 'exit' call should never return. In case it does cause
+ the process to terminate. */
+ unimp
+END(__start_context)
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/sigcontextinfo.h b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/sigcontextinfo.h
index 2c2770d07..59656978b 100644
--- a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/sigcontextinfo.h
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/sigcontextinfo.h
@@ -20,6 +20,9 @@
#define SIGCONTEXT struct sigcontext *
#define SIGCONTEXT_EXTRA_ARGS
#define GET_PC(__ctx) ((void *) ((__ctx)->si_regs.pc))
+#define FIRST_FRAME_POINTER \
+ ({ void *ret; \
+ asm volatile ("ta 3; add %%fp, 56, %0" : "=r" (ret)); ret; })
#define ADVANCE_STACK_FRAME(__next) \
((void *) (((unsigned *)(__next))+14))
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/swapcontext.S b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/swapcontext.S
new file mode 100644
index 000000000..154746689
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/swapcontext.S
@@ -0,0 +1,119 @@
+/* Save current context and install the given one.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by David S. Miller <davem@davemloft.net>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <sys/trap.h>
+
+#include "ucontext_i.h"
+
+
+/* int __swapcontext (ucontext_t *oucp, const ucontext_t *ucp);
+
+ Saves the machine context in oucp such that when it is activated,
+ it appears as if __swapcontext() returned again, restores the
+ machine context in ucp and thereby resumes execution in that
+ context.
+
+ This implementation is intended to be used for *synchronous* context
+ switches only. Therefore, it does not have to save anything
+ other than the PRESERVED state. */
+
+ENTRY(__swapcontext)
+ save %sp, -112, %sp
+ ta ST_FLUSH_WINDOWS
+ st %g0, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_PSR]
+ add %i7, 8, %o0
+ st %o0, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_PC]
+ add %o0, 4, %o0
+ st %o0, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_NPC]
+ rd %y, %o1
+ st %o1, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_Y]
+ st %g1, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G1]
+ st %g2, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G2]
+ st %g3, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G3]
+ st %g4, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G4]
+ st %g5, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G5]
+ st %g6, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G6]
+ st %g7, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G7]
+ st %g0, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O0]
+ st %i1, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O1]
+ st %i2, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O2]
+ st %i3, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O3]
+ st %i4, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O4]
+ st %i5, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O5]
+ st %i6, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O6]
+ st %i7, [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O7]
+ st %g0, [%i0 + UC_MCONTEXT + MC_GWINS]
+ stb %g0, [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_EN]
+ st %g0, [%i0 + UC_MCONTEXT + MC_XRS + XRS_ID]
+ st %g0, [%i0 + UC_MCONTEXT + MC_XRS + XRS_PTR]
+
+ mov SIG_SETMASK, %o0
+ add %i1, UC_SIGMASK, %o1
+ add %i0, UC_SIGMASK, %o2
+ mov 8, %o3
+ mov __NR_rt_sigprocmask, %g1
+ ta 0x10
+
+ mov %i1, %i0
+ ldub [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_EN], %g1
+ cmp %g1, 0
+ be 1f
+ nop
+ ld [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_FSR], %fsr
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D0], %f0
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D2], %f2
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D4], %f4
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D6], %f6
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D8], %f8
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D10], %f10
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D12], %f12
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D14], %f14
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D16], %f16
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D18], %f18
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D20], %f20
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D22], %f22
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D24], %f24
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D26], %f26
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D28], %f28
+ ldd [%i0 + UC_MCONTEXT + MC_FPREGS + FPU_D30], %f30
+1:
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_Y], %g1
+ wr %g1, 0x0, %y
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G2], %g2
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G3], %g3
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G4], %g4
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G5], %g5
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G6], %g6
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_G7], %g7
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O1], %i1
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O2], %i2
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O3], %i3
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O4], %i4
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O5], %i5
+ ld [%i0 + UC_MCONTEXT + MC_GREGS + GREG_O6], %i6
+ restore
+ ld [%o0 + UC_MCONTEXT + MC_GREGS + GREG_O7], %o7
+ ld [%o0 + UC_MCONTEXT + MC_GREGS + GREG_PC], %g1
+ jmpl %g1, %g0
+ ld [%o0 + UC_MCONTEXT + MC_GREGS + GREG_O0], %o0
+END(__swapcontext)
+
+weak_alias (__swapcontext, swapcontext)
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/syscall.S b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/syscall.S
index 161074552..5786880f2 100644
--- a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/syscall.S
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/syscall.S
@@ -27,6 +27,7 @@ ENTRY(syscall)
mov %o3, %o2
mov %o4, %o3
mov %o5, %o4
+ ld [%sp + 92], %o5
ta 0x10
bcc 1f
mov %o7, %g1
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h
index c808a97fc..3cb0a48c9 100644
--- a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h
@@ -1,4 +1,5 @@
-/* Copyright (C) 1997, 2002, 2003, 2004, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 2002, 2003, 2004, 2006, 2008
+ Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Miguel de Icaza <miguel@gnu.ai.mit.edu>, January 1997.
@@ -89,6 +90,13 @@ ENTRY(name); \
#else /* __ASSEMBLER__ */
+#if defined SHARED && defined DO_VERSIONING && defined PIC \
+ && !defined NO_HIDDEN && !defined NOT_IN_libc
+# define CALL_ERRNO_LOCATION "call __GI___errno_location;"
+#else
+# define CALL_ERRNO_LOCATION "call __errno_location;"
+#endif
+
#define __SYSCALL_STRING \
"ta 0x10;" \
"bcs 2f;" \
@@ -97,7 +105,7 @@ ENTRY(name); \
".subsection 2;" \
"2:" \
"save %%sp, -192, %%sp;" \
- "call __errno_location;" \
+ CALL_ERRNO_LOCATION \
" nop;" \
"st %%i0,[%%o0];" \
"ba 1b;" \
@@ -113,7 +121,7 @@ ENTRY(name); \
".subsection 2;" \
"2:" \
"save %%sp, -192, %%sp;" \
- "call __errno_location;" \
+ CALL_ERRNO_LOCATION \
" nop;" \
"st %%i0, [%%o0];" \
"ba 1b;" \
@@ -126,7 +134,7 @@ ENTRY(name); \
" sub %%g0, %%o0, %%o0;" \
"1:"
-#define __SYSCALL_CLOBBERS "g2", "g3", "g4", "g5", "g6", \
+#define __SYSCALL_CLOBBERS \
"f0", "f1", "f2", "f3", "f4", "f5", "f6", "f7", \
"f8", "f9", "f10", "f11", "f12", "f13", "f14", "f15", \
"f16", "f17", "f18", "f19", "f20", "f21", "f22", "f23", \
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc32/ucontext_i.sym b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/ucontext_i.sym
new file mode 100644
index 000000000..544030ce8
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc32/ucontext_i.sym
@@ -0,0 +1,61 @@
+#include <stddef.h>
+#include <signal.h>
+#include <sys/ucontext.h>
+
+--
+
+SIG_BLOCK
+SIG_SETMASK
+
+UC_FLAGS offsetof (ucontext_t, uc_flags)
+UC_LINK offsetof (ucontext_t, uc_link)
+UC_SIGMASK offsetof (ucontext_t, uc_sigmask)
+UC_STACK offsetof (ucontext_t, uc_stack)
+UC_MCONTEXT offsetof (ucontext_t, uc_mcontext)
+MC_GREGS offsetof (mcontext_t, gregs)
+MC_GWINS offsetof (mcontext_t, gwins)
+MC_FPREGS offsetof (mcontext_t, fpregs)
+MC_XRS offsetof (mcontext_t, xrs)
+MC_FILLER offsetof (mcontext_t, filler)
+GREG_PSR (REG_PSR * sizeof(greg_t))
+GREG_PC (REG_PC * sizeof(greg_t))
+GREG_NPC (REG_nPC * sizeof(greg_t))
+GREG_Y (REG_Y * sizeof(greg_t))
+GREG_G1 (REG_G1 * sizeof(greg_t))
+GREG_G2 (REG_G2 * sizeof(greg_t))
+GREG_G3 (REG_G3 * sizeof(greg_t))
+GREG_G4 (REG_G4 * sizeof(greg_t))
+GREG_G5 (REG_G5 * sizeof(greg_t))
+GREG_G6 (REG_G6 * sizeof(greg_t))
+GREG_G7 (REG_G7 * sizeof(greg_t))
+GREG_O0 (REG_O0 * sizeof(greg_t))
+GREG_O1 (REG_O1 * sizeof(greg_t))
+GREG_O2 (REG_O2 * sizeof(greg_t))
+GREG_O3 (REG_O3 * sizeof(greg_t))
+GREG_O4 (REG_O4 * sizeof(greg_t))
+GREG_O5 (REG_O5 * sizeof(greg_t))
+GREG_O6 (REG_O6 * sizeof(greg_t))
+GREG_O7 (REG_O7 * sizeof(greg_t))
+FPU_D0 offsetof (fpregset_t, fpu_fr.fpu_dregs[0])
+FPU_D2 offsetof (fpregset_t, fpu_fr.fpu_dregs[1])
+FPU_D4 offsetof (fpregset_t, fpu_fr.fpu_dregs[2])
+FPU_D6 offsetof (fpregset_t, fpu_fr.fpu_dregs[3])
+FPU_D8 offsetof (fpregset_t, fpu_fr.fpu_dregs[4])
+FPU_D10 offsetof (fpregset_t, fpu_fr.fpu_dregs[5])
+FPU_D12 offsetof (fpregset_t, fpu_fr.fpu_dregs[6])
+FPU_D14 offsetof (fpregset_t, fpu_fr.fpu_dregs[7])
+FPU_D16 offsetof (fpregset_t, fpu_fr.fpu_dregs[8])
+FPU_D18 offsetof (fpregset_t, fpu_fr.fpu_dregs[9])
+FPU_D20 offsetof (fpregset_t, fpu_fr.fpu_dregs[10])
+FPU_D22 offsetof (fpregset_t, fpu_fr.fpu_dregs[11])
+FPU_D24 offsetof (fpregset_t, fpu_fr.fpu_dregs[12])
+FPU_D26 offsetof (fpregset_t, fpu_fr.fpu_dregs[13])
+FPU_D28 offsetof (fpregset_t, fpu_fr.fpu_dregs[14])
+FPU_D30 offsetof (fpregset_t, fpu_fr.fpu_dregs[15])
+FPU_Q offsetof (fpregset_t, fpu_q)
+FPU_FSR offsetof (fpregset_t, fpu_fsr)
+FPU_QCNT offsetof (fpregset_t, fpu_qcnt)
+FPU_Q_ENTRY_SZ offsetof (fpregset_t, fpu_q_entrysize)
+FPU_EN offsetof (fpregset_t, fpu_en)
+XRS_ID offsetof (xrs_t, xrs_id)
+XRS_PTR offsetof (xrs_t, xrs_ptr)
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S b/libc/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S
index 134ce789f..ccc558992 100644
--- a/libc/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Richard Henderson <richard@gnu.ai.mit.edu>, 1997.
@@ -86,7 +86,11 @@ ENTRY (__brk)
#endif
st %o0, [%g1]
#else
+#ifndef NOT_IN_libc
+ call HIDDEN_JUMPTARGET(__errno_location)
+#else
call __errno_location
+#endif
mov %o0,%l1
st %l1, [%o0]
#endif
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc64/semctl.c b/libc/sysdeps/unix/sysv/linux/sparc/sparc64/semctl.c
index 057e28782..4f826b156 100644
--- a/libc/sysdeps/unix/sysv/linux/sparc/sparc64/semctl.c
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc64/semctl.c
@@ -54,5 +54,5 @@ semctl (int semid, int semnum, int cmd, ...)
va_end (ap);
return INLINE_SYSCALL (ipc, 5, IPCOP_semctl, semid, semnum, cmd,
- CHECK_SEMCTL (&arg, semid, cmd));
+ CHECK_SEMCTL (&arg, semid, cmd)->array);
}
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S b/libc/sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S
index 27487d8ed..2c89558b2 100644
--- a/libc/sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S
@@ -27,6 +27,7 @@ ENTRY(syscall)
mov %o3,%o2
mov %o4,%o3
mov %o5,%o4
+ ldx [%sp + STACK_BIAS + 176],%o5
ta 0x6d
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h b/libc/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h
index f156f9241..79fa13de7 100644
--- a/libc/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997, 2000, 2002, 2003, 2004, 2006
+/* Copyright (C) 1997, 2000, 2002, 2003, 2004, 2006, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Richard Henderson <richard@gnu.ai.mit.edu>, 1997.
@@ -106,12 +106,19 @@ ENTRY(name); \
#else /* __ASSEMBLER__ */
+#if defined SHARED && defined DO_VERSIONING && defined PIC \
+ && !defined NO_HIDDEN && !defined NOT_IN_libc
+# define CALL_ERRNO_LOCATION "call __GI___errno_location;"
+#else
+# define CALL_ERRNO_LOCATION "call __errno_location;"
+#endif
+
#define __SYSCALL_STRING \
"ta 0x6d;" \
"bcc,pt %%xcc, 1f;" \
" nop;" \
"save %%sp, -192, %%sp;" \
- "call __errno_location;" \
+ CALL_ERRNO_LOCATION \
" nop;" \
"st %%i0,[%%o0];" \
"restore %%g0, -1, %%o0;" \
@@ -122,7 +129,7 @@ ENTRY(name); \
"bcc,pt %%xcc, 1f;" \
" sub %%o1, 1, %%o1;" \
"save %%sp, -192, %%sp;" \
- "call __errno_location;" \
+ CALL_ERRNO_LOCATION \
" mov -1, %%i1;" \
"st %%i0,[%%o0];" \
"restore %%g0, -1, %%o0;" \
@@ -135,7 +142,7 @@ ENTRY(name); \
" sub %%g0, %%o0, %%o0;" \
"1:"
-#define __SYSCALL_CLOBBERS "g2", "g3", "g4", "g5", "g6", \
+#define __SYSCALL_CLOBBERS \
"f0", "f1", "f2", "f3", "f4", "f5", "f6", "f7", \
"f8", "f9", "f10", "f11", "f12", "f13", "f14", "f15", \
"f16", "f17", "f18", "f19", "f20", "f21", "f22", "f23", \
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sys/epoll.h b/libc/sysdeps/unix/sysv/linux/sparc/sys/epoll.h
new file mode 100644
index 000000000..cc0ddef69
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sys/epoll.h
@@ -0,0 +1,143 @@
+/* Copyright (C) 2002-2006, 2007, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_EPOLL_H
+#define _SYS_EPOLL_H 1
+
+#include <stdint.h>
+#include <sys/types.h>
+
+/* Get __sigset_t. */
+#include <bits/sigset.h>
+
+#ifndef __sigset_t_defined
+# define __sigset_t_defined
+typedef __sigset_t sigset_t;
+#endif
+
+
+/* Flags to be passed to epoll_create2. */
+enum
+ {
+ EPOLL_CLOEXEC = 0x400000,
+#define EPOLL_CLOEXEC EPOLL_CLOEXEC
+ EPOLL_NONBLOCK = 0x4000
+#define EPOLL_NONBLOCK EPOLL_NONBLOCK
+ };
+
+
+enum EPOLL_EVENTS
+ {
+ EPOLLIN = 0x001,
+#define EPOLLIN EPOLLIN
+ EPOLLPRI = 0x002,
+#define EPOLLPRI EPOLLPRI
+ EPOLLOUT = 0x004,
+#define EPOLLOUT EPOLLOUT
+ EPOLLRDNORM = 0x040,
+#define EPOLLRDNORM EPOLLRDNORM
+ EPOLLRDBAND = 0x080,
+#define EPOLLRDBAND EPOLLRDBAND
+ EPOLLWRNORM = 0x100,
+#define EPOLLWRNORM EPOLLWRNORM
+ EPOLLWRBAND = 0x200,
+#define EPOLLWRBAND EPOLLWRBAND
+ EPOLLMSG = 0x400,
+#define EPOLLMSG EPOLLMSG
+ EPOLLERR = 0x008,
+#define EPOLLERR EPOLLERR
+ EPOLLHUP = 0x010,
+#define EPOLLHUP EPOLLHUP
+ EPOLLRDHUP = 0x2000,
+#define EPOLLRDHUP EPOLLRDHUP
+ EPOLLONESHOT = (1 << 30),
+#define EPOLLONESHOT EPOLLONESHOT
+ EPOLLET = (1 << 31)
+#define EPOLLET EPOLLET
+ };
+
+
+/* Valid opcodes ( "op" parameter ) to issue to epoll_ctl(). */
+#define EPOLL_CTL_ADD 1 /* Add a file descriptor to the interface. */
+#define EPOLL_CTL_DEL 2 /* Remove a file descriptor from the interface. */
+#define EPOLL_CTL_MOD 3 /* Change file descriptor epoll_event structure. */
+
+
+typedef union epoll_data
+{
+ void *ptr;
+ int fd;
+ uint32_t u32;
+ uint64_t u64;
+} epoll_data_t;
+
+struct epoll_event
+{
+ uint32_t events; /* Epoll events */
+ epoll_data_t data; /* User data variable */
+};
+
+
+__BEGIN_DECLS
+
+/* Creates an epoll instance. Returns an fd for the new instance.
+ The "size" parameter is a hint specifying the number of file
+ descriptors to be associated with the new instance. The fd
+ returned by epoll_create() should be closed with close(). */
+extern int epoll_create (int __size) __THROW;
+
+/* Same as epoll_create but with an additional FLAGS parameter. */
+extern int epoll_create2 (int __size, int __flags) __THROW;
+
+
+/* Manipulate an epoll instance "epfd". Returns 0 in case of success,
+ -1 in case of error ( the "errno" variable will contain the
+ specific error code ) The "op" parameter is one of the EPOLL_CTL_*
+ constants defined above. The "fd" parameter is the target of the
+ operation. The "event" parameter describes which events the caller
+ is interested in and any associated user data. */
+extern int epoll_ctl (int __epfd, int __op, int __fd,
+ struct epoll_event *__event) __THROW;
+
+
+/* Wait for events on an epoll instance "epfd". Returns the number of
+ triggered events returned in "events" buffer. Or -1 in case of
+ error with the "errno" variable set to the specific error code. The
+ "events" parameter is a buffer that will contain triggered
+ events. The "maxevents" is the maximum number of events to be
+ returned ( usually size of "events" ). The "timeout" parameter
+ specifies the maximum wait time in milliseconds (-1 == infinite).
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern int epoll_wait (int __epfd, struct epoll_event *__events,
+ int __maxevents, int __timeout);
+
+
+/* Same as epoll_wait, but the thread's signal mask is temporarily
+ and atomically replaced with the one provided as parameter.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern int epoll_pwait (int __epfd, struct epoll_event *__events,
+ int __maxevents, int __timeout,
+ __const __sigset_t *__ss);
+
+__END_DECLS
+
+#endif /* sys/epoll.h */
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sys/eventfd.h b/libc/sysdeps/unix/sysv/linux/sparc/sys/eventfd.h
new file mode 100644
index 000000000..aff4f3592
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sys/eventfd.h
@@ -0,0 +1,52 @@
+/* Copyright (C) 2007, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_EVENTFD_H
+#define _SYS_EVENTFD_H 1
+
+#include <stdint.h>
+
+
+/* Type for event counter. */
+typedef uint64_t eventfd_t;
+
+/* Flags for signalfd. */
+enum
+ {
+ EFD_CLOEXEC = 0x400000,
+#define EFD_CLOEXEC EFD_CLOEXEC
+ EFD_NONBLOCK = 0x4000
+#define EFD_NONBLOCK EFD_NONBLOCK
+ };
+
+
+__BEGIN_DECLS
+
+/* Return file descriptor for generic event channel. Set initial
+ value to COUNT. */
+extern int eventfd (int __count, int __flags) __THROW;
+
+/* Read event counter and possibly wait for events. */
+extern int eventfd_read (int __fd, eventfd_t *__value);
+
+/* Increment event counter. */
+extern int eventfd_write (int __fd, eventfd_t value);
+
+__END_DECLS
+
+#endif /* sys/eventfd.h */
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sys/inotify.h b/libc/sysdeps/unix/sysv/linux/sparc/sys/inotify.h
new file mode 100644
index 000000000..b1fccc42c
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sys/inotify.h
@@ -0,0 +1,105 @@
+/* Copyright (C) 2005, 2006, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_INOTIFY_H
+#define _SYS_INOTIFY_H 1
+
+#include <stdint.h>
+
+
+/* Flags for the parameter of inotify_init1. */
+enum
+ {
+ IN_CLOEXEC = 0x400000,
+#define IN_CLOEXEC IN_CLOEXEC
+ IN_NONBLOCK = 0x4000
+#define IN_NONBLOCK IN_NONBLOCK
+ };
+
+
+/* Structure describing an inotify event. */
+struct inotify_event
+{
+ int wd; /* Watch descriptor. */
+ uint32_t mask; /* Watch mask. */
+ uint32_t cookie; /* Cookie to synchronize two events. */
+ uint32_t len; /* Length (including NULs) of name. */
+ char name __flexarr; /* Name. */
+};
+
+
+/* Supported events suitable for MASK parameter of INOTIFY_ADD_WATCH. */
+#define IN_ACCESS 0x00000001 /* File was accessed. */
+#define IN_MODIFY 0x00000002 /* File was modified. */
+#define IN_ATTRIB 0x00000004 /* Metadata changed. */
+#define IN_CLOSE_WRITE 0x00000008 /* Writtable file was closed. */
+#define IN_CLOSE_NOWRITE 0x00000010 /* Unwrittable file closed. */
+#define IN_CLOSE (IN_CLOSE_WRITE | IN_CLOSE_NOWRITE) /* Close. */
+#define IN_OPEN 0x00000020 /* File was opened. */
+#define IN_MOVED_FROM 0x00000040 /* File was moved from X. */
+#define IN_MOVED_TO 0x00000080 /* File was moved to Y. */
+#define IN_MOVE (IN_MOVED_FROM | IN_MOVED_TO) /* Moves. */
+#define IN_CREATE 0x00000100 /* Subfile was created. */
+#define IN_DELETE 0x00000200 /* Subfile was deleted. */
+#define IN_DELETE_SELF 0x00000400 /* Self was deleted. */
+#define IN_MOVE_SELF 0x00000800 /* Self was moved. */
+
+/* Events sent by the kernel. */
+#define IN_UNMOUNT 0x00002000 /* Backing fs was unmounted. */
+#define IN_Q_OVERFLOW 0x00004000 /* Event queued overflowed. */
+#define IN_IGNORED 0x00008000 /* File was ignored. */
+
+/* Helper events. */
+#define IN_CLOSE (IN_CLOSE_WRITE | IN_CLOSE_NOWRITE) /* Close. */
+#define IN_MOVE (IN_MOVED_FROM | IN_MOVED_TO) /* Moves. */
+
+/* Special flags. */
+#define IN_ONLYDIR 0x01000000 /* Only watch the path if it is a
+ directory. */
+#define IN_DONT_FOLLOW 0x02000000 /* Do not follow a sym link. */
+#define IN_MASK_ADD 0x20000000 /* Add to the mask of an already
+ existing watch. */
+#define IN_ISDIR 0x40000000 /* Event occurred against dir. */
+#define IN_ONESHOT 0x80000000 /* Only send event once. */
+
+/* All events which a program can wait on. */
+#define IN_ALL_EVENTS (IN_ACCESS | IN_MODIFY | IN_ATTRIB | IN_CLOSE_WRITE \
+ | IN_CLOSE_NOWRITE | IN_OPEN | IN_MOVED_FROM \
+ | IN_MOVED_TO | IN_CREATE | IN_DELETE \
+ | IN_DELETE_SELF | IN_MOVE_SELF)
+
+
+__BEGIN_DECLS
+
+/* Create and initialize inotify instance. */
+extern int inotify_init (void) __THROW;
+
+/* Create and initialize inotify instance. */
+extern int inotify_init1 (int __flags) __THROW;
+
+/* Add watch of object NAME to inotify instance FD. Notify about
+ events specified by MASK. */
+extern int inotify_add_watch (int __fd, const char *__name, uint32_t __mask)
+ __THROW;
+
+/* Remove the watch specified by WD from the inotify instance FD. */
+extern int inotify_rm_watch (int __fd, uint32_t __wd) __THROW;
+
+__END_DECLS
+
+#endif /* sys/inotify.h */
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sys/signalfd.h b/libc/sysdeps/unix/sysv/linux/sparc/sys/signalfd.h
new file mode 100644
index 000000000..a134cc7ba
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sys/signalfd.h
@@ -0,0 +1,66 @@
+/* Copyright (C) 2007, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_SIGNALFD_H
+#define _SYS_SIGNALFD_H 1
+
+#define __need_sigset_t
+#include <signal.h>
+#include <stdint.h>
+
+
+struct signalfd_siginfo
+{
+ uint32_t ssi_signo;
+ int32_t ssi_errno;
+ int32_t ssi_code;
+ uint32_t ssi_pid;
+ uint32_t ssi_uid;
+ int32_t ssi_fd;
+ uint32_t ssi_tid;
+ uint32_t ssi_band;
+ uint32_t ssi_overrun;
+ uint32_t ssi_trapno;
+ int32_t ssi_status;
+ int32_t ssi_int;
+ uint64_t ssi_ptr;
+ uint64_t ssi_utime;
+ uint64_t ssi_stime;
+ uint64_t ssi_addr;
+ uint8_t __pad[48];
+};
+
+/* Flags for signalfd. */
+enum
+ {
+ SFD_CLOEXEC = 0x400000,
+#define SFD_CLOEXEC SFD_CLOEXEC
+ SFD_NONBLOCK = 0x4000
+#define SFD_NONBLOCK SFD_NONBLOCK
+ };
+
+__BEGIN_DECLS
+
+/* Request notification for delivery of signals in MASK to be
+ performed using descriptor FD.*/
+extern int signalfd (int __fd, const sigset_t *__mask, int __flags)
+ __nonnull ((2)) __THROW;
+
+__END_DECLS
+
+#endif /* sys/signalfd.h */
diff --git a/libc/sysdeps/unix/sysv/linux/sparc/sys/timerfd.h b/libc/sysdeps/unix/sysv/linux/sparc/sys/timerfd.h
new file mode 100644
index 000000000..833d050fb
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/sparc/sys/timerfd.h
@@ -0,0 +1,60 @@
+/* Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_TIMERFD_H
+#define _SYS_TIMERFD_H 1
+
+#include <time.h>
+
+
+/* Bits to be set in the FLAGS parameter of `timerfd_create'. */
+enum
+ {
+ TFD_CLOEXEC = 0x400000,
+#define TFD_CLOEXEC TFD_CLOEXEC
+ TFD_NONBLOCK = 0x4000
+#define TFD_NONBLOCK TFD_NONBLOCK
+ };
+
+
+/* Bits to be set in the FLAGS parameter of `timerfd_settime'. */
+enum
+ {
+ TFD_TIMER_ABSTIME = 1 << 0
+#define TFD_TIMER_ABSTIME TFD_TIMER_ABSTIME
+ };
+
+
+__BEGIN_DECLS
+
+/* Return file descriptor for new interval timer source. */
+extern int timerfd_create (clockid_t __clock_id, int __flags) __THROW;
+
+/* Set next expiration time of interval timer source UFD to UTMR. If
+ FLAGS has the TFD_TIMER_ABSTIME flag set the timeout value is
+ absolute. Optionally return the old expiration time in OTMR. */
+extern int timerfd_settime (int __ufd, int __flags,
+ __const struct itimerspec *__utmr,
+ struct itimerspec *__otmr) __THROW;
+
+/* Return the next expiration time of UFD. */
+extern int timerfd_gettime (int __ufd, struct itimerspec *__otmr) __THROW;
+
+__END_DECLS
+
+#endif /* sys/timerfd.h */
diff --git a/libc/sysdeps/unix/sysv/linux/sys/epoll.h b/libc/sysdeps/unix/sysv/linux/sys/epoll.h
index f4e8bda99..12de0bcfe 100644
--- a/libc/sysdeps/unix/sysv/linux/sys/epoll.h
+++ b/libc/sysdeps/unix/sysv/linux/sys/epoll.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002-2006, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2002-2006, 2007, 2008 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
@@ -31,6 +31,16 @@ typedef __sigset_t sigset_t;
#endif
+/* Flags to be passed to epoll_create2. */
+enum
+ {
+ EPOLL_CLOEXEC = 02000000,
+#define EPOLL_CLOEXEC EPOLL_CLOEXEC
+ EPOLL_NONBLOCK = 04000
+#define EPOLL_NONBLOCK EPOLL_NONBLOCK
+ };
+
+
enum EPOLL_EVENTS
{
EPOLLIN = 0x001,
@@ -63,9 +73,9 @@ enum EPOLL_EVENTS
/* Valid opcodes ( "op" parameter ) to issue to epoll_ctl(). */
-#define EPOLL_CTL_ADD 1 /* Add a file decriptor to the interface. */
-#define EPOLL_CTL_DEL 2 /* Remove a file decriptor from the interface. */
-#define EPOLL_CTL_MOD 3 /* Change file decriptor epoll_event structure. */
+#define EPOLL_CTL_ADD 1 /* Add a file descriptor to the interface. */
+#define EPOLL_CTL_DEL 2 /* Remove a file descriptor from the interface. */
+#define EPOLL_CTL_MOD 3 /* Change file descriptor epoll_event structure. */
typedef union epoll_data
@@ -91,6 +101,10 @@ __BEGIN_DECLS
returned by epoll_create() should be closed with close(). */
extern int epoll_create (int __size) __THROW;
+/* Same as epoll_create but with an FLAGS parameter. The unused SIZE
+ parameter has been dropped. */
+extern int epoll_create1 (int __flags) __THROW;
+
/* Manipulate an epoll instance "epfd". Returns 0 in case of success,
-1 in case of error ( the "errno" variable will contain the
diff --git a/libc/sysdeps/unix/sysv/linux/sys/eventfd.h b/libc/sysdeps/unix/sysv/linux/sys/eventfd.h
index 1ebaea7b3..205824b66 100644
--- a/libc/sysdeps/unix/sysv/linux/sys/eventfd.h
+++ b/libc/sysdeps/unix/sysv/linux/sys/eventfd.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2007, 2008 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
@@ -25,6 +25,15 @@
/* Type for event counter. */
typedef uint64_t eventfd_t;
+/* Flags for signalfd. */
+enum
+ {
+ EFD_CLOEXEC = 02000000,
+#define EFD_CLOEXEC EFD_CLOEXEC
+ EFD_NONBLOCK = 04000
+#define EFD_NONBLOCK EFD_NONBLOCK
+ };
+
__BEGIN_DECLS
diff --git a/libc/sysdeps/unix/sysv/linux/sys/inotify.h b/libc/sysdeps/unix/sysv/linux/sys/inotify.h
index 0131db9d3..81e31fb64 100644
--- a/libc/sysdeps/unix/sysv/linux/sys/inotify.h
+++ b/libc/sysdeps/unix/sysv/linux/sys/inotify.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2005, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 2005, 2006, 2008 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
@@ -22,6 +22,16 @@
#include <stdint.h>
+/* Flags for the parameter of inotify_init1. */
+enum
+ {
+ IN_CLOEXEC = 02000000,
+#define IN_CLOEXEC IN_CLOEXEC
+ IN_NONBLOCK = 04000
+#define IN_NONBLOCK IN_NONBLOCK
+ };
+
+
/* Structure describing an inotify event. */
struct inotify_event
{
@@ -79,6 +89,9 @@ __BEGIN_DECLS
/* Create and initialize inotify instance. */
extern int inotify_init (void) __THROW;
+/* Create and initialize inotify instance. */
+extern int inotify_init1 (int __flags) __THROW;
+
/* Add watch of object NAME to inotify instance FD. Notify about
events specified by MASK. */
extern int inotify_add_watch (int __fd, const char *__name, uint32_t __mask)
diff --git a/libc/sysdeps/unix/sysv/linux/sys/signalfd.h b/libc/sysdeps/unix/sysv/linux/sys/signalfd.h
index 7a7f53ba3..dae71a400 100644
--- a/libc/sysdeps/unix/sysv/linux/sys/signalfd.h
+++ b/libc/sysdeps/unix/sysv/linux/sys/signalfd.h
@@ -45,6 +45,14 @@ struct signalfd_siginfo
uint8_t __pad[48];
};
+/* Flags for signalfd. */
+enum
+ {
+ SFD_CLOEXEC = 02000000,
+#define SFD_CLOEXEC SFD_CLOEXEC
+ SFD_NONBLOCK = 04000
+#define SFD_NONBLOCK SFD_NONBLOCK
+ };
__BEGIN_DECLS
diff --git a/libc/sysdeps/unix/sysv/linux/sys/timerfd.h b/libc/sysdeps/unix/sysv/linux/sys/timerfd.h
index 0a4b81c9b..c1bb06f5f 100644
--- a/libc/sysdeps/unix/sysv/linux/sys/timerfd.h
+++ b/libc/sysdeps/unix/sysv/linux/sys/timerfd.h
@@ -22,6 +22,16 @@
#include <time.h>
+/* Bits to be set in the FLAGS parameter of `timerfd_create'. */
+enum
+ {
+ TFD_CLOEXEC = 02000000,
+#define TFD_CLOEXEC TFD_CLOEXEC
+ TFD_NONBLOCK = 04000
+#define TFD_NONBLOCK TFD_NONBLOCK
+ };
+
+
/* Bits to be set in the FLAGS parameter of `timerfd_settime'. */
enum
{
diff --git a/libc/sysdeps/unix/sysv/linux/sys/user.h b/libc/sysdeps/unix/sysv/linux/sys/user.h
index 30e9b57ab..03e56c3d7 100644
--- a/libc/sysdeps/unix/sysv/linux/sys/user.h
+++ b/libc/sysdeps/unix/sysv/linux/sys/user.h
@@ -1 +1 @@
-#include <linux/user.h>
+#error "This file is machine-dependent and not provided for this machine."
diff --git a/libc/sysdeps/unix/sysv/linux/syscalls.list b/libc/sysdeps/unix/sysv/linux/syscalls.list
index b3ecf9f47..a87906a4e 100644
--- a/libc/sysdeps/unix/sysv/linux/syscalls.list
+++ b/libc/sysdeps/unix/sysv/linux/syscalls.list
@@ -8,6 +8,7 @@ creat - creat Ci:si __libc_creat creat
create_module EXTRA create_module 3 create_module
delete_module EXTRA delete_module 3 delete_module
epoll_create EXTRA epoll_create i:i epoll_create
+epoll_create1 EXTRA epoll_create1 i:i epoll_create1
epoll_ctl EXTRA epoll_ctl i:iiip epoll_ctl
epoll_wait EXTRA epoll_wait Ci:ipii epoll_wait
fdatasync - fdatasync Ci:i fdatasync
@@ -26,6 +27,7 @@ getsid - getsid i:i getsid
init_module EXTRA init_module 5 init_module
inotify_add_watch EXTRA inotify_add_watch i:isi inotify_add_watch
inotify_init EXTRA inotify_init i: inotify_init
+inotify_init1 EXTRA inotify_init1 i:I inotify_init1
inotify_rm_watch EXTRA inotify_rm_watch i:ii inotify_rm_watch
ioperm - ioperm i:iii ioperm
iopl - iopl i:i iopl
@@ -45,6 +47,7 @@ nfsservctl EXTRA nfsservctl i:ipp nfsservctl
pause - pause Ci: __libc_pause pause
personality EXTRA personality i:i __personality personality
pipe - pipe i:f __pipe pipe
+pipe2 - pipe2 i:fi __pipe2 pipe2
pivot_root EXTRA pivot_root i:ss pivot_root
prctl EXTRA prctl i:iiiii __prctl prctl
putpmsg - putpmsg i:ippii putpmsg
diff --git a/libc/sysdeps/unix/sysv/linux/times.c b/libc/sysdeps/unix/sysv/linux/times.c
new file mode 100644
index 000000000..42d265dc8
--- /dev/null
+++ b/libc/sysdeps/unix/sysv/linux/times.c
@@ -0,0 +1,59 @@
+/* Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <errno.h>
+#include <sys/times.h>
+#include <sysdep.h>
+
+
+clock_t
+__times (struct tms *buf)
+{
+ INTERNAL_SYSCALL_DECL (err);
+ clock_t ret = INTERNAL_SYSCALL (times, err, 1, buf);
+ if (INTERNAL_SYSCALL_ERROR_P (ret, err)
+ && __builtin_expect (INTERNAL_SYSCALL_ERRNO (ret, err) == EFAULT, 0))
+ {
+ /* This might be an error or not. For architectures which have
+ no separate return value and error indicators we cannot
+ distinguish a return value of -1 from an error. Do it the
+ hard way. We crash applications which pass in an invalid BUF
+ pointer. */
+#define touch(v) \
+ do { \
+ clock_t temp = v; \
+ asm volatile ("" : "+r" (temp)); \
+ v = temp; \
+ } while (0)
+ touch (buf->tms_utime);
+ touch (buf->tms_stime);
+ touch (buf->tms_cutime);
+ touch (buf->tms_cstime);
+
+ /* If we come here the memory is valid and the kernel did not
+ return an EFAULT error. Return the value given by the kernel. */
+ }
+
+ /* Return value (clock_t) -1 signals an error, but if there wasn't any,
+ return the following value. */
+ if (ret == (clock_t) -1)
+ return (clock_t) 0;
+
+ return ret;
+}
+weak_alias (__times, times)
diff --git a/libc/sysdeps/unix/sysv/linux/x86_64/bits/mman.h b/libc/sysdeps/unix/sysv/linux/x86_64/bits/mman.h
index 535c9edcf..781068253 100644
--- a/libc/sysdeps/unix/sysv/linux/x86_64/bits/mman.h
+++ b/libc/sysdeps/unix/sysv/linux/x86_64/bits/mman.h
@@ -64,6 +64,7 @@
# define MAP_NORESERVE 0x04000 /* Don't check for reservations. */
# define MAP_POPULATE 0x08000 /* Populate (prefault) pagetables. */
# define MAP_NONBLOCK 0x10000 /* Do not block on IO. */
+# define MAP_STACK 0x20000 /* Allocation is for a stack. */
#endif
/* Flags to `msync'. */
diff --git a/libc/sysdeps/unix/sysv/linux/x86_64/makecontext.c b/libc/sysdeps/unix/sysv/linux/x86_64/makecontext.c
index 5deea7d1b..615dede52 100644
--- a/libc/sysdeps/unix/sysv/linux/x86_64/makecontext.c
+++ b/libc/sysdeps/unix/sysv/linux/x86_64/makecontext.c
@@ -1,5 +1,5 @@
/* Create new context.
- Copyright (C) 2002, 2004, 2005 Free Software Foundation, Inc.
+ Copyright (C) 2002, 2004, 2005, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Andreas Jaeger <aj@suse.de>, 2002.
@@ -78,31 +78,39 @@ __makecontext (ucontext_t *ucp, void (*func) (void), int argc, ...)
sp[idx_uc_link] = (unsigned long int) ucp->uc_link;
va_start (ap, argc);
- /* Handle arguments. */
+ /* Handle arguments.
+
+ The standard says the parameters must all be int values. This is
+ an historic accident and would be done differently today. For
+ x86-64 all integer values are passed as 64-bit values and
+ therefore extending the API to copy 64-bit values instead of
+ 32-bit ints makes sense. It does not break existing
+ functionality and it does not violate the standard which says
+ that passing non-int values means undefined behavior. */
for (i = 0; i < argc; ++i)
switch (i)
{
case 0:
- ucp->uc_mcontext.gregs [REG_RDI] = va_arg (ap, int);
+ ucp->uc_mcontext.gregs[REG_RDI] = va_arg (ap, long int);
break;
case 1:
- ucp->uc_mcontext.gregs [REG_RSI] = va_arg (ap, int);
+ ucp->uc_mcontext.gregs[REG_RSI] = va_arg (ap, long int);
break;
case 2:
- ucp->uc_mcontext.gregs [REG_RDX] = va_arg (ap, int);
+ ucp->uc_mcontext.gregs[REG_RDX] = va_arg (ap, long int);
break;
case 3:
- ucp->uc_mcontext.gregs [REG_RCX] = va_arg (ap, int);
+ ucp->uc_mcontext.gregs[REG_RCX] = va_arg (ap, long int);
break;
case 4:
- ucp->uc_mcontext.gregs [REG_R8] = va_arg (ap, int);
+ ucp->uc_mcontext.gregs[REG_R8] = va_arg (ap, long int);
break;
case 5:
- ucp->uc_mcontext.gregs [REG_R9] = va_arg (ap, int);
+ ucp->uc_mcontext.gregs[REG_R9] = va_arg (ap, long int);
break;
default:
/* Put value on stack. */
- sp[(i - 5)] = va_arg (ap, int);
+ sp[i - 5] = va_arg (ap, unsigned long int);
break;
}
va_end (ap);
diff --git a/libc/sysdeps/unix/sysv/linux/x86_64/sys/epoll.h b/libc/sysdeps/unix/sysv/linux/x86_64/sys/epoll.h
index dfb65fe5f..234798e4b 100644
--- a/libc/sysdeps/unix/sysv/linux/x86_64/sys/epoll.h
+++ b/libc/sysdeps/unix/sysv/linux/x86_64/sys/epoll.h
@@ -31,6 +31,16 @@ typedef __sigset_t sigset_t;
#endif
+/* Flags to be passed to epoll_create2. */
+enum
+ {
+ EPOLL_CLOEXEC = 02000000,
+#define EPOLL_CLOEXEC EPOLL_CLOEXEC
+ EPOLL_NONBLOCK = 04000
+#define EPOLL_NONBLOCK EPOLL_NONBLOCK
+ };
+
+
enum EPOLL_EVENTS
{
EPOLLIN = 0x001,
@@ -91,6 +101,10 @@ __BEGIN_DECLS
returned by epoll_create() should be closed with close(). */
extern int epoll_create (int __size) __THROW;
+/* Same as epoll_create but with an FLAGS parameter. The unused SIZE
+ parameter has been dropped. */
+extern int epoll_create1 (int __flags) __THROW;
+
/* Manipulate an epoll instance "epfd". Returns 0 in case of success,
-1 in case of error ( the "errno" variable will contain the
diff --git a/libc/sysdeps/unix/sysv/linux/x86_64/vfork.S b/libc/sysdeps/unix/sysv/linux/x86_64/vfork.S
index 4bad38892..e289656ad 100644
--- a/libc/sysdeps/unix/sysv/linux/x86_64/vfork.S
+++ b/libc/sysdeps/unix/sysv/linux/x86_64/vfork.S
@@ -1,4 +1,4 @@
-/* Copyright (C) 2001, 2002, 2004 Free Software Foundation, Inc.
+/* Copyright (C) 2001, 2002, 2004, 2008 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
@@ -31,6 +31,7 @@ ENTRY (__vfork)
is preserved by the syscall and that we're allowed to destroy. */
popq %rdi
cfi_adjust_cfa_offset(-8)
+ cfi_register(%rip, %rdi)
#ifdef SAVE_PID
SAVE_PID
diff --git a/libc/sysdeps/unix/sysv/syscalls.list b/libc/sysdeps/unix/sysv/syscalls.list
index 436d05eb9..f65ed79f7 100644
--- a/libc/sysdeps/unix/sysv/syscalls.list
+++ b/libc/sysdeps/unix/sysv/syscalls.list
@@ -11,6 +11,6 @@ settimeofday - settimeofday i:PP __settimeofday settimeofday
signal - signal i:ii signal
stime - stime i:p stime
time - time Ei:P time
-times - times i:p __times times
+times - times Ei:p __times times
ulimit - ulimit i:ii ulimit
utime - utime i:sP utime
diff --git a/libc/sysdeps/x86_64/Makefile b/libc/sysdeps/x86_64/Makefile
index edbdac0e3..da8209338 100644
--- a/libc/sysdeps/x86_64/Makefile
+++ b/libc/sysdeps/x86_64/Makefile
@@ -13,3 +13,13 @@ endif
ifeq ($(subdir),string)
sysdep_routines += cacheinfo
endif
+
+ifeq ($(subdir),elf)
+sysdep-dl-routines += tlsdesc dl-tlsdesc
+sysdep_routines += tlsdesc dl-tlsdesc
+sysdep-rtld-routines += tlsdesc dl-tlsdesc
+endif
+
+ifeq ($(subdir),csu)
+gen-as-const-headers += tlsdesc.sym
+endif
diff --git a/libc/sysdeps/x86_64/bits/byteswap.h b/libc/sysdeps/x86_64/bits/byteswap.h
index ec2b17889..08b38e852 100644
--- a/libc/sysdeps/x86_64/bits/byteswap.h
+++ b/libc/sysdeps/x86_64/bits/byteswap.h
@@ -1,5 +1,5 @@
/* Macros to swap the order of bytes in integer values.
- Copyright (C) 1997, 1998, 2000, 2002, 2003, 2007
+ Copyright (C) 1997, 1998, 2000, 2002, 2003, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -18,7 +18,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#if !defined _BYTESWAP_H && !defined _NETINET_IN_H
+#if !defined _BYTESWAP_H && !defined _NETINET_IN_H && !defined _ENDIAN_H
# error "Never use <bits/byteswap.h> directly; include <byteswap.h> instead."
#endif
diff --git a/libc/sysdeps/x86_64/bits/linkmap.h b/libc/sysdeps/x86_64/bits/linkmap.h
index 8ea715715..dd0d14087 100644
--- a/libc/sysdeps/x86_64/bits/linkmap.h
+++ b/libc/sysdeps/x86_64/bits/linkmap.h
@@ -3,6 +3,7 @@ struct link_map_machine
{
Elf64_Addr plt; /* Address of .plt + 0x16 */
Elf64_Addr gotplt; /* Address of .got + 0x18 */
+ void *tlsdesc_table; /* Address of TLS descriptor hash table. */
};
#else
@@ -10,5 +11,6 @@ struct link_map_machine
{
Elf32_Addr plt; /* Address of .plt + 0x16 */
Elf32_Addr gotplt; /* Address of .got + 0x0c */
+ void *tlsdesc_table; /* Address of TLS descriptor hash table. */
};
#endif
diff --git a/libc/sysdeps/x86_64/dl-lookupcfg.h b/libc/sysdeps/x86_64/dl-lookupcfg.h
new file mode 100644
index 000000000..2af2b9e8f
--- /dev/null
+++ b/libc/sysdeps/x86_64/dl-lookupcfg.h
@@ -0,0 +1,28 @@
+/* Configuration of lookup functions.
+ Copyright (C) 2005, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#define DL_UNMAP_IS_SPECIAL
+
+#include_next <dl-lookupcfg.h>
+
+struct link_map;
+
+extern void internal_function _dl_unmap (struct link_map *map);
+
+#define DL_UNMAP(map) _dl_unmap (map)
diff --git a/libc/sysdeps/x86_64/dl-machine.h b/libc/sysdeps/x86_64/dl-machine.h
index 31a7013d5..959b1328d 100644
--- a/libc/sysdeps/x86_64/dl-machine.h
+++ b/libc/sysdeps/x86_64/dl-machine.h
@@ -26,6 +26,7 @@
#include <sys/param.h>
#include <sysdep.h>
#include <tls.h>
+#include <dl-tlsdesc.h>
/* Return nonzero iff ELF header is compatible with the running host. */
static inline int __attribute__ ((unused))
@@ -131,6 +132,10 @@ elf_machine_runtime_setup (struct link_map *l, int lazy, int profile)
got[2] = (Elf64_Addr) &_dl_runtime_resolve;
}
+ if (l->l_info[ADDRIDX (DT_TLSDESC_GOT)] && lazy)
+ *(Elf64_Addr*)(D_PTR (l, l_info[ADDRIDX (DT_TLSDESC_GOT)]) + l->l_addr)
+ = (Elf64_Addr) &_dl_tlsdesc_resolve_rela;
+
return lazy;
}
@@ -194,7 +199,9 @@ _dl_start_user:\n\
# define elf_machine_type_class(type) \
((((type) == R_X86_64_JUMP_SLOT \
|| (type) == R_X86_64_DTPMOD64 \
- || (type) == R_X86_64_DTPOFF64 || (type) == R_X86_64_TPOFF64) \
+ || (type) == R_X86_64_DTPOFF64 \
+ || (type) == R_X86_64_TPOFF64 \
+ || (type) == R_X86_64_TLSDESC) \
* ELF_RTYPE_CLASS_PLT) \
| (((type) == R_X86_64_COPY) * ELF_RTYPE_CLASS_COPY))
#else
@@ -323,6 +330,41 @@ elf_machine_rela (struct link_map *map, const Elf64_Rela *reloc,
*reloc_addr = sym->st_value + reloc->r_addend;
# endif
break;
+ case R_X86_64_TLSDESC:
+ {
+ struct tlsdesc volatile *td =
+ (struct tlsdesc volatile *)reloc_addr;
+
+# ifndef RTLD_BOOTSTRAP
+ if (! sym)
+ {
+ td->arg = (void*)reloc->r_addend;
+ td->entry = _dl_tlsdesc_undefweak;
+ }
+ else
+# endif
+ {
+# ifndef RTLD_BOOTSTRAP
+# ifndef SHARED
+ CHECK_STATIC_TLS (map, sym_map);
+# else
+ if (!TRY_STATIC_TLS (map, sym_map))
+ {
+ td->arg = _dl_make_tlsdesc_dynamic
+ (sym_map, sym->st_value + reloc->r_addend);
+ td->entry = _dl_tlsdesc_dynamic;
+ }
+ else
+# endif
+# endif
+ {
+ td->arg = (void*)(sym->st_value - sym_map->l_tls_offset
+ + reloc->r_addend);
+ td->entry = _dl_tlsdesc_return;
+ }
+ }
+ break;
+ }
case R_X86_64_TPOFF64:
/* The offset is negative, forward from the thread pointer. */
# ifndef RTLD_BOOTSTRAP
@@ -435,6 +477,15 @@ elf_machine_lazy_rel (struct link_map *map,
map->l_mach.plt
+ (((Elf64_Addr) reloc_addr) - map->l_mach.gotplt) * 2;
}
+ else if (__builtin_expect (r_type == R_X86_64_TLSDESC, 1))
+ {
+ struct tlsdesc volatile * __attribute__((__unused__)) td =
+ (struct tlsdesc volatile *)reloc_addr;
+
+ td->arg = (void*)reloc;
+ td->entry = (void*)(D_PTR (map, l_info[ADDRIDX (DT_TLSDESC_PLT)])
+ + map->l_addr);
+ }
else
_dl_reloc_bad_type (map, r_type, 1);
}
diff --git a/libc/sysdeps/x86_64/dl-tls.h b/libc/sysdeps/x86_64/dl-tls.h
index 3e4768dc1..9b389edb4 100644
--- a/libc/sysdeps/x86_64/dl-tls.h
+++ b/libc/sysdeps/x86_64/dl-tls.h
@@ -1,5 +1,5 @@
/* Thread-local storage handling in the ELF dynamic linker. x86-64 version.
- Copyright (C) 2002 Free Software Foundation, Inc.
+ Copyright (C) 2002, 2005 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 @@
/* Type used for the representation of TLS information in the GOT. */
-typedef struct
+typedef struct dl_tls_index
{
unsigned long int ti_module;
unsigned long int ti_offset;
diff --git a/libc/sysdeps/x86_64/dl-tlsdesc.S b/libc/sysdeps/x86_64/dl-tlsdesc.S
new file mode 100644
index 000000000..5eac1f2a5
--- /dev/null
+++ b/libc/sysdeps/x86_64/dl-tlsdesc.S
@@ -0,0 +1,245 @@
+/* Thread-local storage handling in the ELF dynamic linker. x86_64 version.
+ Copyright (C) 2004, 2005, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+#include <tls.h>
+#include "tlsdesc.h"
+
+ .text
+
+ /* This function is used to compute the TP offset for symbols in
+ Static TLS, i.e., whose TP offset is the same for all
+ threads.
+
+ The incoming %rax points to the TLS descriptor, such that
+ 0(%rax) points to _dl_tlsdesc_return itself, and 8(%rax) holds
+ the TP offset of the symbol corresponding to the object
+ denoted by the argument. */
+
+ .hidden _dl_tlsdesc_return
+ .global _dl_tlsdesc_return
+ .type _dl_tlsdesc_return,@function
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_return:
+ movq 8(%rax), %rax
+ ret
+ cfi_endproc
+ .size _dl_tlsdesc_return, .-_dl_tlsdesc_return
+
+ /* This function is used for undefined weak TLS symbols, for
+ which the base address (i.e., disregarding any addend) should
+ resolve to NULL.
+
+ %rax points to the TLS descriptor, such that 0(%rax) points to
+ _dl_tlsdesc_undefweak itself, and 8(%rax) holds the addend.
+ We return the addend minus the TP, such that, when the caller
+ adds TP, it gets the addend back. If that's zero, as usual,
+ that's most likely a NULL pointer. */
+
+ .hidden _dl_tlsdesc_undefweak
+ .global _dl_tlsdesc_undefweak
+ .type _dl_tlsdesc_undefweak,@function
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_undefweak:
+ movq 8(%rax), %rax
+ subq %fs:0, %rax
+ ret
+ cfi_endproc
+ .size _dl_tlsdesc_undefweak, .-_dl_tlsdesc_undefweak
+
+#ifdef SHARED
+ .hidden _dl_tlsdesc_dynamic
+ .global _dl_tlsdesc_dynamic
+ .type _dl_tlsdesc_dynamic,@function
+
+ /* %rax points to the TLS descriptor, such that 0(%rax) points to
+ _dl_tlsdesc_dynamic itself, and 8(%rax) points to a struct
+ tlsdesc_dynamic_arg object. It must return in %rax the offset
+ between the thread pointer and the object denoted by the
+ argument, without clobbering any registers.
+
+ The assembly code that follows is a rendition of the following
+ C code, hand-optimized a little bit.
+
+ptrdiff_t
+_dl_tlsdesc_dynamic (register struct tlsdesc *tdp asm ("%rax"))
+{
+ struct tlsdesc_dynamic_arg *td = tdp->arg;
+ dtv_t *dtv = *(dtv_t **)((char *)__thread_pointer + DTV_OFFSET);
+ if (__builtin_expect (td->gen_count <= dtv[0].counter
+ && (dtv[td->tlsinfo.ti_module].pointer.val
+ != TLS_DTV_UNALLOCATED),
+ 1))
+ return dtv[td->tlsinfo.ti_module].pointer.val + td->tlsinfo.ti_offset
+ - __thread_pointer;
+
+ return __tls_get_addr_internal (&td->tlsinfo) - __thread_pointer;
+}
+*/
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_dynamic:
+ /* Preserve call-clobbered registers that we modify.
+ We need two scratch regs anyway. */
+ movq %rsi, -16(%rsp)
+ movq %fs:DTV_OFFSET, %rsi
+ movq %rdi, -8(%rsp)
+ movq TLSDESC_ARG(%rax), %rdi
+ movq (%rsi), %rax
+ cmpq %rax, TLSDESC_GEN_COUNT(%rdi)
+ ja .Lslow
+ movq TLSDESC_MODID(%rdi), %rax
+ salq $4, %rax
+ movq (%rax,%rsi), %rax
+ cmpq $-1, %rax
+ je .Lslow
+ addq TLSDESC_MODOFF(%rdi), %rax
+.Lret:
+ movq -16(%rsp), %rsi
+ subq %fs:0, %rax
+ movq -8(%rsp), %rdi
+ ret
+.Lslow:
+ /* Besides rdi and rsi, saved above, save rdx, rcx, r8, r9,
+ r10 and r11. Also, align the stack, that's off by 8 bytes. */
+ subq $72, %rsp
+ cfi_adjust_cfa_offset (72)
+ movq %rdx, 8(%rsp)
+ movq %rcx, 16(%rsp)
+ movq %r8, 24(%rsp)
+ movq %r9, 32(%rsp)
+ movq %r10, 40(%rsp)
+ movq %r11, 48(%rsp)
+ /* %rdi already points to the tlsinfo data structure. */
+ call __tls_get_addr@PLT
+ movq 8(%rsp), %rdx
+ movq 16(%rsp), %rcx
+ movq 24(%rsp), %r8
+ movq 32(%rsp), %r9
+ movq 40(%rsp), %r10
+ movq 48(%rsp), %r11
+ addq $72, %rsp
+ cfi_adjust_cfa_offset (-72)
+ jmp .Lret
+ cfi_endproc
+ .size _dl_tlsdesc_dynamic, .-_dl_tlsdesc_dynamic
+#endif /* SHARED */
+
+ /* This function is a wrapper for a lazy resolver for TLS_DESC
+ RELA relocations. The incoming 0(%rsp) points to the caller's
+ link map, pushed by the dynamic object's internal lazy TLS
+ resolver front-end before tail-calling us. We need to pop it
+ ourselves. %rax points to a TLS descriptor, such that 0(%rax)
+ holds the address of the internal resolver front-end (unless
+ some other thread beat us to resolving it) and 8(%rax) holds a
+ pointer to the relocation.
+
+ When the actual resolver returns, it will have adjusted the
+ TLS descriptor such that we can tail-call it for it to return
+ the TP offset of the symbol. */
+
+ .hidden _dl_tlsdesc_resolve_rela
+ .global _dl_tlsdesc_resolve_rela
+ .type _dl_tlsdesc_resolve_rela,@function
+ cfi_startproc
+ .align 16
+ /* The PLT entry will have pushed the link_map pointer. */
+_dl_tlsdesc_resolve_rela:
+ cfi_adjust_cfa_offset (8)
+ /* Save all call-clobbered registers. */
+ subq $72, %rsp
+ cfi_adjust_cfa_offset (72)
+ movq %rax, (%rsp)
+ movq %rdi, 8(%rsp)
+ movq %rax, %rdi /* Pass tlsdesc* in %rdi. */
+ movq %rsi, 16(%rsp)
+ movq 72(%rsp), %rsi /* Pass link_map* in %rsi. */
+ movq %r8, 24(%rsp)
+ movq %r9, 32(%rsp)
+ movq %r10, 40(%rsp)
+ movq %r11, 48(%rsp)
+ movq %rdx, 56(%rsp)
+ movq %rcx, 64(%rsp)
+ call _dl_tlsdesc_resolve_rela_fixup
+ movq (%rsp), %rax
+ movq 8(%rsp), %rdi
+ movq 16(%rsp), %rsi
+ movq 24(%rsp), %r8
+ movq 32(%rsp), %r9
+ movq 40(%rsp), %r10
+ movq 48(%rsp), %r11
+ movq 56(%rsp), %rdx
+ movq 64(%rsp), %rcx
+ addq $80, %rsp
+ cfi_adjust_cfa_offset (-80)
+ jmp *(%rax)
+ cfi_endproc
+ .size _dl_tlsdesc_resolve_rela, .-_dl_tlsdesc_resolve_rela
+
+ /* This function is a placeholder for lazy resolving of TLS
+ relocations. Once some thread starts resolving a TLS
+ relocation, it sets up the TLS descriptor to use this
+ resolver, such that other threads that would attempt to
+ resolve it concurrently may skip the call to the original lazy
+ resolver and go straight to a condition wait.
+
+ When the actual resolver returns, it will have adjusted the
+ TLS descriptor such that we can tail-call it for it to return
+ the TP offset of the symbol. */
+
+ .hidden _dl_tlsdesc_resolve_hold
+ .global _dl_tlsdesc_resolve_hold
+ .type _dl_tlsdesc_resolve_hold,@function
+ cfi_startproc
+ .align 16
+_dl_tlsdesc_resolve_hold:
+0:
+ /* Save all call-clobbered registers. */
+ subq $72, %rsp
+ cfi_adjust_cfa_offset (72)
+ movq %rax, (%rsp)
+ movq %rdi, 8(%rsp)
+ movq %rax, %rdi /* Pass tlsdesc* in %rdi. */
+ movq %rsi, 16(%rsp)
+ /* Pass _dl_tlsdesc_resolve_hold's address in %rsi. */
+ leaq . - _dl_tlsdesc_resolve_hold(%rip), %rsi
+ movq %r8, 24(%rsp)
+ movq %r9, 32(%rsp)
+ movq %r10, 40(%rsp)
+ movq %r11, 48(%rsp)
+ movq %rdx, 56(%rsp)
+ movq %rcx, 64(%rsp)
+ call _dl_tlsdesc_resolve_hold_fixup
+1:
+ movq (%rsp), %rax
+ movq 8(%rsp), %rdi
+ movq 16(%rsp), %rsi
+ movq 24(%rsp), %r8
+ movq 32(%rsp), %r9
+ movq 40(%rsp), %r10
+ movq 48(%rsp), %r11
+ movq 56(%rsp), %rdx
+ movq 64(%rsp), %rcx
+ addq $72, %rsp
+ cfi_adjust_cfa_offset (-72)
+ jmp *(%eax)
+ cfi_endproc
+ .size _dl_tlsdesc_resolve_hold, .-_dl_tlsdesc_resolve_hold
diff --git a/libc/sysdeps/x86_64/dl-tlsdesc.h b/libc/sysdeps/x86_64/dl-tlsdesc.h
new file mode 100644
index 000000000..9e64aab5a
--- /dev/null
+++ b/libc/sysdeps/x86_64/dl-tlsdesc.h
@@ -0,0 +1,64 @@
+/* Thread-local storage descriptor handling in the ELF dynamic linker.
+ x86_64 version.
+ Copyright (C) 2005, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _X86_64_DL_TLSDESC_H
+# define _X86_64_DL_TLSDESC_H 1
+
+/* Use this to access DT_TLSDESC_PLT and DT_TLSDESC_GOT. */
+#ifndef ADDRIDX
+# define ADDRIDX(tag) (DT_NUM + DT_THISPROCNUM + DT_VERSIONTAGNUM \
+ + DT_EXTRANUM + DT_VALNUM + DT_ADDRTAGIDX (tag))
+#endif
+
+/* Type used to represent a TLS descriptor in the GOT. */
+struct tlsdesc
+{
+ ptrdiff_t (*entry)(struct tlsdesc *on_rax);
+ void *arg;
+};
+
+typedef struct dl_tls_index
+{
+ unsigned long int ti_module;
+ unsigned long int ti_offset;
+} tls_index;
+
+/* Type used as the argument in a TLS descriptor for a symbol that
+ needs dynamic TLS offsets. */
+struct tlsdesc_dynamic_arg
+{
+ tls_index tlsinfo;
+ size_t gen_count;
+};
+
+extern ptrdiff_t attribute_hidden
+ _dl_tlsdesc_return(struct tlsdesc *on_rax),
+ _dl_tlsdesc_undefweak(struct tlsdesc *on_rax),
+ _dl_tlsdesc_resolve_rela(struct tlsdesc *on_rax),
+ _dl_tlsdesc_resolve_hold(struct tlsdesc *on_rax);
+
+# ifdef SHARED
+extern void *internal_function _dl_make_tlsdesc_dynamic (struct link_map *map,
+ size_t ti_offset);
+
+extern ptrdiff_t attribute_hidden _dl_tlsdesc_dynamic(struct tlsdesc *);
+# endif
+
+#endif
diff --git a/libc/sysdeps/x86_64/fpu/s_expm1l.S b/libc/sysdeps/x86_64/fpu/s_expm1l.S
index b4f5a3efd..05a1bfcce 100644
--- a/libc/sysdeps/x86_64/fpu/s_expm1l.S
+++ b/libc/sysdeps/x86_64/fpu/s_expm1l.S
@@ -1,5 +1,5 @@
/* ix87 specific implementation of exp(x)-1.
- Copyright (C) 1996, 1997, 2001, 2002 Free Software Foundation, Inc.
+ Copyright (C) 1996, 1997, 2001, 2002, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
Based on code by John C. Bowman <bowman@ipp-garching.mpg.de>.
@@ -48,6 +48,11 @@ l2e: .tfloat 1.442695040888963407359924681002
.text
ENTRY(__expm1l)
+ movzwl 8+8(%rsp), %eax // load sign bit and 15-bit exponent
+ xorb $0x80, %ah // invert sign bit (now 1 is "positive")
+ cmpl $0xc006, %eax // is num positive and exp >= 6 (number is >= 128.0)?
+ jae __ieee754_expl // (if num is denormal, it is at least >= 64.0)
+
fldt 8(%rsp) // x
fxam // Is NaN or +-Inf?
fstsw %ax
diff --git a/libc/sysdeps/x86_64/memset.S b/libc/sysdeps/x86_64/memset.S
index c7bf2318d..681ab870e 100644
--- a/libc/sysdeps/x86_64/memset.S
+++ b/libc/sysdeps/x86_64/memset.S
@@ -55,12 +55,14 @@ L(now_dw_aligned):
cmp $0x90,%r8
jg L(ck_mem_ops_method)
L(now_dw_aligned_small):
- lea L(setPxQx)(%rip),%r11
add %r8,%rdi
#ifndef PIC
+ lea L(setPxQx)(%rip),%r11
jmpq *(%r11,%r8,8)
#else
- movslq (%r11,%r8,4),%rcx
+ lea L(Got0)(%rip),%r11
+ lea L(setPxQx)(%rip),%rcx
+ movswq (%rcx,%r8,2),%rcx
lea (%rcx,%r11,1),%r11
jmpq *%r11
#endif
@@ -115,177 +117,177 @@ L(setPxQx):
# endif
#else
L(setPxQx):
- .int L(Got0)-L(setPxQx)
- .int L(P1Q0)-L(setPxQx)
- .int L(P2Q0)-L(setPxQx)
- .int L(P3Q0)-L(setPxQx)
- .int L(P4Q0)-L(setPxQx)
- .int L(P5Q0)-L(setPxQx)
- .int L(P6Q0)-L(setPxQx)
- .int L(P7Q0)-L(setPxQx)
-
- .int L(P0Q1)-L(setPxQx)
- .int L(P1Q1)-L(setPxQx)
- .int L(P2Q1)-L(setPxQx)
- .int L(P3Q1)-L(setPxQx)
- .int L(P4Q1)-L(setPxQx)
- .int L(P5Q1)-L(setPxQx)
- .int L(P6Q1)-L(setPxQx)
- .int L(P7Q1)-L(setPxQx)
-
- .int L(P0Q2)-L(setPxQx)
- .int L(P1Q2)-L(setPxQx)
- .int L(P2Q2)-L(setPxQx)
- .int L(P3Q2)-L(setPxQx)
- .int L(P4Q2)-L(setPxQx)
- .int L(P5Q2)-L(setPxQx)
- .int L(P6Q2)-L(setPxQx)
- .int L(P7Q2)-L(setPxQx)
-
- .int L(P0Q3)-L(setPxQx)
- .int L(P1Q3)-L(setPxQx)
- .int L(P2Q3)-L(setPxQx)
- .int L(P3Q3)-L(setPxQx)
- .int L(P4Q3)-L(setPxQx)
- .int L(P5Q3)-L(setPxQx)
- .int L(P6Q3)-L(setPxQx)
- .int L(P7Q3)-L(setPxQx)
-
- .int L(P0Q4)-L(setPxQx)
- .int L(P1Q4)-L(setPxQx)
- .int L(P2Q4)-L(setPxQx)
- .int L(P3Q4)-L(setPxQx)
- .int L(P4Q4)-L(setPxQx)
- .int L(P5Q4)-L(setPxQx)
- .int L(P6Q4)-L(setPxQx)
- .int L(P7Q4)-L(setPxQx)
-
- .int L(P0Q5)-L(setPxQx)
- .int L(P1Q5)-L(setPxQx)
- .int L(P2Q5)-L(setPxQx)
- .int L(P3Q5)-L(setPxQx)
- .int L(P4Q5)-L(setPxQx)
- .int L(P5Q5)-L(setPxQx)
- .int L(P6Q5)-L(setPxQx)
- .int L(P7Q5)-L(setPxQx)
-
- .int L(P0Q6)-L(setPxQx)
- .int L(P1Q6)-L(setPxQx)
- .int L(P2Q6)-L(setPxQx)
- .int L(P3Q6)-L(setPxQx)
- .int L(P4Q6)-L(setPxQx)
- .int L(P5Q6)-L(setPxQx)
- .int L(P6Q6)-L(setPxQx)
- .int L(P7Q6)-L(setPxQx)
-
- .int L(P0Q7)-L(setPxQx)
- .int L(P1Q7)-L(setPxQx)
- .int L(P2Q7)-L(setPxQx)
- .int L(P3Q7)-L(setPxQx)
- .int L(P4Q7)-L(setPxQx)
- .int L(P5Q7)-L(setPxQx)
- .int L(P6Q7)-L(setPxQx)
- .int L(P7Q7)-L(setPxQx)
-
- .int L(P0Q8)-L(setPxQx)
- .int L(P1Q8)-L(setPxQx)
- .int L(P2Q8)-L(setPxQx)
- .int L(P3Q8)-L(setPxQx)
- .int L(P4Q8)-L(setPxQx)
- .int L(P5Q8)-L(setPxQx)
- .int L(P6Q8)-L(setPxQx)
- .int L(P7Q8)-L(setPxQx)
-
- .int L(P0Q9)-L(setPxQx)
- .int L(P1Q9)-L(setPxQx)
- .int L(P2Q9)-L(setPxQx)
- .int L(P3Q9)-L(setPxQx)
- .int L(P4Q9)-L(setPxQx)
- .int L(P5Q9)-L(setPxQx)
- .int L(P6Q9)-L(setPxQx)
- .int L(P7Q9)-L(setPxQx)
-
- .int L(P0QA)-L(setPxQx)
- .int L(P1QA)-L(setPxQx)
- .int L(P2QA)-L(setPxQx)
- .int L(P3QA)-L(setPxQx)
- .int L(P4QA)-L(setPxQx)
- .int L(P5QA)-L(setPxQx)
- .int L(P6QA)-L(setPxQx)
- .int L(P7QA)-L(setPxQx)
-
- .int L(P0QB)-L(setPxQx)
- .int L(P1QB)-L(setPxQx)
- .int L(P2QB)-L(setPxQx)
- .int L(P3QB)-L(setPxQx)
- .int L(P4QB)-L(setPxQx)
- .int L(P5QB)-L(setPxQx)
- .int L(P6QB)-L(setPxQx)
- .int L(P7QB)-L(setPxQx)
-
- .int L(P0QC)-L(setPxQx)
- .int L(P1QC)-L(setPxQx)
- .int L(P2QC)-L(setPxQx)
- .int L(P3QC)-L(setPxQx)
- .int L(P4QC)-L(setPxQx)
- .int L(P5QC)-L(setPxQx)
- .int L(P6QC)-L(setPxQx)
- .int L(P7QC)-L(setPxQx)
-
- .int L(P0QD)-L(setPxQx)
- .int L(P1QD)-L(setPxQx)
- .int L(P2QD)-L(setPxQx)
- .int L(P3QD)-L(setPxQx)
- .int L(P4QD)-L(setPxQx)
- .int L(P5QD)-L(setPxQx)
- .int L(P6QD)-L(setPxQx)
- .int L(P7QD)-L(setPxQx)
-
- .int L(P0QE)-L(setPxQx)
- .int L(P1QE)-L(setPxQx)
- .int L(P2QE)-L(setPxQx)
- .int L(P3QE)-L(setPxQx)
- .int L(P4QE)-L(setPxQx)
- .int L(P5QE)-L(setPxQx)
- .int L(P6QE)-L(setPxQx)
- .int L(P7QE)-L(setPxQx)
-
- .int L(P0QF)-L(setPxQx)
- .int L(P1QF)-L(setPxQx)
- .int L(P2QF)-L(setPxQx)
- .int L(P3QF)-L(setPxQx)
- .int L(P4QF)-L(setPxQx)
- .int L(P5QF)-L(setPxQx)
- .int L(P6QF)-L(setPxQx)
- .int L(P7QF)-L(setPxQx)
-
- .int L(P0QG)-L(setPxQx)
- .int L(P1QG)-L(setPxQx)
- .int L(P2QG)-L(setPxQx)
- .int L(P3QG)-L(setPxQx)
- .int L(P4QG)-L(setPxQx)
- .int L(P5QG)-L(setPxQx)
- .int L(P6QG)-L(setPxQx)
- .int L(P7QG)-L(setPxQx)
-
- .int L(P0QH)-L(setPxQx)
- .int L(P1QH)-L(setPxQx)
- .int L(P2QH)-L(setPxQx)
- .int L(P3QH)-L(setPxQx)
- .int L(P4QH)-L(setPxQx)
- .int L(P5QH)-L(setPxQx)
- .int L(P6QH)-L(setPxQx)
- .int L(P7QH)-L(setPxQx)
-
- .int L(P0QI)-L(setPxQx)
+ .short L(Got0)-L(Got0)
+ .short L(P1Q0)-L(Got0)
+ .short L(P2Q0)-L(Got0)
+ .short L(P3Q0)-L(Got0)
+ .short L(P4Q0)-L(Got0)
+ .short L(P5Q0)-L(Got0)
+ .short L(P6Q0)-L(Got0)
+ .short L(P7Q0)-L(Got0)
+
+ .short L(P0Q1)-L(Got0)
+ .short L(P1Q1)-L(Got0)
+ .short L(P2Q1)-L(Got0)
+ .short L(P3Q1)-L(Got0)
+ .short L(P4Q1)-L(Got0)
+ .short L(P5Q1)-L(Got0)
+ .short L(P6Q1)-L(Got0)
+ .short L(P7Q1)-L(Got0)
+
+ .short L(P0Q2)-L(Got0)
+ .short L(P1Q2)-L(Got0)
+ .short L(P2Q2)-L(Got0)
+ .short L(P3Q2)-L(Got0)
+ .short L(P4Q2)-L(Got0)
+ .short L(P5Q2)-L(Got0)
+ .short L(P6Q2)-L(Got0)
+ .short L(P7Q2)-L(Got0)
+
+ .short L(P0Q3)-L(Got0)
+ .short L(P1Q3)-L(Got0)
+ .short L(P2Q3)-L(Got0)
+ .short L(P3Q3)-L(Got0)
+ .short L(P4Q3)-L(Got0)
+ .short L(P5Q3)-L(Got0)
+ .short L(P6Q3)-L(Got0)
+ .short L(P7Q3)-L(Got0)
+
+ .short L(P0Q4)-L(Got0)
+ .short L(P1Q4)-L(Got0)
+ .short L(P2Q4)-L(Got0)
+ .short L(P3Q4)-L(Got0)
+ .short L(P4Q4)-L(Got0)
+ .short L(P5Q4)-L(Got0)
+ .short L(P6Q4)-L(Got0)
+ .short L(P7Q4)-L(Got0)
+
+ .short L(P0Q5)-L(Got0)
+ .short L(P1Q5)-L(Got0)
+ .short L(P2Q5)-L(Got0)
+ .short L(P3Q5)-L(Got0)
+ .short L(P4Q5)-L(Got0)
+ .short L(P5Q5)-L(Got0)
+ .short L(P6Q5)-L(Got0)
+ .short L(P7Q5)-L(Got0)
+
+ .short L(P0Q6)-L(Got0)
+ .short L(P1Q6)-L(Got0)
+ .short L(P2Q6)-L(Got0)
+ .short L(P3Q6)-L(Got0)
+ .short L(P4Q6)-L(Got0)
+ .short L(P5Q6)-L(Got0)
+ .short L(P6Q6)-L(Got0)
+ .short L(P7Q6)-L(Got0)
+
+ .short L(P0Q7)-L(Got0)
+ .short L(P1Q7)-L(Got0)
+ .short L(P2Q7)-L(Got0)
+ .short L(P3Q7)-L(Got0)
+ .short L(P4Q7)-L(Got0)
+ .short L(P5Q7)-L(Got0)
+ .short L(P6Q7)-L(Got0)
+ .short L(P7Q7)-L(Got0)
+
+ .short L(P0Q8)-L(Got0)
+ .short L(P1Q8)-L(Got0)
+ .short L(P2Q8)-L(Got0)
+ .short L(P3Q8)-L(Got0)
+ .short L(P4Q8)-L(Got0)
+ .short L(P5Q8)-L(Got0)
+ .short L(P6Q8)-L(Got0)
+ .short L(P7Q8)-L(Got0)
+
+ .short L(P0Q9)-L(Got0)
+ .short L(P1Q9)-L(Got0)
+ .short L(P2Q9)-L(Got0)
+ .short L(P3Q9)-L(Got0)
+ .short L(P4Q9)-L(Got0)
+ .short L(P5Q9)-L(Got0)
+ .short L(P6Q9)-L(Got0)
+ .short L(P7Q9)-L(Got0)
+
+ .short L(P0QA)-L(Got0)
+ .short L(P1QA)-L(Got0)
+ .short L(P2QA)-L(Got0)
+ .short L(P3QA)-L(Got0)
+ .short L(P4QA)-L(Got0)
+ .short L(P5QA)-L(Got0)
+ .short L(P6QA)-L(Got0)
+ .short L(P7QA)-L(Got0)
+
+ .short L(P0QB)-L(Got0)
+ .short L(P1QB)-L(Got0)
+ .short L(P2QB)-L(Got0)
+ .short L(P3QB)-L(Got0)
+ .short L(P4QB)-L(Got0)
+ .short L(P5QB)-L(Got0)
+ .short L(P6QB)-L(Got0)
+ .short L(P7QB)-L(Got0)
+
+ .short L(P0QC)-L(Got0)
+ .short L(P1QC)-L(Got0)
+ .short L(P2QC)-L(Got0)
+ .short L(P3QC)-L(Got0)
+ .short L(P4QC)-L(Got0)
+ .short L(P5QC)-L(Got0)
+ .short L(P6QC)-L(Got0)
+ .short L(P7QC)-L(Got0)
+
+ .short L(P0QD)-L(Got0)
+ .short L(P1QD)-L(Got0)
+ .short L(P2QD)-L(Got0)
+ .short L(P3QD)-L(Got0)
+ .short L(P4QD)-L(Got0)
+ .short L(P5QD)-L(Got0)
+ .short L(P6QD)-L(Got0)
+ .short L(P7QD)-L(Got0)
+
+ .short L(P0QE)-L(Got0)
+ .short L(P1QE)-L(Got0)
+ .short L(P2QE)-L(Got0)
+ .short L(P3QE)-L(Got0)
+ .short L(P4QE)-L(Got0)
+ .short L(P5QE)-L(Got0)
+ .short L(P6QE)-L(Got0)
+ .short L(P7QE)-L(Got0)
+
+ .short L(P0QF)-L(Got0)
+ .short L(P1QF)-L(Got0)
+ .short L(P2QF)-L(Got0)
+ .short L(P3QF)-L(Got0)
+ .short L(P4QF)-L(Got0)
+ .short L(P5QF)-L(Got0)
+ .short L(P6QF)-L(Got0)
+ .short L(P7QF)-L(Got0)
+
+ .short L(P0QG)-L(Got0)
+ .short L(P1QG)-L(Got0)
+ .short L(P2QG)-L(Got0)
+ .short L(P3QG)-L(Got0)
+ .short L(P4QG)-L(Got0)
+ .short L(P5QG)-L(Got0)
+ .short L(P6QG)-L(Got0)
+ .short L(P7QG)-L(Got0)
+
+ .short L(P0QH)-L(Got0)
+ .short L(P1QH)-L(Got0)
+ .short L(P2QH)-L(Got0)
+ .short L(P3QH)-L(Got0)
+ .short L(P4QH)-L(Got0)
+ .short L(P5QH)-L(Got0)
+ .short L(P6QH)-L(Got0)
+ .short L(P7QH)-L(Got0)
+
+ .short L(P0QI)-L(Got0)
# ifdef USE_EXTRA_TABLE
- .int L(P1QI)-L(setPxQx)
- .int L(P2QI)-L(setPxQx)
- .int L(P3QI)-L(setPxQx)
- .int L(P4QI)-L(setPxQx)
- .int L(P5QI)-L(setPxQx)
- .int L(P6QI)-L(setPxQx)
- .int L(P7QI)-L(setPxQx)
+ .short L(P1QI)-L(Got0)
+ .short L(P2QI)-L(Got0)
+ .short L(P3QI)-L(Got0)
+ .short L(P4QI)-L(Got0)
+ .short L(P5QI)-L(Got0)
+ .short L(P6QI)-L(Got0)
+ .short L(P7QI)-L(Got0)
# endif
#endif
.popsection
@@ -499,18 +501,20 @@ L(ck_mem_ops_method):
# align to 16 byte boundary first
#test $0xf,%rdi
#jz L(aligned_now)
- lea L(AliPxQx)(%rip),%r11
- mov $0x10,%r10
- mov %rdi,%r9
- and $0xf,%r9
- sub %r9,%r10
- and $0xf,%r10
- add %r10,%rdi
- sub %r10,%r8
+ mov $0x10,%r10
+ mov %rdi,%r9
+ and $0xf,%r9
+ sub %r9,%r10
+ and $0xf,%r10
+ add %r10,%rdi
+ sub %r10,%r8
#ifndef PIC
+ lea L(AliPxQx)(%rip),%r11
jmpq *(%r11,%r10,8)
#else
- movslq (%r11,%r10,4),%rcx
+ lea L(aligned_now)(%rip), %r11
+ lea L(AliPxQx)(%rip),%rcx
+ movswq (%rcx,%r10,2),%rcx
lea (%rcx,%r11,1),%r11
jmpq *%r11
#endif
@@ -525,23 +529,23 @@ L(AliPxQx):
.quad L(A4Q1), L(A5Q1), L(A6Q1), L(A7Q1)
#else
L(AliPxQx):
- .int L(aligned_now)-L(AliPxQx)
- .int L(A1Q0)-L(AliPxQx)
- .int L(A2Q0)-L(AliPxQx)
- .int L(A3Q0)-L(AliPxQx)
- .int L(A4Q0)-L(AliPxQx)
- .int L(A5Q0)-L(AliPxQx)
- .int L(A6Q0)-L(AliPxQx)
- .int L(A7Q0)-L(AliPxQx)
-
- .int L(A0Q1)-L(AliPxQx)
- .int L(A1Q1)-L(AliPxQx)
- .int L(A2Q1)-L(AliPxQx)
- .int L(A3Q1)-L(AliPxQx)
- .int L(A4Q1)-L(AliPxQx)
- .int L(A5Q1)-L(AliPxQx)
- .int L(A6Q1)-L(AliPxQx)
- .int L(A7Q1)-L(AliPxQx)
+ .short L(aligned_now)-L(aligned_now)
+ .short L(A1Q0)-L(aligned_now)
+ .short L(A2Q0)-L(aligned_now)
+ .short L(A3Q0)-L(aligned_now)
+ .short L(A4Q0)-L(aligned_now)
+ .short L(A5Q0)-L(aligned_now)
+ .short L(A6Q0)-L(aligned_now)
+ .short L(A7Q0)-L(aligned_now)
+
+ .short L(A0Q1)-L(aligned_now)
+ .short L(A1Q1)-L(aligned_now)
+ .short L(A2Q1)-L(aligned_now)
+ .short L(A3Q1)-L(aligned_now)
+ .short L(A4Q1)-L(aligned_now)
+ .short L(A5Q1)-L(aligned_now)
+ .short L(A6Q1)-L(aligned_now)
+ .short L(A7Q1)-L(aligned_now)
#endif
.popsection
@@ -634,12 +638,14 @@ L(8byte_move_loop):
L(8byte_move_skip):
andl $127,%r8d
lea (%rdi,%r8,1),%rdi
- lea L(setPxQx)(%rip),%r11
#ifndef PIC
+ lea L(setPxQx)(%rip),%r11
jmpq *(%r11,%r8,8) # old scheme remained for nonPIC
#else
- movslq (%r11,%r8,4),%rcx
+ lea L(Got0)(%rip),%r11
+ lea L(setPxQx)(%rip),%rcx
+ movswq (%rcx,%r8,2),%rcx
lea (%rcx,%r11,1),%r11
jmpq *%r11
#endif
@@ -676,11 +682,13 @@ L(8byte_stos_skip):
andl $7,%r8d
lea (%rdi,%r8,1),%rdi
- lea L(setPxQx)(%rip),%r11
#ifndef PIC
+ lea L(setPxQx)(%rip),%r11
jmpq *(%r11,%r8,8) # old scheme remained for nonPIC
#else
- movslq (%r11,%r8,4),%rcx
+ lea L(Got0)(%rip),%r11
+ lea L(setPxQx)(%rip),%rcx
+ movswq (%rcx,%r8,2),%rcx
lea (%rcx,%r11,1),%r11
jmpq *%r11
#endif
@@ -722,11 +730,13 @@ L(8byte_nt_move_skip):
andl $127,%r8d
lea (%rdi,%r8,1),%rdi
- lea L(setPxQx)(%rip),%r11
#ifndef PIC
+ lea L(setPxQx)(%rip),%r11
jmpq *(%r11,%r8,8) # old scheme remained for nonPIC
#else
- movslq (%r11,%r8,4),%rcx
+ lea L(Got0)(%rip),%r11
+ lea L(setPxQx)(%rip),%rcx
+ movswq (%rcx,%r8,2),%rcx
lea (%rcx,%r11,1),%r11
jmpq *%r11
#endif
@@ -736,15 +746,17 @@ L(SSE_pre):
movd %rdx,%xmm0
punpcklqdq %xmm0,%xmm0
- lea L(SSExDx)(%rip),%r9 # for later after the alignment
cmp $0xb0,%r8 # 176
jge L(byte32sse2_pre)
add %r8,%rdi
#ifndef PIC
+ lea L(SSExDx)(%rip),%r9
jmpq *(%r9,%r8,8)
#else
- movslq (%r9,%r8,4),%rcx
+ lea L(SSE0Q0)(%rip),%r9
+ lea L(SSExDx)(%rip),%rcx
+ movswq (%rcx,%r8,2),%rcx
lea (%rcx,%r9,1),%r9
jmpq *%r9
#endif
@@ -1012,13 +1024,15 @@ L(byte32sse2):
lea 0x80(%rdi),%rdi
jge L(byte32sse2)
- lea L(SSExDx)(%rip),%r11
add %r8,%rdi
#ifndef PIC
+ lea L(SSExDx)(%rip),%r11
jmpq *(%r11,%r8,8)
#else
- movslq (%r11,%r8,4),%rcx
- lea (%rcx,%r11,1),%r11
+ lea L(SSE0Q0)(%rip),%r11
+ lea L(SSExDx)(%rip),%rcx
+ movswq (%rcx,%r8,2),%rcx
+ lea (%rcx,%r11,1),%r11
jmpq *%r11
#endif
@@ -1044,13 +1058,15 @@ L(sse2_nt_move):
lea 0x80(%rdi),%rdi
jge L(sse2_nt_move)
- lea L(SSExDx)(%rip),%r11
sfence
add %r8,%rdi
#ifndef PIC
+ lea L(SSExDx)(%rip),%r11
jmpq *(%r11,%r8,8)
#else
- movslq (%r11,%r8,4),%rcx
+ lea L(SSE0Q0)(%rip),%r11
+ lea L(SSExDx)(%rip),%rcx
+ movswq (%rcx,%r8,2),%rcx
lea (%rcx,%r11,1),%r11
jmpq *%r11
#endif
@@ -1109,221 +1125,221 @@ L(SSExDx):
.quad L(SSE12QB), L(SSE13QB), L(SSE14QB), L(SSE15QB)
#else
L(SSExDx):
- .int L(SSE0Q0) -L(SSExDx)
- .int L(SSE1Q0) -L(SSExDx)
- .int L(SSE2Q0) -L(SSExDx)
- .int L(SSE3Q0) -L(SSExDx)
- .int L(SSE4Q0) -L(SSExDx)
- .int L(SSE5Q0) -L(SSExDx)
- .int L(SSE6Q0) -L(SSExDx)
- .int L(SSE7Q0) -L(SSExDx)
-
- .int L(SSE8Q0) -L(SSExDx)
- .int L(SSE9Q0) -L(SSExDx)
- .int L(SSE10Q0)-L(SSExDx)
- .int L(SSE11Q0)-L(SSExDx)
- .int L(SSE12Q0)-L(SSExDx)
- .int L(SSE13Q0)-L(SSExDx)
- .int L(SSE14Q0)-L(SSExDx)
- .int L(SSE15Q0)-L(SSExDx)
-
- .int L(SSE0Q1) -L(SSExDx)
- .int L(SSE1Q1) -L(SSExDx)
- .int L(SSE2Q1) -L(SSExDx)
- .int L(SSE3Q1) -L(SSExDx)
- .int L(SSE4Q1) -L(SSExDx)
- .int L(SSE5Q1) -L(SSExDx)
- .int L(SSE6Q1) -L(SSExDx)
- .int L(SSE7Q1) -L(SSExDx)
-
- .int L(SSE8Q1) -L(SSExDx)
- .int L(SSE9Q1) -L(SSExDx)
- .int L(SSE10Q1)-L(SSExDx)
- .int L(SSE11Q1)-L(SSExDx)
- .int L(SSE12Q1)-L(SSExDx)
- .int L(SSE13Q1)-L(SSExDx)
- .int L(SSE14Q1)-L(SSExDx)
- .int L(SSE15Q1)-L(SSExDx)
-
- .int L(SSE0Q2) -L(SSExDx)
- .int L(SSE1Q2) -L(SSExDx)
- .int L(SSE2Q2) -L(SSExDx)
- .int L(SSE3Q2) -L(SSExDx)
- .int L(SSE4Q2) -L(SSExDx)
- .int L(SSE5Q2) -L(SSExDx)
- .int L(SSE6Q2) -L(SSExDx)
- .int L(SSE7Q2) -L(SSExDx)
-
- .int L(SSE8Q2) -L(SSExDx)
- .int L(SSE9Q2) -L(SSExDx)
- .int L(SSE10Q2)-L(SSExDx)
- .int L(SSE11Q2)-L(SSExDx)
- .int L(SSE12Q2)-L(SSExDx)
- .int L(SSE13Q2)-L(SSExDx)
- .int L(SSE14Q2)-L(SSExDx)
- .int L(SSE15Q2)-L(SSExDx)
-
- .int L(SSE0Q3) -L(SSExDx)
- .int L(SSE1Q3) -L(SSExDx)
- .int L(SSE2Q3) -L(SSExDx)
- .int L(SSE3Q3) -L(SSExDx)
- .int L(SSE4Q3) -L(SSExDx)
- .int L(SSE5Q3) -L(SSExDx)
- .int L(SSE6Q3) -L(SSExDx)
- .int L(SSE7Q3) -L(SSExDx)
-
- .int L(SSE8Q3) -L(SSExDx)
- .int L(SSE9Q3) -L(SSExDx)
- .int L(SSE10Q3)-L(SSExDx)
- .int L(SSE11Q3)-L(SSExDx)
- .int L(SSE12Q3)-L(SSExDx)
- .int L(SSE13Q3)-L(SSExDx)
- .int L(SSE14Q3)-L(SSExDx)
- .int L(SSE15Q3)-L(SSExDx)
-
- .int L(SSE0Q4) -L(SSExDx)
- .int L(SSE1Q4) -L(SSExDx)
- .int L(SSE2Q4) -L(SSExDx)
- .int L(SSE3Q4) -L(SSExDx)
- .int L(SSE4Q4) -L(SSExDx)
- .int L(SSE5Q4) -L(SSExDx)
- .int L(SSE6Q4) -L(SSExDx)
- .int L(SSE7Q4) -L(SSExDx)
-
- .int L(SSE8Q4) -L(SSExDx)
- .int L(SSE9Q4) -L(SSExDx)
- .int L(SSE10Q4)-L(SSExDx)
- .int L(SSE11Q4)-L(SSExDx)
- .int L(SSE12Q4)-L(SSExDx)
- .int L(SSE13Q4)-L(SSExDx)
- .int L(SSE14Q4)-L(SSExDx)
- .int L(SSE15Q4)-L(SSExDx)
-
- .int L(SSE0Q5) -L(SSExDx)
- .int L(SSE1Q5) -L(SSExDx)
- .int L(SSE2Q5) -L(SSExDx)
- .int L(SSE3Q5) -L(SSExDx)
- .int L(SSE4Q5) -L(SSExDx)
- .int L(SSE5Q5) -L(SSExDx)
- .int L(SSE6Q5) -L(SSExDx)
- .int L(SSE7Q5) -L(SSExDx)
-
- .int L(SSE8Q5) -L(SSExDx)
- .int L(SSE9Q5) -L(SSExDx)
- .int L(SSE10Q5)-L(SSExDx)
- .int L(SSE11Q5)-L(SSExDx)
- .int L(SSE12Q5)-L(SSExDx)
- .int L(SSE13Q5)-L(SSExDx)
- .int L(SSE14Q5)-L(SSExDx)
- .int L(SSE15Q5)-L(SSExDx)
-
- .int L(SSE0Q6) -L(SSExDx)
- .int L(SSE1Q6) -L(SSExDx)
- .int L(SSE2Q6) -L(SSExDx)
- .int L(SSE3Q6) -L(SSExDx)
- .int L(SSE4Q6) -L(SSExDx)
- .int L(SSE5Q6) -L(SSExDx)
- .int L(SSE6Q6) -L(SSExDx)
- .int L(SSE7Q6) -L(SSExDx)
-
- .int L(SSE8Q6) -L(SSExDx)
- .int L(SSE9Q6) -L(SSExDx)
- .int L(SSE10Q6)-L(SSExDx)
- .int L(SSE11Q6)-L(SSExDx)
- .int L(SSE12Q6)-L(SSExDx)
- .int L(SSE13Q6)-L(SSExDx)
- .int L(SSE14Q6)-L(SSExDx)
- .int L(SSE15Q6)-L(SSExDx)
-
- .int L(SSE0Q7) -L(SSExDx)
- .int L(SSE1Q7) -L(SSExDx)
- .int L(SSE2Q7) -L(SSExDx)
- .int L(SSE3Q7) -L(SSExDx)
- .int L(SSE4Q7) -L(SSExDx)
- .int L(SSE5Q7) -L(SSExDx)
- .int L(SSE6Q7) -L(SSExDx)
- .int L(SSE7Q7) -L(SSExDx)
-
- .int L(SSE8Q7) -L(SSExDx)
- .int L(SSE9Q7) -L(SSExDx)
- .int L(SSE10Q7)-L(SSExDx)
- .int L(SSE11Q7)-L(SSExDx)
- .int L(SSE12Q7)-L(SSExDx)
- .int L(SSE13Q7)-L(SSExDx)
- .int L(SSE14Q7)-L(SSExDx)
- .int L(SSE15Q7)-L(SSExDx)
-
- .int L(SSE0Q8) -L(SSExDx)
- .int L(SSE1Q8) -L(SSExDx)
- .int L(SSE2Q8) -L(SSExDx)
- .int L(SSE3Q8) -L(SSExDx)
- .int L(SSE4Q8) -L(SSExDx)
- .int L(SSE5Q8) -L(SSExDx)
- .int L(SSE6Q8) -L(SSExDx)
- .int L(SSE7Q8) -L(SSExDx)
-
- .int L(SSE8Q8) -L(SSExDx)
- .int L(SSE9Q8) -L(SSExDx)
- .int L(SSE10Q8)-L(SSExDx)
- .int L(SSE11Q8)-L(SSExDx)
- .int L(SSE12Q8)-L(SSExDx)
- .int L(SSE13Q8)-L(SSExDx)
- .int L(SSE14Q8)-L(SSExDx)
- .int L(SSE15Q8)-L(SSExDx)
-
- .int L(SSE0Q9) -L(SSExDx)
- .int L(SSE1Q9) -L(SSExDx)
- .int L(SSE2Q9) -L(SSExDx)
- .int L(SSE3Q9) -L(SSExDx)
- .int L(SSE4Q9) -L(SSExDx)
- .int L(SSE5Q9) -L(SSExDx)
- .int L(SSE6Q9) -L(SSExDx)
- .int L(SSE7Q9) -L(SSExDx)
-
- .int L(SSE8Q9) -L(SSExDx)
- .int L(SSE9Q9) -L(SSExDx)
- .int L(SSE10Q9)-L(SSExDx)
- .int L(SSE11Q9)-L(SSExDx)
- .int L(SSE12Q9)-L(SSExDx)
- .int L(SSE13Q9)-L(SSExDx)
- .int L(SSE14Q9)-L(SSExDx)
- .int L(SSE15Q9)-L(SSExDx)
-
- .int L(SSE0QA) -L(SSExDx)
- .int L(SSE1QA) -L(SSExDx)
- .int L(SSE2QA) -L(SSExDx)
- .int L(SSE3QA) -L(SSExDx)
- .int L(SSE4QA) -L(SSExDx)
- .int L(SSE5QA) -L(SSExDx)
- .int L(SSE6QA) -L(SSExDx)
- .int L(SSE7QA) -L(SSExDx)
-
- .int L(SSE8QA) -L(SSExDx)
- .int L(SSE9QA) -L(SSExDx)
- .int L(SSE10QA)-L(SSExDx)
- .int L(SSE11QA)-L(SSExDx)
- .int L(SSE12QA)-L(SSExDx)
- .int L(SSE13QA)-L(SSExDx)
- .int L(SSE14QA)-L(SSExDx)
- .int L(SSE15QA)-L(SSExDx)
-
- .int L(SSE0QB) -L(SSExDx)
- .int L(SSE1QB) -L(SSExDx)
- .int L(SSE2QB) -L(SSExDx)
- .int L(SSE3QB) -L(SSExDx)
- .int L(SSE4QB) -L(SSExDx)
- .int L(SSE5QB) -L(SSExDx)
- .int L(SSE6QB) -L(SSExDx)
- .int L(SSE7QB) -L(SSExDx)
-
- .int L(SSE8QB) -L(SSExDx)
- .int L(SSE9QB) -L(SSExDx)
- .int L(SSE10QB)-L(SSExDx)
- .int L(SSE11QB)-L(SSExDx)
- .int L(SSE12QB)-L(SSExDx)
- .int L(SSE13QB)-L(SSExDx)
- .int L(SSE14QB)-L(SSExDx)
- .int L(SSE15QB)-L(SSExDx)
+ .short L(SSE0Q0) -L(SSE0Q0)
+ .short L(SSE1Q0) -L(SSE0Q0)
+ .short L(SSE2Q0) -L(SSE0Q0)
+ .short L(SSE3Q0) -L(SSE0Q0)
+ .short L(SSE4Q0) -L(SSE0Q0)
+ .short L(SSE5Q0) -L(SSE0Q0)
+ .short L(SSE6Q0) -L(SSE0Q0)
+ .short L(SSE7Q0) -L(SSE0Q0)
+
+ .short L(SSE8Q0) -L(SSE0Q0)
+ .short L(SSE9Q0) -L(SSE0Q0)
+ .short L(SSE10Q0)-L(SSE0Q0)
+ .short L(SSE11Q0)-L(SSE0Q0)
+ .short L(SSE12Q0)-L(SSE0Q0)
+ .short L(SSE13Q0)-L(SSE0Q0)
+ .short L(SSE14Q0)-L(SSE0Q0)
+ .short L(SSE15Q0)-L(SSE0Q0)
+
+ .short L(SSE0Q1) -L(SSE0Q0)
+ .short L(SSE1Q1) -L(SSE0Q0)
+ .short L(SSE2Q1) -L(SSE0Q0)
+ .short L(SSE3Q1) -L(SSE0Q0)
+ .short L(SSE4Q1) -L(SSE0Q0)
+ .short L(SSE5Q1) -L(SSE0Q0)
+ .short L(SSE6Q1) -L(SSE0Q0)
+ .short L(SSE7Q1) -L(SSE0Q0)
+
+ .short L(SSE8Q1) -L(SSE0Q0)
+ .short L(SSE9Q1) -L(SSE0Q0)
+ .short L(SSE10Q1)-L(SSE0Q0)
+ .short L(SSE11Q1)-L(SSE0Q0)
+ .short L(SSE12Q1)-L(SSE0Q0)
+ .short L(SSE13Q1)-L(SSE0Q0)
+ .short L(SSE14Q1)-L(SSE0Q0)
+ .short L(SSE15Q1)-L(SSE0Q0)
+
+ .short L(SSE0Q2) -L(SSE0Q0)
+ .short L(SSE1Q2) -L(SSE0Q0)
+ .short L(SSE2Q2) -L(SSE0Q0)
+ .short L(SSE3Q2) -L(SSE0Q0)
+ .short L(SSE4Q2) -L(SSE0Q0)
+ .short L(SSE5Q2) -L(SSE0Q0)
+ .short L(SSE6Q2) -L(SSE0Q0)
+ .short L(SSE7Q2) -L(SSE0Q0)
+
+ .short L(SSE8Q2) -L(SSE0Q0)
+ .short L(SSE9Q2) -L(SSE0Q0)
+ .short L(SSE10Q2)-L(SSE0Q0)
+ .short L(SSE11Q2)-L(SSE0Q0)
+ .short L(SSE12Q2)-L(SSE0Q0)
+ .short L(SSE13Q2)-L(SSE0Q0)
+ .short L(SSE14Q2)-L(SSE0Q0)
+ .short L(SSE15Q2)-L(SSE0Q0)
+
+ .short L(SSE0Q3) -L(SSE0Q0)
+ .short L(SSE1Q3) -L(SSE0Q0)
+ .short L(SSE2Q3) -L(SSE0Q0)
+ .short L(SSE3Q3) -L(SSE0Q0)
+ .short L(SSE4Q3) -L(SSE0Q0)
+ .short L(SSE5Q3) -L(SSE0Q0)
+ .short L(SSE6Q3) -L(SSE0Q0)
+ .short L(SSE7Q3) -L(SSE0Q0)
+
+ .short L(SSE8Q3) -L(SSE0Q0)
+ .short L(SSE9Q3) -L(SSE0Q0)
+ .short L(SSE10Q3)-L(SSE0Q0)
+ .short L(SSE11Q3)-L(SSE0Q0)
+ .short L(SSE12Q3)-L(SSE0Q0)
+ .short L(SSE13Q3)-L(SSE0Q0)
+ .short L(SSE14Q3)-L(SSE0Q0)
+ .short L(SSE15Q3)-L(SSE0Q0)
+
+ .short L(SSE0Q4) -L(SSE0Q0)
+ .short L(SSE1Q4) -L(SSE0Q0)
+ .short L(SSE2Q4) -L(SSE0Q0)
+ .short L(SSE3Q4) -L(SSE0Q0)
+ .short L(SSE4Q4) -L(SSE0Q0)
+ .short L(SSE5Q4) -L(SSE0Q0)
+ .short L(SSE6Q4) -L(SSE0Q0)
+ .short L(SSE7Q4) -L(SSE0Q0)
+
+ .short L(SSE8Q4) -L(SSE0Q0)
+ .short L(SSE9Q4) -L(SSE0Q0)
+ .short L(SSE10Q4)-L(SSE0Q0)
+ .short L(SSE11Q4)-L(SSE0Q0)
+ .short L(SSE12Q4)-L(SSE0Q0)
+ .short L(SSE13Q4)-L(SSE0Q0)
+ .short L(SSE14Q4)-L(SSE0Q0)
+ .short L(SSE15Q4)-L(SSE0Q0)
+
+ .short L(SSE0Q5) -L(SSE0Q0)
+ .short L(SSE1Q5) -L(SSE0Q0)
+ .short L(SSE2Q5) -L(SSE0Q0)
+ .short L(SSE3Q5) -L(SSE0Q0)
+ .short L(SSE4Q5) -L(SSE0Q0)
+ .short L(SSE5Q5) -L(SSE0Q0)
+ .short L(SSE6Q5) -L(SSE0Q0)
+ .short L(SSE7Q5) -L(SSE0Q0)
+
+ .short L(SSE8Q5) -L(SSE0Q0)
+ .short L(SSE9Q5) -L(SSE0Q0)
+ .short L(SSE10Q5)-L(SSE0Q0)
+ .short L(SSE11Q5)-L(SSE0Q0)
+ .short L(SSE12Q5)-L(SSE0Q0)
+ .short L(SSE13Q5)-L(SSE0Q0)
+ .short L(SSE14Q5)-L(SSE0Q0)
+ .short L(SSE15Q5)-L(SSE0Q0)
+
+ .short L(SSE0Q6) -L(SSE0Q0)
+ .short L(SSE1Q6) -L(SSE0Q0)
+ .short L(SSE2Q6) -L(SSE0Q0)
+ .short L(SSE3Q6) -L(SSE0Q0)
+ .short L(SSE4Q6) -L(SSE0Q0)
+ .short L(SSE5Q6) -L(SSE0Q0)
+ .short L(SSE6Q6) -L(SSE0Q0)
+ .short L(SSE7Q6) -L(SSE0Q0)
+
+ .short L(SSE8Q6) -L(SSE0Q0)
+ .short L(SSE9Q6) -L(SSE0Q0)
+ .short L(SSE10Q6)-L(SSE0Q0)
+ .short L(SSE11Q6)-L(SSE0Q0)
+ .short L(SSE12Q6)-L(SSE0Q0)
+ .short L(SSE13Q6)-L(SSE0Q0)
+ .short L(SSE14Q6)-L(SSE0Q0)
+ .short L(SSE15Q6)-L(SSE0Q0)
+
+ .short L(SSE0Q7) -L(SSE0Q0)
+ .short L(SSE1Q7) -L(SSE0Q0)
+ .short L(SSE2Q7) -L(SSE0Q0)
+ .short L(SSE3Q7) -L(SSE0Q0)
+ .short L(SSE4Q7) -L(SSE0Q0)
+ .short L(SSE5Q7) -L(SSE0Q0)
+ .short L(SSE6Q7) -L(SSE0Q0)
+ .short L(SSE7Q7) -L(SSE0Q0)
+
+ .short L(SSE8Q7) -L(SSE0Q0)
+ .short L(SSE9Q7) -L(SSE0Q0)
+ .short L(SSE10Q7)-L(SSE0Q0)
+ .short L(SSE11Q7)-L(SSE0Q0)
+ .short L(SSE12Q7)-L(SSE0Q0)
+ .short L(SSE13Q7)-L(SSE0Q0)
+ .short L(SSE14Q7)-L(SSE0Q0)
+ .short L(SSE15Q7)-L(SSE0Q0)
+
+ .short L(SSE0Q8) -L(SSE0Q0)
+ .short L(SSE1Q8) -L(SSE0Q0)
+ .short L(SSE2Q8) -L(SSE0Q0)
+ .short L(SSE3Q8) -L(SSE0Q0)
+ .short L(SSE4Q8) -L(SSE0Q0)
+ .short L(SSE5Q8) -L(SSE0Q0)
+ .short L(SSE6Q8) -L(SSE0Q0)
+ .short L(SSE7Q8) -L(SSE0Q0)
+
+ .short L(SSE8Q8) -L(SSE0Q0)
+ .short L(SSE9Q8) -L(SSE0Q0)
+ .short L(SSE10Q8)-L(SSE0Q0)
+ .short L(SSE11Q8)-L(SSE0Q0)
+ .short L(SSE12Q8)-L(SSE0Q0)
+ .short L(SSE13Q8)-L(SSE0Q0)
+ .short L(SSE14Q8)-L(SSE0Q0)
+ .short L(SSE15Q8)-L(SSE0Q0)
+
+ .short L(SSE0Q9) -L(SSE0Q0)
+ .short L(SSE1Q9) -L(SSE0Q0)
+ .short L(SSE2Q9) -L(SSE0Q0)
+ .short L(SSE3Q9) -L(SSE0Q0)
+ .short L(SSE4Q9) -L(SSE0Q0)
+ .short L(SSE5Q9) -L(SSE0Q0)
+ .short L(SSE6Q9) -L(SSE0Q0)
+ .short L(SSE7Q9) -L(SSE0Q0)
+
+ .short L(SSE8Q9) -L(SSE0Q0)
+ .short L(SSE9Q9) -L(SSE0Q0)
+ .short L(SSE10Q9)-L(SSE0Q0)
+ .short L(SSE11Q9)-L(SSE0Q0)
+ .short L(SSE12Q9)-L(SSE0Q0)
+ .short L(SSE13Q9)-L(SSE0Q0)
+ .short L(SSE14Q9)-L(SSE0Q0)
+ .short L(SSE15Q9)-L(SSE0Q0)
+
+ .short L(SSE0QA) -L(SSE0Q0)
+ .short L(SSE1QA) -L(SSE0Q0)
+ .short L(SSE2QA) -L(SSE0Q0)
+ .short L(SSE3QA) -L(SSE0Q0)
+ .short L(SSE4QA) -L(SSE0Q0)
+ .short L(SSE5QA) -L(SSE0Q0)
+ .short L(SSE6QA) -L(SSE0Q0)
+ .short L(SSE7QA) -L(SSE0Q0)
+
+ .short L(SSE8QA) -L(SSE0Q0)
+ .short L(SSE9QA) -L(SSE0Q0)
+ .short L(SSE10QA)-L(SSE0Q0)
+ .short L(SSE11QA)-L(SSE0Q0)
+ .short L(SSE12QA)-L(SSE0Q0)
+ .short L(SSE13QA)-L(SSE0Q0)
+ .short L(SSE14QA)-L(SSE0Q0)
+ .short L(SSE15QA)-L(SSE0Q0)
+
+ .short L(SSE0QB) -L(SSE0Q0)
+ .short L(SSE1QB) -L(SSE0Q0)
+ .short L(SSE2QB) -L(SSE0Q0)
+ .short L(SSE3QB) -L(SSE0Q0)
+ .short L(SSE4QB) -L(SSE0Q0)
+ .short L(SSE5QB) -L(SSE0Q0)
+ .short L(SSE6QB) -L(SSE0Q0)
+ .short L(SSE7QB) -L(SSE0Q0)
+
+ .short L(SSE8QB) -L(SSE0Q0)
+ .short L(SSE9QB) -L(SSE0Q0)
+ .short L(SSE10QB)-L(SSE0Q0)
+ .short L(SSE11QB)-L(SSE0Q0)
+ .short L(SSE12QB)-L(SSE0Q0)
+ .short L(SSE13QB)-L(SSE0Q0)
+ .short L(SSE14QB)-L(SSE0Q0)
+ .short L(SSE15QB)-L(SSE0Q0)
#endif
.popsection
diff --git a/libc/sysdeps/x86_64/tlsdesc.c b/libc/sysdeps/x86_64/tlsdesc.c
new file mode 100644
index 000000000..0cc32aab6
--- /dev/null
+++ b/libc/sysdeps/x86_64/tlsdesc.c
@@ -0,0 +1,151 @@
+/* Manage TLS descriptors. x86_64 version.
+ Copyright (C) 2005, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <link.h>
+#include <ldsodefs.h>
+#include <elf/dynamic-link.h>
+#include <tls.h>
+#include <dl-tlsdesc.h>
+#include <tlsdeschtab.h>
+
+/* The following 2 functions take a caller argument, that contains the
+ address expected to be in the TLS descriptor. If it's changed, we
+ want to return immediately. */
+
+/* This function is used to lazily resolve TLS_DESC RELA relocations.
+ The argument location is used to hold a pointer to the relocation. */
+
+void
+attribute_hidden
+_dl_tlsdesc_resolve_rela_fixup (struct tlsdesc volatile *td,
+ struct link_map *l)
+{
+ const ElfW(Rela) *reloc = td->arg;
+
+ if (_dl_tlsdesc_resolve_early_return_p
+ (td, (void*)(D_PTR (l, l_info[ADDRIDX (DT_TLSDESC_PLT)]) + l->l_addr)))
+ return;
+
+ /* The code below was borrowed from _dl_fixup(). */
+ const ElfW(Sym) *const symtab
+ = (const void *) D_PTR (l, l_info[DT_SYMTAB]);
+ const char *strtab = (const void *) D_PTR (l, l_info[DT_STRTAB]);
+ const ElfW(Sym) *sym = &symtab[ELFW(R_SYM) (reloc->r_info)];
+ lookup_t result;
+
+ /* Look up the target symbol. If the normal lookup rules are not
+ used don't look in the global scope. */
+ if (ELFW(ST_BIND) (sym->st_info) != STB_LOCAL
+ && __builtin_expect (ELFW(ST_VISIBILITY) (sym->st_other), 0) == 0)
+ {
+ const struct r_found_version *version = NULL;
+
+ if (l->l_info[VERSYMIDX (DT_VERSYM)] != NULL)
+ {
+ const ElfW(Half) *vernum =
+ (const void *) D_PTR (l, l_info[VERSYMIDX (DT_VERSYM)]);
+ ElfW(Half) ndx = vernum[ELFW(R_SYM) (reloc->r_info)] & 0x7fff;
+ version = &l->l_versions[ndx];
+ if (version->hash == 0)
+ version = NULL;
+ }
+
+ result = _dl_lookup_symbol_x (strtab + sym->st_name, l, &sym,
+ l->l_scope, version, ELF_RTYPE_CLASS_PLT,
+ DL_LOOKUP_ADD_DEPENDENCY, NULL);
+ }
+ else
+ {
+ /* We already found the symbol. The module (and therefore its load
+ address) is also known. */
+ result = l;
+ }
+
+ if (! sym)
+ {
+ td->arg = (void*)reloc->r_addend;
+ td->entry = _dl_tlsdesc_undefweak;
+ }
+ else
+ {
+# ifndef SHARED
+ CHECK_STATIC_TLS (l, result);
+# else
+ if (!TRY_STATIC_TLS (l, result))
+ {
+ td->arg = _dl_make_tlsdesc_dynamic (result, sym->st_value
+ + reloc->r_addend);
+ td->entry = _dl_tlsdesc_dynamic;
+ }
+ else
+# endif
+ {
+ td->arg = (void*)(sym->st_value - result->l_tls_offset
+ + reloc->r_addend);
+ td->entry = _dl_tlsdesc_return;
+ }
+ }
+
+ _dl_tlsdesc_wake_up_held_fixups ();
+}
+
+/* This function is used to avoid busy waiting for other threads to
+ complete the lazy relocation. Once another thread wins the race to
+ relocate a TLS descriptor, it sets the descriptor up such that this
+ function is called to wait until the resolver releases the
+ lock. */
+
+void
+attribute_hidden
+_dl_tlsdesc_resolve_hold_fixup (struct tlsdesc volatile *td,
+ void *caller)
+{
+ /* Maybe we're lucky and can return early. */
+ if (caller != td->entry)
+ return;
+
+ /* Locking here will stop execution until the running resolver runs
+ _dl_tlsdesc_wake_up_held_fixups(), releasing the lock.
+
+ FIXME: We'd be better off waiting on a condition variable, such
+ that we didn't have to hold the lock throughout the relocation
+ processing. */
+ __rtld_lock_lock_recursive (GL(dl_load_lock));
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+}
+
+/* Unmap the dynamic object, but also release its TLS descriptor table
+ if there is one. */
+
+void
+internal_function
+_dl_unmap (struct link_map *map)
+{
+ __munmap ((void *) (map)->l_map_start,
+ (map)->l_map_end - (map)->l_map_start);
+
+#if SHARED
+ /* _dl_unmap is only called for dlopen()ed libraries, for which
+ calling free() is safe, or before we've completed the initial
+ relocation, in which case calling free() is probably pointless,
+ but still safe. */
+ if (map->l_mach.tlsdesc_table)
+ htab_delete (map->l_mach.tlsdesc_table);
+#endif
+}
diff --git a/libc/sysdeps/x86_64/tlsdesc.sym b/libc/sysdeps/x86_64/tlsdesc.sym
new file mode 100644
index 000000000..33854975d
--- /dev/null
+++ b/libc/sysdeps/x86_64/tlsdesc.sym
@@ -0,0 +1,17 @@
+#include <stddef.h>
+#include <sysdep.h>
+#include <tls.h>
+#include <link.h>
+#include <dl-tlsdesc.h>
+
+--
+
+-- Abuse tls.h macros to derive offsets relative to the thread register.
+
+DTV_OFFSET offsetof(struct pthread, header.dtv)
+
+TLSDESC_ARG offsetof(struct tlsdesc, arg)
+
+TLSDESC_GEN_COUNT offsetof(struct tlsdesc_dynamic_arg, gen_count)
+TLSDESC_MODID offsetof(struct tlsdesc_dynamic_arg, tlsinfo.ti_module)
+TLSDESC_MODOFF offsetof(struct tlsdesc_dynamic_arg, tlsinfo.ti_offset)
diff --git a/libc/time/alt_digit.c b/libc/time/alt_digit.c
index 1a81ba125..95e4f07c7 100644
--- a/libc/time/alt_digit.c
+++ b/libc/time/alt_digit.c
@@ -1,5 +1,5 @@
/* Helper functions used by strftime/strptime to handle alternate digits.
- Copyright (C) 1995-2001,02 Free Software Foundation, Inc.
+ Copyright (C) 1995-2002, 2008 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
@@ -24,7 +24,7 @@
#include <string.h>
/* Some of the functions here must not be used while setlocale is called. */
-__libc_lock_define (extern, __libc_setlocale_lock attribute_hidden)
+__libc_rwlock_define (extern, __libc_setlocale_lock attribute_hidden)
#define CURRENT(item) (current->values[_NL_ITEM_INDEX (item)].string)
#define CURRENT_WSTR(item) \
@@ -77,7 +77,7 @@ _nl_get_alt_digit (unsigned int number, struct locale_data *current)
if (number >= 100 || CURRENT (ALT_DIGITS)[0] == '\0')
return NULL;
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
if (current->private.time == NULL
|| ! current->private.time->alt_digits_initialized)
@@ -88,7 +88,7 @@ _nl_get_alt_digit (unsigned int number, struct locale_data *current)
? current->private.time->alt_digits[number]
: NULL);
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
return result;
}
@@ -104,7 +104,7 @@ _nl_get_walt_digit (unsigned int number, struct locale_data *current)
if (number >= 100 || CURRENT_WSTR (_NL_WALT_DIGITS)[0] == L'\0')
return NULL;
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
if (current->private.time == NULL)
{
@@ -141,7 +141,7 @@ _nl_get_walt_digit (unsigned int number, struct locale_data *current)
result = data->walt_digits[number];
out:
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
return (wchar_t *) result;
}
@@ -159,7 +159,7 @@ _nl_parse_alt_digit (const char **strp, struct locale_data *current)
if (CURRENT_WSTR (_NL_WALT_DIGITS)[0] == L'\0')
return result;
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
if (current->private.time == NULL
|| ! current->private.time->alt_digits_initialized)
@@ -184,7 +184,7 @@ _nl_parse_alt_digit (const char **strp, struct locale_data *current)
}
}
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
if (result != -1)
*strp += maxlen;
diff --git a/libc/time/era.c b/libc/time/era.c
index a8d223733..a6f4a4cb0 100644
--- a/libc/time/era.c
+++ b/libc/time/era.c
@@ -1,5 +1,5 @@
/* Helper functions used by strftime/strptime to handle locale-specific "eras".
- Copyright (C) 1995-2001,02 Free Software Foundation, Inc.
+ Copyright (C) 1995-2002, 2008 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
@@ -24,7 +24,7 @@
#include <string.h>
/* Some of the functions here must not be used while setlocale is called. */
-__libc_lock_define (extern, __libc_setlocale_lock attribute_hidden)
+__libc_rwlock_define (extern, __libc_setlocale_lock attribute_hidden)
#define CURRENT(item) (current->values[_NL_ITEM_INDEX (item)].string)
#define CURRENT_WORD(item) (current->values[_NL_ITEM_INDEX (item)].word)
@@ -45,7 +45,7 @@ _nl_init_era_entries (struct locale_data *current)
if (CURRENT_WORD (_NL_TIME_ERA_NUM_ENTRIES) == 0)
return;
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
if (current->private.time == NULL)
{
@@ -135,7 +135,7 @@ _nl_init_era_entries (struct locale_data *current)
}
out:
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
}
struct era_entry *
diff --git a/libc/time/mktime.c b/libc/time/mktime.c
index e299375a1..e47d69615 100644
--- a/libc/time/mktime.c
+++ b/libc/time/mktime.c
@@ -1,5 +1,5 @@
/* Convert a `struct tm' to a time_t value.
- Copyright (C) 1993-1999, 2002-2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 1993-1999, 2002-2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Paul Eggert <eggert@twinsun.com>.
@@ -293,7 +293,9 @@ __mktime_internal (struct tm *tp,
int mday = tp->tm_mday;
int mon = tp->tm_mon;
int year_requested = tp->tm_year;
- int isdst = tp->tm_isdst;
+ /* Normalize the value. */
+ int isdst = ((tp->tm_isdst >> (8 * sizeof (tp->tm_isdst) - 1))
+ | (tp->tm_isdst != 0));
/* 1 if the previous probe was DST. */
int dst2;
diff --git a/libc/time/strftime_l.c b/libc/time/strftime_l.c
index eb8f06ce6..2f9668495 100644
--- a/libc/time/strftime_l.c
+++ b/libc/time/strftime_l.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2004, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2002, 2004, 2007, 2008 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
@@ -459,7 +459,8 @@ static CHAR_T const month_name[][10] =
#endif
static size_t __strftime_internal (CHAR_T *, size_t, const CHAR_T *,
- const struct tm *, bool ut_argument_spec_iso
+ const struct tm *, bool *
+ ut_argument_spec_iso
LOCALE_PARAM_PROTO) __THROW;
/* Write information from TP into S according to the format
@@ -485,7 +486,8 @@ my_strftime (s, maxsize, format, tp ut_argument LOCALE_PARAM)
tmcopy = *tp;
tp = &tmcopy;
#endif
- return __strftime_internal (s, maxsize, format, tp, false
+ bool tzset_called = false;
+ return __strftime_internal (s, maxsize, format, tp, &tzset_called
ut_argument LOCALE_ARG);
}
#ifdef _LIBC
@@ -499,7 +501,7 @@ __strftime_internal (s, maxsize, format, tp, tzset_called ut_argument
size_t maxsize;
const CHAR_T *format;
const struct tm *tp;
- bool tzset_called;
+ bool *tzset_called;
ut_argument_spec
LOCALE_PARAM_DECL
{
@@ -567,16 +569,6 @@ __strftime_internal (s, maxsize, format, tp, tzset_called ut_argument
if (! (zone && *zone))
zone = "GMT";
}
- else
- {
- /* POSIX.1 requires that local time zone information is used as
- though strftime called tzset. */
-# if HAVE_TZSET
- if (!tzset_called)
- tzset ();
- tzset_called = true;
-# endif
- }
#endif
if (hour12 > 12)
@@ -1329,7 +1321,18 @@ __strftime_internal (s, maxsize, format, tp, tzset_called ut_argument
#if HAVE_TZNAME
/* The tzset() call might have changed the value. */
if (!(zone && *zone) && tp->tm_isdst >= 0)
- zone = tzname[tp->tm_isdst];
+ {
+ /* POSIX.1 requires that local time zone information is used as
+ though strftime called tzset. */
+# if HAVE_TZSET
+ if (!*tzset_called)
+ {
+ tzset ();
+ *tzset_called = true;
+ }
+# endif
+ zone = tzname[tp->tm_isdst];
+ }
#endif
if (! zone)
zone = "";
@@ -1365,6 +1368,16 @@ __strftime_internal (s, maxsize, format, tp, tzset_called ut_argument
struct tm ltm;
time_t lt;
+ /* POSIX.1 requires that local time zone information is used as
+ though strftime called tzset. */
+# if HAVE_TZSET
+ if (!*tzset_called)
+ {
+ tzset ();
+ *tzset_called = true;
+ }
+# endif
+
ltm = *tp;
lt = mktime (&ltm);
diff --git a/libc/time/strptime_l.c b/libc/time/strptime_l.c
index c089b30ef..58741b78b 100644
--- a/libc/time/strptime_l.c
+++ b/libc/time/strptime_l.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2004, 2005, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2002, 2004, 2005, 2007, 2008 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
@@ -34,22 +34,13 @@
#endif
-#ifndef __P
-# if defined __GNUC__ || (defined __STDC__ && __STDC__)
-# define __P(args) args
-# else
-# define __P(args) ()
-# endif /* GCC. */
-#endif /* Not __P. */
-
-
#if ! HAVE_LOCALTIME_R && ! defined localtime_r
# ifdef _LIBC
# define localtime_r __localtime_r
# else
/* Approximate localtime_r as best we can in its absence. */
# define localtime_r my_localtime_r
-static struct tm *localtime_r __P ((const time_t *, struct tm *));
+static struct tm *localtime_r (const time_t *, struct tm *);
static struct tm *
localtime_r (t, tp)
const time_t *t;
@@ -956,7 +947,6 @@ __strptime_internal (rp, fmt, tmp, statep LOCALE_PARAM)
else
{
s.decided = loc;
- s.era_cnt = -1;
break;
}
diff --git a/libc/timezone/Makefile b/libc/timezone/Makefile
index 3d5b73ae9..05a48bd0e 100644
--- a/libc/timezone/Makefile
+++ b/libc/timezone/Makefile
@@ -69,13 +69,10 @@ installed-posixrules-file := $(firstword $(filter /%,$(posixrules-file)) \
$(addprefix $(inst_zonedir)/, \
$(posixrules-file)))
-ifeq ($(cross-compiling),no)
-# Don't try to install the zoneinfo files since we can't run zic.
install-others = $(addprefix $(inst_zonedir)/,$(zonenames) \
$(zonenames:%=posix/%) \
$(zonenames:%=right/%)) \
$(installed-localtime-file) $(installed-posixrules-file)
-endif
ifeq ($(have-ksh),yes)
install-others += $(inst_zonedir)/iso3166.tab $(inst_zonedir)/zone.tab
@@ -106,18 +103,35 @@ $(tzfiles:%=$(objpfx)z.%): $(objpfx)z.%: % Makefile
echo '$$(addprefix $$(inst_zonedir)/,$$($*-zones)): \' ;\
echo '$$(foreach t,$$(tzbases),$$(addprefix $$(inst_zonedir)/,$$($$t-zones)))' ;\
fi ;\
- echo '$$(addprefix $$(dir $$(inst_zonedir))zone%/right/,$$($*-zones)): \' ;\
- echo '$< $$(objpfx)zic leapseconds yearistype' ;\
- echo ' $$(tzcompile)' ;\
- echo '$$(addprefix $$(dir $$(inst_zonedir))zone%/posix/,$$($*-zones)): \' ;\
- echo '$< $$(objpfx)zic /dev/null yearistype' ;\
- echo ' $$(tzcompile)' ;\
- echo '$$(addprefix $$(dir $$(inst_zonedir))zone%/,$$($*-zones)): \' ;\
- echo '$< $$(objpfx)zic $$(leapseconds) yearistype' ;\
- echo ' $$(tzcompile)' ;\
+ echo '$$(addprefix $$(dir $$(inst_zonedir))zone%/right/,$$($*-zones)): \' ;) > $@.new
+
+ifeq (no,$(cross-compiling))
+ (echo '$< $$(objpfx)zic leapseconds yearistype' ;) >> $@.new
+else
+ (echo '$< $$(objpfx)cross-zic leapseconds yearistype' ;) >> $@.new
+endif
+
+ (echo ' $$(tzcompile)' ;\
+ echo '$$(addprefix $$(dir $$(inst_zonedir))zone%/posix/,$$($*-zones)): \' ;) >> $@.new
+
+ifeq (no,$(cross-compiling))
+ (echo '$< $$(objpfx)zic /dev/null yearistype' ;) >> $@.new
+else
+ (echo '$< $$(objpfx)cross-zic /dev/null yearistype' ;) >> $@.new
+endif
+
+ (echo ' $$(tzcompile)' ;\
+ echo '$$(addprefix $$(dir $$(inst_zonedir))zone%/,$$($*-zones)): \' ;) >> $@.new
+
+ifeq (no,$(cross-compiling))
+ (echo '$< $$(objpfx)zic $$(leapseconds) yearistype' ;) >> $@.new
+else
+ (echo '$< $$(objpfx)cross-zic $$(leapseconds) yearistype' ;) >> $@.new
+endif
+
+ (echo ' $$(tzcompile)' ;\
echo 'endif' ;\
- echo 'zonenames := $$(zonenames) $$($*-zones)' ;\
- ) > $@.new
+ echo 'zonenames := $$(zonenames) $$($*-zones)' ;) >> $@.new
mv $@.new $@
.PHONY: echo-zonenames
@@ -128,7 +142,11 @@ echo-zonenames:
# We have to use `-d $(inst_zonedir)' to explictly tell zic where to
# place the output files although $(zonedir) is compiled in. But the
# user might have set $(install_root) on the command line of `make install'.
+ifeq (no,$(cross-compiling))
zic-cmd = $(built-program-cmd) -d $(inst_zonedir)
+else
+zic-cmd = $(objpfx)cross-zic -d $(inst_zonedir)
+endif
tzcompile = $(zic-cmd)$(target-zone-flavor) -L $(word 3,$^) \
-y $(dir $(word 4,$^))$(notdir $(word 4,$^)) $<
@@ -158,8 +176,16 @@ $(installed-posixrules-file): $(inst_zonedir)/$(posixrules) $(objpfx)zic \
$(zic-cmd) -p $(posixrules)
endif
+zic-objs = zic.o ialloc.o scheck.o
-$(objpfx)zic: $(objpfx)scheck.o $(objpfx)ialloc.o
+$(objpfx)zic: $(addprefix $(objpfx), $(zic-objs))
+
+$(addprefix $(objpfx)cross-,$(zic-objs)): $(objpfx)cross-%.o: %.c
+ gcc $< -c $(OUTPUT_OPTION) $(CFLAGS-$*.c) $(CPPFLAGS-$*) \
+ $(compile-mkdep-flags)
+
+$(objpfx)cross-zic: $(addprefix $(objpfx)cross-,$(zic-objs))
+ gcc $(addprefix $(objpfx)cross-,$(zic-objs)) -o $@
tz-cflags = -DTZDIR='"$(zonedir)"' \
-DTZDEFAULT='"$(localtime-file)"' \
@@ -192,7 +218,11 @@ test-tz-ENV = TZDIR=$(testdata)
tst-timezone-ENV = TZDIR=$(testdata)
# Note this must come second in the deps list for $(built-program-cmd) to work.
+ifeq (no,$(cross-compiling))
zic-deps = $(objpfx)zic $(leapseconds) yearistype
+else
+zic-deps = $(objpfx)cross-zic $(objpfx)zic $(leapseconds) yearistype
+endif
$(testdata)/America/New_York: northamerica $(zic-deps)
$(build-testdata)
diff --git a/libc/timezone/asia b/libc/timezone/asia
index 3007414a7..70f151532 100644
--- a/libc/timezone/asia
+++ b/libc/timezone/asia
@@ -1,4 +1,4 @@
-# @(#)asia 8.12
+# @(#)asia 8.18
# <pre>
# This data is by no means authoritative; if you think you know better,
@@ -446,13 +446,13 @@ Zone Asia/Dili 8:22:20 - LMT 1912
# India
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
-Zone Asia/Calcutta 5:53:28 - LMT 1880 # Kolkata
+Zone Asia/Kolkata 5:53:28 - LMT 1880 # Kolkata
5:53:20 - HMT 1941 Oct # Howrah Mean Time?
6:30 - BURT 1942 May 15 # Burma Time
5:30 - IST 1942 Sep
5:30 1:00 IST 1945 Oct 15
5:30 - IST
-# The following are like Asia/Calcutta:
+# The following are like Asia/Kolkata:
# Andaman Is
# Lakshadweep (Laccadive, Minicoy and Amindivi Is)
# Nicobar Is
@@ -577,6 +577,15 @@ Zone Asia/Jayapura 9:22:48 - LMT 1932 Nov
# daylight saving time ...
# http://uk.reuters.com/article/oilRpt/idUKBLA65048420070916
#
+# From Roozbeh Pournader (2007-11-05):
+# This is quoted from Official Gazette of the Islamic Republic of
+# Iran, Volume 63, Number 18242, dated Tuesday 1386/6/24
+# [2007-10-16]. I am doing the best translation I can:...
+# The official time of the country will be moved forward for one hour
+# on the 24 hours of the first day of the month of Farvardin and will
+# be changed back to its previous state on the 24 hours of the
+# thirtieth day of Shahrivar.
+#
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule Iran 1978 1980 - Mar 21 0:00 1:00 D
Rule Iran 1978 only - Oct 21 0:00 0 S
@@ -651,6 +660,21 @@ Zone Asia/Tehran 3:25:44 - LMT 1916
#
# So we'll ignore the Economist's claim.
+# From Steffen Thorsen (2008-03-10):
+# The cabinet in Iraq abolished DST last week, according to the following
+# news sources (in Arabic):
+# <a href="http://www.aljeeran.net/wesima_articles/news-20080305-98602.html">
+# http://www.aljeeran.net/wesima_articles/news-20080305-98602.html
+# </a>
+# <a href="http://www.aswataliraq.info/look/article.tpl?id=2047&IdLanguage=17&IdPublication=4&NrArticle=71743&NrIssue=1&NrSection=10">
+# http://www.aswataliraq.info/look/article.tpl?id=2047&IdLanguage=17&IdPublication=4&NrArticle=71743&NrIssue=1&NrSection=10
+# </a>
+#
+# We have published a short article in English about the change:
+# <a href="http://www.timeanddate.com/news/time/iraq-dumps-daylight-saving.html">
+# http://www.timeanddate.com/news/time/iraq-dumps-daylight-saving.html
+# </a>
+
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule Iraq 1982 only - May 1 0:00 1:00 D
Rule Iraq 1982 1984 - Oct 1 0:00 0 S
@@ -661,8 +685,8 @@ Rule Iraq 1986 1990 - Mar lastSun 1:00s 1:00 D
# IATA SSIM (1991/1996) says Apr 1 12:01am UTC; guess the `:01' is a typo.
# Shanks & Pottenger say Iraq did not observe DST 1992/1997; ignore this.
#
-Rule Iraq 1991 max - Apr 1 3:00s 1:00 D
-Rule Iraq 1991 max - Oct 1 3:00s 0 S
+Rule Iraq 1991 2007 - Apr 1 3:00s 1:00 D
+Rule Iraq 1991 2007 - Oct 1 3:00s 0 S
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Baghdad 2:57:40 - LMT 1890
2:57:36 - BMT 1918 # Baghdad Mean Time?
@@ -1678,7 +1702,7 @@ Zone Asia/Singapore 6:55:25 - LMT 1901 Jan 1
# kept their clocks set five and a half hours ahead of Greenwich Mean
# Time (GMT), in line with neighbor India.
# From Paul Eggert (2006-04-18):
-# People who live in regions under Tamil control can use TZ='Asia/Calcutta',
+# People who live in regions under Tamil control can use [TZ='Asia/Kolkata'],
# as that zone has agreed with the Tamil areas since our cutoff date of 1970.
# From K Sethu (2006-04-25):
@@ -1768,10 +1792,62 @@ Rule Syria 2006 only - Sep 22 0:00 0 -
# From Paul Eggert (2007-03-29):
# Today the AP reported "Syria will switch to summertime at midnight Thursday."
# http://www.iht.com/articles/ap/2007/03/29/africa/ME-GEN-Syria-Time-Change.php
-# For lack of better info, assume the rule changed to "last Friday in March"
-# this year.
-Rule Syria 2007 max - Mar lastFri 0:00 1:00 S
-Rule Syria 2007 max - Oct 1 0:00 0 -
+Rule Syria 2007 only - Mar lastFri 0:00 1:00 S
+# From Jesper Norgard (2007-10-27):
+# The sister center ICARDA of my work CIMMYT is confirming that Syria DST will
+# not take place 1.st November at 0:00 o'clock but 1.st November at 24:00 or
+# rather Midnight between Thursday and Friday. This does make more sence than
+# having it between Wednesday and Thursday (two workdays in Syria) since the
+# weekend in Syria is not Saturday and Sunday, but Friday and Saturday. So now
+# it is implemented at midnight of the last workday before weekend...
+#
+# From Steffen Thorsen (2007-10-27):
+# Jesper Norgaard Welen wrote:
+#
+# > "Winter local time in Syria will be observed at midnight of Thursday 1
+# > November 2007, and the clock will be put back 1 hour."
+#
+# I found confirmation on this in this gov.sy-article (Arabic):
+# http://wehda.alwehda.gov.sy/_print_veiw.asp?FileName=12521710520070926111247
+#
+# which using Google's translate tools says:
+# Council of Ministers also approved the commencement of work on
+# identifying the winter time as of Friday, 2/11/2007 where the 60th
+# minute delay at midnight Thursday 1/11/2007.
+Rule Syria 2007 only - Nov Fri>=1 0:00 0 -
+
+# From Stephen Colebourne (2008-03-17):
+# For everyone's info, I saw an IATA time zone change for [Syria] for
+# this month (March 2008) in the last day or so...This is the data IATA
+# are now using:
+# Country Time Standard --- DST Start --- --- DST End --- DST
+# Name Zone Variation Time Date Time Date
+# Variation
+# Syrian Arab
+# Republic SY +0200 2200 03APR08 2100 30SEP08 +0300
+# 2200 02APR09 2100 30SEP09 +0300
+# 2200 01APR10 2100 30SEP10 +0300
+
+# From Arthur David Olson (2008-03-17):
+# Here's a link to English-language coverage by the Syrian Arab News
+# Agency (SANA)...
+# <a href="http://www.sana.sy/eng/21/2008/03/11/165173.htm">
+# http://www.sana.sy/eng/21/2008/03/11/165173.htm
+# </a>...which reads (in part) "The Cabinet approved the suggestion of the
+# Ministry of Electricity to begin daylight savings time on Friday April
+# 4th, advancing clocks one hour ahead on midnight of Thursday April 3rd."
+# Since Syria is two hours east of UTC, the 2200 and 2100 transition times
+# shown above match up with midnight in Syria.
+
+# From Arthur David Olson (2008-03-18):
+# My buest guess at a Syrian rule is "the Friday nearest April 1";
+# coding that involves either using a "Mar Fri>=29" construct that old time zone
+# compilers can't handle or having multiple Rules (a la Israel).
+# For now, use "Apr Fri>=1", and go with IATA on a uniform Sep 30 end.
+
+Rule Syria 2008 max - Apr Fri>=1 0:00 1:00 S
+Rule Syria 2008 max - Oct 1 0:00 0 -
+
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Damascus 2:25:12 - LMT 1920 # Dimashq
2:00 Syria EE%sT
@@ -1825,13 +1901,13 @@ Zone Asia/Tashkent 4:37:12 - LMT 1924 May 2
# Vietnam
-# From Paul Eggert (1993-11-18):
-# Saigon's official name is Thanh-Pho Ho Chi Minh, but it's too long.
-# We'll stick with the traditional name for now.
+# From Arthur David Olson (2008-03-18):
+# The English-language name of Vietnam's most populous city is "Ho Chi Min City";
+# we use Ho_Chi_Minh below to avoid a name of more than 14 characters.
# From Shanks & Pottenger:
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
-Zone Asia/Saigon 7:06:40 - LMT 1906 Jun 9
+Zone Asia/Ho_Chi_Minh 7:06:40 - LMT 1906 Jun 9
7:06:20 - SMT 1911 Mar 11 0:01 # Saigon MT?
7:00 - ICT 1912 May
8:00 - ICT 1931 May
diff --git a/libc/timezone/backward b/libc/timezone/backward
index 7c922604e..a65991c2d 100644
--- a/libc/timezone/backward
+++ b/libc/timezone/backward
@@ -1,4 +1,4 @@
-# @(#)backward 8.3
+# @(#)backward 8.6
# This file provides links between current names for time zones
# and their old names. Many names changed in late 1993.
@@ -24,12 +24,15 @@ Link America/St_Thomas America/Virgin
Link Asia/Ashgabat Asia/Ashkhabad
Link Asia/Chongqing Asia/Chungking
Link Asia/Dhaka Asia/Dacca
+Link Asia/Kolkata Asia/Calcutta
Link Asia/Macau Asia/Macao
Link Asia/Jerusalem Asia/Tel_Aviv
+Link Asia/Ho_Chi_Minh Asia/Saigon
Link Asia/Thimphu Asia/Thimbu
Link Asia/Makassar Asia/Ujung_Pandang
Link Asia/Ulaanbaatar Asia/Ulan_Bator
Link Atlantic/Faroe Atlantic/Faeroe
+Link Europe/Oslo Atlantic/Jan_Mayen
Link Australia/Sydney Australia/ACT
Link Australia/Sydney Australia/Canberra
Link Australia/Lord_Howe Australia/LHI
diff --git a/libc/timezone/europe b/libc/timezone/europe
index 60290ddc5..73eed00fc 100644
--- a/libc/timezone/europe
+++ b/libc/timezone/europe
@@ -1,4 +1,4 @@
-# @(#)europe 8.11
+# @(#)europe 8.12
# <pre>
# This data is by no means authoritative; if you think you know better,
@@ -1714,7 +1714,6 @@ Zone Europe/Oslo 0:43:00 - LMT 1895 Jan 1
# come up with more definitive info about the timekeeping during the
# war years it's probably best just do do the following for now:
Link Europe/Oslo Arctic/Longyearbyen
-Link Europe/Oslo Atlantic/Jan_Mayen
# Poland
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
diff --git a/libc/timezone/iso3166.tab b/libc/timezone/iso3166.tab
index 0e985e95b..8d6239958 100644
--- a/libc/timezone/iso3166.tab
+++ b/libc/timezone/iso3166.tab
@@ -1,12 +1,12 @@
# ISO 3166 alpha-2 country codes
#
-# @(#)iso3166.tab 8.4
+# @(#)iso3166.tab 8.5
#
# From Paul Eggert (2006-09-27):
#
# This file contains a table with the following columns:
# 1. ISO 3166-1 alpha-2 country code, current as of
-# ISO 3166-1 Newsletter No. V-12 (2006-09-26). See:
+# ISO 3166-1 Newsletter VI-1 (2007-09-21). See:
# <a href="http://www.iso.org/iso/en/prods-services/iso3166ma/index.html">
# ISO 3166 Maintenance agency (ISO 3166/MA)
# </a>.
@@ -47,6 +47,7 @@ BG Bulgaria
BH Bahrain
BI Burundi
BJ Benin
+BL St Barthelemy
BM Bermuda
BN Brunei
BO Bolivia
@@ -159,6 +160,7 @@ MA Morocco
MC Monaco
MD Moldova
ME Montenegro
+MF St Martin (French part)
MG Madagascar
MH Marshall Islands
MK Macedonia
diff --git a/libc/timezone/leapseconds b/libc/timezone/leapseconds
index 583451e49..35df858d7 100644
--- a/libc/timezone/leapseconds
+++ b/libc/timezone/leapseconds
@@ -1,4 +1,4 @@
-# @(#)leapseconds 8.4
+# @(#)leapseconds 8.5
# Allowance for leapseconds added to each timezone file.
@@ -46,26 +46,27 @@ Leap 1998 Dec 31 23:59:60 + S
Leap 2005 Dec 31 23:59:60 + S
# INTERNATIONAL EARTH ROTATION AND REFERENCE SYSTEMS SERVICE (IERS)
+#
# SERVICE INTERNATIONAL DE LA ROTATION TERRESTRE ET DES SYSTEMES DE REFERENCE
#
# SERVICE DE LA ROTATION TERRESTRE
-# OBSERVATOIRE DE PARIS
+# OBSERVATOIRE DE PARIS
# 61, Av. de l'Observatoire 75014 PARIS (France)
# Tel. : 33 (0) 1 40 51 22 26
# FAX : 33 (0) 1 40 51 22 91
# Internet : services.iers@obspm.fr
#
-# Paris, 28 June 2007
+# Paris, 18 January 2008
#
-# Bulletin C 34
+# Bulletin C 35
#
-# To authorities responsible
+# To authorities responsible
# for the measurement and
-# distribution of time
+# distribution of time
#
# INFORMATION ON UTC - TAI
#
-# NO positive leap second will be introduced at the end of December 2007.
+# NO positive leap second will be introduced at the end of June 2008.
# The difference between Coordinated Universal Time UTC and the
# International Atomic Time TAI is :
#
@@ -77,6 +78,6 @@ Leap 2005 Dec 31 23:59:60 + S
# will be no time step at the next possible date.
#
# Daniel GAMBIS
-# Director
-# Earth Orientation Center of IERS
+# Head
+# Earth Orientation Center of the IERS
# Observatoire de Paris, France
diff --git a/libc/timezone/northamerica b/libc/timezone/northamerica
index 73e13a520..60e5d51e0 100644
--- a/libc/timezone/northamerica
+++ b/libc/timezone/northamerica
@@ -1,4 +1,4 @@
-# @(#)northamerica 8.18
+# @(#)northamerica 8.23
# <pre>
# also includes Central America and the Caribbean
@@ -2187,6 +2187,69 @@ Zone America/Costa_Rica -5:36:20 - LMT 1890 # San Jose
# says Cuban clocks will advance at midnight on March 10.
# For lack of better information, assume Cuba will use US rules,
# except that it switches at midnight standard time as usual.
+#
+# From Steffen Thorsen (2007-10-25):
+# Carlos Alberto Fonseca Arauz informed me that Cuba will end DST one week
+# earlier - on the last Sunday of October, just like in 2006.
+#
+# He supplied these references:
+#
+# http://www.prensalatina.com.mx/article.asp?ID=%7B4CC32C1B-A9F7-42FB-8A07-8631AFC923AF%7D&language=ES
+# http://actualidad.terra.es/sociedad/articulo/cuba_llama_ahorrar_energia_cambio_1957044.htm
+#
+# From Alex Kryvenishev (2007-10-25):
+# Here is also article from Granma (Cuba):
+#
+# [Regira] el Horario Normal desde el [proximo] domingo 28 de octubre
+# http://www.granma.cubaweb.cu/2007/10/24/nacional/artic07.html
+#
+# http://www.worldtimezone.com/dst_news/dst_news_cuba03.html
+
+# From Arthur David Olson (2008-03-09):
+# I'm in Maryland which is now observing United States Eastern Daylight
+# Time. At 9:44 local time I used RealPlayer to listen to
+# <a href="http://media.enet.cu/radioreloj">
+# http://media.enet.cu/radioreloj
+# </a>, a Cuban information station, and heard
+# the time announced as "ocho cuarenta y cuatro" ("eight forty-four"),
+# indicating that Cuba is still on standard time.
+
+# From Steffen Thorsen (2008-03-12):
+# It seems that Cuba will start DST on Sunday, 2007-03-16...
+# It was announced yesterday, according to this source (in Spanish):
+# <a href="http://www.nnc.cubaweb.cu/marzo-2008/cien-1-11-3-08.htm">
+# http://www.nnc.cubaweb.cu/marzo-2008/cien-1-11-3-08.htm
+# </a>
+#
+# Some more background information is posted here:
+# <a href="http://www.timeanddate.com/news/time/cuba-starts-dst-march-16.html">
+# http://www.timeanddate.com/news/time/cuba-starts-dst-march-16.html
+# </a>
+#
+# The article also says that Cuba has been observing DST since 1963,
+# while Shanks (and tzdata) has 1965 as the first date (except in the
+# 1940's). Many other web pages in Cuba also claim that it has been
+# observed since 1963, but with the exception of 1970 - an exception
+# which is not present in tzdata/Shanks. So there is a chance we need to
+# change some historic records as well.
+#
+# One example:
+# <a href="http://www.radiohc.cu/espanol/noticias/mar07/11mar/hor.htm">
+# http://www.radiohc.cu/espanol/noticias/mar07/11mar/hor.htm
+# </a>
+
+# From Jesper Norgaard Welen (2008-03-13):
+# The Cuban time change has just been confirmed on the most authoritative
+# web site, the Granma. Please check out
+# <a href="http://www.granma.cubaweb.cu/2008/03/13/nacional/artic10.html">
+# http://www.granma.cubaweb.cu/2008/03/13/nacional/artic10.html
+# </a>
+#
+# Basically as expected after Steffen Thorsens information, the change
+# will take place midnight between Saturday and Sunday.
+
+# From Arthur David Olson (2008-03-12):
+# Assume Sun>=15 (third Sunday) going forward.
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule Cuba 1928 only - Jun 10 0:00 1:00 D
@@ -2218,9 +2281,9 @@ Rule Cuba 1997 only - Oct 12 0:00s 0 S
Rule Cuba 1998 1999 - Mar lastSun 0:00s 1:00 D
Rule Cuba 1998 2003 - Oct lastSun 0:00s 0 S
Rule Cuba 2000 2006 - Apr Sun>=1 0:00s 1:00 D
-Rule Cuba 2006 only - Oct lastSun 0:00s 0 S
-Rule Cuba 2007 max - Mar Sun>=8 0:00s 1:00 D
-Rule Cuba 2007 max - Nov Sun>=1 0:00s 0 S
+Rule Cuba 2006 max - Oct lastSun 0:00s 0 S
+Rule Cuba 2007 only - Mar Sun>=8 0:00s 1:00 D
+Rule Cuba 2008 max - Mar Sun>=15 0:00s 1:00 D
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone America/Havana -5:29:28 - LMT 1890
@@ -2287,6 +2350,10 @@ Zone America/Grenada -4:07:00 - LMT 1911 Jul # St George's
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone America/Guadeloupe -4:06:08 - LMT 1911 Jun 8 # Pointe a Pitre
-4:00 - AST
+# St Barthelemy
+Link America/Guadeloupe America/St_Barthelemy
+# St Martin (French part)
+Link America/Guadeloupe America/Marigot
# Guatemala
#
diff --git a/libc/timezone/private.h b/libc/timezone/private.h
index d64c724ef..008d468ac 100644
--- a/libc/timezone/private.h
+++ b/libc/timezone/private.h
@@ -21,7 +21,7 @@
#ifndef lint
#ifndef NOID
-static char privatehid[] = "@(#)private.h 8.3";
+static char privatehid[] = "@(#)private.h 8.6";
#endif /* !defined NOID */
#endif /* !defined lint */
@@ -48,10 +48,6 @@ static char privatehid[] = "@(#)private.h 8.3";
#define HAVE_SETTIMEOFDAY 3
#endif /* !defined HAVE_SETTIMEOFDAY */
-#ifndef HAVE_STRERROR
-#define HAVE_STRERROR 1
-#endif /* !defined HAVE_STRERROR */
-
#ifndef HAVE_SYMLINK
#define HAVE_SYMLINK 1
#endif /* !defined HAVE_SYMLINK */
@@ -109,17 +105,15 @@ static char privatehid[] = "@(#)private.h 8.3";
#endif /* !defined WEXITSTATUS */
#if HAVE_UNISTD_H
-#include "unistd.h" /* for F_OK and R_OK */
+#include "unistd.h" /* for F_OK, R_OK, and other POSIX goodness */
#endif /* HAVE_UNISTD_H */
-#if !HAVE_UNISTD_H
#ifndef F_OK
#define F_OK 0
#endif /* !defined F_OK */
#ifndef R_OK
#define R_OK 4
#endif /* !defined R_OK */
-#endif /* !HAVE_UNISTD_H */
/* Unlike <ctype.h>'s isdigit, this also works if c < 0 | c > UCHAR_MAX. */
#define is_digit(c) ((unsigned)(c) - '0' <= 9)
@@ -165,91 +159,27 @@ typedef long int_fast64_t;
*/
/*
-** If your compiler lacks prototypes, "#define P(x) ()".
-*/
-
-#ifndef P
-#define P(x) x
-#endif /* !defined P */
-
-/*
-** SunOS 4.1.1 headers lack EXIT_SUCCESS.
-*/
-
-#ifndef EXIT_SUCCESS
-#define EXIT_SUCCESS 0
-#endif /* !defined EXIT_SUCCESS */
-
-/*
-** SunOS 4.1.1 headers lack EXIT_FAILURE.
-*/
-
-#ifndef EXIT_FAILURE
-#define EXIT_FAILURE 1
-#endif /* !defined EXIT_FAILURE */
-
-/*
-** SunOS 4.1.1 headers lack FILENAME_MAX.
-*/
-
-#ifndef FILENAME_MAX
-
-#ifndef MAXPATHLEN
-#ifdef unix
-#include "sys/param.h"
-#endif /* defined unix */
-#endif /* !defined MAXPATHLEN */
-
-#ifdef MAXPATHLEN
-#define FILENAME_MAX MAXPATHLEN
-#endif /* defined MAXPATHLEN */
-#ifndef MAXPATHLEN
-#define FILENAME_MAX 1024 /* Pure guesswork */
-#endif /* !defined MAXPATHLEN */
-
-#endif /* !defined FILENAME_MAX */
-
-/*
-** SunOS 4.1.1 libraries lack remove.
-*/
-
-#ifndef remove
-extern int unlink P((const char * filename));
-#define remove unlink
-#endif /* !defined remove */
-
-/*
-** Some ancient errno.h implementations don't declare errno.
-** But some newer errno.h implementations define it as a macro.
-** Fix the former without affecting the latter.
-*/
-
-#ifndef errno
-extern int errno;
-#endif /* !defined errno */
-
-/*
** Some time.h implementations don't declare asctime_r.
** Others might define it as a macro.
** Fix the former without affecting the latter.
*/
#ifndef asctime_r
-extern char * asctime_r();
+extern char * asctime_r(struct tm const *, char *);
#endif
/*
** Private function declarations.
*/
-char * icalloc P((int nelem, int elsize));
-char * icatalloc P((char * old, const char * new));
-char * icpyalloc P((const char * string));
-char * imalloc P((int n));
-void * irealloc P((void * pointer, int size));
-void icfree P((char * pointer));
-void ifree P((char * pointer));
-const char * scheck P((const char * string, const char * format));
+char * icalloc(int nelem, int elsize);
+char * icatalloc(char * old, const char * new);
+char * icpyalloc(const char * string);
+char * imalloc(int n);
+void * irealloc(void * pointer, int size);
+void icfree(char * pointer);
+void ifree(char * pointer);
+const char * scheck(const char * string, const char * format);
/*
** Finally, some convenience items.
@@ -337,8 +267,8 @@ const char * scheck P((const char * string, const char * format));
#if HAVE_INCOMPATIBLE_CTIME_R
#undef asctime_r
#undef ctime_r
-char *asctime_r P((struct tm const *, char *));
-char *ctime_r P((time_t const *, char *));
+char *asctime_r(struct tm const *, char *);
+char *ctime_r(time_t const *, char *);
#endif /* HAVE_INCOMPATIBLE_CTIME_R */
#ifndef YEARSPERREPEAT
diff --git a/libc/timezone/southamerica b/libc/timezone/southamerica
index bfda82764..43f73d323 100644
--- a/libc/timezone/southamerica
+++ b/libc/timezone/southamerica
@@ -1,4 +1,4 @@
-# @(#)southamerica 8.12
+# @(#)southamerica 8.19
# <pre>
# This data is by no means authoritative; if you think you know better,
@@ -105,7 +105,11 @@ Rule Arg 1989 1992 - Oct Sun>=15 0:00 1:00 S
# which did not result in the switch of a time zone, as they stayed 9 hours
# from the International Date Line.
Rule Arg 1999 only - Oct Sun>=1 0:00 1:00 S
-Rule Arg 2000 only - Mar Sun>=1 0:00 0 -
+# From Paul Eggert (2007-12-28):
+# DST was set to expire on March 5, not March 3, but since it was converted
+# to standard time on March 3 it's more convenient for us to pretend that
+# it ended on March 3.
+Rule Arg 2000 only - Mar 3 0:00 0 -
#
# From Peter Gradelski via Steffen Thorsen (2000-03-01):
# We just checked with our Sao Paulo office and they say the government of
@@ -140,6 +144,30 @@ Rule Arg 2000 only - Mar Sun>=1 0:00 0 -
# This kind of things had always been done this way in Argentina.
# We are still -03:00 all year round in all of the country.
#
+# From Steffen Thorsen (2007-12-21):
+# A user (Leonardo Chaim) reported that Argentina will adopt DST....
+# all of the country (all Zone-entries) are affected. News reports like
+# http://www.lanacion.com.ar/opinion/nota.asp?nota_id=973037 indicate
+# that Argentina will use DST next year as well, from October to
+# March, although exact rules are not given.
+#
+# From Jesper Norgaard Welen (2007-12-26)
+# The last hurdle of Argentina DST is over, the proposal was approved in
+# the lower chamber too (Deputados) with a vote 192 for and 2 against.
+# By the way thanks to Mariano Absatz and Daniel Mario Vega for the link to
+# the original scanned proposal, where the dates and the zero hours are
+# clear and unambiguous...This is the article about final approval:
+# <a href="http://www.lanacion.com.ar/politica/nota.asp?nota_id=973996">
+# http://www.lanacion.com.ar/politica/nota.asp?nota_id=973996
+# </a>
+#
+# From Paul Eggert (2007-12-22):
+# For dates after mid-2008, the following rules are my guesses and
+# are quite possibly wrong, but are more likely than no DST at all.
+Rule Arg 2007 only - Dec 30 0:00 1:00 S
+Rule Arg 2008 max - Mar Sun>=15 0:00 0 -
+Rule Arg 2008 max - Oct Sun>=1 0:00 1:00 S
+
# From Mariano Absatz (2004-05-21):
# Today it was officially published that the Province of Mendoza is changing
# its timezone this winter... starting tomorrow night....
@@ -200,6 +228,76 @@ Rule Arg 2000 only - Mar Sun>=1 0:00 0 -
# http://www.sanjuan.gov.ar/prensa/archivo/000426.html
# http://www.sanjuan.gov.ar/prensa/archivo/000441.html
+# From Alex Krivenyshev (2008-01-17):
+# Here are articles that Argentina Province San Luis is planning to end DST
+# as earlier as upcoming Monday January 21, 2008 or February 2008:
+#
+# Provincia argentina retrasa reloj y marca diferencia con resto del pais
+# (Argentine Province delayed clock and mark difference with the rest of the
+# country)
+# <a href="http://cl.invertia.com/noticias/noticia.aspx?idNoticia=200801171849_EFE_ET4373&idtel">
+# http://cl.invertia.com/noticias/noticia.aspx?idNoticia=200801171849_EFE_ET4373&idtel
+# </a>
+#
+# Es inminente que en San Luis atrasen una hora los relojes
+# (It is imminent in San Luis clocks one hour delay)
+# <a href="http://www.lagaceta.com.ar/vernotae.asp?id_nota=253414">
+# http://www.lagaceta.com.ar/vernotae.asp?id_nota=253414
+# </a>
+#
+# <a href="http://www.worldtimezone.net/dst_news/dst_news_argentina02.html">
+# http://www.worldtimezone.net/dst_news/dst_news_argentina02.html
+# </a>
+
+# From Jesper Norgaard Welen (2008-01-18):
+# The page of the San Luis provincial government
+# <a href="http://www.sanluis.gov.ar/notas.asp?idCanal=0&id=22812">
+# http://www.sanluis.gov.ar/notas.asp?idCanal=0&id=22812
+# </a>
+# confirms what Alex Krivenyshev has earlier sent to the tz
+# emailing list about that San Luis plans to return to standard
+# time much earlier than the rest of the country. It also
+# confirms that upon request the provinces San Juan and Mendoza
+# refused to follow San Luis in this change.
+#
+# The change is supposed to take place Monday the 21.st at 0:00
+# hours. As far as I understand it if this goes ahead, we need
+# a new timezone for San Luis (although there are also documented
+# independent changes in the southamerica file of San Luis in
+# 1990 and 1991 which has not been confirmed).
+
+# From Jesper Norgaard Welen (2008-01-25):
+# Unfortunately the below page has become defunct, about the San Luis
+# time change. Perhaps because it now is part of a group of pages "Most
+# important pages of 2008."
+#
+# You can use
+# <a href="http://www.sanluis.gov.ar/notas.asp?idCanal=8141&id=22834">
+# http://www.sanluis.gov.ar/notas.asp?idCanal=8141&id=22834
+# </a>
+# instead it seems. Or use "Buscador" from the main page of the San Luis
+# government, and fill in "huso" and click OK, and you will get 3 pages
+# from which the first one is identical to the above.
+
+# From Mariano Absatz (2008-01-28):
+# I can confirm that the Province of San Luis (and so far only that
+# province) decided to go back to UTC-3 effective midnight Jan 20th 2008
+# (that is, Monday 21st at 0:00 is the time the clocks were delayed back
+# 1 hour), and they intend to keep UTC-3 as their timezone all year round
+# (that is, unless they change their mind any minute now).
+#
+# So we'll have to add yet another city to 'southamerica' (I think San
+# Luis city is the mos populated city in the Province, so it'd be
+# America/Argentina/San_Luis... of course I can't remember if San Luis's
+# history of particular changes goes along with Mendoza or San Juan :-(
+# (I only remember not being able to collect hard facts about San Luis
+# back in 2004, when these provinces changed to UTC-4 for a few days, I
+# mailed them personally and never got an answer).
+
+# From Arthur David Olson (2008-03-15):
+# Until there's better information, asssume San Luis was like San Juan
+# rather than Mendoza (since San Juan has a simpler DST history).
+
# Unless otherwise specified, data are from Shanks & Pottenger through 1992,
# from the IATA otherwise. As noted below, Shanks & Pottenger say that
# America/Cordoba split into 6 subregions during 1991/1992, but we
@@ -214,7 +312,7 @@ Zone America/Argentina/Buenos_Aires -3:53:48 - LMT 1894 Oct 31
-4:00 Arg AR%sT 1969 Oct 5
-3:00 Arg AR%sT 1999 Oct 3
-4:00 Arg AR%sT 2000 Mar 3
- -3:00 - ART
+ -3:00 Arg AR%sT
#
# Santa Fe (SF), Entre Rios (ER), Corrientes (CN), Misiones (MN), Chaco (CC),
# Formosa (FM), Salta (SA), Santiago del Estero (SE), Cordoba (CB),
@@ -237,7 +335,7 @@ Zone America/Argentina/Cordoba -4:16:48 - LMT 1894 Oct 31
-4:00 - WART 1991 Oct 20
-3:00 Arg AR%sT 1999 Oct 3
-4:00 Arg AR%sT 2000 Mar 3
- -3:00 - ART
+ -3:00 Arg AR%sT
#
# Tucuman (TM)
Zone America/Argentina/Tucuman -4:20:52 - LMT 1894 Oct 31
@@ -250,7 +348,7 @@ Zone America/Argentina/Tucuman -4:20:52 - LMT 1894 Oct 31
-4:00 Arg AR%sT 2000 Mar 3
-3:00 - ART 2004 Jun 1
-4:00 - WART 2004 Jun 13
- -3:00 - ART
+ -3:00 Arg AR%sT
#
# La Rioja (LR)
Zone America/Argentina/La_Rioja -4:27:24 - LMT 1894 Oct 31
@@ -263,7 +361,7 @@ Zone America/Argentina/La_Rioja -4:27:24 - LMT 1894 Oct 31
-4:00 Arg AR%sT 2000 Mar 3
-3:00 - ART 2004 Jun 1
-4:00 - WART 2004 Jun 20
- -3:00 - ART
+ -3:00 Arg AR%sT
#
# San Juan (SJ)
Zone America/Argentina/San_Juan -4:34:04 - LMT 1894 Oct 31
@@ -276,7 +374,7 @@ Zone America/Argentina/San_Juan -4:34:04 - LMT 1894 Oct 31
-4:00 Arg AR%sT 2000 Mar 3
-3:00 - ART 2004 May 31
-4:00 - WART 2004 Jul 25
- -3:00 - ART
+ -3:00 Arg AR%sT
#
# Jujuy (JY)
Zone America/Argentina/Jujuy -4:21:12 - LMT 1894 Oct 31
@@ -290,7 +388,7 @@ Zone America/Argentina/Jujuy -4:21:12 - LMT 1894 Oct 31
-3:00 1:00 ARST 1992
-3:00 Arg AR%sT 1999 Oct 3
-4:00 Arg AR%sT 2000 Mar 3
- -3:00 - ART
+ -3:00 Arg AR%sT
#
# Catamarca (CT), Chubut (CH)
Zone America/Argentina/Catamarca -4:23:08 - LMT 1894 Oct 31
@@ -303,7 +401,7 @@ Zone America/Argentina/Catamarca -4:23:08 - LMT 1894 Oct 31
-4:00 Arg AR%sT 2000 Mar 3
-3:00 - ART 2004 Jun 1
-4:00 - WART 2004 Jun 20
- -3:00 - ART
+ -3:00 Arg AR%sT
#
# Mendoza (MZ)
Zone America/Argentina/Mendoza -4:35:16 - LMT 1894 Oct 31
@@ -320,6 +418,20 @@ Zone America/Argentina/Mendoza -4:35:16 - LMT 1894 Oct 31
-4:00 Arg AR%sT 2000 Mar 3
-3:00 - ART 2004 May 23
-4:00 - WART 2004 Sep 26
+ -3:00 Arg AR%sT
+#
+# San Luis (SL)
+Zone America/Argentina/San_Luis -4:25:24 - LMT 1894 Oct 31
+ -4:16:48 - CMT 1920 May
+ -4:00 - ART 1930 Dec
+ -4:00 Arg AR%sT 1969 Oct 5
+ -3:00 Arg AR%sT 1991 Mar 1
+ -4:00 - WART 1991 May 7
+ -3:00 Arg AR%sT 1999 Oct 3
+ -4:00 Arg AR%sT 2000 Mar 3
+ -3:00 - ART 2004 May 31
+ -4:00 - WART 2004 Jul 25
+ -3:00 Arg AR%sT 2008 Jan 21
-3:00 - ART
#
# Santa Cruz (SC)
@@ -331,7 +443,7 @@ Zone America/Argentina/Rio_Gallegos -4:36:52 - LMT 1894 Oct 31
-4:00 Arg AR%sT 2000 Mar 3
-3:00 - ART 2004 Jun 1
-4:00 - WART 2004 Jun 20
- -3:00 - ART
+ -3:00 Arg AR%sT
#
# Tierra del Fuego, Antartida e Islas del Atlantico Sur (TF)
Zone America/Argentina/Ushuaia -4:33:12 - LMT 1894 Oct 31
@@ -342,7 +454,7 @@ Zone America/Argentina/Ushuaia -4:33:12 - LMT 1894 Oct 31
-4:00 Arg AR%sT 2000 Mar 3
-3:00 - ART 2004 May 30
-4:00 - WART 2004 Jun 20
- -3:00 - ART
+ -3:00 Arg AR%sT
# Aruba
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
@@ -731,6 +843,26 @@ Zone America/Rio_Branco -4:31:12 - LMT 1914
# America/Santiago. The pre-1980 Pacific/Easter data are dubious,
# but we have no other source.
+# From German Poo-Caaman~o (2008-03-03):
+# Due to drought, Chile extends Daylight Time in three weeks. This
+# is one-time change (Saturday 3/29 at 24:00 for America/Santiago
+# and Saturday 3/29 at 22:00 for Pacific/Easter)
+# The Supreme Decree is located at
+# <a href="http://www.shoa.cl/servicios/supremo316.pdf">
+# http://www.shoa.cl/servicios/supremo316.pdf
+# </a>
+# and the instructions for 2008 are located in:
+# <a href="http://www.horaoficial.cl/cambio.htm">
+# http://www.horaoficial.cl/cambio.htm
+# </a>.
+
+# From José Miguel Garrido (2008-03-05):
+# ...
+# You could see the announces of the change on
+# <a href="http://www.shoa.cl/noticias/2008/04hora/hora.htm">
+# http://www.shoa.cl/noticias/2008/04hora/hora.htm
+# </a>.
+
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule Chile 1927 1932 - Sep 1 0:00 1:00 S
Rule Chile 1928 1932 - Apr 1 0:00 0 -
@@ -761,7 +893,11 @@ Rule Chile 1998 only - Mar Sun>=9 3:00u 0 -
Rule Chile 1998 only - Sep 27 4:00u 1:00 S
Rule Chile 1999 only - Apr 4 3:00u 0 -
Rule Chile 1999 max - Oct Sun>=9 4:00u 1:00 S
-Rule Chile 2000 max - Mar Sun>=9 3:00u 0 -
+Rule Chile 2000 2007 - Mar Sun>=9 3:00u 0 -
+# N.B.: the end of March 29 in Chile is March 30 in Universal time,
+# which is used below in specifying the transition.
+Rule Chile 2008 only - Mar 30 3:00u 0 -
+Rule Chile 2009 max - Mar Sun>=9 3:00u 0 -
# IATA SSIM anomalies: (1992-02) says 1992-03-14;
# (1996-09) says 1998-03-08. Ignore these.
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
@@ -1107,19 +1243,17 @@ Zone America/Montevideo -3:44:44 - LMT 1898 Jun 28
# Venezuela
#
-# From Kiraz Janicke (2007-09-25), in
-# http://www.venezuelanalysis.com/analysis/2645:
-# The proposal ... involves turning the clock back half an hour from
-# +4.00 Greenwich Mean Time (GMT), to +4.30GMT, the time zone
-# Venezuela had until December 31, 1964, when the current time zone
-# was adopted. The change was due to take place on September 17 and
-# then on September 24, but has since been postponed until December
-# 31, to allow for compliance with international organizations, such
-# as the International Office of Weights and Measures.
+# From John Stainforth (2007-11-28):
+# ... the change for Venezuela originally expected for 2007-12-31 has
+# been brought forward to 2007-12-09. The official announcement was
+# published today in the "Gaceta Oficial de la Republica Bolivariana
+# de Venezuela, numero 38.819" (official document for all laws or
+# resolution publication)
+# http://www.globovision.com/news.php?nid=72208
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone America/Caracas -4:27:44 - LMT 1890
-4:27:40 - CMT 1912 Feb 12 # Caracas Mean Time?
-4:30 - VET 1965 # Venezuela Time
- -4:00 - VET 2008
+ -4:00 - VET 2007 Dec 9 03:00
-4:30 - VET
diff --git a/libc/timezone/zdump.c b/libc/timezone/zdump.c
index 6bf540aef..82c91e485 100644
--- a/libc/timezone/zdump.c
+++ b/libc/timezone/zdump.c
@@ -1,4 +1,4 @@
-static char elsieid[] = "@(#)zdump.c 8.4";
+static char elsieid[] = "@(#)zdump.c 8.6";
/*
** This code has been made independent of the rest of the time
@@ -88,6 +88,9 @@ static char elsieid[] = "@(#)zdump.c 8.4";
#define SECSPERNYEAR (SECSPERDAY * DAYSPERNYEAR)
#define SECSPERLYEAR (SECSPERNYEAR + SECSPERDAY)
+#ifndef HAVE_GETTEXT
+#define HAVE_GETTEXT 0
+#endif
#if HAVE_GETTEXT
#include "locale.h" /* for setlocale */
#include "libintl.h"
@@ -129,13 +132,9 @@ static char elsieid[] = "@(#)zdump.c 8.4";
#define TZ_DOMAIN "tz"
#endif /* !defined TZ_DOMAIN */
-#ifndef P
-#define P(x) x
-#endif /* !defined P */
-
extern char ** environ;
-extern int getopt P((int argc, char * const argv[],
- const char * options));
+extern int getopt(int argc, char * const argv[],
+ const char * options);
extern char * optarg;
extern int optind;
extern char * tzname[2];
@@ -146,15 +145,15 @@ static size_t longest;
static char * progname;
static int warned;
-static char * abbr P((struct tm * tmp));
-static void abbrok P((const char * abbrp, const char * zone));
-static long delta P((struct tm * newp, struct tm * oldp));
-static void dumptime P((const struct tm * tmp));
-static time_t hunt P((char * name, time_t lot, time_t hit));
-static void setabsolutes P((void));
-static void show P((char * zone, time_t t, int v));
-static const char * tformat P((void));
-static time_t yeartot P((long y));
+static char * abbr(struct tm * tmp);
+static void abbrok(const char * abbrp, const char * zone);
+static long delta(struct tm * newp, struct tm * oldp);
+static void dumptime(const struct tm * tmp);
+static time_t hunt(char * name, time_t lot, time_t hit);
+static void setabsolutes(void);
+static void show(char * zone, time_t t, int v);
+static const char * tformat(void);
+static time_t yeartot(long y);
#ifndef TYPECHECK
#define my_localtime localtime
@@ -394,7 +393,7 @@ _("%s: usage is %s [ --version ] [ -v ] [ -c [loyear,]hiyear ] zonename ...\n"),
}
static void
-setabsolutes()
+setabsolutes(void)
{
if (0.5 == (time_t) 0.5) {
/*
@@ -592,7 +591,7 @@ struct tm * tmp;
*/
static const char *
-tformat()
+tformat(void)
{
if (0.5 == (time_t) 0.5) { /* floating */
if (sizeof (time_t) > sizeof (double))
diff --git a/libc/timezone/zic.c b/libc/timezone/zic.c
index 3cb0b171f..5f8028e48 100644
--- a/libc/timezone/zic.c
+++ b/libc/timezone/zic.c
@@ -3,7 +3,7 @@
** 2006-07-17 by Arthur David Olson.
*/
-static char elsieid[] = "@(#)zic.c 8.14";
+static char elsieid[] = "@(#)zic.c 8.17";
#include "private.h"
#include "locale.h"
@@ -99,70 +99,66 @@ struct zone {
zic_t z_untiltime;
};
-extern int getopt P((int argc, char * const argv[],
- const char * options));
-extern int link P((const char * fromname, const char * toname));
+extern int getopt(int argc, char * const argv[],
+ const char * options);
+extern int link(const char * fromname, const char * toname);
extern char * optarg;
extern int optind;
-static void addtt P((zic_t starttime, int type));
-static int addtype P((long gmtoff, const char * abbr, int isdst,
- int ttisstd, int ttisgmt));
-static void leapadd P((zic_t t, int positive, int rolling, int count));
-static void adjleap P((void));
-static void associate P((void));
-static int ciequal P((const char * ap, const char * bp));
-static void convert P((long val, char * buf));
-static void convert64 P((zic_t val, char * buf));
-static void dolink P((const char * fromfield, const char * tofield));
-static void doabbr P((char * abbr, const char * format,
- const char * letters, int isdst, int doquotes));
-static void eat P((const char * name, int num));
-static void eats P((const char * name, int num,
- const char * rname, int rnum));
-static long eitol P((int i));
-static void error P((const char * message));
-static char ** getfields P((char * buf));
-static long gethms P((const char * string, const char * errstrng,
- int signable));
-static void infile P((const char * filename));
-static void inleap P((char ** fields, int nfields));
-static void inlink P((char ** fields, int nfields));
-static void inrule P((char ** fields, int nfields));
-static int inzcont P((char ** fields, int nfields));
-static int inzone P((char ** fields, int nfields));
-static int inzsub P((char ** fields, int nfields, int iscont));
-static int is32 P((zic_t x));
-static int itsabbr P((const char * abbr, const char * word));
-static int itsdir P((const char * name));
-static int lowerit P((int c));
-static char * memcheck P((char * tocheck));
-static int mkdirs P((char * filename));
-static void newabbr P((const char * abbr));
-static long oadd P((long t1, long t2));
-static void outzone P((const struct zone * zp, int ntzones));
-static void puttzcode P((long code, FILE * fp));
-static void puttzcode64 P((zic_t code, FILE * fp));
-static int rcomp P((const void * leftp, const void * rightp));
-static zic_t rpytime P((const struct rule * rp, int wantedy));
-static void rulesub P((struct rule * rp,
+static void addtt(zic_t starttime, int type);
+static int addtype(long gmtoff, const char * abbr, int isdst,
+ int ttisstd, int ttisgmt);
+static void leapadd(zic_t t, int positive, int rolling, int count);
+static void adjleap(void);
+static void associate(void);
+static int ciequal(const char * ap, const char * bp);
+static void convert(long val, char * buf);
+static void convert64(zic_t val, char * buf);
+static void dolink(const char * fromfield, const char * tofield);
+static void doabbr(char * abbr, const char * format,
+ const char * letters, int isdst, int doquotes);
+static void eat(const char * name, int num);
+static void eats(const char * name, int num,
+ const char * rname, int rnum);
+static long eitol(int i);
+static void error(const char * message);
+static char ** getfields(char * buf);
+static long gethms(const char * string, const char * errstrng,
+ int signable);
+static void infile(const char * filename);
+static void inleap(char ** fields, int nfields);
+static void inlink(char ** fields, int nfields);
+static void inrule(char ** fields, int nfields);
+static int inzcont(char ** fields, int nfields);
+static int inzone(char ** fields, int nfields);
+static int inzsub(char ** fields, int nfields, int iscont);
+static int is32(zic_t x);
+static int itsabbr(const char * abbr, const char * word);
+static int itsdir(const char * name);
+static int lowerit(int c);
+static char * memcheck(char * tocheck);
+static int mkdirs(char * filename);
+static void newabbr(const char * abbr);
+static long oadd(long t1, long t2);
+static void outzone(const struct zone * zp, int ntzones);
+static void puttzcode(long code, FILE * fp);
+static void puttzcode64(zic_t code, FILE * fp);
+static int rcomp(const void * leftp, const void * rightp);
+static zic_t rpytime(const struct rule * rp, int wantedy);
+static void rulesub(struct rule * rp,
const char * loyearp, const char * hiyearp,
const char * typep, const char * monthp,
- const char * dayp, const char * timep));
-static int stringoffset P((char * result, long offset));
-static int stringrule P((char * result, const struct rule * rp,
- long dstoff, long gmtoff));
-static void stringzone P((char * result,
- const struct zone * zp, int ntzones));
-static void setboundaries P((void));
-static zic_t tadd P((zic_t t1, long t2));
-static void usage P((void));
-static void writezone P((const char * name, const char * string));
-static int yearistype P((int year, const char * type));
-
-#if !HAVE_STRERROR
-static char * strerror P((int));
-#endif /* !HAVE_STRERROR */
+ const char * dayp, const char * timep);
+static int stringoffset(char * result, long offset);
+static int stringrule(char * result, const struct rule * rp,
+ long dstoff, long gmtoff);
+static void stringzone(char * result,
+ const struct zone * zp, int ntzones);
+static void setboundaries(void);
+static zic_t tadd(zic_t t1, long t2);
+static void usage(void);
+static void writezone(const char * name, const char * string);
+static int yearistype(int year, const char * type);
static int charcnt;
static int errors;
@@ -287,8 +283,8 @@ struct lookup {
const int l_value;
};
-static struct lookup const * byword P((const char * string,
- const struct lookup * lp));
+static struct lookup const * byword(const char * string,
+ const struct lookup * lp);
static struct lookup const line_codes[] = {
{ "Rule", LC_RULE },
@@ -405,19 +401,6 @@ char * const ptr;
** Error handling.
*/
-#if !HAVE_STRERROR
-static char *
-strerror(errnum)
-int errnum;
-{
- extern char * sys_errlist[];
- extern int sys_nerr;
-
- return (errnum > 0 && errnum <= sys_nerr) ?
- sys_errlist[errnum] : _("Unknown system error");
-}
-#endif /* !HAVE_STRERROR */
-
static void
eats(name, num, rname, rnum)
const char * const name;
@@ -471,7 +454,7 @@ const char * const string;
}
static void
-usage P((void))
+usage(void)
{
(void) fprintf(stderr, _("%s: usage is %s \
[ --version ] [ -v ] [ -l localtime ] [ -p posixrules ] \\\n\
@@ -699,7 +682,7 @@ warning(_("hard link failed, symbolic link used"));
#define TIME_T_BITS_IN_FILE 64
static void
-setboundaries P((void))
+setboundaries(void)
{
register int i;
@@ -741,7 +724,7 @@ const void * cp2;
}
static void
-associate P((void))
+associate(void)
{
register struct zone * zp;
register struct rule * rp;
@@ -2012,7 +1995,8 @@ const int zonecount;
}
for (i = 0; i < zonecount; ++i) {
zp = &zpfirst[i];
- updateminmax(zp->z_untilrule.r_loyear);
+ if (i < zonecount - 1)
+ updateminmax(zp->z_untilrule.r_loyear);
for (j = 0; j < zp->z_nrules; ++j) {
rp = &zp->z_rules[j];
if (rp->r_lowasnum)
@@ -2043,8 +2027,11 @@ wp = ecpyalloc(_("no POSIX environment variable for zone"));
else max_year = INT_MAX;
}
/*
- ** For the benefit of older systems, generate data through 2037.
+ ** For the benefit of older systems,
+ ** generate data from 1900 through 2037.
*/
+ if (min_year > 1900)
+ min_year = 1900;
if (max_year < 2037)
max_year = 2037;
for (i = 0; i < zonecount; ++i) {
@@ -2331,7 +2318,7 @@ int count;
}
static void
-adjleap P((void))
+adjleap(void)
{
register int i;
register long last = 0;
diff --git a/libc/timezone/zone.tab b/libc/timezone/zone.tab
index 8d4333ad9..1647036c0 100644
--- a/libc/timezone/zone.tab
+++ b/libc/timezone/zone.tab
@@ -1,4 +1,4 @@
-# @(#)zone.tab 8.11
+# @(#)zone.tab 8.16
#
# TZ zone descriptions
#
@@ -42,7 +42,8 @@ AQ -7824+10654 Antarctica/Vostok Vostok Station, S Magnetic Pole
AQ -6640+14001 Antarctica/DumontDUrville Dumont-d'Urville Station, Terre Adelie
AQ -690022+0393524 Antarctica/Syowa Syowa Station, E Ongul I
AR -3436-05827 America/Argentina/Buenos_Aires Buenos Aires (BA, CF)
-AR -3124-06411 America/Argentina/Cordoba most locations (CB, CC, CN, ER, FM, LP, MN, NQ, RN, SA, SE, SF, SL)
+AR -3124-06411 America/Argentina/Cordoba most locations (CB, CC, CN, ER, FM, LP, MN, NQ, RN, SA, SE, SF)
+AR -3319-06621 America/Argentina/San_Luis San Luis (SL)
AR -2411-06518 America/Argentina/Jujuy Jujuy (JY)
AR -2649-06513 America/Argentina/Tucuman Tucuman (TM)
AR -2828-06547 America/Argentina/Catamarca Catamarca (CT), Chubut (CH)
@@ -77,6 +78,7 @@ BG +4241+02319 Europe/Sofia
BH +2623+05035 Asia/Bahrain
BI -0323+02922 Africa/Bujumbura
BJ +0629+00237 Africa/Porto-Novo
+BL +1753-06251 America/St_Barthelemy
BM +3217-06446 Atlantic/Bermuda
BN +0456+11455 Asia/Brunei
BO -1630-06809 America/La_Paz
@@ -208,7 +210,7 @@ ID -0232+14042 Asia/Jayapura Irian Jaya & the Moluccas
IE +5320-00615 Europe/Dublin
IL +3146+03514 Asia/Jerusalem
IM +5409-00428 Europe/Isle_of_Man
-IN +2232+08822 Asia/Calcutta
+IN +2232+08822 Asia/Kolkata
IO -0720+07225 Indian/Chagos
IQ +3321+04425 Asia/Baghdad
IR +3540+05126 Asia/Tehran
@@ -250,6 +252,7 @@ MA +3339-00735 Africa/Casablanca
MC +4342+00723 Europe/Monaco
MD +4700+02850 Europe/Chisinau
ME +4226+01916 Europe/Podgorica
+MF +1804-06305 America/Marigot
MG -1855+04731 Indian/Antananarivo
MH +0709+17112 Pacific/Majuro most locations
MH +0905+16720 Pacific/Kwajalein Kwajalein
@@ -339,8 +342,7 @@ SE +5920+01803 Europe/Stockholm
SG +0117+10351 Asia/Singapore
SH -1555-00542 Atlantic/St_Helena
SI +4603+01431 Europe/Ljubljana
-SJ +7800+01600 Arctic/Longyearbyen Svalbard
-SJ +7059-00805 Atlantic/Jan_Mayen Jan Mayen
+SJ +7800+01600 Arctic/Longyearbyen
SK +4809+01707 Europe/Bratislava
SL +0830-01315 Africa/Freetown
SM +4355+01228 Europe/San_Marino
@@ -410,7 +412,7 @@ VC +1309-06114 America/St_Vincent
VE +1030-06656 America/Caracas
VG +1827-06437 America/Tortola
VI +1821-06456 America/St_Thomas
-VN +1045+10640 Asia/Saigon
+VN +1045+10640 Asia/Ho_Chi_Minh
VU -1740+16825 Pacific/Efate
WF -1318-17610 Pacific/Wallis
WS -1350-17144 Pacific/Apia
diff --git a/libc/version.h b/libc/version.h
index 9ac2ee7ad..4bb7ab359 100644
--- a/libc/version.h
+++ b/libc/version.h
@@ -1,4 +1,4 @@
/* This file just defines the current version number of libc. */
#define RELEASE "development"
-#define VERSION "2.7.90"
+#define VERSION "2.8.90"
diff --git a/libc/wcsmbs/wcsmbsload.c b/libc/wcsmbs/wcsmbsload.c
index 6531775ce..6061e4200 100644
--- a/libc/wcsmbs/wcsmbsload.c
+++ b/libc/wcsmbs/wcsmbsload.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998-2002,2004,2005 Free Software Foundation, Inc.
+/* Copyright (C) 1998-2002,2004,2005,2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
@@ -147,7 +147,7 @@ __wcsmbs_getfct (const char *to, const char *from, size_t *nstepsp)
#if __OPTION_EGLIBC_LOCALE_CODE
/* Some of the functions here must not be used while setlocale is called. */
-__libc_lock_define (extern, __libc_setlocale_lock attribute_hidden)
+__libc_rwlock_define (extern, __libc_setlocale_lock attribute_hidden)
/* Load conversion functions for the currently selected locale. */
void
@@ -155,7 +155,7 @@ internal_function
__wcsmbs_load_conv (struct locale_data *new_category)
{
/* Acquire the lock. */
- __libc_lock_lock (__libc_setlocale_lock);
+ __libc_rwlock_wrlock (__libc_setlocale_lock);
/* We should repeat the test since while we waited some other thread
might have run this function. */
@@ -213,7 +213,7 @@ __wcsmbs_load_conv (struct locale_data *new_category)
}
}
- __libc_lock_unlock (__libc_setlocale_lock);
+ __libc_rwlock_unlock (__libc_setlocale_lock);
}
#else
void
diff --git a/ports/ChangeLog.arm b/ports/ChangeLog.arm
index f23b2b92d..e40900185 100644
--- a/ports/ChangeLog.arm
+++ b/ports/ChangeLog.arm
@@ -1,3 +1,81 @@
+2008-08-19 Joseph Myers <joseph@codesourcery.com>
+
+ * data/c++-types-arm-linux-gnueabi.data: New.
+ * data/localplt-arm-linux-gnueabi.data: New.
+ * sysdeps/arm/bsd-_setjmp.S: Use HIDDEN_JUMPTARGET to call
+ __sigsetjmp.
+ * sysdeps/arm/bsd-setjmp.S: Likewise.
+ * sysdeps/arm/eabi/aeabi_localeconv.c: Use __localeconv.
+ * sysdeps/arm/eabi/find_exidx.c (__gnu_Unwind_Find_exidx): Use
+ __dl_iterate_phdr.
+ * sysdeps/arm/eabi/setjmp.S: Add hidden_def (__sigsetjmp).
+ * sysdeps/arm/memmove.S: Use HIDDEN_JUMPTARGET to call memcpy from
+ within libc.
+ * sysdeps/arm/setjmp.S: Add hidden_def (__sigsetjmp).
+ * sysdeps/unix/sysv/linux/arm/clone.S: Use HIDDEN_JUMPTARGET to
+ call _exit.
+ * sysdeps/unix/sysv/linux/arm/ioperm.c (init_iosys): Use __sysctl,
+ __readlink and fgets_unlocked.
+ (_ioperm): Use __open and __close.
+
+2008-07-18 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/arm/eabi/fgetexcptflg.c: New.
+ * sysdeps/arm/eabi/fsetexcptflg.c (__fesetexceptflag): Operate on
+ set exception flags, not on mask of enabled exceptions.
+
+2008-07-18 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/arm/eabi/feupdateenv.c: New.
+
+2008-07-18 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/arm/libm-test-ulps: Update.
+
+2008-06-01 Paul Brook <paul@codesourcery.com>
+ Zack Weinberg <zack@codesourcery.com>
+ Daniel Jacobowitz <dan@codesourcery.com>
+
+ * sysdeps/arm/nptl/pthread_spin_lock.S,
+ sysdeps/arm/nptl/pthread_spin_trylock.S: Delete.
+ * sysdeps/arm/nptl/pthread_spin_lock.c,
+ sysdeps/arm/nptl/pthread_spin_trylock.c: New files using
+ atomic_compare_and_exchange_val_acq to take spinlocks.
+ * sysdeps/unix/sysv/linux/arm/nptl/bits/atomic.h (lll_trylock,
+ lll_cond_trylock): Use atomic_compare_and_exchange_val_acq.
+ (__lll_trylock, __lll_cond_trylock): Delete.
+ * sysdeps/unix/sysv/linux/arm/nptl/bits/atomic.h
+ (atomic_exchange_acq): Delete.
+ (atomic_full_barrier): Define.
+ (__arch_compare_and_exchange_val_32_acq): Use named operands.
+ * sysdeps/unix/sysv/linux/arm/eabi/configure.in: Update
+ arch_minimum_kernel to 2.6.16.
+ * sysdeps/unix/sysv/linux/arm/eabi/configure: Regenerated.
+
+2008-04-21 Daniel Jacobowitz <dan@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/arm/check_pf.c: Update from generic
+ version.
+
+2008-04-21 Khem Raj <kraj@mvista.com>
+
+ * sysdeps/unix/sysv/linux/arm/ioperm.c: Don't include asm/page.h.
+
+2008-04-21 Mike Frysinger <vapier@gentoo.org>
+
+ * sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h (DOCARGS_6,
+ UNDOCARGS_6): Define.
+
+2008-04-21 Khem Raj <kraj@mvista.com>
+
+ * sysdeps/unix/sysv/linux/arm/bits/shm.h: New file.
+
+2008-04-11 Paul Brook <paul@codesourcery.com>
+ Sandra Loosemore <sandra@codesourcery.com>
+
+ * sysdeps/arm/eabi/machine-gmon.h: New file.
+ * sysdeps/arm/eabi/Versions: Add __gnu_mcount_nc.
+
2007-12-21 Daniel Jacobowitz <dan@codesourcery.com>
* sysdeps/unix/sysv/linux/arm/profil-counter.h: Use the i386 version.
diff --git a/ports/ChangeLog.eglibc b/ports/ChangeLog.eglibc
index 41b44ee28..5e01eda23 100644
--- a/ports/ChangeLog.eglibc
+++ b/ports/ChangeLog.eglibc
@@ -1,3 +1,110 @@
+2008-08-08 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/m68k/bits/byteswap.h: Allow inclusion from <endian.h>.
+ (__bswap_constant_16): Define.
+ (__bswap_16): Allow arguments with side effects.
+ (__bswap_constant_32): Ensure result is unsigned.
+ (__bswap_32): Define as inline function in fallback case.
+ (__bswap_constant_64): Define.
+ (__bswap_64): Use it for constant arguments.
+ * sysdeps/m68k/bits/setjmp.h (__jmp_buf): Give name to structure
+ type.
+ * sysdeps/m68k/m680x0/fpu/bits/mathinline.h: Only allow inclusion
+ from <math.h>. Do not use extern inline directly.
+ * sysdeps/unix/sysv/linux/m68k/bits/fcntl.h: Include <bits/uio.h>.
+ (O_CLOEXEC, SYNC_FILE_RANGE_WAIT_BEFORE, SYNC_FILE_RANGE_WRITE,
+ SYNC_FILE_RANGE_WAIT_AFTER, SPLICE_F_MOVE, SPLICE_F_NONBLOCK,
+ SPLICE_F_MORE, SPLICE_F_GIFT): Define.
+ (sync_file_range, vmsplice, splice, tee): Declare.
+ * sysdeps/unix/sysv/linux/m68k/bits/mman.h (MADV_REMOVE): Define.
+ * sysdeps/unix/sysv/linux/m68k/bits/poll.h (POLLMSG, POLLREMOVE,
+ POLLRDHUP): Define.
+ * sysdeps/unix/sysv/linux/m68k/bits/stat.h (UTIME_NOW,
+ UTIME_OMIT): Define.
+ * sysdeps/unix/sysv/linux/m68k/kernel-features.h: New.
+ * sysdeps/unix/sysv/linux/m68k/sys/user.h: New.
+
+2008-07-22 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/mips/fpu_control.h (_FPU_GETCW, _FPU_SETCW): Make asms
+ volatile.
+
+2008-07-16 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/mips/bits/setjmp.h (__jmp_buf): Give name to structure
+ type.
+
+2008-07-09 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/shlib-versions:
+ New.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/single/shlib-versions:
+ New.
+ * c++-types-powerpce500v1-linux-gnu.data: New.
+ * c++-types-powerpce500v2-linux-gnu.data: New.
+ * localplt-powerpce500v1-linux-gnu.data: New.
+ * localplt-powerpce500v2-linux-gnu.data: New.
+ * sysdeps/powerpc/powerpc32/e500/fpu/spe.h: New.
+ * sysdeps/powerpc/powerpc32/e500/fpu/strtofix.c: Include <spe.h>.
+ Use libc_hidden_def for STRTOFIX.
+ * sysdeps/powerpc/powerpc32/e500/soft-fp/sfp-machine.h: Declare
+ __feraiseexcept_soft and use libc_hidden_proto.
+ * sysdeps/powerpc/powerpc32/e500/soft-fp/fraiseexcept-soft.c:
+ Declare __feraiseexcept_soft. Use libc_hidden_proto and
+ libc_hidden_def.
+
+2008-07-08 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/powerpc/nofpu/shlib-versions: New.
+ * c++-types-powerpcsoft-linux-gnu.data: New.
+ * localplt-powerpcsoft-linux-gnu.data: New.
+ * sysdeps/powerpc/nofpu/feholdexcpt.c (feholdexcept): Use
+ __fegetenv.
+
+2008-07-08 Joseph Myers <joseph@codesourcery.com>
+
+ * c++-types-arm-linux-gnueabi.data: New.
+ * localplt-arm-linux-gnueabi.data: New.
+ * sysdeps/arm/bsd-_setjmp.S: Use HIDDEN_JUMPTARGET to call
+ __sigsetjmp.
+ * sysdeps/arm/bsd-setjmp.S: Likewise.
+ * sysdeps/arm/eabi/aeabi_localeconv.c: Use __localeconv.
+ * sysdeps/arm/eabi/find_exidx.c (__gnu_Unwind_Find_exidx): Use
+ __dl_iterate_phdr.
+ * sysdeps/arm/eabi/setjmp.S: Add hidden_def (__sigsetjmp).
+ * sysdeps/arm/memmove.S: Use HIDDEN_JUMPTARGET to call memcpy from
+ within libc.
+ * sysdeps/arm/setjmp.S: Add hidden_def (__sigsetjmp).
+ * sysdeps/unix/sysv/linux/arm/clone.S: Use HIDDEN_JUMPTARGET to
+ call _exit.
+ * sysdeps/unix/sysv/linux/arm/ioperm.c (init_iosys): Use __sysctl,
+ __readlink and fgets_unlocked.
+ (_ioperm): Use __open and __close.
+
+2008-06-30 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/arm/eabi/fgetexcptflg.c: New.
+ * sysdeps/arm/eabi/fsetexcptflg.c (__fesetexceptflag): Operate on
+ set exception flags, not on mask of enabled exceptions.
+
+2008-06-17 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/arm/eabi/feupdateenv.c: New.
+
+2008-06-17 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/arm/libm-test-ulps: Update.
+
+2008-04-11 Paul Brook <paul@codesourcery.com>
+ Sandra Loosemore <sandra@codesourcery.com>
+
+ * sysdeps/arm/eabi/machine-gmon.h (_mcount): Make the thumb2
+ version compile without error.
+
+2008-04-11 Paul Brook <paul@codesourcery.com>
+
+ * sysdeps/arm/eabi/Versions: Add __gnu_mcount_nc.
+
2008-04-02 Paul Brook <paul@codesourcery.com>
* sysdeps/arm/eabi/machine-gmon.h: New file.
diff --git a/ports/ChangeLog.hppa b/ports/ChangeLog.hppa
index abe017e92..3d570dba9 100644
--- a/ports/ChangeLog.hppa
+++ b/ports/ChangeLog.hppa
@@ -1,3 +1,44 @@
+2008-08-07 Helge Deller <deller@gmx.de>
+
+ * sysdeps/unix/sysv/linux/hppa/ucontext_i.sym: New file.
+ * sysdeps/unix/sysv/linux/hppa/Makefile: New file.
+ * sysdeps/unix/sysv/linux/hppa/getcontext.S: New file.
+ * sysdeps/unix/sysv/linux/hppa/makecontext.c: New file.
+ * sysdeps/unix/sysv/linux/hppa/setcontext.S: New file.
+ * sysdeps/unix/sysv/linux/hppa/swapcontext.c: New file.
+
+2008-06-17 Aurelian Jarno <aurelien@aurel32.net>
+ Carlos O'Donell <carlos@systemhalted.org>
+
+ [BZ #6037]
+ * sysdeps/unix/sysv/linux/hppa/bits/atomic.h: Check for -11
+ (-EAGAIN) instead of 11. Loop again when the kernel
+ returns -45 (-EDEADLOCK). Add back memory clobber.
+ Do not initialize lws_ret and lws_errno.
+
+2008-06-17 Guy Martin <gmsoft@tuxicoman.be>
+
+ [BZ #5957]
+ * sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h:
+ Use shared futex in lll_wait_tid().
+
+2008-05-12 Aurelien Jarno <aurelien@aurel32.net>
+
+ [BZ #6506]
+ * sysdeps/hppa/fpu/fesetenv.c: bufptr is always read, temp is
+ read while writing back status word.
+
+2008-04-21 Daniel Jacobowitz <dan@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/hppa/bits/shm.h: Fix comment describing
+ shmid_ds.
+
+2008-04-04 Carlos O'Donell <carlos@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/hppa/bits/atomic.h: Remove
+ memory contraint and instead indicate that *mem is
+ written to.
+
2008-03-24 Carlos O'Donell <carlos@codesourcery.com>
* sysdeps/unix/sysv/linux/hppa/sys/user.h: New file.
diff --git a/ports/ChangeLog.m68k b/ports/ChangeLog.m68k
index b6aa316ad..c399a4868 100644
--- a/ports/ChangeLog.m68k
+++ b/ports/ChangeLog.m68k
@@ -1,3 +1,29 @@
+2008-08-10 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/m68k/bits/byteswap.h: Allow inclusion from <endian.h>.
+ (__bswap_constant_16): Define.
+ (__bswap_16): Allow arguments with side effects.
+ (__bswap_constant_32): Ensure result is unsigned.
+ (__bswap_32): Define as inline function in fallback case.
+ (__bswap_constant_64): Define.
+ (__bswap_64): Use it for constant arguments.
+ * sysdeps/m68k/bits/setjmp.h (__jmp_buf): Give name to structure
+ type.
+ * sysdeps/m68k/m680x0/fpu/bits/mathinline.h: Only allow inclusion
+ from <math.h>. Do not use extern inline directly.
+ * sysdeps/unix/sysv/linux/m68k/bits/fcntl.h: Include <bits/uio.h>.
+ (O_CLOEXEC, SYNC_FILE_RANGE_WAIT_BEFORE, SYNC_FILE_RANGE_WRITE,
+ SYNC_FILE_RANGE_WAIT_AFTER, SPLICE_F_MOVE, SPLICE_F_NONBLOCK,
+ SPLICE_F_MORE, SPLICE_F_GIFT): Define.
+ (sync_file_range, vmsplice, splice, tee): Declare.
+ * sysdeps/unix/sysv/linux/m68k/bits/mman.h (MADV_REMOVE): Define.
+ * sysdeps/unix/sysv/linux/m68k/bits/poll.h (POLLMSG, POLLREMOVE,
+ POLLRDHUP): Define.
+ * sysdeps/unix/sysv/linux/m68k/bits/stat.h (UTIME_NOW,
+ UTIME_OMIT): Define.
+ * sysdeps/unix/sysv/linux/m68k/kernel-features.h: New.
+ * sysdeps/unix/sysv/linux/m68k/sys/user.h: New.
+
2008-03-28 Maxim Kuvyrkov <maxim@codesourcery.com>
Explicitly get address of _DYNAMIC.
diff --git a/ports/ChangeLog.mips b/ports/ChangeLog.mips
index a7a219e49..065ac681a 100644
--- a/ports/ChangeLog.mips
+++ b/ports/ChangeLog.mips
@@ -1,3 +1,55 @@
+2008-08-19 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/mips/sys/epoll.h: Change epoll_create2
+ to epoll_create1.
+
+2008-08-19 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/mips/bits/socket.h: Define SOCK_CLOEXEC,
+ SOCK_NONBLOCK, PF_ISDN and AF_ISDN.
+ * sysdeps/unix/sysv/linux/mips/sys/epoll.h: New file.
+ * sysdeps/unix/sysv/linux/mips/sys/eventfd.h: New file.
+ * sysdeps/unix/sysv/linux/mips/sys/inotify.h: New file.
+ * sysdeps/unix/sysv/linux/mips/sys/signalfd.h: New file.
+ * sysdeps/unix/sysv/linux/mips/sys/timerfd.h: New file.
+
+2008-08-19 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/mips/fpu_control.h (_FPU_GETCW, _FPU_SETCW): Make asms
+ volatile.
+
+2008-07-18 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/mips/bits/setjmp.h (__jmp_buf): Give name to structure
+ type.
+
+2008-05-21 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/mips/bits/socket.h: Cleanup namespace.
+ (SOCK_DCCP): Define.
+
+2008-05-01 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/mips/bits/resource.h: Define
+ RUSAGE_THREAD and RUSAGE_LWP.
+
+2008-04-21 Daniel Jacobowitz <dan@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/mips/bits/shm.h: Fix comment describing
+ shmid_ds.
+
+2008-04-21 Khem Raj <kraj@mvista.com>
+
+ * sysdeps/unix/sysv/linux/mips/xmknod.c: Delete file.
+
+2008-04-02 Aurelien Jarno <aurelien@aurel32.net>
+
+ * sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list: Add
+ truncate and ftruncate systems calls.
+ * sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c: Make an
+ empty file.
+ * sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c: Ditto.
+
2008-03-28 Joseph Myers <joseph@codesourcery.com>
* sysdeps/unix/sysv/linux/mips/nptl/bits/local_lim.h: Undefine
diff --git a/ports/ChangeLog.powerpc b/ports/ChangeLog.powerpc
index 463dd291a..136f97a2a 100644
--- a/ports/ChangeLog.powerpc
+++ b/ports/ChangeLog.powerpc
@@ -1,3 +1,11 @@
+2008-08-19 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/powerpc/nofpu/shlib-versions: New.
+ * c++-types-powerpcsoft-linux-gnu.data: New.
+ * localplt-powerpcsoft-linux-gnu.data: New.
+ * sysdeps/powerpc/nofpu/feholdexcpt.c (feholdexcept): Use
+ __fegetenv.
+
2007-08-29 Daniel Jacobowitz <dan@codesourcery.com>
* sysdeps/powerpc/nofpu/fsetexcptflg.c (__fesetexceptflag): Do not
diff --git a/ports/data/c++-types-arm-linux-gnueabi.data b/ports/data/c++-types-arm-linux-gnueabi.data
new file mode 100644
index 000000000..fde53bf33
--- /dev/null
+++ b/ports/data/c++-types-arm-linux-gnueabi.data
@@ -0,0 +1,67 @@
+blkcnt64_t:x
+blkcnt_t:l
+blksize_t:l
+caddr_t:Pc
+clockid_t:i
+clock_t:l
+daddr_t:i
+dev_t:y
+fd_mask:l
+fsblkcnt64_t:y
+fsblkcnt_t:m
+fsfilcnt64_t:y
+fsfilcnt_t:m
+fsid_t:8__fsid_t
+gid_t:j
+id_t:j
+ino64_t:y
+ino_t:m
+int16_t:s
+int32_t:i
+int64_t:x
+int8_t:a
+intptr_t:i
+key_t:i
+loff_t:x
+mode_t:j
+nlink_t:j
+off64_t:x
+off_t:l
+pid_t:i
+pthread_attr_t:14pthread_attr_t
+pthread_barrier_t:17pthread_barrier_t
+pthread_barrierattr_t:21pthread_barrierattr_t
+pthread_cond_t:14pthread_cond_t
+pthread_condattr_t:18pthread_condattr_t
+pthread_key_t:j
+pthread_mutex_t:15pthread_mutex_t
+pthread_mutexattr_t:19pthread_mutexattr_t
+pthread_once_t:i
+pthread_rwlock_t:16pthread_rwlock_t
+pthread_rwlockattr_t:20pthread_rwlockattr_t
+pthread_spinlock_t:i
+pthread_t:m
+quad_t:x
+register_t:i
+rlim64_t:y
+rlim_t:m
+sigset_t:10__sigset_t
+size_t:j
+socklen_t:j
+ssize_t:i
+suseconds_t:l
+time_t:l
+u_char:h
+uid_t:j
+uint:j
+u_int:j
+u_int16_t:t
+u_int32_t:j
+u_int64_t:y
+u_int8_t:h
+ulong:m
+u_long:m
+u_quad_t:y
+useconds_t:j
+ushort:t
+u_short:t
diff --git a/ports/data/c++-types-powerpce500v1-linux-gnu.data b/ports/data/c++-types-powerpce500v1-linux-gnu.data
new file mode 100644
index 000000000..fde53bf33
--- /dev/null
+++ b/ports/data/c++-types-powerpce500v1-linux-gnu.data
@@ -0,0 +1,67 @@
+blkcnt64_t:x
+blkcnt_t:l
+blksize_t:l
+caddr_t:Pc
+clockid_t:i
+clock_t:l
+daddr_t:i
+dev_t:y
+fd_mask:l
+fsblkcnt64_t:y
+fsblkcnt_t:m
+fsfilcnt64_t:y
+fsfilcnt_t:m
+fsid_t:8__fsid_t
+gid_t:j
+id_t:j
+ino64_t:y
+ino_t:m
+int16_t:s
+int32_t:i
+int64_t:x
+int8_t:a
+intptr_t:i
+key_t:i
+loff_t:x
+mode_t:j
+nlink_t:j
+off64_t:x
+off_t:l
+pid_t:i
+pthread_attr_t:14pthread_attr_t
+pthread_barrier_t:17pthread_barrier_t
+pthread_barrierattr_t:21pthread_barrierattr_t
+pthread_cond_t:14pthread_cond_t
+pthread_condattr_t:18pthread_condattr_t
+pthread_key_t:j
+pthread_mutex_t:15pthread_mutex_t
+pthread_mutexattr_t:19pthread_mutexattr_t
+pthread_once_t:i
+pthread_rwlock_t:16pthread_rwlock_t
+pthread_rwlockattr_t:20pthread_rwlockattr_t
+pthread_spinlock_t:i
+pthread_t:m
+quad_t:x
+register_t:i
+rlim64_t:y
+rlim_t:m
+sigset_t:10__sigset_t
+size_t:j
+socklen_t:j
+ssize_t:i
+suseconds_t:l
+time_t:l
+u_char:h
+uid_t:j
+uint:j
+u_int:j
+u_int16_t:t
+u_int32_t:j
+u_int64_t:y
+u_int8_t:h
+ulong:m
+u_long:m
+u_quad_t:y
+useconds_t:j
+ushort:t
+u_short:t
diff --git a/ports/data/c++-types-powerpce500v2-linux-gnu.data b/ports/data/c++-types-powerpce500v2-linux-gnu.data
new file mode 100644
index 000000000..fde53bf33
--- /dev/null
+++ b/ports/data/c++-types-powerpce500v2-linux-gnu.data
@@ -0,0 +1,67 @@
+blkcnt64_t:x
+blkcnt_t:l
+blksize_t:l
+caddr_t:Pc
+clockid_t:i
+clock_t:l
+daddr_t:i
+dev_t:y
+fd_mask:l
+fsblkcnt64_t:y
+fsblkcnt_t:m
+fsfilcnt64_t:y
+fsfilcnt_t:m
+fsid_t:8__fsid_t
+gid_t:j
+id_t:j
+ino64_t:y
+ino_t:m
+int16_t:s
+int32_t:i
+int64_t:x
+int8_t:a
+intptr_t:i
+key_t:i
+loff_t:x
+mode_t:j
+nlink_t:j
+off64_t:x
+off_t:l
+pid_t:i
+pthread_attr_t:14pthread_attr_t
+pthread_barrier_t:17pthread_barrier_t
+pthread_barrierattr_t:21pthread_barrierattr_t
+pthread_cond_t:14pthread_cond_t
+pthread_condattr_t:18pthread_condattr_t
+pthread_key_t:j
+pthread_mutex_t:15pthread_mutex_t
+pthread_mutexattr_t:19pthread_mutexattr_t
+pthread_once_t:i
+pthread_rwlock_t:16pthread_rwlock_t
+pthread_rwlockattr_t:20pthread_rwlockattr_t
+pthread_spinlock_t:i
+pthread_t:m
+quad_t:x
+register_t:i
+rlim64_t:y
+rlim_t:m
+sigset_t:10__sigset_t
+size_t:j
+socklen_t:j
+ssize_t:i
+suseconds_t:l
+time_t:l
+u_char:h
+uid_t:j
+uint:j
+u_int:j
+u_int16_t:t
+u_int32_t:j
+u_int64_t:y
+u_int8_t:h
+ulong:m
+u_long:m
+u_quad_t:y
+useconds_t:j
+ushort:t
+u_short:t
diff --git a/ports/data/c++-types-powerpcsoft-linux-gnu.data b/ports/data/c++-types-powerpcsoft-linux-gnu.data
new file mode 100644
index 000000000..fde53bf33
--- /dev/null
+++ b/ports/data/c++-types-powerpcsoft-linux-gnu.data
@@ -0,0 +1,67 @@
+blkcnt64_t:x
+blkcnt_t:l
+blksize_t:l
+caddr_t:Pc
+clockid_t:i
+clock_t:l
+daddr_t:i
+dev_t:y
+fd_mask:l
+fsblkcnt64_t:y
+fsblkcnt_t:m
+fsfilcnt64_t:y
+fsfilcnt_t:m
+fsid_t:8__fsid_t
+gid_t:j
+id_t:j
+ino64_t:y
+ino_t:m
+int16_t:s
+int32_t:i
+int64_t:x
+int8_t:a
+intptr_t:i
+key_t:i
+loff_t:x
+mode_t:j
+nlink_t:j
+off64_t:x
+off_t:l
+pid_t:i
+pthread_attr_t:14pthread_attr_t
+pthread_barrier_t:17pthread_barrier_t
+pthread_barrierattr_t:21pthread_barrierattr_t
+pthread_cond_t:14pthread_cond_t
+pthread_condattr_t:18pthread_condattr_t
+pthread_key_t:j
+pthread_mutex_t:15pthread_mutex_t
+pthread_mutexattr_t:19pthread_mutexattr_t
+pthread_once_t:i
+pthread_rwlock_t:16pthread_rwlock_t
+pthread_rwlockattr_t:20pthread_rwlockattr_t
+pthread_spinlock_t:i
+pthread_t:m
+quad_t:x
+register_t:i
+rlim64_t:y
+rlim_t:m
+sigset_t:10__sigset_t
+size_t:j
+socklen_t:j
+ssize_t:i
+suseconds_t:l
+time_t:l
+u_char:h
+uid_t:j
+uint:j
+u_int:j
+u_int16_t:t
+u_int32_t:j
+u_int64_t:y
+u_int8_t:h
+ulong:m
+u_long:m
+u_quad_t:y
+useconds_t:j
+ushort:t
+u_short:t
diff --git a/ports/data/localplt-arm-linux-gnueabi.data b/ports/data/localplt-arm-linux-gnueabi.data
new file mode 100644
index 000000000..109522e37
--- /dev/null
+++ b/ports/data/localplt-arm-linux-gnueabi.data
@@ -0,0 +1,13 @@
+libc.so: __signbit
+libc.so: calloc
+libc.so: free
+libc.so: fscanf
+libc.so: malloc
+libc.so: memalign
+libc.so: raise
+libc.so: realloc
+libm.so: __signbit
+libm.so: __signbitf
+libm.so: matherr
+libpthread.so: __errno_location
+libpthread.so: raise
diff --git a/ports/data/localplt-powerpce500v1-linux-gnu.data b/ports/data/localplt-powerpce500v1-linux-gnu.data
new file mode 100644
index 000000000..f38522386
--- /dev/null
+++ b/ports/data/localplt-powerpce500v1-linux-gnu.data
@@ -0,0 +1,31 @@
+libc.so: __adddf3
+libc.so: __divdf3
+libc.so: __eqdf2
+libc.so: __extendsfdf2
+libc.so: __fixdfsi
+libc.so: __fixunsdfsi
+libc.so: __floatsidf
+libc.so: __floatunsidf
+libc.so: __gedf2
+libc.so: __gtdf2
+libc.so: __ledf2
+libc.so: __ltdf2
+libc.so: __muldf3
+libc.so: __nedf2
+libc.so: __signbit
+libc.so: __signbitl
+libc.so: __subdf3
+libc.so: __truncdfsf2
+libc.so: __unorddf2
+libc.so: abort
+libc.so: calloc
+libc.so: free
+libc.so: malloc
+libc.so: memalign
+libc.so: realloc
+libm.so: __signbit
+libm.so: __signbitf
+libm.so: __signbitl
+libm.so: copysignl
+libm.so: fegetround
+libm.so: matherr
diff --git a/ports/data/localplt-powerpce500v2-linux-gnu.data b/ports/data/localplt-powerpce500v2-linux-gnu.data
new file mode 100644
index 000000000..3c64ec9d9
--- /dev/null
+++ b/ports/data/localplt-powerpce500v2-linux-gnu.data
@@ -0,0 +1,13 @@
+libc.so: __signbit
+libc.so: __signbitl
+libc.so: abort
+libc.so: calloc
+libc.so: free
+libc.so: malloc
+libc.so: memalign
+libc.so: realloc
+libm.so: __signbit
+libm.so: __signbitf
+libm.so: __signbitl
+libm.so: fegetround
+libm.so: matherr
diff --git a/ports/data/localplt-powerpcsoft-linux-gnu.data b/ports/data/localplt-powerpcsoft-linux-gnu.data
new file mode 100644
index 000000000..65fa5dac9
--- /dev/null
+++ b/ports/data/localplt-powerpcsoft-linux-gnu.data
@@ -0,0 +1,41 @@
+libc.so: _Unwind_Find_FDE
+libc.so: __adddf3
+libc.so: __addsf3
+libc.so: __divdf3
+libc.so: __divsf3
+libc.so: __eqdf2
+libc.so: __eqsf2
+libc.so: __extendsfdf2
+libc.so: __fixdfsi
+libc.so: __fixsfsi
+libc.so: __fixunsdfsi
+libc.so: __floatsidf
+libc.so: __floatsisf
+libc.so: __floatunsidf
+libc.so: __floatunsisf
+libc.so: __gedf2
+libc.so: __gtdf2
+libc.so: __ledf2
+libc.so: __ltdf2
+libc.so: __muldf3
+libc.so: __mulsf3
+libc.so: __nedf2
+libc.so: __signbit
+libc.so: __signbitl
+libc.so: __subdf3
+libc.so: __subsf3
+libc.so: __truncdfsf2
+libc.so: __unorddf2
+libc.so: abort
+libc.so: calloc
+libc.so: free
+libc.so: malloc
+libc.so: memalign
+libc.so: realloc
+libm.so: __signbit
+libm.so: __signbitf
+libm.so: __signbitl
+libm.so: copysignl
+libm.so: fabsl
+libm.so: fegetround
+libm.so: matherr
diff --git a/ports/sysdeps/arm/bsd-_setjmp.S b/ports/sysdeps/arm/bsd-_setjmp.S
index c4a094e50..c3a438327 100644
--- a/ports/sysdeps/arm/bsd-_setjmp.S
+++ b/ports/sysdeps/arm/bsd-_setjmp.S
@@ -1,5 +1,5 @@
/* BSD `_setjmp' entry point to `sigsetjmp (..., 0)'. ARM version.
- Copyright (C) 1997, 1998, 2002 Free Software Foundation, Inc.
+ Copyright (C) 1997, 1998, 2002, 2008 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
@@ -25,6 +25,6 @@
ENTRY (_setjmp)
mov r1, #0
- b PLTJMP(C_SYMBOL_NAME(__sigsetjmp))
+ b PLTJMP(HIDDEN_JUMPTARGET(__sigsetjmp))
END (_setjmp)
libc_hidden_def (_setjmp)
diff --git a/ports/sysdeps/arm/bsd-setjmp.S b/ports/sysdeps/arm/bsd-setjmp.S
index d227ba68a..36c571c5e 100644
--- a/ports/sysdeps/arm/bsd-setjmp.S
+++ b/ports/sysdeps/arm/bsd-setjmp.S
@@ -1,5 +1,5 @@
/* BSD `setjmp' entry point to `sigsetjmp (..., 1)'. ARM version.
- Copyright (C) 1997, 1998 Free Software Foundation, Inc.
+ Copyright (C) 1997, 1998, 2008 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
@@ -25,5 +25,5 @@
ENTRY (setjmp)
mov r1, #1
- b PLTJMP(C_SYMBOL_NAME(__sigsetjmp))
+ b PLTJMP(HIDDEN_JUMPTARGET(__sigsetjmp))
END (setjmp)
diff --git a/ports/sysdeps/arm/eabi/Versions b/ports/sysdeps/arm/eabi/Versions
index ca51099cd..5f2af29c3 100644
--- a/ports/sysdeps/arm/eabi/Versions
+++ b/ports/sysdeps/arm/eabi/Versions
@@ -14,4 +14,7 @@ libc {
# Helper routines
__gnu_Unwind_Find_exidx;
}
+ GLIBC_2.8 {
+ __gnu_mcount_nc;
+ }
}
diff --git a/ports/sysdeps/arm/eabi/aeabi_localeconv.c b/ports/sysdeps/arm/eabi/aeabi_localeconv.c
index f4e51d02e..323148e0f 100644
--- a/ports/sysdeps/arm/eabi/aeabi_localeconv.c
+++ b/ports/sysdeps/arm/eabi/aeabi_localeconv.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2004, 2005 Free Software Foundation, Inc.
+/* Copyright (C) 2004, 2005, 2008 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
@@ -21,5 +21,5 @@
struct lconv *
__aeabi_localeconv (void)
{
- return localeconv ();
+ return __localeconv ();
}
diff --git a/ports/sysdeps/arm/eabi/feupdateenv.c b/ports/sysdeps/arm/eabi/feupdateenv.c
new file mode 100644
index 000000000..9769867ab
--- /dev/null
+++ b/ports/sysdeps/arm/eabi/feupdateenv.c
@@ -0,0 +1,59 @@
+/* Install given floating-point environment and raise exceptions.
+ Copyright (C) 1997, 1999, 2000, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <fenv.h>
+#include <fpu_control.h>
+
+#include <unistd.h>
+#include <ldsodefs.h>
+#include <dl-procinfo.h>
+#include <sysdep.h>
+
+int
+__feupdateenv (const fenv_t *envp)
+{
+ if (GLRO (dl_hwcap) & HWCAP_ARM_VFP)
+ {
+ unsigned int temp;
+
+ /* Get the current exception state. */
+ _FPU_GETCW (temp);
+
+ /* Install new environment. */
+ fesetenv (envp);
+
+ /* Raise the saved exceptions. */
+ feraiseexcept (temp & FE_ALL_EXCEPT);
+
+ /* Success. */
+ return 0;
+ }
+
+ /* Unsupported, so fail. */
+ return 1;
+}
+
+#include <shlib-compat.h>
+#if SHLIB_COMPAT (libm, GLIBC_2_1, GLIBC_2_2)
+strong_alias (__feupdateenv, __old_feupdateenv)
+compat_symbol (libm, __old_feupdateenv, feupdateenv, GLIBC_2_1);
+#endif
+
+versioned_symbol (libm, __feupdateenv, feupdateenv, GLIBC_2_2);
diff --git a/ports/sysdeps/arm/eabi/fgetexcptflg.c b/ports/sysdeps/arm/eabi/fgetexcptflg.c
new file mode 100644
index 000000000..2259fa37a
--- /dev/null
+++ b/ports/sysdeps/arm/eabi/fgetexcptflg.c
@@ -0,0 +1,54 @@
+/* Store current representation for exceptions.
+ Copyright (C) 1997, 1999, 2000, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <fenv.h>
+#include <fpu_control.h>
+
+#include <unistd.h>
+#include <ldsodefs.h>
+#include <dl-procinfo.h>
+#include <sysdep.h>
+
+int
+__fegetexceptflag (fexcept_t *flagp, int excepts)
+{
+ if (GLRO (dl_hwcap) & HWCAP_ARM_VFP)
+ {
+ unsigned long temp;
+
+ /* Get the current exceptions. */
+ _FPU_GETCW (temp);
+
+ *flagp = temp & excepts & FE_ALL_EXCEPT;
+
+ /* Success. */
+ return 0;
+ }
+
+ /* Unsupported, so fail. */
+ return 1;
+}
+
+#include <shlib-compat.h>
+#if SHLIB_COMPAT (libm, GLIBC_2_1, GLIBC_2_2)
+strong_alias (__fegetexceptflag, __old_fegetexceptflag)
+compat_symbol (libm, __old_fegetexceptflag, fegetexceptflag, GLIBC_2_1);
+#endif
+versioned_symbol (libm, __fegetexceptflag, fegetexceptflag, GLIBC_2_2);
diff --git a/ports/sysdeps/arm/eabi/find_exidx.c b/ports/sysdeps/arm/eabi/find_exidx.c
index 9e4f4012f..59b33de5a 100644
--- a/ports/sysdeps/arm/eabi/find_exidx.c
+++ b/ports/sysdeps/arm/eabi/find_exidx.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2005 Free Software Foundation, Inc.
+/* Copyright (C) 2005, 2008 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
@@ -72,7 +72,7 @@ __gnu_Unwind_Find_exidx (_Unwind_Ptr pc, int * pcount)
data.pc = pc;
data.exidx_start = 0;
- if (dl_iterate_phdr (find_exidx_callback, &data) <= 0)
+ if (__dl_iterate_phdr (find_exidx_callback, &data) <= 0)
return 0;
*pcount = data.exidx_len / 8;
diff --git a/ports/sysdeps/arm/eabi/fsetexcptflg.c b/ports/sysdeps/arm/eabi/fsetexcptflg.c
index 2e05514f1..3dfeb2c29 100644
--- a/ports/sysdeps/arm/eabi/fsetexcptflg.c
+++ b/ports/sysdeps/arm/eabi/fsetexcptflg.c
@@ -1,5 +1,5 @@
/* Set floating-point environment exception handling.
- Copyright (C) 1997,98,99,2000,01,05 Free Software Foundation, Inc.
+ Copyright (C) 1997,98,99,2000,01,05,08 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
@@ -37,8 +37,8 @@ __fesetexceptflag (const fexcept_t *flagp, int excepts)
_FPU_GETCW (temp);
/* Set the desired exception mask. */
- temp &= ~((excepts & FE_ALL_EXCEPT) << FE_EXCEPT_SHIFT);
- temp |= (*flagp & excepts & FE_ALL_EXCEPT) << FE_EXCEPT_SHIFT;
+ temp &= ~(excepts & FE_ALL_EXCEPT);
+ temp |= (*flagp & excepts & FE_ALL_EXCEPT);
/* Save state back to the FPU. */
_FPU_SETCW (temp);
diff --git a/ports/sysdeps/arm/eabi/machine-gmon.h b/ports/sysdeps/arm/eabi/machine-gmon.h
index d488aefdf..189a9a3c6 100644
--- a/ports/sysdeps/arm/eabi/machine-gmon.h
+++ b/ports/sysdeps/arm/eabi/machine-gmon.h
@@ -75,6 +75,7 @@ void __attribute__((__naked__)) _mcount (void) \
{ \
__asm__("push {r0, r1, r2, r3, fp, lr};" \
"movs r0, fp;" \
+ "ittt ne;" \
"ldrne r0, [r0, #-4];" \
"movsne r1, lr;" \
"blne mcount_internal;" \
diff --git a/ports/sysdeps/arm/eabi/setjmp.S b/ports/sysdeps/arm/eabi/setjmp.S
index b7d2400f9..835db714a 100644
--- a/ports/sysdeps/arm/eabi/setjmp.S
+++ b/ports/sysdeps/arm/eabi/setjmp.S
@@ -1,5 +1,5 @@
/* setjmp for ARM.
- Copyright (C) 1997, 1998, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1997, 1998, 2005, 2006, 2008 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
@@ -94,3 +94,4 @@ Lhwcap:
END (__sigsetjmp)
+hidden_def (__sigsetjmp)
diff --git a/ports/sysdeps/arm/libm-test-ulps b/ports/sysdeps/arm/libm-test-ulps
index 6a4bcc614..4fec86ee1 100644
--- a/ports/sysdeps/arm/libm-test-ulps
+++ b/ports/sysdeps/arm/libm-test-ulps
@@ -13,10 +13,24 @@ float: 2
idouble: 1
ifloat: 2
+# atan2
+Test "atan2 (-0.75, -1.0) == -2.49809154479650885165983415456218025":
+float: 1
+ifloat: 1
+Test "atan2 (0.75, -1.0) == 2.49809154479650885165983415456218025":
+float: 1
+ifloat: 1
+Test "atan2 (1.390625, 0.9296875) == 0.981498387184244311516296577615519772":
+float: 1
+ifloat: 1
+
# atanh
Test "atanh (0.7) == 0.8673005276940531944":
double: 1
idouble: 1
+Test "atanh (0.75) == 0.972955074527656652552676371721589865":
+float: 1
+ifloat: 1
# cabs
Test "cabs (-0.7 + 12.4 i) == 12.419742348374220601176836866763271":
@@ -59,6 +73,9 @@ double: 1
float: 3
idouble: 1
ifloat: 3
+Test "Imaginary part of: cacosh (-2 - 3 i) == 1.9833870299165354323470769028940395 - 2.1414491111159960199416055713254211 i":
+float: 1
+ifloat: 1
Test "Real part of: cacosh (0.7 + 1.2 i) == 1.0927647857577371459105272080819308 + 1.1351827477151551088992008271819053 i":
double: 1
float: 1
@@ -74,6 +91,11 @@ ifloat: 2
Test "Imaginary part of: casin (0.7 + 1.2 i) == 0.4356135790797415103321208644578462 + 1.0927647857577371459105272080819308 i":
float: 1
ifloat: 1
+Test "Real part of: casin (0.75 + 1.25 i) == 0.453276177638793913448921196101971749 + 1.13239363160530819522266333696834467 i":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
# casinh
Test "Real part of: casinh (-2 - 3 i) == -1.9686379257930962917886650952454982 - 0.96465850440760279204541105949953237 i":
@@ -92,6 +114,14 @@ idouble: 1
Test "Imaginary part of: casinh (0.7 + 1.2 i) == 0.97865459559367387689317593222160964 + 0.91135418953156011567903546856170941 i":
float: 1
ifloat: 1
+Test "Real part of: casinh (0.75 + 1.25 i) == 1.03171853444778027336364058631006594 + 0.911738290968487636358489564316731207 i":
+float: 1
+ifloat: 1
+Test "Imaginary part of: casinh (0.75 + 1.25 i) == 1.03171853444778027336364058631006594 + 0.911738290968487636358489564316731207 i":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
# catan
Test "Real part of: catan (-2 - 3 i) == -1.4099210495965755225306193844604208 - 0.22907268296853876629588180294200276 i":
@@ -124,14 +154,23 @@ double: 1
float: 6
idouble: 1
ifloat: 6
+Test "Real part of: catanh (0.75 + 1.25 i) == 0.261492138795671927078652057366532140 + 0.996825126463918666098902241310446708 i":
+double: 1
+idouble: 1
# cbrt
Test "cbrt (-27.0) == -3.0":
double: 1
idouble: 1
+Test "cbrt (0.75) == 0.908560296416069829445605878163630251":
+double: 1
+idouble: 1
Test "cbrt (0.970299) == 0.99":
double: 1
idouble: 1
+Test "cbrt (0.9921875) == 0.997389022060725270579075195353955217":
+double: 1
+idouble: 1
# ccos
Test "Imaginary part of: ccos (-2 - 3 i) == -4.18962569096880723013255501961597373 - 9.10922789375533659797919726277886212 i":
@@ -143,6 +182,14 @@ idouble: 1
Test "Imaginary part of: ccos (0.7 + 1.2 i) == 1.3848657645312111080 - 0.97242170335830028619 i":
double: 1
idouble: 1
+Test "Real part of: ccos (0.75 + 1.25 i) == 1.38173873063425888530729933139078645 - 1.09193013555397466170919531722024128 i":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
+Test "Imaginary part of: ccos (0.75 + 1.25 i) == 1.38173873063425888530729933139078645 - 1.09193013555397466170919531722024128 i":
+float: 1
+ifloat: 1
# ccosh
Test "Real part of: ccosh (-2 - 3 i) == -3.72454550491532256547397070325597253 + 0.511822569987384608834463849801875634 i":
@@ -159,6 +206,14 @@ ifloat: 1
Test "Imaginary part of: ccosh (0.7 + 1.2 i) == 0.4548202223691477654 + 0.7070296600921537682 i":
double: 1
idouble: 1
+Test "Real part of: ccosh (0.75 + 1.25 i) == 0.408242591877968807788852146397499084 + 0.780365930845853240391326216300863152 i":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
+Test "Imaginary part of: ccosh (0.75 + 1.25 i) == 0.408242591877968807788852146397499084 + 0.780365930845853240391326216300863152 i":
+float: 1
+ifloat: 1
# cexp
Test "Imaginary part of: cexp (-2.0 - 3.0 i) == -0.13398091492954261346140525546115575 - 0.019098516261135196432576240858800925 i":
@@ -172,6 +227,9 @@ ifloat: 1
Test "Imaginary part of: cexp (0.7 + 1.2 i) == 0.72969890915032360123451688642930727 + 1.8768962328348102821139467908203072 i":
float: 1
ifloat: 1
+Test "Real part of: cexp (0.75 + 1.25 i) == 0.667537446429131586942201977015932112 + 2.00900045494094876258347228145863909 i":
+float: 1
+ifloat: 1
# clog
Test "Imaginary part of: clog (-2 - 3 i) == 1.2824746787307683680267437207826593 - 2.1587989303424641704769327722648368 i":
@@ -179,6 +237,9 @@ double: 1
float: 3
idouble: 1
ifloat: 3
+Test "Real part of: clog (0.75 + 1.25 i) == 0.376885901188190075998919126749298416 + 1.03037682652431246378774332703115153 i":
+float: 1
+ifloat: 1
# clog10
Test "Imaginary part of: clog10 (-0 + inf i) == inf + pi/2*log10(e) i":
@@ -224,6 +285,9 @@ ifloat: 1
Test "Imaginary part of: clog10 (0.7 + 1.2 i) == 0.1427786545038868803 + 0.4528483579352493248 i":
double: 1
idouble: 1
+Test "Real part of: clog10 (0.75 + 1.25 i) == 0.163679467193165171449476605077428975 + 0.447486970040493067069984724340855636 i":
+float: 1
+ifloat: 1
Test "Imaginary part of: clog10 (3 + inf i) == inf + pi/2*log10(e) i":
float: 1
ifloat: 1
@@ -260,6 +324,22 @@ idouble: 0.2758
ifloat: 0.3667
# cpow
+Test "Real part of: cpow (0.75 + 1.25 i, 0.0 + 1.0 i) == 0.331825439177608832276067945276730566 + 0.131338600281188544930936345230903032 i":
+float: 1
+ifloat: 1
+Test "Imaginary part of: cpow (0.75 + 1.25 i, 0.0 + 1.0 i) == 0.331825439177608832276067945276730566 + 0.131338600281188544930936345230903032 i":
+float: 1
+ifloat: 1
+Test "Real part of: cpow (0.75 + 1.25 i, 0.75 + 1.25 i) == 0.117506293914473555420279832210420483 + 0.346552747708338676483025352060418001 i":
+double: 1
+float: 4
+idouble: 1
+ifloat: 4
+Test "Real part of: cpow (0.75 + 1.25 i, 1.0 + 1.0 i) == 0.0846958290317209430433805274189191353 + 0.513285749182902449043287190519090481 i":
+double: 2
+float: 3
+idouble: 2
+ifloat: 3
Test "Real part of: cpow (2 + 3 i, 4 + 0 i) == -119.0 - 120.0 i":
double: 1
float: 4
@@ -289,6 +369,12 @@ ifloat: 1
Test "Imaginary part of: csinh (0.7 + 1.2 i) == 0.27487868678117583582 + 1.1698665727426565139 i":
float: 1
ifloat: 1
+Test "Real part of: csinh (0.75 + 1.25 i) == 0.259294854551162779153349830618433028 + 1.22863452409509552219214606515777594 i":
+float: 1
+ifloat: 1
+Test "Imaginary part of: csinh (0.75 + 1.25 i) == 0.259294854551162779153349830618433028 + 1.22863452409509552219214606515777594 i":
+float: 1
+ifloat: 1
# csqrt
Test "Real part of: csqrt (-2 + 3 i) == 0.89597747612983812471573375529004348 + 1.6741492280355400404480393008490519 i":
@@ -318,6 +404,9 @@ double: 1
float: 1
idouble: 1
ifloat: 1
+Test "Imaginary part of: ctan (0.75 + 1.25 i) == 0.160807785916206426725166058173438663 + 0.975363285031235646193581759755216379 i":
+double: 1
+idouble: 1
# ctanh
Test "Real part of: ctanh (-2 - 3 i) == -0.965385879022133124278480269394560686 + 0.988437503832249372031403430350121098e-2 i":
@@ -338,6 +427,14 @@ double: 2
float: 1
idouble: 2
ifloat: 1
+Test "Real part of: ctanh (0.75 + 1.25 i) == 1.37260757053378320258048606571226857 + 0.385795952609750664177596760720790220 i":
+double: 1
+idouble: 1
+
+# erf
+Test "erf (1.25) == 0.922900128256458230136523481197281140":
+double: 1
+idouble: 1
# erfc
Test "erfc (0.7) == 0.32219880616258152702":
@@ -351,11 +448,17 @@ ifloat: 2
Test "erfc (2.0) == 0.0046777349810472658379":
double: 1
idouble: 1
+Test "erfc (2.0) == 0.00467773498104726583793074363274707139":
+double: 1
+idouble: 1
Test "erfc (4.1) == 0.67000276540848983727e-8":
double: 24
float: 12
idouble: 24
ifloat: 12
+Test "erfc (4.125) == 0.542340079956506600531223408575531062e-8":
+double: 1
+idouble: 1
# exp10
Test "exp10 (-1) == 0.1":
@@ -366,6 +469,11 @@ ifloat: 1
Test "exp10 (0.7) == 5.0118723362727228500155418688494574":
float: 1
ifloat: 1
+Test "exp10 (0.75) == 5.62341325190349080394951039776481231":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "exp10 (3) == 1000":
double: 6
float: 2
@@ -373,6 +481,9 @@ idouble: 6
ifloat: 2
# expm1
+Test "expm1 (0.75) == 1.11700001661267466854536981983709561":
+double: 1
+idouble: 1
Test "expm1 (1) == M_El - 1.0":
float: 1
ifloat: 1
@@ -429,6 +540,19 @@ float: 1
ifloat: 1
# j0
+Test "j0 (-4.0) == -3.9714980986384737228659076845169804197562E-1":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
+Test "j0 (0.75) == 0.864242275166648623555731103820923211":
+float: 1
+ifloat: 1
+Test "j0 (10.0) == -0.245935764451348335197760862485328754":
+double: 2
+float: 1
+idouble: 2
+ifloat: 1
Test "j0 (10.0) == -0.24593576445134833520":
double: 2
float: 1
@@ -437,22 +561,55 @@ ifloat: 1
Test "j0 (2.0) == 0.22389077914123566805":
float: 2
ifloat: 2
+Test "j0 (2.0) == 0.223890779141235668051827454649948626":
+float: 2
+ifloat: 2
+Test "j0 (4.0) == -3.9714980986384737228659076845169804197562E-1":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "j0 (8.0) == 0.17165080713755390609":
float: 1
ifloat: 1
+Test "j0 (8.0) == 0.171650807137553906090869407851972001":
+float: 1
+ifloat: 1
# j1
+Test "j1 (10.0) == 0.0434727461688614366697487680258592883":
+float: 2
+ifloat: 2
Test "j1 (10.0) == 0.043472746168861436670":
float: 2
ifloat: 2
Test "j1 (2.0) == 0.57672480775687338720":
double: 1
idouble: 1
+Test "j1 (2.0) == 0.576724807756873387202448242269137087":
+double: 1
+idouble: 1
Test "j1 (8.0) == 0.23463634685391462438":
double: 1
idouble: 1
+Test "j1 (8.0) == 0.234636346853914624381276651590454612":
+double: 1
+idouble: 1
# jn
+Test "jn (0, -4.0) == -3.9714980986384737228659076845169804197562E-1":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
+Test "jn (0, 0.75) == 0.864242275166648623555731103820923211":
+float: 1
+ifloat: 1
+Test "jn (0, 10.0) == -0.245935764451348335197760862485328754":
+double: 2
+float: 1
+idouble: 2
+ifloat: 1
Test "jn (0, 10.0) == -0.24593576445134833520":
double: 2
float: 1
@@ -461,47 +618,105 @@ ifloat: 1
Test "jn (0, 2.0) == 0.22389077914123566805":
float: 2
ifloat: 2
+Test "jn (0, 2.0) == 0.223890779141235668051827454649948626":
+float: 2
+ifloat: 2
+Test "jn (0, 4.0) == -3.9714980986384737228659076845169804197562E-1":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "jn (0, 8.0) == 0.17165080713755390609":
float: 1
ifloat: 1
+Test "jn (0, 8.0) == 0.171650807137553906090869407851972001":
+float: 1
+ifloat: 1
+Test "jn (1, 10.0) == 0.0434727461688614366697487680258592883":
+float: 2
+ifloat: 2
Test "jn (1, 10.0) == 0.043472746168861436670":
float: 2
ifloat: 2
Test "jn (1, 2.0) == 0.57672480775687338720":
double: 1
idouble: 1
+Test "jn (1, 2.0) == 0.576724807756873387202448242269137087":
+double: 1
+idouble: 1
Test "jn (1, 8.0) == 0.23463634685391462438":
double: 1
idouble: 1
+Test "jn (1, 8.0) == 0.234636346853914624381276651590454612":
+double: 1
+idouble: 1
Test "jn (10, 0.1) == 0.26905328954342155795e-19":
double: 6
float: 4
idouble: 6
ifloat: 4
+Test "jn (10, 0.125) == 0.250543369809369890173993791865771547e-18":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "jn (10, 0.7) == 0.75175911502153953928e-11":
double: 3
float: 1
idouble: 3
ifloat: 1
+Test "jn (10, 0.75) == 0.149621713117596814698712483621682835e-10":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
+Test "jn (10, 10.0) == 0.207486106633358857697278723518753428":
+double: 4
+float: 3
+idouble: 4
+ifloat: 3
Test "jn (10, 10.0) == 0.20748610663335885770":
double: 4
float: 3
idouble: 4
ifloat: 3
+Test "jn (10, 2.0) == 0.251538628271673670963516093751820639e-6":
+float: 4
+ifloat: 4
Test "jn (10, 2.0) == 0.25153862827167367096e-6":
float: 4
ifloat: 4
Test "jn (3, 0.1) == 0.000020820315754756261429":
double: 1
idouble: 1
+Test "jn (3, 0.125) == 0.406503832554912875023029337653442868e-4":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "jn (3, 0.7) == 0.0069296548267508408077":
float: 1
ifloat: 1
+Test "jn (3, 0.75) == 0.848438342327410884392755236884386804e-2":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
+Test "jn (3, 10.0) == 0.0583793793051868123429354784103409563":
+double: 3
+float: 1
+idouble: 3
+ifloat: 1
Test "jn (3, 10.0) == 0.058379379305186812343":
double: 3
float: 1
idouble: 3
ifloat: 1
+Test "jn (3, 2.0) == 0.128943249474402051098793332969239835":
+double: 1
+float: 2
+idouble: 1
+ifloat: 2
Test "jn (3, 2.0) == 0.12894324947440205110":
double: 1
float: 2
@@ -533,11 +748,19 @@ double: 1
float: 1
idouble: 1
ifloat: 1
+Test "log10 (0.75) == -0.124938736608299953132449886193870744":
+double: 1
+float: 2
+idouble: 1
+ifloat: 2
Test "log10 (e) == log10(e)":
float: 1
ifloat: 1
# log1p
+Test "log1p (-0.25) == -0.287682072451780927439219005993827432":
+float: 1
+ifloat: 1
Test "log1p (-0.3) == -0.35667494393873237891263871124118447":
double: 1
float: 1
@@ -567,11 +790,19 @@ double: 1
float: 1
idouble: 1
ifloat: 1
+Test "sincos (M_PI_6l*2.0, &sin_res, &cos_res) puts 0.86602540378443864676372317075293616 in sin_res":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "sincos (pi/2, &sin_res, &cos_res) puts 0 in cos_res":
double: 0.2758
float: 0.3667
idouble: 0.2758
ifloat: 0.3667
+Test "sincos (pi/6, &sin_res, &cos_res) puts 0.86602540378443864676372317075293616 in cos_res":
+float: 1
+ifloat: 1
Test "sincos (pi/6, &sin_res, &cos_res) puts 0.866025403784438646764 in cos_res":
float: 1
ifloat: 1
@@ -616,11 +847,21 @@ double: 2
float: 1
idouble: 2
ifloat: 1
+Test "y0 (1.0) == 0.0882569642156769579829267660235151628":
+double: 2
+float: 1
+idouble: 2
+ifloat: 1
Test "y0 (1.0) == 0.088256964215676957983":
double: 2
float: 1
idouble: 2
ifloat: 1
+Test "y0 (1.5) == 0.382448923797758843955068554978089862":
+double: 2
+float: 1
+idouble: 2
+ifloat: 1
Test "y0 (1.5) == 0.38244892379775884396":
double: 2
float: 1
@@ -629,6 +870,14 @@ ifloat: 1
Test "y0 (10.0) == 0.055671167283599391424":
float: 1
ifloat: 1
+Test "y0 (10.0) == 0.0556711672835993914244598774101900481":
+float: 1
+ifloat: 1
+Test "y0 (8.0) == 0.223521489387566220527323400498620359":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "y0 (8.0) == 0.22352148938756622053":
double: 1
float: 1
@@ -639,6 +888,9 @@ ifloat: 1
Test "y1 (0.1) == -6.4589510947020269877":
double: 1
idouble: 1
+Test "y1 (0.125) == -5.19993611253477499595928744876579921":
+double: 1
+idouble: 1
Test "y1 (0.7) == -1.1032498719076333697":
double: 1
float: 1
@@ -647,16 +899,34 @@ ifloat: 1
Test "y1 (1.5) == -0.41230862697391129595":
float: 1
ifloat: 1
+Test "y1 (1.5) == -0.412308626973911295952829820633445323":
+float: 1
+ifloat: 1
Test "y1 (10.0) == 0.24901542420695388392":
double: 3
float: 1
idouble: 3
ifloat: 1
+Test "y1 (10.0) == 0.249015424206953883923283474663222803":
+double: 3
+float: 1
+idouble: 3
+ifloat: 1
+Test "y1 (2.0) == -0.107032431540937546888370772277476637":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "y1 (2.0) == -0.10703243154093754689":
double: 1
float: 1
idouble: 1
ifloat: 1
+Test "y1 (8.0) == -0.158060461731247494255555266187483550":
+double: 1
+float: 2
+idouble: 1
+ifloat: 2
Test "y1 (8.0) == -0.15806046173124749426":
double: 1
float: 2
@@ -669,11 +939,21 @@ double: 2
float: 1
idouble: 2
ifloat: 1
+Test "yn (0, 1.0) == 0.0882569642156769579829267660235151628":
+double: 2
+float: 1
+idouble: 2
+ifloat: 1
Test "yn (0, 1.0) == 0.088256964215676957983":
double: 2
float: 1
idouble: 2
ifloat: 1
+Test "yn (0, 1.5) == 0.382448923797758843955068554978089862":
+double: 2
+float: 1
+idouble: 2
+ifloat: 1
Test "yn (0, 1.5) == 0.38244892379775884396":
double: 2
float: 1
@@ -682,6 +962,14 @@ ifloat: 1
Test "yn (0, 10.0) == 0.055671167283599391424":
float: 1
ifloat: 1
+Test "yn (0, 10.0) == 0.0556711672835993914244598774101900481":
+float: 1
+ifloat: 1
+Test "yn (0, 8.0) == 0.223521489387566220527323400498620359":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "yn (0, 8.0) == 0.22352148938756622053":
double: 1
float: 1
@@ -690,6 +978,9 @@ ifloat: 1
Test "yn (1, 0.1) == -6.4589510947020269877":
double: 1
idouble: 1
+Test "yn (1, 0.125) == -5.19993611253477499595928744876579921":
+double: 1
+idouble: 1
Test "yn (1, 0.7) == -1.1032498719076333697":
double: 1
float: 1
@@ -698,16 +989,34 @@ ifloat: 1
Test "yn (1, 1.5) == -0.41230862697391129595":
float: 1
ifloat: 1
+Test "yn (1, 1.5) == -0.412308626973911295952829820633445323":
+float: 1
+ifloat: 1
Test "yn (1, 10.0) == 0.24901542420695388392":
double: 3
float: 1
idouble: 3
ifloat: 1
+Test "yn (1, 10.0) == 0.249015424206953883923283474663222803":
+double: 3
+float: 1
+idouble: 3
+ifloat: 1
+Test "yn (1, 2.0) == -0.107032431540937546888370772277476637":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "yn (1, 2.0) == -0.10703243154093754689":
double: 1
float: 1
idouble: 1
ifloat: 1
+Test "yn (1, 8.0) == -0.158060461731247494255555266187483550":
+double: 1
+float: 2
+idouble: 1
+ifloat: 2
Test "yn (1, 8.0) == -0.15806046173124749426":
double: 1
float: 2
@@ -718,17 +1027,36 @@ double: 2
float: 2
idouble: 2
ifloat: 2
+Test "yn (10, 0.125) == -127057845771019398.252538486899753195":
+double: 1
+idouble: 1
Test "yn (10, 0.7) == -0.42447194260703866924e10":
double: 3
idouble: 3
+Test "yn (10, 0.75) == -2133501638.90573424452445412893839236":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "yn (10, 1.0) == -0.12161801427868918929e9":
double: 1
idouble: 1
+Test "yn (10, 1.0) == -121618014.278689189288130426667971145":
+double: 1
+idouble: 1
Test "yn (10, 10.0) == -0.35981415218340272205":
double: 1
float: 1
idouble: 1
ifloat: 1
+Test "yn (10, 10.0) == -0.359814152183402722051986577343560609":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
+Test "yn (10, 2.0) == -129184.542208039282635913145923304214":
+double: 2
+idouble: 2
Test "yn (10, 2.0) == -129184.54220803928264":
double: 2
idouble: 2
@@ -737,16 +1065,32 @@ double: 1
float: 1
idouble: 1
ifloat: 1
+Test "yn (3, 0.125) == -2612.69757350066712600220955744091741":
+double: 1
+idouble: 1
Test "yn (3, 0.7) == -15.819479052819633505":
double: 3
float: 1
idouble: 3
ifloat: 1
+Test "yn (3, 0.75) == -12.9877176234475433186319774484809207":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
+Test "yn (3, 10.0) == -0.251362657183837329779204747654240998":
+double: 1
+float: 1
+idouble: 1
+ifloat: 1
Test "yn (3, 10.0) == -0.25136265718383732978":
double: 1
float: 1
idouble: 1
ifloat: 1
+Test "yn (3, 2.0) == -1.12778377684042778608158395773179238":
+double: 1
+idouble: 1
Test "yn (3, 2.0) == -1.1277837768404277861":
double: 1
idouble: 1
@@ -758,9 +1102,15 @@ float: 2
idouble: 1
ifloat: 2
+Function: "atan2":
+float: 1
+ifloat: 1
+
Function: "atanh":
double: 1
+float: 1
idouble: 1
+ifloat: 1
Function: "cabs":
double: 1
@@ -840,7 +1190,9 @@ idouble: 1
Function: Real part of "ccos":
double: 1
+float: 1
idouble: 1
+ifloat: 1
Function: Imaginary part of "ccos":
double: 1
@@ -870,6 +1222,10 @@ Function: Imaginary part of "cexp":
float: 1
ifloat: 1
+Function: Real part of "clog":
+float: 1
+ifloat: 1
+
Function: Imaginary part of "clog":
double: 1
float: 3
@@ -895,15 +1251,15 @@ idouble: 2
ifloat: 1
Function: Real part of "cpow":
-double: 1
+double: 2
float: 4
-idouble: 1
+idouble: 2
ifloat: 4
Function: Imaginary part of "cpow":
-double: 1.1031
+double: 2
float: 2
-idouble: 1.1031
+idouble: 2
ifloat: 2
Function: Imaginary part of "csin":
@@ -954,6 +1310,10 @@ float: 1
idouble: 2
ifloat: 1
+Function: "erf":
+double: 1
+idouble: 1
+
Function: "erfc":
double: 24
float: 12
@@ -967,7 +1327,9 @@ idouble: 6
ifloat: 2
Function: "expm1":
+double: 1
float: 1
+idouble: 1
ifloat: 1
Function: "fmod":
@@ -1014,9 +1376,9 @@ ifloat: 1
Function: "log10":
double: 1
-float: 1
+float: 2
idouble: 1
-ifloat: 1
+ifloat: 2
Function: "log1p":
double: 1
diff --git a/ports/sysdeps/arm/memmove.S b/ports/sysdeps/arm/memmove.S
index 2dd0790a2..eda1bcc9b 100644
--- a/ports/sysdeps/arm/memmove.S
+++ b/ports/sysdeps/arm/memmove.S
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 Free Software Foundation, Inc.
+/* Copyright (C) 2006, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by MontaVista Software, Inc. (written by Nicolas Pitre)
@@ -66,7 +66,11 @@ ENTRY(memmove)
subs ip, r0, r1
cmphi r2, ip
+#ifdef NOT_IN_libc
bls memcpy
+#else
+ bls HIDDEN_JUMPTARGET(memcpy)
+#endif
stmfd sp!, {r0, r4, lr}
add r1, r1, r2
diff --git a/ports/sysdeps/arm/nptl/pthread_spin_lock.c b/ports/sysdeps/arm/nptl/pthread_spin_lock.c
index 9661d13d4..1217b899a 100644
--- a/ports/sysdeps/arm/nptl/pthread_spin_lock.c
+++ b/ports/sysdeps/arm/nptl/pthread_spin_lock.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2005, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2008 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
@@ -22,7 +22,7 @@
int
pthread_spin_lock (pthread_spinlock_t *lock)
{
- while (atomic_compare_and_exchange_val_acq(lock, 1, 0) != 0)
+ while (atomic_compare_and_exchange_val_acq (lock, 1, 0) != 0)
while (*lock != 0)
;
diff --git a/ports/sysdeps/arm/nptl/pthread_spin_trylock.c b/ports/sysdeps/arm/nptl/pthread_spin_trylock.c
index 8e65e7326..fb998d243 100644
--- a/ports/sysdeps/arm/nptl/pthread_spin_trylock.c
+++ b/ports/sysdeps/arm/nptl/pthread_spin_trylock.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2005, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2008 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
@@ -23,5 +23,5 @@
int
pthread_spin_trylock (pthread_spinlock_t *lock)
{
- return atomic_compare_and_exchange_val_acq(lock, 1, 0) ? EBUSY : 0;
+ return atomic_compare_and_exchange_val_acq (lock, 1, 0) ? EBUSY : 0;
}
diff --git a/ports/sysdeps/arm/setjmp.S b/ports/sysdeps/arm/setjmp.S
index 2e8c6940f..3fff9e9b5 100644
--- a/ports/sysdeps/arm/setjmp.S
+++ b/ports/sysdeps/arm/setjmp.S
@@ -1,5 +1,5 @@
/* setjmp for ARM.
- Copyright (C) 1997, 1998 Free Software Foundation, Inc.
+ Copyright (C) 1997, 1998, 2008 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
@@ -29,3 +29,5 @@ ENTRY (__sigsetjmp)
/* Make a tail call to __sigjmp_save; it takes the same args. */
B PLTJMP(C_SYMBOL_NAME(__sigjmp_save))
END (__sigsetjmp)
+
+hidden_def (__sigsetjmp)
diff --git a/ports/sysdeps/hppa/fpu/fesetenv.c b/ports/sysdeps/hppa/fpu/fesetenv.c
index b5753efab..1a5ca6592 100644
--- a/ports/sysdeps/hppa/fpu/fesetenv.c
+++ b/ports/sysdeps/hppa/fpu/fesetenv.c
@@ -35,7 +35,7 @@ fesetenv (const fenv_t *envp)
bufptr = temp.buf;
__asm__ (
"fstd,ma %%fr0,8(%1)\n"
- : "=m" (temp), "+r" (bufptr) : : "%r0");
+ : "=m" (temp) : "r" (bufptr) : "%r0");
temp.env.__status_word &= ~(FE_ALL_EXCEPT
| (FE_ALL_EXCEPT << 27)
@@ -56,7 +56,7 @@ fesetenv (const fenv_t *envp)
is loaded last and T-Bit is enabled. */
__asm__ (
"fldd,mb -8(%1),%%fr0\n"
- : "=m" (temp), "+r" (bufptr) : : "%r0" );
+ : : "m" (temp), "r" (bufptr) : "%r0" );
/* Success. */
return 0;
diff --git a/ports/sysdeps/m68k/bits/byteswap.h b/ports/sysdeps/m68k/bits/byteswap.h
index 41b386b31..a2546c9a2 100644
--- a/ports/sysdeps/m68k/bits/byteswap.h
+++ b/ports/sysdeps/m68k/bits/byteswap.h
@@ -1,5 +1,5 @@
/* Macros to swap the order of bytes in integer values. m68k version.
- Copyright (C) 1997, 2002 Free Software Foundation, Inc.
+ Copyright (C) 1997, 2002, 2008 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,7 +17,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#if !defined _BYTESWAP_H && !defined _NETINET_IN_H
+#if !defined _BYTESWAP_H && !defined _NETINET_IN_H && !defined _ENDIAN_H
# error "Never use <bits/byteswap.h> directly; include <byteswap.h> instead."
#endif
@@ -27,13 +27,25 @@
/* Swap bytes in 16 bit value. We don't provide an assembler version
because GCC is smart enough to generate optimal assembler output, and
this allows for better cse. */
-#define __bswap_16(x) \
- ((((x) >> 8) & 0xff) | (((x) & 0xff) << 8))
+#define __bswap_constant_16(x) \
+ ((((x) >> 8) & 0xffu) | (((x) & 0xffu) << 8))
+
+#ifdef __GNUC__
+# define __bswap_16(x) \
+ (__extension__ \
+ ({ unsigned short int __bsx = (x); __bswap_constant_16 (__bsx); }))
+#else
+static __inline unsigned short int
+__bswap_16 (unsigned short int __bsx)
+{
+ return __bswap_constant_16 (__bsx);
+}
+#endif
/* Swap bytes in 32 bit value. */
#define __bswap_constant_32(x) \
- ((((x) & 0xff000000) >> 24) | (((x) & 0x00ff0000) >> 8) | \
- (((x) & 0x0000ff00) << 8) | (((x) & 0x000000ff) << 24))
+ ((((x) & 0xff000000u) >> 24) | (((x) & 0x00ff0000u) >> 8) | \
+ (((x) & 0x0000ff00u) << 8) | (((x) & 0x000000ffu) << 24))
#if defined __GNUC__ && __GNUC__ >= 2 && !defined(__mcoldfire__)
# define __bswap_32(x) \
@@ -49,18 +61,38 @@
: "0" ((unsigned int) (x))); \
__bswap_32_v; })
#else
-# define __bswap_32(x) __bswap_constant_32 (x)
+static __inline unsigned int
+__bswap_32 (unsigned int __bsx)
+{
+ return __bswap_constant_32 (__bsx);
+}
#endif
#if defined __GNUC__ && __GNUC__ >= 2
/* Swap bytes in 64 bit value. */
+# define __bswap_constant_64(x) \
+ ((((x) & 0xff00000000000000ull) >> 56) \
+ | (((x) & 0x00ff000000000000ull) >> 40) \
+ | (((x) & 0x0000ff0000000000ull) >> 24) \
+ | (((x) & 0x000000ff00000000ull) >> 8) \
+ | (((x) & 0x00000000ff000000ull) << 8) \
+ | (((x) & 0x0000000000ff0000ull) << 24) \
+ | (((x) & 0x000000000000ff00ull) << 40) \
+ | (((x) & 0x00000000000000ffull) << 56))
+
+/* Swap bytes in 64 bit value. */
# define __bswap_64(x) \
__extension__ \
({ union { unsigned long long int __ll; \
unsigned long int __l[2]; } __bswap_64_v, __bswap_64_r; \
- __bswap_64_v.__ll = (x); \
- __bswap_64_r.__l[0] = __bswap_32 (__bswap_64_v.__l[1]); \
- __bswap_64_r.__l[1] = __bswap_32 (__bswap_64_v.__l[0]); \
+ if (__builtin_constant_p (x)) \
+ __bswap_64_r.__ll = __bswap_constant_64 (x); \
+ else \
+ { \
+ __bswap_64_v.__ll = (x); \
+ __bswap_64_r.__l[0] = __bswap_32 (__bswap_64_v.__l[1]); \
+ __bswap_64_r.__l[1] = __bswap_32 (__bswap_64_v.__l[0]); \
+ } \
__bswap_64_r.__ll; })
#endif
diff --git a/ports/sysdeps/m68k/bits/setjmp.h b/ports/sysdeps/m68k/bits/setjmp.h
index 27ec051e5..b2d8b2e60 100644
--- a/ports/sysdeps/m68k/bits/setjmp.h
+++ b/ports/sysdeps/m68k/bits/setjmp.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997,1998,2005,2006 Free Software Foundation, Inc.
+/* Copyright (C) 1997,1998,2005,2006,2008 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
@@ -24,7 +24,7 @@
# error "Never include <bits/setjmp.h> directly; use <setjmp.h> instead."
#endif
-typedef struct
+typedef struct __jmp_buf_internal_tag
{
/* There are eight 4-byte data registers, but D0 is not saved. */
long int __dregs[7];
diff --git a/ports/sysdeps/m68k/m680x0/fpu/bits/mathinline.h b/ports/sysdeps/m68k/m680x0/fpu/bits/mathinline.h
index acbac47aa..6b69f7a49 100644
--- a/ports/sysdeps/m68k/m680x0/fpu/bits/mathinline.h
+++ b/ports/sysdeps/m68k/m680x0/fpu/bits/mathinline.h
@@ -1,5 +1,5 @@
/* Definitions of inline math functions implemented by the m68881/2.
- Copyright (C) 1991,92,93,94,96,97,98,99,2000,2002, 2003, 2004
+ Copyright (C) 1991,92,93,94,96,97,98,99,2000,2002, 2003, 2004, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -18,6 +18,16 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+#ifndef _MATH_H
+# error "Never use <bits/mathinline.h> directly; include <math.h> instead."
+#endif
+
+#ifndef __extern_inline
+# define __MATH_INLINE __inline
+#else
+# define __MATH_INLINE __extern_inline
+#endif
+
#ifdef __GNUC__
#ifdef __USE_ISOC99
@@ -89,11 +99,7 @@
# define __m81_inline static __inline
#else
# define __m81_u(x) x
-# ifdef __cplusplus
-# define __m81_inline __inline
-# else
-# define __m81_inline extern __inline
-# endif
+# define __m81_inline __MATH_INLINE
# define __M81_MATH_INLINES 1
#endif
@@ -351,14 +357,14 @@ __inline_functions (long double,l)
/* Note that there must be no whitespace before the argument passed for
NAME, to make token pasting work correctly with -traditional. */
# define __inline_forward_c(rettype, name, args1, args2) \
-extern __inline rettype __attribute__((__const__)) \
+__MATH_INLINE rettype __attribute__((__const__)) \
name args1 \
{ \
return __CONCAT(__,name) args2; \
}
# define __inline_forward(rettype, name, args1, args2) \
-extern __inline rettype name args1 \
+__MATH_INLINE rettype name args1 \
{ \
return __CONCAT(__,name) args2; \
}
diff --git a/ports/sysdeps/mips/bits/setjmp.h b/ports/sysdeps/mips/bits/setjmp.h
index 4f159c498..d3ced9827 100644
--- a/ports/sysdeps/mips/bits/setjmp.h
+++ b/ports/sysdeps/mips/bits/setjmp.h
@@ -27,7 +27,7 @@
#include <sgidefs.h>
-typedef struct
+typedef struct __jmp_buf_internal_tag
{
#if _MIPS_SIM == _ABIO32
/* Program counter. */
diff --git a/ports/sysdeps/mips/fpu_control.h b/ports/sysdeps/mips/fpu_control.h
index 5712ac533..eb71928a5 100644
--- a/ports/sysdeps/mips/fpu_control.h
+++ b/ports/sysdeps/mips/fpu_control.h
@@ -1,5 +1,6 @@
/* FPU control word bits. Mips version.
- Copyright (C) 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright (C) 1996, 1997, 1998, 1999, 2000, 2006, 2008
+ Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Olaf Flebbe and Ralf Baechle.
@@ -100,8 +101,8 @@ extern fpu_control_t __fpu_control;
typedef unsigned int fpu_control_t __attribute__ ((__mode__ (__SI__)));
/* Macros for accessing the hardware control word. */
-#define _FPU_GETCW(cw) __asm__ ("cfc1 %0,$31" : "=r" (cw))
-#define _FPU_SETCW(cw) __asm__ ("ctc1 %0,$31" : : "r" (cw))
+#define _FPU_GETCW(cw) __asm__ volatile ("cfc1 %0,$31" : "=r" (cw))
+#define _FPU_SETCW(cw) __asm__ volatile ("ctc1 %0,$31" : : "r" (cw))
/* Default control word set at startup. */
extern fpu_control_t __fpu_control;
diff --git a/ports/sysdeps/powerpc/nofpu/feholdexcpt.c b/ports/sysdeps/powerpc/nofpu/feholdexcpt.c
index ade9d19f4..4074ac041 100644
--- a/ports/sysdeps/powerpc/nofpu/feholdexcpt.c
+++ b/ports/sysdeps/powerpc/nofpu/feholdexcpt.c
@@ -1,6 +1,6 @@
/* Store current floating-point environment and clear exceptions
(soft-float edition).
- Copyright (C) 2002, 2007 Free Software Foundation, Inc.
+ Copyright (C) 2002, 2007, 2008 Free Software Foundation, Inc.
Contributed by Aldy Hernandez <aldyh@redhat.com>, 2002.
This file is part of the GNU C Library.
@@ -28,7 +28,7 @@ feholdexcept (fenv_t *envp)
fenv_union_t u;
/* Get the current state. */
- fegetenv (envp);
+ __fegetenv (envp);
u.fenv = *envp;
/* Clear everything except the rounding mode. */
diff --git a/ports/sysdeps/powerpc/nofpu/shlib-versions b/ports/sysdeps/powerpc/nofpu/shlib-versions
new file mode 100644
index 000000000..72085ddf4
--- /dev/null
+++ b/ports/sysdeps/powerpc/nofpu/shlib-versions
@@ -0,0 +1 @@
+powerpc.*-.*-.* ABI powerpcsoft-@OS@
diff --git a/ports/sysdeps/powerpc/powerpc32/e500/fpu/spe.h b/ports/sysdeps/powerpc/powerpc32/e500/fpu/spe.h
new file mode 100644
index 000000000..91bca2710
--- /dev/null
+++ b/ports/sysdeps/powerpc/powerpc32/e500/fpu/spe.h
@@ -0,0 +1,12 @@
+#ifndef _SPE_H
+
+#include_next <spe.h>
+
+libc_hidden_proto (strtosfix16)
+libc_hidden_proto (strtosfix32)
+libc_hidden_proto (strtosfix64)
+libc_hidden_proto (strtoufix16)
+libc_hidden_proto (strtoufix32)
+libc_hidden_proto (strtoufix64)
+
+#endif
diff --git a/ports/sysdeps/powerpc/powerpc32/e500/fpu/strtofix.c b/ports/sysdeps/powerpc/powerpc32/e500/fpu/strtofix.c
index 653006835..63628f6f4 100644
--- a/ports/sysdeps/powerpc/powerpc32/e500/fpu/strtofix.c
+++ b/ports/sysdeps/powerpc/powerpc32/e500/fpu/strtofix.c
@@ -1,5 +1,6 @@
/* Convert string representing a number to float value, using given locale.
- Copyright (C) 1997,1998,2002,2004,2005,2006 Free Software Foundation, Inc.
+ Copyright (C) 1997,1998,2002,2004,2005,2006,2008
+ Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
@@ -28,6 +29,7 @@
#include <locale/localeinfo.h>
#include <locale.h>
#include <math.h>
+#include <spe.h>
#include <stdlib.h>
#include <string.h>
@@ -696,3 +698,5 @@ STRTOFIX (const char *nptr, char **endptr)
#endif
return round_and_set_sign (val, negative, half, extra);
}
+
+libc_hidden_def (STRTOFIX)
diff --git a/ports/sysdeps/powerpc/powerpc32/e500/soft-fp/fraiseexcept-soft.c b/ports/sysdeps/powerpc/powerpc32/e500/soft-fp/fraiseexcept-soft.c
index 0aea3a880..3462d415b 100644
--- a/ports/sysdeps/powerpc/powerpc32/e500/soft-fp/fraiseexcept-soft.c
+++ b/ports/sysdeps/powerpc/powerpc32/e500/soft-fp/fraiseexcept-soft.c
@@ -1,5 +1,5 @@
/* Raise given exceptions.
- Copyright (C) 2004 Free Software Foundation, Inc.
+ Copyright (C) 2004, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Aldy Hernandez <aldyh@redhat.com>, 2004.
@@ -20,6 +20,11 @@
#include <fenv_libc.h>
#include <bp-sym.h>
+#include <libc-symbols.h>
+
+int __feraiseexcept_soft (int);
+libc_hidden_proto (__feraiseexcept_soft)
#define __FERAISEEXCEPT_INTERNAL __feraiseexcept_soft
#include "../spe-raise.c"
+libc_hidden_def (__feraiseexcept_soft)
diff --git a/ports/sysdeps/powerpc/powerpc32/e500/soft-fp/sfp-machine.h b/ports/sysdeps/powerpc/powerpc32/e500/soft-fp/sfp-machine.h
index ceff99b12..752eb6258 100644
--- a/ports/sysdeps/powerpc/powerpc32/e500/soft-fp/sfp-machine.h
+++ b/ports/sysdeps/powerpc/powerpc32/e500/soft-fp/sfp-machine.h
@@ -1,6 +1,10 @@
#ifndef _SFP_MACHINE_H_
#define _SFP_MACHINE_H_
#include <fenv_libc.h>
+#include <libc-symbols.h>
+
+int __feraiseexcept_soft (int);
+libc_hidden_proto (__feraiseexcept_soft)
#define _FP_W_TYPE_SIZE 32
#define _FP_W_TYPE unsigned long
diff --git a/ports/sysdeps/unix/sysv/linux/arm/bits/shm.h b/ports/sysdeps/unix/sysv/linux/arm/bits/shm.h
new file mode 100644
index 000000000..4faa287bc
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/arm/bits/shm.h
@@ -0,0 +1,104 @@
+/* Copyright (C) 1995,1996,1997,2000,2002,2004,2008
+ 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_SHM_H
+# error "Never include <bits/shm.h> directly; use <sys/shm.h> instead."
+#endif
+
+#include <bits/types.h>
+
+/* Permission flag for shmget. */
+#define SHM_R 0400 /* or S_IRUGO from <linux/stat.h> */
+#define SHM_W 0200 /* or S_IWUGO from <linux/stat.h> */
+
+/* Flags for `shmat'. */
+#define SHM_RDONLY 010000 /* attach read-only else read-write */
+#define SHM_RND 020000 /* round attach address to SHMLBA */
+#define SHM_REMAP 040000 /* take-over region on attach */
+
+/* Commands for `shmctl'. */
+#define SHM_LOCK 11 /* lock segment (root only) */
+#define SHM_UNLOCK 12 /* unlock segment (root only) */
+
+__BEGIN_DECLS
+
+/* Segment low boundary address multiple. */
+#define SHMLBA (__getpagesize () << 2)
+extern int __getpagesize (void) __THROW __attribute__ ((__const__));
+
+
+/* Type to count number of attaches. */
+typedef unsigned long int shmatt_t;
+
+/* Data structure describing a shared memory segment. */
+struct shmid_ds
+ {
+ struct ipc_perm shm_perm; /* operation permission struct */
+ size_t shm_segsz; /* size of segment in bytes */
+ __time_t shm_atime; /* time of last shmat() */
+ unsigned long int __unused1;
+ __time_t shm_dtime; /* time of last shmdt() */
+ unsigned long int __unused2;
+ __time_t shm_ctime; /* time of last change by shmctl() */
+ unsigned long int __unused3;
+ __pid_t shm_cpid; /* pid of creator */
+ __pid_t shm_lpid; /* pid of last shmop */
+ shmatt_t shm_nattch; /* number of current attaches */
+ unsigned long int __unused4;
+ unsigned long int __unused5;
+ };
+
+#ifdef __USE_MISC
+
+/* ipcs ctl commands */
+# define SHM_STAT 13
+# define SHM_INFO 14
+
+/* shm_mode upper byte flags */
+# define SHM_DEST 01000 /* segment will be destroyed on last detach */
+# define SHM_LOCKED 02000 /* segment will not be swapped */
+# define SHM_HUGETLB 04000 /* segment is mapped via hugetlb */
+# define SHM_NORESERVE 010000 /* don't check for reservations */
+
+struct shminfo
+ {
+ unsigned long int shmmax;
+ unsigned long int shmmin;
+ unsigned long int shmmni;
+ unsigned long int shmseg;
+ unsigned long int shmall;
+ unsigned long int __unused1;
+ unsigned long int __unused2;
+ unsigned long int __unused3;
+ unsigned long int __unused4;
+ };
+
+struct shm_info
+ {
+ int used_ids;
+ unsigned long int shm_tot; /* total allocated shm */
+ unsigned long int shm_rss; /* total resident shm */
+ unsigned long int shm_swp; /* total swapped shm */
+ unsigned long int swap_attempts;
+ unsigned long int swap_successes;
+ };
+
+#endif /* __USE_MISC */
+
+__END_DECLS
diff --git a/ports/sysdeps/unix/sysv/linux/arm/check_pf.c b/ports/sysdeps/unix/sysv/linux/arm/check_pf.c
index dfca75d37..209f36438 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/check_pf.c
+++ b/ports/sysdeps/unix/sysv/linux/arm/check_pf.c
@@ -1,5 +1,5 @@
/* Determine protocol families for which interfaces exist. Linux version.
- Copyright (C) 2003, 2006, 2007 Free Software Foundation, Inc.
+ Copyright (C) 2003, 2006, 2007, 2008 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
@@ -35,12 +35,12 @@
#include <kernel-features.h>
-#ifndef IFA_F_TEMPORARY
-# define IFA_F_TEMPORARY IFA_F_SECONDARY
-#endif
#ifndef IFA_F_HOMEADDRESS
# define IFA_F_HOMEADDRESS 0
#endif
+#ifndef IFA_F_OPTIMISTIC
+# define IFA_F_OPTIMISTIC 0
+#endif
static int
@@ -140,89 +140,67 @@ make_request (int fd, pid_t pid, bool *seen_ipv4, bool *seen_ipv6,
struct rtattr *rta = IFA_RTA (ifam);
size_t len = nlmh->nlmsg_len - NLMSG_LENGTH (sizeof (*ifam));
- switch (ifam->ifa_family)
- {
- const void *local;
- const void *address;
+ if (ifam->ifa_family != AF_INET
+ && ifam->ifa_family != AF_INET6)
+ continue;
- case AF_INET:
- local = NULL;
- address = NULL;
- while (RTA_OK (rta, len))
+ const void *local = NULL;
+ const void *address = NULL;
+ while (RTA_OK (rta, len))
+ {
+ switch (rta->rta_type)
{
- switch (rta->rta_type)
- {
- case IFA_LOCAL:
- local = RTA_DATA (rta);
- break;
-
- case IFA_ADDRESS:
- address = RTA_DATA (rta);
- goto out_v4;
- }
-
- rta = RTA_NEXT (rta, len);
+ case IFA_LOCAL:
+ local = RTA_DATA (rta);
+ break;
+
+ case IFA_ADDRESS:
+ address = RTA_DATA (rta);
+ goto out;
}
- if (local != NULL)
+ rta = RTA_NEXT (rta, len);
+ }
+
+ if (local != NULL)
+ {
+ address = local;
+ out:
+ if (ifam->ifa_family == AF_INET)
{
- out_v4:
- if (*(const in_addr_t *) (address ?: local)
+ if (*(const in_addr_t *) address
!= htonl (INADDR_LOOPBACK))
*seen_ipv4 = true;
}
- break;
-
- case AF_INET6:
- local = NULL;
- address = NULL;
- while (RTA_OK (rta, len))
- {
- switch (rta->rta_type)
- {
- case IFA_LOCAL:
- local = RTA_DATA (rta);
- break;
-
- case IFA_ADDRESS:
- address = RTA_DATA (rta);
- goto out_v6;
- }
-
- rta = RTA_NEXT (rta, len);
- }
-
- if (local != NULL)
+ else
{
- out_v6:
- if (!IN6_IS_ADDR_LOOPBACK (address ?: local))
+ if (!IN6_IS_ADDR_LOOPBACK (address))
*seen_ipv6 = true;
}
+ }
- if (ifam->ifa_flags & (IFA_F_DEPRECATED
- | IFA_F_TEMPORARY
- | IFA_F_HOMEADDRESS))
- {
- struct in6ailist *newp = alloca (sizeof (*newp));
- newp->info.flags = (((ifam->ifa_flags & IFA_F_DEPRECATED)
- ? in6ai_deprecated : 0)
- | ((ifam->ifa_flags
- & IFA_F_TEMPORARY)
- ? in6ai_temporary : 0)
- | ((ifam->ifa_flags
- & IFA_F_HOMEADDRESS)
- ? in6ai_homeaddress : 0));
- memcpy (newp->info.addr, address ?: local,
- sizeof (newp->info.addr));
- newp->next = in6ailist;
- in6ailist = newp;
- ++in6ailistlen;
- }
- break;
- default:
- /* Ignore. */
- break;
+ struct in6ailist *newp = alloca (sizeof (*newp));
+ newp->info.flags = (((ifam->ifa_flags
+ & (IFA_F_DEPRECATED
+ | IFA_F_OPTIMISTIC))
+ ? in6ai_deprecated : 0)
+ | ((ifam->ifa_flags
+ & IFA_F_HOMEADDRESS)
+ ? in6ai_homeaddress : 0));
+ newp->info.prefixlen = ifam->ifa_prefixlen;
+ newp->info.index = ifam->ifa_index;
+ if (ifam->ifa_family == AF_INET)
+ {
+ newp->info.addr[0] = 0;
+ newp->info.addr[1] = 0;
+ newp->info.addr[2] = htonl (0xffff);
+ newp->info.addr[3] = *(const in_addr_t *) address;
}
+ else
+ memcpy (newp->info.addr, address, sizeof (newp->info.addr));
+ newp->next = in6ailist;
+ in6ailist = newp;
+ ++in6ailistlen;
}
else if (nlmh->nlmsg_type == NLMSG_DONE)
/* We found the end, leave the loop. */
diff --git a/ports/sysdeps/unix/sysv/linux/arm/clone.S b/ports/sysdeps/unix/sysv/linux/arm/clone.S
index 6c8f8e8e2..cfd2e7ef7 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/clone.S
+++ b/ports/sysdeps/unix/sysv/linux/arm/clone.S
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996, 1997, 1998, 1999, 2002, 2005
+/* Copyright (C) 1996, 1997, 1998, 1999, 2002, 2005, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Pat Beirne <patb@corelcomputer.com>
@@ -100,7 +100,7 @@ ENTRY(__clone)
ldr pc, [sp], #8
@ and we are done, passing the return value through r0
- b PLTJMP(_exit)
+ b PLTJMP(HIDDEN_JUMPTARGET(_exit))
PSEUDO_END (__clone)
diff --git a/ports/sysdeps/unix/sysv/linux/arm/eabi/configure b/ports/sysdeps/unix/sysv/linux/arm/eabi/configure
index ab8304889..28fb9ef2d 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/eabi/configure
+++ b/ports/sysdeps/unix/sysv/linux/arm/eabi/configure
@@ -1,5 +1,5 @@
# This file is generated from configure.in by Autoconf. DO NOT EDIT!
# Local configure fragment for sysdeps/unix/sysv/linux/arm/eabi.
-arch_minimum_kernel=2.6.14
+arch_minimum_kernel=2.6.16
libc_cv_gcc_unwind_find_fde=no
diff --git a/ports/sysdeps/unix/sysv/linux/arm/eabi/configure.in b/ports/sysdeps/unix/sysv/linux/arm/eabi/configure.in
index 83aa8fccb..d1fb7f422 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/eabi/configure.in
+++ b/ports/sysdeps/unix/sysv/linux/arm/eabi/configure.in
@@ -1,5 +1,5 @@
GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
# Local configure fragment for sysdeps/unix/sysv/linux/arm/eabi.
-arch_minimum_kernel=2.6.14
+arch_minimum_kernel=2.6.16
libc_cv_gcc_unwind_find_fde=no
diff --git a/ports/sysdeps/unix/sysv/linux/arm/ioperm.c b/ports/sysdeps/unix/sysv/linux/arm/ioperm.c
index 65ec07733..8af1ea356 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/ioperm.c
+++ b/ports/sysdeps/unix/sysv/linux/arm/ioperm.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 1999, 2003, 2005 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 1999, 2003, 2005, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Phil Blundell, based on the Alpha version by
David Mosberger.
@@ -45,7 +45,6 @@
#include <sys/mman.h>
#include <linux/version.h>
-#include <asm/page.h>
#include <sys/sysctl.h>
#define PATH_ARM_SYSTYPE "/etc/arm_systype"
@@ -111,14 +110,14 @@ init_iosys (void)
static int ioshift_name[] = { CTL_BUS, BUS_ISA, BUS_ISA_PORT_SHIFT };
size_t len = sizeof(io.base);
- if (! sysctl (iobase_name, 3, &io.io_base, &len, NULL, 0)
- && ! sysctl (ioshift_name, 3, &io.shift, &len, NULL, 0))
+ if (! __sysctl (iobase_name, 3, &io.io_base, &len, NULL, 0)
+ && ! __sysctl (ioshift_name, 3, &io.shift, &len, NULL, 0))
{
io.initdone = 1;
return 0;
}
- n = readlink (PATH_ARM_SYSTYPE, systype, sizeof (systype) - 1);
+ n = __readlink (PATH_ARM_SYSTYPE, systype, sizeof (systype) - 1);
if (n > 0)
{
systype[n] = '\0';
@@ -145,7 +144,7 @@ init_iosys (void)
if (n == 1)
break;
else
- fgets (systype, 256, fp);
+ fgets_unlocked (systype, 256, fp);
}
fclose (fp);
@@ -196,7 +195,7 @@ _ioperm (unsigned long int from, unsigned long int num, int turn_on)
{
int fd;
- fd = open ("/dev/mem", O_RDWR);
+ fd = __open ("/dev/mem", O_RDWR);
if (fd < 0)
return -1;
@@ -204,7 +203,7 @@ _ioperm (unsigned long int from, unsigned long int num, int turn_on)
(unsigned long int) __mmap (0, MAX_PORT << io.shift,
PROT_READ | PROT_WRITE,
MAP_SHARED, fd, io.io_base);
- close (fd);
+ __close (fd);
if ((long) io.base == -1)
return -1;
}
diff --git a/ports/sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h b/ports/sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h
index 3fb2186d2..9c8077187 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h
+++ b/ports/sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h
@@ -73,6 +73,9 @@
# define DOCARGS_5 DOCARGS_4
# define UNDOCARGS_5 UNDOCARGS_4
+# define DOCARGS_6 DOCARGS_5
+# define UNDOCARGS_6 UNDOCARGS_5
+
# ifdef IS_IN_libpthread
# define CENABLE bl PLTJMP(__pthread_enable_asynccancel)
# define CDISABLE bl PLTJMP(__pthread_disable_asynccancel)
diff --git a/ports/sysdeps/unix/sysv/linux/hppa/Makefile b/ports/sysdeps/unix/sysv/linux/hppa/Makefile
new file mode 100644
index 000000000..4c3a1148c
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/hppa/Makefile
@@ -0,0 +1,5 @@
+# Used by *context() functions
+ifeq ($(subdir),stdlib)
+gen-as-const-headers += ucontext_i.sym
+endif
+
diff --git a/ports/sysdeps/unix/sysv/linux/hppa/bits/atomic.h b/ports/sysdeps/unix/sysv/linux/hppa/bits/atomic.h
index 92a309d59..2964732f4 100644
--- a/ports/sysdeps/unix/sysv/linux/hppa/bits/atomic.h
+++ b/ports/sysdeps/unix/sysv/linux/hppa/bits/atomic.h
@@ -51,34 +51,41 @@ typedef uintmax_t uatomic_max_t;
*addr = new;
return prev; */
-/* Use the kernel atomic light weight syscalls on hppa */
-#define LWS "0xb0"
-#define LWS_CAS "0"
-/* Note r31 is the link register */
-#define LWS_CLOBBER "r1", "r26", "r25", "r24", "r23", "r22", "r21", "r20", "r28", "r31", "memory"
-#define ASM_EAGAIN "11"
+/* Use the kernel atomic light weight syscalls on hppa. */
+#define _LWS "0xb0"
+#define _LWS_CAS "0"
+/* Note r31 is the link register. */
+#define _LWS_CLOBBER "r1", "r26", "r25", "r24", "r23", "r22", "r21", "r20", "r28", "r31", "memory"
+/* String constant for -EAGAIN. */
+#define _ASM_EAGAIN "-11"
+/* String constant for -EDEADLOCK. */
+#define _ASM_EDEADLOCK "-45"
#if __ASSUME_LWS_CAS
/* The only basic operation needed is compare and exchange. */
# define atomic_compare_and_exchange_val_acq(mem, newval, oldval) \
({ \
- volatile int lws_errno = EFAULT; \
- volatile int lws_ret = 0xdeadbeef; \
+ volatile int lws_errno; \
+ volatile int lws_ret; \
asm volatile( \
"0: \n\t" \
- "copy %3, %%r26 \n\t" \
- "copy %4, %%r25 \n\t" \
- "copy %5, %%r24 \n\t" \
- "ble " LWS "(%%sr2, %%r0) \n\t" \
- "ldi " LWS_CAS ", %%r20 \n\t" \
- "cmpib,=,n " ASM_EAGAIN ",%%r21,0b \n\t" \
+ "copy %2, %%r26 \n\t" \
+ "copy %3, %%r25 \n\t" \
+ "copy %4, %%r24 \n\t" \
+ "ble " _LWS "(%%sr2, %%r0) \n\t" \
+ "ldi " _LWS_CAS ", %%r20 \n\t" \
+ "ldi " _ASM_EAGAIN ", %%r24 \n\t" \
+ "cmpb,=,n %%r24, %%r21, 0b \n\t" \
+ "nop \n\t" \
+ "ldi " _ASM_EDEADLOCK ", %%r25 \n\t" \
+ "cmpb,=,n %%r25, %%r21, 0b \n\t" \
"nop \n\t" \
"stw %%r28, %0 \n\t" \
"sub %%r0, %%r21, %%r21 \n\t" \
"stw %%r21, %1 \n\t" \
- : "=m" (lws_ret), "=m" (lws_errno), "=m" (*mem) \
+ : "=m" (lws_ret), "=m" (lws_errno) \
: "r" (mem), "r" (oldval), "r" (newval) \
- : LWS_CLOBBER \
+ : _LWS_CLOBBER \
); \
\
if(lws_errno == EFAULT || lws_errno == ENOSYS) \
@@ -91,7 +98,7 @@ typedef uintmax_t uatomic_max_t;
({ \
int ret; \
ret = atomic_compare_and_exchange_val_acq(mem, newval, oldval); \
- /* Return 1 if it was already acquired */ \
+ /* Return 1 if it was already acquired. */ \
(ret != oldval); \
})
#else
diff --git a/ports/sysdeps/unix/sysv/linux/hppa/bits/shm.h b/ports/sysdeps/unix/sysv/linux/hppa/bits/shm.h
index a91f1f575..13efced9f 100644
--- a/ports/sysdeps/unix/sysv/linux/hppa/bits/shm.h
+++ b/ports/sysdeps/unix/sysv/linux/hppa/bits/shm.h
@@ -42,7 +42,7 @@
/* Type to count number of attaches. */
typedef unsigned long int shmatt_t;
-/* Data structure describing a set of semaphores. */
+/* Data structure describing a shared memory segment. */
struct shmid_ds
{
struct ipc_perm shm_perm; /* operation permission struct */
diff --git a/ports/sysdeps/unix/sysv/linux/hppa/getcontext.S b/ports/sysdeps/unix/sysv/linux/hppa/getcontext.S
new file mode 100644
index 000000000..f88fa03d9
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/hppa/getcontext.S
@@ -0,0 +1,163 @@
+/* Get current user context.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Helge Deller <deller@gmx.de>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+
+#include "ucontext_i.h"
+
+
+ /* Trampoline function. */
+ /* Can not use ENTRY(__getcontext_ret) here. */
+ .type __getcontext_ret, @function
+ .hidden __getcontext_ret
+__getcontext_ret:
+ .proc
+ .callinfo FRAME=0,NO_CALLS
+ copy %r23, %r3
+ copy %r24, %r4
+ copy %r25, %r5
+ copy %r26, %r6
+ bv 0(%r20)
+ copy %r0, %ret0
+ .procend
+ .size __getcontext_ret, .-__getcontext_ret
+
+
+ENTRY(__getcontext)
+ /* Save the registers. */
+ stw %r0, oR0(%r26)
+ stw %r1, oR1(%r26)
+ /* stw %r2, oR2(%r26) - used for trampoline. */
+ stw %r3, oR3(%r26)
+ stw %r4, oR4(%r26)
+ stw %r5, oR5(%r26)
+ stw %r6, oR6(%r26)
+ stw %r7, oR7(%r26)
+ stw %r8, oR8(%r26)
+ stw %r9, oR9(%r26)
+ stw %r10, oR10(%r26)
+ stw %r11, oR11(%r26)
+ stw %r12, oR12(%r26)
+ stw %r13, oR13(%r26)
+ stw %r14, oR14(%r26)
+ stw %r15, oR15(%r26)
+ stw %r16, oR16(%r26)
+ stw %r17, oR17(%r26)
+ stw %r18, oR18(%r26)
+ stw %r19, oR19(%r26)
+ /* stw %r20, oR20(%r26) - used for trampoline. */
+ stw %r21, oR21(%r26)
+ stw %r22, oR22(%r26)
+ /* stw %r23, oR23(%r26) - used for trampoline. */
+ /* stw %r24, oR24(%r26) - used for trampoline. */
+ /* stw %r25, oR25(%r26) - used for trampoline. */
+ /* stw %r26, oR26(%r26) - used for trampoline. */
+ stw %r27, oR27(%r26)
+ stw %r28, oR28(%r26)
+ stw %r29, oR29(%r26)
+ ldo -64(%sp), %r1 /* Calculate %sp in %r1. */
+ stw %r1, oR30(%r26) /* Save new %sp. */
+ stw %r31, oR31(%r26)
+
+ stw %r0, oUC_FLAGS(%r26)
+ /* stw %r0, oUC_LINK(%r26) - Do not overwrite. */
+ stw %r1, oSS_SP(%r26)
+ stw %r0, oSS_FLAGS(%r26)
+ stw %r0, oSS_SIZE(%r26)
+
+ stw %r0, oSC_FLAGS(%r26)
+
+ stw %r0, oIASQ0(%r26)
+ stw %r0, oIASQ1(%r26)
+ stw %r0, oIAOQ0(%r26)
+ stw %r0, oIAOQ1(%r26)
+ stw %r0, oSAR(%r26) /* used as flag in swapcontext(). */
+
+
+ /* Store floating-point regs. */
+ ldo oFPREGS0(%r26),%r1
+ fstds,ma %fr0, 8(%r1)
+ fstds,ma %fr1, 8(%r1)
+ fstds,ma %fr2, 8(%r1)
+ fstds,ma %fr3, 8(%r1)
+ fstds,ma %fr4, 8(%r1)
+ fstds,ma %fr5, 8(%r1)
+ fstds,ma %fr6, 8(%r1)
+ fstds,ma %fr7, 8(%r1)
+ fstds,ma %fr8, 8(%r1)
+ fstds,ma %fr9, 8(%r1)
+ fstds,ma %fr10, 8(%r1)
+ fstds,ma %fr11, 8(%r1)
+ fstds,ma %fr12, 8(%r1)
+ fstds,ma %fr13, 8(%r1)
+ fstds,ma %fr14, 8(%r1)
+ fstds,ma %fr15, 8(%r1)
+ fstds,ma %fr16, 8(%r1)
+ fstds,ma %fr17, 8(%r1)
+ fstds,ma %fr18, 8(%r1)
+ fstds,ma %fr19, 8(%r1)
+ fstds,ma %fr20, 8(%r1)
+ fstds,ma %fr21, 8(%r1)
+ fstds,ma %fr22, 8(%r1)
+ fstds,ma %fr23, 8(%r1)
+ fstds,ma %fr24, 8(%r1)
+ fstds,ma %fr25, 8(%r1)
+ fstds,ma %fr26, 8(%r1)
+ fstds,ma %fr27, 8(%r1)
+ fstds,ma %fr28, 8(%r1)
+ fstds,ma %fr29, 8(%r1)
+ fstds,ma %fr30, 8(%r1)
+ fstds %fr31, 0(%r1)
+
+ /* Prologue */
+ stwm %r4, 64(%r30)
+#ifdef PIC
+ stw %r19, -32(%r30)
+#endif
+
+ /* Set up the trampoline registers.
+ r20, r23, r24, r25, r26 and r2 are clobbered
+ by call to getcontext() anyway. Reuse them. */
+ stw %r2, oR20(%r26)
+ stw %r3, oR23(%r26)
+ stw %r4, oR24(%r26)
+ stw %r5, oR25(%r26)
+ stw %r6, oR26(%r26)
+ ldil L%__getcontext_ret, %r1
+ ldo R%__getcontext_ret(%r1), %r1
+ stw %r1, oR2(%r26)
+
+ /* Save the current signal mask. */
+ /* sigprocmask(SIG_BLOCK, NULL, &ucp->uc_sigmask); */
+ ldo oSIGMASK(%r26), %r24
+ copy %r0, %r25
+ bl sigprocmask, %r2
+ ldi SIG_BLOCK, %r26
+
+ /* Epilogue */
+ ldw -84(%r30), %r2
+#ifdef PIC
+ ldw -96(%r30), %r19
+#endif
+ bv %r0(%r2)
+ ldwm -64(%r30), %r4
+END(__getcontext)
+
+weak_alias (__getcontext, getcontext)
diff --git a/ports/sysdeps/unix/sysv/linux/hppa/makecontext.c b/ports/sysdeps/unix/sysv/linux/hppa/makecontext.c
new file mode 100644
index 000000000..69a18135d
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/hppa/makecontext.c
@@ -0,0 +1,79 @@
+/* Create new context.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Helge Deller <deller@gmx.de>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <libintl.h>
+#include <stdarg.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <sysdep.h>
+#include <ucontext.h>
+
+/* XXX: This implementation only handles integer arguments. */
+
+void
+__makecontext (ucontext_t *ucp, void (*func) (void), int argc, ...)
+{
+ unsigned int *sp;
+ va_list ap;
+ int i;
+
+ if (argc > 8)
+ {
+ fprintf (stderr, _("\
+makecontext: does not know how to handle more than 8 arguments\n"));
+ exit (-1);
+ }
+
+ /* Get stack pointer. */
+ sp = (unsigned int *) ucp->uc_stack.ss_sp;
+
+ /* Store address to jump to. */
+ ucp->uc_mcontext.sc_gr[2] = (unsigned long) func;
+
+ va_start (ap, argc);
+ /* Handle arguments. */
+ for (i = 0; i < argc; ++i)
+ switch (i)
+ {
+ case 0:
+ case 1:
+ case 2:
+ case 3:
+ ucp->uc_mcontext.sc_gr[26-i] = va_arg (ap, int);
+ break;
+ case 4:
+ case 5:
+ case 6:
+ case 7:
+ if (sizeof(unsigned long) == 4) {
+ /* 32bit: put arg7-arg4 on stack. */
+ sp[7-i] = va_arg (ap, int);
+ } else {
+ /* 64bit: r19-r22 are arg7-arg4. */
+ ucp->uc_mcontext.sc_gr[22+4-i] = va_arg (ap, int);
+ }
+ break;
+ }
+ va_end (ap);
+
+}
+
+
+weak_alias(__makecontext, makecontext)
diff --git a/ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h b/ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h
index ec907aefb..6998a91b6 100644
--- a/ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h
+++ b/ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h
@@ -325,12 +325,12 @@ extern int lll_unlock_wake_cb (lll_lock_t *__futex) attribute_hidden;
thread ID while the clone is running and is reset to zero
afterwards. */
#define lll_wait_tid(tid) \
- do \
- { \
- __typeof (tid) __tid; \
- while ((__tid = (tid)) != 0) \
- lll_futex_wait (&(tid), __tid, 0); \
- } \
+ do \
+ { \
+ __typeof (tid) __tid; \
+ while ((__tid = (tid)) != 0) \
+ lll_futex_wait (&(tid), __tid, LLL_SHARED); \
+ } \
while (0)
extern int __lll_timedwait_tid (int *, const struct timespec *)
diff --git a/ports/sysdeps/unix/sysv/linux/hppa/setcontext.S b/ports/sysdeps/unix/sysv/linux/hppa/setcontext.S
new file mode 100644
index 000000000..43ccf24d2
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/hppa/setcontext.S
@@ -0,0 +1,154 @@
+/* Install given context.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Helge Deller <deller@gmx.de>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <sysdep.h>
+
+#include "ucontext_i.h"
+
+
+ENTRY(__setcontext)
+ /* Prologue */
+ stwm %r3, 64(%r30)
+#ifdef PIC
+ stw %r19, -32(%r30)
+#endif
+
+ /* Save ucp. */
+ copy %r26, %r3
+
+.Lagain:
+ /* Set the current signal mask. */
+ /* sigprocmask(SIG_BLOCK, &ucp->uc_sigmask, NULL); */
+ copy %r0, %r24
+ ldo oSIGMASK(%r3), %r25
+ bl sigprocmask, %r2
+ ldi SIG_SETMASK, %r26
+
+ comib,<>,n 0,%ret0,.Lerror
+
+ /* Save %sp, %dp. */
+ copy %sp, %r4
+ copy %dp, %r5
+ copy %r19, %r6
+
+ /* Get the registers. */
+ ldw oR1(%r3), %r1
+ ldw oR2(%r3), %r2
+ /* ldw oR3(%r3), %r3 - used for ucp pointer. */
+ /* ldw oR4(%r3), %r4 - used for original %sp. */
+ /* ldw oR5(%r3), %r5 - used for %dp / %r27. */
+ /* ldw oR6(%r3), %r6 - used for %r19. */
+ ldw oR7(%r3), %r7
+ ldw oR8(%r3), %r8
+ ldw oR9(%r3), %r9
+ ldw oR10(%r3), %r10
+ ldw oR11(%r3), %r11
+ ldw oR12(%r3), %r12
+ ldw oR13(%r3), %r13
+ ldw oR14(%r3), %r14
+ ldw oR15(%r3), %r15
+ ldw oR16(%r3), %r16
+ ldw oR17(%r3), %r17
+ ldw oR18(%r3), %r18
+ ldw oR19(%r3), %r19
+ ldw oR20(%r3), %r20
+ ldw oR21(%r3), %r21
+ /* ldw oR22(%r3), %r22 - dyncall arg. */
+ ldw oR23(%r3), %r23
+ ldw oR24(%r3), %r24
+ ldw oR25(%r3), %r25
+ ldw oR26(%r3), %r26
+ ldw oR27(%r3), %r27
+ ldw oR28(%r3), %r28
+ ldw oR29(%r3), %r29
+ ldw oR30(%r3), %r30
+ /* ldw oR31(%r3), %r31 - dyncall scratch register */
+
+ /* Restore floating-point registers. */
+ ldo oFPREGS31(%r3), %r22
+ fldds 0(%r22), %fr31
+ fldds,mb -8(%r22), %fr30
+ fldds,mb -8(%r22), %fr29
+ fldds,mb -8(%r22), %fr28
+ fldds,mb -8(%r22), %fr27
+ fldds,mb -8(%r22), %fr26
+ fldds,mb -8(%r22), %fr25
+ fldds,mb -8(%r22), %fr24
+ fldds,mb -8(%r22), %fr23
+ fldds,mb -8(%r22), %fr22
+ fldds,mb -8(%r22), %fr21
+ fldds,mb -8(%r22), %fr20
+ fldds,mb -8(%r22), %fr19
+ fldds,mb -8(%r22), %fr18
+ fldds,mb -8(%r22), %fr17
+ fldds,mb -8(%r22), %fr16
+ fldds,mb -8(%r22), %fr15
+ fldds,mb -8(%r22), %fr14
+ fldds,mb -8(%r22), %fr13
+ fldds,mb -8(%r22), %fr12
+ fldds,mb -8(%r22), %fr11
+ fldds,mb -8(%r22), %fr10
+ fldds,mb -8(%r22), %fr9
+ fldds,mb -8(%r22), %fr8
+ fldds,mb -8(%r22), %fr7
+ fldds,mb -8(%r22), %fr6
+ fldds,mb -8(%r22), %fr5
+ fldds,mb -8(%r22), %fr4
+ fldds,mb -8(%r22), %fr3
+ fldds,mb -8(%r22), %fr2
+ fldds,mb -8(%r22), %fr1
+ fldds,mb -8(%r22), %fr0
+
+ /* Calculate new stack pointer. */
+ ldw oSS_SP(%r3), %sp
+ ldo 64(%sp), %sp
+
+ /* Call external function. */
+ copy %r2, %r22
+ bl $$dyncall, %r31
+ copy %r31, %r2
+
+ /* We return here. Get new ucp in %r3, reload %sp. */
+ ldw oUC_LINK(%r3), %r3
+ copy %r4, %sp
+ copy %r5, %dp
+ copy %r6, %r19
+
+ /* Continue until ucp == NULL. */
+ comib,<> 0,%r3,.Lagain
+ nop
+
+ /* No further context available. Exit now. */
+ bl _exit, %r2
+ ldi -1, %r26
+
+
+.Lerror:
+ /* Epilogue */
+ ldw -84(%r30), %r2
+#ifdef PIC
+ ldw -96(%r30), %r19
+#endif
+ bv %r0(%r2)
+ ldwm -64(%r30), %r3
+L(pseudo_end):
+PSEUDO_END(__setcontext)
+
+weak_alias(__setcontext, setcontext)
diff --git a/ports/sysdeps/unix/sysv/linux/hppa/swapcontext.c b/ports/sysdeps/unix/sysv/linux/hppa/swapcontext.c
new file mode 100644
index 000000000..8b33173be
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/hppa/swapcontext.c
@@ -0,0 +1,43 @@
+/* Swap to new context.
+ Copyright (C) 2008 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+ Contributed by Helge Deller <deller@gmx.de>, 2008.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#include <ucontext.h>
+
+extern int __getcontext (ucontext_t *ucp);
+extern int __setcontext (const ucontext_t *ucp);
+
+int
+__swapcontext (ucontext_t *oucp, const ucontext_t *ucp)
+{
+ /* Save the current machine context to oucp. */
+ __getcontext (oucp);
+
+ /* mark sc_sar flag to skip the setcontext call on reactivation. */
+ if (oucp->uc_mcontext.sc_sar == 0) {
+ oucp->uc_mcontext.sc_sar++;
+
+ /* Restore the machine context in ucp. */
+ __setcontext (ucp);
+ }
+
+ return 0;
+}
+
+weak_alias (__swapcontext, swapcontext)
diff --git a/ports/sysdeps/unix/sysv/linux/hppa/ucontext_i.sym b/ports/sysdeps/unix/sysv/linux/hppa/ucontext_i.sym
new file mode 100644
index 000000000..ee33029a0
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/hppa/ucontext_i.sym
@@ -0,0 +1,59 @@
+#include <stddef.h>
+#include <signal.h>
+#include <sys/ucontext.h>
+
+--
+
+SIG_BLOCK
+SIG_SETMASK
+
+#define ucontext(member) offsetof (ucontext_t, member)
+#define mcontext(member) ucontext (uc_mcontext.member)
+#define mreg(reg) mcontext (sc_gr[reg])
+
+oUC_FLAGS ucontext (uc_flags)
+oUC_LINK ucontext (uc_link)
+oSS_SP ucontext (uc_stack.ss_sp)
+oSS_FLAGS ucontext (uc_stack.ss_flags)
+oSS_SIZE ucontext (uc_stack.ss_size)
+oSC_FLAGS mcontext (sc_flags)
+oR0 mreg (0)
+oR1 mreg (1)
+oR2 mreg (2)
+oR3 mreg (3)
+oR4 mreg (4)
+oR5 mreg (5)
+oR6 mreg (6)
+oR7 mreg (7)
+oR8 mreg (8)
+oR9 mreg (9)
+oR10 mreg (10)
+oR11 mreg (11)
+oR12 mreg (12)
+oR13 mreg (13)
+oR14 mreg (14)
+oR15 mreg (15)
+oR16 mreg (16)
+oR17 mreg (17)
+oR18 mreg (18)
+oR19 mreg (19)
+oR20 mreg (20)
+oR21 mreg (21)
+oR22 mreg (22)
+oR23 mreg (23)
+oR24 mreg (24)
+oR25 mreg (25)
+oR26 mreg (26)
+oR27 mreg (27)
+oR28 mreg (28)
+oR29 mreg (29)
+oR30 mreg (30)
+oR31 mreg (31)
+oFPREGS0 mcontext (sc_fr[0])
+oFPREGS31 mcontext (sc_fr[31])
+oIASQ0 mcontext (sc_iasq[0])
+oIASQ1 mcontext (sc_iasq[1])
+oIAOQ0 mcontext (sc_iaoq[0])
+oIAOQ1 mcontext (sc_iaoq[1])
+oSAR mcontext (sc_sar)
+oSIGMASK ucontext (uc_sigmask)
diff --git a/ports/sysdeps/unix/sysv/linux/m68k/bits/fcntl.h b/ports/sysdeps/unix/sysv/linux/m68k/bits/fcntl.h
index 169a24b73..203d5a1a5 100644
--- a/ports/sysdeps/unix/sysv/linux/m68k/bits/fcntl.h
+++ b/ports/sysdeps/unix/sysv/linux/m68k/bits/fcntl.h
@@ -1,5 +1,5 @@
/* O_*, F_*, FD_* bit values for Linux.
- Copyright (C) 2000, 2004 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2004, 2008 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
@@ -21,8 +21,11 @@
# error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
#endif
-
#include <sys/types.h>
+#ifdef __USE_GNU
+# include <bits/uio.h>
+#endif
+
/* open/fcntl - O_SYNC is only implemented on blocks devices and on files
located on an ext2 file system */
@@ -46,6 +49,7 @@
# define O_NOFOLLOW 0100000 /* Do not follow links. */
# define O_DIRECT 0200000 /* Direct disk access. */
# define O_NOATIME 01000000 /* Do not set atime. */
+# define O_CLOEXEC 02000000 /* Set close_on_exec. */
#endif
/* For now Linux has synchronisity options for data and read operations.
@@ -181,10 +185,55 @@ struct flock64
# define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
#endif
+
+#ifdef __USE_GNU
+/* Flags for SYNC_FILE_RANGE. */
+# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
+ in the range before performing the
+ write. */
+# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
+ dirty pages in the range which are
+ not presently under writeback. */
+# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
+ the range after performing the
+ write. */
+
+/* Flags for SPLICE and VMSPLICE. */
+# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
+# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
+ (but we may still block on the fd
+ we splice from/to). */
+# define SPLICE_F_MORE 4 /* Expect more data. */
+# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
+#endif
+
__BEGIN_DECLS
+#ifdef __USE_GNU
+
/* Provide kernel hint to read ahead. */
extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
__THROW;
+
+/* Selective file content synch'ing. */
+extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
+ unsigned int __flags);
+
+
+/* Splice address range into a pipe. */
+extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
+ size_t __count, unsigned int __flags);
+
+/* Splice two files together. */
+extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
+ __off64_t *__offout, size_t __len,
+ unsigned int __flags);
+
+/* In-kernel implementation of tee for pipe buffers. */
+extern ssize_t tee (int __fdin, int __fdout, size_t __len,
+ unsigned int __flags);
+
+#endif
+
__END_DECLS
diff --git a/ports/sysdeps/unix/sysv/linux/m68k/bits/mman.h b/ports/sysdeps/unix/sysv/linux/m68k/bits/mman.h
index fbec1a03f..ab9917666 100644
--- a/ports/sysdeps/unix/sysv/linux/m68k/bits/mman.h
+++ b/ports/sysdeps/unix/sysv/linux/m68k/bits/mman.h
@@ -1,5 +1,5 @@
/* Definitions for POSIX memory map interface. Linux/m68k version.
- Copyright (C) 1997, 2000, 2003, 2005 Free Software Foundation, Inc.
+ Copyright (C) 1997, 2000, 2003, 2005, 2008 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
@@ -88,6 +88,7 @@
# define MADV_SEQUENTIAL 2 /* Expect sequential page references. */
# define MADV_WILLNEED 3 /* Will need these pages. */
# define MADV_DONTNEED 4 /* Don't need these pages. */
+# define MADV_REMOVE 9 /* Remove these pages and resources. */
# define MADV_DONTFORK 10 /* Do not inherit across fork. */
# define MADV_DOFORK 11 /* Do inherit across fork. */
#endif
diff --git a/ports/sysdeps/unix/sysv/linux/m68k/bits/poll.h b/ports/sysdeps/unix/sysv/linux/m68k/bits/poll.h
index f7a739315..bc285799e 100644
--- a/ports/sysdeps/unix/sysv/linux/m68k/bits/poll.h
+++ b/ports/sysdeps/unix/sysv/linux/m68k/bits/poll.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997, 2001 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 2001, 2008 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
@@ -35,6 +35,13 @@
# define POLLWRBAND 0x100 /* Priority data may be written. */
#endif
+#ifdef __USE_GNU
+/* These are extensions for Linux. */
+# define POLLMSG 0x400
+# define POLLREMOVE 0x1000
+# define POLLRDHUP 0x2000
+#endif
+
/* Event types always implicitly polled for. These bits need not be set in
`events', but they will appear in `revents' to indicate the status of
the file descriptor. */
diff --git a/ports/sysdeps/unix/sysv/linux/m68k/bits/stat.h b/ports/sysdeps/unix/sysv/linux/m68k/bits/stat.h
index dc06b13e2..6b6924037 100644
--- a/ports/sysdeps/unix/sysv/linux/m68k/bits/stat.h
+++ b/ports/sysdeps/unix/sysv/linux/m68k/bits/stat.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992,95,96,97,98,99,2000,2001,2002
+/* Copyright (C) 1992,95,96,97,98,99,2000,2001,2002,2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -162,3 +162,9 @@ struct stat64
#define __S_IREAD 0400 /* Read by owner. */
#define __S_IWRITE 0200 /* Write by owner. */
#define __S_IEXEC 0100 /* Execute by owner. */
+
+#if defined __USE_ATFILE || defined __USE_GNU
+/* XXX This will change to the macro for the next 2008 POSIX revision. */
+# define UTIME_NOW ((1l << 30) - 1l)
+# define UTIME_OMIT ((1l << 30) - 2l)
+#endif
diff --git a/ports/sysdeps/unix/sysv/linux/m68k/kernel-features.h b/ports/sysdeps/unix/sysv/linux/m68k/kernel-features.h
new file mode 100644
index 000000000..9a6d23d3e
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/m68k/kernel-features.h
@@ -0,0 +1,41 @@
+/* Set flags signalling availability of kernel features based on given
+ kernel version number.
+ Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+/* These features were surely available with 2.4.12. */
+#if __LINUX_KERNEL_VERSION >= 132108
+# define __ASSUME_MMAP2_SYSCALL 1
+# define __ASSUME_TRUNCATE64_SYSCALL 1
+# define __ASSUME_STAT64_SYSCALL 1
+# define __ASSUME_FCNTL64 1
+# define __ASSUME_VFORK_SYSCALL 1
+#endif
+
+/* Many syscalls were added in 2.6.10 for m68k. */
+#if __LINUX_KERNEL_VERSION >= 132618
+# define __ASSUME_TGKILL 1
+# define __ASSUME_UTIMES 1
+# define __ASSUME_FADVISE64_64_SYSCALL 1
+#endif
+
+#include_next <kernel-features.h>
+
+/* These syscalls are not implemented yet for m68k. */
+#undef __ASSUME_PSELECT
+#undef __ASSUME_PPOLL
diff --git a/ports/sysdeps/unix/sysv/linux/m68k/sys/user.h b/ports/sysdeps/unix/sysv/linux/m68k/sys/user.h
new file mode 100644
index 000000000..f8b19fcbe
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/m68k/sys/user.h
@@ -0,0 +1,61 @@
+/* Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_USER_H
+#define _SYS_USER_H 1
+
+/* The whole purpose of this file is for GDB and GDB only. Don't read
+ too much into it. Don't use it for anything other than GDB unless
+ you know what you are doing. */
+
+struct user_m68kfp_struct {
+ unsigned long fpregs[8*3];
+ unsigned long fpcntl[3];
+};
+
+struct user_regs_struct {
+ long d1, d2, d3, d4, d5, d6, d7;
+ long a0, a1, a2, a3, a4, a5, a6;
+ long d0;
+ long usp;
+ long orig_d0;
+ short stkadj;
+ short sr;
+ long pc;
+ short fmtvec;
+ short __fill;
+};
+
+struct user {
+ struct user_regs_struct regs;
+ int u_fpvalid;
+ struct user_m68kfp_struct m68kfp;
+ unsigned long int u_tsize;
+ unsigned long int u_dsize;
+ unsigned long int u_ssize;
+ unsigned long start_code;
+ unsigned long start_stack;
+ long int signal;
+ int reserved;
+ unsigned long u_ar0;
+ struct user_m68kfp_struct *u_fpstate;
+ unsigned long magic;
+ char u_comm[32];
+};
+
+#endif
diff --git a/ports/sysdeps/unix/sysv/linux/mips/bits/resource.h b/ports/sysdeps/unix/sysv/linux/mips/bits/resource.h
index 1c8b99a93..3cfdc5dbe 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/bits/resource.h
+++ b/ports/sysdeps/unix/sysv/linux/mips/bits/resource.h
@@ -166,8 +166,16 @@ enum __rusage_who
#define RUSAGE_SELF RUSAGE_SELF
/* All of its terminated child processes. */
- RUSAGE_CHILDREN = -1
+ RUSAGE_CHILDREN = -1,
#define RUSAGE_CHILDREN RUSAGE_CHILDREN
+
+#ifdef __USE_GNU
+ /* The calling thread. */
+ RUSAGE_THREAD = 1
+# define RUSAGE_THREAD RUSAGE_THREAD
+ /* Name for the same functionality on Solaris. */
+# define RUSAGE_LWP RUSAGE_THREAD
+#endif
};
#define __need_timeval
diff --git a/ports/sysdeps/unix/sysv/linux/mips/bits/shm.h b/ports/sysdeps/unix/sysv/linux/mips/bits/shm.h
index b3083346d..037980cfa 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/bits/shm.h
+++ b/ports/sysdeps/unix/sysv/linux/mips/bits/shm.h
@@ -42,7 +42,7 @@
/* Type to count number of attaches. */
typedef unsigned long int shmatt_t;
-/* Data structure describing a set of semaphores. */
+/* Data structure describing a shared memory segment. */
struct shmid_ds
{
struct ipc_perm shm_perm; /* operation permission struct */
diff --git a/ports/sysdeps/unix/sysv/linux/mips/bits/socket.h b/ports/sysdeps/unix/sysv/linux/mips/bits/socket.h
index 8748c0a04..4f219d5af 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/bits/socket.h
+++ b/ports/sysdeps/unix/sysv/linux/mips/bits/socket.h
@@ -1,5 +1,5 @@
/* System-specific socket constants and types. Linux/MIPS version.
- Copyright (C) 1991, 92, 1994-1999, 2000, 2001, 2004, 2005, 2006, 2007
+ Copyright (C) 1991, 92, 1994-1999, 2000, 2001, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -26,10 +26,8 @@
#endif
#define __need_size_t
-#define __need_NULL
#include <stddef.h>
-#include <limits.h>
#include <sys/types.h>
/* Type for length arguments in socket calls. */
@@ -54,10 +52,22 @@ enum __socket_type
SOCK_SEQPACKET = 5, /* Sequenced, reliable, connection-based,
datagrams of fixed maximum length. */
#define SOCK_SEQPACKET SOCK_SEQPACKET
- SOCK_PACKET = 10 /* Linux specific way of getting packets
+ SOCK_DCCP = 6,
+#define SOCK_DCCP SOCK_DCCP /* Datagram Congestion Control Protocol. */
+ SOCK_PACKET = 10, /* Linux specific way of getting packets
at the dev level. For writing rarp and
other similar things on the user level. */
#define SOCK_PACKET SOCK_PACKET
+
+ /* Flags to be ORed into the type parameter of socket and socketpair and
+ used for the flags parameter of paccept. */
+
+ SOCK_CLOEXEC = 02000000, /* Atomically set close-on-exec flag for the
+ new descriptor(s). */
+#define SOCK_CLOEXEC SOCK_CLOEXEC
+ SOCK_NONBLOCK = 0200 /* Atomically mark descriptor(s) as
+ non-blocking. */
+#define SOCK_NONBLOCK SOCK_NONBLOCK
};
/* Protocol families. */
@@ -92,7 +102,8 @@ enum __socket_type
#define PF_BLUETOOTH 31 /* Bluetooth sockets. */
#define PF_IUCV 32 /* IUCV sockets. */
#define PF_RXRPC 33 /* RxRPC sockets. */
-#define PF_MAX 34 /* For now.. */
+#define PF_ISDN 34 /* mISDN sockets. */
+#define PF_MAX 35 /* For now.. */
/* Address families. */
#define AF_UNSPEC PF_UNSPEC
@@ -126,6 +137,7 @@ enum __socket_type
#define AF_BLUETOOTH PF_BLUETOOTH
#define AF_IUCV PF_IUCV
#define AF_RXRPC PF_RXRPC
+#define AF_ISDN PF_ISDN
#define AF_MAX PF_MAX
/* Socket level values. Others are defined in the appropriate headers.
@@ -156,11 +168,7 @@ struct sockaddr
/* Structure large enough to hold any socket address (with the historical
exception of AF_UNIX). We reserve 128 bytes. */
-#if ULONG_MAX > 0xffffffff
-# define __ss_aligntype __uint64_t
-#else
-# define __ss_aligntype __uint32_t
-#endif
+#define __ss_aligntype unsigned long int
#define _SS_SIZE 128
#define _SS_PADSIZE (_SS_SIZE - (2 * sizeof (__ss_aligntype)))
@@ -257,7 +265,7 @@ struct cmsghdr
#define CMSG_NXTHDR(mhdr, cmsg) __cmsg_nxthdr (mhdr, cmsg)
#define CMSG_FIRSTHDR(mhdr) \
((size_t) (mhdr)->msg_controllen >= sizeof (struct cmsghdr) \
- ? (struct cmsghdr *) (mhdr)->msg_control : (struct cmsghdr *) NULL)
+ ? (struct cmsghdr *) (mhdr)->msg_control : (struct cmsghdr *) 0)
#define CMSG_ALIGN(len) (((len) + sizeof (size_t) - 1) \
& (size_t) ~(sizeof (size_t) - 1))
#define CMSG_SPACE(len) (CMSG_ALIGN (len) \
@@ -301,18 +309,74 @@ enum
#endif
};
+#ifdef __USE_GNU
/* User visible structure for SCM_CREDENTIALS message */
-
struct ucred
{
pid_t pid; /* PID of sending process. */
uid_t uid; /* UID of sending process. */
gid_t gid; /* GID of sending process. */
};
+#endif
+
+/* Ugly workaround for unclean kernel headers. */
+#if !defined __USE_MISC && !defined __USE_GNU
+# ifndef FIOGETOWN
+# define __SYS_SOCKET_H_undef_FIOGETOWN
+# endif
+# ifndef FIOSETOWN
+# define __SYS_SOCKET_H_undef_FIOSETOWN
+# endif
+# ifndef SIOCATMARK
+# define __SYS_SOCKET_H_undef_SIOCATMARK
+# endif
+# ifndef SIOCGPGRP
+# define __SYS_SOCKET_H_undef_SIOCGPGRP
+# endif
+# ifndef SIOCGSTAMP
+# define __SYS_SOCKET_H_undef_SIOCGSTAMP
+# endif
+# ifndef SIOCGSTAMPNS
+# define __SYS_SOCKET_H_undef_SIOCGSTAMPNS
+# endif
+# ifndef SIOCSPGRP
+# define __SYS_SOCKET_H_undef_SIOCSPGRP
+# endif
+#endif
/* Get socket manipulation related informations from kernel headers. */
#include <asm/socket.h>
+#if !defined __USE_MISC && !defined __USE_GNU
+# ifdef __SYS_SOCKET_H_undef_FIOGETOWN
+# undef __SYS_SOCKET_H_undef_FIOGETOWN
+# undef FIOGETOWN
+# endif
+# ifdef __SYS_SOCKET_H_undef_FIOSETOWN
+# undef __SYS_SOCKET_H_undef_FIOSETOWN
+# undef FIOSETOWN
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCATMARK
+# undef __SYS_SOCKET_H_undef_SIOCATMARK
+# undef SIOCATMARK
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCGPGRP
+# undef __SYS_SOCKET_H_undef_SIOCGPGRP
+# undef SIOCGPGRP
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCGSTAMP
+# undef __SYS_SOCKET_H_undef_SIOCGSTAMP
+# undef SIOCGSTAMP
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCGSTAMPNS
+# undef __SYS_SOCKET_H_undef_SIOCGSTAMPNS
+# undef SIOCGSTAMPNS
+# endif
+# ifdef __SYS_SOCKET_H_undef_SIOCSPGRP
+# undef __SYS_SOCKET_H_undef_SIOCSPGRP
+# undef SIOCSPGRP
+# endif
+#endif
/* Structure used to manipulate the SO_LINGER option. */
struct linger
diff --git a/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c b/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c
index 42efcba31..6e25b021a 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c
+++ b/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c
@@ -1,28 +1 @@
-/* Copyright (C) 2003 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 Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 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
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, write to the Free
- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
- 02111-1307 USA. */
-
-#include <sys/types.h>
-
-#include <sysdep.h>
-
-extern int ftruncate (int fd, off64_t length);
-
-int __ftruncate64 (int fd, off64_t length) {
- return ftruncate (fd, length);
-}
-weak_alias (__ftruncate64, ftruncate64)
+/* Empty. */
diff --git a/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list b/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list
index babdba0ca..2e4bed090 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list
+++ b/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list
@@ -3,3 +3,5 @@
readahead - readahead i:iii __readahead readahead
sync_file_range - sync_file_range i:iiii sync_file_range
posix_fadvise - fadvise64 i:iiii posix_fadvise
+ftruncate - ftruncate i:ii __ftruncate ftruncate ftruncate64 __ftruncate64
+truncate - truncate i:si truncate truncate64
diff --git a/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c b/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c
index 339023f14..6e25b021a 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c
+++ b/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c
@@ -1,30 +1 @@
-/* Copyright (C) 2003 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 Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 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
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, write to the Free
- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
- 02111-1307 USA. */
-
-#include <sys/types.h>
-
-#include <sysdep.h>
-#include <bp-checks.h>
-
-extern int truncate (const char *__unbounded path, int dummy,
- off64_t length);
-
-int truncate64 (const char *__unbounded path, int dummy,
- off64_t length) {
- return truncate (path, dummy, length);
-}
+/* Empty. */
diff --git a/ports/sysdeps/unix/sysv/linux/mips/sys/epoll.h b/ports/sysdeps/unix/sysv/linux/mips/sys/epoll.h
new file mode 100644
index 000000000..6d2ec8edf
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/mips/sys/epoll.h
@@ -0,0 +1,144 @@
+/* Copyright (C) 2002-2006, 2007, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_EPOLL_H
+#define _SYS_EPOLL_H 1
+
+#include <stdint.h>
+#include <sys/types.h>
+
+/* Get __sigset_t. */
+#include <bits/sigset.h>
+
+#ifndef __sigset_t_defined
+# define __sigset_t_defined
+typedef __sigset_t sigset_t;
+#endif
+
+
+/* Flags to be passed to epoll_create1. */
+enum
+ {
+ EPOLL_CLOEXEC = 02000000,
+#define EPOLL_CLOEXEC EPOLL_CLOEXEC
+ EPOLL_NONBLOCK = 0200
+#define EPOLL_NONBLOCK EPOLL_NONBLOCK
+ };
+
+
+enum EPOLL_EVENTS
+ {
+ EPOLLIN = 0x001,
+#define EPOLLIN EPOLLIN
+ EPOLLPRI = 0x002,
+#define EPOLLPRI EPOLLPRI
+ EPOLLOUT = 0x004,
+#define EPOLLOUT EPOLLOUT
+ EPOLLRDNORM = 0x040,
+#define EPOLLRDNORM EPOLLRDNORM
+ EPOLLRDBAND = 0x080,
+#define EPOLLRDBAND EPOLLRDBAND
+ EPOLLWRNORM = 0x100,
+#define EPOLLWRNORM EPOLLWRNORM
+ EPOLLWRBAND = 0x200,
+#define EPOLLWRBAND EPOLLWRBAND
+ EPOLLMSG = 0x400,
+#define EPOLLMSG EPOLLMSG
+ EPOLLERR = 0x008,
+#define EPOLLERR EPOLLERR
+ EPOLLHUP = 0x010,
+#define EPOLLHUP EPOLLHUP
+ EPOLLRDHUP = 0x2000,
+#define EPOLLRDHUP EPOLLRDHUP
+ EPOLLONESHOT = (1 << 30),
+#define EPOLLONESHOT EPOLLONESHOT
+ EPOLLET = (1 << 31)
+#define EPOLLET EPOLLET
+ };
+
+
+/* Valid opcodes ( "op" parameter ) to issue to epoll_ctl(). */
+#define EPOLL_CTL_ADD 1 /* Add a file descriptor to the interface. */
+#define EPOLL_CTL_DEL 2 /* Remove a file descriptor from the interface. */
+#define EPOLL_CTL_MOD 3 /* Change file descriptor epoll_event structure. */
+
+
+typedef union epoll_data
+{
+ void *ptr;
+ int fd;
+ uint32_t u32;
+ uint64_t u64;
+} epoll_data_t;
+
+struct epoll_event
+{
+ uint32_t events; /* Epoll events */
+ epoll_data_t data; /* User data variable */
+};
+
+
+__BEGIN_DECLS
+
+/* Creates an epoll instance. Returns an fd for the new instance.
+ The "size" parameter is a hint specifying the number of file
+ descriptors to be associated with the new instance. The fd
+ returned by epoll_create() should be closed with close(). */
+extern int epoll_create (int __size) __THROW;
+
+/* Same as epoll_create but with an FLAGS parameter. The unused SIZE
+ parameter has been dropped. */
+extern int epoll_create1 (int __flags) __THROW;
+
+
+/* Manipulate an epoll instance "epfd". Returns 0 in case of success,
+ -1 in case of error ( the "errno" variable will contain the
+ specific error code ) The "op" parameter is one of the EPOLL_CTL_*
+ constants defined above. The "fd" parameter is the target of the
+ operation. The "event" parameter describes which events the caller
+ is interested in and any associated user data. */
+extern int epoll_ctl (int __epfd, int __op, int __fd,
+ struct epoll_event *__event) __THROW;
+
+
+/* Wait for events on an epoll instance "epfd". Returns the number of
+ triggered events returned in "events" buffer. Or -1 in case of
+ error with the "errno" variable set to the specific error code. The
+ "events" parameter is a buffer that will contain triggered
+ events. The "maxevents" is the maximum number of events to be
+ returned ( usually size of "events" ). The "timeout" parameter
+ specifies the maximum wait time in milliseconds (-1 == infinite).
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern int epoll_wait (int __epfd, struct epoll_event *__events,
+ int __maxevents, int __timeout);
+
+
+/* Same as epoll_wait, but the thread's signal mask is temporarily
+ and atomically replaced with the one provided as parameter.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern int epoll_pwait (int __epfd, struct epoll_event *__events,
+ int __maxevents, int __timeout,
+ __const __sigset_t *__ss);
+
+__END_DECLS
+
+#endif /* sys/epoll.h */
diff --git a/ports/sysdeps/unix/sysv/linux/mips/sys/eventfd.h b/ports/sysdeps/unix/sysv/linux/mips/sys/eventfd.h
new file mode 100644
index 000000000..fa34c8cec
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/mips/sys/eventfd.h
@@ -0,0 +1,52 @@
+/* Copyright (C) 2007, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_EVENTFD_H
+#define _SYS_EVENTFD_H 1
+
+#include <stdint.h>
+
+
+/* Type for event counter. */
+typedef uint64_t eventfd_t;
+
+/* Flags for signalfd. */
+enum
+ {
+ EFD_CLOEXEC = 02000000,
+#define EFD_CLOEXEC EFD_CLOEXEC
+ EFD_NONBLOCK = 0200
+#define EFD_NONBLOCK EFD_NONBLOCK
+ };
+
+
+__BEGIN_DECLS
+
+/* Return file descriptor for generic event channel. Set initial
+ value to COUNT. */
+extern int eventfd (int __count, int __flags) __THROW;
+
+/* Read event counter and possibly wait for events. */
+extern int eventfd_read (int __fd, eventfd_t *__value);
+
+/* Increment event counter. */
+extern int eventfd_write (int __fd, eventfd_t value);
+
+__END_DECLS
+
+#endif /* sys/eventfd.h */
diff --git a/ports/sysdeps/unix/sysv/linux/mips/sys/inotify.h b/ports/sysdeps/unix/sysv/linux/mips/sys/inotify.h
new file mode 100644
index 000000000..a811c7fc3
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/mips/sys/inotify.h
@@ -0,0 +1,105 @@
+/* Copyright (C) 2005, 2006, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_INOTIFY_H
+#define _SYS_INOTIFY_H 1
+
+#include <stdint.h>
+
+
+/* Flags for the parameter of inotify_init1. */
+enum
+ {
+ IN_CLOEXEC = 02000000,
+#define IN_CLOEXEC IN_CLOEXEC
+ IN_NONBLOCK = 0200
+#define IN_NONBLOCK IN_NONBLOCK
+ };
+
+
+/* Structure describing an inotify event. */
+struct inotify_event
+{
+ int wd; /* Watch descriptor. */
+ uint32_t mask; /* Watch mask. */
+ uint32_t cookie; /* Cookie to synchronize two events. */
+ uint32_t len; /* Length (including NULs) of name. */
+ char name __flexarr; /* Name. */
+};
+
+
+/* Supported events suitable for MASK parameter of INOTIFY_ADD_WATCH. */
+#define IN_ACCESS 0x00000001 /* File was accessed. */
+#define IN_MODIFY 0x00000002 /* File was modified. */
+#define IN_ATTRIB 0x00000004 /* Metadata changed. */
+#define IN_CLOSE_WRITE 0x00000008 /* Writtable file was closed. */
+#define IN_CLOSE_NOWRITE 0x00000010 /* Unwrittable file closed. */
+#define IN_CLOSE (IN_CLOSE_WRITE | IN_CLOSE_NOWRITE) /* Close. */
+#define IN_OPEN 0x00000020 /* File was opened. */
+#define IN_MOVED_FROM 0x00000040 /* File was moved from X. */
+#define IN_MOVED_TO 0x00000080 /* File was moved to Y. */
+#define IN_MOVE (IN_MOVED_FROM | IN_MOVED_TO) /* Moves. */
+#define IN_CREATE 0x00000100 /* Subfile was created. */
+#define IN_DELETE 0x00000200 /* Subfile was deleted. */
+#define IN_DELETE_SELF 0x00000400 /* Self was deleted. */
+#define IN_MOVE_SELF 0x00000800 /* Self was moved. */
+
+/* Events sent by the kernel. */
+#define IN_UNMOUNT 0x00002000 /* Backing fs was unmounted. */
+#define IN_Q_OVERFLOW 0x00004000 /* Event queued overflowed. */
+#define IN_IGNORED 0x00008000 /* File was ignored. */
+
+/* Helper events. */
+#define IN_CLOSE (IN_CLOSE_WRITE | IN_CLOSE_NOWRITE) /* Close. */
+#define IN_MOVE (IN_MOVED_FROM | IN_MOVED_TO) /* Moves. */
+
+/* Special flags. */
+#define IN_ONLYDIR 0x01000000 /* Only watch the path if it is a
+ directory. */
+#define IN_DONT_FOLLOW 0x02000000 /* Do not follow a sym link. */
+#define IN_MASK_ADD 0x20000000 /* Add to the mask of an already
+ existing watch. */
+#define IN_ISDIR 0x40000000 /* Event occurred against dir. */
+#define IN_ONESHOT 0x80000000 /* Only send event once. */
+
+/* All events which a program can wait on. */
+#define IN_ALL_EVENTS (IN_ACCESS | IN_MODIFY | IN_ATTRIB | IN_CLOSE_WRITE \
+ | IN_CLOSE_NOWRITE | IN_OPEN | IN_MOVED_FROM \
+ | IN_MOVED_TO | IN_CREATE | IN_DELETE \
+ | IN_DELETE_SELF | IN_MOVE_SELF)
+
+
+__BEGIN_DECLS
+
+/* Create and initialize inotify instance. */
+extern int inotify_init (void) __THROW;
+
+/* Create and initialize inotify instance. */
+extern int inotify_init1 (int __flags) __THROW;
+
+/* Add watch of object NAME to inotify instance FD. Notify about
+ events specified by MASK. */
+extern int inotify_add_watch (int __fd, const char *__name, uint32_t __mask)
+ __THROW;
+
+/* Remove the watch specified by WD from the inotify instance FD. */
+extern int inotify_rm_watch (int __fd, uint32_t __wd) __THROW;
+
+__END_DECLS
+
+#endif /* sys/inotify.h */
diff --git a/ports/sysdeps/unix/sysv/linux/mips/sys/signalfd.h b/ports/sysdeps/unix/sysv/linux/mips/sys/signalfd.h
new file mode 100644
index 000000000..2fe7e379d
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/mips/sys/signalfd.h
@@ -0,0 +1,66 @@
+/* Copyright (C) 2007, 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_SIGNALFD_H
+#define _SYS_SIGNALFD_H 1
+
+#define __need_sigset_t
+#include <signal.h>
+#include <stdint.h>
+
+
+struct signalfd_siginfo
+{
+ uint32_t ssi_signo;
+ int32_t ssi_errno;
+ int32_t ssi_code;
+ uint32_t ssi_pid;
+ uint32_t ssi_uid;
+ int32_t ssi_fd;
+ uint32_t ssi_tid;
+ uint32_t ssi_band;
+ uint32_t ssi_overrun;
+ uint32_t ssi_trapno;
+ int32_t ssi_status;
+ int32_t ssi_int;
+ uint64_t ssi_ptr;
+ uint64_t ssi_utime;
+ uint64_t ssi_stime;
+ uint64_t ssi_addr;
+ uint8_t __pad[48];
+};
+
+/* Flags for signalfd. */
+enum
+ {
+ SFD_CLOEXEC = 02000000,
+#define SFD_CLOEXEC SFD_CLOEXEC
+ SFD_NONBLOCK = 0200
+#define SFD_NONBLOCK SFD_NONBLOCK
+ };
+
+__BEGIN_DECLS
+
+/* Request notification for delivery of signals in MASK to be
+ performed using descriptor FD.*/
+extern int signalfd (int __fd, const sigset_t *__mask, int __flags)
+ __nonnull ((2)) __THROW;
+
+__END_DECLS
+
+#endif /* sys/signalfd.h */
diff --git a/ports/sysdeps/unix/sysv/linux/mips/sys/timerfd.h b/ports/sysdeps/unix/sysv/linux/mips/sys/timerfd.h
new file mode 100644
index 000000000..ebd37ff4a
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/mips/sys/timerfd.h
@@ -0,0 +1,60 @@
+/* Copyright (C) 2008 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 Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 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
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _SYS_TIMERFD_H
+#define _SYS_TIMERFD_H 1
+
+#include <time.h>
+
+
+/* Bits to be set in the FLAGS parameter of `timerfd_create'. */
+enum
+ {
+ TFD_CLOEXEC = 02000000,
+#define TFD_CLOEXEC TFD_CLOEXEC
+ TFD_NONBLOCK = 0200
+#define TFD_NONBLOCK TFD_NONBLOCK
+ };
+
+
+/* Bits to be set in the FLAGS parameter of `timerfd_settime'. */
+enum
+ {
+ TFD_TIMER_ABSTIME = 1 << 0
+#define TFD_TIMER_ABSTIME TFD_TIMER_ABSTIME
+ };
+
+
+__BEGIN_DECLS
+
+/* Return file descriptor for new interval timer source. */
+extern int timerfd_create (clockid_t __clock_id, int __flags) __THROW;
+
+/* Set next expiration time of interval timer source UFD to UTMR. If
+ FLAGS has the TFD_TIMER_ABSTIME flag set the timeout value is
+ absolute. Optionally return the old expiration time in OTMR. */
+extern int timerfd_settime (int __ufd, int __flags,
+ __const struct itimerspec *__utmr,
+ struct itimerspec *__otmr) __THROW;
+
+/* Return the next expiration time of UFD. */
+extern int timerfd_gettime (int __ufd, struct itimerspec *__otmr) __THROW;
+
+__END_DECLS
+
+#endif /* sys/timerfd.h */
diff --git a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/shlib-versions b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/shlib-versions
new file mode 100644
index 000000000..2ea2298f2
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/shlib-versions
@@ -0,0 +1 @@
+powerpc.*-.*-.* ABI powerpce500v2-linux-gnu
diff --git a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/single/shlib-versions b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/single/shlib-versions
new file mode 100644
index 000000000..a746f46f3
--- /dev/null
+++ b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/single/shlib-versions
@@ -0,0 +1 @@
+powerpc.*-.*-.* ABI powerpce500v1-linux-gnu