Bug 218222 - rpmbuild creates RPMs with incorrect MD5s
Summary: rpmbuild creates RPMs with incorrect MD5s
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: rpm
Version: 6
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Panu Matilainen
QA Contact:
URL:
Whiteboard: bzcl34nup
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2006-12-03 20:14 UTC by Jim Radford
Modified: 2008-05-06 17:06 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-05-06 17:06:27 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Trivial specfile that creates an uninstallable rpm (719 bytes, text/plain)
2006-12-03 20:14 UTC, Jim Radford
no flags Details

Description Jim Radford 2006-12-03 20:14:27 UTC
Summary:

  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
installed.

Steps the reproduce:

  Build the spec attached and try and install the result. 

    rpmbuild -ba env-prelink.spec
    rpm -U <the resulting rpm>

Results:

    error: unpacking of archive failed on file /usr/bin/env-prelinked;45732eeb:
cpio: MD5 sum mismatch

Additional Info:

  Uncomment the "prelink -u" line and try again.  It will work.

  See bug #158266 which might be related.

Comment 1 Jim Radford 2006-12-03 20:14:27 UTC
Created attachment 142690 [details]
Trivial specfile that creates an uninstallable rpm

Comment 2 Jeff Johnson 2006-12-03 22:58:50 UTC
The problem is not misgenerates in rpmbuild, but rather prelink -undo is being run inappropriately,
so the wrong plaintext is checked.

Comment 3 Jeff Johnson 2006-12-03 23:07:37 UTC
Addin a brp-prelink-undo script is probably the best fix, although that can be done manually in %install
if necessary.

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.

Comment 4 Jim Radford 2006-12-04 20:11:24 UTC
> it makes no sense to package a file prelinked on one machine for installation
on another.

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
someone else.

> 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.

Comment 5 Jeff Johnson 2006-12-05 23:54:22 UTC
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.

Comment 6 Red Hat Bugzilla 2007-08-21 05:30:07 UTC
User pnasrat's account has been closed

Comment 7 Panu Matilainen 2007-08-22 06:30:06 UTC
Reassigning to owner after bugzilla made a mess, sorry about the noise...

Comment 8 Bug Zapper 2008-04-04 05:04:54 UTC
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.
http://fedoraproject.org/wiki/LifeCycle/EOL

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
the change.

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:
http://fedoraproject.org/wiki/BugZappers/F9CleanUp

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

Comment 9 Bug Zapper 2008-05-06 17:06:25 UTC
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.


Note You need to log in before you can comment on or make changes to this bug.