diff options
author | John Wiegley <johnw@newartisans.com> | 2004-08-28 04:26:48 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2004-08-28 04:26:48 -0400 |
commit | b4304515ff0501da47cbcd4b47c770e2bb55a83d (patch) | |
tree | 03bfa7fb21d09cffa20ded425016ad8b0aef7e21 /configure.in | |
parent | 863485ad8ff29399fb9eafd1cfc863c5e8aa27f6 (diff) | |
download | fork-ledger-b4304515ff0501da47cbcd4b47c770e2bb55a83d.tar.gz fork-ledger-b4304515ff0501da47cbcd4b47c770e2bb55a83d.tar.bz2 fork-ledger-b4304515ff0501da47cbcd4b47c770e2bb55a83d.zip |
ledger.so (the python module) now builds based on autoconf discovery
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/configure.in b/configure.in index 3faa10fe..6fd1cbab 100644 --- a/configure.in +++ b/configure.in @@ -26,6 +26,28 @@ AC_CHECK_LIB([xmlparse], [XML_ParserCreate], AM_CONDITIONAL(READ_GNUCASH, false)], [-lxmltok]) +AM_PATH_PYTHON(2.2,, :) +AM_CONDITIONAL(HAVE_PYTHON, [test "$PYTHON" != :]) +AC_CACHE_CHECK( + [if boost_python is available], + [boost_python_cpplib_avail], + [boost_python_save_libs=$LIBS + LIBS="-lboost_python $LIBS" + AC_LANG_PUSH(C++) + AC_TRY_COMPILE( + [#include <boost/python.hpp> + using namespace boost::python; + class foo {}; + BOOST_PYTHON_MODULE(samp) { + class_< foo > ("foo") ; + }], + [return 0], + [boost_python_cpplib_avail=true], + [boost_python_cpplib_avail=false]) + AC_LANG_POP + LIBS=$boost_python_save_libs]) +AM_CONDITIONAL(HAVE_BOOST_PYTHON, test x$boost_python_cpplib_avail = xtrue) + # Check for options AC_ARG_ENABLE(debug, [ --enable-debug Turn on debugging], |