about summary refs log tree commit diff
path: root/elf
Commit message (Collapse)AuthorAgeFilesLines
* * include/libc-symbols.h (__libc_freeres_fn_section, libc_freeres_fn):Roland McGrath2002-11-012-10/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | New macros. * elf/dl-close.c (free_mem): Use libc_freeres_fn macro, remove text_set_element. * elf/dl-libc.c (free_mem): Likewise. * iconv/gconv_conf.c (free_mem): Likewise. * iconv/gconv_db.c (free_mem): Likewise. * iconv/gconv_dl.c (free_mem): Likewise. * iconv/gconv_cache.c (free_mem): Likewise. * intl/finddomain.c (free_mem): Likewise. * intl/dcigettext.c (free_mem): Likewise. * locale/setlocale.c (free_mem): Likewise. * misc/fstab.c (fstab_free): Likewise. * nss/nsswitch.c (free_mem): Likewise. * posix/regcomp.c (free_mem): Likewise. * resolv/gai_misc.c (free_res): Likewise. * stdlib/fmtmsg.c (free_mem): Likewise. * sunrpc/clnt_perr.c (free_mem): Likewise. * sysdeps/generic/setenv.c (free_mem): Likewise. * sysdeps/unix/sysv/linux/shm_open.c (freeit): Likewise. * sysdeps/pthread/aio_misc.c (free_res): Likewise. * time/tzset.c (free_mem): Likewise. * malloc/mtrace.c (release_libc_mem): Add __libc_freeres_fn_section. * locale/loadarchive.c (_nl_archive_subfreeres): Likewise. * malloc/set-freeres.c (__libc_freeres): Likewise. * login/getutent.c: Include stdlib.h instead of stddef.h. (buffer): Change into pointer to utmp, add libc_freeres_ptr. (__getutent): Allocate buffer the first time it is run. * login/getutid.c: Include stdlib.h instead of stddef.h. (buffer): Change into pointer to utmp, add libc_freeres_ptr. (__getutid): Allocate buffer the first time it is run. * login/getutline.c: Include stdlib.h instead of stddef.h. (buffer): Change into pointer to utmp, add libc_freeres_ptr. (__getutline): Allocate buffer the first time it is run. * malloc/mtrace.c (malloc_trace_buffer): Change into char *. (mtrace): Allocate malloc_trace_buffer. * resolv/nsap_addr.c (inet_nsap_ntoa): Decrease size of tmpbuf. * resolv/ns_print.c (ns_sprintrrf): Decrease size of t. * string/strerror.c: Include libintl.h and errno.h. (buf): New variable. (strerror): Only allocate buffer if actually needed (unknown error). * time/tzfile.c (transitions): Add libc_freeres_ptr. (freeres): Remove. 2002-10-25 Jakub Jelinek <jakub@redhat.com> * include/libc-symbols.h (libc_freeres_ptr): New macro. * malloc/set-freeres.c (__libc_freeres_ptrs): Define using symbol_set_define. (__libc_freeres): Free all pointers in that section. * Makerules (build-shlib): Add $(LDSEDCMD-$(@F:lib%.so=%).so) to sed commands when creating .lds script. (LDSEDCMD-c.so): New variable. * inet/rcmd.c (ahostbuf): Change into char *. Add libc_freeres_ptr. (rcmd_af): Use strdup to allocate ahostbuf. * inet/rexec.c (ahostbuf): Change into char *. Add libc_freeres_ptr. (rexec_af): Use strdup to allocate ahostbuf. * stdio-common/reg-printf.c (printf_funcs): Remove. (__printf_arginfo_table): Change into printf_arginfo_function **. Add libc_freeres_ptr. (__register_printf_function): Allocate __printf_arginfo_table and __printf_function_table the first time it is called. * stdio-common/printf-parse.h (__printf_arginfo_table): Change into printf_arginfo_function **. (parse_one_spec): Add __builtin_expect. * grp/fgetgrent.c (buffer): Add libc_freeres_ptr. (free_mem): Remove. * inet/getnetgrent.c (buffer): Add libc_freeres_ptr. (free_mem): Remove. * intl/localealias.c (libc_freeres_ptr): Define if !_LIBC. (string_space, map): Add libc_freeres_ptr. (free_mem): Remove. * misc/efgcvt.c (FCVT_BUFPTR): Add libc_freeres_ptr. (free_mem): Remove. * misc/mntent.c (getmntent_buffer): Add libc_freeres_ptr. (free_mem): Remove. * crypt/md5-crypt.c (libc_freeres_ptr): Define if !_LIBC. (buffer): Add libc_freeres_ptr. (free_mem): Remove for _LIBC. * nss/getXXbyYY.c (buffer): Add libc_freeres_ptr. (free_mem): Remove. * nss/getXXent.c (buffer): Add libc_freeres_ptr. (free_mem): Remove. * pwd/fgetpwent.c (buffer): Add libc_freeres_ptr. (free_mem): Remove. * resolv/res_hconf.c (ifaddrs): Add libc_freeres_ptr. (free_mem): Remove. * shadow/fgetspent.c (buffer): Add libc_freeres_ptr. (free_mem): Remove. * sysdeps/posix/ttyname.c (getttyname_name): Add libc_freeres_ptr. (free_mem): Remove. * sysdeps/unix/sysv/linux/getsysstats.c (mount_proc): Add libc_freeres_ptr. (free_mem): Remove. * sysdeps/unix/sysv/linux/ttyname.c (getttyname_name, ttyname_buf): Add libc_freeres_ptr. (free_mem): Remove. 2002-10-30 Jakub Jelinek <jakub@redhat.com> * malloc/obstack.c [_LIBC] (obstack_free): Change into strong_alias instead of duplicating the whole function in libc.
* Update.Ulrich Drepper2002-10-251-2/+17
| | | | | | | 2002-10-23 Alexandre Oliva <aoliva@redhat.com> * elf/dl-reloc.c (_dl_reloc_bad_use): Print the full 32-bit relocation type on ELF64 platforms.
* Update.Ulrich Drepper2002-10-241-1/+1
| | | | * elf/elf.h (R_X86_64_GOTTPOFF): Renamed from r_x86_64_GOTTPOFF.
* Define ELF_NOTE_OS_FREEBSD and NT_TASKSTRUCT.Ulrich Drepper2002-10-241-0/+2
|
* * elf/dl-misc.c: Include <sysdep.h>.Roland McGrath2002-10-241-5/+13
| | | | | | | | | | | | | | | (_dl_debug_vdprintf): Only take dl_load_lock if not _dl_starting_up. * sysdeps/generic/ldsodefs.h (_dl_starting_up): Declare it here. * sysdeps/unix/sysv/linux/init-first.c: Not here. * sysdeps/powerpc/elf/libc-start.c: Or here. * sysdeps/unix/sysv/aix/libc-start.c: Or here. * sysdeps/unix/sysv/aix/start-libc.c: Or here. * sysdeps/unix/sysv/aix/init-first.c: Or here. * sysdeps/generic/libc-start.c: Or here. * sysdeps/unix/sysv/linux/init-first.c (init): Protect _dl_starting_up access with [! SHARED]. * sysdeps/unix/sysv/aix/init-first.c (init): Likewise.
* * posix/regcomp.c (re_comp): Call __regfree on re_comp_buf.Roland McGrath2002-10-241-1/+3
| | | | | | | | | | | | | (free_mem): New function. * posix/Makefile (tests): Add bug-regex14. Add bug-regex14-mem if not cross compiling. (generated): Add bug-regex14-mem and bug-regex14.mtrace. (bug-regex14-ENV): Set. (bug-regex14-mem): New target. * posix/bug-regex14.c: New file. * elf/Makefile ($(objpfx)librtld.map): Use temporary file for output target, so we don't touch it when the link fails.
* (struct filebuf): For buf element to have the alignment of ElfXX_Ehdr since ↵Ulrich Drepper2002-10-231-1/+1
| | | | this is what will be stored in it.
* * sysdeps/generic/libc-tls.c (__libc_setup_tls): Initialize the staticRoland McGrath2002-10-222-6/+7
| | | | | | | | | | | | | | | | | | slotinfo list's len member to the proper size, not just 1. Initialize static_map.l_tls_initimage. * elf/dl-open.c (dl_open_worker): Fix loop searching for dtv_slotinfo_list element containing new modules' l_tls_modid. * elf/tst-tls9.c, elf/tst-tls9-static.c: New files. * elf/tst-tlsmod5.c, elf/tst-tlsmod6.c: New files. * elf/Makefile (tests): Add tst-tls9. (tests-static): Add tst-tls9-static. (tst-tls9-static-ENV): New variable. ($(objpfx)tst-tls9-static, $(objpfx)tst-tls9-static.out): New targets. * elf/dl-close.c (remove_slotinfo): Remove an assert; the number of modids used by partially loaded modules being closed can't be known.
* 2002-10-21 Roland McGrath <roland@redhat.com>Roland McGrath2002-10-225-1/+77
| | | | | | | | | * elf/tst-tls9.c, elf/tst-tls9-static.c: New files. * elf/tst-tlsmod5.c, elf/tst-tlsmod6.c: New files. * elf/Makefile (tests): Add tst-tls9. (tests-static): Add tst-tls9-static. (tst-tls9-static-ENV): New variable. ($(objpfx)tst-tls9-static, $(objpfx)tst-tls9-static.out): New targets.
* * sysdeps/unix/alpha/sysdep.h (INLINE_SYSCALL, INLINE_SYSCALL1)Roland McGrath2002-10-181-1/+1
| | | | | | | | | | (inline_syscall_clobbers, inline_syscall0, inline_syscall1) (inline_syscall2, inline_syscall3, inline_syscall4, inline_syscall5) (inline_syscall6): Move these macros ... * sysdeps/unix/sysv/linux/alpha/sysdep.h: ... to here. * aclocal.m4 (GLIBC_PROVIDES): Add AC_PROVIDEs for _AS_PATH_SEPARATOR_PREPARE and _AS_TEST_PREPARE.
* * aclocal.m4 (GLIBC_PROVIDES): Add AC_PROVIDE([_AS_ECHO_N_PREPARE]).Roland McGrath2002-10-181-19/+0
| | | | | | | | | | | Remove AC_LANG(C) call, instead just define([_AC_LANG], [C]). * elf/dl-support.c: Move _dl_tls_* variables to ... * sysdeps/generic/libc-tls.c: ... here. * elf/dl-close.c (remove_slotinfo): Take new argument. If false, allow IDX to be one past the current last slotinfo entry. (_dl_close): Pass IMAP->l_init_called for that parameter.
* 2002-10-17 Roland McGrath <roland@redhat.com>Roland McGrath2002-10-181-12/+22
| | | | | | * elf/dl-close.c (remove_slotinfo): Take new argument. If false, allow IDX to be one past the current last slotinfo entry. (_dl_close): Pass IMAP->l_init_called for that parameter.
* * elf/dl-load.c (_dl_map_object_from_fd): Don't check DF_STATIC_TLS.Roland McGrath2002-10-174-13/+25
| | | | | | | | | | | | | | | | * elf/dl-reloc.c (_dl_relocate_object: CHECK_STATIC_TLS): New macro to signal error if an IE-model TLS reloc resolved to a dlopen'd module. * sysdeps/i386/dl-machine.h (elf_machine_rel, elf_machine_rela): Call it after performing TPOFF relocs. * sysdeps/x86_64/dl-machine.h (elf_machine_rela): Likewise. * sysdeps/sh/dl-machine.h (elf_machine_rela): Likewise. * elf/dl-conflict.c (CHECK_STATIC_TLS): New macro (no-op). * elf/dl-close.c (remove_slotinfo): Change asserts so as not to crash when closing a partially-initialized object. * elf/dl-load.c (_dl_map_object_from_fd) [! USE_TLS]: Call lose instead of _dl_fatal_printf when we see PT_TLS.
* * elf/dl-load.c (_dl_dst_count, _dl_dst_substitute): Handle $LIBRoland McGrath2002-10-141-4/+5
| | | | | | dynamic string tag. * elf/Makefile ($(objpfx)trusted-dirs.st): Make the output define DL_DST_LIB based on $(slibdir).
* * elf/rtld-Rules ($(objpfx)rtld-libc.a): Use $(verbose) in ar command.Roland McGrath2002-10-141-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sysdeps/mach/hurd/getresuid.c: New file. * sysdeps/mach/hurd/getresgid.c: New file. * sysdeps/mach/hurd/setresuid.c: New file. * sysdeps/mach/hurd/setresgid.c: New file. * posix/unistd.h [__USE_GNU] (getresuid, getresgid, setresuid, setresgid): Declare them. * NEWS: Mention it. * include/unistd.h (__getresuid, __getresgid, __setresuid, __setresgid): Declare them, add libc_hidden_proto. * posix/Versions (libc: GLIBC_2.3.2): New set. Add getresuid, getresgid, setresuid, setresgid here. * Versions.def (libc): Define GLIBC_2.3.2 set. * sysdeps/generic/getresuid.c (__getresuid): Fix argument types. Add libc_hidden_def. * sysdeps/generic/getresgid.c (__getresgid): Likewise. * sysdeps/generic/setresgid.c: New file. * sysdeps/generic/setresuid.c: New file. * sysdeps/unix/sysv/linux/Makefile [$(subdir) = misc] (sysdep_routines): Don't add getresuid and getresgid here. * sysdeps/unix/sysv/linux/arm/Makefile [$(subdir) = misc] (sysdep_routines): Don't add setresuid and setresgid here. * sysdeps/unix/sysv/linux/cris/Makefile: Likewise. * sysdeps/unix/sysv/linux/sh/Makefile: Likewise. * sysdeps/unix/sysv/linux/s390/s390-32/Makefile: Likewise. * sysdeps/unix/sysv/linux/s390/s390-64/Makefile: Likewise. * sysdeps/unix/sysv/linux/i386/Makefile: Likewise. * sysdeps/unix/sysv/linux/m68k/Makefile: Likewise. * posix/Makefile (routines): Add them all here instead. * sysdeps/unix/sysv/linux/i386/getresuid.c (getresuid): Renamed to __getresuid. Add libc_hidden_def for that, and weak alias to old name. * sysdeps/unix/sysv/linux/i386/getresgid.c (getresgid): Renamed to __getresgid. Add libc_hidden_def for that, and weak alias to old name. * sysdeps/unix/sysv/linux/i386/setresuid.c: Add libc_hidden_def. [! __NR_setresuid]: Include generic file. * sysdeps/unix/sysv/linux/i386/setresgid.c (setresgid): Renamed to __setresgid. Add libc_hidden_def for that, and weak alias to old name. [! __NR_setresuid]: Include generic file. * sysdeps/unix/sysv/linux/syscalls.list (setresuid, setresgid): Caller is - now, not EXTRA. * sysdeps/unix/sysv/linux/sparc/sparc32/syscalls.list (setresuid, setresgid, getresuid, getresgid): Likewise. * sysdeps/unix/sysv/linux/syscalls.list (getresuid, getresgid): Add these calls here. * sysdeps/unix/sysv/linux/alpha/syscalls.list: Remove them here. * sysdeps/unix/sysv/linux/hppa/syscalls.list: Likewise. * sysdeps/unix/sysv/linux/sparc/sparc64/syscalls.list: Likewise. * sysdeps/unix/sysv/linux/s390/s390-64/syscalls.list: Likewise. * sysdeps/unix/sysv/linux/x86_64/syscalls.list: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc32/syscalls.list: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc64/syscalls.list: Likewise. * sysdeps/unix/sysv/linux/mips/syscalls.list: Likewise. * sysdeps/unix/sysv/linux/ia64/syscalls.list: Likewise. * sysdeps/unix/sysv/linux/Makefile [$(subdir) = misc] (sysdep_routines): Add setfsuid and setfsgid here. * sysdeps/unix/sysv/linux/arm/Makefile: Not here. * sysdeps/unix/sysv/linux/sparc/sparc32/Makefile: Likewise. * sysdeps/unix/sysv/linux/cris/Makefile: Likewise. * sysdeps/unix/sysv/linux/sh/Makefile: Likewise. * sysdeps/unix/sysv/linux/s390/s390-32/Makefile: Likewise. * sysdeps/unix/sysv/linux/s390/s390-64/Makefile: Likewise. * sysdeps/unix/sysv/linux/i386/Makefile: Likewise. * sysdeps/unix/sysv/linux/m68k/Makefile: Likewise. * hurd/errno.c: Renamed to ... * hurd/errno-loc.c: ... this. * hurd/Makefile (routines): errno -> errno-loc
* Update.Ulrich Drepper2002-10-121-20/+18
| | | | | | | | | * elf/dl-load.c (_dl_map_object_from_fd): Remove unnecessarily duplicated variable c. * sysdeps/unix/sysv/linux/sigwait.c (__sigwait): Use INTERNAL_SYSCALL if possible. Add hack to prevent the compiler from clobbering the signal context.
* * sysdeps/generic/bits/libc-tsd.h [USE___THREAD]: ConditionalRoland McGrath2002-10-119-136/+273
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | changed from [USE_TLS && HAVE___THREAD]. * sysdeps/i386/dl-machine.h (elf_machine_type_class, elf_machine_rel): Disable TLS relocs if [RTLD_BOOTSTRAP && !USE___THREAD]. * sysdeps/x86_64/dl-machine.h (elf_machine_type_class, elf_machine_rela): Likewise. * sysdeps/sh/dl-machine.h (elf_machine_type_class, elf_machine_rela): Likewise. * include/link.h (struct link_map): Remove member l_tls_tp_initialized. * elf/rtld.c (_dl_start_final, dl_main): Don't use it. (_dl_start): Conditionalize PT_TLS check on [USE___THREAD]. * sysdeps/i386/dl-tls.h (__TLS_GET_ADDR): Use ___tls_get_addr_internal instead of ___tls_get_addr. (___tls_get_addr_internal): Add attribute_hidden to decl. * sysdeps/generic/ldsodefs.h (struct rtld_global): New variable _dl_error_catch_tsd. * elf/rtld.c (startup_error_tsd): New function. (dl_main): Point _dl_error_catch_tsd at that. * elf/dl-error.c: Don't use libc-tsd.h for DL_ERROR, use new function pointer instead. * elf/dl-tsd.c: New file. * elf/Makefile (routines): Add it. 2002-10-07 Roland McGrath <roland@redhat.com> * elf/dl-misc.c (_dl_debug_vdprintf): Use INTERNAL_SYSCALL macro for writev if it's available. Otherwise if [RTLD_PRIVATE_ERRNO] then take _dl_load_lock around calling __writev. * sysdeps/unix/sysv/linux/i386/sysdep.h (INTERNAL_SYSCALL): New macro. (INLINE_SYSCALL): Use that. * sysdeps/generic/dl-sysdep.h: New file. * sysdeps/mach/hurd/dl-sysdep.h: New file. * sysdeps/generic/ldsodefs.h: Include <dl-sysdep.h>. * include/errno.h [IS_IN_rtld]: Include <dl-sysdep.h> to define ... [RTLD_PRIVATE_ERRNO]: Use a hidden global variable for errno and access it directly. * elf/dl-minimal.c (__errno_location): Removed. * sysdeps/unix/i386/sysdep.S (__syscall_errno) [RTLD_PRIVATE_ERRNO]: Use GOTOFF access for errno. * sysdeps/unix/sysv/linux/i386/sysdep.h [RTLD_PRIVATE_ERRNO] (SYSCALL_ERROR_HANDLER): Likewise. * sysdeps/unix/x86_64/sysdep.S (__syscall_errno) [RTLD_PRIVATE_ERRNO]: Use PC-relative access for errno. * sysdeps/unix/sysv/linux/x86_64/sysdep.h [RTLD_PRIVATE_ERRNO] (SYSCALL_ERROR_HANDLER): Likewise. * include/tls.h: New file. (USE___THREAD): New macro. Define to 1 under [USE_TLS && HAVE___THREAD] and only when compiling libc or libpthread. * sysdeps/unix/sysv/linux/i386/sysdep.h [USE___THREAD]: Conditional changed from [USE_TLS && HAVE___THREAD]. * sysdeps/unix/sysv/linux/x86_64/sysdep.h: Likewise. * sysdeps/unix/i386/sysdep.S: Likewise. * sysdeps/unix/x86_64/sysdep.S: Likewise. * include/errno.h: Likewise. * include/netdb.h: Likewise. * include/resolv.h: Likewise. * sysdeps/generic/errno.c: New file. * csu/Makefile (aux): New variable, list errno. * sysdeps/unix/sysv/linux/i386/sysdep.S (errno, _errno): Remove defns. * sysdeps/unix/sysv/linux/m68k/sysdep.S: Likewise. * sysdeps/unix/sysv/linux/x86_64/sysdep.S: Likewise. * sysdeps/unix/sysv/linux/s390/s390-64/sysdep.S: Likewise. * sysdeps/unix/sysv/linux/s390/s390-32/sysdep.S: Likewise. * sysdeps/unix/sysv/linux/arm/sysdep.S: Likewise. * sysdeps/unix/sysv/linux/cris/sysdep.S: Likewise. * sysdeps/unix/sysv/linux/hppa/sysdep.c: Likewise. * sysdeps/unix/sysv/linux/ia64/sysdep.S: Likewise. * sysdeps/unix/sysv/linux/powerpc/sysdep.c: Likewise. * sysdeps/unix/sysv/linux/sparc/sysdep.S: Likewise. * sysdeps/unix/sysv/linux/sh/sysdep.S: Likewise. * sysdeps/unix/alpha/sysdep.S: Likewise. * sysdeps/generic/start.c: Likewise. * sysdeps/unix/start.c: Likewise. * sysdeps/unix/arm/start.c: Likewise. * sysdeps/unix/bsd/ultrix4/mips/start.S: Likewise. * sysdeps/unix/sparc/start.c: Likewise. * sysdeps/unix/sysv/irix4/start.c: Likewise. * sysdeps/unix/sysv/linux/mips/sysdep.S: File removed. * manual/search.texi (Tree Search Function, Hash Search Function): Mention search.h clearly. 2002-10-05 Roland McGrath <roland@redhat.com> * elf/dl-fxstat64.c: File removed. * elf/dl-xstat64.c: File removed. * elf/Makefile (rtld-routines): Remove them. * sysdeps/unix/sysv/linux/xstat64.c: Remove RTLD_STAT64 conditionals. Instead, use strong_alias instead of versioned_symbol in the !SHLIB_COMPAT case. * sysdeps/unix/sysv/linux/fxstat64.c: Likewise. * sysdeps/unix/sysv/linux/lxstat64.c: Likewise. * include/shlib-compat.h (SHLIB_COMPAT): Require that IS_IN_##lib be defined nonzero. [! NOT_IN_libc] (IS_IN_libc): Define it. * cppflags-iterator.mk (CPPFLAGS-$(cpp-src)): Use -Dx=1 not just -Dx. * elf/Makefile (CPPFLAGS-.os): Likewise. * sunrpc/rpc_main.c (main): Don't declare with noreturn attribute. Return the status instead of calling exit. * Makeconfig (CFLAGS): Prepend -std=gnu99. * Makerules (+make-deps): Use $(CFLAGS) only for .c sources. Remove superfluous rm command, whose @ plus make bugs hid all these commands from the make output. * include/stubs-prologue.h: New file. Give #error under #ifdef _LIBC. * Makefile ($(inst_includedir)/gnu/stubs.h): Depend on it. Use that file's contents instead of literal echo's for the prologue. * include/features.h: Include <gnu/stubs.h> unconditionally. * include/gnu/stubs.h: New file. 2002-09-30 Roland McGrath <roland@redhat.com> * elf/rtld-Rules: New file. * elf/Makefile ($(objpfx)librtld.map, $(objpfx)librtld.mk, $(objpfx)rtld-libc.a): New targets. (generated): Add them. (reloc-link): Remove -o $@ from the variable. ($(objpfx)dl-allobjs.os): Add -o $@ after $(reloc-link). (distribute): Add rtld-Rules. (CPPFLAGS-.os): Define this instead of CFLAGS-.os. * Makerules ($(+sysdir_pfx)sysd-rules): Emit rules for rtld-% targets. (common-mostlyclean, common-clean): Clean up rtld-* files. * sysdeps/unix/make-syscalls.sh: Add rtld-*.os target name to rules.
* * sysdeps/generic/dl-tls.c (__tls_get_addr): After freeing block inRoland McGrath2002-10-111-4/+4
| | | | | | | | | now-unused dtv slot, reset the slot to TLS_DTV_UNALLOCATED. * elf/tls-macros.h [__x86_64__] (TLS_GD): Fix the sequence with the proper set of no-op insn prefixes. * elf/tst-tls8.c (do_test): Use %zd format for l_tls_modid members.
* 2002-10-11 Roland McGrath <roland@redhat.com>Roland McGrath2002-10-111-1/+3
| | | | | * elf/tls-macros.h [__x86_64__] (TLS_GD): Fix the sequence with the proper set of no-op insn prefixes.
* Update.Ulrich Drepper2002-10-101-1/+1
| | | | | | | | * sysdeps/generic/ldsodefs.h: Remove attribute_hidden from _dl_allocate_tls_init. Add rtld_hidden_proto. * sysdeps/generic/dl-tls.c (_dl_allocate_tls_init): Add rtld_hidden_def. * elf/Versions (ld) [GLIBC_PRIVATE]: Add _dl_allocate_tls_init.
* Update.Ulrich Drepper2002-10-051-8/+11
| | | | | | | | | | | | 2002-10-05 Kaz Kojima <kkojima@rr.iij4u.or.jp> * elf/tls-macros.h: Fix SH version of macros so as to match ABI syntax. 2002-10-03 Ulrich Drepper <drepper@redhat.com> * version.h (RELEASE): Change to stable. See ChangeLog.13 for earlier changes.
* Update.Ulrich Drepper2002-10-021-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-10-02 Ulrich Drepper <drepper@redhat.com> * version.h (VERSION): Bump to 2.3. * elf/Makefile (distribute): Add tst-tlsmod1.c, tst-tlsmod2.c, tst-tlsmod3.c, tst-tlsmod4.c, circlemod1.c, circlemod1a.c, circlemod2.c, circlemod2a.c, circlemod3.c, circlemod3a.c, and nodlopenmod2.c. * login/Makefile (distribute): Add utmp-equal.h. * iconvdata/Makefile (distribute): Add TSCII.precomposed and TSCII.irreversible. * Make-dist (dist): Create .bz2 file. Add rule to create .bz2 files. Also distribute xtests sources. 2002-10-02 Kaz Kojima <kkojima@rr.iij4u.or.jp> * elf/elf.h: Change TLS ELF relocation numbers. * elf/tls-macros.h: Fix code sequences for SH TLS_LD and TLS_GD macros. * sysdeps/sh/dl-machine.h (dl_machine_rela) [case R_SH_TLS_TPOFF32]: Use addend. * sysdeps/sh/elf/initfini.c: Move __fpscr_values to... * sysdeps/sh/elf/start.S: ...here.
* Update.Ulrich Drepper2002-10-022-19/+15
| | | | | | | | 2002-10-02 Kaz Kojima <kkojima@rr.iij4u.or.jp> * sysdeps/sh/pt-machine.h: Make C code ifndef'ed with __ASSEMBLER__. * sysdeps/sh/tls.h: Likewise. * sysdeps/unix/sysv/linux/sh/smp.h: New file.
* * elf/tls-macros.h (TLS_LD, TLS_GD): Use call insn, not callq.Roland McGrath2002-09-301-2/+2
| | | | | | | | | | | | | | | | | | * sysdeps/unix/x86_64/sysdep.S [USE_TLS && HAVE___THREAD] [! PIC]: Use direct-%fs form of TLS access for errno. * sysdeps/unix/sysv/linux/i386/i686/sysdep.h: File removed, since the i386 version has all the same asm now. * sysdeps/i386/elf/configure.in: Add @GOTNTPOFF and @NTPOFF uses to the TLS support check. * sysdeps/i386/elf/configure: Regenerated. * sysdeps/unix/sysv/linux/i386/sysdep.h [USE_TLS && HAVE___THREAD] (SYSCALL_ERROR_HANDLER): Use direct-%gs form of TLS access for errno. * sysdeps/unix/i386/sysdep.S (syscall_error) [USE_TLS && HAVE___THREAD]: Use TLS access for errno.
* * elf/rtld.c (_dl_start): Fix conditional for declaring CNT.Roland McGrath2002-09-291-1/+1
| | | | | * aclocal.m4 (LIBC_PROG_BINUTILS): Don't clobber $RANLIB with ranlib before we check it.
* Define macro DO_ELF_MACHINE_REL_RELATIVE for 'elf_machine_rel_relative'. ↵Ulrich Drepper2002-09-281-2/+8
| | | | (elf_dynamic_do_rel): Call DO_ELF_MACHINE_REL_RELATIVE macro instead of 'elf_machine_rel_relative'.
* * elf/dl-addr.c (_dl_addr): Set dli_fbase to l_map_startRoland McGrath2002-09-272-10/+19
| | | | | | | | | | | | | | | | unconditionally. Set dli_fname to _dl_argv[0] only for main program. 2002-09-27 Roland McGrath <roland@redhat.com> * elf/dl-addr.c (_dl_addr): Add a cast. * sysdeps/x86_64/dl-machine.h (elf_machine_rela) [USE_TLS]: Handle new TLS relocs R_X86_64_DTPMOD64, R_X86_64_DTPOFF64, and R_X86_64_TPOFF64. * elf/elf.h (R_X86_64_DTPMOD64, R_X86_64_DTPOFF64, R_X86_64_TPOFF64, R_X86_64_TLSGD, R_X86_64_TLSLD, R_X86_64_DTPOFF32, R_x86_64_GOTTPOFF, R_X86_64_TPOFF32): New macros. (R_X86_64_NUM): Update the value.
* Update.Ulrich Drepper2002-09-272-4/+14
| | | | | | | | | | 2002-09-26 Ulrich Drepper <drepper@redhat.com> * elf/dynamic-link.h (elf_get_dynamic_info): Relocate DT_HASH entry if necessary. * elf/dl-lookup.c (_dl_setup_hash): DT_HASH entry is already relocated. * elf/dl-addr.c (_dl_addr): Use .hash[1] entry to determine end of the symbol table if necessary.
* (elf_get_dynamic_info): Also relocate DT_HASH entry if necessary.Ulrich Drepper2002-09-271-0/+2
|
* * csu/Versions: Use %include <tls.h> to get USE_TLS defined.Roland McGrath2002-09-251-0/+35
| | | | | | | | | | | | | | | | | | | (libc: GLIBC_2.0) [USE_TLS && HAVE___THREAD]: Remove _errno, errno. (libc: GLIBC_2.3) [USE_TLS && HAVE___THREAD]: Put errno here instead. * resolv/Versions: Use %include <tls.h> to get USE_TLS defined. (libc: GLIBC_2.0) [USE_TLS && HAVE___THREAD]: Remove _h_errno, h_errno, and _res. (libc: GLIBC_2.3) [USE_TLS && HAVE___THREAD]: Put h_errno, _res here. * elf/tls-macros.h [__x86_64__] (TLS_LE, TLS_IE, TLS_LD, TLS_GD): New macros for x86-64. * sysdeps/unix/sysv/linux/alpha/bits/time.h: File removed. It was indentical to the linux/bits/time.h file. * nscd/nscd_gethst_r.c (nscd_gethst_r): Add a cast to silence warning. * resolv/gethnamaddr.c (gethostbyaddr): Use socklen_t for SIZE.
* * elf/Makefile (test-extras): Define this instead of test-srcs.Roland McGrath2002-09-231-1/+2
| | | | * Makerules (all-nonlib): Include $(test-extras) too.
* (_dl_init): Fix test of the size of the preinit_array section. (call_init): ↵Ulrich Drepper2002-09-201-6/+7
| | | | Optimize access to DT_INIT_ARRAY entry a bit.
* * sysdeps/generic/utmp-equal.h: New file, extracted from utmp_file.c.Roland McGrath2002-09-201-2/+4
| | | | | | | | | | | | * sysdeps/generic/utmp_file.c (setutent_file): Invalidate last_entry also on platforms with !HAVE_UT_TYPE. (proc_utmp_eq): Remove function. (internal_getut_r, pututline_file): Call __utmp_equal instead. 2002-09-20 Bruno Haible <bruno@clisp.org> * abi-tags: Add support for FreeBSD with ABI OS value 3. * elf/cache.c (print_entry): Support the GNU/FreeBSD ABI tag.
* * locale/lc-ctype.c (_nl_postload_ctype): Add compat_symbol decls forRoland McGrath2002-09-182-3/+3
| | | | | | | | | | | the __ctype_* compat symbols, so the relocs generated bind to the right versioned global symbol in the shared object. * elf/do-rel.h (elf_dynamic_do_rel): Mask off 0x8000 bit (hidden flag) from the value taken from the DT_VERSYM table. * elf/dl-runtime.c (fixup, profile_fixup): Likewise. * sysdeps/mips/dl-machine.h (__dl_runtime_resolve): Likewise. (RESOLVE_GOTSYM): Likewise.
* * elf/dl-lookup.c (_dl_debug_bindings): Print TLS lookups always.Roland McGrath2002-09-182-12/+21
| | | | | | | | | | | | * elf/elf.h (R_386_TLS_TPOFF, R_386_TLS_IE, R_386_TLS_GOTIE, R_386_TLS_LE): Define. (R_386_TLS_IE_32, R_386_TLS_LE_32, R_386_TLS_TPOFF32): Update comments. * sysdeps/i386/dl-machine.h (elf_machine_type_class): Return ELF_RTYPE_CLASS_PLT for R_386_TLS_TPOFF. (elf_machine_rel): Handle R_386_TLS_TPOFF. (elf_machine_rela): Likewise. Remove unnecessary RTLD_BOOTSTRAP #ifdefs.
* * sysdeps/unix/sysv/linux/powerpc/mmap64.c (__mmap64): Add a cast.Roland McGrath2002-09-171-1/+1
| | | | | | | * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep.h (INLINE_SYSCALL): New macro. * elf/rtld.c [HP_TIMING_NONAVAIL]: Fix last change for this case.
* * include/unistd.h: Uncomment libc_hidden_proto for _exit.Roland McGrath2002-09-171-17/+32
| | | | | | | | | | | | | | * sysdeps/mach/hurd/_exit.c: Add libc_hidden_def. * sysdeps/generic/_exit.c: Likewise. 2002-09-12 Jakub Jelinek <jakub@redhat.com> * elf/rtld.c (struct dl_start_final_info): New. (_dl_start_final): Change second argument to struct dl_start_final_info *. Set start_time from info. (_dl_start): Remove bootstrap_map variable, add info. Define bootstrap_map as macro. If not DONT_USE_BOOTSTRAP_MAP, store HP_TIMING_NOW result into info.start_time.
* * sysdeps/generic/ldconfig.h (FLAG_POWERPC_LIB64) New macro.Roland McGrath2002-09-141-8/+5
| | | | | | | | * elf/cache.c (print_entry): Add case for FLAG_POWERPC_LIB64. Remove per-machine conditionals for FLAG_* cases. * sysdeps/unix/sysv/linux/powerpc/ldconfig.h: New file. * sysdeps/unix/sysv/linux/powerpc/readelflib.c: New file. * sysdeps/unix/sysv/linux/powerpc/powerpc64/dl-cache.h: New file.
* Correct DT_LOOS and DT_HIOS values.Ulrich Drepper2002-09-121-2/+2
|
* * elf/rtld.c (_dl_start_final): Move _begin, _end decls outside the fn.Roland McGrath2002-09-121-4/+15
| | | | | (_dl_start) [DONT_USE_BOOTSTRAP_MAP]: Use &_begin instead of l_addr to find the ELF header.
* * elf/rtld.c (dl_main) [USE_TLS]: Adjust l_tls_initimage of mainRoland McGrath2002-09-121-0/+7
| | | | executable if needed, in case it's actually a shared object.
* * elf/dl-load.c (_dl_map_object_from_fd): Use l_addr instead ofRoland McGrath2002-09-121-1/+1
| | | | l_map_start to adjust l_tls_initimage.
* Update.Ulrich Drepper2002-09-102-1/+77
| | | | | | | | | | | 2002-09-09 Steven Munroe <sjmunroe@us.ibm.com> * elf/elf.h: Add powerpc64 specific elf relocation and dynamic types. 2002-09-09 Jakub Jelinek <jakub@redhat.com> * elf/dl-error.c (_dl_signal_cerror): Don't print anything if only LD_DEBUG=statistics or LD_TRACE_PRELINKING.
* 2002-09-04 Bruno Haible <bruno@clisp.org>Roland McGrath2002-09-051-1/+4
| | | | | | | | | | | | | | | | | | * elf/readlib.c (process_file): Conditionalize check for QMAGIC. * sysdeps/unix/sysv/linux/sigset-cvt-mask.h (sigset_set_old_mask, sigset_get_old_mask): Turn into inline functions. * sysdeps/unix/sysv/aix/sigset-cvt-mask.h (sigset_set_old_mask, sigset_get_old_mask): Likewise. * sysdeps/unix/sysv/sysv4/sigset-cvt-mask.h (sigset_set_old_mask, sigset_get_old_mask): Likewise. * sysdeps/generic/_strerror.c (_sys_errlist, _sys_nerr): Remove default definitions. (__strerror_r): Use _sys_errlist_internal instead of _sys_errlist, _sys_nerr_internal instead of _sys_nerr. * nscd/connections.c (handle_request): Declare CALLER inside #if.
* 2002-09-02 Jakub Jelinek <jakub@redhat.com>Roland McGrath2002-09-021-3/+10
| | | | | * elf/rtld.c (dl_main): If prelinking succeeded, mark all objects as relocated.
* (elf_get_dynamic_info): Mark with always_inline attribute.Ulrich Drepper2002-08-311-1/+1
|
* * sysdeps/mach/_strerror.c (__strerror_r): Add libc_hidden_def.Roland McGrath2002-08-301-0/+13
| | | | | | | | | | | | | | | | | | * sysdeps/mach/hurd/pwrite64.c: No libc_hidden_def (__libc_pwrite64). * sysdeps/mach/hurd/dl-sysdep.c (__GI_abort): Define alias for abort. * include/assert.h (__assert_perror_fail): Declare it, do hidden_proto. * assert/assert-perr.c: Add libc_hidden_def. * elf/dl-minimal.c [! NDEBUG] (__assert_perror_fail): New function. * sysdeps/gnu/errlist-compat.awk: Don't fail if there are no versions found at all. * sysdeps/gnu/Versions: File removed. Moved all #errlist-compat sys_errlist stuff to ... * sysdeps/unix/sysv/linux/Versions: ... here. * mach/mach.h: Include <features.h>.
* * elf/dl-runtime.c (IN_DL_RUNTIME): Define this macro first thing.Roland McGrath2002-08-291-0/+2
| | | | | * sysdeps/i386/dl-machine.h: Only declare fixup, profile_fixup and define ELF_MACHINE_RUNTIME_TRAMPOLINE under #ifdef IN_DL_RUNTIME.
* * elf/tst-tls1-static.c: New file.Roland McGrath2002-08-283-4/+2
| | | | | * elf/tst-tls2-static.c: New file. * elf/Makefile ($(tests-static):%=$(objfpx)%.o): Remove rule.
* 2002-08-28 Roland McGrath <roland@redhat.com>Roland McGrath2002-08-281-8/+16
| | | | | | | * elf/Makefile (tests): List tst-tls1 and tst-tls2 unconditionally. [$(build-static) = yes] (tests): Add tst-tls1-static, tst-tls2-static. [$(build-static) = yes] (tests-static): New variable. ($(tests-static):%=$(objfpx)%.o)): New static pattern rule.