Closed thbley closed 11 years ago
The extension was developed against master/PHP-5.5. But I can also make it 5.4 compatible if there is interest :)
I tried the master branch of git://github.com/php/php-src.git: /home/travis/builds/thomasbley/scalar_objects/php-src/ext/scalar_objects/scalar_objects.c: In function ‘zm_globals_ctor_scalar_objects’: 682/home/travis/builds/thomasbley/scalar_objects/php-src/ext/scalar_objects/scalar_objects.c:207:9: error: request for member ‘handlers’ in something not a structure or union 683make: *\ [ext/scalar_objects/scalar_objects.lo] Error 1 684./travis_ci.sh: 9: ./travis_ci.sh: sapi/cli/php: not found
I think 5.4 would be the best option until 5.5 is out of beta!
Added PHP 5.4 compat with https://github.com/nikic/scalar_objects/commit/295c84144c6922141671ed67a1cced0c7122a295. Though your error suggests there is something else wrong. Maybe I messed up the macro for NTS...
Added support for NTS in https://github.com/nikic/scalar_objects/commit/9a07933e5794219cbcd00d6e9ac18801685bbf43. Now it should build fine on both 5.4/5.5
Tried to setup travis CI but didn't manage to get a clean build :/
Travis CI has some environment problems, so we can't do: php -r "echo exec('php -v');"
Using absolute paths works, but it is not very nice:
phpize ./configure --enable-scalar-objects make
TEST_PHP_EXECUTABLE=/home/travis/.phpenv/versions/5.4.9/bin/php php run-tests.php -d extension=pwd
/modules/scalar_objects.so -q -v
[ -f tests/string.diff ] && cat tests/string.diff
On my local machine I have: PHP 5.4.6-1ubuntu1.1 (cli) (built: Nov 15 2012 01:18:34) (Ubuntu 12.10 standard binary)
running phpize, configure and make look good: php -d extension=modules/scalar_objects.so -m gives: PHP Warning: PHP Startup: Unable to load dynamic library 'modules/scalar_objects.so' - modules/scalar_objects.so: undefined symbol: zend_error_noreturn in Unknown on line 0
When I run a full build of php-src, it works!
I tried to build the extension and got:
/home/travis/builds/thomasbley/scalar_objects/php-5.4.11/ext/scalar_objects/scalar_objects.c: In function ‘get_zval_safe’: 691/home/travis/builds/thomasbley/scalar_objects/php-5.4.11/ext/scalar_objects/scalar_objects.c:41:47: error: invalid type argument of ‘->’ (have ‘int’) 692/home/travis/builds/thomasbley/scalar_objects/php-5.4.11/ext/scalar_objects/scalar_objects.c:43:46: error: invalid type argument of ‘->’ (have ‘int’) 693/home/travis/builds/thomasbley/scalar_objects/php-5.4.11/ext/scalar_objects/scalar_objects.c:45:17: error: invalid type argument of unary ‘*’ (have ‘int’)
Do I need 5.5 alpha/trunk?
Complete report: https://travis-ci.org/thomasbley/scalar_objects Build script: https://github.com/thomasbley/scalar_objects/blob/master/travis_ci.sh Thanks!
Regards, Thomas