Team LiB
Previous Section Next Section

Linux Configuration Options

Here is the configuration line used in Chapter 3 to build PHP:

./configure --with-mysql/
--with-apxs2=/usr/local/apache2/bin/apxs

This line tells PHP to include support for MySQL and to build as a dynamic module. Many other extensions and other configurations are available to you, many of which you'll never use (I know I don't). Table A.2 lists some of the more popular extensions in case you want to fiddle with your installation. However, for a complete list of extensions, configuration options, and more, you can use the following command at your shell prompt when in the PHP source directory:

./configure --help
Table A.2: Some Available Extensions

Extension

Description

--disable-all

Disable all extensions enabled by default.

--disable-libxml

Disable new LIBXML support.

--with-openssl[=DIR]

Include OpenSSL support (requires OpenSSL >= 0.9.6).

--with-zlib[=DIR]

Include ZLIB support (requires zlib >= 1.0.9).

--enable-bcmath

Enable bc style precision math functions.

--with-curl[=DIR]

Include CURL support.

--enable-dbase

Enable the bundled dbase library.

--disable-dom

Disable new DOM support.

--enable-ftp

Enable FTP support.

--with-gd[=DIR]

Include GD support where DIR is GD install prefix.

--with-jpeg-dir[=DIR]

GD: Set the path to libjpeg install prefix.

--with-png-dir[=DIR]

GD: Set the path to libpng install prefix.

--with-zlib-dir[=DIR]

GD: Set the path to libz install prefix.

--with-xpm-dir[=DIR]

GD: Set the path to libXpm install prefix.

--with-ttf[=DIR]

GD: Include FreeType 1.x support.

--with-freetype-dir[=DIR]

GD: Set the path to FreeType 2 install prefix.

--with-informix[=DIR]

Include Informix support.

--with-ldap[=DIR]

Include LDAP support.

--enable-mbstring

Enable multibyte string support.

--with-mcrypt[=DIR]

Include mcrypt support.

--with-mhash[=DIR]

Include mhash support.

--with-mssql[=DIR]

Include MSSQL-DB support. DIR is the FreeTDS home directory.

--with-mysql[=DIR]

Include MySQL support. DIR is the MySQL base directory.

--with-oci8[=DIR]

Include Oracle-oci8 support. Default DIR is ORACLE_HOME.

--with-ibm-db2[=DIR]

Include IBM DB2 support. DIR is the DB2 base.

--with-custom-odbc[=DIR]

Include a user-defined ODBC support. DIR is ODBC base directory.

--with-iodbc[=DIR]

Include iODBC support. DIR is the iODBC base directory.

--disable-posix

Disable POSIX-like functions.

--disable-session

Disable session support.

--without-sqlite

Do not include SQLite support.

--with-sybase[=DIR]

Include Sybase-DB support. DIR is the Sybase home directory.

This will list all available configuration options.

Remember, because PHP is an Apache dynamic module, you don't have to recompile Apache when making changes to PHP!

For more information on Linux/Unix configuration options in PHP, please see the PHP manual's section on installation and configuration.


Team LiB
Previous Section Next Section