Module::Build::Database::PostgreSQL
In Build.PL :
my $builder = Module::Build::Database->new( database_type => "PostgreSQL", database_options => { name => "my_database_name", schema => "my_schema_name", }, database_extensions => { postgis => { schema => "public", # postgis.sql and spatial_ref_sys.sql should be under postgis_base (below) }, }, );
perl Build.PL --postgis_base=/util/share/postgresql/contrib
Postgres driver for Module::Build::Database.
The environment variables used by psql will PGUSER, PGHOST, PGPORT will be used when connecting to a live database (for install and fakeinstall). PGDATABASE will be ignored: the name of the database should be given in Build.PL.
To install Module::Build::Database, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Module::Build::Database
CPAN shell
perl -MCPAN -e shell install Module::Build::Database
For more information on module installation, please visit the detailed CPAN module installation guide.