Bug 189833

Summary: h2ph problem with gcc internal defines
Product: Red Hat Enterprise Linux 3 Reporter: Jason Vas Dias <jvdias>
Component: perlAssignee: Jason Vas Dias <jvdias>
Status: CLOSED ERRATA QA Contact: David Lawrence <dkl>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0CC: jlieskov, perl-devel, pgraner, poelstra, prockai
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: RHBA-2006-0294 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-05-10 21:57:45 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:
Bug Depends On: 185406    
Bug Blocks: 187539    

Comment 1 Jason Vas Dias 2006-04-24 23:40:18 UTC
I was under the mistaken impression that this bug did not affect RHEL-3 -
but it does:

$ perl -e 'require "sys/socket.ph";'
Can't locate features.ph in @INC (did you run h2ph?) 
$ perl -v
...
This is perl, v5.8.0 built for ppc-linux-thread-multi
...
$ uname -a 
uname -a
Linux pseries.test.redhat.com 2.4.21-37.0.1.EL #1 SMP Wed Jan 11 18:37:26 EST
2006 ppc64 ppc64 ppc64 GNU/Linux


This bug was found during testing of errata 2006:294 by  
Jan Lieskovsky <jlieskov> , during an attempted run of RHTS
test script 185240.t, which failed.

This test succeeded on my test machine because I had run h2ph on many
include files manually a long time ago, and they were not removed by
rpm upgrade - I had forgotten about them.

It seems that this never worked in 5.8.0-89.10, the RHEL-3-U4 perl, either,
since this make command, used to generate the list of headers to convert, 
failed, and 5.8.0-89.10 does not contain features.ph either :
---
# Generate *.ph files with a trick. Is this sick or what ?
make all -f - <<EOF
PKGS	= glibc-devel gdbm-devel gpm-devel libgr-devel libjpeg-devel \
	  libpng-devel libtiff-devel ncurses-devel popt \
	  zlib-devel binutils libelf e2fsprogs-devel pam pwdb \
	  rpm-devel
STDH	= \$(filter %{_includedir}/include/%%, \$(shell rpm -q --queryformat
'[%%{FILENAMES}\n]' \$(PKGS)))
...
---
While maybe not "sick", it was definitely not "well", as the rpm listing failed
owing to the nonexistence of 'libgr-devel" (or "libelf") , so none of the 
headers intended to be shipped by the rpm listing were shipped.

This is now fixed with perl-5.8.0-93.EL3, which ships all the headers in :
         gcc glibc-headers glibc-kernheaders binutils elfutils-devel  \
         gdbm-devel gpm-devel libjpeg-devel \
	 libpng-devel libtiff-devel ncurses-devel popt \
	 zlib-devel e2fsprogs-devel pam-devel \
	 rpm-devel | egrep '\.h$'

Now the socket.ph requires succeeds, though with some warnings:
$ perl -e 'require "sys/socket.ph";'
Scalar found where operator expected at (eval 147) line 1, near "'int'  $__val"
        (Missing operator before   $__val?)
String found where operator expected at (eval 394) line 1, near "&__const
'struct sockaddr'"
        (Missing operator before  'struct sockaddr'?)
$ echo $?
0

The same warnings are generated when I convert the RHEL-3 headers with the
latest upstream perl-5.8.8 version - it is an upstream h2ph problem, that
I will fix in FC-{6,5,4} and later in RHEL-{3,4} in due course, but which is 
not critical for RHEL-3 - the requires and all tests now succeed.

Comment 2 Jason Vas Dias 2006-04-25 00:42:42 UTC
Please can we add the appropriate ACKs to this bug and add it to the 
RHEL-3-U8 CANFIX list as it was found during testing of errata 2006:294
and is fixed with a correction the the .spec file only .


Comment 5 Red Hat Bugzilla 2006-05-10 21:57:46 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2006-0294.html