diff options
author | Michael Cahill <michael.cahill@wiredtiger.com> | 2014-05-27 14:04:14 +1000 |
---|---|---|
committer | Michael Cahill <michael.cahill@wiredtiger.com> | 2014-05-27 14:04:14 +1000 |
commit | a99d2d2101b842569a8e898b4cf7a60063a79e86 (patch) | |
tree | 4fd9f218aef320eef81b127ab70c9963f6c90ddc /build_posix | |
parent | aeb55a911aa6782e50755e2529a38ffd5335ed3a (diff) | |
download | mongo-a99d2d2101b842569a8e898b4cf7a60063a79e86.tar.gz |
Add configure support for enabling LevelDB, including the HyperLevelDB flavor.
Diffstat (limited to 'build_posix')
-rw-r--r-- | build_posix/aclocal/options.m4 | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/build_posix/aclocal/options.m4 b/build_posix/aclocal/options.m4 index 6dd7bbe2257..f07c18fc167 100644 --- a/build_posix/aclocal/options.m4 +++ b/build_posix/aclocal/options.m4 @@ -56,6 +56,32 @@ esac AC_MSG_RESULT($wt_cv_enable_java) AM_CONDITIONAL([JAVA], [test x$wt_cv_enable_java = xyes]) +AC_MSG_CHECKING(if --enable-leveldb option specified) +AC_ARG_ENABLE(leveldb, + [AS_HELP_STRING([--enable-leveldb], + [Build the LevelDB API.])], r=$enableval, r=no) +wt_cv_enable_hyperleveldb=no +case "$r" in +no) wt_cv_enable_leveldb=no;; +hyper) wt_cv_enable_leveldb=yes + wt_cv_enable_hyperleveldb=yes;; +*) wt_cv_enable_leveldb=yes;; +esac +AC_MSG_RESULT($wt_cv_enable_leveldb) +if test "$wt_cv_enable_hyperleveldb" = "yes"; then + AC_LANG_PUSH([C++]) + AC_CHECK_HEADER(hyperleveldb/db.h,, + [AC_MSG_ERROR([--enable-leveldb=hyper requires hyperleveldb/db.h])]) + AC_LANG_POP([C++]) +elif test "$wt_cv_enable_leveldb" = "yes"; then + AC_LANG_PUSH([C++]) + AC_CHECK_HEADER(leveldb/db.h,, + [AC_MSG_ERROR([--enable-leveldb requires leveldb/db.h])]) + AC_LANG_POP([C++]) +fi +AM_CONDITIONAL([HYPERLEVELDB], [test "$wt_cv_enable_hyperleveldb" = "yes"]) +AM_CONDITIONAL([LEVELDB], [test "$wt_cv_enable_leveldb" = "yes"]) + AC_MSG_CHECKING(if --enable-python option specified) AC_ARG_ENABLE(python, [AS_HELP_STRING([--enable-python], |