verify-elf.in: PIE executables on ARM always has TEXTREL, do not check them

This commit is contained in:
Дмитрий Левин 2008-02-24 23:09:25 +00:00
parent cd04e08abc
commit 816b34cd86

View File

@ -129,11 +129,14 @@ for f in "$@"; do
fi
if [ -n "$VERIFY_ELF_TEXTREL" ]; then
textrel="$(printf %s "$objdump_info" |sed -ne 's/^[[:space:]]*TEXTREL[[:space:]]\+\([^[:space:]]\+\).*/\1/p')"
if [ -n "$textrel" ]; then
[ "$VERIFY_ELF_TEXTREL" = relaxed ] && prefix=WARNING || prefix=ERROR
[ "$VERIFY_ELF_TEXTREL" = relaxed ] || rc=1
Info "$prefix: $f: TEXTREL entry found: $textrel"
# PIE executables on ARM always has TEXTREL, do not check them.
if [ -z "$RPM_TARGET_ARCH" -o -n "${RPM_TARGET_ARCH##arm*}" -o ! -x "$f" -o -n "${t##*ELF*shared object*}" ]; then
textrel="$(printf %s "$objdump_info" |sed -ne 's/^[[:space:]]*TEXTREL[[:space:]]\+\([^[:space:]]\+\).*/\1/p')"
if [ -n "$textrel" ]; then
[ "$VERIFY_ELF_TEXTREL" = relaxed ] && prefix=WARNING || prefix=ERROR
[ "$VERIFY_ELF_TEXTREL" = relaxed ] || rc=1
Info "$prefix: $f: TEXTREL entry found: $textrel"
fi
fi
fi