Red Hat Bugzilla – Bug 218222
rpmbuild creates RPMs with incorrect MD5s
Last modified: 2008-05-06 13:06:27 EDT
rpmbuild creates RPMs with incorrect MD5s when already prelinked binaries are
to be installed.
Essentially, add any binary from an already installed rpm (in this case
/usr/bin/env) into an rpm and rpmbuild will create a corrupt rpm that cannot be
Steps the reproduce:
Build the spec attached and try and install the result.
rpmbuild -ba env-prelink.spec
rpm -U <the resulting rpm>
error: unpacking of archive failed on file /usr/bin/env-prelinked;45732eeb:
cpio: MD5 sum mismatch
Uncomment the "prelink -u" line and try again. It will work.
See bug #158266 which might be related.
Created attachment 142690 [details]
Trivial specfile that creates an uninstallable rpm
The problem is not misgenerates in rpmbuild, but rather prelink -undo is being run inappropriately,
so the wrong plaintext is checked.
Addin a brp-prelink-undo script is probably the best fix, although that can be done manually in %install
AFAIK, it makes no sense to package a file prelinked on one machine for installation on another.
So doing prelink -undo on the build machine seems to be what needs doing.
> it makes no sense to package a file prelinked on one machine for installation
How about a deb to rpm translator? How about a backwards compatible binary
package built from files from an old distribution?
> Addin a brp-prelink-undo script is probably the best fix
Are you suggesting a general fix for rpm or a hack that users should know they
need to add to their spec file?
> although that can be done manually in %install if necessary.
This took quite a while to track down. I really wouldn't wish the process on
> The problem is not misgenerates in rpmbuild, but rather prelink -undo is being
run inappropriately, so the wrong plaintext is checked.
If rpm/rpmbuild wants to alter binaries before packaging them, then it should at
least try to do it in a consistent way.
A brp-prelink-undo script would be a general solution.
rpm did not run prelink on your library.
I have no idea what a deb->rpm translator or a backwards compatible binary
has to do with prelinking. Prelinked libraries should not be packaged, only
un-prelinked libraries. Prelinking is done on the install, not the build, machine.
User email@example.com's account has been closed
Reassigning to owner after bugzilla made a mess, sorry about the noise...
Fedora apologizes that these issues have not been resolved yet. We're
sorry it's taken so long for your bug to be properly triaged and acted
on. We appreciate the time you took to report this issue and want to
make sure no important bugs slip through the cracks.
If you're currently running a version of Fedora Core between 1 and 6,
please note that Fedora no longer maintains these releases. We strongly
encourage you to upgrade to a current Fedora release. In order to
refocus our efforts as a project we are flagging all of the open bugs
for releases which are no longer maintained and closing them.
If this bug is still open against Fedora Core 1 through 6, thirty days
from now, it will be closed 'WONTFIX'. If you can reporduce this bug in
the latest Fedora version, please change to the respective version. If
you are unable to do this, please add a comment to this bug requesting
Thanks for your help, and we apologize again that we haven't handled
these issues to this point.
The process we are following is outlined here:
We will be following the process here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping to ensure this
doesn't happen again.
And if you'd like to join the bug triage team to help make things
better, check out http://fedoraproject.org/wiki/BugZappers
This bug is open for a Fedora version that is no longer maintained and
will not be fixed by Fedora. Therefore we are closing this bug.
If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen thus bug against that version.
Thank you for reporting this bug and we are sorry it could not be fixed.