diff options
Diffstat (limited to 'infrastructure/m4/ax_path_bdb.m4')
-rw-r--r-- | infrastructure/m4/ax_path_bdb.m4 | 27 |
1 files changed, 16 insertions, 11 deletions
diff --git a/infrastructure/m4/ax_path_bdb.m4 b/infrastructure/m4/ax_path_bdb.m4 index 08d71053..1a771048 100644 --- a/infrastructure/m4/ax_path_bdb.m4 +++ b/infrastructure/m4/ax_path_bdb.m4 @@ -12,10 +12,10 @@ dnl sets BDB_LIBS, BDB_CPPFLAGS, and BDB_LDFLAGS to the necessary dnl values to add to LIBS, CPPFLAGS, and LDFLAGS, as well as setting dnl BDB_VERSION to the version found. HAVE_DB_H is defined also. dnl -dnl The option --with-bdb-dir=DIR can be used to specify a specific -dnl Berkeley DB installation to use. +dnl The options --with-bdb-headers=DIR and --with-bdb-lib=DIR can be +dnl used to specify a specific Berkeley DB installation to use. dnl -dnl An example of it's use is: +dnl An example of its use is: dnl dnl AX_PATH_BDB([3],[ dnl LIBS="$BDB_LIBS $LIBS" @@ -57,6 +57,8 @@ dnl Changes: dnl dnl 1/5/05 applied patch from Rafa Rzepecki to eliminate compiler dnl warning about unused variable, argv +dnl 1/7/07 Add --with-bdb-headers and --with-bdb-lib options +dnl (James O'Gorman, james@netinertia.co.uk) dnl dnl @category InstalledPackages dnl @author Tim Toolan <toolan@ele.uri.edu> @@ -68,21 +70,24 @@ AC_DEFUN([AX_PATH_BDB], [ dnl # Used to indicate success or failure of this function. ax_path_bdb_ok=no - # Add --with-bdb-dir option to configure. - AC_ARG_WITH([bdb-dir], - [AC_HELP_STRING([--with-bdb-dir=DIR], - [Berkeley DB installation directory])]) + # Add --with-bdb-headers and --with-bdb-lib options + AC_ARG_WITH([bdb-headers], + [AC_HELP_STRING([--with-bdb-headers=DIR], + [Berkeley DB include files location])]) + AC_ARG_WITH([bdb-lib], + [AC_HELP_STRING([--with-bdb-lib=DIR], + [Berkeley DB library location])]) + # Check if --with-bdb-dir was specified. - if test "x$with_bdb_dir" = "x" ; then + if test "x$with_bdb_headers" = "x" -a "x$with_bdb_lib" = "x"; then # No option specified, so just search the system. AX_PATH_BDB_NO_OPTIONS([$1], [HIGHEST], [ ax_path_bdb_ok=yes ]) else - # Set --with-bdb-dir option. - ax_path_bdb_INC="$with_bdb_dir/include" - ax_path_bdb_LIB="$with_bdb_dir/lib" + ax_path_bdb_INC="$with_bdb_headers" + ax_path_bdb_LIB="$with_bdb_lib" dnl # Save previous environment, and modify with new stuff. ax_path_bdb_save_CPPFLAGS="$CPPFLAGS" |