Commit Graph

1370 Commits

Author SHA1 Message Date
Ulrich Drepper 5ce98c3f3f Update.
2004-05-03  Jakub Jelinek  <jakub@redhat.com>

	* sysdeps/unix/bsd/bits/fcntl.h (F_SETOWN, F_GETOWN): Define if
	__USE_BSD or __USE_UNIX98.
	* sysdeps/unix/bsd/ultrix4/bits/fcntl.h (F_SETOWN, F_GETOWN): Likewise.
	* sysdeps/unix/bsd/bsd4.4/bits/fcntl.h (F_SETOWN, F_GETOWN): Likewise.
	* sysdeps/unix/bsd/sun/sunos4/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/common/bits/fcntl.h (F_SETOWN, F_GETOWN): Likewise.
	* sysdeps/unix/sysv/aix/bits/fcntl.h (F_SETOWN, F_GETOWN): Likewise.
	* sysdeps/unix/sysv/irix4/bits/fcntl.h (F_SETOWN, F_GETOWN): Likewise.
	* sysdeps/unix/sysv/linux/alpha/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/s390/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/cris/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	*sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/sparc/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/mips/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/sh/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/i386/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/m68k/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/ia64/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/arm/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/hppa/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h (F_SETOWN, F_GETOWN):
	Likewise.
	* sysdeps/generic/bits/fcntl.h (F_SETOWN, F_GETOWN): Likewise.
	* sysdeps/mach/hurd/bits/fcntl.h (F_SETOWN, F_GETOWN): Likewise.
	* io/sys/stat.h (S_ISSOCK, S_IFSOCK): Likewise.

2004-05-01  Jakub Jelinek  <jakub@redhat.com>

	* posix/Versions (libc): Remove __libc_wait, __libc_waitpid,
	__libc_pause, __libc_nanosleep, __libc_pread, __libc_pread64,
	__libc_pwrite64, __waitid and __pselect @@GLIBC_PRIVATE.
	* stdlib/Versions (libc): Remove __on_exit@@GLIBC_PRIVATE.
	* sysdeps/unix/sysv/linux/Versions (libc): Remove
	__libc_sigaction@@GLIBC_PRIVATE.
	* sysdeps/unix/sysv/linux/x86_64/Versions (libc): Remove
	__modify_ldt@@GLIBC_PRIVATE.
	* socket/Versions (libc): Remove __libc_accept, __libc_send,
	__libc_recvfrom, __libc_recvmsg, __libc_sendmsg, __libc_recv,
	__libc_sendto and __libc_connect @@GLIBC_PRIVATE.
	* stdio-common/Versions (libc): Remove
	_itoa_upper_digits@@GLIBC_PRIVATE.
	* resolv/Versions (libresolv): Remove __ns_samename@@GLIBC_PRIVATE.
	* misc/Versions (libc): Remove __libc_fsync, __libc_msync,
	__libc_readv and __libc_writev @@GLIBC_PRIVATE.
	* termios/Versions (libc): Remove __libc_tcdrain@@GLIBC_PRIVATE.
	* io/Versions (libc): Remove __libc_open, __libc_close, __libc_read,
	__libc_write, __libc_lseek, __libc_fcntl, __libc_open64 and
	__libc_lseek64 @@GLIBC_PRIVATE.

2004-04-30  Jakub Jelinek  <jakub@redhat.com>

	* elf/dl-load.c (open_verify): Move e_phentsize check after e_type
	check.

2004-04-29  Steven Munroe  <sjmunroe@us.ibm.com>

	* sysdeps/powerpc/powerpc64/fpu/s_ceil.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_ceilf.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_floor.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_floorf.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_llrint.c: Removed.
	* sysdeps/powerpc/powerpc64/fpu/s_llrint.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_llrintf.c: Removed.
	* sysdeps/powerpc/powerpc64/fpu/s_llrintf.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_llround.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_llroundf.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_lround.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_lroundf.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_rint.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_rintf.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_round.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_roundf.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_trunc.S: New file.
	* sysdeps/powerpc/powerpc64/fpu/s_truncf.S: New file.

	* math/test-misc.c [LDBL_MANT_DIG == 106](main): Correct LDBL_MAX
	mantissa for AIX long double format.
	* misc/qefgcvt.c [LDBL_MANT_DIG == 106] (NDIGIT_MAX): Define for AIX
	long double format.
	* misc/qefgcvt_r.c [LDBL_MANT_DIG == 106] (NDIGIT_MAX): Likewise.
	* stdlib/fpioconst.c [!__NO_LONG_DOUBLE_MATH && __LDBL_MAX_EXP__>1024]
	(_fpioconst_pow10): AIX long double format has same exponent range as
	double.
	* stdlib/fpioconst.h [!__NO_LONG_DOUBLE_MATH && __LDBL_MAX_EXP__>1024]
	(LDBL_MAX_10_EXP_LOG): AIX long double format has same exponent range
	as double.

2004-04-23  Art Haas  <ahaas@airmail.net>

	* sysdeps/unix/sysv/linux/kernel-features.h: Add 'defined'.
2004-05-03 21:40:12 +00:00
Ulrich Drepper b33ed4326d Update.
2004-04-21  Jakub Jelinek  <jakub@redhat.com>

	* posix/tst-chmod.c (do_test): Fix a typo.
	* elf/lateglobal.c (main): Fix error checks.
	Patch by Stephen Clarke <stephen.clarke@st.com>.

	* manual/ctype.texi (isblank, iswblank): Mark as ISO functions,
	mention they have been added in ISO C99.
	Reported by Ben Pfaff <blp@cs.stanford.edu>.

2004-03-31  H.J. Lu  <hongjiu.lu@intel.com>

	* sysdeps/ieee754/ldbl-128/bits/huge_vall.h: Fix typo.
2004-04-21 18:58:31 +00:00
Roland McGrath 26e059c142 2004-04-01 Roland McGrath <roland@redhat.com>
* elf/tst-execstack.c (do_test): Make F static.
2004-04-02 02:23:05 +00:00
Ulrich Drepper 8f23eb7abe Update.
2004-04-01  Ulrich Drepper  <drepper@redhat.com>

	* elf/elf.h: Define more ppc64 specific dynamic tags.

	* libio/fileops.c (new_do_write): Return _IO_size_t to make 64-bit
2004-04-01 18:49:40 +00:00
Ulrich Drepper eec8b6cae5 Update.
2004-03-26  Ulrich Drepper  <drepper@redhat.com>

	* elf/dl-caller.c: New file.
	* include/caller.h: New file.
	* Makefile (distribute): Add include/caller.h.
	* elf/Makefile (dl-routines): Add dl-caller.
	* elf/dl-load.c (_dl_map_object_from_fd): Record l_text_end.
	* elf/dl-open.c (check_libc_caller): Removed.
	(dl_open_worker): Use __check_caller instead.
	* elf/rtld.c (_rtld_global_ro): Initialize _dl_check_caller.
	(_dl_start_final): Record l_text_end for ld.so map.
	(dl_main): Record l_text_end for main object and vdso.
	* include/link.h (struct link_map): Add l_text_end field.
	* sysdeps/generic/ldsodefs.h (struct rtld_global_ro): Add
	_dl_check_caller field.
	Define enum allowmask.  Add declaration of _dl_check_caller.
	* sysdeps/unix/sysv/linux/dl-execstack.c: Also use __check_caller test.
2004-03-27 03:40:33 +00:00
Ulrich Drepper 4ba541a978 Update.
2004-03-26  Ulrich Drepper  <drepper@redhat.com>

	* elf/dl-open.c (check_libc_caller): Fix typo.
2004-03-26 21:25:35 +00:00
Ulrich Drepper fde9eb68f5 Include stddef.h and stdlib.h. 2004-03-26 09:48:53 +00:00
Roland McGrath db2f05ba83 * Makerules ($(common-objpfx)shlib.lds): Don't use \n in rhs of sed
substitutions; the semicolon terminators are enough for ld anyway.

	* elf/dl-deps.c (_dl_map_object_deps): Use alloca instead of
	dynamically sized auto array in function already using alloca.
	* locale/programs/ld-ctype.c (ctype_output): Likewise.
	* locale/programs/ld-time.c (time_output): Likewise.
	* elf/dl-misc.c (_dl_debug_vdprintf): Use macro instead of const for
	IOV array size.
	* locale/programs/charmap.c (charmap_read): Avoid alloca (or strdupa)
	when also using dynamically-sized auto array.
	* locale/programs/locfile.c (locfile_read): Likewise.
	* locale/programs/repertoire.c (repertoire_read): Likewise.
	* nis/nis_print_group_entry.c (nis_print_group_entry): Likewise.
	* locale/programs/locarchive.c (enlarge_archive): Likewise.
	* posix/annexc.c (check_header): Likewise.

	* iconv/gconv_int.h (norm_add_slashes): Don't handle null SUFFIX.
	strlen ("") gets optimized away just as well.
	* intl/loadmsgcat.c (_nl_init_domain_conv): Update caller.
	* wcsmbs/wcsmbsload.c (__wcsmbs_load_conv): Likewise.
2004-03-25 03:54:03 +00:00
Andreas Jaeger 6873f5c706 Update.
2004-03-22  Joseph S. Myers  <jsm@polyomino.org.uk>

	* sunrpc/rpc/xdr.h (IXDR_GET_LONG, IXDR_PUT_LONG): Do not use
	casts as lvalues.

2004-03-22  Andreas Jaeger  <aj@suse.de>

	* elf/tst-dlmodcount.c (unload): Remove unused variable.

	* misc/tst-mntent.c (main): Use tmpfile instead of tmpnam.
2004-03-22 10:53:16 +00:00
Roland McGrath f57ebe2988 * elf/ldconfig.c: Include stdbool.h. 2004-03-18 21:28:37 +00:00
Roland McGrath 8e115d80b0 * elf/ldconfig.c (parse_conf_include): New function.
(parse_conf): Call it to parse lines starting with "include".
	Remaining words are glob patterns for more config files to read.
	Take additional bool argument to disable opt_chroot processing.
	(main): Update caller.
2004-03-18 08:43:41 +00:00
Ulrich Drepper f032388692 Update.
* sysdeps/generic/errno.c: Include <dl-sysdep.h>.  Use
	RTLD_PRIVATE_ERRNO to decide whether errno compat symbols are needed.
2004-03-11 06:06:12 +00:00
Ulrich Drepper 53761a8b36 Unify _dl_sym and _dl_vsym code and make the entry points wrappers around the unified code. 2004-03-11 03:41:54 +00:00
Ulrich Drepper 9363dbb847 Update.
* elf/dl-lookup.c (_dl_lookup_symbol_x): Fix possible NULL pointer
	derefernce in error message.  Pretty printing.
2004-03-10 00:08:55 +00:00
Ulrich Drepper 1e5f1d862b Update.
* sysdeps/i386/dl-machine.h: Define ARCH_FIXUP_ATTRIBUTE and use
	it in the fixup function declarations.
	* elf/dl-runtime.c: If ARCH_FIXUP_ATTRIBUTE is not defined,
	provide dummy definition.  Use macro in fixup function
	definitions.
2004-03-09 07:44:07 +00:00
Ulrich Drepper b30542fb71 Update.
2004-03-08  Ulrich Drepper  <drepper@redhat.com>

	* Makerules: Use extra-modules.mk if modules-names is defined.
	* extra-modules.mk: New file.
	* dlfcn/Makefile (CPPFLAGS-modcxaatexit.c): Removed.
	* elf/Makefile (CFLAGS-interp.c): Add -DNOT_IN_libc=1.
	* csu/Makefile ($(objpfx)version-info.h): Pass -DNOT_IN_libc=1 to
	compiler.
	* Makefile (distribute): Add symbol-hacks.h.
	* sysdeps/generic/symbol-hacks.h: New file.
	* sysdeps/wordsize-32/symbol-hacks.h: New file.
	* sysdeps/wordsize-32/divdi3.c: Define *_internal aliases for __divdi3,
	__moddi3, __udivdi3, and __umoddi3.
	* include/libc-symbols.h: Include <symbol-hacks.h>.
2004-03-08 21:31:23 +00:00
Roland McGrath cc143ec3e0 * elf/rtld.c (_rtld_global_ro) [MAP_COPY]: Don't set _dl_unload_cache.
* sysdeps/mach/hurd/dl-sysdep.c (_dl_important_hwcaps):
	Don't use INTUSE with _dl_signal_error.
2004-03-08 20:38:37 +00:00
Ulrich Drepper 4166148912 Update.
2004-03-07  Andreas Schwab  <schwab@suse.de>

	* elf/dl-sym.c: Include <dl-tls.h> only when USE_TLS.
2004-03-07 19:37:37 +00:00
Ulrich Drepper c31e278f86 Update.
2004-03-07  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/generic/ldsodefs.h: Move _dl_initial_searclist,
	_dl_hp_timing_overhead, _dl_init_all_dirs, and the content of
	dl-procinfo.c from _rtld_global to _rtld_global_ro.
	* elf/rtld.c: Adjust initializer for _rtld_global_ro.
	* elf/dl-close.c: Use GLRO instead of GL where appropriate.
	* elf/dl-libc.c: Likewise.
	* elf/dl-load.c: Likewise.
	* sysdeps/i386/dl-procinfo.h: Likewise.
	* sysdeps/i386/i686/hp-timing.h: Likewise.
	* sysdeps/ia64/hp-timing.h: Likewise.
	* sysdeps/sparc/sparc32/sparcv9/hp-timing.h: Likewise.
	* sysdeps/sparc/sparc64/hp-timing.h: Likewise.
	* sysdeps/unix/sysv/linux/arm/dl-procinfo.h: Likewise.
	* sysdeps/unix/sysv/linux/i386/dl-procinfo.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/sparc32/dl-procinfo.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/sparc64/dl-procinfo.h: Likewise.
2004-03-07 08:39:57 +00:00
Ulrich Drepper 021723ab78 Update.
2004-03-06  Ulrich Drepper  <drepper@redhat.com>

	* elf/dl-lookup.c: We don't need for specialized lookup functions.
	Combining the functionality does not slow down relocation processing,
	it might even speed it up a little.
	* sysdeps/generic/ldsodefs.h: Adjust prototypes for lookup function.
	Add only one function pointer to rtlf_global_ro.
	* elf/do-lookup.h: Replace #ifs with ifs.
	* elf/dl-libc.c: Adjust _dl_lookup_* callers.
	* elf/dl-reloc.c: Likewise.
	* elf/dl-runtime.c: Likewise.
	* elf/dl-sym.c: Likewise.
	* elf/rtld.c: Likewise.  Adjust _rtld_global_ro initialization.

	* sysdeps/generic/ldsodefs.h (__rtld_local_attribute__,
	__rtld_global_attribute__): Undef after use.
	(_rtld_local_ro): Define __rtld_local_attribute__ with just hidden
	if available.

	* sysdeps/alpha/Subdirs: New file.
	* sysdeps/alpha/soft-fp/Makefile: New file.
	* sysdeps/alpha/soft-fp/Versions: New file.
	* sysdeps/alpha/soft-fp/local-soft-fp.h: New file.
	* sysdeps/alpha/soft-fp/ots_add.c: New file.
	* sysdeps/alpha/soft-fp/ots_cmp.c: new file.
	* sysdeps/alpha/soft-fp/ots_cmpe.c: New file.
	* sysdeps/alpha/soft-fp/ots_cvtqux.c: New file.
	* sysdeps/alpha/soft-fp/ots_cvtqx.c: New file.
	* sysdeps/alpha/soft-fp/ots_cvttx.c: New file.
	* sysdeps/alpha/soft-fp/ots_cvtxq.c: New file.
	* sysdeps/alpha/soft-fp/ots_cvtxt.c: New file.
	* sysdeps/alpha/soft-fp/ots_div.c: New file.
	* sysdeps/alpha/soft-fp/ots_mul.c: New file.
	* sysdeps/alpha/soft-fp/ots_nintxq.c: New file.
	* sysdeps/alpha/soft-fp/ots_sub.c: New file.
2004-03-07 05:26:02 +00:00
Ulrich Drepper bdf4a4f1ea We don't need for specialized lookup functions. Combining the functionality does not slow down relocation processing, it might even speed it up a little. 2004-03-07 05:19:40 +00:00
Ulrich Drepper 4df8c11d26 Update.
* configure.in: Recognize --enable-bind-now.
	* elf/dynamic-link.h (elf_get_dynamic_info): Allow bind-now flags
	in ld.so.
	* Makerules (LDFLAGS-c.so): Add -z now if so configured.
	* elf/Makefile ($(objpfx)ld.so): Likewise.
	* config.make.in (bind-now): New definition.
2004-03-06 09:51:56 +00:00
Ulrich Drepper 42af49f875 Update.
* elf/dl-fini.c (_dl_fini): Combine _dl_debug_printf calls.
	* elf/rtld.c (print_statistics): Likewise.
2004-03-06 09:15:58 +00:00
Ulrich Drepper 53bfdc1cf6 Update.
2004-03-06  Ulrich Drepper  <drepper@redhat.com>

	* elf/dl-open.c: No need to pass any parameter to _dl_start_profile.
	They are the same in both places.
	* elf/dl-profile.c: Likewise.
	* elf/rtld.c: Likewise.
	* sysdeps/generic/ldsodefs.h: Likewise.
	* elf/dl-support.c: Define _dl_profile_output variable.  Initialize it.
2004-03-06 09:07:56 +00:00
Ulrich Drepper 154d10bdf1 Update.
* elf/Versions: Remove functions which are not exported anymore.
	* dlfcn/dlerror.c: Call ld.so functions through GLSO.
	* dlfcn/dlinfo.c: Likewise.
	* elf/dl-close.c: Likewise.
	* elf/dl-libc.c: Likewise.
	* elf/dl-open.c: Likewise.
	* elf/dl-sym.c: Likewise.
	* sysdeps/generic/libc-start.c: Likewise.
	* elf/dl-debug.c: Remove *_internal definition.  Don't use INTUSE for
	functions which are not exported anymore.
	* elf/dl-deps.c: Likewise.
	* elf/dl-dst.h: Likewise.
	* elf/dl-error.c: Likewise.
	* elf/dl-fini.c: Likewise.
	* elf/dl-init.c: Likewise.
	* elf/dl-load.c: Likewise.
	* elf/dl-lookup.c: Likewise.
	* elf/dl-misc.c: Likewise.
	* elf/dl-profile.c: Likewise.
	* elf/dl-profstub.c: Likewise.
	* elf/dl-reloc.c: Likewise.
	* elf/dl-runtime.c: Likewise.
	* elf/dl-version.c: Likewise.
	* elf/do-lookup.h: Likewise.
	* include/dlfcn.h: Likewise.
	* sysdeps/generic/dl-cache.c: Likewise.
	* sysdeps/generic/dl-fptr.c: Likewise.
	* sysdeps/generic/dl-origin.c: Likewise.
	* sysdeps/generic/dl-sysdep.c: Likewise.
	* sysdeps/generic/dl-tls.c: Likewise.
	* sysdeps/generic/ldsodefs.h: Likewise.
	* sysdeps/i386/dl-tls.h: Likewise.
	* sysdeps/unix/sysv/linux/dl-origin.c: Likewise.
	* elf/rtld.c: Likewise.  Export function though _rtld_global_ro.

	* generic/dl-fptr.c: Likewise.
	* mach/hurd/dl-sysdep.c: Likewise.
	* unix/sysv/linux/ia64/dl-static.c: Likewise.
	* unix/sysv/linux/ia64/getpagesize.c: Likewise.
	* unix/sysv/linux/m68k/getpagesize.c: Likewise.
	* unix/sysv/linux/sparc/sparc32/getpagesize.c: Likewise.
2004-03-06 08:19:29 +00:00
Ulrich Drepper dd70526e8a Update.
* sysdeps/generic/ldsodefs.h (struct rtld_global): Move
	dl_debug_fd to rtld_global_ro.
	* elf/rtld.c: Use GLRO instead of GL for dl_debug_fd.
	* elf/dl-misc.c: Likewise.
2004-03-05 11:25:26 +00:00
Ulrich Drepper afdca0f2a3 Update.
* sysdeps/sparc/sparc64/dl-machine.h: Likewise.
	* sysdeps/sparc/sparc32/dl-machine.h: Likewise.
	* sysdeps/s390/s390-64/dl-machine.h: Likewise.
	* sysdeps/s390/s390-32/dl-machine.h: Likewise.
	* sysdeps/powerpc/powerpc64/dl-machine.h: Likewise.
	* sysdeps/powerpc/powerpc32/dl-machine.c: Likewise.
	* sysdeps/m68k/dl-machine.h: Likewise.
	* sysdeps/ia64/dl-machine.h: Likewise.
	* sysdeps/arm/dl-machine.h: Likewise.
	* sysdeps/alpha/dl-machine.h: Likewise.
2004-03-05 10:29:47 +00:00
Ulrich Drepper 20c37dfde1 Update.
2004-03-05  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/generic/ldsodefs.h: Define new structure rtld_global_ro.
	Declare _rtld_global_ro and _rtld_local_ro.  Move members of
	rtld_global structure into the new one if they are modified only
	at startup time.  Define GLRO to access _rtld_global_ro.
	* elf/Versions: Export _rtld_global_ro.
	* elf/dl-close.c: Use GLRO instead of GL where appropriate.
	* elf/dl-conflict.c: Likewise.
	* elf/dl-deps.c: Likewise.
	* elf/dl-dst.h: Likewise.
	* elf/dl-error.c: Likewise.
	* elf/dl-fini.c: Likewise.
	* elf/dl-init.c: Likewise.
	* elf/dl-load.c: Likewise.
	* elf/dl-lookup.c: Likewise.
	* elf/dl-minimal.c: Likewise.
	* elf/dl-open.c: Likewise.
	* elf/dl-profile.c: Likewise.
	* elf/dl-reloc.c: Likewise.
	* elf/dl-runtime.c: Likewise.
	* elf/dl-support.c: Likewise.
	* elf/dl-version.c: Likewise.
	* elf/do-lookup.h: Likewise.
	* elf/rtld.c: Likewise.
	* sysdeps/generic/dl-cache.c: Likewise.
	* sysdeps/generic/dl-origin.c: Likewise.
	* sysdeps/generic/dl-sysdep.c: Likewise.
	* sysdeps/generic/libc-start.c: Likewise.
	* sysdeps/generic/dl-cache.c: Likewise.
	* sysdeps/i386/dl-machine.h: Likewise.
	* sysdeps/i386/setfpucw.c: Likewise.
	* sysdeps/i386/fpu/fclrexcpt.c: Likewise.
	* sysdeps/i386/fpu/fedisblexcpt.c: Likewise.
	* sysdeps/i386/fpu/feenablxcpt.c: Likewise.
	* sysdeps/i386/fpu/feholdexcpt.c: Likewise.
	* sysdeps/i386/fpu/fesetround.c: Likewise.
	* sysdeps/i386/fpu/fsetexcptflg.c: Likewise.
	* sysdeps/i386/fpu/ftestexcept.c: Likewise.
	* sysdeps/unix/sysv/linux/dl-execstat.c: Likewise.
	* sysdeps/unix/sysv/linux/dl-librecon.h: Likewise.
	* sysdeps/unix/sysv/linux/dl-origin.c: Likewise.
	* sysdeps/unix/sysv/linux/dl-osinfo.h: Likewise.
	* sysdeps/unix/sysv/linux/getclktck.c: Likewise.
	* sysdeps/unix/sysv/linux/getpagesize.c: Likewise.
	* sysdeps/unix/sysv/linux/init-first.c: Likewise.
	* sysdeps/unix/sysv/linux/prof-freq.c: Likewise.
	* sysdeps/unix/sysv/linux/i386/dl-librecon.h: Likewise.
	* sysdeps/unix/sysv/linux/i386/sigaction.h: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S: Likewise.
	* sysdeps/x86_64/dl-machine.h: Likewise.
2004-03-05 10:15:54 +00:00
Ulrich Drepper dd272e5774 Update.
* sysdeps/generic/ldsodefs.h: Don't define _dl_name_match_p as inline.
	* elf/dl-misc.c: Define _dl_name_match_p here.
	* elf/dl-open.c (check_libc_caller): Don't use _dl_name_match_p.
2004-03-05 04:24:45 +00:00
Ulrich Drepper f213ef0280 Update.
2004-03-04  Ulrich Drepper  <drepper@redhat.com>

	* elf/dl-open.c (dl_open_worker): Check that _dl_open is called
	from the right place.
2004-03-05 03:47:38 +00:00
Ulrich Drepper 49ad572a70 Update.
* elf/rtld.c (dl_main): Adjust l->l_ld of the vDSO by l->l_addr.
	* sysdeps/generic/dl-sysdep.c (_dl_sysdep_start): Only set
	GL(dl_sysinfo) if non-zero.
2004-02-28 17:56:22 +00:00
Ulrich Drepper 3b3ddb4f7d Update.
2004-02-26  Jakub Jelinek  <jakub@redhat.com>

	* elf/rtld.c (dl_main): Correctly set up l_map_end and l_addr
	in vDSO's link_map, don't assume l_addr == 0.  Set GL(dl_sysinfo)
	from e_entry only if AT_SYSINFO not present and adjust by l_addr.
	Take vDSO into account when inserting rtld into _dl_loaded chain.
2004-02-26 20:06:58 +00:00
Ulrich Drepper 445888be74 (elf_get_dynamic_info): Recognize DF_1_NOW. In ld.so, neither DT_FLAGS nor DT_FLAGS_1 must be used. 2004-02-21 22:34:38 +00:00
Andreas Jaeger 14755b91e9 * elf/dl-load.c (_dl_map_object_from_fd): Fix casts used as lvalue.
* iconv/gconv_simple.c (internal_ucs4le_loop): Remove cast used as
	lvalue.
2004-02-21 18:25:59 +00:00
Ulrich Drepper dd0b7b197e Update.
2004-02-20  Ulrich Drepper  <drepper@redhat.com>

	* tst-cancel9.c (cleanup): Don't print to stderr.
2004-02-21 03:20:32 +00:00
Ulrich Drepper 230c3e1e54 Update.
2004-02-20  Thorsten Kukuk  <kukuk@suse.de>

	* nscd/nscd.c (termination_handler): Use _exit instead of exit

	* nscd/nscd.c (main): Report fork errors.
2004-02-21 01:57:26 +00:00
Ulrich Drepper a461b14777 Update.
2004-02-20  Ulrich Drepper  <drepper@redhat.com>

	* dlfcn/dlsym.c: Get ld.so loading lock before the call into ld.so.
	* dlfcn/dlvsym.c: Likewise.
	* elf/dl-addr.c: Get loading lock while using _dl_loaded data.
	* elf/dl-fini.c: Likewise.
	Patch by Shunichi Sagawa <s-sagawa@jp.fujitsu.com>.
2004-02-21 01:06:02 +00:00
Ulrich Drepper 11986c680d Update.
2004-02-19  Steven Munroe  <sjmunroe@us.ibm.com>

	* sysdeps/generic/libc-start.c [LIBC_START_DISABLE_INLINE] (STATIC):
	Define as static.
	* sysdeps/powerpc/elf/libc-start.c: Define LIBC_START_DISABLE_INLINE
	because gcc does not allow inline of functions that call setjmp.

2004-02-19  Steven Munroe  <sjmunroe@us.ibm.com>

	* sysdeps/powerpc/powerpc64/Makefile: Use -finline-limit.

2004-02-19  Jakub Jelinek  <jakub@redhat.com>

	* elf/rtld.c (_dl_argv): If DL_ARGV_NOT_RELRO defined, don't
	use attribute_relro for _dl_argv.
	* sysdeps/alpha/dl-machine.h (DL_ARGV_NOT_RELRO): Define.
	* sysdeps/ia64/dl-machine.h (DL_ARGV_NOT_RELRO): Define.
	* sysdeps/sparc/sparc32/dl-machine.h (DL_ARGV_NOT_RELRO): Define.
	* sysdeps/sparc/sparc64/dl-machine.h (DL_ARGV_NOT_RELRO): Define.

	vfork instead of fork.
2004-02-20 06:07:55 +00:00
Ulrich Drepper f04b9a68fe Update.
* elf/rtld.c (dl_main): Don't fail execution if file named in
	ld.so.preload is not present.
2004-02-17 02:35:52 +00:00
Ulrich Drepper a481b13cc2 Update.
* elf/dl-load.c (lose): Use noinline attribute instead of silly
	alloca to prevent inlining.
	* elf/dl-runtime.c (fixup): Likewise.
	(profile_fixup): Likewise.
2004-02-09 07:10:19 +00:00
Ulrich Drepper e8ed861df7 Update.
2004-01-26  David Mosberger  <davidm@hpl.hp.com>

	* elf/link.h (struct dl_phdr_info): Fix typo in comment.
	* elf/rtld.c (dl_main): After incrementing dl_nloaded, also
	increment dl_load_adds.
	* elf/dl-iteratephdr.c (__dl_iterate_phdr): Replace GL(dl_load_subs)
	with equivalent GL(dl_load_adds - GL(dl_nloaded).
	(dl_iterate_phdr): Likewise.
	* elf/dl-close.c (_dl_close): Delete increment of GL(dl_load_subs).
	* elf/dl-support.c: Remove global variable _dl_load_subs.
	* sysdeps/generic/ldsodefs.h (struct rtld_global): Remove
	_dl_load_subs member.

2004-01-27  Jakub Jelinek  <jakub@redhat.com>

	* elf/rtld.c (_dl_start_final): Don't set l_relro_* here.
	(_dl_start): And neither here.
	(dl_main): Set GL(dl_loaded)->l_relro_* and
	GL(dl_rtld_map)->l_relro_*.
2004-01-27 21:30:46 +00:00
Ulrich Drepper bed12f78fa Update.
2004-01-23  David Mosberger  <davidm@hpl.hp.com>

	* sysdeps/generic/ldsodefs.h (struct rtld_global): Add members
	_dl_load_adds and _dl_load_subs.
	* elf/dl-support.c (_dl_load_adds): New variable.
	(_dl_load_subs): Likewise.
	* elf/dl-object.c (_dl_new_object): Increment dl_load_adds.
	* elf/dl-close.c (_dl_close): Increment dl_load_subs.
	* elf/link.h (struct dl_phdr_info): Add members dlpi_adds and
	dlpi_subs.
	* include/link.h: Likewise.
	* elf/dl-iteratephdr.c (__dl_iterate_phdr): Initialize dlpi_adds
	and dlpi_subs members.
	(dl_iterate_phdr): Likewise.
	* elf/tst-dlmodcount.c: New file.
	* elf/Makefile (distribute): Mention tst-dlmodcount.c.
	(tests): If build-shared, mention tst-dlmodcount.
	($(objpfx)tst-dlmodcount): If build-shared, build and
	run tst-dlmodcount.
2004-01-24 20:12:10 +00:00
Ulrich Drepper e8648a5a87 Update.
2004-01-22  Jakub Jelinek  <jakub@redhat.com>

	* elf/dl-reloc.c (_dl_relocate_object): Move PT_GNU_RELRO protection
	into...
	(_dl_protect_relro): New routine.
	* sysdeps/generic/ldsodefs.h (_dl_protect_relro): New prototype.
	* elf/rtld.c (_dl_start_final): Copy l_relro_addr and l_relro_size
	from bootstrap_map.
	(_dl_main): Don't set GL(_dl_loaded)->l_relro_{addr,size} here.
	Call _dl_protect_relro for libraries if prelinking.
2004-01-24 08:36:13 +00:00
Ulrich Drepper 75631a5763 (_dl_relocate_object): Move PT_GNU_RELRO protection into... (_dl_protect_relro): New routine. 2004-01-24 08:33:05 +00:00
Ulrich Drepper a658675d7b Update.
2004-01-20  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/unix/sysv/linux/readahead.c (__readahead): Use off64_t
	instead of loff_t.  Include <fcntl.h>.
	* sysdeps/unix/sysv/linux/alpha/bits/fcntl.h: Add readahead prototype.
	* sysdeps/unix/sysv/linux/arm/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/cris/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/hppa/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/i386/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/ia64/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/m68k/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/s390/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/sh/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/bits/fcntl.h: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h: Likewise.

	* elf/dl-load.c: Don't add attribute_relro to max_dirnamelen.

	* sysdeps/generic/inttypes.h: Fix PRI*FAST{16,32} macros.

	* include/unistd.h (__libc_enable_secure): Mark attribute_relro.
	(__libc_enable_secure_internal): Likewise.
	* elf/dl-load.c: Don't declare __libc_stack_end.
	* sysdeps/generic/libc-start.c: Likewise.
	* sysdeps/unix/sysv/linux/dl-execstack.c: Likewise.
	* sysdeps/generic/segfault.c: Likewise.  Include ldsodefs.h.
	* sysdeps/generic/backtrace.c: Likewise.
2004-01-20 23:25:27 +00:00
Ulrich Drepper 02e294c24d Define PT_IA_64_HP_OPT_ANOT, PT_IA_64_HP_HSL_ANOT, and PT_IA_64_HP_STACK. 2004-01-16 10:22:21 +00:00
Richard Henderson ff151400d8 * elf/dl-load.c: Don't declare __libc_stack_end. * sysdeps/generic/libc-start.c: Likewise. * sysdeps/unix/sysv/linux/dl-execstack.c: Likewise. * sysdeps/generic/segfault.c: Likewise. Include ldsodefs.h. * sysdeps/generic/backtrace.c: Likewise. linuxthreads/ * attr.c: Include ldsodefs.h. (pthread_getattr_np): Don't declare __libc_stack_end. nptl/ * allocatestack.c: Don't declare __libc_stack_end. * init.c (__pthread_initialize_minimal_internal): Likewise. * pthread_getattr_np.c (pthread_getattr_np): Likewise.
2004-01-16  Richard Henderson  <rth@redhat.com>

        * elf/dl-load.c: Don't declare __libc_stack_end.
        * sysdeps/generic/libc-start.c: Likewise.
        * sysdeps/unix/sysv/linux/dl-execstack.c: Likewise.
        * sysdeps/generic/segfault.c: Likewise.  Include ldsodefs.h.
        * sysdeps/generic/backtrace.c: Likewise.
2004-01-16 08:07:01 +00:00
Ulrich Drepper 39b04aa398 Update.
2004-01-15  Ulrich Drepper  <drepper@redhat.com>

	* elf/rtld.c: Handle platforms with HP_TIMING_NONAVAIL defined.
2004-01-16 03:03:47 +00:00
Ulrich Drepper 828037ae0e Update.
* elf/elf.h: Fix typo in comment.
2004-01-15 22:32:26 +00:00
Ulrich Drepper 697afbe1c8 Update.
* elf/rtld.c: Initialize _dl_argv to allow aliasing.
2004-01-15 18:04:12 +00:00
Ulrich Drepper 392a6b5265 Update.
2004-01-14  Ulrich Drepper  <drepper@redhat.com>

	* configure.in: Define HAVE_Z_RELRO if the linker supports -z relro.
	* config.h.in: Add entry for HAVE_Z_RELRO.
	* include/libc-symbols.h: Define attribute_relro.
	* elf/dl-load.c: Add attribute_relro to env_path_list, capstr, ncapstr,
	max_capstrlen, and max_dirnamelen definitions.
	* elf/rtld.c: Add attribute_relro to _dl_argc, _dl_argv, _dl_skip_args,
	load_time, start_time, library_path, preloadlist, version_info,
	any_debug.
	Remove rtld_total_time.  Make it a local variable.  Pass pointer to
	it to print_statistics.  Change print_statistics accordingly.
	* sysdeps/generic/dl-sysdep.c: Add attribute_relro to _dl_auxv.  Use
	attribute_relro instead of explicitly assigning variable to the
	.data.rel.ro section for __libc_enable_secure and __libc_stack_end.
	* sysdeps/generic/ldsodefs.h: Declare __libc_stack_end, _dl_argc,
	_dl_argv, _dl_argv_internal with attribute_relro.
2004-01-15 06:38:27 +00:00
Ulrich Drepper ea4f25a7f9 Update.
2004-01-13  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/x86_64/dl-machine.h: Include <tls.h>.

	* elf/rtld.c (_dl_start_final): Initialze __libc_stack_end here.
	* sysdeps/generic/dl-sysdep.c: Define __libc_stack_end with
	rtld_hidden_def and move into .data.rel.ro section.
	* sysdeps/generic/ldsodefs.h: Declare __libc_stack_end with
	rtld_hidden_proto.
	* sysdeps/generic/libc-start.c: Only initialize __libc_stack_end here
	if !SHARED.

	* sysdeps/unix/sysv/linux/dl-execstack.c
	(_dl_make_stack_executable): Move common code in front.  Use
	__builtin_expect.
2004-01-14 00:24:36 +00:00
Ulrich Drepper d1fc817ea4 Update.
2004-01-13  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/unix/sysv/linux/dl-execstack.c: Change interface.  Add
	challenge for caller.
	* sysdeps/generic/ldsodefs.h: Change declaration and type of hook
	member in rtld_global appropriately.
	* elf/dl-support.c: Likewise.
	* elf/dl-load.c (_dl_map_object_from_fd): Take additional paramter.
	Pass it on to the changed function.
	(_dl_map_object): Pass new parameter to _dl_map_object_from_fd.
2004-01-13 15:47:32 +00:00
Ulrich Drepper ed20b3d9cc Update.
2004-01-13  Ulrich Drepper  <drepper@redhat.com>

	* Makeconfig: Define relro-LDFLAGS if have-z-relro==yes.  Add it to
	LDFLAGS.so and LDFLAGS-rtld.
	(+link): Add relro-LDFLAGS.
	* Makeconfig (shlib.lds): Place __libc_subfreeres, __libc_atexit, and
	__libc_thread_subfreeres sections after .jcr section.
	* config.make.in: Add have-z-relro.
	* configure.in: Add check for -z relro option.
	* include/link.h (struct link_map): Add relro_addr and relro_size
	members.
	* elf/dl-load.c (_dl_map_object_from_fd): Recognize PT_GNU_RELRO.
	* elf/dl-reloc.c (_dl_relocate_object): At the end, make relro
	part of loaded segments read-only.
	* elf/elf.h: Define PT_GNU_RELRO.
	* elf/rtld.c (_dl_start): Recognize PT_GNU_RELRO of ld.so.
	(dl_main): Recognize PT_GNU_RELRO of the application.  Call
	_dl_debug_initialize and initialize l_info[DT_DEBUG] before
	relocations.
2004-01-13 08:36:54 +00:00
Ulrich Drepper 8e597a18bd Update copyright year. 2004-01-01 20:42:01 +00:00
Ulrich Drepper d4b04a331c Update.
2003-12-31  Ulrich Drepper  <drepper@redhat.com>

	* elf/dl-dst.h (DL_DST_REQUIRED): Avoid the complex operations if
	CNT == 0.
2003-12-31 11:17:09 +00:00
Ulrich Drepper e5ebb9ca48 Update.
2003-12-29  Ulrich Drepper  <drepper@redhat.com>

	* elf/elf.h: Add a few definitions from Solaris 9.
2003-12-29 18:51:29 +00:00
Ulrich Drepper bbe35eb571 Update.
2003-12-20  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/unix/sysv/linux/Makefile (CFLAGS-getpid.c): Define.
	* sysdeps/unix/sysv/linux/getpid.c: New file.
2003-12-20 09:58:33 +00:00
Ulrich Drepper 27a754a97b Update.
2003-12-17  Ulrich Drepper  <drepper@redhat.com>

	* elf/rtld.c: Don't use strong_alias to define _rtld_local.  This
	removes the visibility attributes which might be defined earlier
	for some gcc versions.  Instead spell out what strong_alias does
	plus the visibility.
2003-12-17 08:36:34 +00:00
Ulrich Drepper c776b3d717 Update.
2003-12-02  David Mosberger  <davidm@hpl.hp.com>

	* sysdeps/ia64/elf/initfini.c: Add unwind info.

	* sysdeps/ia64/dl-machine.h (elf_machine_matches_host): Mark with
	attribute "unused".
	(elf_machine_dynamic): Mark with attributes "unused" and "const".
	(elf_machine_runtime_setup): Likewise.

	* sysdeps/generic/dl-fptr.c (make_fptr_table): Mark with
	attribute "always_inline".
	* sysdeps/ia64/dl-machine.h (__ia64_init_bootstrap_fdesc_table):
	Likewise.

	* configure.in: Check whether compiler has libunwind support.
	* config.make.in (have-cc-with-libunwind): New variable.
	* config.h.in (HAVE_CC_WITH_LIBUNWIND): New macro.
	* Makeconfig (gnulib): If have-cc-withh-libunwind is "yes", also
	mention -lunwind.

003-11-12  David Mosberger  <davidm@hpl.hp.com>

	* sysdeps/unix/sysv/linux/ia64/sysdep.h: Define DO_CALL_VIA_BREAK.
	Redefine DO_CALL to use vdso if supported, otherwise DO_CALL_VIA_BREAK.
	Likewise for DO_INLINE_SYSCALL.  Make INTERNAL_SYSCALL use
	DO_INLINE_SYSCALL.

	* sysdeps/unix/sysv/linux/ia64/vfork.S: Use DO_CALL_VIA_BREAK()
	instead of DO_CALL().

	* sysdeps/unix/sysv/linux/ia64/clone2.S: Use break directly instead
	of DO_CALL().

	* sysdeps/unix/sysv/linux/ia64/brk.S (__curbrk): Restructure it
	to take advantage of DO_CALL() macro.
	* sysdeps/unix/sysv/linux/ia64/setcontext.S: Likewise.
	* sysdeps/unix/sysv/linux/ia64/getcontext.S: Likewise.

	* elf/rtld.c (dl_main): Restrict dl_sysinfo_dso check to first
	program header.  On ia64, the check failed previously because
	there are two program headers.

	* sysdeps/generic/s_nexttowardf.c: Likewise.
	* math/bug-nexttoward.c: New file.
2003-12-10 23:02:33 +00:00
Ulrich Drepper 6def43e690 Update.
2003-11-21  David Mosberger  <davidm@hpl.hp.com>

	* elf/soinit.c (_fini): Put _fini() in .init_array section if
	HAVE_INITFINI_ARRAY is defined.
2003-11-26 07:15:17 +00:00
Ulrich Drepper 97fd3a3003 Update.
2003-11-25  Ulrich Drepper  <drepper@redhat.com>

	* posix/runptests.c (main): Make errors fatal.
	* posix/PTESTS: One test in GA135 and GA136 check functionality
	which seems not guaranteed.

2003-11-25  Jakub Jelinek  <jakub@redhat.com>

	* posix/regexec.c (re_search_internal): If prune_impossible_nodes
	returned REG_NOMATCH, set match_last to -1.  Don't initialize
	pmatch[0] needlessly.  Fix comment.
	(prune_impossible_nodes): Don't segfault on NULL state_log entry.
	(set_regs): Fix comment.
	* posix/regcomp.c (parse_bracket_exp): Only set has_plural_match
	if adding both SIMPLE_BRACKET and COMPLEX_BRACKET.
	(build_charclass_op): Set has_plural_match if adding both
	SIMPLE_BRACKET and COMPLEX_BRACKET.
	* posix/bug-regex11.c (tests): Fix register values for one commented
	out test.  Add new tests.

	* posix/regex_internal.c (re_string_allocate): Make sure init_len
	is at least dfa->mb_cur_max.
	(re_string_reconstruct): If is_utf8, don't fall back into
	re_string_skip_chars just because idx points into a middle of
	valid UTF-8 character.  Instead, set the wcs bytes which correspond
	to the partial character bytes to WEOF.
	* posix/regexec.c (re_search_internal): Allocate input.bufs_len + 1
	instead of dfa->nodes_len + 1 state_log entries initially.
	* posix/bug-regex20.c (main): Uncomment backwards case insensitive
	tests.
2003-11-26 03:24:15 +00:00
Ulrich Drepper 476238abeb Update.
* elf/rtld.c (map_doit): Pass __RTLD_OPENEXEC in last parameter to
	_dl_map_object.
2003-10-27 20:09:12 +00:00
Ulrich Drepper 9a267ae298 Update.
* elf/sprof.c (load_shobj): Use l_map_start not l_addr to locate
	ELF header.
2003-10-27 09:18:17 +00:00
Ulrich Drepper 5a4b5076f1 Update.
* include/dlfcn.h (__RTLD_OPENEXEC): Define.
	* elf/dl-load.c (_dl_map_object_from_fd): Don't allow loading
	executables unless __RTLD_OPENEXEC flag is present.
	* elf/rtld.c (dl_main): Pass __RTLD_OPENEXEC flag to
	_dl_map_object when loading the executable.

	reverse lookup format for IPv6 addresses is using bitstring and
	* resolv/ns_name.c: Implement encoding and decoding bitstring in
2003-10-27 01:36:12 +00:00
Roland McGrath 27d640befb * sysdeps/unix/sysv/linux/hppa/sysdep.h: Fix merge error.
2003-10-15  Roland McGrath  <roland@redhat.com>

	* elf/dl-iteratephdr.c [! SHARED] (dl_iterate_phdr): New function.
	Fake an entry for the main executable and then call __dl_iterate_phdr.
	* elf/Makefile (routines): Remove dl-iteratephdr-static.
	(elide-routines.os): Likewise.
	(CFLAGS-dl-iterate-phdr-static.c): Variable removed.
	* sysdeps/generic/dl-iteratephdr-static.c: File removed.
	* sysdeps/unix/sysv/linux/ia64/dl-iteratephdr-static.c: File removed.
2003-10-22 07:10:00 +00:00
Ulrich Drepper a21a20a33f Update.
2003-10-15  Jakub Jelinek  <jakub@redhat.com>

	* elf/rtld.c (print_statistics): Print also number of relative
	relocations.
2003-10-15 06:24:26 +00:00
Roland McGrath b49329d93c 2003-10-09 Roland McGrath <roland@redhat.com>
* elf/rtld.c (dl_main): Don't set l_name for sysinfo DSO, since there
	is no file to name.
2003-10-09 22:34:17 +00:00
Ulrich Drepper b77ca0e827 Update.
2003-10-01  Thorsten Kukuk  <kukuk@suse.de>

	* elf/dl-reloc.c (_dl_allocate_static_tls): Move definition of
	variables only used if TLS_DTV_AT_TP is defined into the #if branch.
2003-10-02 18:58:31 +00:00
Roland McGrath f28c14d69a * elf/rtld.c (dl_main): Add cast in last change. 2003-10-01 07:15:10 +00:00
Ulrich Drepper f556dbfa41 Update.
2003-09-30  Ulrich Drepper  <drepper@redhat.com>

	* elf/rtld.c (dl_main): Also set l_map_start.

2003-09-30  Daniel Jacobowitz  <drow@mvista.com>

	* elf/rtld.c (dl_main): Set l_libname and l_name for the sysinfo DSO
	to work around kernel problem.
2003-09-30 20:37:46 +00:00
Ulrich Drepper 3c6904fb49 Update.
2003-09-27  Wolfram Gloger  <wg@malloc.de>

	* malloc/malloc.c: Include <malloc-machine.h> earlier instead of
	"thread-m.h", so that default parameters can be overridden in a
	system-specific malloc-machine.h.  Remove extra ; from extern "C"
	closing brace.
	* sysdeps/generic/malloc-machine.h: New file.
	* sysdeps/mach/hurd/malloc-machine.h: New file.
	* malloc/thread-m.h: Removed.
	* malloc/Makefile: Remove CFLAGS-malloc.c parameter addition, it
	is in sysdeps/generic/malloc-machine.h now.

	* elf/dl-reloc.c (_dl_allocate_static_tls): Move definition of
	variables only used if TLS_TCB_AT_TP is defined into the #if
	branch.
2003-09-30 02:10:33 +00:00
Ulrich Drepper 9771695416 Update.
2003-09-24  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/ia64/dl-machine.h (RTLD_START): Remove setting of
	__libc_stack_end.  Patch by David Mosberger.

2003-09-24  Jakub Jelinek  <jakub@redhat.com>

	* elf/Versions (ld): Export __libc_stack_end@GLIBC_2.1 instead of
	__libc_stack_end@GLIBC_PRIVATE.

	* sysdeps/generic/dl-sysdep.c (DL_STACK_END): Define if not defined.
	(_dl_sysdep_start): Set __libc_stack_end here.
	* sysdeps/alpha/dl-machine.h (RTLD_START): Remove setting of
	__libc_stack_end.
	* sysdeps/arm/dl-machine.h (RTLD_START): Likewise.
	* sysdeps/cris/dl-machine.h (RTLD_START): Likewise.
	* sysdeps/i386/dl-machine.h (RTLD_START): Likewise.
	* sysdeps/m68k/dl-machine.h (RTLD_START): Likewise.
	* sysdeps/s390/s390-32/dl-machine.h (RTLD_START): Likewise.
	* sysdeps/s390/s390-64/dl-machine.h (RTLD_START): Likewise.
	* sysdeps/sh/dl-machine.h (RTLD_START): Likewise.
	* sysdeps/x86_64/dl-machine.h (RTLD_START): Likewise.
	* sysdeps/ia64/dl-machine.h (DL_STACK_END): Define.
	* sysdeps/sparc/sparc32/dl-machine.h (DL_STACK_END): Define.
	(RTLD_START): Remove setting of __libc_stack_end.
	* sysdeps/sparc/sparc64/dl-machine.h (DL_STACK_END): Define.
	(RTLD_START): Remove setting of __libc_stack_end.

2003-09-24  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/unix/sysv/linux/sys/sysmacros.h: Add gnu_dev_ prefix to
	function definitions.  Adjust macro expansions accordingly.
	* sysdeps/unix/sysv/linux/Versions: Add gnu_dev_ prefix to major,
	minor, makedev name.
	* sysdeps/unix/sysv/linux/makedev.c: Likewise.

2003-09-24  Jakub Jelinek  <jakub@redhat.com>

	* sysdeps/unix/sysv/linux/sys/sysmacros.h (major, minor, makedev):
	Add __THROW.
2003-09-24 21:13:55 +00:00
Roland McGrath c70ba48888 * elf/rtld.c (dl_main): In rtld_is_main case, reinitialize
GL(dl_stack_flags) according to rtld's own PT_GNU_STACK.
	Move GL(dl_make_stack_executable_hook) initialization up.
	* elf/tst-execstack-prog.c: New file.
	* elf/Makefile (tests-execstack-yes): Add it.
	(LDFLAGS-tst-execstack-prog): New variable.
2003-09-24 01:56:08 +00:00
Roland McGrath 2abf9ff113 * sysdeps/i386/dl-machine.h (RTLD_START): Set __libc_stack_end before
calling _dl_start, using GOTOFF access.

	* configure.in (libc_cv_z_execstack): New check.
	* configure: Regenerated.
	* config.make.in (have-z-execstack): New variable set by it.
	* elf/tst-execstack.c: New file.
	* elf/tst-execstack-mod.c: New file.
	* elf/tst-execstack-needed.c: New file.
	* elf/Makefile (tests-execstack-yes, modules-execstack-yes): New
	variables.
	(tests, modules-names): Conditionally include them.
	(distribute): Add tst-execstack-mod.c here.
	($(objpfx)tst-execstack, $(objpfx)tst-execstack.out): New targets.
	(LDFLAGS-tst-execstack, LDFLAGS-tst-execstack-mod): New variables.
	($(objpfx)tst-execstack-needed): New target.
	(LDFLAGS-tst-execstack-needed): New variable.

	* sysdeps/generic/ldsodefs.h (struct rtld_global): Add _dl_stack_flags
	and _dl_make_stack_executable_hook.  Declare _dl_make_stack_executable.
	* elf/rtld.c (_rtld_global): Add initializer for _dl_stack_flags.
	(dl_main): Reset _dl_stack_flags according to PT_GNU_STACK phdr.
	Initialize _dl_make_stack_executable_hook.
	* elf/dl-support.c: Define those new variables.
	(_dl_non_dynamic_init): Scan phdrs for PT_GNU_STACK.
	(_dl_phdr): Fix type.
	* elf/dl-load.c (_dl_map_object_from_fd): Grok PT_GNU_STACK phdr and
	enable execute permission for the stack if necessary.
	* sysdeps/generic/dl-execstack.c: New file.
	* elf/Makefile (dl-routines): Add it.
	* elf/Versions (ld: GLIBC_PRIVATE): Add _dl_make_stack_executable.
	* sysdeps/unix/sysv/linux/dl-execstack.c: New file.
2003-09-23 12:07:26 +00:00
Roland McGrath ecdeaac05f 2003-09-23 Roland McGrath <roland@redhat.com>
* sysdeps/generic/ldsodefs.h (struct rtld_global): Add _dl_stack_flags
	and _dl_make_stack_executable_hook.  Declare _dl_make_stack_executable.
	* elf/rtld.c (_rtld_global): Add initializer for _dl_stack_flags.
	(dl_main): Reset _dl_stack_flags according to PT_GNU_STACK phdr.
	Initialize _dl_make_stack_executable_hook.
	* elf/dl-support.c: Define those new variables.
	(_dl_non_dynamic_init): Scan phdrs for PT_GNU_STACK.
	(_dl_phdr): Fix type.
	* elf/dl-load.c (_dl_map_object_from_fd): Grok PT_GNU_STACK phdr and
	enable execute permission for the stack if necessary.
	* sysdeps/generic/dl-execstack.c: New file.
	* elf/Makefile (dl-routines): Add it.
	* elf/Versions (ld: GLIBC_PRIVATE): Add _dl_make_stack_executable.
	* sysdeps/unix/sysv/linux/dl-execstack.c: New file.
2003-09-23 12:06:48 +00:00
Ulrich Drepper 5896ffa882 Update.
* elf/Makefile ($(objpfx)librtld.os): Create link map also for
	final build to ease quality control.
2003-09-20 06:16:45 +00:00
Ulrich Drepper 06f6ca9019 Update.
2003-09-17  Philip Blundell  <philb@gnu.org>

	* sysdeps/unix/sysv/linux/arm/vfork.S: Branch to fork if
	libpthread is loaded.  Elide backwards compatibility code when not
	required.
2003-09-17 18:23:49 +00:00
Ulrich Drepper e07bb02a4f Update.
2003-09-15  Jakub Jelinek  <jakub@redhat.com>

	* argp/argp.h (argp_parse, __argp_parse): Remove __THROW.
	* argp/Makefile (CFLAGS-argp-help.c, CFLAGS-argp-parse.c): Add
	$(uses-callbacks).
	* dirent/Makefile (CFLAGS-scandir.c, CFLAGS-scandir64.c): Likewise.
	* elf/Makefile (CFLAGS-dl-iterate-phdr.c,
	CFLAGS-dl-iterate-phdr-static.c): Add $(uses-callbacks).
	* elf/dl-iteratephdr.c (cancel_handler): New function.
	(__dl_iterate_phdr): Add __libc_cleanup_{push,pop}.
	* elf/link.h (dl_iterate_phdr): Remove __THROW.
	* io/Makefile (CFLAGS-fts.c): Merge into one assignment.
	Add $(uses-callbacks).
	(CFLAGS-ftw.c, CFLAGS-ftw64.c): Add $(uses-callbacks).
	* misc/Makefile (CFLAGS-tsearch.c, CFLAGS-lsearch.c): Change
	$(exceptions) to $(uses-callbacks).
	* Makeconfig (uses-callbacks): Set to $(exceptions).
	* posix/Makefile (CFLAGS-glob.c, CFLAGS-glob64.c): Add
	$(uses-callbacks).
	* stdlib/Makefile (CFLAGS-bsearch.c, CFLAGS-msort.c, CFLAGS-qsort.c):
	Likewise.
2003-09-16 05:54:09 +00:00
Ulrich Drepper 6fee336275 Update.
2003-09-11  H.J. Lu  <hongjiu.lu@intel.com>

	* elf/tls-macros.h (TLS_IE): Add a stop bit for ia64.
	(TLS_LD): Likewise.
	(TLS_GD): Likewise.

2003-09-11  Jakub Jelinek  <jakub@redhat.com>

	* libio/fileops.c (_IO_new_file_overflow): Add INTUSE to
	_IO_free_backup_area call.
2003-09-11 23:57:58 +00:00
Ulrich Drepper 2fe98a4ae7 Update.
2003-08-26  Jakub Jelinek  <jakub@redhat.com>

	* elf/ldconfig.c (search_dir): When checking for GNU-style .so
	link file use the real file name, not the resolved name we got by
	following the symlinks.
2003-08-26 08:08:21 +00:00
Ulrich Drepper 82d8607da1 Update.
2003-08-25  Jakub Jelinek  <jakub@redhat.com>

	* elf/ldconfig.c (search_dir): Treat symlink as regular file
	if it won't point to itself unless it is .so symlink for the linker.
2003-08-25 21:50:13 +00:00
Ulrich Drepper 062df96045 (save_cache): Don't write beyond end of file_entries buffer. Duplicate last old cache entry if the count would be odd. 2003-08-25 18:37:54 +00:00
Ulrich Drepper 395412a0e8 Update.
2003-08-25  Ulrich Drepper  <drepper@redhat.com>

	* elf/ldconfig.c (search_dir): Revert patch of 2003-7-21.
2003-08-25 09:06:06 +00:00
Ulrich Drepper b61c8aba80 Update.
2003-08-13  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/unix/sysv/linux/i386/syscalls.list: Add time syscall.

	* elf/Makefile: Use LC_ALL=C in a few cases where we call external
	text processing tools.

	* sysdeps/pthread/aio_misc.h (struct waitlist): Don't add caller_pid
	element unless BROKEN_THREAD_SIGNALS is defined.
	(struct requestlist): Likewise.
	* sysdeps/pthread/aio_misc.c (__aio_enqueue_request): Don't fill in
	caller_pid of new request unless BROKEN_THREAD_SIGNALS is defined.
	* sysdeps/pthread/aio_suspend.c (aio_suspend): Likewise.
	* sysdeps/pthread/aio_notify.c (__aio_notify_only): Remove caller_pid
	parameter unless BROKEN_THREAD_SIGNALS is defined.  Adjust callers.
	Pass current PID to __aio_sigqueue.
	* sysdeps/pthread/lio_listio.c (lio_listio): Adjust __aio_notify_only
	call.  Don't initialize caller_pid field of waitlist element.
2003-08-14 00:14:43 +00:00
Ulrich Drepper 334fcf2a65 Update.
2003-08-07  Jakub Jelinek  <jakub@redhat.com>

	* sysdeps/generic/ldsodefs.h (_rtld_global): Add
	_dl_rtld_lock_recursive and _dl_rtld_unlock_recursive.
	* elf/rtld.c (rtld_lock_default_lock_recursive,
	rtld_lock_default_unlock_recursive): New functions.
	(dl_main): Initialize _dl_rtld_lock_recursive and
	_dl_rtld_unlock_recursive.

2003-08-05  Jakub Jelinek  <jakub@redhat.com>

	* elf/ldconfig.c (main): Append SLIBDIR and LIBDIR to
	config_file directories instead of prepending.
2003-08-08 07:43:03 +00:00
Ulrich Drepper d347a4ab1d Update.
2003-07-31  Jakub Jelinek  <jakub@redhat.com>

	* dlfcn/dlerror.c (once): New.
	(dlerror): Call __libc_once.
	(_dlerror_run): Remove once.

2003-07-31  Jakub Jelinek  <jakub@redhat.com>

	* sysdeps/unix/sysv/linux/ia64/bits/sigcontext.h (struct sigcontext):
	Sync with 2.5.7 and 2.5.73 kernel changes.

2003-07-31  Jakub Jelinek  <jakub@redhat.com>

	* dlfcn/eval.c (funcall): Add noinline attribute to shut up warnings.
	* elf/rtld.c (dl_main): Cast ElfW(Addr) arguments with %Zx/%Zd
	formats to size_t.
	* elf/dl-lookup.c (_dl_debug_bindings): Likewise.
	* elf/tst-tls6.c (do_test): Use %zd format for l_tls_modid.
	* elf/tst-tls8.c (do_test): Use %zd format for modid1 and modid2.
	* gmon/tst-sprofil.c (main): Add parens to shut up warning.
	* iconv/tst-iconv3.c (main): Use %td instead of %zd for pointer
	difference argument.
	* stdio-common/tst-wc-printf.c (main): Cast arguments with %C
	format to wint_t.
	* stdlib/tst-limits.c (main): For WORD_BIT and LONG_BIT, use
	%d format and cast expected value to int.
	* sysdeps/generic/libc-start.c (STATIC): Add
	__attribute__((always_inline) if LIBC_START_MAIN is already defined.
	* sysdeps/powerpc/fpu/w_sqrt.c (a_nan, a_inf): Change from uint32_t
	to ieee_float_shape_type.
	(__sqrt): Avoid type punning.
	* sysdeps/powerpc/fpu/w_sqrtf.c (a_nan, a_inf): Change from uint32_t
	to ieee_float_shape_type.
	(__sqrtf): Avoid type punning.
	* sysdeps/s390/s390-32/dl-machine.h (elf_machine_rela): Don't define
	refsym if in dl-conflict.c.
	* sysdeps/s390/s390-64/dl-machine.h (elf_machine_rela): Likewise.
	* sysdeps/unix/sysv/linux/i386/semctl.c (union semun): Add __old_buf.
	(__new_semctl): Shut up warning.
	* sysdeps/unix/sysv/linux/semctl.c (union semun): Add __old_buf.
	(__new_semctl): Shut up warning.
	* sysdeps/unix/sysv/linux/shmctl.c (__new_shmctl): Wrap long lines.
	Change old into union of __old_shmid_ds and __old_shminfo structs.
	Adjust all users.
	* wcsmbs/wcsmbs-tst1.c (main): Cast arguments with %C format to wint_t.

2003-07-31  Jakub Jelinek  <jakub@redhat.com>

	* sysdeps/unix/sysv/linux/utimes.c (__utimes): Fix actime and
	modtime computation.
	* sysdeps/unix/sysv/linux/futimes.c (__futimes): Likewise.
	* sysdeps/posix/utimes.c (__utimes): Likewise.
2003-07-31 19:26:38 +00:00
Ulrich Drepper adc12574e5 Update.
2003-07-30  Jakub Jelinek  <jakub@redhat.com>

	* elf/dl-reloc.c (_dl_allocate_static_tls): Don't return any value,
	call dl_signal_error directly.  If already relocated, call
	GL(dl_init_static_tls) directly, otherwise queue it for later.
	(CHECK_STATIC_TLS): Undo 2003-07-24 change.
	* elf/rtld.c (dl_main): Initialize GL(dl_init_static_tls).
	* elf/dl-open.c (dl_open_worker): Call GL_dl_init_static_tls
	for all static TLS initializations delayed in _dl_allocate_static_tls.
	* elf/dl-support.c (_dl_init_static_tls): New variable.
	* include/link.h (struct link_map): Add l_need_tls_init.
	* sysdeps/generic/ldsodefs.h (_rtld_global): Add _dl_init_static_tls.
	(_dl_nothread_init_static_tls): New prototype.
	(_dl_allocate_static_tls): Adjust prototype.

	* elf/tls-macros.h (VAR_INT_DEF): Add alignment directive.

	elf_machine_rela_relative): Adjust.
	(CHECK_STATIC_TLS): _dl_allocate_static_tls can fail now.
2003-07-31 07:42:20 +00:00
Ulrich Drepper 9722e6f3e2 (_dl_allocate_static_tls): Don't return any value, call dl_signal_error directly. If already relocated, call GL(dl_init_static_tls) directly, otherwise queue it for later. (CHECK_STATIC_TLS): Undo 2003-07-24 change. 2003-07-31 07:34:08 +00:00
Alexandre Oliva 87d254a7bf * elf/dynamic-link.h (elf_machine_rel, elf_machine_rela, elf_machine_rel_relative, elf_machine_rela_relative): Don't assume reloc_addr is aligned. * sysdeps/alpha/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/arm/dl-machine.h (elf_machine_rel, elf_machine_rela, elf_machine_rel_relative, elf_machine_rela_relative): Adjust. * sysdeps/cris/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/hppa/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/i386/dl-machine.h (elf_machine_rel, elf_machine_rela, elf_machine_rel_relative, elf_machine_rela_relative): Adjust. * sysdeps/ia64/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/m68k/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/mips/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/powerpc/powerpc32/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/powerpc/powerpc64/dl-machine.h (elf_machine_rela_relative, elf_machine_rela): Adjust. * sysdeps/s390/s390-32/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/s390/s390-64/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): * sysdeps/sh/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/sparc/sparc32/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/sparc/sparc64/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust. * sysdeps/x86_64/dl-machine.h (elf_machine_rela, elf_machine_rela_relative): Adjust.
2003-07-31  Alexandre Oliva  <aoliva@redhat.com>

	* elf/dynamic-link.h (elf_machine_rel, elf_machine_rela,
	elf_machine_rel_relative, elf_machine_rela_relative): Don't assume
	reloc_addr is aligned.
	* sysdeps/alpha/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/arm/dl-machine.h (elf_machine_rel, elf_machine_rela,
	elf_machine_rel_relative, elf_machine_rela_relative): Adjust.
	* sysdeps/cris/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/hppa/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/i386/dl-machine.h (elf_machine_rel, elf_machine_rela,
	elf_machine_rel_relative, elf_machine_rela_relative): Adjust.
	* sysdeps/ia64/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/m68k/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/mips/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/powerpc/powerpc32/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/powerpc/powerpc64/dl-machine.h
	(elf_machine_rela_relative, elf_machine_rela): Adjust.
	* sysdeps/s390/s390-32/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/s390/s390-64/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): 
	* sysdeps/sh/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/sparc/sparc32/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/sparc/sparc64/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
	* sysdeps/x86_64/dl-machine.h (elf_machine_rela,
	elf_machine_rela_relative): Adjust.
2003-07-31 06:33:53 +00:00
Roland McGrath e4a6507c4c revert bogus commit 2003-07-30 07:06:00 +00:00
Roland McGrath 98c24a32e6 * elf/dl-support.c: Likewise. 2003-07-29 21:28:19 +00:00
Roland McGrath 6e0bb37514 * elf/Makefile: Revert accidental changes in last commit. 2003-07-29 21:14:31 +00:00
Roland McGrath 172ce013bd * elf/dl-support.c (_dl_hwcap): Add nocommon attribute. 2003-07-29 08:57:15 +00:00
Roland McGrath 5181d776e8 * elf/Makefile (tests) [$(build-shared) = yes]:
Depend on $(test-modules).
	* dlfcn/Makefile: Likewise.
2003-07-29 08:36:30 +00:00
Roland McGrath 23195635ae * elf/tst-tls14.c [USE_TLS && HAVE___THREAD]: Conditionalize on this.
* elf/tst-tlsmod14a.c: Likewise.

	* sysdeps/unix/sysv/linux/sys/sysctl.h: Include <linux/compiler.h>
	before <linux/sysctl.h>.
2003-07-28 21:50:26 +00:00
Ulrich Drepper 7b787f8516 Update.
2003-07-24  Jakub Jelinek  <jakub@redhat.com>

	* sysdeps/pthread/aio_cancel.c (aio_cancel): Return AIO_ALLDONE
	if aiocbp != NULL and has already completed.  Return -1/EINVAL if
	aiocbp->aio_fildes does not match fildes.
2003-07-25 07:56:33 +00:00
Ulrich Drepper 99fe3b0e7a Update.
2003-07-24  Ulrich Drepper  <drepper@redhat.com>

	* include/link.h (struct link_map): Add l_tls_firstbyte_offset field.
	* sysdeps/generic/dl-tls.c [TLS_TCB_AT_TP] (_dl_determine_tlsoffset):
	Fix calculation of offsets to take misalignment of first byte in
	file into account.
	* elf/dl-load.c (_dl_map_object_from_fd): Initialize
	l_tls_firstbyte_offset field.
	* elf/rtld.c (_dl_start_final, _dl_start, dl_main): Likewise.
	* elf/dl-reloc.c (_dl_allocate_static_tls): Change return type to int.
	Take l_tls_firstbyte_offset information into account.
	(CHECK_STATIS_TLS): _dl_allocate_static_tls can fail now.
	* sysdeps/generic/ldsodefs.h: Adjust _dl_allocate_static_tls prototype.
	* elf/Makefile: Add rules to build and run tst-tls14.
	* elf/tst-tls14.c: New file.
	* elf/tst-tlsmod14a.c: New file.
	* elf/tst-tlsmod14b.c: New file.
2003-07-24 20:07:00 +00:00
Ulrich Drepper 9d79e0377b Update.
* include/stdio.h (__libc_fatal): Add libc_hidden_proto.
	* include/dlfcn.h (__libc_dlopen_mode, __libc_dlsym, __libc_dlclose):
	Likewise.
	* elf/dl-libc.c (__libc_dlopen_mode, __libc_dlsym, __libc_dlclose):
	Add libc_hidden_def.
	* sysdeps/generic/libc_fatal.c (__libc_fatal): Likewise.
	* sysdeps/posix/libc_fatal.c (__libc_fatal): Likewise.
	* sysdeps/unix/sysv/linux/libc_fatal.c (__libc_fatal): Likewise.
	* elf/Versions (libc): Export __libc_dlopen_mode@@GLIBC_PRIVATE,
	__libc_dlsym@@GLIBC_PRIVATE and __libc_dlclose@@GLIBC_PRIVATE.
	* libio/Versions (libc): Export __libc_fatal@@GLIBC_PRIVATE.
	* sysdeps/generic/unwind-dw2.c: Readd #ifs removed during last
	change.
	* sysdeps/generic/unwind.inc: Removed.
2003-07-22 23:56:53 +00:00
Ulrich Drepper 11bf8ce1d6 Update.
2003-07-22  H.J. Lu  <hongjiu.lu@intel.com>

	* elf/dl-support.c (_dl_hwcap): New variable.
	(_dl_aux_init): Initialize GL(dl_hwcap) for static binaries.

	* sysdeps/i386/fpu/fclrexcpt.c: Include <unistd.h>, <ldsodefs.h>
	and <dl-procinfo.h>.
	(__feclearexcept): Clear MXCSR if needed.
	* sysdeps/i386/fpu/fsetexcptflg.c: Likewise.

	* sysdeps/i386/fpu_control.h (_FPU_GETCW, _FPU_SETCW): Document
	that newer hardware needs more than these macros.

	* sysdeps/i386/setfpucw.c: New file.

2003-07-22  Jakub Jelinek  <jakub@redhat.com>

	* elf/Makefile (CFLAGS-ldconfig.c): Define IS_IN_ldconfig.
	* elf/ldconfig.c: Include dl-procinfo.c.
	(PROCINFO_CLASS): Define.
	* sysdeps/generic/ldsodefs.h (PROCINFO_CLASS): Define.
	* sysdeps/unix/sysv/linux/x86_64/dl-procinfo.c: New file.
	* sysdeps/unix/sysv/linux/x86_64/dl-procinfo.h: New file.
	* sysdeps/unix/sysv/linux/i386/dl-procinfo.c (PROCINFO_CLASS):
	Define if not yet defined.  Use it instead of EXTERN.  Undefine
	at the end of the file.
	* sysdeps/unix/sysv/linux/arm/dl-procinfo.c (PROCINFO_CLASS):
	Likewise.
	* sysdeps/unix/sysv/linux/sparc/sparc32/dl-procinfo.c
	(PROCINFO_CLASS): Likewise.
	* sysdeps/unix/sysv/linux/sparc/sparc64/dl-procinfo.c
	(PROCINFO_CLASS): Likewise.

2003-07-22  H.J. Lu  <hongjiu.lu@intel.com>

	* elf/ldconfig.c (main): Issue a fatal error if relative path
	is used to build cache.

2003-07-22  Ulrich Drepper  <drepper@redhat.com>

	* elf/readlib.c (process_file): Avoid possible overflow in assignment.
2003-07-22 22:28:07 +00:00
Ulrich Drepper f00b19417d (process_file): Avoid possible overflow in assignment. 2003-07-22 21:35:06 +00:00
Andreas Jaeger 7220da7c36 (process_file): Check that file is a shared object. 2003-07-22 20:00:48 +00:00
Andreas Jaeger 422514503d Update.
* elf/sofini.c (__FRAME_END__): Use attribute used so that gcc
	will not optimize it away.
	(__DTOR_END__): Likewise.
	(__CTOR_END__): Likewise.
2003-07-22 19:37:41 +00:00
Ulrich Drepper 1a379ea0c7 Update.
2003-07-21  Ulrich Drepper  <drepper@redhat.com>

	* Makerules (build-module-helper): Add -z defs unless explicitly said
	not to do it.
	* dlfcn/Makefile: Define various *-no-z-defs variables for test DSOs
	which has undefined symbols.
	* elf/Makefile: Likewise.
2003-07-21 22:40:24 +00:00
Ulrich Drepper ca86a76366 Update.
2003-07-21  HJ Lu  <hongjiu.lu@intel.com>

	* elf/ldconfig.c (search_dir): Treat symlink as regular file
	if it won't point to itself.
2003-07-21 20:17:47 +00:00
Roland McGrath c801e76565 2003-06-26 Roland McGrath <roland@redhat.com>
* elf/elf.h (AT_SECURE): New macro.
	* sysdeps/generic/dl-sysdep.c (_dl_sysdep_start): Grok it,
	set __libc_enable_secure.
	(_dl_show_auxv): Add AT_SECURE to name table.
	* elf/dl-support.c (_dl_aux_init): Grok AT_SECURE, set
	__libc_enable_secure and __libc_enable_secure_decided.
	* sysdeps/unix/sysv/linux/ldsodefs.h
	[__ASSUME_AT_SECURE] (HAVE_AUX_SECURE): Define it.
	* sysdeps/unix/sysv/linux/kernel-features.h
	[__LINUX_KERNEL_VERSION >= 132425] (__ASSUME_AT_SECURE): Define it.
2003-06-26 19:54:29 +00:00
Ulrich Drepper 81b215afa3 Update.
2003-06-11  Jakub Jelinek  <jakub@redhat.com>

	* elf/Versions (libc): Add _dl_open_hook@GLIBC_PRIVATE.
	* elf/dl-libc.c (struct dl_open_hook): New.
	(_dl_open_hook): New variable.
	(do_dlsym_private): New function.
	(__libc_dlopen_mode) [!SHARED]: Lookup _dl_open_hook@GLIBC_PRIVATE
	and initialize it if found.
	(__libc_dlopen_mode) [SHARED]: If _dl_open_hook is non-NULL,
	call dlopen_mode hook.
	(__libc_dlsym) [SHARED]: If _dl_open_hook is non-NULL,
	call dlsym hook.
	(__libc_dlclose) [SHARED]: If _dl_open_hook is non-NULL,
	call dlclose hook.
2003-06-25 08:32:03 +00:00
Ulrich Drepper bd89c0b573 Update.
2003-06-25  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/unix/sysv/linux/cris/sysdep.h (INLINE_SYSCALL): Cast
	result to long int so that extensions to long long int work.
	Patch by Uwe Reimann <libc-alpha@pulsar.homelinux.net>.

2003-06-19  Jakub Jelinek  <jakub@redhat.com>

	* elf/ldconfig.c (main): Use add_system_dir instead of add_dir.
	* sysdeps/generic/dl-cache.h (add_system_dir): Define.
	* sysdeps/unix/sysv/linux/x86_64/dl-cache.h: Include sparc
	dl-cache.h.
	* sysdeps/unix/sysv/linux/s390/dl-cache.h: New file.
	* sysdeps/unix/sysv/linux/mips/dl-cache.h: New file.
	* sysdeps/unix/sysv/linux/powerpc/dl-cache.h: New file.
	* sysdeps/unix/sysv/linux/sparc/dl-cache.h: New file.
2003-06-25 08:19:44 +00:00
Roland McGrath 4d4ac6ad6b 2003-06-05 Roland McGrath <roland@redhat.com>
* elf/elf.h (PT_GNU_STACK): New macro.
2003-06-25 01:51:07 +00:00
Ulrich Drepper 4cfde89657 Update.
2003-06-16  Ulrich Drepper  <drepper@redhat.com>

	* elf/rtld.c (dl_main): Use l_map_start not l_addr in Phdr
	computation so that prelinking wroks.

	* inet/netinet/ip6.h (IP6OPT_PAD1, IP6OPT_PADN): Define.
2003-06-16 07:39:03 +00:00
Ulrich Drepper 553eca268c Update.
* elf/dl-iteratephdr.c (__dl_iterate_phdr): Don't skip dynamic
	linker's map.
	* elf/rtld.c (dl_main): Initialize l_phdr and l_phnum of of the
	dynamic linker's map.
2003-06-16 07:00:05 +00:00
Ulrich Drepper 2533775393 Update.
2003-06-13  Ulrich Drepper  <drepper@redhat.com>

	Fixing gcc 3.3 warnings, part II.
	* argp/argp-help.c (hol_entry_long_iterate): Always inline.
	* elf/dl-load.c (cache_rpath): Don't inline.
	* iconvdata/cns11642l2.h: Always inline all functions.
	* iconvdata/iso-ir-165.h: Likewise.
	* locale/Makefile (aux): Add coll-lookup.
	* locale/coll-lookup.c: New file.
	* locale/coll-lookup.h (collidx_table_lookup): Do not define here.
	(collseq_table_lookup): Likewise.
	* locale/weightwc.h: Adjust collidx_table_lookup calls for name change.
	* posix/fnmatch_loop.c: Adjust collseq_table_lookup calls for name
	change.
	* posix/regcomp.c: Likewise.
	* posix/regexec.c: Likewise.
	* locale/programs/3level.h (*_get): Always inline.
	* locale/programs/locfile.h: Move definition of handle_copy to...
	* locale/programs/locfile.c: ...here.
	* locale/programs/ld-collate.c (obstack_int32_grow): Always inline.
	(obstack_int32_grow_fast): Likewise.
	(utf8_encode): Likewise.
	(find_element): Avoid aliasing problems.
	(insert_value): Likewise.
	(collate_read): Likewise.
	* nss/getent.c (print_hosts): Don't inline
	(print_networks): Likewise.
	(print_shadow): Likewise.
	(build_doc): Likewise.
	* nss/nss_files/files-parse.c [ENTDATA] (parser_stclass): Don't
	inline.
	* posix/regcomp.c (re_set_fastmap): Always inline.
	(seek_collating_symbol_entry): Likewise.
	(lookup_collation_sequence_value): Likewise.
	(build_range_exp): Likewise.
	(build_collating_symbol): Likewise.
	* posix/regexec.c (acquire_init_state_context): Don't inline.
	(clean_state_log_if_need): Likewise.
	* resolv/res_send.c (eConsIovec): Rewrite to not return struct and
	adjust all callers.
	(evConsTime): Likewise.
	(evAddTime): Likewise.
	(evSubTime): Likewise.
	(evNowTime): Likewise.
	(evTimeSpec): Removed.
	(__libc_res_nsend): Avoid aliasing problem.
	* sysdeps/unix/sysv/linux/ifreq.h: Move old_siocgifconf definition to..
	* sysdeps/unix/sysv/linux/ifreq.c: ...here.
	* sysdeps/unix/sysv/linux/i386/dl-procinfo.h (_dl_string_hwcap):
	Always inline.
	(_dl_string_platform): Likewise.
	* wctype/wchar-lookup.h (wctype_table_lookup): Always inline.
	(wcwidth_table_lookup): Likewise.
	(wctrans_table_lookup): Likewise.

	* sysdeps/unix/sysv/linux/sys/epoll.h: Include <stdint.h>.
2003-06-13 21:05:42 +00:00
Ulrich Drepper dd9423a67a Update.
2003-06-11  Ulrich Drepper  <drepper@redhat.com>

	* allocatestack.c (queue_stack): Always inline.
	* ptreadhP.h (__do_cancel): Likewise.
2003-06-11 21:57:23 +00:00
Ulrich Drepper bb958f59aa Update.
2003-06-02  Ulrich Drepper  <drepper@redhat.com>

	* posix/getconf.c (main): Also recognize names without the
	__POSIX_ prefix.

	* elf/Makefile (CFLAGS-dl-lookup.c): Define.
2003-06-02 22:44:59 +00:00
Ulrich Drepper 80b5421740 Update.
2003-06-01  Ulrich Drepper  <drepper@redhat.com>

	* elf/Makefile (CFLAGS-dl-runtime.c): Define.

	* wcsmbs/wcpncpy.c (__wcpncpy): Fix broken implementation to match
	stpncpy.
2003-06-01 08:52:38 +00:00
Ulrich Drepper 479aa8ecb2 Update.Update.
2003-05-20  Jakub Jelinek  <jakub@redhat.com>

	* elf/dynamic-link.h (elf_get_dynamic_info): Add temp argument.
	If temp != NULL, copy dynamic entries which need relocation to temp
	array before relocating.
	(DL_RO_DYN_TEMP_CNT): Define.
	* elf/dl-load.c (_dl_map_object_from_fd): Adjust caller.
	* elf/rtld.c (_dl_start): Likewise.
	(dl_main): Likewise.  Add dyn_temp static variable.
2003-05-20 22:36:38 +00:00
Ulrich Drepper 81f3ac4c9a Update.
2003-05-14  Jakub Jelinek  <jakub@redhat.com>

	* elf/rtld.c (dl_main): For LD_TRACE_PRELINKING print search scope
	even if no DT_NEEDED is present.
2003-05-14 21:40:32 +00:00
Ulrich Drepper be4d80380a Update.
* sysdeps/generic/enbl-secure.c (__libc_enable_secure_decided): New
	variable.
	(__libc_init_secure): Don't do anything if __libc_enable_secure_decided
	is nonzero.
	* include/unistd.h: Declare __libc_enable_secure_decided.
	* elf/dl-support.c (_dl_aux_init): Recognize AT_UID, AT_EUID, AT_GID,
	and AT_EGID.  If all found, set __libc_enable_secure and
	__libc_enable_secure_decided.
2003-05-06 06:34:21 +00:00
Ulrich Drepper f866314b89 Update.
2003-04-22  Roland McGrath  <roland@redhat.com>

	* elf/elf.h (AT_SYSINFO_EHDR): New macro, replaces AT_SYSINFO_EH_FRAME.
	* sysdeps/generic/ldsodefs.h (struct rtld_global): Remove
	dl_sysinfo_eh_frame member, add dl_sysinfo_dso member instead.
	* elf/dl-support.c: Update defn.
	* sysdeps/generic/libc-start.c: Don't call __register_frame_info_bases.
	* sysdeps/generic/dl-sysdep.c (_dl_sysdep_start) [NEED_DL_SYSINFO]:
	Set GL(dl_sysinfo_dso) from AT_SYSINFO_EHDR.
	(_dl_show_auxv): Grok AT_SYSINFO_EHDR, not AT_SYSINFO_EH_FRAME.
	* elf/rtld.c (dl_main) [NEED_DL_SYSINFO]: If GL(dl_sysinfo_dso) is
	set, set up a link_map for the preloaded, prelinked object.
2003-05-04 04:30:13 +00:00
Ulrich Drepper 003f9e7223 (AT_SYSINFO_EHDR): New macro, replaces AT_SYSINFO_EH_FRAME. 2003-05-04 04:15:55 +00:00
Roland McGrath 362f5ae2c1 * sysdeps/generic/bp-thunks.h: Protect includes with [!__ASSEMBLER__].
* sysdeps/unix/sysv/linux/i386/bp-thunks.h: Likewise.

	* sysdeps/unix/sysv/linux/Makefile ($(objpfx)syscall-%.h):
	Use $(make-target-directory).
	* sysdeps/unix/Makefile ($(objpfx)stub-syscalls.c): Likewise.

	* Makerules (compile-mkdep-flags): New variable, pass -MD -MF $@.d.
	(compile-command.S): Don't use ifndef.  Append $(compile-mkdep-flags).
	(compile-command.s, compile-command.c): Likewise.
	($(objpfx)%.d): All such pattern rules removed.
	($(+sysdir_pfx)sysd-rules): Don't generate them.
	($(common-objpfx)dummy.d): Target removed.
	(make-dummy-dep): Variable removed.
	(generate-md5): Likewise.
	(%.d: %.dt): New pattern rule.
	(+depfiles): Use $(wildcard) function to get just existing *.d files
	and .d files for existing *.dt files.
	(common-clean): Remove all *.d and *.dt files.
	(before-compile): Add $(objpfx). when it doesn't exist,
	regardless of $(no_deps).
	* elf/rtld-Rules ($(objpfx)rtld-%.d): All such pattern rules removed.
	(rtld-depfiles): Use .os.d instead of .d names.
	Include existing *.d files and .d files for existing *.dt files.

	* Makerules ($(common-objpfx)%.make): Protect with [! subdir].
	Use -MD, -MT and -MF flags instead of SUNPRO_DEPENDENCIES variable.

	* sysdeps/unix/Makefile ($(common-objpfx)s-%.d): Remove compat.h hack.
	Do s-*.d includes only if we have some syscall routines in this subdir.

	* include/libc-symbols.h (libc_freeres_ptr): Use %nobits instead of
	@nobits.  The former is accepted by gas on any ELF platform.
2003-05-02 02:21:25 +00:00
Ulrich Drepper 541765b6b4 Update.
2003-04-26  Ulrich Drepper  <drepper@redhat.com>

	* elf/dl-close.c [USE_TLS && TLS_TCB_AT_TP] (_dl_close): Reimplement
	tracking of freed memory in static TLS block.
	* elf/Makefile: Add rules to build and run tst-tls13.
	* elf/tst-tls13.c: New file.
	* elf/tst-tlsmod13.c: New file.
	* elf/tst-tlsmod13a.c: New file.

	* elf/tst-tls8.c: Adjust types of variables to avoid warnings.

	* elf/dl-reloc.c: Pretty printing.
2003-04-27 06:20:14 +00:00
Ulrich Drepper 669863e271 Test for unloading of modules with TLS in static block. 2003-04-27 06:15:09 +00:00
Ulrich Drepper 06a04e0924 Update.
2003-04-26  Andreas Schwab  <schwab@suse.de>

	* elf/dl-close.c (remove_slotinfo): Fix missing parens.
2003-04-26 20:14:27 +00:00
Ulrich Drepper 299601a1ef Update.
2003-04-22  Jakub Jelinek  <jakub@redhat.com>

	* include/link.h (NO_TLS_OFFSET): Define to 0 if not defined.
	* elf/dl-close.c (_dl_close): Use NO_TLS_OFFSET.
	* elf/dl-object.c (_dl_new_object): Initialize l_tls_offset to
	NO_TLS_OFFSET.
	* elf/rtld.c (_dl_start_final, _dl_start): Likewise.
	* elf/dl-reloc.c (CHECK_STATIC_TLS): Use NO_TLS_OFFSET.
	* sysdeps/generic/dl-tls.c (_dl_allocate_tls_init): Likewise.
	* sysdeps/powerpc/dl-tls.h (TLS_TPREL_VALUE): Don't subtract
	TLS_TCB_SIZE.
2003-04-25 09:12:43 +00:00
Roland McGrath 4c51367922 * elf/dl-reloc.c (_dl_allocate_static_tls): Add internal_function.
* nis/ypclnt.c (__yp_bind): Expect YPDB parameter to always be !=
2003-04-24 17:18:42 +00:00
Roland McGrath 545dbc9345 2003-04-24 Jakub Jelinek <jakub@redhat.com>
* elf/dl-reloc.c (allocate_static_tls): Rename to...
	(_dl_allocate_static_tls): ... this function.  No longer static.
	(CHECK_STATIC_TLS): Adjust.
	* sysdeps/generic/ldsodefs.h (_dl_allocate_static_tls): New prototype.
	* sysdeps/powerpc/powerpc32/dl-machine.h (__process_machine_rela):
	Add SYM_MAP argument.
	(elf_machine_rela): Adjust caller.  Declare SYM_MAP unconditionally.
	Check if SYM_MAP != NULL for R_PPC_DTPREL32.  Only handle 32-bit
	TLS relocs here.  #ifdef out relocs which never appear in
	.gnu.conflict section from dl-conflict.c processing.
	* sysdeps/powerpc/powerpc32/dl-machine.c (__process_machine_rela):
	Add SYM_MAP argument.  Handle 16-bit TLS relocs here.
2003-04-24 17:10:52 +00:00
Roland McGrath 63af556fef * elf/tst-tls12.c (main): Fix declaration.
* elf/tst-tls10.c (dummy): Make hidden instead of static.
	* elf/tst-tlsmod7.c (dummy): Likewise.
	* elf/tst-tlsmod8.c (dummy): Likewise.
	* elf/tst-tlsmod9.c (dummy): Likewise.

2003-04-22  Roland McGrath  <roland@redhat.com>

	* sysdeps/unix/sysv/linux/not-cancel.h: Put parens around macro args.
	(open_not_cancel): Make last argument non-optional.
	* sysdeps/generic/check_fds.c (check_one_fd): Update caller.
	* sysdeps/unix/sysv/linux/gethostid.c (gethostid): Likewise.
	* iconv/gconv_cache.c (__gconv_load_cache): Likewise.

	* include/tls.h: Protect against multiple inclusion.
2003-04-23 01:54:52 +00:00
Ulrich Drepper 94c24227fc Update.
2003-04-16  Jakub Jelinek  <jakub@redhat.com>

	* elf/Makefile (distribute): Add tst-tlsmod{[7-9],1[0-2]}.c and
	tst-tls10.h.
	(tests): Add tst-tls1[0-2].
	(modules-names): Add tst-tlsmod{[7-8],1[0-2]}.
	($(objpfx)tst-tlsmod8.so): Depend on tst-tlsmod7.so.
	($(objpfx)tst-tlsmod10.so): Depend on tst-tlsmod9.so.
	($(objpfx)tst-tlsmod12.so): Depend on tst-tlsmod11.so.
	($(objpfx)tst-tls10): Depend on tst-tlsmod8.so.
	($(objpfx)tst-tls11): Depend on tst-tlsmod10.so.
	($(objpfx)tst-tls12): Depend on tst-tlsmod12.so.
	* elf/tst-tls10.c: New test.
	* elf/tst-tls11.c: New test.
	* elf/tst-tls12.c: New test.
	* elf/tst-tls10.h: New file.
	* elf/tst-tlsmod7.c: New file.
	* elf/tst-tlsmod8.c: New file.
	* elf/tst-tlsmod9.c: New file.
	* elf/tst-tlsmod10.c: New file.
	* elf/tst-tlsmod11.c: New file.
	* elf/tst-tlsmod12.c: New file.

2003-04-15  Steven Munroe  <sjmunroe@us.ibm.com>

	* sysdeps/powerpc/bits/atomic.h: Moved ppc32/64 specific code to ...
	* sysdeps/powerpc/powerpc32/bits/atomic.h: New file.
	* sysdeps/powerpc/powerpc64/bits/atomic.h: New file.

	* posix/regex.h: Include <sys/types.h>.
2003-04-17 19:19:29 +00:00
Ulrich Drepper 162434a682 Update.
2003-04-15  Ulrich Drepper  <drepper@redhat.com>

	* elf/elf.h: Define AT_SYSINFO_EH_FRAME.
	* sysdeps/generic/dl-sysdep.c (_dl_sysdep_start): Handle
	AT_SYSINFO_EH_FRAME.
	(_dl_show_auxv):Display AT_SYSINFO_EH_FRAME value.
	* sysdeps/generic/ldsodefs.h [NEED_DL_SYSINFO] (struct rtld_global):
	Add _dl_sysinfo_eh_frame field.
	* elf/dl-support.c [NEED_DL_SYSINFO]: Define _dl_sysinfo_eh_frame.
	* sysdeps/generic/libc-start.c [NEED_DL_SYSINFO] Define eh_obj
	variable.
	[NEED_DL_SYSINFO] (LIBC_START_MAIN): Call __register_frame_info_bases
	if _dl_sysinfo_eh_frame is non-NULL.

	* Makeconfig (gnulib): Add -lgcc_eh.

	* config.h.in: Define HAVE_FORCED_UNWIND.
2003-04-15 22:46:40 +00:00
Ulrich Drepper 69acbe9f1d (parse_conf): Ignore leading whitespace. Use feof_unlocked instead of feof. (add_dir): Ignire trailing whitespace. 2003-04-08 04:20:29 +00:00
Ulrich Drepper efedd9cf71 Update.
2003-04-06  Jakub Jelinek  <jakub@redhat.com>

	* elf/rtld.c: Revert 2003-03-14 change.
	* elf/dl-conflict.c (_dl_resolve_conflicts): Move
	#if ! ELF_MACHINE_NO_RELA conditional into the routine.
2003-04-06 18:58:09 +00:00
Ulrich Drepper fbb7fc7523 Update.
* elf/tls-macros.h [__ia64__] (TLS_IE, TLS_LD, TLS_GD): Add gp
	register as input to asm.

2003-04-01  Jakub Jelinek  <jakub@redhat.com>
2003-04-01 20:11:20 +00:00
Ulrich Drepper d403820aeb (do_test): Comment out tests which fail in the moment. 2003-03-29 06:49:46 +00:00
Roland McGrath 5972c58b0e * elf/vismod.h (getvarlocal1): Return const char **.
(getvarinmod1): Likewise.
	(getvaritcpt1): Likewise.
	(getvarlocal2): Likewise.
	(getvarinmod2): Likewise.
	(getvaritcpt2): Likewise.
	(getvaritcpt3): Likewise.
	* elf/vismain.c (do_test): Adjusted.
	* elf/vismod1.c (getvarlocal1): Return address.
	(getvarinmod1): Likewise.
	(getvaritcpt1): Likewise.
	* elf/vismod2.c (getvarlocal2): Likewise.
	(getvarinmod2): Likewise.
	(getvaritcpt2): Likewise.
	* elf/vismod3.c (getvaritcpt3): Likewise.

	* elf/vismain.c (do_test): Print both addresses when they don't match.
2003-03-29 03:46:37 +00:00
Roland McGrath 8a3e01b9fb 2003-03-26 H.J. Lu <hjl@gnu.org>
* elf/vismod.h (getvarlocal1): Return const char **.
	(getvarinmod1): Likewise.
	(getvaritcpt1): Likewise.
	(getvarlocal2): Likewise.
	(getvarinmod2): Likewise.
	(getvaritcpt2): Likewise.
	(getvaritcpt3): Likewise.
	* elf/vismain.c (do_test): Adjusted.
	* elf/vismod1.c (getvarlocal1): Return address.
	(getvarinmod1): Likewise.
	(getvaritcpt1): Likewise.
	* elf/vismod2.c (getvarlocal2): Likewise.
	(getvarinmod2): Likewise.
	(getvaritcpt2): Likewise.
	* elf/vismod3.c (getvaritcpt3): Likewise.
2003-03-29 03:46:03 +00:00
Roland McGrath fd54683c97 * Makerules (check-abi) [$(enable-check-abi) = warn]:
Ignore exit status from diff.
	* configure.in (enable_check_abi): Document possible value "warn".
	Change default to no for now.
	* configure: Regenerated.

	* sysdeps/unix/Makefile ($(objpfx)stub-syscalls.c): Emit stub_warning
	macro calls and a #include <stub-tag.h> at the end.
	* Makerules ($(objpfx)stubs): Tweak sed commands.

	* sysdeps/unix/sysv/linux/syscalls.list: Use - rather than EXTRA in
	caller column for *xattr syscalls, since they are in sysdeps/generic.

	* sysdeps/unix/sysv/linux/i386/setfsuid.c: setfsgid -> setfsuid
	* sysdeps/unix/sysv/linux/i386/setfsgid.c: setfsuid -> setfsgid

2003-03-26  Roland McGrath  <roland@redhat.com>

	* Makerules (check-abi-config): Use /thread instead of /tls when
	use-thread and not just use-tls is set.

	* Makerules (update-abi): Put quotes around $(update-abi-config).

	* elf/Makefile (check-abi): Depend on check-abi-ld.
	(update-abi): Depend on update-abi-ld.
2003-03-27 09:48:09 +00:00
Ulrich Drepper 697119d670 Update.
2003-03-25  H.J. Lu  <hjl@gnu.org>

	* elf/dl-lookup.c (_dl_lookup_symbol): Avoid looking up protected
	symbols twice.
	(_dl_lookup_versioned_symbol): Likewise.
2003-03-26 05:55:17 +00:00
Ulrich Drepper 4009bf4044 Update.
2003-03-19  Ulrich Drepper  <drepper@redhat.com>

	* Makefile (distribute): Add include/atomic.h and bits/atomic.h.
	* include/atomic.h: New file.
	* sysdeps/i386/i486/bits/atomic.h: New file.
	* sysdeps/x86_64/bits/atomic.h: New file.
	* sysdeps/s390/bits/atomic.h: New file.
	* sysdeps/sh/bits/atomic.h: New file.
	* sysdeps/ia64/bits/atomic.h: New file.
	* sysdeps/powerpc/bits/atomic.h: New file.
	* sysdeps/generic/bits/atomic.h: New file.
	* sysdeps/i386/i486/atomicity.h: Removed.
	* sysdeps/x86_64/atomicity.h: Removed.
	* sysdeps/s390/s390-32/atomicity.h: Removed.
	* sysdeps/s390/s390-64/atomicity.h: Removed.
	* sysdeps/ia64/atomicity.h: Removed.
	* sysdeps/powerpc/powerpc32/atomicity.h: Removed.
	* sysdeps/powerpc/powerpc64/atomicity.h: Removed.
	* elf/dl-profile.c: Use atomic.h instead of atomicity.h.  Adjust
	use of macros from atomicity.h to new names and semantics.
	* gmon_mcount.c: Likewise.
	* malloc/set-freeres.c: Likewise.
	* nscd/cache.c: Likewise.
	* stdlib/cxa_finalize.c: Likewise.
	* sysdeps/unix/sysv/linux/getsysstats.c: Likewise.

	* sysdeps/mips/ieee754.h: New file, suitable to replace both
	* stdlib/strtod.c (INTERNAL): While eating trailing zeros handle
2003-03-20 07:19:17 +00:00
Roland McGrath 638bb1f394 * nscd/cache.c (cache_search): Give first arg type `request_type'.
* nscd/nscd.h: Update decl.

	* nscd/nscd_getpw_r.c (nscd_getpw_r): Add casts for signedness.
	* nscd/nscd_getgr_r.c (nscd_getgr_r): Likewise.
	* elf/dl-close.c (_dl_close): Likewise.
	* sysdeps/unix/sysv/linux/powerpc/chown.c (__chown): int -> size_t
	* io/fts.c (fts_build): Likewise.
	* elf/cache.c (add_to_cache): Likewise.
	* locale/programs/locarchive.c (show_archive_content): Likewise.

	* posix/fnmatch.c (fnmatch): Tweak __builtin_expect use.

	* include/ctype.h (__ctype_b_loc): Tweak type punning to make gcc 3.3
	happy.
	(__ctype_toupper_loc, __ctype_tolower_loc): Likewise.
2003-03-16 01:04:03 +00:00
Roland McGrath 45e4762c2c * dlfcn/tst-dlinfo.c: New file.
* dlfcn/Makefile (tests): Add tst-dlinfo.
	($(objpfx)tst-dlinfo): New target.

	* dlfcn/dlinfo.c: New file.
	* dlfcn/Makefile (libdl-routines): Add it.
	* dlfcn/Versions (libdl: GLIBC_2.3.3): Add dlinfo.
	* dlfcn/dlfcn.h [__USE_GNU]: Declare dlinfo.
	[__USE_GNU] (RTLD_DI_*): New enum constants.
	[__USE_GNU] (Dl_serpath, Dl_serinfo): New types.
	* elf/dl-load.c (cache_rpath): New inline function.
	(_dl_map_object): Use it.
	(_dl_rtld_di_serinfo): New function.
	* sysdeps/generic/ldsodefs.h: Declare it.
	* elf/Versions (ld: GLIBC_PRIVATE): Add it.
2003-03-15 23:16:22 +00:00
Alexandre Oliva a77dcecfd4 * elf/dl-conflict.c: Don't compile _dl_resolve_conflicts if ELF_MACHINE_NO_RELA is set. * elf/rtld.c (dl_main): No prelink support for REL-only.
* elf/dl-conflict.c: Don't compile _dl_resolve_conflicts if
	ELF_MACHINE_NO_RELA is set.
	* elf/rtld.c (dl_main): No prelink support for REL-only.
2003-03-14 05:34:36 +00:00
Alexandre Oliva b5bac573e6 * sysdeps/generic/ldconfig.h (FLAG_MIPS64_LIBN32, FLAG_MIPS64_LIBN64): Define. * elf/cache.c (print_entry): Handle mips64 n32 and n64.
* sysdeps/generic/ldconfig.h (FLAG_MIPS64_LIBN32,
	FLAG_MIPS64_LIBN64): Define.
	* elf/cache.c (print_entry): Handle mips64 n32 and n64.

2003-03-14  Alexandre Oliva  <aoliva@redhat.com>
2003-03-14 05:32:50 +00:00
Roland McGrath d8a5edc221 * elf/dl-load.c (_dl_map_object_from_fd): Bail if no PT_LOAD phdrs
found.  Reported by Alexandre Oliva <aoliva@redhat.com>.

2003-03-13  Alexandre Oliva  <aoliva@redhat.com>

	* stdio-common/_itoa.c (_itoa_base_table): Make 64-bit
	literals long long.
	* stdlib/fpioconst.c: Likewise.
	* stdlib/strtod.c: Likewise.

	* sysdeps/mips/add_n.S: Use L macro for local labels.
	* sysdeps/mips/addmul_1.S: Likewise.
	* sysdeps/mips/lshift.S: Likewise.
	* sysdeps/mips/memcpy.S: Likewise.
	* sysdeps/mips/memset.S: Likewise.
	* sysdeps/mips/mul_1.S: Likewise.
	* sysdeps/mips/rshift.S: Likewise.
	* sysdeps/mips/sub_n.S: Likewise.
	* sysdeps/mips/submul_1.S: Likewise.
	* sysdeps/mips/mips64/add_n.S: Likewise.
	* sysdeps/mips/mips64/addmul_1.S: Likewise.
	* sysdeps/mips/mips64/lshift.S: Likewise.
	* sysdeps/mips/mips64/mul_1.S: Likewise.
	* sysdeps/mips/mips64/rshift.S: Likewise.
	* sysdeps/mips/mips64/sub_n.S: Likewise.
	* sysdeps/mips/mips64/submul_1.S: Likewise.
	* sysdeps/unix/mips/sysdep.h: Define L() according to ABI
	conventions.  Define END as in sys/asm.h.
	* sysdeps/unix/mips/sysdep.S: Likewise.
	* sysdeps/unix/mips/wait.S: Likewise.
	* sysdeps/unix/sysv/linux/mips/clone.S: Likewise.

	* sysdeps/ieee754/dbl-64/dbl2mpn.c (__mpn_extract_double):
	Cast shifted values that may be too narrow to mp_limb_t.
	* sysdeps/ieee754/dbl-64/mpn2dbl.c (__mpn_construct_double):
	Likewise.
	* sysdeps/ieee754/flt-32/mpn2flt.c (__mpn_construct_float):
	Likewise.
	* sysdeps/ieee754/ldbl-128/ldbl2mpn.c
	(__mpn_extract_long_double): Likewise.
	* sysdeps/ieee754/ldbl-128/mpn2ldbl.c
	(__mpn_construct_long_double): Likewise.
	* sysdeps/ieee754/ldbl-96/ldbl2mpn.c
	(__mpn_extract_long_double): Likewise.
	* sysdeps/ieee754/ldbl-96/mpn2ldbl.c
	(__mpn_construct_long_double): Likewise.

2003-03-13  Roland McGrath  <roland@redhat.com>
2003-03-14 03:59:59 +00:00
Roland McGrath 6461e57784 * elf/Makefile ($(objpfx)librtld.mk): Tweak regexp so that one-line
entries in the map file match too.
2003-03-13 21:51:07 +00:00
Roland McGrath 8dd569934c 2003-03-10 Roland McGrath <roland@redhat.com>
* dlfcn/Makefile (libdl-routines): Add dladdr1.
	* dlfcn/dladdr1.c: New file.
	* dlfcn/dlfcn.h [__USE_GNU]: Declare dladdr1.
	[__USE_GNU] (RTLD_DL_SYMENT, RTLD_DL_LINKMAP): New enum constants.
	* elf/dl-addr.c (_dl_addr): Take new args, a struct link_map ** and
	a const ElfNN_Sym ** to fill in.
	* include/dlfcn.h: Update decl.  Include <link.h>.
	* dlfcn/dladdr.c (dladdr): Update caller.
	* malloc/mtrace.c (tr_where): Likewise.
	* sysdeps/generic/elf/backtracesyms.c: Likewise.
	* sysdeps/generic/elf/backtracesymsfd.c: Likewise.
	* dlfcn/Versions (libdl: GLIBC_2.3.3): New set, add dladdr1.
	* Versions.def (libdl): Define GLIBC_2.3.3 set.
2003-03-10 09:12:11 +00:00
Ulrich Drepper 6fffb9a2c1 Update.
* elf/dl-load.c (_dl_map_object_from_fd): Determine whether there
	are holes between the segments.  Only call mprotect to set
	proection to PROT_NONE if there are some.

	* elf/dl-load.c (struct filebuf): Actually use FILEBUF_SIZE.
	Update comment.
2003-03-04 00:10:34 +00:00
Roland McGrath 868b9d6a26 * elf/dl-load.c (struct filebuf): Fix typo in last change. 2003-03-03 21:23:04 +00:00
Ulrich Drepper ca97fb5325 Update.
* elf/dl-load.c (struct filebuf): For 64-bit platforms use 640
	byte filebuf size.
2003-03-03 19:08:31 +00:00
Ulrich Drepper 7d9952c196 (struct filebuf): Reduce buf array to 512 bytes. 2003-03-03 07:07:44 +00:00