ID: 41870
User updated by: roman dot vanicek at gmail dot com
Reported By: roman dot vanicek at gmail dot com
Status: Open
Bug Type: Compile Failure
Operating System: Ubuntu Linux 6.06
PHP Version: 5.2.3
New Comment:
Sorry for a small detail, the error appears during the compilation and
not the linking - i was a bit confused seeing libtool at the beginning
of the line. Apart from this, everything holds true.
Previous Comments:
------------------------------------------------------------------------
[2007-07-02 09:43:19] roman dot vanicek at gmail dot com
Description:
------------
I want to compile PHP with PDO_ODBC against iODBC.
Configure settings:
--with-pdo-odbc=generic,/usr,iodbc
Configure works fine, compilation too but during the linking phase, i
am getting this error:
/bin/sh: -c: line 0: syntax error near unexpected token `('
The problem is in the Makfile generated by configure. The parantheses
probably need to be quoted (or not used at all).
If I change these parameters (3 times in the Makefile)
-DPDO_ODBC_TYPE=\"generic (iodbc)\"
manually to
-DPDO_ODBC_TYPE=\"generic-iodbc\"
then it works like a charm :-)
Probably it would be best to fix the code that generates the Makefile
without parantheses ("generic","generic-iodbc" works, on the other hand
"generic - iodbc","generic iodbc" does not work).
Reproduce code:
---------------
./configure --with-pdo-odbc=generic,/usr,iodbc
make
Expected result:
----------------
Build complete.
Actual result:
--------------
/bin/sh /root/build/php/php-5.2.3/libtool --silent --preserve-dup-deps
--mode=compile gcc -I/root/build/php/php-5.2.3/ext -I/usr/include
-DPDO_ODBC_TYPE=\"generic (iodbc)\" -Iext/pdo_odbc/
-I/root/build/php/php-5.2.3/ext/pdo_odbc/ -DPHP_ATOM_INC
-I/root/build/php/php-5.2.3/include -I/root/build/php/php-5.2.3/main
-I/root/build/php/php-5.2.3 -I/usr/include/libxml2
-I/root/build/php/php-5.2.3/ext/date/lib -I/usr/include/freetype2
-I/root/build/php/php-5.2.3/ext/mbstring/oniguruma
-I/root/build/php/php-5.2.3/ext/mbstring/libmbfl
-I/root/build/php/php-5.2.3/ext/mbstring/libmbfl/mbfl
-I/usr/local/lib/oracli/sdk/include -I/root/build/bin/freetds/include
-I/root/build/php/php-5.2.3/TSRM -I/root/build/php/php-5.2.3/Zend
-I/usr/include -g -O2 -c
/root/build/php/php-5.2.3/ext/pdo_odbc/pdo_odbc.c -o
ext/pdo_odbc/pdo_odbc.lo
/bin/sh: -c: line 0: syntax error near unexpected token `('
/bin/sh: -c: line 0: `/bin/sh /root/build/php/php-5.2.3/libtool
--silent --preserve-dup-deps --mode=compile gcc
-I/root/build/php/php-5.2.3/ext -I/usr/include
-DPDO_ODBC_TYPE=\"generic (iodbc)\" -Iext/pdo_odbc/
-I/root/build/php/php-5.2.3/ext/pdo_odbc/ -DPHP_ATOM_INC
-I/root/build/php/php-5.2.3/include -I/root/build/php/php-5.2.3/main
-I/root/build/php/php-5.2.3 -I/usr/include/libxml2
-I/root/build/php/php-5.2.3/ext/date/lib -I/usr/include/freetype2
-I/root/build/php/php-5.2.3/ext/mbstring/oniguruma
-I/root/build/php/php-5.2.3/ext/mbstring/libmbfl
-I/root/build/php/php-5.2.3/ext/mbstring/libmbfl/mbfl
-I/usr/local/lib/oracli/sdk/include -I/root/build/bin/freetds/include
-I/root/build/php/php-5.2.3/TSRM -I/root/build/php/php-5.2.3/Zend
-I/usr/include -g -O2 -c
/root/build/php/php-5.2.3/ext/pdo_odbc/pdo_odbc.c -o
ext/pdo_odbc/pdo_odbc.lo '
make: *** [ext/pdo_odbc/pdo_odbc.lo] Error 2
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=41870&edit=1