large stack with only 64kb of remaining space, which the upstream alloca
heuristic is ill-equipped to deal with.
Forward-ported from cl/51331379 (from cl/38559-p2).
- (ppluzhnikov, google-local)
+ (ppluzhnikov, google-local)
locale/programs/locarchive.c
Reduce starting table sizes for locale-archive file, since we use only a
For b/15780211, revert local change to csu/elf-init.c and move
initialization of __google_auxv earlier (in the fully-static link).
(ppluzhnikov, google-local)
+
+elf/ldd.bash.in
+ Import ldd patches from Ubuntu source package. This fixes the ability
+ of ldd to trace dependencies in non-executable dynamic libraries.
+ (bmoses, google-local)
echo "ldd: ${file}:" $"not regular file" >&2
result=1
elif test -r "$file"; then
- test -x "$file" || echo 'ldd:' $"\
-warning: you do not have execution permission for" "\`$file'" >&2
RTLD=
ret=1
for rtld in ${RTLDLIST}; do
if test -x $rtld; then
- verify_out=`${rtld} --verify "$file"`
- ret=$?
- case $ret in
- [02]) RTLD=${rtld}; break;;
- esac
+ dummy=`$rtld 2>&1`
+ if test $? = 127; then
+ verify_out=`${rtld} --verify "$file"`
+ ret=$?
+ case $ret in
+ [02]) RTLD=${rtld}; break;;
+ esac
+ fi
fi
done
case $ret in
- 0)
- # If the program exits with exit code 5, it means the process has been
- # invoked with __libc_enable_secure. Fall back to running it through
- # the dynamic linker.
- try_trace "$file"
- rc=$?
- if [ $rc = 5 ]; then
- try_trace "$RTLD" "$file"
- rc=$?
- fi
- [ $rc = 0 ] || result=1
+ 0|2)
+ try_trace "$RTLD" "$file" || result=1
;;
1)
# This can be a non-ELF binary or no binary at all.
result=1
}
;;
- 2)
- try_trace "$RTLD" "$file" || result=1
- ;;
*)
echo 'ldd:' ${RTLD} $"exited with unknown exit code" "($ret)" >&2
exit 1