Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't create extensions plv8 postgresql

After install postgres, can't create extension plv8.

I'm use: CREATE EXTENSION plv8;

I'm getting:

ERROR:  could not open extension control file "/usr/local/share/postgresql/extension/plv8.control": No such file or directory
********** Error **********

ERROR: could not open extension control file "/usr/local/share/postgresql/extension/plv8.control": No such file or directory
SQL state: 58P01

version postgres: 9.6.2 version pgAdmin4: 1.4

How to install plv8?


1 Answers

This should work on most platforms (https://github.com/plv8/plv8/issues/212#issuecomment-287589193):

$ easy_install pgxnclient
$ pgxnclient install plv8

It didn't work for me though. The only solution I came up with was building the library from source.

If you don't have wget installed, run:

$ brew install wget

Then run:

$ wget https://github.com/plv8/plv8/archive/v2.0.0.tar.gz
$ tar -xvzf v2.0.0.tar.gz
$ cd plv8-2.0.0
$ make static
$ make install

It worked for me.

like image 72
karytka Avatar answered Aug 08 '26 17:08

karytka