mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-05 21:00:05 +00:00
* sysdeps/powerpc/elf/libc-start.c [! SHARED]: Call
__pthread_initialize_minimal and __libc_check_standard_fds to match the generic version. * sysdeps/powerpc/Makefile (CFLAGS-pt-initfini.s): New variable. * sysdeps/unix/sysv/linux/shmat.c (shmat): Add a cast to avoid a warning when INLINE_SYSCALL macro uses the __syscall_ipc function. * locale/localeconv.c (__localeconv): Cast -1 to char to avoid warnings on platorms where char is unsigned.
This commit is contained in:
parent
a37a5055dc
commit
a2c396f8a9
14
ChangeLog
14
ChangeLog
@ -1,3 +1,17 @@
|
||||
2002-09-02 Roland McGrath <roland@redhat.com>
|
||||
|
||||
* sysdeps/powerpc/elf/libc-start.c [! SHARED]: Call
|
||||
__pthread_initialize_minimal and __libc_check_standard_fds to
|
||||
match the generic version.
|
||||
|
||||
* sysdeps/powerpc/Makefile (CFLAGS-pt-initfini.s): New variable.
|
||||
|
||||
* sysdeps/unix/sysv/linux/shmat.c (shmat): Add a cast to avoid a
|
||||
warning when INLINE_SYSCALL macro uses the __syscall_ipc function.
|
||||
|
||||
* locale/localeconv.c (__localeconv): Cast -1 to char to avoid
|
||||
warnings on platorms where char is unsigned.
|
||||
|
||||
2002-09-02 Ulrich Drepper <drepper@redhat.com>
|
||||
|
||||
* version.h (VERSION): Bump to 2.2.93.
|
||||
|
@ -46,6 +46,11 @@ shared-only-routines += divdi3 libgcc-compat
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(subdir):$(elf),linuxthreads:yes)
|
||||
# See CFLAGS-initfini.s above; this is the same code.
|
||||
CFLAGS-pt-initfini.s = -g0 -fpic -O1
|
||||
endif
|
||||
|
||||
ifeq ($(subdir),string)
|
||||
CFLAGS-memcmp.c += -Wno-uninitialized
|
||||
endif
|
||||
|
@ -33,6 +33,15 @@ weak_extern (__cache_line_size)
|
||||
extern int __libc_multiple_libcs;
|
||||
extern void *__libc_stack_end;
|
||||
|
||||
#ifndef SHARED
|
||||
# include <tls.h>
|
||||
extern void __pthread_initialize_minimal (void)
|
||||
# if !(USE_TLS - 0)
|
||||
__attribute__ ((weak))
|
||||
# endif
|
||||
;
|
||||
#endif
|
||||
|
||||
struct startup_info
|
||||
{
|
||||
void *__unbounded sda_base;
|
||||
@ -43,7 +52,7 @@ struct startup_info
|
||||
|
||||
/* Scan the Aux Vector for the "Data Cache Block Size" entry. If found
|
||||
verify that the static extern __cache_line_size is defined by checking
|
||||
for not NULL. If it is defined then assign the cache block size
|
||||
for not NULL. If it is defined then assign the cache block size
|
||||
value to __cache_line_size. */
|
||||
static inline void
|
||||
__aux_init_cache (ElfW(auxv_t) *av)
|
||||
@ -103,7 +112,7 @@ BP_SYM (__libc_start_main) (int argc, char *__unbounded *__unbounded ubp_av,
|
||||
while (*temp != NULL)
|
||||
++temp;
|
||||
auxvec = (ElfW(auxv_t) *)++temp;
|
||||
|
||||
|
||||
|
||||
# ifndef SHARED
|
||||
_dl_aux_init ((ElfW(auxv_t) *) auxvec);
|
||||
@ -113,7 +122,7 @@ BP_SYM (__libc_start_main) (int argc, char *__unbounded *__unbounded ubp_av,
|
||||
}
|
||||
|
||||
INIT_ARGV_and_ENVIRON;
|
||||
|
||||
|
||||
/* Initialize the __cache_line_size variable from the aux vector. */
|
||||
__aux_init_cache((ElfW(auxv_t) *) auxvec);
|
||||
|
||||
@ -121,6 +130,25 @@ BP_SYM (__libc_start_main) (int argc, char *__unbounded *__unbounded ubp_av,
|
||||
stack, for backtraces. This variable should be thread-specific. */
|
||||
__libc_stack_end = stack_on_entry + 4;
|
||||
|
||||
#ifndef SHARED
|
||||
/* Initialize the thread library at least a bit since the libgcc
|
||||
functions are using thread functions if these are available and
|
||||
we need to setup errno. If there is no thread library and we
|
||||
handle TLS the function is defined in the libc to initialized the
|
||||
TLS handling. */
|
||||
# if !(USE_TLS - 0)
|
||||
if (__pthread_initialize_minimal)
|
||||
# endif
|
||||
__pthread_initialize_minimal ();
|
||||
|
||||
/* Some security at this point. Prevent starting a SUID binary where
|
||||
the standard file descriptors are not opened. We have to do this
|
||||
only for statically linked applications since otherwise the dynamic
|
||||
loader did the work already. */
|
||||
if (__builtin_expect (__libc_enable_secure, 0))
|
||||
__libc_check_standard_fds ();
|
||||
#endif
|
||||
|
||||
/* Register the destructor of the dynamic linker if there is any. */
|
||||
if (rtld_fini != NULL)
|
||||
__cxa_atexit ((void (*) (void *)) rtld_fini, NULL, NULL);
|
||||
|
@ -48,9 +48,10 @@ shmat (shmid, shmaddr, shmflg)
|
||||
length = shmds.shm_segsz;
|
||||
#endif
|
||||
|
||||
result = (void *__unbounded) INLINE_SYSCALL (ipc, 5, IPCOP_shmat, shmid, shmflg,
|
||||
result = (void *__unbounded) INLINE_SYSCALL (ipc, 5, IPCOP_shmat,
|
||||
shmid, shmflg,
|
||||
(long int) __ptrvalue (&raddr),
|
||||
__ptrvalue (shmaddr));
|
||||
__ptrvalue ((void *) shmaddr));
|
||||
if ((unsigned long) result <= -(unsigned long) SHMLBA)
|
||||
result = raddr;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user