Bug 749195

Summary: [PATCH] nfs-utils-1.2.5-2.fc16 fails to build, PAGE_SIZE undefined
Product: [Fedora] Fedora Reporter: Karsten Hopp <karsten>
Component: nfs-utilsAssignee: Steve Dickson <steved>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: high    
Version: 16CC: bfields, jlayton, jskala, steved
Target Milestone: ---   
Target Release: ---   
Hardware: powerpc   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-11-28 09:18:59 EST Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Bug Depends On:    
Bug Blocks: 718272    
Description Flags
fix for undefined PAGE_SIZE none

Description Karsten Hopp 2011-10-26 09:14:18 EDT
Created attachment 530281 [details]
fix for undefined PAGE_SIZE

Description of problem:
ppc and ppc64 don't have PAGE_SIZE defined in the glibc headers, so nfs-utils fails to build:

Version-Release number of selected component (if applicable):
nfs-utils-1.2.5-2.fc16 and nfs-utils-1.2.5-1.fc16

How reproducible:

Steps to Reproduce:
1. ppc-koji build --scratch dist-f16 nfs-utils-1.2.5-2.fc16.src.rpm
Actual results:
Comment 1 Steve Dickson 2011-11-14 07:35:37 EST
It appears glibc-headers was removed from the default build root... 

Instead the patch that adds the define, wouldn't be simpler
and better to add glibc-headers to the BuildRequires list?
Comment 2 Karsten Hopp 2011-11-15 15:09:31 EST
no, root.log of http://ppc.koji.fedoraproject.org/koji/taskinfo?taskID=306011 has this:

DEBUG util.py:247:   glibc                     ppc       2.14.90-13                  build    4.6 M
DEBUG util.py:247:   glibc-common              ppc       2.14.90-13                  build     11 M
DEBUG util.py:247:   glibc-devel               ppc       2.14.90-13                  build    989 k
DEBUG util.py:247:   glibc-headers             ppc       2.14.90-13                  build    602 k

(The root.log is from PPC, but I've reproduced this on PPC64)
Comment 3 Jeff Layton 2011-11-15 15:15:07 EST
Why is PAGE_SIZE not defined in the glibc headers on those arches? I'd imagine that that would break a lot of code, not just nfs-utils...
Comment 4 Jiri Skala 2011-11-22 10:06:28 EST
searching on ppc64:

/usr/include/common.h:#define PAGE_SIZE 4096
Comment 5 Karsten Hopp 2011-11-22 14:19:36 EST
re: comment #4: neither nfs-utils nor any of its build requirements pull in librtas-devel (which provides /usr/include/common.h). In addition common.h doesn't get included and has a wrong value on ppc where we have a 64k pagesize.

re: comment #3: actually there only a few packages (<5) that use PAGE_SIZE instead of getpagesize(), at least that's my impression after rebuilding > 10000 packages on ppc.
Comment 6 Steve Dickson 2011-11-22 15:28:09 EST
This appears to be fixed in nfs-utils-1.2.5-3.fc16 which has been pushed to stable.
Comment 7 Steve Dickson 2011-11-28 09:18:59 EST
(In reply to comment #6)
> This appears to be fixed in nfs-utils-1.2.5-3.fc16 which has been pushed to
> stable.
The latest nfs-utils version does indeed build: