1995-05-11 01:02:23 +00:00
|
|
|
|
/* Operating system support for run-time dynamic linker. Hurd version.
|
* sysdeps/mach/hurd/Makefile ($(link-rpcuserlibs)): Don't append
options after $(build-module), which is no longer a single command.
(LDFLAGS-link-rpcuserlibs): New variable to hold those options.
(LDFLAGS-libmachuser-link.so, LDFLAGS-libhurduser-link.so): New
variables using it. Reported by Mark Kettenis <kettenis@gnu.org>.
2001-03-11 Roland McGrath <roland@frob.com>
* elf/rtld.c (dl_main): Add cast to quiet warning.
* elf/dl-load.c (_dl_map_object_from_fd): Likewise.
* iconv/gconv_conf.c (__gconv_get_path): Likewise.
(__gconv_read_conf): Likewise.
* iconv/gconv_db.c (gen_steps): Likewise.
(__gconv_find_transform): Likewise.
* locale/programs/charmap-dir.c (fopen_uncompressed): Likewise.
(fopen_uncompressed): Use const in second argument's type.
2001-03-11 Roland McGrath <roland@frob.com>
* sysdeps/mach/hurd/dl-sysdep.c (__writev): New function.
* mach/mach_error.h: Fix ancient #endif syntax.
* hurd/hurdmalloc.c: Likewise.
* sysdeps/generic/atomicity.h (exchange_and_add, atomic_add,
compare_and_swap): Add volatile qualifier to first arg, to bring
these prototypes in line with all the other implementations.
Add a #warning to remind the builder that these are not atomic.
2001-03-04 Roland McGrath <roland@frob.com>
* hurd/vpprintf.c (vpprintf) [USE_IN_LIBIO]: Use innermore first
member of TEMP_F so its type is _IO_FILE * as expected.
* hurd/fopenport.c (seekio): Conditionalize type of POS argument
on [USE_IN_LIBIO]. Check the value for overflow, since for libio
it might exceed off_t's range.
2001-02-25 Roland McGrath <roland@frob.com>
* sysdeps/mach/hurd/sysd-stdio.c (__stdio_reopen): Use prototype.
* sysdeps/unix/bsd/getpt.c (__posix_openpt): Likewise.
* sysdeps/mach/hurd/i386/intr-msg.h (SYSCALL_EXAMINE): Make this a
macro instead of an inline function,
(MSG_EXAMINE): Likewise.
* hurd/hurd/ioctl.h (_HURD_HANDLE_IOCTLS_1): Remove extraneous ##.
* hurd/get-host.c: Include <string.h> for decls of built-ins.
* hurd/hurdchdir.c: Likewise.
* sysdeps/mach/hurd/i386/sigreturn.c: Likweise.
* sysdeps/mach/hurd/opendir.c: Likewise.
* mach/mach_init.c: Include <unistd.h> for _exit decl.
* mach/errsystems.awk: Give output file a trailing newline.
* mach/Machrules (MIG): Prepend CC='${CC}' to the mig command, so that
the script will use our compiler for the cpp stage.
With --enable-all-warnings we get a whole bunch of warnings,
and these are just a few fixes; there are more needed to silence it.
* mach/mach/mig_support.h (__mig_strncpy, mig_strncpy): Add extern
decls before extern inline defns to quiet gcc warning.
* hurd/hurd/threadvar.h (__hurd_threadvar_location_from_sp): Likewise.
* sysdeps/mach/i386/machine-sp.h (__thread_stack_pointer): Likewise.
2001-04-01 05:04:31 +00:00
|
|
|
|
Copyright (C) 1995,96,97,98,99,2000,2001 Free Software Foundation, Inc.
|
1996-12-20 01:39:50 +00:00
|
|
|
|
This file is part of the GNU C Library.
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
1996-12-20 01:39:50 +00:00
|
|
|
|
The GNU C Library is free software; you can redistribute it and/or
|
2001-07-06 04:58:11 +00:00
|
|
|
|
modify it under the terms of the GNU Lesser General Public
|
|
|
|
|
License as published by the Free Software Foundation; either
|
|
|
|
|
version 2.1 of the License, or (at your option) any later version.
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
1996-12-20 01:39:50 +00:00
|
|
|
|
The GNU C Library is distributed in the hope that it will be useful,
|
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
2001-07-06 04:58:11 +00:00
|
|
|
|
Lesser General Public License for more details.
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
2001-07-06 04:58:11 +00:00
|
|
|
|
You should have received a copy of the GNU Lesser General Public
|
|
|
|
|
License along with the GNU C Library; if not, write to the Free
|
|
|
|
|
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
|
|
|
|
02111-1307 USA. */
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
|
|
|
|
#include <hurd.h>
|
|
|
|
|
#include <link.h>
|
|
|
|
|
#include <unistd.h>
|
|
|
|
|
#include <fcntl.h>
|
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
#include <sys/mman.h>
|
2000-03-23 20:31:46 +00:00
|
|
|
|
#include <ldsodefs.h>
|
1995-05-11 01:02:23 +00:00
|
|
|
|
#include <sys/wait.h>
|
|
|
|
|
#include <assert.h>
|
|
|
|
|
#include <sysdep.h>
|
|
|
|
|
#include <mach/mig_support.h>
|
|
|
|
|
#include "hurdstartup.h"
|
2001-06-17 21:09:28 +00:00
|
|
|
|
#include <hurd/lookup.h>
|
1995-05-11 01:02:23 +00:00
|
|
|
|
#include <hurd/auth.h>
|
|
|
|
|
#include <hurd/term.h>
|
|
|
|
|
#include <stdarg.h>
|
1996-05-04 13:57:05 +00:00
|
|
|
|
#include <ctype.h>
|
1996-07-30 19:23:06 +00:00
|
|
|
|
#include <sys/stat.h>
|
* sysdeps/mach/hurd/Makefile ($(link-rpcuserlibs)): Don't append
options after $(build-module), which is no longer a single command.
(LDFLAGS-link-rpcuserlibs): New variable to hold those options.
(LDFLAGS-libmachuser-link.so, LDFLAGS-libhurduser-link.so): New
variables using it. Reported by Mark Kettenis <kettenis@gnu.org>.
2001-03-11 Roland McGrath <roland@frob.com>
* elf/rtld.c (dl_main): Add cast to quiet warning.
* elf/dl-load.c (_dl_map_object_from_fd): Likewise.
* iconv/gconv_conf.c (__gconv_get_path): Likewise.
(__gconv_read_conf): Likewise.
* iconv/gconv_db.c (gen_steps): Likewise.
(__gconv_find_transform): Likewise.
* locale/programs/charmap-dir.c (fopen_uncompressed): Likewise.
(fopen_uncompressed): Use const in second argument's type.
2001-03-11 Roland McGrath <roland@frob.com>
* sysdeps/mach/hurd/dl-sysdep.c (__writev): New function.
* mach/mach_error.h: Fix ancient #endif syntax.
* hurd/hurdmalloc.c: Likewise.
* sysdeps/generic/atomicity.h (exchange_and_add, atomic_add,
compare_and_swap): Add volatile qualifier to first arg, to bring
these prototypes in line with all the other implementations.
Add a #warning to remind the builder that these are not atomic.
2001-03-04 Roland McGrath <roland@frob.com>
* hurd/vpprintf.c (vpprintf) [USE_IN_LIBIO]: Use innermore first
member of TEMP_F so its type is _IO_FILE * as expected.
* hurd/fopenport.c (seekio): Conditionalize type of POS argument
on [USE_IN_LIBIO]. Check the value for overflow, since for libio
it might exceed off_t's range.
2001-02-25 Roland McGrath <roland@frob.com>
* sysdeps/mach/hurd/sysd-stdio.c (__stdio_reopen): Use prototype.
* sysdeps/unix/bsd/getpt.c (__posix_openpt): Likewise.
* sysdeps/mach/hurd/i386/intr-msg.h (SYSCALL_EXAMINE): Make this a
macro instead of an inline function,
(MSG_EXAMINE): Likewise.
* hurd/hurd/ioctl.h (_HURD_HANDLE_IOCTLS_1): Remove extraneous ##.
* hurd/get-host.c: Include <string.h> for decls of built-ins.
* hurd/hurdchdir.c: Likewise.
* sysdeps/mach/hurd/i386/sigreturn.c: Likweise.
* sysdeps/mach/hurd/opendir.c: Likewise.
* mach/mach_init.c: Include <unistd.h> for _exit decl.
* mach/errsystems.awk: Give output file a trailing newline.
* mach/Machrules (MIG): Prepend CC='${CC}' to the mig command, so that
the script will use our compiler for the cpp stage.
With --enable-all-warnings we get a whole bunch of warnings,
and these are just a few fixes; there are more needed to silence it.
* mach/mach/mig_support.h (__mig_strncpy, mig_strncpy): Add extern
decls before extern inline defns to quiet gcc warning.
* hurd/hurd/threadvar.h (__hurd_threadvar_location_from_sp): Likewise.
* sysdeps/mach/i386/machine-sp.h (__thread_stack_pointer): Likewise.
2001-04-01 05:04:31 +00:00
|
|
|
|
#include <sys/uio.h>
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
1998-07-14 19:43:02 +00:00
|
|
|
|
#include <entry.h>
|
|
|
|
|
#include <dl-machine.h>
|
|
|
|
|
#include <dl-procinfo.h>
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
1995-05-31 13:23:14 +00:00
|
|
|
|
extern void __mach_init (void);
|
|
|
|
|
|
1995-05-11 01:02:23 +00:00
|
|
|
|
extern int _dl_argc;
|
|
|
|
|
extern char **_dl_argv;
|
|
|
|
|
extern char **_environ;
|
|
|
|
|
|
1996-07-29 03:49:00 +00:00
|
|
|
|
int __libc_enable_secure;
|
2000-08-15 16:25:27 +00:00
|
|
|
|
int __libc_multiple_libcs = 0; /* Defining this here avoids the inclusion
|
1998-07-14 19:43:02 +00:00
|
|
|
|
of init-first. */
|
|
|
|
|
/* This variable containts the lowest stack address ever used. */
|
|
|
|
|
void *__libc_stack_end;
|
|
|
|
|
unsigned long int _dl_hwcap_mask = HWCAP_IMPORTANT;
|
1998-07-17 12:36:43 +00:00
|
|
|
|
|
1996-07-29 03:49:00 +00:00
|
|
|
|
|
1995-05-11 01:02:23 +00:00
|
|
|
|
struct hurd_startup_data *_dl_hurd_data;
|
|
|
|
|
|
1998-11-29 16:32:43 +00:00
|
|
|
|
/* Defining these variables here avoids the inclusion of hurdsig.c. */
|
|
|
|
|
unsigned long int __hurd_sigthread_stack_base;
|
|
|
|
|
unsigned long int __hurd_sigthread_stack_end;
|
|
|
|
|
unsigned long int *__hurd_sigthread_variables;
|
|
|
|
|
|
|
|
|
|
/* Defining these variables here avoids the inclusion of init-first.c.
|
|
|
|
|
We need to provide temporary storage for the per-thread variables
|
|
|
|
|
of the main user thread here, since it is used for storing the
|
|
|
|
|
`errno' variable. Note that this information is lost once we
|
|
|
|
|
relocate the dynamic linker. */
|
1995-06-08 09:00:23 +00:00
|
|
|
|
static unsigned long int threadvars[_HURD_THREADVAR_MAX];
|
|
|
|
|
unsigned long int __hurd_threadvar_stack_offset
|
|
|
|
|
= (unsigned long int) &threadvars;
|
1996-02-08 02:10:15 +00:00
|
|
|
|
unsigned long int __hurd_threadvar_stack_mask;
|
1995-06-08 09:00:23 +00:00
|
|
|
|
|
|
|
|
|
/* XXX loser kludge for vm_map kernel bug */
|
|
|
|
|
static vm_address_t fmha;
|
|
|
|
|
static vm_size_t fmhs;
|
1996-02-08 02:10:15 +00:00
|
|
|
|
static void unfmh(void){
|
1995-06-08 09:00:23 +00:00
|
|
|
|
__vm_deallocate(__mach_task_self(),fmha,fmhs);}
|
1996-02-08 02:10:15 +00:00
|
|
|
|
static void fmh(void) {
|
1995-06-08 09:00:23 +00:00
|
|
|
|
error_t err;int x;mach_port_t p;
|
|
|
|
|
vm_address_t a=0x08000000U,max=VM_MAX_ADDRESS;
|
|
|
|
|
while (!(err=__vm_region(__mach_task_self(),&a,&fmhs,&x,&x,&x,&x,&p,&x))){
|
|
|
|
|
__mach_port_deallocate(__mach_task_self(),p);
|
|
|
|
|
if (a+fmhs>=0x80000000U){
|
1995-07-10 09:40:15 +00:00
|
|
|
|
max=a; break;}
|
1995-06-08 09:00:23 +00:00
|
|
|
|
fmha=a+=fmhs;}
|
|
|
|
|
if (err) assert(err==KERN_NO_SPACE);
|
1995-07-10 09:40:15 +00:00
|
|
|
|
if (!fmha)fmhs=0;else{
|
1995-06-08 09:00:23 +00:00
|
|
|
|
fmhs=max-fmha;
|
|
|
|
|
err = __vm_map (__mach_task_self (),
|
|
|
|
|
&fmha, fmhs, 0, 0, MACH_PORT_NULL, 0, 1,
|
|
|
|
|
VM_PROT_NONE, VM_PROT_NONE, VM_INHERIT_COPY);
|
1995-07-10 09:40:15 +00:00
|
|
|
|
assert_perror(err);}
|
1995-06-08 09:00:23 +00:00
|
|
|
|
}
|
|
|
|
|
/* XXX loser kludge for vm_map kernel bug */
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1995-05-11 01:02:23 +00:00
|
|
|
|
Elf32_Addr
|
|
|
|
|
_dl_sysdep_start (void **start_argptr,
|
|
|
|
|
void (*dl_main) (const Elf32_Phdr *phdr, Elf32_Word phent,
|
|
|
|
|
Elf32_Addr *user_entry))
|
|
|
|
|
{
|
|
|
|
|
void go (int *argdata)
|
|
|
|
|
{
|
1995-09-30 21:18:30 +00:00
|
|
|
|
extern unsigned int _dl_skip_args; /* rtld.c */
|
1995-05-11 01:02:23 +00:00
|
|
|
|
char **p;
|
|
|
|
|
|
|
|
|
|
/* Cache the information in various global variables. */
|
1995-05-31 13:23:14 +00:00
|
|
|
|
_dl_argc = *argdata;
|
1995-09-30 21:18:30 +00:00
|
|
|
|
_dl_argv = 1 + (char **) argdata;
|
1995-05-11 01:02:23 +00:00
|
|
|
|
_environ = &_dl_argv[_dl_argc + 1];
|
1995-09-30 21:18:30 +00:00
|
|
|
|
for (p = _environ; *p++;); /* Skip environ pointers and terminator. */
|
|
|
|
|
|
|
|
|
|
if ((void *) p == _dl_argv[0])
|
|
|
|
|
{
|
|
|
|
|
static struct hurd_startup_data nodata;
|
|
|
|
|
_dl_hurd_data = &nodata;
|
2001-04-10 23:12:08 +00:00
|
|
|
|
nodata.user_entry = (vm_address_t) ENTRY_POINT;
|
1995-09-30 21:18:30 +00:00
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
_dl_hurd_data = (void *) p;
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
1996-07-29 00:18:42 +00:00
|
|
|
|
__libc_enable_secure = _dl_hurd_data->flags & EXEC_SECURE;
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
1995-11-16 00:44:18 +00:00
|
|
|
|
if (_dl_hurd_data->flags & EXEC_STACK_ARGS &&
|
|
|
|
|
_dl_hurd_data->user_entry == 0)
|
2001-04-10 23:12:08 +00:00
|
|
|
|
_dl_hurd_data->user_entry = (vm_address_t) ENTRY_POINT;
|
1995-11-16 00:44:18 +00:00
|
|
|
|
|
1995-06-08 09:00:23 +00:00
|
|
|
|
unfmh(); /* XXX */
|
1995-09-30 21:18:30 +00:00
|
|
|
|
|
Update.
1998-07-20 17:09 Ulrich Drepper <drepper@cygnus.com>
* shlib-versions: Remove definition for libSegFault.
* memory.texi: Comment out the relocating allocator description.
* manual/signal.texi: Remove reference to relocating allocator.
* manual/top-menu.texi: Regenerated.
* posix/fnmatch.c: Implement [: :] and change to recognize
^ as negation only when not _POSIXLY_CORRECT.
* sysdeps/generic/glob.c: Add several optimizations.
* posix/glob.h: Undefine __PMT to prevent warnings.
Reported by Roland McGrath.
* posix/regex.c: Define namespace macros only for _LIBC.
* sysdeps/arm/dl-machine.h: Fix typo.
* sysdeps/unix/sysv/sysv4/solaris2/sigpending.c: New file.
* sysdeps/unix/sysv/sysv4/solaris2/sigstack.c: New file.
* sysdeps/unix/sysv/sysv4/solaris2/sigwaitinfo.c: New file.
* sysdeps/unix/sysv/sysv4/solaris2/syscalls.list: Add sigaltstack,
sigpending, sigqueue, and sigtimedwait.
* sysdeps/unix/sysv/sysv4/solaris2/sparc/sparc32/syscall.S: New file.
* timezone/leapseconds: Update from tzdata1998f.
1998-07-18 Mark Kettenis <kettenis@phys.uva.nl>
* stdio/stdio.h [__USE_GNU]: Add prototype for fputs_unlocked.
* stdio/Versions [GLIBC_2.1]: Add fputs_unlocked.
* libio/stdio.h: Fix typo.
1998-07-19 Roland McGrath <roland@baalperazim.frob.com>
* sysdeps/mach/hurd/dl-sysdep.c (_dl_sysdep_start): #if 0 out the
magic memobj port arg parsing stuff. Fix it someday when we are ready
to really use it.
(_dl_sysdep_output): New function, modified from _dl_sysdep_error.
(_dl_sysdep_error, _dl_sysdep_message, _dl_sysdep_fatal): Removed.
1998-07-19 Roland McGrath <roland@baalperazim.frob.com>
* stdio/fputs.c: Add fputs_unlocked as weak alias for fputs.
1998-07-19 Roland McGrath <roland@baalperazim.frob.com>
* sysdeps/posix/sigsuspend.c: Define __sigsuspend with sigsuspend as
a weak alias.
* sysdeps/mach/hurd/sigsuspend.c: Likewise.
* sysdeps/generic/sigsuspend.c: Likewise.
1998-07-19 Roland McGrath <roland@baalperazim.frob.com>
* sysdeps/mach/hurd/i386/sigcontextinfo.h: New file.
1998-07-19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* Makerules (map-file): Don't use $(wildcard) to find the
generated version script, instead look in $(version-maps).
($(common-objpfx)libc.so): Only depend on libc.map if versioning
is used.
* extra-lib.mk ($(objpfx)$(lib).so): Only depend on version script
if versioning is used. Don't use $(wildcard) to find the
generated version script, instead look in $(verson-maps).
1998-07-17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* sysdeps/generic/segfault.c: Rename GET_EIP to GET_PC. Remove
unused function handle.
* sysdeps/generic/sigcontextinfo.h: Rename GET_EIP to GET_PC.
* sysdeps/unix/sysv/linux/i386/sigcontextinfo.h: Likewise.
* debug/catchsegv.sh: Fix argument processing, quoting and various
typos. Put the crash info always in the current directory. Find
program in $PATH if it contains no directory component.
* Makerules (install-lib.so-versioned,
install-lib.so-unversioned): New variables.
(install-lib-nosubdir): Depend on unversioned libs in
slibdir, not libdir.
1998-07-19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* Make-dist (+tsrcs): Remove references to %-map variables and
*.map files. Add Versions in subdirs.
* Makerules (distinfo-vars): Don't write out %-map variables.
1998-07-20 13:55 Ulrich Drepper <drepper@cygnus.com>
* inet/protocols/rwhod.h: Remove definition of _PATH_RWHODIR.
Include <paths.h> instead.
* sysdeps/generic/paths.h: Define _PATH_RWHODIR.
* sysdeps/unix/sysv/linux/paths.h: Likewise.
Reported by Dale Scheetz <dwarf@polaris.net>.
1998-07-17 21:44 Ulrich Drepper <drepper@cygnus.com>
* catgets/open_catalog.c: Strictly check whether catalog file is
larger enough for the data. Reported by Andries.Brouwer@cwi.nl.
1998-07-20 17:25:48 +00:00
|
|
|
|
#if 0 /* XXX make this work for real someday... */
|
2001-04-10 23:12:08 +00:00
|
|
|
|
if (_dl_hurd_data->user_entry == (vm_address_t) ENTRY_POINT)
|
1995-09-30 21:18:30 +00:00
|
|
|
|
/* We were invoked as a command, not as the program interpreter.
|
|
|
|
|
The generic ld.so code supports this: it will parse the args
|
|
|
|
|
as "ld.so PROGRAM [ARGS...]". For booting the Hurd, we
|
|
|
|
|
support an additional special syntax:
|
|
|
|
|
ld.so [-LIBS...] PROGRAM [ARGS...]
|
|
|
|
|
Each LIBS word consists of "FILENAME=MEMOBJ";
|
|
|
|
|
for example "-/lib/libc.so=123" says that the contents of
|
|
|
|
|
/lib/libc.so are found in a memory object whose port name
|
|
|
|
|
in our task is 123. */
|
1995-10-05 09:00:06 +00:00
|
|
|
|
while (_dl_argc > 2 && _dl_argv[1][0] == '-' && _dl_argv[1][1] != '-')
|
1995-09-30 21:18:30 +00:00
|
|
|
|
{
|
|
|
|
|
char *lastslash, *memobjname, *p;
|
|
|
|
|
struct link_map *l;
|
|
|
|
|
mach_port_t memobj;
|
|
|
|
|
error_t err;
|
|
|
|
|
|
|
|
|
|
++_dl_skip_args;
|
|
|
|
|
--_dl_argc;
|
|
|
|
|
p = _dl_argv++[1] + 1;
|
|
|
|
|
|
|
|
|
|
memobjname = strchr (p, '=');
|
|
|
|
|
if (! memobjname)
|
|
|
|
|
_dl_sysdep_fatal ("Bogus library spec: ", p, "\n", NULL);
|
|
|
|
|
*memobjname++ = '\0';
|
1996-05-04 13:57:05 +00:00
|
|
|
|
memobj = 0;
|
|
|
|
|
while (*memobjname != '\0')
|
|
|
|
|
memobj = (memobj * 10) + (*memobjname++ - '0');
|
1995-11-16 00:44:18 +00:00
|
|
|
|
|
1995-09-30 21:18:30 +00:00
|
|
|
|
/* Add a user reference on the memory object port, so we will
|
|
|
|
|
still have one after _dl_map_object_from_fd calls our
|
|
|
|
|
`close'. */
|
|
|
|
|
err = __mach_port_mod_refs (__mach_task_self (), memobj,
|
|
|
|
|
MACH_PORT_RIGHT_SEND, +1);
|
|
|
|
|
assert_perror (err);
|
1995-11-16 00:44:18 +00:00
|
|
|
|
|
1995-09-30 21:18:30 +00:00
|
|
|
|
lastslash = strrchr (p, '/');
|
|
|
|
|
l = _dl_map_object_from_fd (lastslash ? lastslash + 1 : p,
|
2000-07-21 04:12:25 +00:00
|
|
|
|
memobj, strdup (p), 0);
|
1995-09-30 21:18:30 +00:00
|
|
|
|
|
|
|
|
|
/* Squirrel away the memory object port where it
|
|
|
|
|
can be retrieved by the program later. */
|
|
|
|
|
l->l_info[DT_NULL] = (void *) memobj;
|
|
|
|
|
}
|
Update.
1998-07-20 17:09 Ulrich Drepper <drepper@cygnus.com>
* shlib-versions: Remove definition for libSegFault.
* memory.texi: Comment out the relocating allocator description.
* manual/signal.texi: Remove reference to relocating allocator.
* manual/top-menu.texi: Regenerated.
* posix/fnmatch.c: Implement [: :] and change to recognize
^ as negation only when not _POSIXLY_CORRECT.
* sysdeps/generic/glob.c: Add several optimizations.
* posix/glob.h: Undefine __PMT to prevent warnings.
Reported by Roland McGrath.
* posix/regex.c: Define namespace macros only for _LIBC.
* sysdeps/arm/dl-machine.h: Fix typo.
* sysdeps/unix/sysv/sysv4/solaris2/sigpending.c: New file.
* sysdeps/unix/sysv/sysv4/solaris2/sigstack.c: New file.
* sysdeps/unix/sysv/sysv4/solaris2/sigwaitinfo.c: New file.
* sysdeps/unix/sysv/sysv4/solaris2/syscalls.list: Add sigaltstack,
sigpending, sigqueue, and sigtimedwait.
* sysdeps/unix/sysv/sysv4/solaris2/sparc/sparc32/syscall.S: New file.
* timezone/leapseconds: Update from tzdata1998f.
1998-07-18 Mark Kettenis <kettenis@phys.uva.nl>
* stdio/stdio.h [__USE_GNU]: Add prototype for fputs_unlocked.
* stdio/Versions [GLIBC_2.1]: Add fputs_unlocked.
* libio/stdio.h: Fix typo.
1998-07-19 Roland McGrath <roland@baalperazim.frob.com>
* sysdeps/mach/hurd/dl-sysdep.c (_dl_sysdep_start): #if 0 out the
magic memobj port arg parsing stuff. Fix it someday when we are ready
to really use it.
(_dl_sysdep_output): New function, modified from _dl_sysdep_error.
(_dl_sysdep_error, _dl_sysdep_message, _dl_sysdep_fatal): Removed.
1998-07-19 Roland McGrath <roland@baalperazim.frob.com>
* stdio/fputs.c: Add fputs_unlocked as weak alias for fputs.
1998-07-19 Roland McGrath <roland@baalperazim.frob.com>
* sysdeps/posix/sigsuspend.c: Define __sigsuspend with sigsuspend as
a weak alias.
* sysdeps/mach/hurd/sigsuspend.c: Likewise.
* sysdeps/generic/sigsuspend.c: Likewise.
1998-07-19 Roland McGrath <roland@baalperazim.frob.com>
* sysdeps/mach/hurd/i386/sigcontextinfo.h: New file.
1998-07-19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* Makerules (map-file): Don't use $(wildcard) to find the
generated version script, instead look in $(version-maps).
($(common-objpfx)libc.so): Only depend on libc.map if versioning
is used.
* extra-lib.mk ($(objpfx)$(lib).so): Only depend on version script
if versioning is used. Don't use $(wildcard) to find the
generated version script, instead look in $(verson-maps).
1998-07-17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* sysdeps/generic/segfault.c: Rename GET_EIP to GET_PC. Remove
unused function handle.
* sysdeps/generic/sigcontextinfo.h: Rename GET_EIP to GET_PC.
* sysdeps/unix/sysv/linux/i386/sigcontextinfo.h: Likewise.
* debug/catchsegv.sh: Fix argument processing, quoting and various
typos. Put the crash info always in the current directory. Find
program in $PATH if it contains no directory component.
* Makerules (install-lib.so-versioned,
install-lib.so-unversioned): New variables.
(install-lib-nosubdir): Depend on unversioned libs in
slibdir, not libdir.
1998-07-19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* Make-dist (+tsrcs): Remove references to %-map variables and
*.map files. Add Versions in subdirs.
* Makerules (distinfo-vars): Don't write out %-map variables.
1998-07-20 13:55 Ulrich Drepper <drepper@cygnus.com>
* inet/protocols/rwhod.h: Remove definition of _PATH_RWHODIR.
Include <paths.h> instead.
* sysdeps/generic/paths.h: Define _PATH_RWHODIR.
* sysdeps/unix/sysv/linux/paths.h: Likewise.
Reported by Dale Scheetz <dwarf@polaris.net>.
1998-07-17 21:44 Ulrich Drepper <drepper@cygnus.com>
* catgets/open_catalog.c: Strictly check whether catalog file is
larger enough for the data. Reported by Andries.Brouwer@cwi.nl.
1998-07-20 17:25:48 +00:00
|
|
|
|
#endif
|
1995-09-30 21:18:30 +00:00
|
|
|
|
|
1995-05-11 01:02:23 +00:00
|
|
|
|
/* Call elf/rtld.c's main program. It will set everything
|
|
|
|
|
up and leave us to transfer control to USER_ENTRY. */
|
|
|
|
|
(*dl_main) ((const Elf32_Phdr *) _dl_hurd_data->phdr,
|
|
|
|
|
_dl_hurd_data->phdrsz / sizeof (Elf32_Phdr),
|
|
|
|
|
&_dl_hurd_data->user_entry);
|
|
|
|
|
|
2000-08-01 20:24:20 +00:00
|
|
|
|
/* The call above might screw a few things up.
|
|
|
|
|
|
|
|
|
|
First of all, if _dl_skip_args is nonzero, we are ignoring
|
|
|
|
|
the first few arguments. However, if we have no Hurd startup
|
|
|
|
|
data, it is the magical convention that ARGV[0] == P. The
|
|
|
|
|
startup code in init-first.c will get confused if this is not
|
|
|
|
|
the case, so we must rearrange things to make it so. We'll
|
|
|
|
|
overwrite the origional ARGV[0] at P with ARGV[_dl_skip_args].
|
|
|
|
|
|
|
|
|
|
Secondly, if we need to be secure, it removes some dangerous
|
|
|
|
|
environment variables. If we have no Hurd startup date this
|
|
|
|
|
changes P (since that's the location after the terminating
|
|
|
|
|
NULL in the list of environment variables). We do the same
|
|
|
|
|
thing as in the first case but make sure we recalculate P.
|
|
|
|
|
If we do have Hurd startup data, we have to move the data
|
|
|
|
|
such that it starts just after the terminating NULL in the
|
|
|
|
|
environment list.
|
|
|
|
|
|
|
|
|
|
We use memmove, since the locations might overlap. */
|
|
|
|
|
if (__libc_enable_secure || _dl_skip_args)
|
1995-09-30 21:18:30 +00:00
|
|
|
|
{
|
2000-08-01 20:24:20 +00:00
|
|
|
|
char **newp;
|
|
|
|
|
|
|
|
|
|
for (newp = _environ; *newp++;);
|
|
|
|
|
|
|
|
|
|
if (_dl_argv[-_dl_skip_args] == (char *) p)
|
|
|
|
|
{
|
|
|
|
|
if ((char *) newp != _dl_argv[0])
|
|
|
|
|
{
|
|
|
|
|
assert ((char *) newp < _dl_argv[0]);
|
|
|
|
|
_dl_argv[0] = memmove ((char *) newp, _dl_argv[0],
|
|
|
|
|
strlen (_dl_argv[0]) + 1);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
if ((void *) newp != _dl_hurd_data)
|
|
|
|
|
memmove (newp, _dl_hurd_data, sizeof (*_dl_hurd_data));
|
|
|
|
|
}
|
1995-09-30 21:18:30 +00:00
|
|
|
|
}
|
|
|
|
|
|
1995-05-11 01:02:23 +00:00
|
|
|
|
{
|
|
|
|
|
extern void _dl_start_user (void);
|
|
|
|
|
/* Unwind the stack to ARGDATA and simulate a return from _dl_start
|
|
|
|
|
to the RTLD_START code which will run the user's entry point. */
|
|
|
|
|
RETURN_TO (argdata, &_dl_start_user, _dl_hurd_data->user_entry);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
1995-05-31 13:23:14 +00:00
|
|
|
|
/* Set up so we can do RPCs. */
|
|
|
|
|
__mach_init ();
|
|
|
|
|
|
1997-07-26 02:33:30 +00:00
|
|
|
|
/* Initialize frequently used global variable. */
|
|
|
|
|
_dl_pagesize = __getpagesize ();
|
|
|
|
|
|
1995-06-08 09:00:23 +00:00
|
|
|
|
fmh(); /* XXX */
|
|
|
|
|
|
1995-05-11 01:02:23 +00:00
|
|
|
|
/* See hurd/hurdstartup.c; this deals with getting information
|
|
|
|
|
from the exec server and slicing up the arguments.
|
|
|
|
|
Then it will call `go', above. */
|
|
|
|
|
_hurd_startup (start_argptr, &go);
|
|
|
|
|
|
|
|
|
|
LOSE;
|
1995-08-14 22:49:23 +00:00
|
|
|
|
abort ();
|
1995-05-11 01:02:23 +00:00
|
|
|
|
}
|
1995-11-17 02:33:47 +00:00
|
|
|
|
|
|
|
|
|
void
|
2000-12-06 12:47:03 +00:00
|
|
|
|
internal_function
|
1995-11-17 02:33:47 +00:00
|
|
|
|
_dl_sysdep_start_cleanup (void)
|
|
|
|
|
{
|
|
|
|
|
/* Deallocate the reply port and task port rights acquired by
|
|
|
|
|
__mach_init. We are done with them now, and the user will
|
|
|
|
|
reacquire them for himself when he wants them. */
|
|
|
|
|
__mig_dealloc_reply_port (MACH_PORT_NULL);
|
|
|
|
|
__mach_port_deallocate (__mach_task_self (), __mach_task_self_);
|
|
|
|
|
}
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
|
|
|
|
/* Minimal open/close/mmap implementation sufficient for initial loading of
|
|
|
|
|
shared libraries. These are weak definitions so that when the
|
|
|
|
|
dynamic linker re-relocates itself to be user-visible (for -ldl),
|
|
|
|
|
it will get the user's definition (i.e. usually libc's). */
|
|
|
|
|
|
2001-06-17 21:09:28 +00:00
|
|
|
|
/* Open FILE_NAME and return a Hurd I/O for it in *PORT, or return an
|
|
|
|
|
error. If STAT is non-zero, stat the file into that stat buffer. */
|
1996-07-30 19:23:06 +00:00
|
|
|
|
static error_t
|
2001-06-17 21:09:28 +00:00
|
|
|
|
open_file (const char *file_name, int flags,
|
1998-07-16 20:14:19 +00:00
|
|
|
|
mach_port_t *port, struct stat *stat)
|
1995-05-11 01:02:23 +00:00
|
|
|
|
{
|
|
|
|
|
enum retry_type doretry;
|
|
|
|
|
char retryname[1024]; /* XXX string_t LOSES! */
|
2001-06-17 21:09:28 +00:00
|
|
|
|
file_t startdir;
|
1995-10-09 07:06:29 +00:00
|
|
|
|
error_t err;
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
2001-06-17 21:09:28 +00:00
|
|
|
|
error_t use_init_port (int which, error_t (*operate) (file_t))
|
|
|
|
|
{
|
|
|
|
|
return (which < _dl_hurd_data->portarraysize
|
|
|
|
|
? ((*operate) (_dl_hurd_data->portarray[which]))
|
|
|
|
|
: EGRATUITOUS);
|
|
|
|
|
}
|
|
|
|
|
file_t get_dtable_port (int fd)
|
|
|
|
|
{
|
|
|
|
|
if ((unsigned int) fd < _dl_hurd_data->dtablesize
|
|
|
|
|
&& _dl_hurd_data->dtable[fd] != MACH_PORT_NULL)
|
|
|
|
|
{
|
|
|
|
|
__mach_port_mod_refs (__mach_task_self (), _dl_hurd_data->dtable[fd],
|
|
|
|
|
MACH_PORT_RIGHT_SEND, +1);
|
|
|
|
|
return _dl_hurd_data->dtable[fd];
|
|
|
|
|
}
|
|
|
|
|
errno = EBADF;
|
|
|
|
|
return MACH_PORT_NULL;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
assert (!(flags & ~O_READ));
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
|
|
|
|
startdir = _dl_hurd_data->portarray[file_name[0] == '/' ?
|
|
|
|
|
INIT_PORT_CRDIR : INIT_PORT_CWDIR];
|
|
|
|
|
|
|
|
|
|
while (file_name[0] == '/')
|
|
|
|
|
file_name++;
|
|
|
|
|
|
2001-06-17 21:09:28 +00:00
|
|
|
|
err = __dir_lookup (startdir, (char *)file_name, O_RDONLY, 0,
|
|
|
|
|
&doretry, retryname, port);
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
2001-06-17 21:09:28 +00:00
|
|
|
|
if (!err)
|
|
|
|
|
err = __hurd_file_name_lookup_retry (use_init_port, get_dtable_port,
|
|
|
|
|
__dir_lookup, doretry, retryname,
|
|
|
|
|
O_RDONLY, 0, port);
|
|
|
|
|
if (!err && stat)
|
1995-05-11 01:02:23 +00:00
|
|
|
|
{
|
2001-06-17 21:09:28 +00:00
|
|
|
|
err = __io_stat (*port, stat);
|
1995-10-09 07:06:29 +00:00
|
|
|
|
if (err)
|
2001-06-17 21:09:28 +00:00
|
|
|
|
__mach_port_deallocate (__mach_task_self (), *port);
|
1995-05-11 01:02:23 +00:00
|
|
|
|
}
|
2001-06-17 21:09:28 +00:00
|
|
|
|
|
|
|
|
|
return err;
|
1995-05-11 01:02:23 +00:00
|
|
|
|
}
|
|
|
|
|
|
1996-07-30 19:23:06 +00:00
|
|
|
|
int weak_function
|
|
|
|
|
__open (const char *file_name, int mode, ...)
|
|
|
|
|
{
|
1998-07-16 20:14:19 +00:00
|
|
|
|
mach_port_t port;
|
|
|
|
|
error_t err = open_file (file_name, mode, &port, 0);
|
1996-07-30 19:23:06 +00:00
|
|
|
|
if (err)
|
|
|
|
|
return __hurd_fail (err);
|
|
|
|
|
else
|
1998-07-16 20:14:19 +00:00
|
|
|
|
return (int)port;
|
1996-07-30 19:23:06 +00:00
|
|
|
|
}
|
|
|
|
|
|
1996-07-08 06:18:25 +00:00
|
|
|
|
int weak_function
|
Mon Jun 10 06:14:03 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* sysdeps/mach/hurd/dl-sysdep.c (__open): Define this instead of open.
(__close, __mmap): Likewise define with __ names now.
Mon Jun 10 05:13:18 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* elf/dl-support.c: New file.
* elf/Makefile (CFLAGS-dl-support.c): New variable.
(routines, elide-routines.so): Add dl-support.
* elf/dl-minimal.c (_dl_pagesize): Remove common defn.
* elf/dl-load.c (_dl_pagesize): Define it here.
(_dl_map_object_from_fd): Initialize it if zero.
* elf/link.h (_dl_pagesize): Remove const.
Sun Jun 9 04:04:26 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* elf/Makefile (routines): Add dl-symbol.
* elf/dl-lookup.c (_dl_symbol_value): Moved to ...
* elf/dl-symbol.c: New file.
* elf/elf.h (Elf32_Xword, Elf32_Sxword): New types.
(Elf32_Section, Elf64_Section): New types, 16 bits.
(Elf32_Sym, Elf64_Sym): Use it.
* elf/dl-deps.c (_dl_open): Moved to ...
* elf/dl-open.c: New file.
* Makefile (routines): Add dl-open.
* elf/Makefile (dl-routines): New variable.
(routines): Add $(dl-routines).
(elide-routines.so): New variable, set to $(dl-routines).
(libdl-inhibit-o): Variable removed; build all flavors of -ldl.
(rtld-routines): All but rtld, dl-sysdep, and dl-minimal moved to
$(dl-routines).
* elf/dl-lookup.c (_dl_lookup_symbol): Remove magic symbol grokage.
* elf/dladdr.c: Use ELFW(ST_BIND) in place of ELF32_ST_BIND.
* elf/dl-load.c (open_path): Use __ names for open and close. Avoid
using strdup.
(_dl_map_object): Likewise.
(_dl_map_object_from_fd): Use __ names for mmap, munmap, and mprotect.
* elf/dl-minimal.c (malloc): Likewise.
* elf/dl-reloc.c (_dl_relocate_object): Likewise.
* elf/dl-minimal.c (_dl_pagesize): New variable.
(malloc): Use that instead of a static variable.
* elf/dl-reloc.c (_dl_relocate_object): Use _dl_pagesize instead of
calling getpagesize.
* elf/dl-load.c (_dl_map_object_from_fd): Likewise.
* elf/link.h: Declare _dl_pagesize.
* elf/rtld.c (dl_r_debug): Renamed to _dl_r_debug.
* elf/link.h (struct link_map): Use Half for l_phnum instead of Word.
* elf/rtld.c (dl_main): Use Half for phdr count arg.
(_dl_sysdep_start): Update prototype of DL_MAIN function ptr arg.
* elf/dl-load.c (_dl_map_object_from_fd): Use explicit Elf32_Word to
extract 4-byte magic number, not ElfW(Word). Match EI_CLASS against
native wordsize, either 32 or 64.
* elf/elf.h (Elf64_Byte, Elf64_Section): Typedefs removed. In C a
char is always a byte, no need for a typedef. Section indices are
16-bit quantities in elf64, which already have a typedef Elf64_Half.
Remove partial -lelf implementation. There is now a
separately-distributed `libelf' package that implements it.
* elf/dl-lookup.c: Don't #include <libelf.h> any more.
(_dl_elf_hash): New function, moved from
libelf.h:elf_hash.
(_dl_lookup_symbol): Use it instead of elf_hash.
* elf/libelf.h: File removed.
* elf/elf_hash.c: File removed.
* elf/Makefile (headers): Remove libelf.h.
(extra-libs): Remove libelf.
(libelf-routines): Variable removed.
* elf/Makefile (libdl.so): Remove commands from this target. The
implicit rule commands are correct, this explicit rule just serves to
add some dependencies.
* elf/dl-lookup.c (_dl_lookup_symbol): Use ELFW(ST_TYPE) in place of
ELF32_ST_TYPE. Likewise ST_BIND.
* elf/do-rel.h (elf_dynamic_do_rel): Likewise R_SYM.
* elf/link.h (ElfW): New macro for wordsize-independent ElfXX_* type
naming.
(ELFW): New macro, likewise for ELFXX_* macro naming.
(_ElfW, _ElfW_1): New macros, subroutines of ElfW and ELF.
Sat Jun 8 20:52:38 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* elf/link.h, elf/do-rel.h, elf/dynamic-link.h, elf/dl-deps.c,
elf/dl-init.c, elf/dl-load.c, elf/dl-lookup.c, elf/dl-reloc.c,
elf/dl-runtime.c, elf/dladdr.c, elf/dlclose.c, elf/dlsym.c,
elf/linux-compat.c, elf/rtld.c: Change all uses of `Elf32_XXX' to
`ElfW(XXX)' for wordsize-independence.
Sat Jun 8 20:50:42 1996 Richard Henderson <rth@tamu.edu>
* elf/elf.h: Move Elf64_* types in parity with Elf32 counterparts.
(Elf64_auxv_t): New type.
(EM_ALPHA, R_ALPHA_*): New macros for elf64-alpha format.
1996-06-10 10:18:47 +00:00
|
|
|
|
__close (int fd)
|
1995-05-11 01:02:23 +00:00
|
|
|
|
{
|
|
|
|
|
if (fd != (int) MACH_PORT_NULL)
|
|
|
|
|
__mach_port_deallocate (__mach_task_self (), (mach_port_t) fd);
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
|
1998-07-16 20:14:19 +00:00
|
|
|
|
__ssize_t weak_function
|
|
|
|
|
__libc_read (int fd, void *buf, size_t nbytes)
|
|
|
|
|
{
|
|
|
|
|
error_t err;
|
|
|
|
|
char *data;
|
|
|
|
|
mach_msg_type_number_t nread;
|
|
|
|
|
|
|
|
|
|
data = buf;
|
|
|
|
|
err = __io_read ((mach_port_t) fd, &data, &nread, -1, nbytes);
|
|
|
|
|
if (err)
|
|
|
|
|
return __hurd_fail (err);
|
|
|
|
|
|
|
|
|
|
if (data != buf)
|
|
|
|
|
{
|
|
|
|
|
memcpy (buf, data, nread);
|
|
|
|
|
__vm_deallocate (__mach_task_self (), (vm_address_t) data, nread);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return nread;
|
|
|
|
|
}
|
|
|
|
|
|
1998-11-29 16:32:43 +00:00
|
|
|
|
__ssize_t weak_function
|
|
|
|
|
__libc_write (int fd, const void *buf, size_t nbytes)
|
|
|
|
|
{
|
|
|
|
|
error_t err;
|
|
|
|
|
mach_msg_type_number_t nwrote;
|
1999-01-24 10:40:26 +00:00
|
|
|
|
|
1998-11-29 16:32:43 +00:00
|
|
|
|
assert (fd < _hurd_init_dtablesize);
|
1999-01-24 10:40:26 +00:00
|
|
|
|
|
1998-11-29 16:32:43 +00:00
|
|
|
|
err = __io_write (_hurd_init_dtable[fd], buf, nbytes, -1, &nwrote);
|
|
|
|
|
if (err)
|
|
|
|
|
return __hurd_fail (err);
|
|
|
|
|
|
|
|
|
|
return nwrote;
|
|
|
|
|
}
|
|
|
|
|
|
* sysdeps/mach/hurd/Makefile ($(link-rpcuserlibs)): Don't append
options after $(build-module), which is no longer a single command.
(LDFLAGS-link-rpcuserlibs): New variable to hold those options.
(LDFLAGS-libmachuser-link.so, LDFLAGS-libhurduser-link.so): New
variables using it. Reported by Mark Kettenis <kettenis@gnu.org>.
2001-03-11 Roland McGrath <roland@frob.com>
* elf/rtld.c (dl_main): Add cast to quiet warning.
* elf/dl-load.c (_dl_map_object_from_fd): Likewise.
* iconv/gconv_conf.c (__gconv_get_path): Likewise.
(__gconv_read_conf): Likewise.
* iconv/gconv_db.c (gen_steps): Likewise.
(__gconv_find_transform): Likewise.
* locale/programs/charmap-dir.c (fopen_uncompressed): Likewise.
(fopen_uncompressed): Use const in second argument's type.
2001-03-11 Roland McGrath <roland@frob.com>
* sysdeps/mach/hurd/dl-sysdep.c (__writev): New function.
* mach/mach_error.h: Fix ancient #endif syntax.
* hurd/hurdmalloc.c: Likewise.
* sysdeps/generic/atomicity.h (exchange_and_add, atomic_add,
compare_and_swap): Add volatile qualifier to first arg, to bring
these prototypes in line with all the other implementations.
Add a #warning to remind the builder that these are not atomic.
2001-03-04 Roland McGrath <roland@frob.com>
* hurd/vpprintf.c (vpprintf) [USE_IN_LIBIO]: Use innermore first
member of TEMP_F so its type is _IO_FILE * as expected.
* hurd/fopenport.c (seekio): Conditionalize type of POS argument
on [USE_IN_LIBIO]. Check the value for overflow, since for libio
it might exceed off_t's range.
2001-02-25 Roland McGrath <roland@frob.com>
* sysdeps/mach/hurd/sysd-stdio.c (__stdio_reopen): Use prototype.
* sysdeps/unix/bsd/getpt.c (__posix_openpt): Likewise.
* sysdeps/mach/hurd/i386/intr-msg.h (SYSCALL_EXAMINE): Make this a
macro instead of an inline function,
(MSG_EXAMINE): Likewise.
* hurd/hurd/ioctl.h (_HURD_HANDLE_IOCTLS_1): Remove extraneous ##.
* hurd/get-host.c: Include <string.h> for decls of built-ins.
* hurd/hurdchdir.c: Likewise.
* sysdeps/mach/hurd/i386/sigreturn.c: Likweise.
* sysdeps/mach/hurd/opendir.c: Likewise.
* mach/mach_init.c: Include <unistd.h> for _exit decl.
* mach/errsystems.awk: Give output file a trailing newline.
* mach/Machrules (MIG): Prepend CC='${CC}' to the mig command, so that
the script will use our compiler for the cpp stage.
With --enable-all-warnings we get a whole bunch of warnings,
and these are just a few fixes; there are more needed to silence it.
* mach/mach/mig_support.h (__mig_strncpy, mig_strncpy): Add extern
decls before extern inline defns to quiet gcc warning.
* hurd/hurd/threadvar.h (__hurd_threadvar_location_from_sp): Likewise.
* sysdeps/mach/i386/machine-sp.h (__thread_stack_pointer): Likewise.
2001-04-01 05:04:31 +00:00
|
|
|
|
/* This is only used for printing messages (see dl-misc.c). */
|
|
|
|
|
__ssize_t weak_function
|
|
|
|
|
__writev (int fd, const struct iovec *iov, int niov)
|
|
|
|
|
{
|
|
|
|
|
int i;
|
|
|
|
|
size_t total = 0;
|
|
|
|
|
for (i = 0; i < niov; ++i)
|
|
|
|
|
total += iov[i].iov_len;
|
|
|
|
|
|
|
|
|
|
assert (fd < _hurd_init_dtablesize);
|
|
|
|
|
|
|
|
|
|
if (total != 0)
|
|
|
|
|
{
|
|
|
|
|
char buf[total], *bufp = buf;
|
|
|
|
|
error_t err;
|
|
|
|
|
mach_msg_type_number_t nwrote;
|
|
|
|
|
|
|
|
|
|
for (i = 0; i < niov; ++i)
|
|
|
|
|
bufp = (memcpy (bufp, iov[i].iov_base, iov[i].iov_len)
|
|
|
|
|
+ iov[i].iov_len);
|
|
|
|
|
|
|
|
|
|
err = __io_write (_hurd_init_dtable[fd], buf, total, -1, &nwrote);
|
|
|
|
|
if (err)
|
|
|
|
|
return __hurd_fail (err);
|
|
|
|
|
|
|
|
|
|
return nwrote;
|
|
|
|
|
}
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
1998-07-29 18:41:02 +00:00
|
|
|
|
off_t weak_function
|
|
|
|
|
__lseek (int fd, off_t offset, int whence)
|
|
|
|
|
{
|
|
|
|
|
error_t err;
|
1998-10-24 01:36:01 +00:00
|
|
|
|
|
1998-07-29 18:41:02 +00:00
|
|
|
|
err = __io_seek ((mach_port_t) fd, offset, whence, &offset);
|
|
|
|
|
if (err)
|
|
|
|
|
return __hurd_fail (err);
|
1998-10-24 01:36:01 +00:00
|
|
|
|
|
1998-07-29 18:41:02 +00:00
|
|
|
|
return offset;
|
|
|
|
|
}
|
|
|
|
|
|
1998-04-07 09:21:28 +00:00
|
|
|
|
__ptr_t weak_function
|
|
|
|
|
__mmap (__ptr_t addr, size_t len, int prot, int flags, int fd, off_t offset)
|
1995-05-11 01:02:23 +00:00
|
|
|
|
{
|
1995-10-09 07:06:29 +00:00
|
|
|
|
error_t err;
|
1995-05-11 01:02:23 +00:00
|
|
|
|
vm_prot_t vmprot;
|
|
|
|
|
vm_address_t mapaddr;
|
1998-07-16 20:14:19 +00:00
|
|
|
|
mach_port_t memobj_rd, memobj_wr;
|
1995-05-11 01:02:23 +00:00
|
|
|
|
|
|
|
|
|
vmprot = VM_PROT_NONE;
|
|
|
|
|
if (prot & PROT_READ)
|
|
|
|
|
vmprot |= VM_PROT_READ;
|
|
|
|
|
if (prot & PROT_WRITE)
|
|
|
|
|
vmprot |= VM_PROT_WRITE;
|
|
|
|
|
if (prot & PROT_EXEC)
|
|
|
|
|
vmprot |= VM_PROT_EXECUTE;
|
|
|
|
|
|
1998-07-16 20:14:19 +00:00
|
|
|
|
if (flags & MAP_ANON)
|
|
|
|
|
memobj_rd = MACH_PORT_NULL;
|
|
|
|
|
else
|
|
|
|
|
{
|
1998-07-17 12:36:43 +00:00
|
|
|
|
assert (!(flags & MAP_SHARED));
|
1998-07-16 20:14:19 +00:00
|
|
|
|
err = __io_map ((mach_port_t) fd, &memobj_rd, &memobj_wr);
|
|
|
|
|
if (err)
|
|
|
|
|
return (__ptr_t) __hurd_fail (err);
|
|
|
|
|
__mach_port_deallocate (__mach_task_self (), memobj_wr);
|
|
|
|
|
}
|
|
|
|
|
|
1995-05-11 01:02:23 +00:00
|
|
|
|
mapaddr = (vm_address_t) addr;
|
1995-10-09 07:06:29 +00:00
|
|
|
|
err = __vm_map (__mach_task_self (),
|
|
|
|
|
&mapaddr, (vm_size_t) len, 0 /*ELF_MACHINE_USER_ADDRESS_MASK*/,
|
|
|
|
|
!(flags & MAP_FIXED),
|
1998-07-16 20:14:19 +00:00
|
|
|
|
memobj_rd,
|
Sun Jul 14 01:51:39 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* manual/Makefile (glibc-targets): Variable and targets removed.
Sat Jul 13 23:50:17 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* manual/Makefile (lib): New phony target. Depend on stamp files.
($(objpfx)stamp%-$(subdir)): New rule to create them when necessary.
1996-07-13 Paul Eggert <eggert@twinsun.com>
* time/strftime.c (strftime): Use space padding for %e, %k, %l,
to match Emacs format-time-string specification.
(DO_NUMBER_SPACEPAD): Renamed from DO_NUMBER_NOPAD.
Sat Jul 13 20:17:38 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* elf/dl-deps.c (_dl_map_object_deps): Take new args PRELOADS and
NPRELOADS, vector of `struct link_map *'s; add them to the searchlist
between MAP and its deps.
* elf/link.h: Fix decl.
* elf/rtld.c (dl_main): If not secure, parse LD_PRELOAD for
colon-separated list of names, map those and pass vector of ptrs as
PRELOADS list to _dl_map_object_deps.
* elf/dl-runtime.c (_dl_object_relocation_scope): Pass new args to
_dl_map_object_deps with empty preload list.
* elf/dl-open.c (_dl_open): Likewise.
* sysdeps/mach/hurd/dl-sysdep.c (_dl_sysdep_open_zero_fill): Function
removed.
(__mmap): Pass MACH_PORT_NULL for memobj port when (flags & MAP_ANON).
* sysdeps/generic/dl-sysdep.c (_dl_sysdep_open_zero_fill):
Conditionalize defn on [! MAP_ANON].
* elf/dl-minimal.c (malloc): Conditionalize use of _dl_zerofd
on [! MAP_ANON].
* elf/rtld.c (dl_main): Likewise.
* elf/dl-load.c (_dl_zerofd): Conditionalize defn on [! MAP_ANON].
(_dl_map_object_from_fd): Conditionalize initialization of _dl_zerofd.
* elf/dl-fini.c (_dl_fini): Skip finalizer for executable itself.
Sat Jul 13 02:47:53 1996 David Mosberger-Tang <davidm@azstarnet.com>
* stdlib/random.c (__random): Declare as int32_t to be in sync
with declaration.
* socket/Makefile (headers): Add socketbits.h.
* misc/mntent.c (endmntent): Allow for NULL stream. SunOS does
it that way.
* grp/initgroups.c (initgroups): Add groups that user is a member
of, not the ones he is _not_ a member of.
* nss/nsswitch.c (known_compare): Make known_compare() a static
instead of a local function. The latter are difficult to debug
and slow to execute on certain platforms.
* sysdeps/posix/ttyname_r.c (ttyname_r): Use sizeof (dev) - 1 in
place of sizeof (dev). The size of a literal string includes the
NUL byte.
* sysdeps/unix/getlogin.c (getlogin): Initialize ut_fd with -1.
Thu Jul 11 16:59:10 1996 David Mosberger-Tang <davidm@azstarnet.com>
* misc/mntent.c (addmntent): Seek to end of file before writing
entry. Return 1 on error, not -1.
Tue Jul 9 19:08:05 1996 David Mosberger-Tang <davidm@azstarnet.com>
* sysdeps/unix/sysv/linux/syscalls.list: Mark bdflush as EXTRA
syscall.
Fri Jul 5 18:44:55 1996 David Mosberger-Tang <davidm@azstarnet.com>
* sysdeps/unix/sysv/linux/alpha/ioperm.c (port_to_cpu_addr): Size
shift amount for Jensen must be 5 not 4.
Sat Jul 13 20:04:28 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* socket/sys/socket.h (struct osockaddr): New type.
Sat Jul 13 03:50:53 1996 Ulrich Drepper <drepper@cygnus.com>
* misc/Makefile (routines): Add qefgcvt and qefgcvt_r.
* misc/efgcvt.c, misc/efgcvt_r.c: Change code so that the `double'
and `long double' versions can be generated.
* misc/qefgcvt.c, misc/qefgcvt_r.c: New files. Define macros
so that included efgcvt{,_r}.c file generate `long double'
versions.
* stdlib/stdlib.h: Add prototypes for q[efg]cvt() and q[ef]cvt_r()
functions.
* manual/startup.texi: Document new getsubopt function.
* manual/examples/subopt.c: New example program for documenting
getsubopt function.
Fri Jul 12 23:58:37 1996 Ulrich Drepper <drepper@cygnus.com>
* stdlib/Makefile (routines): Add getsubopt.
* stdlib/stdlib.h: Add prototype for getsubopt.
* stdlib/getsubopt.c: New file. Implement getsubopt function
to handle suboption parsing.
1996-07-14 06:04:09 +00:00
|
|
|
|
(vm_offset_t) offset,
|
1995-10-09 07:06:29 +00:00
|
|
|
|
flags & (MAP_COPY|MAP_PRIVATE),
|
|
|
|
|
vmprot, VM_PROT_ALL,
|
1995-12-19 10:00:22 +00:00
|
|
|
|
(flags & MAP_SHARED) ? VM_INHERIT_SHARE : VM_INHERIT_COPY);
|
1996-01-10 10:00:22 +00:00
|
|
|
|
if (err == KERN_NO_SPACE && (flags & MAP_FIXED))
|
|
|
|
|
{
|
|
|
|
|
/* XXX this is not atomic as it is in unix! */
|
|
|
|
|
/* The region is already allocated; deallocate it first. */
|
|
|
|
|
err = __vm_deallocate (__mach_task_self (), mapaddr, len);
|
|
|
|
|
if (! err)
|
|
|
|
|
err = __vm_map (__mach_task_self (),
|
|
|
|
|
&mapaddr, (vm_size_t) len, 0 /*ELF_MACHINE_USER_ADDRESS_MASK*/,
|
|
|
|
|
!(flags & MAP_FIXED),
|
1998-07-16 20:14:19 +00:00
|
|
|
|
memobj_rd, (vm_offset_t) offset,
|
1996-01-10 10:00:22 +00:00
|
|
|
|
flags & (MAP_COPY|MAP_PRIVATE),
|
|
|
|
|
vmprot, VM_PROT_ALL,
|
|
|
|
|
(flags & MAP_SHARED)
|
|
|
|
|
? VM_INHERIT_SHARE : VM_INHERIT_COPY);
|
|
|
|
|
}
|
|
|
|
|
|
1998-07-16 20:14:19 +00:00
|
|
|
|
if ((flags & MAP_ANON) == 0)
|
|
|
|
|
__mach_port_deallocate (__mach_task_self (), memobj_rd);
|
|
|
|
|
|
1998-04-07 09:21:28 +00:00
|
|
|
|
return err ? (__ptr_t) __hurd_fail (err) : (__ptr_t) mapaddr;
|
1995-05-11 01:02:23 +00:00
|
|
|
|
}
|
|
|
|
|
|
1998-07-28 16:26:04 +00:00
|
|
|
|
int weak_function
|
|
|
|
|
__fxstat (int vers, int fd, struct stat *buf)
|
|
|
|
|
{
|
|
|
|
|
error_t err;
|
1998-10-24 01:36:01 +00:00
|
|
|
|
|
1998-07-28 16:26:04 +00:00
|
|
|
|
assert (vers == _STAT_VER);
|
1998-10-24 01:36:01 +00:00
|
|
|
|
|
1998-07-28 16:26:04 +00:00
|
|
|
|
err = __io_stat ((mach_port_t) fd, buf);
|
|
|
|
|
if (err)
|
|
|
|
|
return __hurd_fail (err);
|
|
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
int weak_function
|
|
|
|
|
__xstat (int vers, const char *file, struct stat *buf)
|
|
|
|
|
{
|
|
|
|
|
error_t err;
|
|
|
|
|
mach_port_t port;
|
1998-10-24 01:36:01 +00:00
|
|
|
|
|
1998-07-28 16:26:04 +00:00
|
|
|
|
assert (vers == _STAT_VER);
|
|
|
|
|
|
|
|
|
|
err = open_file (file, 0, &port, buf);
|
|
|
|
|
if (err)
|
|
|
|
|
return __hurd_fail (err);
|
|
|
|
|
|
|
|
|
|
__mach_port_deallocate (__mach_task_self (), port);
|
|
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
|
2000-09-29 21:40:26 +00:00
|
|
|
|
/* This function is called by the dynamic linker (rtld.c) to check
|
|
|
|
|
whether debugging malloc is allowed even for SUID binaries. This
|
|
|
|
|
stub will always fail, which means that malloc-debugging is always
|
|
|
|
|
disabled for SUID binaries. */
|
|
|
|
|
int weak_function
|
|
|
|
|
__access (const char *file, int type)
|
|
|
|
|
{
|
|
|
|
|
errno = ENOSYS;
|
|
|
|
|
return -1;
|
|
|
|
|
}
|
|
|
|
|
|
1998-07-29 18:41:02 +00:00
|
|
|
|
pid_t weak_function
|
|
|
|
|
__getpid ()
|
|
|
|
|
{
|
|
|
|
|
pid_t pid, ppid;
|
|
|
|
|
int orphaned;
|
1998-10-24 01:36:01 +00:00
|
|
|
|
|
1998-07-29 18:41:02 +00:00
|
|
|
|
if (__proc_getpids (_dl_hurd_data->portarray[INIT_PORT_PROC],
|
|
|
|
|
&pid, &ppid, &orphaned))
|
|
|
|
|
return -1;
|
|
|
|
|
|
|
|
|
|
return pid;
|
|
|
|
|
}
|
|
|
|
|
|
1999-01-24 10:40:26 +00:00
|
|
|
|
/* This is called only in some strange cases trying to guess a value
|
|
|
|
|
for $ORIGIN for the executable. The dynamic linker copes with
|
|
|
|
|
getcwd failing (dl-object.c), and it's too much hassle to include
|
|
|
|
|
the functionality here. (We could, it just requires duplicating or
|
|
|
|
|
reusing getcwd.c's code but using our special lookup function as in
|
|
|
|
|
`open', above.) */
|
1998-11-29 16:32:43 +00:00
|
|
|
|
char *
|
|
|
|
|
weak_function
|
|
|
|
|
__getcwd (char *buf, size_t size)
|
|
|
|
|
{
|
1999-01-24 10:40:26 +00:00
|
|
|
|
errno = ENOSYS;
|
1998-11-29 16:32:43 +00:00
|
|
|
|
return NULL;
|
|
|
|
|
}
|
|
|
|
|
|
1996-07-08 06:18:25 +00:00
|
|
|
|
void weak_function
|
1995-05-11 01:02:23 +00:00
|
|
|
|
_exit (int status)
|
|
|
|
|
{
|
1995-08-14 22:49:23 +00:00
|
|
|
|
__proc_mark_exit (_dl_hurd_data->portarray[INIT_PORT_PROC],
|
Tue May 7 19:00:01 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* string/argz-extract.c: Remove const from decl.
* string/argz.h: Here too.
* Makeconfig (version.mk): Fix regexp in sed cmd.
Depend on $(..)Makeconfig.
* GMP code updated from gmp-2.0 release.
* stdlib/Makefile (mpn-routines): Removed add_1, added inlines.
* sysdeps/generic/add_1.c: File removed.
* stdlib/strtod.c: mp_limb is now mp_limb_t.
* stdlib/fpioconst.c, stdlib/fpioconst.h: Likewise.
* stdio-common/_itoa.c: Likewise.
* stdio-common/printf_fp.c: Likewise.
Don't include ansidecl.h.
* sysdeps/mach/hurd/getcwd.c: Use io_identity instead of io_stat.
* shlib-versions: New file.
* Makerules (soversions.mk): New target, include file generated from
shlib-versions. Moved shared library rules before installation rules.
Rewrote shared library installation rules for versioned libraries.
* math/Makefile (libm.so-version): Variable removed.
* sysdeps/mach/hurd/i386/exc2signal.c: Use struct hurd_signal_detail.
* hurd/report-wait.c (_S_msg_describe_ports): New function.
* configure.in: Add AC_PROG_LN_S check.
* config.make.in (LN_S): New variable.
Sun May 5 03:10:44 1996 Ulrich Drepper <drepper@cygnus.com>
* misc/efgcvt_r.c (ecvt_r): Work aroung gcc bug. gcc does
not know about weak aliases now and optimizes necessary `if'
statement away.
* posix/unistd.h: Add swapoff prototype.
* sysdeps/generic/confname.h: Add even more POSIX.4 symbols.
* sysdeps/posix/fpathconf.c (__fpathconf): Get information
for _PC_PATH_MAX from fstatfs function if available.
* sysdeps/posix/sysconf.c: Add code to handle _SC_AIO_LISTIO_MAX,
_SC_AIO_MAX, _SC_AIO_PRIO_DELTA_MAX, _SC_DELAYTIMER_MAX,
_SC_MQ_OPEN_MAX, _SC_MQ_PRIO_MAX, _SC_RTSIG_MAX,
_SC_SEM_NSEMS_MAX, _SC_SEM_VALUE_MAX, _SC_SIGQUEUE_MAX, and
_SC_TIMER_MAX.
* sysdeps/unix/sysv/sysv4/sysconf.c: Ditto.
* sysdeps/stub/swapoff.c: New file. Stub version for swapoff
function.
* sysdeps/unix/syscalls.list: Add swapoff.
* sysdeps/unix/sysv/linux/Dist: Add sys/acct.h.
* sysdeps/unix/sysv/linux/Makefile [$(subdir) == misc]
(sysdep_routines): Add mount, umount, llseek, setfsgid, setfsuid,
sysinfo, and uselib.
(headers): Add sys/sysinfo.h.
* sysdeps/unix/sysv/linux/gethostid.c: Prevent warning.
* sysdeps/unix/sysv/linux/i386/Makefile [$(subdir) == misc]
(sysdep_routines): Add ioperm, iopl, and vm86.
(headers): Add sys/perm.h and sys/vm86.h.
* sysdeps/unix/sysv/linux/i386/sys/perm.h: New file. Contains
prototypes for iopl and ioperm.
* sysdeps/unix/sysv/linux/i386/sys/vm86.h: New file. Contains
prototype for vm86.
* sysdeps/unix/sysv/linux/i386/syscalls.list: New file. Add
vm86 system call.
* sysdeps/unix/sysv/linux/sys/acct.h: New file. Contains
prototypes for acct function.
* sysdeps/unix/sysv/linux/sys/socket.h: Provide real header
file with prototypes.
* sysdeps/unix/sysv/linux/sys/sysinfo.h: New file. Contains
prototype for sysinfo function.
* sysdeps/unix/sysv/linux/syscalls.list: Add flock, ioperm, iopl,
llseek, setfsgid, setfsuid, sysinfo, and uselib.
* sysdeps/unix/sysv/linux/sysconf.c: Instead of duplicating
posix/sysconf.c now only handle cases different to that
implementation.
Tue May 7 15:08:19 1996 Miles Bader <miles@gnu.ai.mit.edu>
* stdio/linewrap.c (__line_wrap_output): Renamed from lwoutput
(all references changed). Now exported.
* stdio/linewrap.c (struct data): Type deleted (moved to linewrap.h).
(wrap_stream, unwrap_stream, lwclose, lwfileno, lwoutput,
line_wrap_stream, line_unwrap_stream): Use struct line_wrap_data
instead of struct data.
(lwoutput, line_wrap_stream, line_unwrap_stream): Rename various
occurences of `wrap' and `wrapmargin' to `wmargin'.
(line_wrapped, line_wrap_lmargin, line_wrap_set_lmargin,
line_wrap_rmargin, line_wrap_set_rmargin, line_wrap_wmargin,
line_wrap_set_wmargin, line_wrap_point): New functions.
* stdio/linewrap.h: New file.
* stdio/Makefile (headers): Add linewrap.h.
Tue May 7 14:19:12 1996 Roland McGrath <roland@delasyd.gnu.ai.mit.edu>
* sysdeps/unix/sysv/linux/i386/Makefile: File removed.
* stdio/stdio.h: Remove line_wrap_stream, line_unwap_stream decls.
* sysdeps/unix/sysv/linux/schedbits.h: New file.
Tue May 7 13:47:02 1996 Miles Bader <miles@gnu.ai.mit.edu>
* stdio/linewrap.c (struct data): Make margin fields not-pointers.
(lwoutput): Adjust uses acordingly.
* sysdeps/mach/hurd/fdatasync.c: New file.
* sysdeps/mach/hurd/fsync.c: Pass new flag to file_sync.
* sysdeps/mach/hurd/xmknod.c: Pass new flag to dir_link.
* sysdeps/mach/hurd/symlink.c: Likewise.
* sysdeps/mach/hurd/link.c: Likewise.
* sysdeps/mach/hurd/bind.c: Likewise.
* hurd/hurdsig.c (write_corefile): Likewise.
* hurd/hurdsig.c (write_corefile): Pass cttyid port to crash server.
* sysdeps/mach/hurd/fpathconf.c: RPC takes int pointer, not long int.
* sysdeps/mach/hurd/_exit.c (_hurd_exit): Pass sigcode arg to
proc_mark_exit.
* sysdeps/mach/hurd/dl-sysdep.c (_exit): Likewise.
* sysdeps/mach/hurd/wait4.c: Pass sigcode arg to proc_wait.
* sysdeps/mach/hurd/rename.c: Pass new flag to dir_rename.
* hurd/hurdfault.c (_hurdsig_fault_catch_exception_raise): Use struct
hurd_signal_detail.
* hurd/catch-exc.c (_S_catch_exception_raise): Likewise.
* hurd/hurd-raise.c (_hurd_raise_signal): Likewise.
* sysdeps/mach/hurd/i386/trampoline.c (_hurd_setup_sighandler):
Likewise.
* sysdeps/mach/hurd/setitimer.c (restart_itimer): Likewise.
* hurd/hurd/signal.h: Fix _hurd_exception2signal prototype.
* hurd/hurdsig.c (write_corefile): Take const struct
hurd_signal_detail * arg. Pass all details to crash_dump_task.
(_hurd_internal_post_signal): Pass DETAIL to write_corefile.
(_hurd_internal_post_signal: suspend): Pass code and error to
proc_mark_stop.
* hurd/hurdprio.c (_hurd_priority_which_map): Pass flags arg to
proc_getprocinfo by reference.
1996-05-08 02:07:47 +00:00
|
|
|
|
W_EXITCODE (status, 0), 0);
|
1995-05-11 01:02:23 +00:00
|
|
|
|
while (__task_terminate (__mach_task_self ()))
|
|
|
|
|
__mach_task_self_ = (__mach_task_self) ();
|
|
|
|
|
}
|
1998-07-29 18:41:02 +00:00
|
|
|
|
|
|
|
|
|
/* Try to get a machine dependent instruction which will make the
|
|
|
|
|
program crash. This is used in case everything else fails. */
|
|
|
|
|
#include <abort-instr.h>
|
|
|
|
|
#ifndef ABORT_INSTRUCTION
|
|
|
|
|
/* No such instruction is available. */
|
|
|
|
|
# define ABORT_INSTRUCTION
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
void weak_function
|
|
|
|
|
abort (void)
|
|
|
|
|
{
|
|
|
|
|
/* Try to abort using the system specific command. */
|
|
|
|
|
ABORT_INSTRUCTION;
|
|
|
|
|
|
|
|
|
|
/* If the abort instruction failed, exit. */
|
|
|
|
|
_exit (127);
|
|
|
|
|
|
|
|
|
|
/* If even this fails, make sure we never return. */
|
|
|
|
|
while (1)
|
|
|
|
|
/* Try for ever and ever. */
|
|
|
|
|
ABORT_INSTRUCTION;
|
|
|
|
|
}
|
1998-11-29 16:32:43 +00:00
|
|
|
|
|
1995-08-14 22:49:23 +00:00
|
|
|
|
/* This function is called by interruptible RPC stubs. For initial
|
|
|
|
|
dynamic linking, just use the normal mach_msg. Since this defn is
|
1995-05-11 01:02:23 +00:00
|
|
|
|
weak, the real defn in libc.so will override it if we are linked into
|
|
|
|
|
the user program (-ldl). */
|
1995-08-14 22:49:23 +00:00
|
|
|
|
|
1996-07-08 06:18:25 +00:00
|
|
|
|
error_t weak_function
|
1995-08-14 22:49:23 +00:00
|
|
|
|
_hurd_intr_rpc_mach_msg (mach_msg_header_t *msg,
|
|
|
|
|
mach_msg_option_t option,
|
|
|
|
|
mach_msg_size_t send_size,
|
|
|
|
|
mach_msg_size_t rcv_size,
|
|
|
|
|
mach_port_t rcv_name,
|
|
|
|
|
mach_msg_timeout_t timeout,
|
|
|
|
|
mach_port_t notify)
|
|
|
|
|
{
|
|
|
|
|
return __mach_msg (msg, option, send_size, rcv_size, rcv_name,
|
|
|
|
|
timeout, notify);
|
|
|
|
|
}
|
Update.
1997-08-14 03:14 Ulrich Drepper <drepper@cygnus.com>
* elf/dl-minimal.c: Don't use relative #include paths.
(malloc): Don't try to initialize _dl_pagesize, it already is.
(__sigjmp_save, longjmp): Reformat.
* sysdeps/generic/dl-sysdep.c: Implement _dl_show_auxv function to
show content of auxiliary array.
(_dl_sysdep_start): Remember start of auxiliary vector.
* sysdeps/mach/hurd/dl-sysdep.c: (_dl_show_auxv): New dummy function.
* elf/link.h: Add prototype for _dl_show_auxv.
* elf/rtld.c (dl_main): Call _dl_show_auxv if LD_SHOW_AUXV envvar
is present.
* libio/iofdopen.c: Better prepare for use in libstdc++.
* libio/iofflush.c: Likewise.
* libio/iofgetpos.c: Likewise.
* libio/iofgets.c: Likewise.
* libio/iofopen.c: Likewise.
* libio/iofputs.c: Likewise.
* libio/iofread.c: Likewise.
* libio/iofsetpos.c: Likewise.
* libio/ioftell.c: Likewise.
* libio/iofwrite.c: Likewise.
* libio/iogetdelim.c: Likewise.
* libio/iogets.c: Likewise.
* libio/iopopen.c: Likewise.
* libio/ioputs.c: Likewise.
* libio/iosetbuffer.c: Likewise.
* libio/iosetvbuf.c: Likewise.
* libio/ioungetc.c: Likewise.
* libio/iovsprintf.c: Likewise.
* libio/iovsscanf.c: Likewise.
* manual/creature.texi: Mention _XOPEN_SOURCE_EXTENDED in correct
place.
* manual/math.texi: Add comment to sincos decsription to say it's a
GNU extension.
Fix description of random function.
* posix/fnmatch.h: Recognize Windog by _WINDOWS32 not WIN32.
* posix/glob.c: Likewise. Handle stupid system headers on SunOS.
Add casts for all __alloca calls.
* posix/glob.h: Recognize Windog by _WINDOWS32 not WIN32.
Declare additional GLOB_* constants also if _GNU_SOURCE is defined.
Patches by Paul D. Smith <psmith@BayNetworks.COM>.
* stdio-common/_itoa.c: Don't use relateive #include paths.
* sysdeps/i386/fpu/bits/mathinline.h: Enable optimizations even for
gcc 2.7.
(atan): Loading 1.0 from memory does not pay off.
(asinh): Fix typo.
1997-08-13 09:44 Philip Blundell <Philip.Blundell@pobox.com>
* sysdeps/stub/accept.c: Use socklen_t where necessary.
* sysdeps/stub/bind.c: Likewise.
* sysdeps/stub/connect.c: Likewise.
* sysdeps/stub/getsockname.c: Likewise.
* sysdeps/stub/getsockopt.c: Likewise.
* sysdeps/stub/recvfrom.c: Likewise.
* sysdeps/stub/sendto.c: Likewise.
* sysdeps/stub/setsockopt.c: Likewise.
1997-08-11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* io/ftw.c (object_compare): Avoid memcmp when comparing scalar
types.
1997-08-12 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* math/libm-test.c (cbrt_test): Add epsilon for long double to
`cbrt (-0.001)'.
1997-08-11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* sysdeps/stub/bits/string.h: Fix comment.
1997-08-01 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* elf/Makefile (routines): Remove dl-version.
(dl-routines): Add it here instead. This removes dead code from
libc.so.
1997-08-12 17:17 Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>
* malloc/thread-m.h (thread_atfork, thread_atfork_static): New
macros to encapsulate pthread_atfork's functionality.
* malloc/malloc.c (ptmalloc_lock_all, ptmalloc_unlock_all): New
functions, registered via thread_atfork in the initialization
routine or via thread_atfork_static in global scope. This
ensures a consistent state of all locks across fork().
1997-08-11 23:00:32 1997 Mark Kettenis <kettenis@phys.uva.nl>
* login/programs/xtmp.c (compare_entry):
Partially undo patch made by Klaus Espenlaub. There
was no xtmp/utmp typo. Added comment to cclarify this.
* login/programs/xtmp.h: Likewise.
* posix/getopt.c: Recognize Windog by _WINDOWS32 not WIN32.
Patch by Paul D. Smith <psmith@BayNetworks.COM>.
1997-08-12 13:51 Ulrich Drepper <drepper@cygnus.com>
* login/getutid.c: Rename to __getutid and make getutid and getutxid
weak aliases.
Patch by ir. Mark M._Kettenis <kettenis@phys.uva.nl>.
1997-08-11 23:55 Ulrich Drepper <drepper@cygnus.com>
* sysdeps/unix/sysv/linux/Makefile [subdir=misc] (sysdep_headers):
Add bits/mman.h.
1997-08-11 08:51:21 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
* stdlib/fmtmsg.c (fmtmsg): Add static to
__libc_once_define macro.
* libc.map (__progname_full, __progname): Added.
1997-08-04 08:31 H.J. Lu <hjl@gnu.ai.mit.edu>
* sysdeps/unix/sysv/linux/if_index.c (if_nametoindex): Return 0
if SIOGIFINDEX is not defined.
(if_indextoname): Initialize "result" to NULL.
(if_nametoindex, if_nameindex): Fix ENOSYS setting.
1997-08-11 11:58 Richard Henderson <rth@cygnus.com>
Sparc ISO C 9x exception handling:
* sysdeps/sparc/fpu/bits/mathdef.h: New file.
* sysdeps/sparc/fpu/fclrexcpt.c: New file.
* sysdeps/sparc/fpu/fegetenv.c: New file.
* sysdeps/sparc/fpu/fegetround.c: New file.
* sysdeps/sparc/fpu/feholdexcpt.c: New file.
* sysdeps/sparc/fpu/fesetenv.c: New file.
* sysdeps/sparc/fpu/fesetround.c: New file.
* sysdeps/sparc/fpu/feupdateenv.c: New file.
* sysdeps/sparc/fpu/fgetexcptflg.c: New file.
* sysdeps/sparc/fpu/fraiseexcpt.c: New file.
* sysdeps/sparc/fpu/fsetexcptflg.c: New file.
* sysdeps/sparc/fpu/ftestexcept.c: New file.
* sysdeps/sparc/sparc32/fpu/bits/fenv.h: New file.
* sysdeps/sparc/sparc64/fpu/bits/fenv.h: New file.
1997-08-11 11:58 Richard Henderson <rth@cygnus.com>
Sparc64 merge:
* configure.in: Change up subdirectories, rename sparc8->sparcv8.
* csu/Makefile: Nuke need-nopic-initfini bits. The problem was
that sparc64 ld did not recognize pic relocs at all.
* elf/dl-deps.c: Include <string.h>.
* elf/do-rel.h (elf_dynamic_do_rel): Take reloc address and size
directly instead of the DT names to get them from.
* elf/dynamic-link.h (_ELF_DYNAMIC_DO_RELOC): New macro distilled
from ELF_DYNAMIC_DO_REL{,A}. Define a second version that accounts
for the possibility that DT_RELA and DT_JMPPLT overlap, as such is
the case on the Sparc.
* elf/elf.h: Stub out Elf64_Ver*, and make them the same as the
Elf32_Ver* bits. The linker does not even know to differentiate
between the word sizes. Someone should examine this and figure
out what the proper sizes of things should be for 64-bit hosts
before the sparc64 libraries are distributed.
* shlib-versions: Rename sparc64 ld.so to not conflict with sparc32
on the same machine.
Move old sysdeps/sparc contents to sysdeps/sparc/sparc32,
rename sparc8 subdir to sparcv8, move sysdeps/sparc64 content to
sysdeps/sparc/sparc64. Same for sysdeps/unix/sysv/linux/sparc.
* sysdeps/sparc/Implies: Do ieee754 here.
* sysdeps/sparc/configure.in: Move from sparc32/.
* sysdeps/sparc/sparc32/Implies: Do wordsize here.
* sysdeps/sparc/sparc64/Implies: Likewise.
* sysdeps/sparc/sparc32/dl-machine.h (elf_machine_load_address):
Use uninitialized .got to find load address instead of AT_BASE, as
the later does not exist when running ld.so directly.
* sysdeps/sparc/sparc32/fpu/fpu_control.h: Move from ../.
* sysdeps/sparc/sparc64/fpu/fpu_control.h: Likewise.
* sysdeps/sparc/sparc32/udiv_qrnnd.S: Clean up PIC support.
* sysdeps/sparc/sparc64/Makefile (sysdep_routines): Add s_finitel
and s_signbitl for stdio.
* sysdeps/sparc/sparc64/configure.in: Remove, we no longer need
nopic_initfini.
* sysdeps/sparc/sparc64/bsd-_setjmp.S: Remove.
* sysdeps/sparc/sparc64/bsd-setjmp.S: Remove.
* sysdeps/unix/sysv/linux/sparc/sparc64/bsd-_setjmp.S: New empty file.
* sysdeps/unix/sysv/linux/sparc/sparc64/bsd-setjmp.S: New empty file.
* sysdeps/unix/sysv/linux/sparc/sparc64/longjmp.S: Add __longjmp alias.
* sysdeps/unix/sysv/linux/sparc/sparc64/setjmp.S: Add weak _setjmp
and setjmp entry points.
* sysdeps/sparc/sparc64/dl-machine.h: Finish real implementation.
* sysdeps/sparc/sparc64/elf/crtbegin.S: Add copyright, fix PIC.
* sysdeps/sparc/sparc64/elf/crtend.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/bits/sigaction.h (struct sigaction):
Fix sa_flags size for sparc64; add sa_restorer for kernel.
* sysdeps/unix/sysv/linux/sparc/sparc64/brk.S: Fix PIC.
* sysdeps/unix/sysv/linux/sparc/sparc64/clone.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/init-first.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S: New file.
1997-08-10 18:29:08 1997 Mark Kettenis <kettenis@phys.uva.nl>
* login/login.c (login): Check for correct return value of
utmpname.
1997-08-11 16:49 Ulrich Drepper <drepper@cygnus.com>
* time/tzset.c (__tzset_internal): Correctly handle TZ strings
following incorrect old POSIX specs.
Patch by Paul Eggert <eggert@twinsun.com>.
* sysdeps/generic/bits/sigaction.h: Correct comment for SA_RESTART.
* sysdeps/unix/bsd/osf/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/alpha/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/mips/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/minix/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/sysv4/bits/sigaction.h: Likewise.
Reported by NIIBE Yutaka <gniibe@mri.co.jp>.
1997-08-09 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* manual/math.texi: Define the macros @mul and @infinity and use
them to format the multiplication and infinity signs.
(FP Comparison Functions): Use @code, not @math, for C code
examples.
* elf/dl-profile.c: Add descriptions and implement reading of
1997-08-14 01:54:13 +00:00
|
|
|
|
|
1998-11-29 16:32:43 +00:00
|
|
|
|
|
Update.
1997-08-14 03:14 Ulrich Drepper <drepper@cygnus.com>
* elf/dl-minimal.c: Don't use relative #include paths.
(malloc): Don't try to initialize _dl_pagesize, it already is.
(__sigjmp_save, longjmp): Reformat.
* sysdeps/generic/dl-sysdep.c: Implement _dl_show_auxv function to
show content of auxiliary array.
(_dl_sysdep_start): Remember start of auxiliary vector.
* sysdeps/mach/hurd/dl-sysdep.c: (_dl_show_auxv): New dummy function.
* elf/link.h: Add prototype for _dl_show_auxv.
* elf/rtld.c (dl_main): Call _dl_show_auxv if LD_SHOW_AUXV envvar
is present.
* libio/iofdopen.c: Better prepare for use in libstdc++.
* libio/iofflush.c: Likewise.
* libio/iofgetpos.c: Likewise.
* libio/iofgets.c: Likewise.
* libio/iofopen.c: Likewise.
* libio/iofputs.c: Likewise.
* libio/iofread.c: Likewise.
* libio/iofsetpos.c: Likewise.
* libio/ioftell.c: Likewise.
* libio/iofwrite.c: Likewise.
* libio/iogetdelim.c: Likewise.
* libio/iogets.c: Likewise.
* libio/iopopen.c: Likewise.
* libio/ioputs.c: Likewise.
* libio/iosetbuffer.c: Likewise.
* libio/iosetvbuf.c: Likewise.
* libio/ioungetc.c: Likewise.
* libio/iovsprintf.c: Likewise.
* libio/iovsscanf.c: Likewise.
* manual/creature.texi: Mention _XOPEN_SOURCE_EXTENDED in correct
place.
* manual/math.texi: Add comment to sincos decsription to say it's a
GNU extension.
Fix description of random function.
* posix/fnmatch.h: Recognize Windog by _WINDOWS32 not WIN32.
* posix/glob.c: Likewise. Handle stupid system headers on SunOS.
Add casts for all __alloca calls.
* posix/glob.h: Recognize Windog by _WINDOWS32 not WIN32.
Declare additional GLOB_* constants also if _GNU_SOURCE is defined.
Patches by Paul D. Smith <psmith@BayNetworks.COM>.
* stdio-common/_itoa.c: Don't use relateive #include paths.
* sysdeps/i386/fpu/bits/mathinline.h: Enable optimizations even for
gcc 2.7.
(atan): Loading 1.0 from memory does not pay off.
(asinh): Fix typo.
1997-08-13 09:44 Philip Blundell <Philip.Blundell@pobox.com>
* sysdeps/stub/accept.c: Use socklen_t where necessary.
* sysdeps/stub/bind.c: Likewise.
* sysdeps/stub/connect.c: Likewise.
* sysdeps/stub/getsockname.c: Likewise.
* sysdeps/stub/getsockopt.c: Likewise.
* sysdeps/stub/recvfrom.c: Likewise.
* sysdeps/stub/sendto.c: Likewise.
* sysdeps/stub/setsockopt.c: Likewise.
1997-08-11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* io/ftw.c (object_compare): Avoid memcmp when comparing scalar
types.
1997-08-12 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* math/libm-test.c (cbrt_test): Add epsilon for long double to
`cbrt (-0.001)'.
1997-08-11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* sysdeps/stub/bits/string.h: Fix comment.
1997-08-01 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* elf/Makefile (routines): Remove dl-version.
(dl-routines): Add it here instead. This removes dead code from
libc.so.
1997-08-12 17:17 Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>
* malloc/thread-m.h (thread_atfork, thread_atfork_static): New
macros to encapsulate pthread_atfork's functionality.
* malloc/malloc.c (ptmalloc_lock_all, ptmalloc_unlock_all): New
functions, registered via thread_atfork in the initialization
routine or via thread_atfork_static in global scope. This
ensures a consistent state of all locks across fork().
1997-08-11 23:00:32 1997 Mark Kettenis <kettenis@phys.uva.nl>
* login/programs/xtmp.c (compare_entry):
Partially undo patch made by Klaus Espenlaub. There
was no xtmp/utmp typo. Added comment to cclarify this.
* login/programs/xtmp.h: Likewise.
* posix/getopt.c: Recognize Windog by _WINDOWS32 not WIN32.
Patch by Paul D. Smith <psmith@BayNetworks.COM>.
1997-08-12 13:51 Ulrich Drepper <drepper@cygnus.com>
* login/getutid.c: Rename to __getutid and make getutid and getutxid
weak aliases.
Patch by ir. Mark M._Kettenis <kettenis@phys.uva.nl>.
1997-08-11 23:55 Ulrich Drepper <drepper@cygnus.com>
* sysdeps/unix/sysv/linux/Makefile [subdir=misc] (sysdep_headers):
Add bits/mman.h.
1997-08-11 08:51:21 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
* stdlib/fmtmsg.c (fmtmsg): Add static to
__libc_once_define macro.
* libc.map (__progname_full, __progname): Added.
1997-08-04 08:31 H.J. Lu <hjl@gnu.ai.mit.edu>
* sysdeps/unix/sysv/linux/if_index.c (if_nametoindex): Return 0
if SIOGIFINDEX is not defined.
(if_indextoname): Initialize "result" to NULL.
(if_nametoindex, if_nameindex): Fix ENOSYS setting.
1997-08-11 11:58 Richard Henderson <rth@cygnus.com>
Sparc ISO C 9x exception handling:
* sysdeps/sparc/fpu/bits/mathdef.h: New file.
* sysdeps/sparc/fpu/fclrexcpt.c: New file.
* sysdeps/sparc/fpu/fegetenv.c: New file.
* sysdeps/sparc/fpu/fegetround.c: New file.
* sysdeps/sparc/fpu/feholdexcpt.c: New file.
* sysdeps/sparc/fpu/fesetenv.c: New file.
* sysdeps/sparc/fpu/fesetround.c: New file.
* sysdeps/sparc/fpu/feupdateenv.c: New file.
* sysdeps/sparc/fpu/fgetexcptflg.c: New file.
* sysdeps/sparc/fpu/fraiseexcpt.c: New file.
* sysdeps/sparc/fpu/fsetexcptflg.c: New file.
* sysdeps/sparc/fpu/ftestexcept.c: New file.
* sysdeps/sparc/sparc32/fpu/bits/fenv.h: New file.
* sysdeps/sparc/sparc64/fpu/bits/fenv.h: New file.
1997-08-11 11:58 Richard Henderson <rth@cygnus.com>
Sparc64 merge:
* configure.in: Change up subdirectories, rename sparc8->sparcv8.
* csu/Makefile: Nuke need-nopic-initfini bits. The problem was
that sparc64 ld did not recognize pic relocs at all.
* elf/dl-deps.c: Include <string.h>.
* elf/do-rel.h (elf_dynamic_do_rel): Take reloc address and size
directly instead of the DT names to get them from.
* elf/dynamic-link.h (_ELF_DYNAMIC_DO_RELOC): New macro distilled
from ELF_DYNAMIC_DO_REL{,A}. Define a second version that accounts
for the possibility that DT_RELA and DT_JMPPLT overlap, as such is
the case on the Sparc.
* elf/elf.h: Stub out Elf64_Ver*, and make them the same as the
Elf32_Ver* bits. The linker does not even know to differentiate
between the word sizes. Someone should examine this and figure
out what the proper sizes of things should be for 64-bit hosts
before the sparc64 libraries are distributed.
* shlib-versions: Rename sparc64 ld.so to not conflict with sparc32
on the same machine.
Move old sysdeps/sparc contents to sysdeps/sparc/sparc32,
rename sparc8 subdir to sparcv8, move sysdeps/sparc64 content to
sysdeps/sparc/sparc64. Same for sysdeps/unix/sysv/linux/sparc.
* sysdeps/sparc/Implies: Do ieee754 here.
* sysdeps/sparc/configure.in: Move from sparc32/.
* sysdeps/sparc/sparc32/Implies: Do wordsize here.
* sysdeps/sparc/sparc64/Implies: Likewise.
* sysdeps/sparc/sparc32/dl-machine.h (elf_machine_load_address):
Use uninitialized .got to find load address instead of AT_BASE, as
the later does not exist when running ld.so directly.
* sysdeps/sparc/sparc32/fpu/fpu_control.h: Move from ../.
* sysdeps/sparc/sparc64/fpu/fpu_control.h: Likewise.
* sysdeps/sparc/sparc32/udiv_qrnnd.S: Clean up PIC support.
* sysdeps/sparc/sparc64/Makefile (sysdep_routines): Add s_finitel
and s_signbitl for stdio.
* sysdeps/sparc/sparc64/configure.in: Remove, we no longer need
nopic_initfini.
* sysdeps/sparc/sparc64/bsd-_setjmp.S: Remove.
* sysdeps/sparc/sparc64/bsd-setjmp.S: Remove.
* sysdeps/unix/sysv/linux/sparc/sparc64/bsd-_setjmp.S: New empty file.
* sysdeps/unix/sysv/linux/sparc/sparc64/bsd-setjmp.S: New empty file.
* sysdeps/unix/sysv/linux/sparc/sparc64/longjmp.S: Add __longjmp alias.
* sysdeps/unix/sysv/linux/sparc/sparc64/setjmp.S: Add weak _setjmp
and setjmp entry points.
* sysdeps/sparc/sparc64/dl-machine.h: Finish real implementation.
* sysdeps/sparc/sparc64/elf/crtbegin.S: Add copyright, fix PIC.
* sysdeps/sparc/sparc64/elf/crtend.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/bits/sigaction.h (struct sigaction):
Fix sa_flags size for sparc64; add sa_restorer for kernel.
* sysdeps/unix/sysv/linux/sparc/sparc64/brk.S: Fix PIC.
* sysdeps/unix/sysv/linux/sparc/sparc64/clone.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/init-first.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S: New file.
1997-08-10 18:29:08 1997 Mark Kettenis <kettenis@phys.uva.nl>
* login/login.c (login): Check for correct return value of
utmpname.
1997-08-11 16:49 Ulrich Drepper <drepper@cygnus.com>
* time/tzset.c (__tzset_internal): Correctly handle TZ strings
following incorrect old POSIX specs.
Patch by Paul Eggert <eggert@twinsun.com>.
* sysdeps/generic/bits/sigaction.h: Correct comment for SA_RESTART.
* sysdeps/unix/bsd/osf/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/alpha/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/mips/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/minix/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/sysv4/bits/sigaction.h: Likewise.
Reported by NIIBE Yutaka <gniibe@mri.co.jp>.
1997-08-09 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* manual/math.texi: Define the macros @mul and @infinity and use
them to format the multiplication and infinity signs.
(FP Comparison Functions): Use @code, not @math, for C code
examples.
* elf/dl-profile.c: Add descriptions and implement reading of
1997-08-14 01:54:13 +00:00
|
|
|
|
void
|
1998-07-14 19:43:02 +00:00
|
|
|
|
internal_function
|
Update.
1997-08-14 03:14 Ulrich Drepper <drepper@cygnus.com>
* elf/dl-minimal.c: Don't use relative #include paths.
(malloc): Don't try to initialize _dl_pagesize, it already is.
(__sigjmp_save, longjmp): Reformat.
* sysdeps/generic/dl-sysdep.c: Implement _dl_show_auxv function to
show content of auxiliary array.
(_dl_sysdep_start): Remember start of auxiliary vector.
* sysdeps/mach/hurd/dl-sysdep.c: (_dl_show_auxv): New dummy function.
* elf/link.h: Add prototype for _dl_show_auxv.
* elf/rtld.c (dl_main): Call _dl_show_auxv if LD_SHOW_AUXV envvar
is present.
* libio/iofdopen.c: Better prepare for use in libstdc++.
* libio/iofflush.c: Likewise.
* libio/iofgetpos.c: Likewise.
* libio/iofgets.c: Likewise.
* libio/iofopen.c: Likewise.
* libio/iofputs.c: Likewise.
* libio/iofread.c: Likewise.
* libio/iofsetpos.c: Likewise.
* libio/ioftell.c: Likewise.
* libio/iofwrite.c: Likewise.
* libio/iogetdelim.c: Likewise.
* libio/iogets.c: Likewise.
* libio/iopopen.c: Likewise.
* libio/ioputs.c: Likewise.
* libio/iosetbuffer.c: Likewise.
* libio/iosetvbuf.c: Likewise.
* libio/ioungetc.c: Likewise.
* libio/iovsprintf.c: Likewise.
* libio/iovsscanf.c: Likewise.
* manual/creature.texi: Mention _XOPEN_SOURCE_EXTENDED in correct
place.
* manual/math.texi: Add comment to sincos decsription to say it's a
GNU extension.
Fix description of random function.
* posix/fnmatch.h: Recognize Windog by _WINDOWS32 not WIN32.
* posix/glob.c: Likewise. Handle stupid system headers on SunOS.
Add casts for all __alloca calls.
* posix/glob.h: Recognize Windog by _WINDOWS32 not WIN32.
Declare additional GLOB_* constants also if _GNU_SOURCE is defined.
Patches by Paul D. Smith <psmith@BayNetworks.COM>.
* stdio-common/_itoa.c: Don't use relateive #include paths.
* sysdeps/i386/fpu/bits/mathinline.h: Enable optimizations even for
gcc 2.7.
(atan): Loading 1.0 from memory does not pay off.
(asinh): Fix typo.
1997-08-13 09:44 Philip Blundell <Philip.Blundell@pobox.com>
* sysdeps/stub/accept.c: Use socklen_t where necessary.
* sysdeps/stub/bind.c: Likewise.
* sysdeps/stub/connect.c: Likewise.
* sysdeps/stub/getsockname.c: Likewise.
* sysdeps/stub/getsockopt.c: Likewise.
* sysdeps/stub/recvfrom.c: Likewise.
* sysdeps/stub/sendto.c: Likewise.
* sysdeps/stub/setsockopt.c: Likewise.
1997-08-11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* io/ftw.c (object_compare): Avoid memcmp when comparing scalar
types.
1997-08-12 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* math/libm-test.c (cbrt_test): Add epsilon for long double to
`cbrt (-0.001)'.
1997-08-11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* sysdeps/stub/bits/string.h: Fix comment.
1997-08-01 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* elf/Makefile (routines): Remove dl-version.
(dl-routines): Add it here instead. This removes dead code from
libc.so.
1997-08-12 17:17 Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>
* malloc/thread-m.h (thread_atfork, thread_atfork_static): New
macros to encapsulate pthread_atfork's functionality.
* malloc/malloc.c (ptmalloc_lock_all, ptmalloc_unlock_all): New
functions, registered via thread_atfork in the initialization
routine or via thread_atfork_static in global scope. This
ensures a consistent state of all locks across fork().
1997-08-11 23:00:32 1997 Mark Kettenis <kettenis@phys.uva.nl>
* login/programs/xtmp.c (compare_entry):
Partially undo patch made by Klaus Espenlaub. There
was no xtmp/utmp typo. Added comment to cclarify this.
* login/programs/xtmp.h: Likewise.
* posix/getopt.c: Recognize Windog by _WINDOWS32 not WIN32.
Patch by Paul D. Smith <psmith@BayNetworks.COM>.
1997-08-12 13:51 Ulrich Drepper <drepper@cygnus.com>
* login/getutid.c: Rename to __getutid and make getutid and getutxid
weak aliases.
Patch by ir. Mark M._Kettenis <kettenis@phys.uva.nl>.
1997-08-11 23:55 Ulrich Drepper <drepper@cygnus.com>
* sysdeps/unix/sysv/linux/Makefile [subdir=misc] (sysdep_headers):
Add bits/mman.h.
1997-08-11 08:51:21 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
* stdlib/fmtmsg.c (fmtmsg): Add static to
__libc_once_define macro.
* libc.map (__progname_full, __progname): Added.
1997-08-04 08:31 H.J. Lu <hjl@gnu.ai.mit.edu>
* sysdeps/unix/sysv/linux/if_index.c (if_nametoindex): Return 0
if SIOGIFINDEX is not defined.
(if_indextoname): Initialize "result" to NULL.
(if_nametoindex, if_nameindex): Fix ENOSYS setting.
1997-08-11 11:58 Richard Henderson <rth@cygnus.com>
Sparc ISO C 9x exception handling:
* sysdeps/sparc/fpu/bits/mathdef.h: New file.
* sysdeps/sparc/fpu/fclrexcpt.c: New file.
* sysdeps/sparc/fpu/fegetenv.c: New file.
* sysdeps/sparc/fpu/fegetround.c: New file.
* sysdeps/sparc/fpu/feholdexcpt.c: New file.
* sysdeps/sparc/fpu/fesetenv.c: New file.
* sysdeps/sparc/fpu/fesetround.c: New file.
* sysdeps/sparc/fpu/feupdateenv.c: New file.
* sysdeps/sparc/fpu/fgetexcptflg.c: New file.
* sysdeps/sparc/fpu/fraiseexcpt.c: New file.
* sysdeps/sparc/fpu/fsetexcptflg.c: New file.
* sysdeps/sparc/fpu/ftestexcept.c: New file.
* sysdeps/sparc/sparc32/fpu/bits/fenv.h: New file.
* sysdeps/sparc/sparc64/fpu/bits/fenv.h: New file.
1997-08-11 11:58 Richard Henderson <rth@cygnus.com>
Sparc64 merge:
* configure.in: Change up subdirectories, rename sparc8->sparcv8.
* csu/Makefile: Nuke need-nopic-initfini bits. The problem was
that sparc64 ld did not recognize pic relocs at all.
* elf/dl-deps.c: Include <string.h>.
* elf/do-rel.h (elf_dynamic_do_rel): Take reloc address and size
directly instead of the DT names to get them from.
* elf/dynamic-link.h (_ELF_DYNAMIC_DO_RELOC): New macro distilled
from ELF_DYNAMIC_DO_REL{,A}. Define a second version that accounts
for the possibility that DT_RELA and DT_JMPPLT overlap, as such is
the case on the Sparc.
* elf/elf.h: Stub out Elf64_Ver*, and make them the same as the
Elf32_Ver* bits. The linker does not even know to differentiate
between the word sizes. Someone should examine this and figure
out what the proper sizes of things should be for 64-bit hosts
before the sparc64 libraries are distributed.
* shlib-versions: Rename sparc64 ld.so to not conflict with sparc32
on the same machine.
Move old sysdeps/sparc contents to sysdeps/sparc/sparc32,
rename sparc8 subdir to sparcv8, move sysdeps/sparc64 content to
sysdeps/sparc/sparc64. Same for sysdeps/unix/sysv/linux/sparc.
* sysdeps/sparc/Implies: Do ieee754 here.
* sysdeps/sparc/configure.in: Move from sparc32/.
* sysdeps/sparc/sparc32/Implies: Do wordsize here.
* sysdeps/sparc/sparc64/Implies: Likewise.
* sysdeps/sparc/sparc32/dl-machine.h (elf_machine_load_address):
Use uninitialized .got to find load address instead of AT_BASE, as
the later does not exist when running ld.so directly.
* sysdeps/sparc/sparc32/fpu/fpu_control.h: Move from ../.
* sysdeps/sparc/sparc64/fpu/fpu_control.h: Likewise.
* sysdeps/sparc/sparc32/udiv_qrnnd.S: Clean up PIC support.
* sysdeps/sparc/sparc64/Makefile (sysdep_routines): Add s_finitel
and s_signbitl for stdio.
* sysdeps/sparc/sparc64/configure.in: Remove, we no longer need
nopic_initfini.
* sysdeps/sparc/sparc64/bsd-_setjmp.S: Remove.
* sysdeps/sparc/sparc64/bsd-setjmp.S: Remove.
* sysdeps/unix/sysv/linux/sparc/sparc64/bsd-_setjmp.S: New empty file.
* sysdeps/unix/sysv/linux/sparc/sparc64/bsd-setjmp.S: New empty file.
* sysdeps/unix/sysv/linux/sparc/sparc64/longjmp.S: Add __longjmp alias.
* sysdeps/unix/sysv/linux/sparc/sparc64/setjmp.S: Add weak _setjmp
and setjmp entry points.
* sysdeps/sparc/sparc64/dl-machine.h: Finish real implementation.
* sysdeps/sparc/sparc64/elf/crtbegin.S: Add copyright, fix PIC.
* sysdeps/sparc/sparc64/elf/crtend.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/bits/sigaction.h (struct sigaction):
Fix sa_flags size for sparc64; add sa_restorer for kernel.
* sysdeps/unix/sysv/linux/sparc/sparc64/brk.S: Fix PIC.
* sysdeps/unix/sysv/linux/sparc/sparc64/clone.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/init-first.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S: New file.
1997-08-10 18:29:08 1997 Mark Kettenis <kettenis@phys.uva.nl>
* login/login.c (login): Check for correct return value of
utmpname.
1997-08-11 16:49 Ulrich Drepper <drepper@cygnus.com>
* time/tzset.c (__tzset_internal): Correctly handle TZ strings
following incorrect old POSIX specs.
Patch by Paul Eggert <eggert@twinsun.com>.
* sysdeps/generic/bits/sigaction.h: Correct comment for SA_RESTART.
* sysdeps/unix/bsd/osf/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/alpha/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/mips/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/minix/bits/sigaction.h: Likewise.
* sysdeps/unix/sysv/sysv4/bits/sigaction.h: Likewise.
Reported by NIIBE Yutaka <gniibe@mri.co.jp>.
1997-08-09 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* manual/math.texi: Define the macros @mul and @infinity and use
them to format the multiplication and infinity signs.
(FP Comparison Functions): Use @code, not @math, for C code
examples.
* elf/dl-profile.c: Add descriptions and implement reading of
1997-08-14 01:54:13 +00:00
|
|
|
|
_dl_show_auxv (void)
|
|
|
|
|
{
|
|
|
|
|
/* There is nothing to print. Hurd has no auxiliary vector. */
|
|
|
|
|
}
|
1998-05-27 10:29:02 +00:00
|
|
|
|
|
1998-07-14 19:43:02 +00:00
|
|
|
|
|
|
|
|
|
/* Return an array of useful/necessary hardware capability names. */
|
|
|
|
|
const struct r_strlenpair *
|
|
|
|
|
internal_function
|
|
|
|
|
_dl_important_hwcaps (const char *platform, size_t platform_len, size_t *sz,
|
|
|
|
|
size_t *max_capstrlen)
|
|
|
|
|
{
|
|
|
|
|
struct r_strlenpair *result;
|
|
|
|
|
|
|
|
|
|
/* Return an empty array. Hurd has no hardware capabilities. */
|
|
|
|
|
result = (struct r_strlenpair *) malloc (sizeof (*result));
|
|
|
|
|
if (result == NULL)
|
2001-09-08 17:45:32 +00:00
|
|
|
|
_dl_signal_error (ENOMEM, NULL, NULL, "cannot create capability list");
|
1998-07-14 19:43:02 +00:00
|
|
|
|
|
|
|
|
|
result[0].str = (char *) result; /* Does not really matter. */
|
|
|
|
|
result[0].len = 0;
|
|
|
|
|
|
|
|
|
|
*sz = 1;
|
|
|
|
|
return result;
|
|
|
|
|
}
|
2000-04-02 22:01:23 +00:00
|
|
|
|
|
|
|
|
|
void weak_function
|
|
|
|
|
_dl_init_first (int argc, ...)
|
|
|
|
|
{
|
|
|
|
|
/* This no-op definition only gets used if libc is not linked in. */
|
|
|
|
|
}
|