Bug 54081

Summary: Cannot build man-1.5i2-0.6x.5 RPM from SRPM
Product: [Retired] Red Hat Linux Reporter: Craig Prescott <prescott>
Component: rpmAssignee: Jeff Johnson <jbj>
Status: CLOSED WONTFIX QA Contact: Ben Levenson <benl>
Severity: high Docs Contact:
Priority: medium    
Version: 6.2   
Target Milestone: ---   
Target Release: ---   
Hardware: alpha   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2001-09-28 05:15:33 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:

Description Craig Prescott 2001-09-27 03:55:51 UTC
Description of Problem:
When building a binary rpm from man-1.5i2-0.6x.5.src.rpm
[RHSA-2001:072-14], rpm dies when trying to gzip the man pages because it
is looking in the wrong place.

The following patch fixes the problem.

--- man.spec~   Fri Aug 24 12:55:13 2001
+++ man.spec    Wed Sep 26 23:17:32 2001
@@ -41,6 +41,7 @@
 Requires: less, groff, findutils, mktemp >= 1.5-2.1.5x
 %if %{legacypaths}
 %define cache /var/catman
+%define _mandir /usr/man
 %else
 %define cache /var/cache/man
 %endif

Version-Release number of selected component (if applicable):
1.5i2-0.6x.5

How Reproducible:
completely

Steps to Reproduce:
1. rpm --rebuild man-1.5i2-0.6x.5.src.rpm
2. 
3. 

Actual Results:
<...>
install -m 644 man2html.1 /var/tmp/man-root/usr/man/man1/man2html.1
+ strip -R .comment /var/tmp/man-root/usr/bin/man2html
+ gzip -9f /var/tmp/man-root/usr/share/man/*/*
/var/tmp/man-root/usr/share/man/*/*: No such file or directory
error: Bad exit status from /var/tmp/rpm-tmp.11587 (%install)


RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.11587 (%install)

Expected Results:
<...>
install -m 644 man2html.1 /var/tmp/man-root/usr/man/man1/man2html.1
+ strip -R .comment /var/tmp/man-root/usr/bin/man2html
+ gzip -9f /var/tmp/man-root/usr/man/man1/apropos.1
/var/tmp/man-root/usr/man/man1/man.1
/var/tmp/man-root/usr/man/man1/man2html.1
/var/tmp/man-root/usr/man/man1/whatis.1
/var/tmp/man-root/usr/man/man5/man.config.5
/var/tmp/man-root/usr/man/man8/makewhatis.8
+ cd /var/tmp/man-root
<...>
+ exit 0

Additional Information:
I am using rpm-4.0.2-6x.

Comment 1 Bernhard Rosenkraenzer 2001-09-27 12:20:06 UTC
Looks like the current rpm for 6.x doesn't set _mandir correctly. Not sure 
whether this is a problem in the actual rpm errata package or a local config 
issue, reassigning for now.


Comment 2 Craig Prescott 2001-09-28 05:15:09 UTC
In my initial report, I did not choose the correct platform - please accept my
apologies for this mistake...


Comment 3 Jeff Johnson 2001-10-04 12:21:25 UTC
Internalizing %_mandir, particularly for the man package,
is the best solution, as detecting the correct value of
mandir during a transition from /usr/man to /usr/share/man
is difficult to get right in rpm, particularly since build
configuartion preferences are involved.