dblib_pdo installation error
Hello,
I'm trying to install dblib_pdo on my server but on the last step I always get an error.
PHP version: 5.4
Apache 2.4
CentOS 6.6 64-bit
Here are the steps I performed:
- First I installed FreeTDS using the following:
I then created a symlink using the following:
Then,
Then rebuilt Apache. ======== Second installing dblib_pdo:
Until here, everything looks fine and no errors. However, when I lastly run the following command, it outputs error:
====== The error:
====== I'd really appreciate it if anyone can tell how to solve this issue or review commands I used and see if there is anything wrong, or anything that should be added in order to install the dblib_pdo correctly. Any answer would be greatly appreciated. Thank you in advance :)
wget http://ibiblio.org/pub/Linux/ALPHA/freetds/stable/freetds-stable.tgz
tar zfvx freetds-stable.tgz
cd freetds-*; ./configure --prefix=/usr/local/freetds --with-tdsver=8.0 --enable-msdblib --with-gnu-ld; make ; make installI then created a symlink using the following:
ln -s /usr/local/freetds/lib/libsybdb.so.5 /usr/lib64/libsybdb.so.5Then,
touch /usr/local/freetds/lib/libtds.a
touch /usr/local/freetds/include/tds.hThen rebuilt Apache. ======== Second installing dblib_pdo:
wget http://pecl.php.net/get/PDO_DBLIB-1.0.tgz
tar -zxvf PDO_DBLIB-1.0.tgz
cd PDO_DBLIB-1.0
phpize
./configure --with-pdo-dblib=/usr/local/freetdsUntil here, everything looks fine and no errors. However, when I lastly run the following command, it outputs error:
make ; make install====== The error:
/root/PDO_DBLIB-1.0/pdo_dblib.c:37: error: expected "=", ",", ";", "asm" or "__a ttribute__" before "pdo_dblib_functions"
/root/PDO_DBLIB-1.0/pdo_dblib.c:62: error: "pdo_dblib_functions" undeclared here (not in a function)
/root/PDO_DBLIB-1.0/pdo_dblib.c: In function "zm_startup_pdo_dblib":
/root/PDO_DBLIB-1.0/pdo_dblib.c:196: warning: passing argument 1 of "dbmsghandle " from incompatible pointer type
/usr/local/freetds/include/sybdb.h:725: note: expected "MHANDLEFUNC" but argumen t is of type "int (*)(struct DBPROCESS *, DBINT, int, int, char *, char *, ch ar *, DBUSMALLINT)"
make: *** [pdo_dblib.lo] Error 1====== I'd really appreciate it if anyone can tell how to solve this issue or review commands I used and see if there is anything wrong, or anything that should be added in order to install the dblib_pdo correctly. Any answer would be greatly appreciated. Thank you in advance :)
-
You can close the thread, I solved the problem. Thank you :) 0 -
Hello, I am happy to see the issue is now resolved. Would you mind sharing the resolution? Thank you. 0 -
You can close the thread, I solved the problem. Thank you :)
Hello, some days I struggle with this problem, tell me how did you solve it ?0 -
Hello, some days I struggle with this problem, tell me how did you solve it ?
Hello :) Could you confirm if you are experiencing the exact same error message, or just general trouble installing the module? Thank you.0 -
Hello, I have the same problem on Centos 7, PHP v5.6 PDO_DBLIB-1.0/pdo_dblib.c:37:1: error: unknown type name 'function_entry' function_entry pdo_dblib_functions[] .... etc [COLOR=rgb(255,77,77)] Can you please help? 0 -
I've found the solution: I had to manually edit the pdo_dblib.c file and change function from: function_entry pdo_dblib_functions[] = { {NULL, NULL, NULL} }; to zend_function_entry pdo_dblib_functions[] = { {NULL, NULL, NULL} }; I don't know why this isn't fix by now. 0 -
Hello, I'm happy to see you were able to address the issue. Thank you for updating this thread with the solution. Note it looks like an older PECL module with no recent updates: PECL :: Package :: PDO_DBLIB Thank you. 0
Please sign in to leave a comment.
Comments
7 comments