#29488 [Com]: PHP does not compile with freetds 0.62.4

2004-08-10 Thread patrick dot schutte at gmx dot de
 ID:   29488
 Comment by:   patrick dot schutte at gmx dot de
 Reported By:  ssc at coolspot dot de
 Status:   Open
 Bug Type: Compile Failure
 Operating System: Linux 2.6.7 / Debian sarge
 PHP Version:  4.3.8
 New Comment:

Hi, downlaod the laest snap and copy the ext/mssql folder to your
php-4.3.8 folder. I just compiled php-4.3.9dev (latest snap -
200408100430 -) with freetds-0.62.4 it wokrs fine! No Errors. HTH


Previous Comments:


[2004-08-03 13:17:05] ssc at coolspot dot de

Ha,ha.
Is there somebody out there to fix the bug or
do i realy have to do a diff -wu myself ?
Ok, for your convinience :

>>>
[EMAIL PROTECTED]:~/php-shit$ diff -wu php-4.3.6/ext/mssql/php_mssql.h
php-4.3.8/ext/mssql/php_mssql.h
--- php-4.3.6/ext/mssql/php_mssql.h 2003-07-23 18:53:38.0
+0200
+++ php-4.3.8/ext/mssql/php_mssql.h 2004-04-21 01:37:26.0
+0200
@@ -17,7 +17,7 @@
  */


-/* $Id: php_mssql.h,v 1.23.4.9 2003/07/23 16:53:38 iliaa Exp $ */
+/* $Id: php_mssql.h,v 1.23.4.10 2004/04/20 23:37:26 fmk Exp $ */

 #ifndef PHP_MSSQL_H
 #define PHP_MSSQL_H
@@ -37,6 +37,9 @@
 #include "sqldb.h"

 #if HAVE_FREETDS
+#ifndef SHORT
+typedef short SHORT;
+#endif
 #define SQLTEXT SYBTEXT
 #define SQLCHAR SYBCHAR
 #define SQLVARCHAR SYBVARCHAR
<<<

#ifndef SHORT searches for pre-compiler defines not for
typedefs. But typedef is C not Pre-Processor define.
mh.
Ok, now I really know what PHP is all about.

Use PHP 5 ? An older release ?



[2004-08-03 11:42:53] patrick dot schutte at gmx dot de

it's not a freetds-Problem - the mssql-extentions in php-4.3.7, 4.3.8
causes the errors - try php-5.0.0 or 4.3.6



[2004-08-02 10:02:48] ssc at coolspot dot de

Description:

I installed freetds version 0.62.4 on some debian sarge system, using
./configure --prefix=/usr/freetds --enable-msdblib --with-tdsver=8.0
--enable-shared
echo "/usr/freetds/lib" >> /etc/ld.so.conf ; ldconfig
FreeTDS work ok.
I then tried to compile php with
... --with-mssql=/usr/freetds ...
and to link it against freetds resulting in :

In file included from /root/php-4.3.8/ext/mssql/php_mssql.c:33:
/root/php-4.3.8/ext/mssql/php_mssql.h:41: error: redefinition of
`SHORT'
/usr/freetds/include/sybdb.h:117: error: `SHORT' previously declared
here
make: *** [ext/mssql/php_mssql.lo] Fehler 1

I commented out the line 41 in ext/mssql/php_mssql.h,
which is only a typdef short SHORT;, and it then worked,
as expected.

Compiler Version used is :
Lese Spezifikationen von /usr/lib/gcc-lib/i486-linux/3.3.4/specs
Konfiguriert mit: ../src/configure -v
--enable-languages=c,c++,java,f77,pascal,objc,ada,treelang
--prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info
--with-gxx-include-dir=/usr/include/c++/3.3 --enable-shared
--with-system-zlib --enable-nls --without-included-gettext
--enable-__cxa_atexit --enable-clocale=gnu --enable-debug
--enable-java-gc=boehm --enable-java-awt=xlib --enable-objc-gc
i486-linux
Thread-Modell: posix
gcc-Version 3.3.4 (Debian 1:3.3.4-3)



Reproduce code:
---
Any

Expected result:

Should compile

Actual result:
--
Does not compile





-- 
Edit this bug report at http://bugs.php.net/?id=29488&edit=1


#29488 [Com]: PHP does not compile with freetds 0.62.4

2004-08-03 Thread patrick dot schutte at gmx dot de
 ID:   29488
 Comment by:   patrick dot schutte at gmx dot de
 Reported By:  ssc at coolspot dot de
 Status:   Open
 Bug Type: Compile Failure
 Operating System: Linux 2.6.7 / Debian sarge
 PHP Version:  4.3.8
 New Comment:

it's not a freetds-Problem - the mssql-extentions in php-4.3.7, 4.3.8
causes the errors - try php-5.0.0 or 4.3.6


Previous Comments:


[2004-08-02 10:02:48] ssc at coolspot dot de

Description:

I installed freetds version 0.62.4 on some debian sarge system, using
./configure --prefix=/usr/freetds --enable-msdblib --with-tdsver=8.0
--enable-shared
echo "/usr/freetds/lib" >> /etc/ld.so.conf ; ldconfig
FreeTDS work ok.
I then tried to compile php with
... --with-mssql=/usr/freetds ...
and to link it against freetds resulting in :

In file included from /root/php-4.3.8/ext/mssql/php_mssql.c:33:
/root/php-4.3.8/ext/mssql/php_mssql.h:41: error: redefinition of
`SHORT'
/usr/freetds/include/sybdb.h:117: error: `SHORT' previously declared
here
make: *** [ext/mssql/php_mssql.lo] Fehler 1

I commented out the line 41 in ext/mssql/php_mssql.h,
which is only a typdef short SHORT;, and it then worked,
as expected.

Compiler Version used is :
Lese Spezifikationen von /usr/lib/gcc-lib/i486-linux/3.3.4/specs
Konfiguriert mit: ../src/configure -v
--enable-languages=c,c++,java,f77,pascal,objc,ada,treelang
--prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info
--with-gxx-include-dir=/usr/include/c++/3.3 --enable-shared
--with-system-zlib --enable-nls --without-included-gettext
--enable-__cxa_atexit --enable-clocale=gnu --enable-debug
--enable-java-gc=boehm --enable-java-awt=xlib --enable-objc-gc
i486-linux
Thread-Modell: posix
gcc-Version 3.3.4 (Debian 1:3.3.4-3)



Reproduce code:
---
Any

Expected result:

Should compile

Actual result:
--
Does not compile





-- 
Edit this bug report at http://bugs.php.net/?id=29488&edit=1