phpv8 / v8js

V8 Javascript Engine for PHP — This PHP extension embeds the Google V8 Javascript Engine
http://pecl.php.net/package/v8js
MIT License
1.83k stars 200 forks source link

Makefile:210: recipe for target 'v8js_class.lo' failed #388

Closed Rishats closed 5 years ago

Rishats commented 5 years ago

PHP 7.2

`vagrant@homestead:/tmp/v8js$ make /bin/bash /tmp/v8js/libtool --mode=compile g++ -Wno-narrowing -std=c++11 -I. -I/ tmp/v8js -DPHP_ATOM_INC -I/tmp/v8js/include -I/tmp/v8js/main -I/tmp/v8js -I/usr/ include/php/20170718 -I/usr/include/php/20170718/main -I/usr/include/php/2017071 8/TSRM -I/usr/include/php/20170718/Zend -I/usr/include/php/20170718/ext -I/usr/i nclude/php/20170718/ext/date/lib -I/opt/v8/include -I/opt/v8 -DHAVE_CONFIG_H - g -O2 -c /tmp/v8js/v8js_class.cc -o v8js_class.lo libtool: compile: g++ -Wno-narrowing -std=c++11 -I. -I/tmp/v8js -DPHP_ATOM_INC -I/tmp/v8js/include -I/tmp/v8js/main -I/tmp/v8js -I/usr/include/php/20170718 -I/ usr/include/php/20170718/main -I/usr/include/php/20170718/TSRM -I/usr/include/ph p/20170718/Zend -I/usr/include/php/20170718/ext -I/usr/include/php/20170718/ext/ date/lib -I/opt/v8/include -I/opt/v8 -DHAVE_CONFIG_H -g -O2 -c /tmp/v8js/v8js_cl ass.cc -fPIC -DPIC -o .libs/v8js_class.o In file included from /usr/include/dirent.h:245:0, from /usr/include/php/20170718/Zend/zend_virtual_cwd.h:78, from /usr/include/php/20170718/main/php.h:471, from /tmp/v8js/php_v8js_macros.h:42, from /tmp/v8js/v8js_class.cc:22: /tmp/v8js/v8js_class.h: In function ‘v8js_ctx v8js_ctx_fetch_object(zend_object )’: /tmp/v8js/v8js_class.h:83:54: warning: offsetof within non-standard-layout type ‘v8js_ctx’ is undefined [-Winvalid-offsetof] return (struct v8js_ctx )((char )obj - XtOffsetOf(struct v8js_ctx, std)); /tmp/v8js/v8js_class.h:83:43: note: in expansion of macro ‘XtOffsetOf’ return (struct v8js_ctx )((char )obj - XtOffsetOf(struct v8js_ctx, std)); ^~~~ /tmp/v8js/v8js_class.cc: In function ‘void v8js_free_storage(zend_object*)’: /tmp/v8js/v8js_class.cc:105:61: warning: ignoring return value of ‘v8::Maybe l> v8::Object::Delete(v8::Local, v8::Local)’, declared w ith attribute warn_unused_result [-Wunused-result] V8JS_GLOBAL(c->isolate)->Delete(v8_context, object_name_js); ^ In file included from /tmp/v8js/php_v8js_macros.h:52:0, from /tmp/v8js/v8js_class.cc:22: /opt/v8/include/v8.h:3214:37: note: declared here V8_WARN_UNUSED_RESULT Maybe Delete(Local context, ^~ In file included from /usr/include/dirent.h:245:0, from /usr/include/php/20170718/Zend/zend_virtual_cwd.h:78, from /usr/include/php/20170718/main/php.h:471, from /tmp/v8js/php_v8js_macros.h:42, from /tmp/v8js/v8js_class.cc:22: /tmp/v8js/v8js_class.cc: In function ‘zend_object v8js_new(zend_class_entry)’: /tmp/v8js/v8js_class.cc:242:43: warning: offsetof within non-standard-layout typ e ‘v8js_ctx’ is undefined [-Winvalid-offsetof] v8js_object_handlers.offset = XtOffsetOf(struct v8js_ctx, std); /tmp/v8js/v8js_class.cc:242:32: note: in expansion of macro ‘XtOffsetOf’ v8js_object_handlers.offset = XtOffsetOf(struct v8js_ctx, std); ^~~~ /tmp/v8js/v8js_class.cc: In function ‘void zim_V8Js___construct(zend_execute_dat a, zval)’: /tmp/v8js/v8js_class.cc:462:71: warning: ignoring return value of ‘v8::Maybe l> v8::Object::Set(v8::Local, v8::Local, v8::Local alue>)’, declared with attribute warn_unused_result [-Wunused-result] context->Global()->Set(context, V8JS_SYM("global"), context->Global()); ^ In file included from /tmp/v8js/php_v8js_macros.h:52:0, from /tmp/v8js/v8js_class.cc:22: /opt/v8/include/v8.h:3107:37: note: declared here V8_WARN_UNUSED_RESULT Maybe Set(Local context, ^~~ /tmp/v8js/v8js_class.cc:508:88: warning: ignoring return value of ‘v8::Maybe l> v8::Object::DefineOwnProperty(v8::Local, v8::Local, v8 ::Local, v8::PropertyAttribute)’, declared with attribute warn_unused _result [-Wunused-result] AL(isolate)->DefineOwnProperty(context, object_name_js, php_obj, v8::ReadOnly); ^ In file included from /tmp/v8js/php_v8js_macros.h:52:0, from /tmp/v8js/v8js_class.cc:22: /opt/v8/include/v8.h:3135:37: note: declared here V8_WARN_UNUSED_RESULT Maybe DefineOwnProperty( ^~~~~ /tmp/v8js/v8js_class.cc:530:87: warning: ignoring return value of ‘v8::Maybe l> v8::Object::DefineOwnProperty(v8::Local, v8::Local, v8 ::Local, v8::PropertyAttribute)’, declared with attribute warn_unused _result [-Wunused-result] j->DefineOwnProperty(context, key, zval_to_v8js(value, isolate), v8::ReadOnly); ^ In file included from /tmp/v8js/php_v8js_macros.h:52:0, from /tmp/v8js/v8js_class.cc:22: /opt/v8/include/v8.h:3135:37: note: declared here V8_WARN_UNUSED_RESULT Maybe DefineOwnProperty( ^~~~~ /tmp/v8js/v8js_class.cc:597:94: warning: ignoring return value of ‘v8::Maybe l> v8::Object::CreateDataProperty(v8::Local, v8::Local, v 8::Local)’, declared with attribute warn_unused_result [-Wunused-resu lt] eDataProperty(context, method_name, ft->GetFunction(context).ToLocalChecked()); ^ In file included from /tmp/v8js/php_v8js_macros.h:52:0, from /tmp/v8js/v8js_class.cc:22: /opt/v8/include/v8.h:3122:37: note: declared here V8_WARN_UNUSED_RESULT Maybe CreateDataProperty(Local context, ^~~~~~ /tmp/v8js/v8js_class.cc: In function ‘void zim_V8Js_createSnapshot(zendexecute data, zval)’: /tmp/v8js/v8js_class.cc:1190:38: error: ‘Allocate’ is not a member of ‘v8::Isola te’ v8::Isolate isolate = v8::Isolate::Allocate(); ^~~~ /tmp/v8js/v8js_class.cc:1191:46: error: no matching function for call to ‘v8::Sn apshotCreator::SnapshotCreator(v8::Isolate&)’ v8::SnapshotCreator snapshot_creator(isolate); ^ In file included from /tmp/v8js/php_v8js_macros.h:52:0, from /tmp/v8js/v8js_class.cc:22: /opt/v8/include/v8.h:8217:3: note: candidate: v8::SnapshotCreator::SnapshotCreat or(const intptr_t, v8::StartupData) SnapshotCreator(const intptr_t external_references = nullptr, ^~~~~~~ /opt/v8/include/v8.h:8217:3: note: no known conversion for argument 1 from ‘v8 ::Isolate’ to ‘const intptr_t {aka const long int}’ /tmp/v8js/v8js_class.cc: In function ‘void v8js_write_property(zval, zval, zva l*, void)’: /tmp/v8js/v8js_class.cc:1333:87: warning: ignoring return value of ‘v8::Maybe ol> v8::Object::DefineOwnProperty(v8::Local, v8::Local, v 8::Local, v8::PropertyAttribute)’, declared with attribute warn_unuse d_result [-Wunused-result] DefineOwnProperty(v8_context, key, zval_to_v8js(value, isolate), v8::ReadOnly); ^ In file included from /tmp/v8js/php_v8js_macros.h:52:0, from /tmp/v8js/v8js_class.cc:22: /opt/v8/include/v8.h:3135:37: note: declared here V8_WARN_UNUSED_RESULT Maybe DefineOwnProperty( ^~~~~ /tmp/v8js/v8js_class.cc: In function ‘void v8js_unset_property(zval, zval, voi d)’: /tmp/v8js/v8js_class.cc:1357:31: warning: ignoring return value of ‘v8::Maybe ol> v8::Object::Delete(v8::Local, v8::Local)’, declared with attribute warn_unused_result [-Wunused-result] jsobj->Delete(v8_context, key); ^ In file included from /tmp/v8js/php_v8js_macros.h:52:0, from /tmp/v8js/v8js_class.cc:22: /opt/v8/include/v8.h:3214:37: note: declared here V8_WARN_UNUSED_RESULT Maybe Delete(Local context, ^~ Makefile:210: recipe for target 'v8js_class.lo' failed make: *** [v8js_class.lo] Error 1 `

hamzaali00001 commented 5 years ago

Please I am having same problem. Help.

Rishats commented 5 years ago

I just skip this optional steps:


git checkout 6.4.388.18
gclient sync
stesie commented 5 years ago

oh, the README.Linux.md still states V8 6.4 in an example, where the minimum supported version is like 6.9 something ...