Closed smebberson closed 7 years ago
Hello, sorry didn't see your issue earlier.
I looked into the build script of V8.. The current build script not obvious uses these keys, and their combinations lead to strange result.
As I understand it, the mechanism of snapshots is always working and does not depend on these keys. If you explicitly specify the key snapshot=on
, the build script just not built the basic scripts of V8 in the final library, instead, they will make of those "external snapshots".
There may be another problem, the build script of third-party extensions may not handle this case. In such cases it is useless to rebuild the V8 and put snapshots in a different directory. As an example, the build script of php-v8 just to report that V8 is broken. ("external snapshots" not provided)
So I advise you to just specify a single key snapshot=off
.
And look at my alpine-v8-lib and alpine-php-dev for development.
@AlexMasterov, thanks for getting back to me, much appreciated.
I'm actually trying to build v8 for php-js (we're wanting to evaluate this against php-v8, and V8Js). If you see the installation instructions here http://www.php-js.com/documentation/installation you'll note the requirement to copy out/native/natives_blob.bin
and out/native/snapshot_blob.bin
.
I know this is different to all other V8 in PHP extensions...
@smebberson
I hope this gist will help you How to install PHP-JS on Alpine
Can I close this issue?
I also updated V8 to version 5.7+ on Alpine (using GN).
I'm wondering if you could provide some advice on how to use your script but maintain the files
out/native/natives_blob.bin
andout/native/snapshot_blob.bin
after v8 has finished building?I've tried a bunch of things around
-Dv8_use_snapshot
,-Dv8_use_external_startup_data
andsnapshot=on
but those files never exist after build.Any assistance you could offer would be greatly appreciated. Thanks!