1// $Id: config.w32,v 12.1 2007/11/20 21:43:44 gmf Exp $
2//
3// Windows configuration file for Berkeley DB extension for PHP
4// NOTE: this does not build with mod_db4.  Instructions are for a Release build.
5// 1.  If the library name below (e.g. libdb46.lib) does not match the 
6//     current version, replace it with the correct name.
7// 2.  replace <path_to_lib> with the path to a built, release version of libdbXX.lib
8//     e.g. C:/Programs/db-4.6.21/build_windows/Release
9// 3.  replace <path_to_build_windows> with the path to a directory containing db.h,
10//     e.g. C:/Programs/db-4.6.21/build_windows
11// 4.  Instructions for building PHP from source must be used to build this module.  See
12//     http://us2.php.net/install.windows.building
13//
14//     When using buildconf.js to generating the configure.js script, be sure to add
15//     --add-modules-dir=<path-to-db-4.6.x>
16//     This module can then be enabled/built using the following options to configure.js:
17//     	    --enable-db4=yes (build into php.exe)  or 
18// 	    --enable-db4=shared (built as php_db4.dll extension module)
19//
20ARG_ENABLE("db4","Berkeley DB support","no,shared");
21if (PHP_DB4 != "no") {
22	EXTENSION("db4", "db4.cpp", null, "", "php_db4.dll");
23	CHECK_LIB("libdb46.lib", "db4", "<path_to_lib>;");
24	CHECK_HEADER_ADD_INCLUDE("db.h", "CFLAGS_DB4", "<path_to_build_windows>;../db4;");
25	ADD_FLAG("CFLAGS_DB4", "/EHsc");
26}
27