thobbs / phpcassa

PHP client library for Apache Cassandra
thobbs.github.com/phpcassa
MIT License
248 stars 78 forks source link

error occured while building the extension #149

Closed ghost closed 10 years ago

ghost commented 10 years ago
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 848: X--mode=compile: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1015: *** Warning: inferring the mode of operation is deprecated.: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1016: *** Future versions of Libtool will require --mode=MODE be specified.: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: Xg++: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I.: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/src/phpcassa/ext/thrift_protocol: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-DPHP_ATOM_INC: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/src/phpcassa/ext/thrift_protocol/include: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/src/phpcassa/ext/thrift_protocol/main: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/src/phpcassa/ext/thrift_protocol: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/include/php: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/include/php/main: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/include/php/TSRM: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/include/php/Zend: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/include/php/ext: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-I/usr/include/php/ext/date/lib: No such file or directory
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-DHAVE_CONFIG_H: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-g: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-O0: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1159: X-c: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1212: Xphp_thrift_protocol.lo: command not found
/usr/src/phpcassa/ext/thrift_protocol/libtool: line 1217: libtool: compile: cannot determine name of library object from `': command not found
make: *** [php_thrift_protocol.lo] Error 1
thobbs commented 10 years ago

What OS (and version) are you using?

ghost commented 10 years ago

centos 6.4 64 bit

thobbs commented 10 years ago

Do you have the php-devel package installed? What version of PHP?

ghost commented 10 years ago

I didn't installed php-devel package, but built from its source. And I installed some extensions as this way.

php --version PHP 5.5.5 (cli) (built: Oct 30 2013 17:42:34) (DEBUG) Copyright (c) 1997-2013 The PHP Group Zend Engine v2.5.0, Copyright (c) 1998-2013 Zend Technologies

thobbs commented 10 years ago

I'll guess you're missing some build dependencies (or they're not set up in a way that configure can find them). Specifically, it's not finding g++ and isn't recognizing flags from that. I'm not an expert at autotools or compiling things for PHP, so I might not be able to help you debug this.

ghost commented 10 years ago

ok, thanks for your effort, I'll be trying to fix it. thanks.

ghost commented 10 years ago

I've fixed the issue with a very interesting trick. Since I'm working and building some stuffs on my VPS, I was thinking that I've broke something somewhere in the packages. So, after I decide to create another work area (which is/was a small VPS) to confirm the issue, finally I've detected that it is the same issue as well as on another box too. And after a few minutes research I've found this; http://www.wreckedgames.com/forum/index.php/topic,1135.msg7265.html#msg7265 And It has just solved the issue on the 2 VPS boxes. I hope, it can help to other users who face this issue;

    cd phpcassa/ext/thrift_protocol &&
    export echo=echo &&
    phpize &&
    ./configure &&
    make &&
    make install
thobbs commented 10 years ago

Wow, that's an interesting bug in libtool. The error output makes more sense now. Thanks for reporting your fix!