diff options
Diffstat (limited to 'Makefile.am')
-rw-r--r-- | Makefile.am | 34 |
1 files changed, 31 insertions, 3 deletions
diff --git a/Makefile.am b/Makefile.am index 76197716..5ce8a2e5 100644 --- a/Makefile.am +++ b/Makefile.am @@ -2,6 +2,9 @@ lib_LTLIBRARIES = libledger.la libledger_la_SOURCES = amount.cc autoxact.cc balance.cc binary.cc config.cc \ datetime.cc format.cc journal.cc option.cc parser.cc qif.cc quotes.cc \ textual.cc valexpr.cc value.cc walk.cc +if READ_GNUCASH +libledger_la_SOURCES += gnucash.cc +endif if DEBUG libledger_la_CXXFLAGS = -DDEBUG_LEVEL=4 libledger_la_SOURCES += debug.cc @@ -10,11 +13,10 @@ if STANDALONE libledger_a_CXXFLAGS = -DSGI_STL_USE_SINGLE_CLIENT_ALLOCATOR=1 endif endif -if READ_GNUCASH -libledger_la_SOURCES += gnucash.cc -endif libledger_la_LDFLAGS = -version-info 2:0 +###################################################################### + bin_PROGRAMS = ledger if DEBUG ledger_CXXFLAGS = -DDEBUG_LEVEL=4 @@ -47,3 +49,29 @@ nobase_include_HEADERS = \ value.h \ walk.h info_TEXINFOS = ledger.texi + +###################################################################### + +if HAVE_PYTHON +if HAVE_BOOST_PYTHON + +noinst_LIBRARIES = libledger_bpy.a +libledger_bpy_a_SOURCES = amount.cc autoxact.cc balance.cc binary.cc config.cc \ + datetime.cc format.cc journal.cc option.cc parser.cc qif.cc quotes.cc \ + textual.cc valexpr.cc value.cc walk.cc +libledger_bpy_a_CXXFLAGS = -DUSE_BOOST_PYTHON=1 +if READ_GNUCASH +libledger_bpy_a_SOURCES += gnucash.cc +endif +if DEBUG +libledger_bpy_a_CXXFLAGS += -DDEBUG_LEVEL=4 +libledger_bpy_a_SOURCES += debug.cc +endif + +bin_PROGRAMS += ledger.so + +ledger.so: python.cc libledger_bpy.a + CFLAGS="$(CPPFLAGS) -L." python setup.py build --build-lib=. + +endif +endif |