V8 and V8JS are separate.
V8 is the JS engine and V8JS is the PHP PECL code that needs to be loaded by php before Matrix runs. V8JS needs V8 to be available to compile against.
If you’ve got it loading up in php correctly, this should work:
# php -r '(new V8Js)->executeString("print(\"Hello from V8\\n\")");'
Hello from V8
Once that works you’ll need to either restart php-fpm or reload your web server if you’re not using FPM.
What version of PHP are you running?
In PHP 5.6 we run V8 220.127.116.11 with V8JS 0.1.3 - we’re running a much newer V8 and V8JS in newer versions of PHP, but we haven’t made a release of Matrix that supports that yet.
Edit: p.s sorry, I’m not sure how to get V8JS running under Ubuntu, I know we had a lot of “fun” getting it working in EL.