[php-maint] php5 with db2 support

Bryan Irvine sparctacus at gmail.com
Fri Mar 21 21:39:38 UTC 2008


I'm trying to build php5 with support for IBM DB2, and not having much success.

I'm trying to add the following flags to configure but cannot see
where to do that.
--with-ibm-db2=/opt/IBM/db2/V9.5
--with-pdo-odbc=ibm-db2,/home/db2inst1/sqllib

but before I can do that I'm having problems just building a vanilla package.

apt-get source php5
dpkg-source -x php5_5.2.3-1ubuntu6.3.dsc
cd php5-5.2.3
dpkg-buildpackage -rfakeroot -us -uc

generates the following:
...lots of output
In file included from /usr/include/sql.h:19,

                 from /usr/include/sqlext.h:43,

                 from /usr/include/sqlcli.h:841,

                 from /usr/include/sqlcli1.h:45,

                 from /home/optic/php5-5.2.3/ext/pdo_odbc/php_pdo_odbc_int.h:32,

                 from /home/optic/php5-5.2.3/ext/pdo_odbc/pdo_odbc.c:31:

/usr/include/sqltypes.h:72: error: two or more data types in
declaration specifiers

/usr/include/sqltypes.h:92: error: two or more data types in
declaration specifiers

/usr/include/sqltypes.h:106: error: conflicting types for 'WCHAR'

/usr/include/sqlcli.h:821: error: previous declaration of 'WCHAR' was here

/usr/include/sqltypes.h:222: error: conflicting types for 'SQLHANDLE'

/usr/include/sqlcli.h:435: error: previous declaration of 'SQLHANDLE' was here

/usr/include/sqltypes.h:223: error: conflicting types for 'SQLHENV'

/usr/include/sqlcli.h:436: error: previous declaration of 'SQLHENV' was here

/usr/include/sqltypes.h:224: error: conflicting types for 'SQLHDBC'

/usr/include/sqlcli.h:437: error: previous declaration of 'SQLHDBC' was here

/usr/include/sqltypes.h:225: error: conflicting types for 'SQLHSTMT'

/usr/include/sqlcli.h:438: error: previous declaration of 'SQLHSTMT' was here

/usr/include/sqltypes.h:226: error: conflicting types for 'SQLHDESC'

/usr/include/sqlcli.h:449: error: previous declaration of 'SQLHDESC' was here

/usr/include/sqltypes.h:296: error: conflicting types for 'DATE_STRUCT'

/usr/include/sqlcli.h:479: error: previous declaration of 'DATE_STRUCT' was here

/usr/include/sqltypes.h:299: error: conflicting types for 'SQL_DATE_STRUCT'

/usr/include/sqlcli.h:481: error: previous declaration of
'SQL_DATE_STRUCT' was here

/usr/include/sqltypes.h:307: error: conflicting types for 'TIME_STRUCT'

/usr/include/sqlcli.h:488: error: previous declaration of 'TIME_STRUCT' was here

/usr/include/sqltypes.h:310: error: conflicting types for 'SQL_TIME_STRUCT'

/usr/include/sqlcli.h:490: error: previous declaration of
'SQL_TIME_STRUCT' was here

/usr/include/sqltypes.h:322: error: conflicting types for 'TIMESTAMP_STRUCT'

/usr/include/sqlcli.h:501: error: previous declaration of
'TIMESTAMP_STRUCT' was here

/usr/include/sqltypes.h:325: error: conflicting types for 'SQL_TIMESTAMP_STRUCT'

/usr/include/sqlcli.h:504: error: previous declaration of
'SQL_TIMESTAMP_STRUCT' was here

/usr/include/sqltypes.h:332: error: redeclaration of enumerator 'SQL_IS_YEAR'

/usr/include/sqlcli.h:508: error: previous definition of 'SQL_IS_YEAR' was here

/usr/include/sqltypes.h:333: error: redeclaration of enumerator 'SQL_IS_MONTH'

/usr/include/sqlcli.h:509: error: previous definition of 'SQL_IS_MONTH' was here

/usr/include/sqltypes.h:334: error: redeclaration of enumerator 'SQL_IS_DAY'

/usr/include/sqlcli.h:510: error: previous definition of 'SQL_IS_DAY' was here

/usr/include/sqltypes.h:335: error: redeclaration of enumerator 'SQL_IS_HOUR'

/usr/include/sqlcli.h:511: error: previous definition of 'SQL_IS_HOUR' was here

/usr/include/sqltypes.h:336: error: redeclaration of enumerator 'SQL_IS_MINUTE'

/usr/include/sqlcli.h:512: error: previous definition of
'SQL_IS_MINUTE' was here

/usr/include/sqltypes.h:337: error: redeclaration of enumerator 'SQL_IS_SECOND'

/usr/include/sqlcli.h:513: error: previous definition of
'SQL_IS_SECOND' was here

/usr/include/sqltypes.h:338: error: redeclaration of enumerator
'SQL_IS_YEAR_TO_MONTH'

/usr/include/sqlcli.h:514: error: previous definition of
'SQL_IS_YEAR_TO_MONTH' was here

/usr/include/sqltypes.h:339: error: redeclaration of enumerator
'SQL_IS_DAY_TO_HOUR'

/usr/include/sqlcli.h:515: error: previous definition of
'SQL_IS_DAY_TO_HOUR' was here

/usr/include/sqltypes.h:340: error: redeclaration of enumerator
'SQL_IS_DAY_TO_MINUTE'

/usr/include/sqlcli.h:516: error: previous definition of
'SQL_IS_DAY_TO_MINUTE' was here

/usr/include/sqltypes.h:341: error: redeclaration of enumerator
'SQL_IS_DAY_TO_SECOND'

/usr/include/sqlcli.h:517: error: previous definition of
'SQL_IS_DAY_TO_SECOND' was here

/usr/include/sqltypes.h:342: error: redeclaration of enumerator
'SQL_IS_HOUR_TO_MINUTE'

/usr/include/sqlcli.h:518: error: previous definition of
'SQL_IS_HOUR_TO_MINUTE' was here

/usr/include/sqltypes.h:343: error: redeclaration of enumerator
'SQL_IS_HOUR_TO_SECOND'

/usr/include/sqlcli.h:519: error: previous definition of
'SQL_IS_HOUR_TO_SECOND' was here

/usr/include/sqltypes.h:345: error: redeclaration of enumerator
'SQL_IS_MINUTE_TO_SECOND'

/usr/include/sqlcli.h:521: error: previous definition of
'SQL_IS_MINUTE_TO_SECOND' was here

/usr/include/sqltypes.h:345: error: conflicting types for 'SQLINTERVAL'

/usr/include/sqlcli.h:521: error: previous declaration of 'SQLINTERVAL' was here

/usr/include/sqltypes.h:351: error: redefinition of 'struct tagSQL_YEAR_MONTH'

/usr/include/sqltypes.h:357: error: redefinition of 'struct tagSQL_DAY_SECOND'

/usr/include/sqltypes.h:366: error: redefinition of 'struct
tagSQL_INTERVAL_STRUCT'

/usr/include/sqltypes.h:410: error: conflicting types for 'SQLBIGINT'

/usr/include/sqlcli.h:470: error: previous declaration of 'SQLBIGINT' was here

/usr/include/sqltypes.h:413: error: conflicting types for 'SQLUBIGINT'

/usr/include/sqlcli.h:471: error: previous declaration of 'SQLUBIGINT' was here

/usr/include/sqltypes.h:424: error: redefinition of 'struct
tagSQL_NUMERIC_STRUCT'

In file included from /usr/include/sqlext.h:43,

                 from /usr/include/sqlcli.h:841,

                 from /usr/include/sqlcli1.h:45,

                 from /home/optic/php5-5.2.3/ext/pdo_odbc/php_pdo_odbc_int.h:32,

                 from /home/optic/php5-5.2.3/ext/pdo_odbc/pdo_odbc.c:31:

/usr/include/sql.h:570: error: conflicting types for 'SQLAllocConnect'

/usr/include/sqlcli.h:588: error: previous declaration of
'SQLAllocConnect' was here

/usr/include/sql.h:572: error: conflicting types for 'SQLAllocEnv'

/usr/include/sqlcli.h:591: error: previous declaration of 'SQLAllocEnv' was here

/usr/include/sql.h:576: error: conflicting types for 'SQLAllocHandle'

/usr/include/sqlcli.h:598: error: previous declaration of
'SQLAllocHandle' was here

/usr/include/sql.h:580: error: conflicting types for 'SQLAllocStmt'

/usr/include/sqlcli.h:594: error: previous declaration of
'SQLAllocStmt' was here

/usr/include/sql.h:585: error: conflicting types for 'SQLBindCol'

/usr/include/sqlcli.h:605: error: previous declaration of 'SQLBindCol' was here

/usr/include/sql.h:595: error: conflicting types for 'SQLCancel'

/usr/include/sqlcli.h:607: error: previous declaration of 'SQLCancel' was here

/usr/include/sql.h:598: error: conflicting types for 'SQLCloseCursor'

/usr/include/sqlcli.h:674: error: previous declaration of
'SQLCloseCursor' was here

/usr/include/sql.h:603: error: conflicting types for 'SQLColAttribute'

/usr/include/sqlcli.h:625: error: previous declaration of
'SQLColAttribute' was here

/usr/include/sql.h:617: error: conflicting types for 'SQLConnect'

/usr/include/sqlcli.h:636: error: previous declaration of 'SQLConnect' was here

/usr/include/sql.h:621: error: conflicting types for 'SQLCopyDesc'

/usr/include/sqlcli.h:740: error: previous declaration of 'SQLCopyDesc' was here

/usr/include/sql.h:634: error: conflicting types for 'SQLDescribeCol'

/usr/include/sqlcli.h:646: error: previous declaration of
'SQLDescribeCol' was here

/usr/include/sql.h:636: error: conflicting types for 'SQLDisconnect'

/usr/include/sqlcli.h:648: error: previous declaration of
'SQLDisconnect' was here

/usr/include/sql.h:640: error: conflicting types for 'SQLEndTran'

/usr/include/sqlcli.h:717: error: previous declaration of 'SQLEndTran' was here

/usr/include/sql.h:647: error: conflicting types for 'SQLError'

/usr/include/sqlcli.h:657: error: previous declaration of 'SQLError' was here

/usr/include/sql.h:650: error: conflicting types for 'SQLExecDirect'

/usr/include/sqlcli.h:661: error: previous declaration of
'SQLExecDirect' was here

/usr/include/sql.h:652: error: conflicting types for 'SQLExecute'

/usr/include/sqlcli.h:663: error: previous declaration of 'SQLExecute' was here

/usr/include/sql.h:654: error: conflicting types for 'SQLFetch'

/usr/include/sqlcli.h:665: error: previous declaration of 'SQLFetch' was here

/usr/include/sql.h:661: error: conflicting types for 'SQLFreeConnect'

/usr/include/sqlcli.h:667: error: previous declaration of
'SQLFreeConnect' was here

/usr/include/sql.h:663: error: conflicting types for 'SQLFreeEnv'

/usr/include/sqlcli.h:669: error: previous declaration of 'SQLFreeEnv' was here

/usr/include/sql.h:666: error: conflicting types for 'SQLFreeHandle'

/usr/include/sqlcli.h:720: error: previous declaration of
'SQLFreeHandle' was here

/usr/include/sql.h:670: error: conflicting types for 'SQLFreeStmt'

/usr/include/sqlcli.h:672: error: previous declaration of 'SQLFreeStmt' was here

/usr/include/sql.h:683: error: conflicting types for 'SQLGetCursorName'

/usr/include/sqlcli.h:679: error: previous declaration of
'SQLGetCursorName' was here

/usr/include/sql.h:688: error: conflicting types for 'SQLGetData'

/usr/include/sqlcli.h:686: error: previous declaration of 'SQLGetData' was here

/usr/include/sql.h:694: error: conflicting types for 'SQLGetDescField'

/usr/include/sqlcli.h:763: error: previous declaration of
'SQLGetDescField' was here

/usr/include/sql.h:701: error: conflicting types for 'SQLGetDescRec'

/usr/include/sqlcli.h:775: error: previous declaration of
'SQLGetDescRec' was here

/usr/include/sql.h:706: error: conflicting types for 'SQLGetDiagField'

/usr/include/sqlcli.h:737: error: previous declaration of
'SQLGetDiagField' was here

/usr/include/sql.h:711: error: conflicting types for 'SQLGetDiagRec'

/usr/include/sqlcli.h:729: error: previous declaration of
'SQLGetDiagRec' was here

/usr/include/sql.h:738: error: conflicting types for 'SQLNumResultCols'

/usr/include/sqlcli.h:689: error: previous declaration of
'SQLNumResultCols' was here

/usr/include/sql.h:744: error: conflicting types for 'SQLPrepare'

/usr/include/sqlcli.h:693: error: previous declaration of 'SQLPrepare' was here

/usr/include/sql.h:750: error: conflicting types for 'SQLRowCount'

/usr/include/sqlcli.h:696: error: previous declaration of 'SQLRowCount' was here

/usr/include/sql.h:762: error: conflicting types for 'SQLSetCursorName'

/usr/include/sqlcli.h:700: error: previous declaration of
'SQLSetCursorName' was here

/usr/include/sql.h:767: error: conflicting types for 'SQLSetDescField'

/usr/include/sqlcli.h:781: error: previous declaration of
'SQLSetDescField' was here

/usr/include/sql.h:774: error: conflicting types for 'SQLSetDescRec'

/usr/include/sqlcli.h:792: error: previous declaration of
'SQLSetDescRec' was here

/usr/include/sql.h:785: error: conflicting types for 'SQLSetParam'

/usr/include/sqlcli.h:709: error: previous declaration of 'SQLSetParam' was here

/usr/include/sql.h:816: error: conflicting types for 'SQLTransact'

/usr/include/sqlcli.h:713: error: previous declaration of 'SQLTransact' was here

make[1]: *** [ext/pdo_odbc/pdo_odbc.lo] Error 1

make[1]: Leaving directory `/home/optic/php5-5.2.3/apache2-build'

make: *** [build-apache2-stamp] Error 2



More information about the pkg-php-maint mailing list