3
.\" Author: The PostgreSQL Global Development Group
4
.\" Generator: DocBook XSL Stylesheets v1.75.1 <http://docbook.sf.net/>
6
.\" Manual: PostgreSQL 9.1beta1 Documentation
7
.\" Source: PostgreSQL 9.1beta1
10
.TH "PG_CONFIG" "1" "2011-04-27" "PostgreSQL 9.1beta1" "PostgreSQL 9.1beta1 Documentation"
11
.\" -----------------------------------------------------------------
12
.\" * set default formatting
13
.\" -----------------------------------------------------------------
14
.\" disable hyphenation
16
.\" disable justification (adjust text to left margin only)
18
.\" -----------------------------------------------------------------
19
.\" * MAIN CONTENT STARTS HERE *
20
.\" -----------------------------------------------------------------
22
pg_config \- retrieve information about the installed version of PostgreSQL
26
pg_config [\fIoption\fR...]
31
utility prints configuration parameters of the currently installed version of
32
PostgreSQL\&. It is intended, for example, to be used by software packages that want to interface to
34
to facilitate finding the required header files and libraries\&.
38
pg_config, supply one or more of the following options:
42
Print the location of user executables\&. Use this, for example, to find the
44
program\&. This is normally also the location where the
51
Print the location of documentation files\&.
56
Print the location of HTML documentation files\&.
61
Print the location of C header files of the client interfaces\&.
64
\fB\-\-pkgincludedir\fR
66
Print the location of other C header files\&.
69
\fB\-\-includedir\-server\fR
71
Print the location of C header files for server programming\&.
76
Print the location of object code libraries\&.
81
Print the location of dynamically loadable modules, or where the server would search for them\&. (Other architecture\-dependent data files might also be installed in this directory\&.)
86
Print the location of locale support files\&. (This will be an empty string if locale support was not configured when
93
Print the location of manual pages\&.
98
Print the location of architecture\-independent support files\&.
103
Print the location of system\-wide configuration files\&.
108
Print the location of extension makefiles\&.
113
Print the options that were given to the
117
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\&.) See also the examples below\&.
122
Print the value of the
124
variable that was used for building
125
PostgreSQL\&. This shows the C compiler used\&.
130
Print the value of the
132
variable that was used for building
133
PostgreSQL\&. This shows C compiler switches needed at preprocessing time (typically,
140
Print the value of the
142
variable that was used for building
143
PostgreSQL\&. This shows C compiler switches\&.
148
Print the value of the
150
variable that was used for building
151
PostgreSQL\&. This shows extra C compiler switches used for building shared libraries\&.
156
Print the value of the
158
variable that was used for building
159
PostgreSQL\&. This shows linker switches\&.
164
Print the value of the
166
variable that was used for building
167
PostgreSQL\&. This shows linker switches used for building executables only\&.
172
Print the value of the
174
variable that was used for building
175
PostgreSQL\&. This shows linker switches used for building shared libraries only\&.
180
Print the value of the
182
variable that was used for building
183
PostgreSQL\&. This normally contains
185
switches for external libraries linked into
194
If more than one option is given, the information is printed in that order, one item per line\&. If no options are given, all available information is printed, with labels\&.
198
\fB\-\-includedir\-server\fR
201
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 option
202
\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\&.
206
\fB\-\-pkgincludedir\fR,
210
\fB\-\-sysconfdir\fR,
216
\fB\-\-ldflags_sl\fR, and
234
came to be, a method for finding the equivalent configuration information did not exist\&.
237
To reproduce the build configuration of the current PostgreSQL installation, run the following command:
243
eval \&./configure `pg_config \-\-configure`
250
pg_config \-\-configure
251
contains shell quotation marks so arguments with spaces are represented correctly\&. Therefore, using
253
is required for proper results\&.