php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #50689 PHP don't compile error php_odbc.c when pdo_informix
Submitted: 2010-01-07 21:15 UTC Modified: 2013-02-18 00:34 UTC
Votes:8
Avg. Score:4.2 ± 0.8
Reproduced:6 of 6 (100.0%)
Same Version:4 (66.7%)
Same OS:3 (50.0%)
From: fmostini at aerolineas dot com dot ar Assigned:
Status: No Feedback Package: PDO related
PHP Version: 5.2.12 OS: Linux SLES10 32bit
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2010-01-07 21:15 UTC] fmostini at aerolineas dot com dot ar
Description:
------------
Informix PDO 1.2.26 
Informix ClientSDK 3.50
SUSE Linux Enterprise Server 10SP2


./configure  --prefix=/usr --datadir=/usr/share/php5 --mandir=/usr/share/man --bindir=/usr/bin \
        --with-libdir=lib \
        --includedir=/usr/includei \
        --sysconfdir=/etc/php5/apache2 \
        --with-config-file-path=/etc/php5/apache2 \
        --with-config-file-scan-dir=/etc/php5/conf.d  \
        --enable-spl \
        --enable-calendar \
        --enable-filter \
        --enable-ftp    \
        --enable-gd-native-ttf \
        --enable-inline-optimization \
        --enable-safe-mode \
        --enable-session \
        --enable-sysvsem \
        --enable-sysvshm \
        --enable-shared \
        --enable-shmop \
        --disable-debug \
        --disable-rpath \
        --program-suffix=5 \
        --with-apxs2=/usr/sbin/apxs2 \
        --with-bz2  \
        --with-gd \
        --with-gettext   \
        --with-informix=/opt/informix \
        --with-pdo-informix=/opt/informix \
        --with-jpeg-dir=/usr \
        --with-mm \
        --with-mysql \
        --with-openssl \
        --with-pear \
        --with-pcre-regex \
        --with-pic \
        --with-ttf \
        --with-unixODBC=/usr  \
        --with-zlib \
        --enable-xml \
        --enable-simplexml \
        --enable-libxml \
        --enable-sigchild



lxalem01:/home/mostinif/php-5.2.12 # make
/bin/sh /home/mostinif/php-5.2.12/libtool --silent --preserve-dup-deps --mode=compile gcc -I/usr/include -Iext/odbc/ -I/home/mostinif/php-5.2.12/ext/odbc/ -DPHP_ATOM_INC -I/home/mostinif/php-5.2.12/include -I/home/mostinif/php-5.2.12/main -I/home/mostinif/php-5.2.12 -I/home/mostinif/php-5.2.12/ext/date/lib -I/usr/include/libxml2 -I/usr/include/freetype -I/usr/include/mysql -I/opt/informix/incl/cli -I/opt/informix/incl/esql -I/home/mostinif/php-5.2.12/TSRM -I/home/mostinif/php-5.2.12/Zend    -I/usr/include -g -O2  -prefer-pic -c /home/mostinif/php-5.2.12/ext/odbc/php_odbc.c -o ext/odbc/php_odbc.lo
In file included from /home/mostinif/php-5.2.12/ext/odbc/php_odbc_includes.h:119,
                 from /home/mostinif/php-5.2.12/ext/odbc/php_odbc.c:37:
/opt/informix/incl/cli/sqlext.h:2044: error: expected ':', ',', ';', '}' or '__attribute__' before '*' token
/home/mostinif/php-5.2.12/ext/odbc/php_odbc.c: In function 'zif_odbc_columns'


The problem don't happen in php 5.2.9


Patches

bug50689 (last revision 2010-11-24 16:05 UTC by kalle@php.net)

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-01-07 21:29 UTC] fmostini at aerolineas dot com dot ar
in $INFORMIXDIR/incl/cli/sqlext.h lines 2044 for some reason the GUID tag is undefined in previus includes
php-5.2.12/ext/odbc/php_odbc_includes.h:119

typedef struct tagODBC_VS_ARGS {
        const GUID      *pguidEvent;    /* the GUID for event */
        DWORD   dwFlags;                /* flags for the call */
        union {
                WCHAR   *wszArg;
                CHAR    *szArg;
        };
        union {
                WCHAR   *wszCorrelation;
                CHAR    *szCorrelation;
        };
        RETCODE RetCode;
} ODBC_VS_ARGS, *PODBC_VS_ARGS;
 [2010-01-08 01:56 UTC] fmostini at aerolineas dot com dot ar
PDO INFORMIX is 1.2.6 (not .26)
 [2010-11-24 17:05 UTC] kalle@php.net
The following patch has been added/updated:

Patch Name: bug50689
Revision:   1290614721
URL:        http://bugs.php.net/patch-display.php?bug=50689&patch=bug50689&revision=1290614721
 [2010-11-24 17:06 UTC] kalle@php.net
-Status: Open +Status: Feedback
 [2010-11-24 17:06 UTC] kalle@php.net
I attached a patch that defines the GUID struct if not already defined prior to the inclusion of sqlext.h, does that fix the problem for you?
 [2010-12-03 20:24 UTC] fmostini at aerolineas dot com dot ar
Hi

 After applying diff patch provided and recompiling again, appears errors when using GUID Structure, related to a types WORD and DWORD. I made a dirty fix, including 
#include <sqltypes.h>  at the beginning of the ext/odbc/php_odbc_includes.h
This allows php_odbc.c compiles successful, but should find the proper place to define or include these types (WORD/DWORD) in the file.

In file included from /home/mostinif/php-5.2.14/ext/odbc/php_odbc.c:37:
/home/mostinif/php-5.2.14/ext/odbc/php_odbc_includes.h:122: error: expected specifier-qualifier-list before âDWORDâ
/home/mostinif/php-5.2.14/ext/odbc/php_odbc.c: In function âzif_odbc_columnsâ:
/home/mostinif/php-5.2.14/ext/odbc/php_odbc.c:2964: warning: comparison between pointer and integer
make: *** [ext/odbc/php_odbc.lo] Error 1

Best regards,
Flavio
 [2013-02-18 00:34 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 "Open". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu May 02 04:01:30 2024 UTC