[devel] eu-elflint
Alexey Tourbin
at на altlinux.ru
Пт Дек 18 02:49:49 UTC 2009
On Fri, Dec 18, 2009 at 05:23:20AM +0300, Dmitry V. Levin wrote:
> On Fri, Dec 18, 2009 at 03:05:42AM +0300, Alexey Tourbin wrote:
> > Actually I think maybe we should integrate eu-elflint into
> > /usr/lib/rpm/verify-elf. It has --gnu-ld flag to stop barking
> > at binutils semi-bugs, and otherwise it's useful.
>
> It needs /proc to work due to $ORIGIN thing it uses:
>
> with-proc$ ltrace -s64 -e dlopen eu-elflint --quiet --gnu-ld /bin/true
> dlopen("$ORIGIN/../$LIB/elfutils/libebl_x86_64.so", 1) = 0x1227d810
> +++ exited (status 0) +++
>
> without-proc$ strace -eopen eu-elflint --quiet --gnu-ld /bin/pwd
> open("/etc/ld.so.cache", O_RDONLY) = 3
> open("/usr/lib64/libelf.so.1", O_RDONLY) = 3
> open("/lib64/libdl.so.2", O_RDONLY) = 3
> open("/lib64/libc.so.6", O_RDONLY) = 3
> open("/bin/pwd", O_RDONLY) = 3
> open("/etc/ld.so.cache", O_RDONLY) = 4
> open("/lib64/tls/x86_64/libebl_x86_64.so", O_RDONLY) = -1 ENOENT (No such file or directory)
> open("/lib64/tls/libebl_x86_64.so", O_RDONLY) = -1 ENOENT (No such file or directory)
> open("/lib64/x86_64/libebl_x86_64.so", O_RDONLY) = -1 ENOENT (No such file or directory)
> open("/lib64/libebl_x86_64.so", O_RDONLY) = -1 ENOENT (No such file or directory)
> open("/usr/lib64/tls/x86_64/libebl_x86_64.so", O_RDONLY) = -1 ENOENT (No such file or directory)
> open("/usr/lib64/tls/libebl_x86_64.so", O_RDONLY) = -1 ENOENT (No such file or directory)
> open("/usr/lib64/x86_64/libebl_x86_64.so", O_RDONLY) = -1 ENOENT (No such file or directory)
> open("/usr/lib64/libebl_x86_64.so", O_RDONLY) = -1 ENOENT (No such file or directory)
> section [ 9] '.rela.dyn': relocation 0: invalid type
> [...]
> section [10] '.rela.plt': relocation 50: invalid type
We can use something like
verify-elf: LD_LIBRARY_PATH=@LIBDIR@/elfutils eu-elflint...
rpm.spec: Requires: %_libdir/elfutils
----------- следующая часть -----------
Было удалено вложение не в текстовом формате...
Имя : отсутствует
Тип : application/pgp-signature
Размер : 198 байтов
Описание: отсутствует
Url : <http://lists.altlinux.org/pipermail/devel/attachments/20091218/bb2d28cf/attachment.bin>
Подробная информация о списке рассылки Devel