Bug 113273
Summary: | rpm-build check-files Broken pipe | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Andrea Pasquinucci <cesare> | ||||||
Component: | rpm | Assignee: | Jeff Johnson <jbj> | ||||||
Status: | CLOSED RAWHIDE | QA Contact: | Mike McLean <mikem> | ||||||
Severity: | medium | Docs Contact: | |||||||
Priority: | medium | ||||||||
Version: | 1 | ||||||||
Target Milestone: | --- | ||||||||
Target Release: | --- | ||||||||
Hardware: | athlon | ||||||||
OS: | Linux | ||||||||
Whiteboard: | |||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||
Doc Text: | Story Points: | --- | |||||||
Clone Of: | Environment: | ||||||||
Last Closed: | 2004-02-10 21:26:17 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
Andrea Pasquinucci
2004-01-11 20:29:21 UTC
Do you have a BuildRoot: directive in your spec file? Yes I do! Please notice the output of my echo "Value of RPM_BUILD_ROOT="$RPM_BUILD_ROOT 1>&2 added command to check-files, there is %{buildroot}, that is the name of the parameter and not its value. Andrea Please supply a ptr (i.e. URL) to a src.rpm and I'll take a look. I'm back, sorry for the delay. I spent part of today trying to figure out what is going on, little luck. First the URLs: http://www.ucci.it/prps-0-2.src.rpm http://www.ucci.it/rpmmacros the simpliest src.rpm I have and my latest ~/.rpmmacros Anyway, now I can build rpm giving as a normal user the command rpmbuild -vv --root ~/URPM -ba prps-0.spec but 1. there MUST NOT be a Buildroot: in the spec file (last time I tried I had to have a BuildRoot, boh...) 2. there MUST NOT be a %_topdir in the .rpmmacros file 3. there MUST NOT be any variable used to define parameters in the .rpmmacros file (like %{name} etc.) 4. I MUST set by hand the variable $RPM_BUILD_ROOT in the file /usr/lib/rpm/check-files If I do not do one of these things, it seems to me that parameters are not expanded, like it is trying to open files with name /usr/src/redhat/%{buildroot} (this is an example I made up, the point is that %buildroot is NOT expanded), I can see this by running strace. Or it makes path where it repeats 3 or 4 times the Buildroot I gave in the spec file, and it puts a file in a dir with 3 times the Buildroot but looks for it in dir with 2 times the Buildroot ... I am totaly, completely confused, but I can build rpm now. PS. Same thing if I build rpm as root. Adding --root to rpmbuild requires additional configuration and does not have any simple (or useful to you) semantics. What happens if you build w/o --root? As the root user giving the command rpmbuild -vv -ba prps-0.spec it works with my modified check-files script, otherwise it does not (I attach the outcome of both cases), but it requires that I build from the real tree of the machine, whereas I have the files in an private tree (non root owned) starting under my own home directory. If I build from the root directory as a normal user, it works as for root (check-files must be modified), but only with the ~/.rpmmacros file I posted. Created attachment 97093 [details]
output of rpmbuild with original check-files script
Created attachment 97094 [details]
rpmbuild output with modified check-files script
The broken pipe message is now addressed by flushing the input pipe. rpm-4.2.2-0.8 and later. |