↑↓ 选择 ↵ 打开 ⌫ 改范围 完整检索页

pgsql.cc 提供对 postgresql.org 官网内容的中文翻译,由 Pigsty 团队维护。

不受支持的版本: 7.0 / 6.3
历史版本PostgreSQL 7.0 已于 2005 年 5 月结束社区维护,本页译文保留供仍在使用旧版本的读者参考。新系统请看当前版本手册首页。

第 23 章 配置选项

23.1. 配置参数 (configure)

configure可用的全部参数 可以通过键入以下命令获得:

$ ./configure --help
    

安装者可能对以下参数感兴趣:

Directories to install PostgreSQL in:
  --prefix=PREFIX         install architecture-independent files in PREFIX
                          [/usr/local/pgsql]
  --bindir=DIR            user executables in DIR [EPREFIX/bin]
  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
  --includedir=DIR        C header files in DIR [PREFIX/include]
  --mandir=DIR            man documentation in DIR [PREFIX/man]
Features and packages:
  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
--enable and --with options recognized:
  --with-template=template
                          use operating system template file
                              see template directory
  --with-includes=dirs    look for header files for tcl/tk, etc in DIRS
  --with-libraries=dirs   look for additional libraries in DIRS
  --with-libs=dirs        alternate spelling of --with-libraries
  --enable-locale         enable locale support
  --enable-recode         enable cyrillic recode support
  --enable-multibyte      enable multibyte character support
  --with-pgport=portnum   change default postmaster port
  --with-maxbackends=n    set default maximum number of server processes 
  --with-tcl              build Tcl interfaces and pgtclsh
  --with-tclconfig=tcldir
                          tclConfig.sh and tkConfig.sh are in DIR
  --with-perl             build Perl interface and plperl
  --with-odbc             build ODBC driver package
  --with-odbcinst=odbcdir
                          change default directory for odbcinst.ini
  --enable-cassert        enable assertion checks (for debugging)
  --enable-debug          build with debugging symbols (-g) 
  --with-CC=compiler
                          use specific C compiler
  --with-CXX=compiler
                          use specific C++ compiler
  --without-CXX           prevent building C++ code 
    

有些系统在构建Postgres的某个特定 特性时可能会遇到问题。例如,C++ 编译器损坏的系统可能需要 指定--without-CXX来指示构建过程跳过 libpq++的构建。

如果你想使用未安装在系统标准搜索路径中的头文件或库来构建 Postgres,可以使用 --with-includes和 --with-libraries选项。例如,可以用它们来 用一个实验版本的 Tcl 构建。如果需要为头文件或库指定多个 非标准目录,可以这样写:

--with-includes="/opt/tcl/include /opt/perl5/include"
    

提交更正

译文有误、术语不当或页面显示问题,请到译文仓库 pgsty/pgdoc 报告译文问题。 英文原文本身的问题,请在当前版本的对应页面向上游反馈;上游不再修订已结束维护的版本。