Red Hat Bugzilla – Bug 109518
rpmbuild produces errors on ELF files with no section header
Last modified: 2007-04-18 12:59:17 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20031018
Description of problem:
When building an RPM that has an ELF format file with no section
header, rpmbuild will produce a bogus error. This seems to be
associated with the file source that is included with it. Another
case has been logged with the file program too. (See bug #109509
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Try to produce an RPM using the precompiled program at
Actual Results: rpmbuild: corrupted program header size.
Expected Results: RPM should finish building.
The epsxe binary was compressed with the UPX file packer which
produces an ELF executable without a section header. (Also, the error
should read "rpmbuild: corrupted section header size")
That's a elfutils message, reassigning.
Manwhile you can disable the use of elfutils when building
# Use internal dependency generator rather than external helpers?
There is a minor loss of functionality because dependencies
will not be attached to files, only to packages, but I doubt
you will notice.
Created attachment 96389 [details]
Patch for RPM
The error seems to be in the readelf.c file in the file directory of rpm
(source from the file program that's been added to rpm) I've attached a patch
that fixes the problem for me.
This is no libelf issue. As correctly said in comment #2, this is
elfutils is no longer distributed internal to rpm sources in rpm-4.4.x and later.