Bug 193450 - rpmbuild problems
rpmbuild problems
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: php (Show other bugs)
2
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Joe Orton
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-05-28 19:46 EDT by Michael Mussulis
Modified: 2007-11-30 17:11 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-06-01 09:57:43 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
PHP Bug Tracker 36419 None None None Never

  None (edit)
Description Michael Mussulis 2006-05-28 19:46:40 EDT
Description of problem:
Downloaded the latest fedora core source rpm (php-5.1.2-4.3.src.rpm),
installed using rpm -ivh, and invoked rpmbuild -bb.

Build fails with message:

checking for C compiler default output file name... configure: error: C
compiler cannot create executables
See `config.log' for more details.
error: Bad exit status from /var/tmp/rpm-tmp.21471 (%build)

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

I have tried earlier versions, but same problem. The only version which
builds, is 5.0.4-3. Curiously, compiling php from tar.gz distrubution
works fine.



Version-Release number of selected component (if applicable):
5.1.2-4.3

How reproducible:
As in description

Steps to Reproduce:
1. Download php 5.1.2 src rpm
2. install with rpm -ivh
3. Build with rpmbuild -bb php.spec
  
Actual results:
[root@fc2 php-5.1.2]# rpmbuild -bb
/usr/src/redhat/SPECS/php-5.1.2-4.3.spec
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.68654
+ umask 022
+ cd /usr/src/redhat/BUILD
+ LANG=C
+ export LANG
+ unset DISPLAY
+ cd /usr/src/redhat/BUILD
+ rm -rf php-5.1.2
+ /usr/bin/gzip -dc /usr/src/redhat/SOURCES/php-5.1.2.tar.gz
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd php-5.1.2
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chown -Rhf root .
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chgrp -Rhf root .
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ echo 'Patch #5 (php-4.3.3-install.patch):'
Patch #5 (php-4.3.3-install.patch):
+ patch -p1 -b --suffix .install -s
+ echo 'Patch #6 (php-5.0.4-norpath.patch):'
Patch #6 (php-5.0.4-norpath.patch):
+ patch -p1 -b --suffix .norpath -s
+ echo 'Patch #7 (php-4.3.2-libtool15.patch):'
Patch #7 (php-4.3.2-libtool15.patch):
+ patch -p1 -b --suffix .libtool15 -s
+ echo 'Patch #13 (php-5.0.2-phpize64.patch):'
Patch #13 (php-5.0.2-phpize64.patch):
+ patch -p1 -b --suffix .phpize64 -s
+ echo 'Patch #21 (php-4.3.1-odbc.patch):'
Patch #21 (php-4.3.1-odbc.patch):
+ patch -p1 -b --suffix .odbc -s
+ echo 'Patch #22 (php-4.3.11-shutdown.patch):'
Patch #22 (php-4.3.11-shutdown.patch):
+ patch -p1 -b --suffix .shutdown -s
+ echo 'Patch #30 (php-5.0.4-dlopen.patch):'
Patch #30 (php-5.0.4-dlopen.patch):
+ patch -p1 -b --suffix .dlopen -s
+ echo 'Patch #31 (php-5.0.0-easter.patch):'
Patch #31 (php-5.0.0-easter.patch):
+ patch -p1 -b --suffix .easter -s
+ echo 'Patch #50 (php-5.0.4-tests-dashn.patch):'
Patch #50 (php-5.0.4-tests-dashn.patch):
+ patch -p1 -b --suffix .tests-dashn -s
+ echo 'Patch #51 (php-5.0.4-tests-wddx.patch):'
Patch #51 (php-5.0.4-tests-wddx.patch):
+ patch -p1 -b --suffix .tests-wddx -s
+ cp Zend/LICENSE Zend/ZEND_LICENSE
+ cp TSRM/LICENSE TSRM_LICENSE
+ cp regex/COPYRIGHT regex_COPYRIGHT
+ cp ext/gd/libgd/README gd_README
+ mkdir build-cgi build-apache
+ rm -f ext/standard/tests/file/bug21131.phpt
+ rm -f ext/standard/tests/file/bug22414.phpt
ext/iconv/tests/bug16069.phpt
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.21471
+ umask 022
+ cd /usr/src/redhat/BUILD
+ cd php-5.1.2
+ LANG=C
+ export LANG
+ unset DISPLAY
+ libtoolize --force --copy
++ aclocal --print-ac-dir
+ cat /usr/share/aclocal/libtool.m4
+ ./buildconf --force
Forcing buildconf
using default Zend directory
buildconf: checking installation...
buildconf: autoconf version 2.59 (ok)
buildconf: Your version of autoconf likely contains buggy cache code.
           Running cvsclean for you.
           To avoid this, install autoconf-2.13.
rebuilding aclocal.m4
rebuilding configure
aclocal.m4:2054: PHP_PROG_LEX is expanded from...
rebuilding main/php_config.h.in
autoheader: WARNING: Using auxiliary files such as `acconfig.h',
`config.h.bot'
autoheader: WARNING: and `config.h.top', to define templates for
`config.h.in'
autoheader: WARNING: is deprecated and discouraged.
autoheader:
autoheader: WARNING: Using the third argument of `AC_DEFINE' and
autoheader: WARNING: `AC_DEFINE_UNQUOTED' allows to define a template
without
autoheader: WARNING: `acconfig.h':
autoheader:
autoheader: WARNING:   AC_DEFINE([NEED_FUNC_MAIN], 1,
autoheader:             [Define if a function `main' is needed.])
autoheader:
autoheader: WARNING: More sophisticated templates can also be produced,
see the
autoheader: WARNING: documentation.
aclocal.m4:2054: PHP_PROG_LEX is expanded from...
+ CFLAGS=-O2 -g -pipe -march=i386 -mcpu=i686 -fno-strict-aliasing
-Wno-pointer-sign
+ export CFLAGS
+ EXTENSION_DIR=/usr/lib/php/modules
+ export EXTENSION_DIR
+ PEAR_INSTALLDIR=/usr/share/pear
+ export PEAR_INSTALLDIR
+ pushd build-cgi
/usr/src/redhat/BUILD/php-5.1.2/build-cgi
/usr/src/redhat/BUILD/php-5.1.2
+ build --enable-force-cgi-redirect --enable-pcntl --with-imap=shared
--with-imap-ssl --enable-mbstring=shared --enable-mbstr-enc-trans
--enable-mbregex --with-ncurses=shared --with-gd=shared
--enable-bcmath=shared --enable-dba=shared --with-db4=/usr
--with-xmlrpc=shared --with-ldap=shared --with-mysql=shared,/usr
--with-mysqli=shared,/usr/bin/mysql_config --enable-dom=shared
--with-dom-xslt=/usr --with-dom-exslt=/usr --with-pgsql=shared
--with-snmp=shared,/usr --enable-soap=shared --with-xsl=shared,/usr
--enable-xmlreader=shared --enable-xmlwriter=shared --enable-fastcgi
--enable-pdo=shared --with-pdo-odbc=shared,unixODBC,/usr
--with-pdo-mysql=shared,/usr --with-pdo-pgsql=shared,/usr
--with-pdo-sqlite=shared,/usr
+ mkdir Zend
+ cp ../Zend/zend_language_parser.c ../Zend/zend_language_parser.h
../Zend/zend_language_scanner.c ../Zend/zend_language_scanner.h
../Zend/zend_ini_parser.c ../Zend/zend_ini_parser.h
../Zend/zend_ini_scanner.c ../Zend/zend_ini_scanner.h Zend
+ ln -sf ../configure
+ CFLAGS=-O2 -g -pipe -march=i386 -mcpu=i686 -fno-strict-aliasing
-Wno-pointer-sign
+ export CFLAGS
+ CXXFLAGS=-O2 -g -pipe -march=i386 -mcpu=i686
+ export CXXFLAGS
+ FFLAGS=-O2 -g -pipe -march=i386 -mcpu=i686
+ export FFLAGS
++ find . -name config.guess -o -name config.sub
+ ./configure --host=i686-redhat-linux-gnu --build=i686-redhat-linux-gnu
--target=i386-redhat-linux-gnu --program-prefix= --prefix=/usr
--exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin
--sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include
--libdir=/usr/lib --libexecdir=/usr/libexec --localstatedir=/var
--sharedstatedir=/usr/com --mandir=/usr/share/man
--infodir=/usr/share/info --cache-file=../config.cache --with-libdir=lib
--with-config-file-path=/etc --with-config-file-scan-dir=/etc/php.d
--disable-debug --with-pic --disable-rpath --without-pear --with-bz2
--with-curl --with-exec-dir=/usr/bin --with-freetype-dir=/usr
--with-png-dir=/usr --enable-gd-native-ttf --without-gdbm --with-gettext
--with-gmp --with-iconv --with-jpeg-dir=/usr --with-openssl --with-png
--with-pspell --with-expat-dir=/usr --with-pcre-regex=/usr --with-zlib
--with-layout=GNU --enable-exif --enable-ftp --enable-magic-quotes
--enable-sockets --enable-sysvsem --enable-sysvshm --enable-sysvmsg
--enable-track-vars --enable-trans-sid --enable-yp --enable-wddx
--with-kerberos --enable-ucd-snmp-hack --with-unixODBC=shared,/usr
--enable-memory-limit --enable-shmop --enable-calendar --enable-dbx
--enable-dio --with-mime-magic=/etc/httpd/conf/magic --without-sqlite
--with-libxml-dir=/usr --with-xml --enable-force-cgi-redirect
--enable-pcntl --with-imap=shared --with-imap-ssl
--enable-mbstring=shared --enable-mbstr-enc-trans --enable-mbregex
--with-ncurses=shared --with-gd=shared --enable-bcmath=shared
--enable-dba=shared --with-db4=/usr --with-xmlrpc=shared
--with-ldap=shared --with-mysql=shared,/usr
--with-mysqli=shared,/usr/bin/mysql_config --enable-dom=shared
--with-dom-xslt=/usr --with-dom-exslt=/usr --with-pgsql=shared
--with-snmp=shared,/usr --enable-soap=shared --with-xsl=shared,/usr
--enable-xmlreader=shared --enable-xmlwriter=shared --enable-fastcgi
--enable-pdo=shared --with-pdo-odbc=shared,unixODBC,/usr
--with-pdo-mysql=shared,/usr --with-pdo-pgsql=shared,/usr
--with-pdo-sqlite=shared,/usr
configure: creating cache ../config.cache
checking for egrep... grep -E
checking for a sed that does not truncate output... /bin/sed
checking build system type... i686-redhat-linux-gnu
checking host system type... i686-redhat-linux-gnu
checking target system type... i386-redhat-linux-gnu
checking for i686-redhat-linux-gnu-gcc... no
checking for gcc... gcc
checking for C compiler default output file name... configure: error: C
compiler cannot create executables
See `config.log' for more details.
error: Bad exit status from /var/tmp/rpm-tmp.21471 (%build)

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



Expected results:
rpmbuild to build php rpms, and other php related rpm modules.

Additional info:
 Since
reporting the problem I have discovered the nature of the problem, which
lies with php.spec file.

The CFLAGS variable in php.spec file has the flag "-Wno-pointer-sign"
which does not exist in gcc < 4.x. Thus the configure error "configure:
error: C compiler cannot create executables" is bogus (not to mention
totally confusing). Simply removing the flag from php.spec resolves the
problem nicely.

By the way, on Fedora Core 4, php 5.1.2 builds without problems, since
gcc is by default version 4.

So my guess is that no one thought that someone would want to build/use
php > 5.0.4 on Fedora 1,2 or 3. It is written for Fedora 4. And I am
sure you realize that upgrading gcc on FC1,2 or 3 is impossible (unless
you upgrade everything).
Comment 1 Joe Orton 2006-06-01 09:57:43 EDT
Yes, this is not supported.

Note You need to log in before you can comment on or make changes to this bug.