php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #58472 1.0.5 does not compile
Submitted: 2008-12-21 09:56 UTC Modified: 2009-01-22 08:59 UTC
From: spam2 at rhsoft dot net Assigned: ohill (profile)
Status: Closed Package: geoip (PECL)
PHP Version: 5.2.8 OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: spam2 at rhsoft dot net
New email:
PHP Version: OS:

 

 [2008-12-21 09:56 UTC] spam2 at rhsoft dot net
Description:
------------
This moment i tried to rebuild our rpm at fedora9-x86_64 and php 5.2.8, but 1.0.5 will not compile, switching back to 1.0.3 and recompile works already

In file included from /home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.5/geoip-1.0.5/geoip.c:32:
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.5/geoip-1.0.5/php_geoip.h:62:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.5/geoip-1.0.5/geoip.c:55:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.5/geoip-1.0.5/geoip.c: In function 'zm_info_geoip':
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.5/geoip-1.0.5/geoip.c:177: error: expected expression before ')' token
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.5/geoip-1.0.5/geoip.c:468:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.5/geoip-1.0.5/geoip.c:479:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.5/geoip-1.0.5/geoip.c:586:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.5/geoip-1.0.5/geoip.c:616:22: error: operator '>=' has no left operand
make: *** [geoip.lo] Error 1
Fehler: Fehler-Status beim Beenden von /var/tmp/rpm-tmp.34961 (%build)


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-12-21 12:09 UTC] ohill@php.net
Can you paste the content of config.h file? It should have been generated after the phpize && ./configure part.
 [2009-01-07 09:20 UTC] rrichards@php.net
I hit the same problem and find it is caused by having more 
than 1 version on libGeoIP installed.

During configure when the following is called:
find /usr/lib/ -name libGeoIP.\*.\*.\*.\* | cut -d . -f 2-5
The output ends up being:
so.1.4.3
so.1.4.5
When setting LIBGEOIP_VERSION, argument $4 ends up being:
3
so
Note that it includes the linefeed and the so from the next 
line. Not being an integer an error is issued and 
LIBGEOIP_VERSION ends up being empty, causing the failures 
during compile.
1.0.3 doesnt have this problem since LIBGEOIP_VERSION isnt 
used in the source code. Also an issue is that its picking 
up the wrong lib during configure for the define as 1.4.5 
(not 1.4.3 which just gets listed first in the output) is my 
current library in use and the one its linking to.
 [2009-01-07 10:03 UTC] spam2 at rhsoft dot net
I have only one version
The "/usr/lib/libGeoIP.a" is a symlink to get "webalizer-xtended" built with geoip-support on the x86_64-fedora

[root@buildserver:~]$ locate libGeoIP
/usr/lib/libGeoIP.a
/usr/lib64/libGeoIP.a
/usr/lib64/libGeoIP.so
/usr/lib64/libGeoIP.so.1
/usr/lib64/libGeoIP.so.1.4.5
/usr/lib64/libGeoIPUpdate.a
/usr/lib64/libGeoIPUpdate.so
/usr/lib64/libGeoIPUpdate.so.0
/usr/lib64/libGeoIPUpdate.so.0.0.0

[root@buildserver:~]$ stat /usr/lib/libGeoIP.a
  File: ?/usr/lib/libGeoIP.a? -> ?/usr/lib64/libGeoIP.a?
  Size: 21              Blocks: 0          IO Block: 4096   symbolische Verkn?pfung
Device: 811h/2065d      Inode: 386581      Links: 1
Access: (0777/lrwxrwxrwx)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2008-11-01 22:27:54.000000000 +0100
Modify: 2008-11-01 22:27:54.000000000 +0100
Change: 2008-11-01 22:27:54.000000000 +0100
 [2009-01-08 14:38 UTC] ohill@php.net
The .a file is not used. It should be using the shared 
object. Can you post the ./configure output? Is it finding 
the lib at all and generating a config.h?
 [2009-01-09 14:25 UTC] ohill@php.net
This bug has been fixed in CVS.

In case this was a documentation problem, the fix will show up at the
end of next Sunday (CET) on pecl.php.net.

In case this was a pecl.php.net website problem, the change will show
up on the website in short time.
 
Thank you for the report, and for helping us make PECL better.


 [2009-01-22 06:30 UTC] spam2 at rhsoft dot net
1.0.6 has the same problem and the changelog says "Fixing compile bug when multiple GeoIP libs are installed, bug #15372."

There are no multiple-libs, this is not the problem
> The .a file is not used
Not for the pecl-extension but for webalizer-extended which links static

__________
 gcc -I. -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6 -DPHP_ATOM_INC -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/include -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/main -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/php -DHAVE_CONFIG_H -O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -pipe -fno-strict-aliasing -Wno-pointer-sign -D_FORTIFY_SOURCE=2 -c /home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c  -fPIC -DPIC -o .libs/geoip.o
In file included from /home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:32:
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/php_geoip.h:62:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:55:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c: In function 'zm_info_geoip':
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:177: error: expected expression before ')' token
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:468:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:479:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:586:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:616:22: error: operator '>=' has no left operand
make: *** [geoip.lo] Error 1
Fehler: Fehler-Status beim Beenden von /var/tmp/rpm-tmp.MQO8zw (%build)
Fehler beim Bauen des RPM:
    Fehler-Status beim Beenden von /var/tmp/rpm-tmp.MQO8zw (%build)

_________________
[builduser@fedora-x64:~/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6]$ cat config.h           
/* config.h.  Generated from config.h.in by configure.  */                                       
/* config.h.in.  Generated from configure.in by autoheader.  */                                  

/* Whether to build geoip as dynamic module */
#define COMPILE_DL_GEOIP 1                    

/* */
#define HAVE_CONTINENT_BY_ID 1

/* */
#define HAVE_CUSTOM_DIRECTORY 1

/* Define to 1 if you have the <dlfcn.h> header file. */
#define HAVE_DLFCN_H 1                                  

/* */
#define HAVE_GEOIPLIB 1

/* Define to 1 if you have the <inttypes.h> header file. */
#define HAVE_INTTYPES_H 1                                  

/* Define to 1 if you have the <memory.h> header file. */
#define HAVE_MEMORY_H 1                                  

/* Define to 1 if you have the <stdint.h> header file. */
#define HAVE_STDINT_H 1                                  

/* Define to 1 if you have the <stdlib.h> header file. */
#define HAVE_STDLIB_H 1                                  

/* Define to 1 if you have the <strings.h> header file. */
#define HAVE_STRINGS_H 1                                  

/* Define to 1 if you have the <string.h> header file. */
#define HAVE_STRING_H 1                                  

/* Define to 1 if you have the <sys/stat.h> header file. */
#define HAVE_SYS_STAT_H 1                                  

/* Define to 1 if you have the <sys/types.h> header file. */
#define HAVE_SYS_TYPES_H 1                                  

/* Define to 1 if you have the <unistd.h> header file. */
#define HAVE_UNISTD_H 1

/* */
#define LIBGEOIP_VERSION

/* Define to 1 if your C compiler doesn't accept -c and -o together. */
/* #undef NO_MINUS_C_MINUS_O */

/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT ""

/* Define to the full name of this package. */
#define PACKAGE_NAME ""

/* Define to the full name and version of this package. */
#define PACKAGE_STRING ""

/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME ""

/* Define to the version of this package. */
#define PACKAGE_VERSION ""

/* Define to 1 if you have the ANSI C header files. */
#define STDC_HEADERS 1
 [2009-01-22 06:51 UTC] ohill@php.net
PLEASE attach the output of the configure step. You are not 
helping me helping you. I cannot reproduce and you are the 
only one with this bug.
 [2009-01-22 06:56 UTC] spam2 at rhsoft dot net
[harry@srv-rhsoft:~]$ ssh builduser@fedora-x64
Last login: Thu Jan 22 12:53:41 2009 from nat.vmware.local
cd [builduser@fedora-x64:~]$ cd SPECS/                    
[builduser@fedora-x64:~/SPECS]$ rpmbuild -bb php-pecl-geoip.spec 
Ausf?hrung(%prep): /bin/sh -e /var/tmp/rpm-tmp.HZ3O5T            
+ umask 022                                                      
+ cd /home/builduser/rpmbuild/BUILD                              
+ LANG=C                                                         
+ export LANG                                                    
+ unset DISPLAY                                                  
+ cd /home/builduser/rpmbuild/BUILD                              
+ rm -rf php-pecl-geoip-1.0.6                                    
+ /bin/mkdir -p php-pecl-geoip-1.0.6                             
+ cd php-pecl-geoip-1.0.6                                        
+ /bin/tar -xf -                                                 
+ /usr/bin/gzip -dc /home/builduser/rpmbuild/SOURCES/geoip-1.0.6.tgz
+ STATUS=0                                                          
+ '[' 0 -ne 0 ']'                                                   
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .                                 
+ exit 0                                                            
Ausf?hrung(%build): /bin/sh -e /var/tmp/rpm-tmp.9NsZ4l              
+ umask 022                                                         
+ cd /home/builduser/rpmbuild/BUILD                                 
+ cd php-pecl-geoip-1.0.6                                           
+ LANG=C                                                            
+ export LANG                                                       
+ unset DISPLAY                                                     
+ cd geoip-1.0.6                                                    
+ /usr/bin/phpize                                                   
Configuring for:                                                    
PHP Api Version:         20041225                                   
Zend Module Api No:      20060613                                   
Zend Extension Api No:   220060519                                  
+ export 'RPM_OPT_FLAGS=-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -pipe -fno-strict-aliasing -Wno-pointer-sign -D_FORTIFY_SOURCE=2'                                                   
+ RPM_OPT_FLAGS='-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -pipe -fno-strict-aliasing -Wno-pointer-sign -D_FORTIFY_SOURCE=2'                                                          
+ export 'CFLAGS=-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -pipe -fno-strict-aliasing -Wno-pointer-sign -D_FORTIFY_SOURCE=2'                                                          
+ CFLAGS='-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -pipe -fno-strict-aliasing -Wno-pointer-sign -D_FORTIFY_SOURCE=2'                                                                 
+ export 'CXXFLAGS=-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -D_FORTIFY_SOURCE=2'    
+ CXXFLAGS='-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -D_FORTIFY_SOURCE=2'           
+ CFLAGS='-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -pipe -fno-strict-aliasing -Wno-pointer-sign -D_FORTIFY_SOURCE=2'                                                                 
+ export CFLAGS                                                                                  
+ CXXFLAGS='-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -D_FORTIFY_SOURCE=2'           
+ export CXXFLAGS                                                                                
+ FFLAGS='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -I/usr/lib64/gfortran/modules'                                  
+ export FFLAGS                                                                                  
+ ./configure --build=x86_64-unknown-linux-gnu --host=x86_64-unknown-linux-gnu --target=x86_64-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/lib64 --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man --infodir=/usr/share/info                                                                             
checking for grep that handles long lines and -e... /bin/grep                                    
checking for egrep... /bin/grep -E                                                               
checking for a sed that does not truncate output... /bin/sed                                     
checking for x86_64-unknown-linux-gnu-gcc... no                                                  
checking for gcc... gcc                                                                          
checking for C compiler default output file name... a.out                                        
checking whether the C compiler works... yes                                                     
checking whether we are cross compiling... no                                                    
checking for suffix of executables...                                                            
checking for suffix of object files... o                                                         
checking whether we are using the GNU C compiler... yes                                          
checking whether gcc accepts -g... yes                                                           
checking for gcc option to accept ISO C89... none needed                                         
checking how to run the C preprocessor... gcc -E                                                 
checking for icc... no                                                                           
checking whether gcc and cc understand -c and -o together... yes                                 
checking for system library directory... lib                                                     
checking if compiler supports -R... no                                                           
checking if compiler supports -Wl,-rpath,... yes                                                 
checking build system type... x86_64-unknown-linux-gnu                                           
checking host system type... x86_64-unknown-linux-gnu                                            
checking target system type... x86_64-redhat-linux-gnu                                           
checking for PHP prefix... /usr                                                                  
checking for PHP includes... -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib                    
checking for PHP extension directory... /usr/lib64/php/modules                                   
checking for PHP installed headers prefix... /usr/include/php                                    
checking if debug is enabled... no                                                               
checking if zts is enabled... no                                                                 
checking for re2c... re2c                                                                        
checking for re2c version... invalid                                                             
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.    
checking for gawk... gawk                                                                        
checking for geoip support... yes, shared                                                        
checking for geoip files in default path... found in /usr                                        
checking for GeoIP_open in -lGeoIP... yes                                                        
checking for GeoIP_setup_custom_directory in -lGeoIP... yes                                      
checking for GeoIP_continent_by_id in -lGeoIP... yes                                             
checking for LGPL compatible GeoIP libs... expr: non-numeric argument                            
./configure: line 5424: test: : integer expression expected                                      
found                                                                                            
checking for ld used by gcc... /usr/bin/ld                                                       
checking if the linker (/usr/bin/ld) is GNU ld... yes                                            
checking for /usr/bin/ld option to reload object files... -r                                     
checking for BSD-compatible nm... /usr/bin/nm -B                                                 
checking whether ln -s works... yes                                                              
checking how to recognize dependent libraries... pass_all                                        
checking for ANSI C header files... yes                                                          
checking for sys/types.h... yes                                                                  
checking for sys/stat.h... yes                                                                   
checking for stdlib.h... yes                                                                     
checking for string.h... yes                                                                     
checking for memory.h... yes                                                                     
checking for strings.h... yes                                                                    
checking for inttypes.h... yes                                                                   
checking for stdint.h... yes                                                                     
checking for unistd.h... yes                                                                     
checking dlfcn.h usability... yes                                                                
checking dlfcn.h presence... yes                                                                 
checking for dlfcn.h... yes                                                                      
checking for x86_64-unknown-linux-gnu-g77... no                                                  
checking for x86_64-unknown-linux-gnu-xlf... no                                                  
checking for x86_64-unknown-linux-gnu-f77... no                                                  
checking for x86_64-unknown-linux-gnu-frt... no                                                  
checking for x86_64-unknown-linux-gnu-pgf77... no                                                
checking for x86_64-unknown-linux-gnu-cf77... no                                                 
checking for x86_64-unknown-linux-gnu-fort77... no                                               
checking for x86_64-unknown-linux-gnu-fl32... no                                                 
checking for x86_64-unknown-linux-gnu-af77... no                                                 
checking for x86_64-unknown-linux-gnu-xlf90... no                                                
checking for x86_64-unknown-linux-gnu-f90... no                                                  
checking for x86_64-unknown-linux-gnu-pgf90... no                                                
checking for x86_64-unknown-linux-gnu-pghpf... no                                                
checking for x86_64-unknown-linux-gnu-epcf90... no                                               
checking for x86_64-unknown-linux-gnu-gfortran... no                                             
checking for x86_64-unknown-linux-gnu-g95... no                                                  
checking for x86_64-unknown-linux-gnu-xlf95... no                                                
checking for x86_64-unknown-linux-gnu-f95... no                                                  
checking for x86_64-unknown-linux-gnu-fort... no                                                 
checking for x86_64-unknown-linux-gnu-ifort... no                                                
checking for x86_64-unknown-linux-gnu-ifc... no                                                  
checking for x86_64-unknown-linux-gnu-efc... no                                                  
checking for x86_64-unknown-linux-gnu-pgf95... no                                                
checking for x86_64-unknown-linux-gnu-lf95... no                                                 
checking for x86_64-unknown-linux-gnu-ftn... no                                                  
checking for g77... no                                                                           
checking for xlf... no                                                                           
checking for f77... no                                                                           
checking for frt... no                                                                           
checking for pgf77... no                                                                         
checking for cf77... no                                                                          
checking for fort77... no                                                                        
checking for fl32... no                                                                          
checking for af77... no                                                                          
checking for xlf90... no                                                                         
checking for f90... no                                                                           
checking for pgf90... no                                                                         
checking for pghpf... no                                                                         
checking for epcf90... no                                                                        
checking for gfortran... no                                                                      
checking for g95... no                                                                           
checking for xlf95... no                                                                         
checking for f95... no                                                                           
checking for fort... no                                                                          
checking for ifort... no                                                                         
checking for ifc... no                                                                           
checking for efc... no                                                                           
checking for pgf95... no                                                                         
checking for lf95... no                                                                          
checking for ftn... no                                                                           
checking whether we are using the GNU Fortran 77 compiler... no                                  
checking whether  accepts -g... no                                                               
checking the maximum length of command line arguments... 1966080                                 
checking command to parse /usr/bin/nm -B output from gcc object... ok                            
checking for objdir... .libs                                                                     
checking for x86_64-unknown-linux-gnu-ar... no                                                   
checking for ar... ar                                                                            
checking for x86_64-unknown-linux-gnu-ranlib... no                                               
checking for ranlib... ranlib                                                                    
checking for x86_64-unknown-linux-gnu-strip... no                                                
checking for strip... strip                                                                      
checking if gcc supports -fno-rtti -fno-exceptions... no                                         
checking for gcc option to produce PIC... -fPIC                                                  
checking if gcc PIC flag -fPIC works... yes                                                      
checking if gcc static flag -static works... yes                                                 
checking if gcc supports -c -o file.o... yes                                                     
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes     
checking whether -lc should be explicitly linked in... no                                        
checking dynamic linker characteristics... GNU/Linux ld.so                                       
checking how to hardcode library paths into programs... immediate                                
checking whether stripping libraries is possible... yes                                          
checking if libtool supports shared libraries... yes                                             
checking whether to build shared libraries... yes                                                
checking whether to build static libraries... no                                                 
configure: creating libtool                                                                      
appending configuration tag "CXX" to libtool                                                     
appending configuration tag "F77" to libtool                                                     
configure: creating ./config.status                                                              
config.status: creating config.h                                                                 
+ /usr/bin/make -j3                                                                              
/bin/sh /home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/libtool --mode=compile gcc  -I. -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6 -DPHP_ATOM_INC -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/include -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/main -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib  -I/usr/include/php -DHAVE_CONFIG_H  -O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -pipe -fno-strict-aliasing -Wno-pointer-sign -D_FORTIFY_SOURCE=2   -c /home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c -o geoip.lo                                                                                       
mkdir .libs                                                                                      
 gcc -I. -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6 -DPHP_ATOM_INC -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/include -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/main -I/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/php -DHAVE_CONFIG_H -O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -pipe -fno-strict-aliasing -Wno-pointer-sign -D_FORTIFY_SOURCE=2 -c /home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c  -fPIC -DPIC -o .libs/geoip.o
In file included from /home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:32:
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/php_geoip.h:62:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:55:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c: In function 'zm_info_geoip':
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:177: error: expected expression before ')' token
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:468:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:479:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:586:22: error: operator '>=' has no left operand
/home/builduser/rpmbuild/BUILD/php-pecl-geoip-1.0.6/geoip-1.0.6/geoip.c:616:22: error: operator '>=' has no left operand
make: *** [geoip.lo] Error 1
Fehler: Fehler-Status beim Beenden von /var/tmp/rpm-tmp.9NsZ4l (%build)


Fehler beim Bauen des RPM:
    Fehler-Status beim Beenden von /var/tmp/rpm-tmp.9NsZ4l (%build)

______________________

[builduser@fedora-x64:~/SPECS]$ cat php-pecl-geoip.spec   
%{!?__pecl:     %{expand: %%global __pecl     %{_bindir}/pecl}}
%{!?php_extdir: %{expand: %%global php_extdir %(php-config --extension-dir)}}

%define php_apiver %((echo %{default_apiver}; php -i 2>/dev/null | sed -n 's/^PHP API => //p') | tail -1)                                                                                         
%define pecl_name geoip                                                                          

Summary:       Map IP address to geographic places
Name:          php-pecl-geoip                     
Version:       1.0.6                              
Release:       6%{?dist}                          
License:       PHP                                
Group:         Development/Languages              
URL:           http://pecl.php.net/package/geoip  
Source:        http://pecl.php.net/get/geoip-%{version}.tgz
BuildRoot:     %{_tmppath}/%{name}-%{version}-%{release}-root
BuildRequires: php-devel >= 5.2.0, php-pear, GeoIP-devel     
Requires(post): %{__pecl}                                    
Requires(postun): %{__pecl}                                  
Provides:      php-pecl(%{pecl_name}) = %{version}           

%if %{?php_zend_api}0
Requires:       php(zend-abi) = %{php_zend_api}
Requires:       php(api) = %{php_core_api}     
Requires:       GeoIP                          
%else                                          
Requires:       php-api = %{php_apiver}        
%endif                                         

%description
This PHP extension allows you to find the location of an IP address - City,
State, Country, Longitude, Latitude, and other information as all, such as 
ISP and connection type. For more info, please visit Maxmind's website.    

%prep
%setup -q -c

%build
cd %{pecl_name}-%{version}
%{_bindir}/phpize         
export RPM_OPT_FLAGS="-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -pipe -fno-strict-aliasing -Wno-pointer-sign -D_FORTIFY_SOURCE=2"                                                     
export CFLAGS="$RPM_OPT_FLAGS"                                                                   
export CXXFLAGS="-O3 -march=native -mtune=native -mmmx -msse2 -fopenmp -D_FORTIFY_SOURCE=2"      
%configure                                                                                       
%{__make} %{?_smp_mflags}                                                                        


%install
pushd %{pecl_name}-%{version}
%{__rm} -rf %{buildroot}
%{__make} install INSTALL_ROOT=%{buildroot}

popd

%clean
%{__rm} -rf %{buildroot}

%files
%defattr(-, root, root, 0755)
%{php_extdir}/geoip.so


%changelog
* Thu Jan 22 2009 Reindl Harald <h.reindl@thelounge.net> 1.0.6-6.fc10.rh
- Update to 1.0.6

* Fri Dec 5 2008 Reindl Harald <h.reindl@thelounge.net> 1.0.3-4.fc10.rh
- Rebuild for PHP 5.2.7

* Wed Nov 26 2008 Reindl Harald <h.reindl@thelounge.net> 1.0.3-2.fc10.rh
- Rebuild for Fedora 10

* Sun Nov 02 2008 Reindl Harald <h.reindl@thelounge.net> 1.0.3-1.fc9.rh
- Initial build
 [2009-01-22 07:03 UTC] ohill@php.net
Ok... now we know that it's the configure step that is not working, and it's where it's checking for the lib version.

Can you give me the output of this command? 

find /usr/lib/ -name libGeoIP.\*.\*.\*.\* | cut -d . -f 2-5

I think RedHat is not symlinking the library correctly on x86_64 from /usr/lib to /usr/lib64
 [2009-01-22 08:30 UTC] spam2 at rhsoft dot net
> I think RedHat is not symlinking the library correctly on > x86_64 from /usr/lib to /usr/lib64

Why should they do this?
This would conflict if you install GeoIP.x86_64 and GeoIP.i386 at the same time, and yes redhat is a multilib system which is a very good thing if you have a 32-bit-only application which needs this lib.

What i really do not understand is why 1.0.3 compiles and since 1.0.5 this problem exists

"Fixing compile bug when multiple GeoIP libs are installed, bug #15372." is WRONG, this bug here had never to do anything with multiple GeoIP because the comment of multiple libs is wrong in this thread
 [2009-01-22 08:37 UTC] ohill@php.net
Your last comment is completely useless. I asked you to give me the output of some command that NEEDS TO WORK for compile.

The comment in the changelog is correct, and yes there was a bug when multiple libraries were installed.

1.0.3 had less features, and 1.0.5 has more features, features dependent on GeoIP lib installed.

Now... could you for the last time, give me the output of:

find /usr/lib/ -name libGeoIP.\*.\*.\*.\* | cut -d . -f 2-5

And while at it:

find /usr/lib64/ -name libGeoIP.\*.\*.\*.\* | cut -d . -f 2-5
 [2009-01-22 08:40 UTC] spam2 at rhsoft dot net
My comment is not useless
There are no symlinks and there should not be symlinks
You must use /usr/lib64 instead /usr/lib on x86_64
But why does ./configure not stop before make in this case?

[root@fedora-x64:~]$ find /usr/lib/ -name libGeoIP.\*.\*.\*.\* | cut -d . -f 2-5

[root@fedora-x64:~]$ find /usr/lib64/ -name libGeoIP.\*.\*.\*.\* | cut -d . -f 2-5
so.1.4.5
 [2009-01-22 08:59 UTC] ohill@php.net
This bug has been fixed in CVS.

In case this was a documentation problem, the fix will show up at the
end of next Sunday (CET) on pecl.php.net.

In case this was a pecl.php.net website problem, the change will show
up on the website in short time.
 
Thank you for the report, and for helping us make PECL better.

I would like if you could test a CVS checkout, as I won't make a release now with this fix.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Dec 27 05:01:27 2024 UTC