[unixODBC-support] Compile Error

Nick Gorham nick.gorham at easysoft.com
Tue Feb 6 09:33:59 GMT 2007


Drewfus wrote:

> Hi;
>
> When compiling PHP with unixODBC Support - I receive the following error:
>
> /bin/sh /export/home/corenet/reb/php-4.3.4/libtool --silent
> --preserve-dup-deps --mode=compile gcc
> -I/usr/local/easysoft/unixODBC/include -Iext/odbc/
> -I/export/home/corenet/reb/php-4.3.4/ext/odbc/ -DPHP_ATOM_INC
> -I/export/home/corenet/reb/php-4.3.4/include 
> -I/export/home/corenet/reb/php-
> 4.3.4/main 
> -I/export/home/corenet/reb/php-4.3.4-I/export/home/corenet/reb/php-
> 4.3.4/Zend -I/usr/local/include
> -I/export/home/corenet/reb/php-4.3.4/ext/xml/expat
> -D_POSIX_PTHREAD_SEMANTICS -I/export/home/corenet/reb/php-4.3.4/TSRM  -g
> -O2  -prefer-pic -c 
> /export/home/corenet/reb/php-4.3.4/ext/odbc/php_odbc.c
> -o ext/odbc/php_odbc.lo
> /bin/sh /export/home/corenet/reb/php-4.3.4/libtool --silent
> --preserve-dup-deps --mode=link gcc -DPHP_ATOM_INC
> -I/export/home/corenet/reb/php-4.3.4/include 
> -I/export/home/corenet/reb/php-
> 4.3.4/main 
> -I/export/home/corenet/reb/php-4.3.4-I/export/home/corenet/reb/php-
> 4.3.4/Zend -I/usr/local/include
> -I/export/home/corenet/reb/php-4.3.4/ext/xml/expat
> -D_POSIX_PTHREAD_SEMANTICS -I/export/home/corenet/reb/php-4.3.4/TSRM  -g
> -O2   -o ext/odbc/odbc.la -export-dynamic -avoid-version -prefer-pic 
> -module
> -rpath /export/home/corenet/reb/php-4.3.4/modules -L/usr/ucblib
> -L/usr/local/lib/gcc-lib/sparc-sun-solaris2.8/3.3.2 -L/usr/local/lib
> ext/odbc/php_odbc.lo -R/usr/local/easysoft/unixODBC/lib
> -L/usr/local/easysoft/unixODBC/lib -lodbc
> *ld: fatal: file /usr/local/easysoft/unixODBC/lib/libodbc.so: wrong ELF
> class: ELFCLASS64
> ld: fatal: File processing errors. No output written to
> ext/odbc/.libs/odbc.so
> make: *** [ext/odbc/odbc.la] Error 1*
>
> iSQL is working fine - only receiving this error when trying to add 
> unixODBC
> Support to PHP.  Any guidance?
>
> Thanks,
> -Andrew
>
I would guess you have build unixODBC 64bit, but only have a 32bit 
version of PHP. Look at your compiler settings and CFLAGS and rebuild 
unixODBC 32 bit.

-- 
Nick Gorham
Easysoft Limited
http://www.easysoft.com, http://www.unixODBC.org




More information about the unixODBC-support mailing list