Bug 81385

Summary: rpmdeps adds paths to provides of an rpm
Product: [Retired] Red Hat Public Beta Reporter: ajs <ajsfedora>
Component: rpmAssignee: Jeff Johnson <jbj>
Status: CLOSED WORKSFORME QA Contact: Mike McLean <mikem>
Severity: medium Docs Contact:
Priority: medium    
Version: phoebe   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-01-08 22:29:46 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
provides result
none
requires result none

Description ajs 2003-01-08 19:12:31 UTC
Description of problem:
rpm-build generates odd 'provides' listing.  Some libraries have relative or
absolute paths in the output of
find /var/tmp/rpm-buildroot -type f | xargs /usr/lib/rpm/rpmdeps --provides. 
This causes all of the libraries provided by the package to not satisfy the
requirements found by rpmdeps --requires.  The rpm thus does not install on the
system on which it was just built.

With rpm-build-4.1-1.06 there were no paths and the rpm would install.

Version-Release number of selected component (if applicable):
rpm -q rpm-build: rpm-build-4.2-0.25.1

Repeatability:
I can get rpmbuild to do it with an RPM I build of our local Matlab
installation.  I'm having trouble getting other packages to do it.

Steps to Reproduce:
1. rpmbuild -bi mza-matlab.spec
2. find /var/tmp/mza-matlab-6.5-buildroot -type f | xargs /usr/lib/rpm/rpmdeps
--provides | sort --unique
    
Actual results:


Expected results:


Additional info:

Comment 1 Jeff Johnson 2003-01-08 22:02:29 UTC
I need more details to even begin to guess what's happening.

Can you attach the output of rpmdeps --rpmfcdebug, and point
out the specific file/dependency that is not being generated?

Comment 2 ajs 2003-01-08 22:09:41 UTC
Created attachment 89220 [details]
provides result

result of 'find /var/tmp/mza-matlab-6.5-buildroot -type f | xargs
'/usr/lib/rpm/rpmdeps --provides | sort --unique > mza-matlab.provides

Comment 3 ajs 2003-01-08 22:11:23 UTC
Created attachment 89221 [details]
requires result

result of 'find /var/tmp/mza-matlab-6.5-buildroot -type f | xargs
/usr/lib/rpm/rpmdeps --requires | sort --unique > mza-matlab.requires'

Comment 4 ajs 2003-01-08 22:18:47 UTC
Notice that the provides script says that the rpm provides e.g.
'../../bin/glnx86/libmex.so(libmex.INTERNAL)' while the requires script wants
'libmex.so' and 'libmex.so(libmex.INTERNAL)'.  All of the lines in the provides
result that have paths in them generate complaints when I try and install the rpm.

I'm in the process of getting the output of 'rpmdeps --rpmfcdebug'


Comment 5 ajs 2003-01-08 22:27:15 UTC
the output of 'find /var/tmp/mza-matlab-6.5-buildroot -type f | xargs
/usr/lib/rpm/rpmdeps --rpmfcdebug > mza-matlab.rpmfcdebug 2>&1' is about 3 1/2
Meg.  Do you still want it as an attachment?

Comment 6 Jeff Johnson 2003-01-08 22:29:46 UTC
Ick. I can see lots of packaging problems here.

Add to spec file (or to build system configuration)
    %_use_internal_dependency_generator 0
    %__find_requires /usr/lib/rpm/find-requires
    %__find_provides /usr/lib/rpm/find-provides

and you'll be autogenerating dependencies
the Good Old Way.

You will lose per-file dependencies, and file
classes/colors, but I very much doubt that you care.

Comment 7 Jeff Johnson 2003-01-08 22:31:46 UTC
The --rmfcdebug indicates which files generated
which dependencies.

The next step is to examine readelf -a
output, looking for anomalies.

Comment 8 Jeff Johnson 2003-01-08 22:34:04 UTC
Note if adding to spec file you want
    %define __find_requires /usr/lib/rpm/find-requires
etc.