php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #77865 PECL compile fails for geoip
Submitted: 2019-04-08 17:41 UTC Modified: 2019-04-21 04:22 UTC
From: serviciosweb at informaticaferraro dot com Assigned: cmb (profile)
Status: No Feedback Package: *Compile Issues
PHP Version: 7.3.4 OS: CentOs 6.10
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: serviciosweb at informaticaferraro dot com
New email:
PHP Version: OS:

 

 [2019-04-08 17:41 UTC] serviciosweb at informaticaferraro dot com
Description:
------------
Installing with PECL Manager from WHM/cPanel:

WARNING: channel "pecl.php.net" has updated its protocols, use "pecl channel-update pecl.php.net" to update
downloading geoip-1.0.8.tgz ...
Starting to download geoip-1.0.8.tgz (10,061 bytes)
.....done: 10,061 bytes
5 source files, building
running: phpize
Configuring for:
PHP Api Version:         20180731
Zend Module Api No:      20180731
Zend Extension Api No:   320180731
configure.ac:149: warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body
../../lib/autoconf/lang.m4:193: AC_LANG_CONFTEST is expanded from...
../../lib/autoconf/general.m4:2661: _AC_LINK_IFELSE is expanded from...
../../lib/autoconf/general.m4:2678: AC_LINK_IFELSE is expanded from...
aclocal.m4:4346: _LT_SYS_MODULE_PATH_AIX is expanded from...
aclocal.m4:7485: _LT_LINKER_SHLIBS is expanded from...
aclocal.m4:8560: _LT_LANG_C_CONFIG is expanded from...
aclocal.m4:3462: _LT_SETUP is expanded from...
aclocal.m4:3391: LT_INIT is expanded from...
aclocal.m4:3426: AC_PROG_LIBTOOL is expanded from...
configure.ac:149: the top level
configure.ac:149: warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body
../../lib/autoconf/lang.m4:193: AC_LANG_CONFTEST is expanded from...
../../lib/autoconf/general.m4:2661: _AC_LINK_IFELSE is expanded from...
../../lib/autoconf/general.m4:2678: AC_LINK_IFELSE is expanded from...
aclocal.m4:7485: _LT_LINKER_SHLIBS is expanded from...
aclocal.m4:8560: _LT_LANG_C_CONFIG is expanded from...
aclocal.m4:3462: _LT_SETUP is expanded from...
aclocal.m4:3391: LT_INIT is expanded from...
aclocal.m4:3426: AC_PROG_LIBTOOL is expanded from...
configure.ac:149: the top level
configure.ac:149: warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body
../../lib/autoconf/lang.m4:193: AC_LANG_CONFTEST is expanded from...
../../lib/autoconf/general.m4:2661: _AC_LINK_IFELSE is expanded from...
../../lib/autoconf/general.m4:2678: AC_LINK_IFELSE is expanded from...
aclocal.m4:4346: _LT_SYS_MODULE_PATH_AIX is expanded from...
aclocal.m4:7485: _LT_LINKER_SHLIBS is expanded from...
aclocal.m4:8560: _LT_LANG_C_CONFIG is expanded from...
aclocal.m4:3462: _LT_SETUP is expanded from...
aclocal.m4:3391: LT_INIT is expanded from...
aclocal.m4:3426: AC_PROG_LIBTOOL is expanded from...
configure.ac:149: the top level
configure.ac:149: warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body
../../lib/autoconf/lang.m4:193: AC_LANG_CONFTEST is expanded from...
../../lib/autoconf/general.m4:2661: _AC_LINK_IFELSE is expanded from...
../../lib/autoconf/general.m4:2678: AC_LINK_IFELSE is expanded from...
aclocal.m4:7485: _LT_LINKER_SHLIBS is expanded from...
aclocal.m4:8560: _LT_LANG_C_CONFIG is expanded from...
aclocal.m4:3462: _LT_SETUP is expanded from...
aclocal.m4:3391: LT_INIT is expanded from...
aclocal.m4:3426: AC_PROG_LIBTOOL is expanded from...
configure.ac:149: the top level
building in /root/tmp/pear/pear-build-rootlpDBFl/geoip-1.0.8
running: /root/tmp/pear/geoip/configure --with-php-config=/opt/cpanel/ea-php73/root/usr/bin/php-config
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 cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking how to run the C preprocessor... cc -E
checking for icc... no
checking for suncc... no
checking whether cc understands -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-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
checking for PHP prefix... /opt/cpanel/ea-php73/root/usr
checking for PHP includes... -I/opt/cpanel/ea-php73/root/usr/include/php -I/opt/cpanel/ea-php73/root/usr/include/php/main -I/opt/cpanel/ea-php73/root/usr/include/php/TSRM -I/opt/cpanel/ea-php73/root/usr/include/php/Zend -I/opt/cpanel/ea-php73/root/usr/include/php/ext -I/opt/cpanel/ea-php73/root/usr/include/php/ext/date/lib
checking for PHP extension directory... /opt/cpanel/ea-php73/root/usr/lib64/php/modules
checking for PHP installed headers prefix... /opt/cpanel/ea-php73/root/usr/include/php
checking if debug is enabled... no
checking if zts is enabled... no
checking for re2c... no
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_set_charset in -lGeoIP... yes
checking for GeoIP_continent_by_id in -lGeoIP... yes
checking for LGPL compatible GeoIP libs... expr: non-numeric argument
cannot detect
checking library features to determine version (not acurate)... found 1004005
checking for a sed that does not truncate output... (cached) /bin/sed
checking for fgrep... /bin/grep -F
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking for /usr/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for ar... ar
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -B output from cc object... ok
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 for dlfcn.h... yes
checking for objdir... .libs
checking if cc supports -fno-rtti -fno-exceptions... no
checking for cc option to produce PIC... -fPIC -DPIC
checking if cc PIC flag -fPIC -DPIC works... yes
checking if cc static flag -static works... yes
checking if cc supports -c -o file.o... yes
checking if cc supports -c -o file.o... (cached) yes
checking whether the cc 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 ./config.status
config.status: creating config.h
config.status: executing libtool commands
running: make
/bin/sh /root/tmp/pear/pear-build-rootlpDBFl/geoip-1.0.8/libtool --mode=compile cc  -I. -I/root/tmp/pear/geoip -DPHP_ATOM_INC -I/root/tmp/pear/pear-build-rootlpDBFl/geoip-1.0.8/include -I/root/tmp/pear/pear-build-rootlpDBFl/geoip-1.0.8/main -I/root/tmp/pear/geoip -I/opt/cpanel/ea-php73/root/usr/include/php -I/opt/cpanel/ea-php73/root/usr/include/php/main -I/opt/cpanel/ea-php73/root/usr/include/php/TSRM -I/opt/cpanel/ea-php73/root/usr/include/php/Zend -I/opt/cpanel/ea-php73/root/usr/include/php/ext -I/opt/cpanel/ea-php73/root/usr/include/php/ext/date/lib  -DHAVE_CONFIG_H  -g -O2   -c /root/tmp/pear/geoip/geoip.c -o geoip.lo
libtool: compile:  cc -I. -I/root/tmp/pear/geoip -DPHP_ATOM_INC -I/root/tmp/pear/pear-build-rootlpDBFl/geoip-1.0.8/include -I/root/tmp/pear/pear-build-rootlpDBFl/geoip-1.0.8/main -I/root/tmp/pear/geoip -I/opt/cpanel/ea-php73/root/usr/include/php -I/opt/cpanel/ea-php73/root/usr/include/php/main -I/opt/cpanel/ea-php73/root/usr/include/php/TSRM -I/opt/cpanel/ea-php73/root/usr/include/php/Zend -I/opt/cpanel/ea-php73/root/usr/include/php/ext -I/opt/cpanel/ea-php73/root/usr/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /root/tmp/pear/geoip/geoip.c  -fPIC -DPIC -o .libs/geoip.o
/root/tmp/pear/geoip/geoip.c:220:44: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_db_filename':
/root/tmp/pear/geoip/geoip.c:220: error: 'RETURN_STRING' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.c:220: error: (Each undeclared identifier is reported only once
/root/tmp/pear/geoip/geoip.c:220: error: for each function it appears in.)
/root/tmp/pear/geoip/geoip.c:240:73: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_db_get_all_info':
/root/tmp/pear/geoip/geoip.c:240: error: 'add_assoc_string' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.c:242:60: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c:282:26: error: macro "RETVAL_STRING" passed 2 arguments, but takes just 1
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_database_info':
/root/tmp/pear/geoip/geoip.c:282: error: 'RETVAL_STRING' undeclared (first use in this function)
In file included from /root/tmp/pear/geoip/geoip.c:316:
/root/tmp/pear/geoip/geoip.def:20:1: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1
In file included from /root/tmp/pear/geoip/geoip.c:316:
/root/tmp/pear/geoip/geoip.def: In function 'zif_geoip_country_code_by_name':
/root/tmp/pear/geoip/geoip.def:20: error: 'RETURN_STRING' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.def:21:1: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1
/root/tmp/pear/geoip/geoip.def: In function 'zif_geoip_country_code3_by_name':
/root/tmp/pear/geoip/geoip.def:21: error: 'RETURN_STRING' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.def:22:1: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1
/root/tmp/pear/geoip/geoip.def: In function 'zif_geoip_country_name_by_name':
/root/tmp/pear/geoip/geoip.def:22: error: 'RETURN_STRING' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.c:346:54: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_continent_code_by_name':
/root/tmp/pear/geoip/geoip.c:346: error: 'RETURN_STRING' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.c:376:22: error: macro "RETVAL_STRING" passed 2 arguments, but takes just 1
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_org_by_name':
/root/tmp/pear/geoip/geoip.c:376: error: 'RETVAL_STRING' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.c:415:110: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_record_by_name':
/root/tmp/pear/geoip/geoip.c:415: error: 'add_assoc_string' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.c:417:104: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c:418:107: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c:419:104: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c:420:86: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c:421:80: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c:422:101: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c:495:72: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_region_by_name':
/root/tmp/pear/geoip/geoip.c:495: error: 'add_assoc_string' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.c:496:60: error: macro "add_assoc_string" passed 4 arguments, but takes just 3
/root/tmp/pear/geoip/geoip.c:528:22: error: macro "RETVAL_STRING" passed 2 arguments, but takes just 1
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_isp_by_name':
/root/tmp/pear/geoip/geoip.c:528: error: 'RETVAL_STRING' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.c:555:37: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_region_name_by_code':
/root/tmp/pear/geoip/geoip.c:555: error: 'RETURN_STRING' undeclared (first use in this function)
/root/tmp/pear/geoip/geoip.c:583:34: error: macro "RETURN_STRING" passed 2 arguments, but takes just 1
/root/tmp/pear/geoip/geoip.c: In function 'zif_geoip_time_zone_by_country_and_region':
/root/tmp/pear/geoip/geoip.c:583: error: 'RETURN_STRING' undeclared (first use in this function)
make: *** [geoip.lo] Error 1
ERROR: `make' failed


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2019-04-08 17:54 UTC] cmb@php.net
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2019-04-08 17:54 UTC] cmb@php.net
geoip-1.0.8 is very old; geoip-1.1.1 latest.  I suggest to
“use "pecl channel-update pecl.php.net" to update”.
 [2019-04-08 17:59 UTC] spam2 at rhsoft dot net
https://pecl.php.net/package/geoip
1.1.1 	beta 	2016-08-19

1.0.8 is from 2011-10-23
try to build taht against PHP 7.3.4 is insane

[builduser@buildserver:~]$ cat /rpmbuild/SPECS/php-pecl-geoip.spec 
# command 'rpmbuild -bb php-pecl-geoip.spec --with production' will tune for current hardware while default stays compatible

%global  php_extdir  %(%{_bindir}/php-config --extension-dir)
%global  pecl_name   geoip

%if %php_debug_build
 %global _include_minidebuginfo 1
 %global RH_GCC_DEBUG_OPTION -g3
 %global RH_CONFIGURE_DEBUG_OPTION enable-debug
%else
 %global _include_minidebuginfo 0
 %global RH_GCC_DEBUG_OPTION -g0
 %global RH_CONFIGURE_DEBUG_OPTION disable-debug
%endif

%if %{?_with_production:1}%{!?_with_production:0}
 %global rpmsuffix native
 %global build_native_release 1
 %global optflags $(sed "s/sandybridge/native/g" <<< "%{optflags}")
 %global optflags $(sed "s/-mavx/-m%{mavx_native}/g" <<< "%{optflags}")
%else
 %global rpmsuffix %{mtune2}
 %global build_native_release 0
 %global optflags $(sed "s/sandybridge/%{mtune2}/g" <<< "%{optflags}")
 %global optflags $(sed "s/-mavx/-m%{mavx2}/g" <<< "%{optflags}")
%endif

Summary:           php-pecl-%{pecl_name}
Name:              php-pecl-%{pecl_name}
Version:           1.1.1
Release:           1%php_api.%{build_native_release}%{?dist}.%{rpmsuffix}
Epoch:             16
License:           PHP
URL:               http://pecl.php.net/package/%{pecl_name}
Source:            %{pecl_name}-%{version}.tgz
BuildRequires:     autoconf, automake, libtool, php-devel, re2c, GeoIP-devel
Provides:          php-pecl(%{pecl_name}) = %{version}-%{release}

%description
php-pecl-%{pecl_name}

%prep
%setup -qc

%build
cd %{pecl_name}-%{version}
%{_bindir}/phpize
export CFLAGS="%{optflags} %{OS_flags} %{RH_GCC_DEBUG_OPTION} -D_GLIBCXX_ASSERTIONS -fPIC -fno-stack-protector -fstack-protector --param=ssp-buffer-size=8 -fuse-ld=gold -fuse-linker-plugin"
export CXXFLAGS="$CFLAGS"
export CPPFLAGS="$CFLAGS"
export CC="gcc $CFLAGS"
export LDFLAGS="-Wl,--as-needed -Wl,-z,now -Wl,-z,relro -Wl,-z,noexecstack -Wl,-z,nodump %{optflags} %{OS_flags}  %{RH_GCC_DEBUG_OPTION} -D_GLIBCXX_ASSERTIONS -fno-stack-protector -fstack-protector --param=ssp-buffer-size=8 -fuse-ld=gold -fuse-linker-plugin"
./configure --quiet --%{RH_CONFIGURE_DEBUG_OPTION} --enable-%{pecl_name}
make --quiet %{?_smp_mflags}

%install
cd %{pecl_name}-%{version}
INSTALL_ROOT=%{buildroot} make install
strip -s --strip-unneeded %{buildroot}%{php_extdir}/%{pecl_name}.so
rm -rf %{buildroot}%{_includedir}/php/

%files
%{php_extdir}/%{pecl_name}.so
 [2019-04-21 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Sun Apr 18 06:01:23 2021 UTC