DBD::Pg is a Perl module that works with the DBI module to provide access to PostgreSQL databases.
Before installing, please use the "cpansign -v" program to cryptographically verify that your copy of DBD::Pg is complete and valid. The program "cpansign" is part of Module::Signature, available from CPAN.
By default Makefile.PL uses App::Info to find the location of the PostgreSQL library and include directories. However, if you want to control it yourself, define the environment variables POSTGRES_INCLUDE and POSTGRES_LIB, or define just POSTGRES_HOME. Note that if you have compiled PostgreSQL with SSL support, you must define the POSTGRES_LIB environment variable and add "-lssl" to it, like this:
export POSTGRES_LIB="/usr/local/pgsql/lib -lssl"
Now, take the usual steps to install DBD::Pg: - perl Makefile.PL
- make test
- make install
The tests are designed to connect to a live database. The following environment variables must be set for the tests to run: DBI_DSN=dbi:Pg:dbname= DBI_USER= DBI_PASS=If you are running on a non-standard port, you must add it to the DBI_DSN variable like this:
Put double quotes around the dbname if it has a semicolon or a space inside of it:
The tests assume that a schema named "public" is available for 7.3 and greater servers. To override this, set the environment variable DBD_SCHEMA to a valid schema before testing.
You can increase the verbosity of the tests by setting the environment variable TEST_VERBOSE. You can also enable tracing within the tests themselves by setting DBD_TRACE to whatever trace level you want. Be aware that setting the trace level can result in extremely verbose output.
When reporting test failures, please use TEST_VERBOSE=1, do *not* set DBD_TRACE unless requested, and send only the relevant sections.