.\\" auto-generated by docbook2man-spec $Revision: 1.25 $ .TH "PG_CONFIG" "1" "2002-11-22" "Application" "PostgreSQL Client Applications" .SH NAME pg_config \- retrieve information about the installed version of PostgreSQL .SH SYNOPSIS .sp \fBpg_config\fR \fR{\fR \fB--bindir\fR\fR | \fR\fB--includedir\fR\fR | \fR\fB--includedir-server\fR\fR | \fR\fB--libdir\fR\fR | \fR\fB--pkglibdir\fR\fR | \fR\fB--configure\fR\fR | \fR\fB--version\fR\fR }\fR\fR...\fR .SH "DESCRIPTION" .PP The \fBpg_config\fR utility prints configuration parameters of the currently installed version of PostgreSQL. It is intended, for example, to be used by software packages that want to interface to PostgreSQL to facilitate finding the required header files and libraries. .SH "OPTIONS" .PP To use \fBpg_config\fR, supply one or more of the following options: .TP \fB--bindir\fR Print the location of user executables. Use this, for example, to find the \fBpsql\fR program. This is normally also the location where the \fIpg_config\fR program resides. .TP \fB--includedir\fR Print the location of C header files of the client interfaces. .TP \fB--includedir-server\fR Print the location of C header files for server programming. .TP \fB--libdir\fR Print the location of object code libraries. .TP \fB--pkglibdir\fR Print the location of dynamically loadable modules, or where the server would search for them. (Other architecture-dependent data files may also be installed in this directory.) .TP \fB--configure\fR Print the options that were given to the \fIconfigure\fR script when PostgreSQL was configured for building. This can be used to reproduce the identical configuration, or to find out with what options a binary package was built. (Note however that binary packages often contain vendor-specific custom patches.) .TP \fB--version\fR Print the version of PostgreSQL and exit. .PP If more than one option (except for \fB--version\fR) is given, the information is printed in that order, one item per line. .SH "NOTES" .PP The option \fB--includedir-server\fR is new in PostgreSQL 7.2. In prior releases, the server include files were installed in the same location as the client headers, which could be queried with the \fB--includedir\fR. To make your package handle both cases, try the newer option first and test the exit status to see whether it succeeded. .PP In releases prior to PostgreSQL 7.1, before the \fBpg_config\fR came to be, a method for finding the equivalent configuration information did not exist. .SH "HISTORY" .PP The \fBpg_config\fR utility first appeared in PostgreSQL 7.1. .SH "SEE ALSO" .PP \fIPostgreSQL Programmer's Guide\fR