Closed GaneshKandu closed 1 year ago
This is more question for the PHP maintainers as to how there --with-iodbc
configure option behaves which building PHP, as it seems to be linking libiodbc.so.2
into the PHP binary.
Why are you actually linking with iodbc
for the odbc
and unixODBC
for the pdo_odbc
, as both use different ODBC library names and so best to use one or the other ?
Disabling the odbc
and pdo_odbc
in php's php.ini file will not affect what is linked into the php, php-fpm applications when built ...
For this issue i compiled php without odbc
and pdo_odbc
and building odbc
separately with iODBC
cd /setups/php-7.3.33/ext/odbc
/usr/local/apps/php/bin/phpize
./configure --with-php-config=/usr/local/apps/php/bin/php-config --with-iodbc=shared,/usr/local/apps ODBC_TYPE=iODBC
for make
command i am getting this error, do you know where its wrong ?
/bin/sh /setups/php-7.3.33/ext/odbc/libtool --mode=compile cc -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -I. -I/setups/php-7.3.33/ext/odbc -DPHP_ATOM_INC -I/setups/php-7.3.33/ext/odbc/include -I/setups/php-7.3.33/ext/odbc/main -I/setups/php-7.3.33/ext/odbc -I/usr/local/apps/php/include/php -I/usr/local/apps/php/include/php/main -I/usr/local/apps/php/include/php/TSRM -I/usr/local/apps/php/include/php/Zend -I/usr/local/apps/php/include/php/ext -I/usr/local/apps/php/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /setups/php-7.3.33/ext/odbc/php_odbc.c -o php_odbc.lo
mkdir .libs
cc -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -I. -I/setups/php-7.3.33/ext/odbc -DPHP_ATOM_INC -I/setups/php-7.3.33/ext/odbc/include -I/setups/php-7.3.33/ext/odbc/main -I/setups/php-7.3.33/ext/odbc -I/usr/local/apps/php/include/php -I/usr/local/apps/php/include/php/main -I/usr/local/apps/php/include/php/TSRM -I/usr/local/apps/php/include/php/Zend -I/usr/local/apps/php/include/php/ext -I/usr/local/apps/php/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /setups/php-7.3.33/ext/odbc/php_odbc.c -fPIC -DPIC -o .libs/php_odbc.o
In file included from /setups/php-7.3.33/ext/odbc/php_odbc.c:35:0:
/setups/php-7.3.33/ext/odbc/php_odbc_includes.h:163:21: fatal error: WINDOWS.H: No such file or directory
#include <WINDOWS.H>
^
compilation terminated.
make: *** [php_odbc.lo] Error 1
[root@localhost odbc]# odbc/php_odbc_includes.h:163:21: fatal error: WINDOWS.H: No such file or directory
@GaneshKandu — I trust you closed this because you found the cause and thus a solution. Would you please share it, so others who hit the same issue in the future may be helped more quickly?
@TallTed I am just accepting that php compilation works in that way and will load libiodbc.so
I didn't found any solution for this issue.
compilation terminated.
make: *** [php_odbc.lo] Error 1
[root@localhost odbc]# odbc/php_odbc_includes.h:163:21: fatal error: WINDOWS.H: No such file or directory
Hi,
I am building php with
odbc
andpdo_odbc
configuration
build was successful and
odbc
andpdo_odbc
created successful with no issuebut
ldd php
,ldd php-fpm
and some other binaries show that it need libiodbc.so.2mt thought is only
odbc
andpdo_odbc
should load libiodbc.so.2 whyldd php
,ldd php-fpm
and some other binaries of php is loading libiodbc.so.2 even after disablingodbc
andpdo_odbc
in php's php.ini filewhat could be issue ? why this happening in php < 7.4 ?