1998-03-29 16:50  Ulrich Drepper  <drepper@cygnus.com>

	* config.make.in (ldd-rewrite-script): New variable.
	* configure.in: Substitute ldd-rewrite-script.
	* elf/Makefile: Rewrite rules to generate ldd script.
	* elf/ldd.bash.in: Allow handling of non-ELF binaries.
	* elf/ldd.sh.in: Likewise.
	* sysdeps/unix/sysv/linux/Makefile: Remove rule to install lddlibc4.
	* sysdeps/unix/sysv/linux/configure.in: Define ldd_rewrite_script to
	point to sed script for libc4 handling insertion for ix86, m68, SPARC.
	* sysdeps/unix/sysv/linux/i386/Makefile: Add rule to install lddlibc4.

1998-03-26 15:20  Zack Weinberg  <zack@rabi.phys.columbia.edu>

	* inet/rcmd.c (iruserok): Remain setuid to the local user
	while .rhosts is actually read, to make .rhosts-over-NFS work
	(PR libc/524).  Use iruserfopen() for security checks on both
	hosts.equiv and .rhosts.  General cleanup.
	(iruserfopen): New function, performs careful checking on
	hosts.equiv/.rhosts files.  Disallows all the old forbidden
	stuff plus hard links to files.

1998-03-29 09:26  Ulrich Drepper  <drepper@cygnus.com>

	* setjmp/tst-setjmp.c: Don't test __setjmp, test _setjmp instead.

1998-03-29 02:02  H.J. Lu  <hjl@gnu.org>

	* sysdeps/i386/i486/bits/string.h: Fix typos.

	* nss/nsswitch.c (__nss_lookup): Fix the bogus checking for
	"adjusted for next function".

1998-03-28 00:13  H.J. Lu  <hjl@gnu.org>

	* sysdeps/unix/sysv/linux/alpha/readdir.c (__readdir64): New
	strong alias.

	* sysdeps/unix/sysv/linux/alpha/syscalls.list (socket): Added.

	* libc.map (__ieee_get_fp_control, __ieee_set_fp_control):
	Added.  Used by libm.so on alpha.

1998-03-28  Thorsten Kukuk  <kukuk@vt.uni-paderborn.de>

	* intl/bindtextdom.c [_LIBC]: Define strdup only if not yet
	defined.

1998-03-27 07:29  H.J. Lu  <hjl@gnu.org>

	* Makerules (object-suffixes-for-rules): Add .oS only for
	building shared library.
	Add ranlib rule for nonshared library.
	(rmobjs): Fix typo.

	* Makeconfig (libtype.oS, CFLAGS-.oS, CPPFLAGS-.oS): Moved
	into for shared library only.
	(CPPFLAGS-.oS): Add -DPIC.
	(libtypes): Use $(object-suffixes-for-rules) instead of
	$(object-suffixes).

1998-03-28  Ulrich Drepper  <drepper@cygnus.com>

	* sysdeps/unix/sysv/linux/Makefile (inhibit-stdio_lim): Compile
	and install lddlibc4.

1998-03-28 09:13  Zack Weinberg  <zack@rabi.phys.columbia.edu>

	* iconvdata/gap.pl: Gobble rest of line with a scalar, not a
	hash.
	* iconvdata/gaptab.pl: Likewise.
This commit is contained in:
Ulrich Drepper 1998-03-29 17:03:23 +00:00
parent a44d23932d
commit cb34385453
21 changed files with 292 additions and 110 deletions

View File

@ -1,3 +1,75 @@
1998-03-29 16:50 Ulrich Drepper <drepper@cygnus.com>
* config.make.in (ldd-rewrite-script): New variable.
* configure.in: Substitute ldd-rewrite-script.
* elf/Makefile: Rewrite rules to generate ldd script.
* elf/ldd.bash.in: Allow handling of non-ELF binaries.
* elf/ldd.sh.in: Likewise.
* sysdeps/unix/sysv/linux/Makefile: Remove rule to install lddlibc4.
* sysdeps/unix/sysv/linux/configure.in: Define ldd_rewrite_script to
point to sed script for libc4 handling insertion for ix86, m68, SPARC.
* sysdeps/unix/sysv/linux/i386/Makefile: Add rule to install lddlibc4.
1998-03-26 15:20 Zack Weinberg <zack@rabi.phys.columbia.edu>
* inet/rcmd.c (iruserok): Remain setuid to the local user
while .rhosts is actually read, to make .rhosts-over-NFS work
(PR libc/524). Use iruserfopen() for security checks on both
hosts.equiv and .rhosts. General cleanup.
(iruserfopen): New function, performs careful checking on
hosts.equiv/.rhosts files. Disallows all the old forbidden
stuff plus hard links to files.
1998-03-29 09:26 Ulrich Drepper <drepper@cygnus.com>
* setjmp/tst-setjmp.c: Don't test __setjmp, test _setjmp instead.
1998-03-29 02:02 H.J. Lu <hjl@gnu.org>
* sysdeps/i386/i486/bits/string.h: Fix typos.
* nss/nsswitch.c (__nss_lookup): Fix the bogus checking for
"adjusted for next function".
1998-03-28 00:13 H.J. Lu <hjl@gnu.org>
* sysdeps/unix/sysv/linux/alpha/readdir.c (__readdir64): New
strong alias.
* sysdeps/unix/sysv/linux/alpha/syscalls.list (socket): Added.
* libc.map (__ieee_get_fp_control, __ieee_set_fp_control):
Added. Used by libm.so on alpha.
1998-03-28 Thorsten Kukuk <kukuk@vt.uni-paderborn.de>
* intl/bindtextdom.c [_LIBC]: Define strdup only if not yet
defined.
1998-03-27 07:29 H.J. Lu <hjl@gnu.org>
* Makerules (object-suffixes-for-rules): Add .oS only for
building shared library.
Add ranlib rule for nonshared library.
(rmobjs): Fix typo.
* Makeconfig (libtype.oS, CFLAGS-.oS, CPPFLAGS-.oS): Moved
into for shared library only.
(CPPFLAGS-.oS): Add -DPIC.
(libtypes): Use $(object-suffixes-for-rules) instead of
$(object-suffixes).
1998-03-28 Ulrich Drepper <drepper@cygnus.com>
* sysdeps/unix/sysv/linux/Makefile (inhibit-stdio_lim): Compile
and install lddlibc4.
1998-03-28 09:13 Zack Weinberg <zack@rabi.phys.columbia.edu>
* iconvdata/gap.pl: Gobble rest of line with a scalar, not a
hash.
* iconvdata/gaptab.pl: Likewise.
1998-03-27 22:46 Ulrich Drepper <drepper@cygnus.com>
* Rules: Allow Makefiles to specify test-static for tests which

View File

@ -571,7 +571,7 @@ endif
# Various things use $(object-suffixes) to know what all to make.
# The compilation rules use $(CPPFLAGS-${SUFFIX}) and $(CFLAGS-${SUFFIX})
# to pass different flags for each flavor.
libtypes = $(foreach o,$(object-suffixes),$(libtype$o))
libtypes = $(foreach o,$(object-suffixes-for-rules),$(libtype$o))
all-object-suffixes := .o .os .op .og .ob .oS
object-suffixes :=
ifeq (yes,$(build-static))
@ -589,6 +589,13 @@ CFLAGS-.os = $(filter %frame-pointer,$(+cflags)) $(pic-ccflag)
libtype.os := lib%_pic.a
# This can be changed by a sysdep makefile
pic-ccflag = -fPIC
# Special library that contains the static-only routines for libc.
libtype.oS = lib%_nonshared.a
# Must build the routines as PIC, though, because they can end up in (users')
# shared objects. We don't want to use CFLAGS-os because users may, for
# example, make that processor-specific.
CFLAGS-.oS = $(CFLAGS-.o) $(pic-ccflag)
CPPFLAGS-.oS = $(CPPFLAGS-.o) -DPIC
endif
ifeq (yes,$(build-profile))
# Under --enable-profile, we will build a static library of profiled objects.
@ -618,14 +625,6 @@ CFLAGS-.ob = -g -fbounded-pointers
libtype.ob = lib%_b.a
endif
# Special library that contains the static-only routines for libc.
libtype.oS = lib%_nonshared.a
# Must build the routines as PIC, though, because they can end up in (users')
# shared objects. We don't want to use CFLAGS-os because users may, for
# example, make that processor-specific.
CFLAGS-.oS = $(CFLAGS-.o) $(pic-ccflag)
CPPFLAGS-.oS = $(CPPFLAGS-.o)
+gnu-stabs = $(shell echo>&2 '*** BARF ON ME')
ifndef BUILD_CC

View File

@ -172,7 +172,11 @@ endef
$(common-objpfx)dummy.d:
echo '# .s files cannot contain includes, so they need no deps.' > $@
object-suffixes-for-rules = $(object-suffixes) .oS
object-suffixes-for-rules := $(object-suffixes)
ifeq (yes,$(build-shared))
object-suffixes-for-rules += .oS
endif
# It matters that this set of rules, for compiling from sources in
# the current directory (the $srcdir/$subdir) come before the
@ -571,6 +575,15 @@ $(subdirs-stamps): subdir_lib;
endif
object-suffixes-left = $(object-suffixes)
include $(o-iterator)
ifeq (yes,$(build-shared))
$(common-objpfx)$(patsubst %,$(libtype.oS),c)($(ar-symtab-name)): \
$(common-objpfx)$(patsubst %,$(libtype.oS),c)(\
$(patsubst %,%.oS,$(static-only-routines))) \
$(wildcard $(foreach d,$(subdirs),$(common-objpfx)$d/stamp.oS))
$(SHELL) $(..)./autolock.sh \
$(common-objpfx)$(patsubst %,$(libtype.oS),c).lck \
$(RANLIB) $(common-objpfx)$(patsubst %,$(libtype.oS),c)
endif
# This makes all the object files.
@ -914,7 +927,7 @@ common-mostlyclean:
define rmobjs
$(foreach o,$(object-suffixes),
-rm -f $(objpfx)stamp$o $(o-objects))
-rm -f $(objpfx)stamp.oS $(patsubst %,$(static-only-routines),$(objpfx)%.oS)
-rm -f $(objpfx)stamp.oS $(patsubst %,$(objpfx)%.oS,$(static-only-routines))
endef
# Also remove the dependencies and generated source files.

View File

@ -15,6 +15,9 @@ rootsbindir = @libc_cv_rootsbindir@
# in GNU libc.
has-ldconfig = @has_ldconfig@
# Maybe the `ldd' script must be rewritten.
ldd-rewrite-script = @ldd_rewrite_script@
# System configuration.
config-machine = @host_cpu@
base-machine = @base_machine@

15
configure vendored
View File

@ -2512,6 +2512,9 @@ esac
libc_link_dests=
libc_link_sources=
# They also can set these variables.
ldd_rewrite_script=no
# Iterate over all the sysdep directories we will use, running their
# configure fragments, and looking for a uname implementation.
uname=
@ -2547,7 +2550,7 @@ if test "$uname" = "sysdeps/generic"; then
fi
echo $ac_n "checking OS release for uname""... $ac_c" 1>&6
echo "configure:2551: checking OS release for uname" >&5
echo "configure:2554: checking OS release for uname" >&5
if eval "test \"`echo '$''{'libc_cv_uname_release'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@ -2569,7 +2572,7 @@ echo "$ac_t""$libc_cv_uname_release" 1>&6
uname_release="$libc_cv_uname_release"
echo $ac_n "checking OS version for uname""... $ac_c" 1>&6
echo "configure:2573: checking OS version for uname" >&5
echo "configure:2576: checking OS version for uname" >&5
if eval "test \"`echo '$''{'libc_cv_uname_version'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@ -2591,7 +2594,7 @@ else
fi
echo $ac_n "checking stdio selection""... $ac_c" 1>&6
echo "configure:2595: checking stdio selection" >&5
echo "configure:2598: checking stdio selection" >&5
case $stdio in
libio) cat >> confdefs.h <<\EOF
@ -2603,7 +2606,7 @@ esac
echo "$ac_t""$stdio" 1>&6
echo $ac_n "checking ldap selection""... $ac_c" 1>&6
echo "configure:2607: checking ldap selection" >&5
echo "configure:2610: checking ldap selection" >&5
case $add_ons in
*ldap*)
@ -2620,6 +2623,7 @@ echo "$ac_t""$ldap" 1>&6
if test $gnu_ld = yes; then
cat >> confdefs.h <<\EOF
@ -2665,7 +2669,7 @@ if test $static = no && test $shared = yes; then
fi
echo $ac_n "checking whether -fPIC is default""... $ac_c" 1>&6
echo "configure:2669: checking whether -fPIC is default" >&5
echo "configure:2673: checking whether -fPIC is default" >&5
if eval "test \"`echo '$''{'pic_default'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@ -2892,6 +2896,7 @@ s%@libc_cv_slibdir@%$libc_cv_slibdir%g
s%@libc_cv_sysconfdir@%$libc_cv_sysconfdir%g
s%@libc_cv_rootsbindir@%$libc_cv_rootsbindir%g
s%@has_ldconfig@%$has_ldconfig%g
s%@ldd_rewrite_script@%$ldd_rewrite_script%g
s%@gnu_ld@%$gnu_ld%g
s%@gnu_as@%$gnu_as%g
s%@elf@%$elf%g

View File

@ -1000,6 +1000,9 @@ esac
libc_link_dests=
libc_link_sources=
# They also can set these variables.
ldd_rewrite_script=no
# Iterate over all the sysdep directories we will use, running their
# configure fragments, and looking for a uname implementation.
uname=
@ -1108,6 +1111,7 @@ AC_SUBST(libc_cv_sysconfdir)
AC_SUBST(libc_cv_rootsbindir)
AC_SUBST(has_ldconfig)
AC_SUBST(ldd_rewrite_script)
AC_SUBST(gnu_ld) AC_SUBST(gnu_as) AC_SUBST(elf)
if test $gnu_ld = yes; then

View File

@ -164,23 +164,34 @@ $(inst_slibdir)/$(rtld-installed-name): \
.PHONY: ldso_install
ldso_install: $(inst_slibdir)/$(rtld-installed-name)
sh-ldd-rewrite = -e 's%@RTLD@%$(slibdir)/$(rtld-installed-name)%g' \
-e 's%@VERSION@%$(version)%g'
bash-ldd-rewrite = $(sh-ldd-rewrite) -e 's%@BASH@%$(BASH)%g' \
-e 's%@TEXTDOMAINDIR@%$(localedir)%g'
ifneq ($(have-bash2),yes)
$(objpfx)ldd: ldd.sh.in $(common-objpfx)version.mk \
$(common-objpfx)soversions.mk $(common-objpfx)config.make
sed -e 's%@RTLD@%$(slibdir)/$(rtld-installed-name)%g' \
-e 's%@VERSION@%$(version)%g' < $< > $@.new
chmod 555 $@.new
mv -f $@.new $@
ldd-shell = bash
else
$(objpfx)ldd: ldd.bash.in $(common-objpfx)version.mk \
ldd-shell = sh
endif
ifeq ($(ldd-rewrite-script),no)
define gen-ldd
sed $($(ldd-shell)-ldd-rewrite) < $< > $@.new
endef
else
define gen-ldd
sed $($(ldd-shell)-ldd-rewrite) < $< | sed -f $(ldd-rewrite-script) > $@.new
endef
endif
$(objpfx)ldd: ldd.$(ldd-shell).in $(common-objpfx)version.mk \
$(common-objpfx)soversions.mk $(common-objpfx)config.make
sed -e 's%@BASH@%$(BASH)%g' \
-e 's%@RTLD@%$(slibdir)/$(rtld-installed-name)%g' \
-e 's%@VERSION@%$(version)%g' \
-e 's%@TEXTDOMAINDIR@%$(localedir)%g' < $< > $@.new
$(gen-ldd)
chmod 555 $@.new
mv -f $@.new $@
endif
ifeq ($(build-shared),yes)
$(objpfx)sprof: $(objpfx)libdl.so$(libdl.so-version)

View File

@ -87,6 +87,12 @@ Report bugs using the \`glibcbug' script to <bugs@gnu.org>."
esac
done
nonelf ()
{
# Maybe extra code for non-ELF binaries.
return 1;
}
add_env="LD_TRACE_LOADED_OBJECTS=1 LD_WARN=$warn LD_BIND_NOW=$bind_now"
add_env="$add_env LD_VERBOSE=$verbose"
case $# in
@ -115,6 +121,8 @@ case $# in
eval $add_env exec '"$file"' || exit 1
;;
1)
# This can be a non-ELF binary or no binary at all.
nonelf $file ||
echo $" not a dynamic executable"
exit 1
;;
@ -154,8 +162,11 @@ warning: you do not have execution permission for" "\`$file'"
eval $add_env '"$file"' || result=1
;;
1)
echo $" not a dynamic executable"
result=1
# This can be a non-ELF binary or no binary at all.
nonelf $file || {
echo $" not a dynamic executable"
result=1
}
;;
2)
eval $add_env ${RTLD} '"$file"' || result=1

View File

@ -83,6 +83,12 @@ Try \`ldd --help' for more information."
esac
done
nonelf ()
{
# Maybe extra code for non-ELF binaries.
return 1;
}
add_env="LD_TRACE_LOADED_OBJECTS=1 LD_WARN=$warn LD_BIND_NOW=$bind_now"
add_env="$add_env LD_VERBOSE=$verbose"
case $# in
@ -113,6 +119,7 @@ Try \`ldd --help' for more information."
eval $add_env exec '"$file"' || exit 1
;;
1)
nonelf $file ||
echo ' not a dynamic executable'
exit 1
;;
@ -155,6 +162,7 @@ ldd: warning: you do not have execution permission for \`$file'"
eval $add_env '"$file"' || result=1
;;
1)
nonelf $file ||
echo ' not a dynamic executable'
result=1
;;

View File

@ -1,6 +1,6 @@
$first=$last=$idx=0;
while (<>) {
local($ucs,%rest) = split;
local($ucs,$rest) = split;
local($u)=hex($ucs);
if ($u - $last > 6) {
if ($last != 0) {

View File

@ -6,7 +6,7 @@ sub fmt {
printf (" '\\x%02x',", $val);
}
while (<>) {
local($ucs,$char,%rest) = split;
local($ucs,$char,$rest) = split;
local($u)=hex($ucs);
local($c)=hex($char);
if ($u - $last > 6) {

View File

@ -287,6 +287,49 @@ ruserok(rhost, superuser, ruser, luser)
return -1;
}
/* Extremely paranoid file open function. */
static FILE *
iruserfopen (char *file, uid_t okuser)
{
struct stat st;
char *cp = NULL;
FILE *res = NULL;
/* If not a regular file, if owned by someone other than user or
root, if writeable by anyone but the owner, or if hardlinked
anywhere, quit. */
cp = NULL;
if (__lxstat (_STAT_VER, file, &st))
cp = _("lstat failed");
else if (!S_ISREG (st.st_mode))
cp = _("not regular file");
else
{
res = fopen (file, "r");
if (!res)
cp = _("cannot open");
else if (__fxstat (_STAT_VER, fileno (res), &st) < 0)
cp = _("fstat failed");
else if (st.st_uid && st.st_uid != okuser)
cp = _("bad owner");
else if (st.st_mode & (S_IWGRP|S_IWOTH))
cp = _("writeable by other than owner");
else if (st.st_nlink > 1)
cp = _("hard linked somewhere");
}
/* If there were any problems, quit. */
if (cp != NULL)
{
__rcmd_errstr = cp;
if (res)
fclose (res);
return NULL;
}
return res;
}
/*
* New .rhosts strategy: We are passed an ip address. We spin through
* hosts.equiv and .rhosts looking for a match. When the .rhosts only
@ -297,83 +340,60 @@ ruserok(rhost, superuser, ruser, luser)
* Returns 0 if ok, -1 if not ok.
*/
int
iruserok(raddr, superuser, ruser, luser)
u_int32_t raddr;
int superuser;
const char *ruser, *luser;
iruserok (raddr, superuser, ruser, luser)
u_int32_t raddr;
int superuser;
const char *ruser, *luser;
{
register char *cp;
struct stat sbuf;
struct passwd pwdbuf, *pwd;
FILE *hostf;
int first;
FILE *hostf;
int isbad;
first = 1;
hostf = superuser ? NULL : fopen(_PATH_HEQUIV, "r");
again:
if (hostf) {
if (__ivaliduser(hostf, raddr, luser, ruser) == 0) {
(void)fclose(hostf);
return 0;
}
(void)fclose(hostf);
}
if (first == 1 && (__check_rhosts_file || superuser)) {
char *pbuf;
size_t dirlen;
size_t buflen = __sysconf (_SC_GETPW_R_SIZE_MAX);
char *buffer = __alloca (buflen);
if (!superuser)
hostf = iruserfopen (_PATH_HEQUIV, 0);
first = 0;
if (__getpwnam_r (luser, &pwdbuf, buffer, buflen, &pwd) < 0)
return -1;
if (hostf)
{
isbad = __ivaliduser (hostf, raddr, luser, ruser);
fclose (hostf);
dirlen = strlen (pwd->pw_dir);
pbuf = alloca (dirlen + sizeof "/.rhosts");
__mempcpy (__mempcpy (pbuf, pwd->pw_dir, dirlen),
"/.rhosts", sizeof "/.rhosts");
if (!isbad)
return 0;
}
/*
* Change effective uid while opening .rhosts. If root and
* reading an NFS mounted file system, can't read files that
* are protected read/write owner only.
*/
if (__access (pbuf, R_OK) != 0)
hostf = NULL;
else
{
uid_t uid = geteuid ();
seteuid (pwd->pw_uid);
hostf = fopen (pbuf, "r");
seteuid (uid);
}
if (__check_rhosts_file || superuser)
{
char *pbuf;
struct passwd pwdbuf, *pwd;
size_t dirlen;
size_t buflen = __sysconf (_SC_GETPW_R_SIZE_MAX);
char *buffer = __alloca (buflen);
uid_t uid;
if (hostf == NULL)
return -1;
/*
* If not a regular file, or is owned by someone other than
* user or root or if writeable by anyone but the owner, quit.
*/
cp = NULL;
if (lstat(pbuf, &sbuf) < 0)
cp = _(".rhosts lstat failed");
else if (!S_ISREG(sbuf.st_mode))
cp = _(".rhosts not regular file");
else if (fstat(fileno(hostf), &sbuf) < 0)
cp = _(".rhosts fstat failed");
else if (sbuf.st_uid && sbuf.st_uid != pwd->pw_uid)
cp = _("bad .rhosts owner");
else if (sbuf.st_mode & (S_IWGRP|S_IWOTH))
cp = _(".rhosts writeable by other than owner");
/* If there were any problems, quit. */
if (cp) {
__rcmd_errstr = cp;
(void)fclose(hostf);
return -1;
}
goto again;
}
if (__getpwnam_r (luser, &pwdbuf, buffer, buflen, &pwd))
return -1;
dirlen = strlen (pwd->pw_dir);
pbuf = alloca (dirlen + sizeof "/.rhosts");
__mempcpy (__mempcpy (pbuf, pwd->pw_dir, dirlen),
"/.rhosts", sizeof "/.rhosts");
/* Change effective uid while reading .rhosts. If root and
reading an NFS mounted file system, can't read files that
are protected read/write owner only. */
uid = geteuid ();
seteuid (pwd->pw_uid);
hostf = iruserfopen (pbuf, pwd->pw_uid);
if (hostf != NULL)
{
isbad = __ivaliduser (hostf, raddr, luser, ruser);
fclose (hostf);
}
seteuid (uid);
return isbad;
}
return -1;
}
/*

View File

@ -1,5 +1,5 @@
/* Implementation of the bindtextdomain(3) function
Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
Copyright (C) 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
This file is part of the GNU C Library. Its master source is NOT part of
the C library, however.
@ -65,7 +65,9 @@ extern struct binding *_nl_domain_bindings;
prefix. So we have to make a difference here. */
#ifdef _LIBC
# define BINDTEXTDOMAIN __bindtextdomain
# define strdup(str) __strdup (str)
# ifndef strdup
# define strdup(str) __strdup (str)
# endif
#else
# define BINDTEXTDOMAIN bindtextdomain__
#endif

View File

@ -104,6 +104,7 @@ GLIBC_2.0 {
_dl_debug_message;
__ffs;
__close; __connect; __fcntl; __lseek; __open; __read; __send; __wait;
__ieee_get_fp_control; __ieee_set_fp_control;
# Exception handling support functions from libgcc
__register_frame; __register_frame_table; __deregister_frame;

View File

@ -1,4 +1,4 @@
/* Copyright (C) 1991, 1992, 1997 Free Software Foundation, Inc.
/* Copyright (C) 1991, 1992, 1997, 1998 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@ -83,13 +83,14 @@ main (void)
if (!lose && value == 10)
{
/* And again for the `__setjmp' function. */
extern int __setjmp (jmp_buf);
/* And again for the `_setjmp' function. */
#ifndef _setjmp
extern int _setjmp (jmp_buf);
#endif
last_value = -1;
lose = 0;
value = __setjmp (env);
value = _setjmp (env);
if (value != last_value + 1)
{
fputs("Shouldn't have ", stdout);

View File

@ -235,7 +235,7 @@ __memset_cc_by2 (void *__s, int __c, size_t __n)
"jnz 1b\n"
"2:\n\t"
"movw %w2,(%0)"
: "=&r" (__tmp), "=&r" (__dummy)
: "=&r" (__tmp), "=&r" (__d0)
: "q" (0x01010101UL * (unsigned char) __c), "0" (__tmp), "1" (__n / 2)
: "memory", "cc");
return __s;
@ -1516,6 +1516,7 @@ __strstr_g (__const char *__haystack, __const char *__needle)
__STRING_INLINE char *
__strstr_g (__const char *__haystack, __const char *__needle)
{
register unsigned long int __d0, __d1, __d2, __d3;
register char *__res;
__asm__ __volatile__
("cld\n\t"

View File

@ -1,4 +1,7 @@
#define readdir64 __no_readdir64_decl
#define __readdir64 __no___readdir64_decl
#include <sysdeps/unix/readdir.c>
#undef __readdir64
strong_alias (__readdir, __readdir64)
#undef readdir64
weak_alias (__readdir, readdir64)

View File

@ -51,6 +51,7 @@ sendmsg - sendmsg 3 __libc_sendmsg __sendmsg sendmsg
sendto - sendto 6 __libc_sendto __sendto sendto
setsockopt - setsockopt 5 __setsockopt setsockopt
shutdown - shutdown 2 __shutdown shutdown
socket - socket 3 __socket socket
socketpair - socketpair 4 __socketpair socketpair
sysctl - _sysctl 6 sysctl

View File

@ -98,3 +98,14 @@ fi
if test -f $srcdir/elf/ldconfig.c; then
has_ldconfig=yes
fi
# We need some extensions to the `ldd' script.
case "$machine" in
i[3456]86* | m68k | sparc/sparc32)
ldd_rewrite_script=../sysdeps/unix/sysv/linux/ldd-rewrite.sed
;;
*)
;;
esac

View File

@ -83,3 +83,14 @@ fi
if test -f $srcdir/elf/ldconfig.c; then
has_ldconfig=yes
fi
# We need some extensions to the `ldd' script.
changequote(,)
case "$machine" in
i[3456]86* | m68k | sparc/sparc32)
ldd_rewrite_script=../sysdeps/unix/sysv/linux/ldd-rewrite.sed
;;
*)
;;
esac
changequote([,])

View File

@ -2,3 +2,8 @@ ifeq ($(subdir),misc)
sysdep_routines += ioperm iopl vm86
sysdep_headers += sys/perm.h sys/vm86.h
endif
ifeq ($(subdir),elf)
others += lddlibc4
install-bin += lddlibc4
endif