+pythondir = $(PYTHON_INSTALLDIR)
+
+python_DATA = guestfs.py
+
+python_LTLIBRARIES = libguestfsmod.la
+
+libguestfsmod_la_SOURCES = guestfs-py.c guestfs-py.h guestfs-py-byhand.c
+libguestfsmod_la_CFLAGS = -Wall -I$(PYTHON_INCLUDEDIR) \
+ -I$(top_srcdir)/src -I$(top_builddir)/src
+libguestfsmod_la_LIBADD = $(top_builddir)/src/libguestfs.la
+libguestfsmod_la_LDFLAGS = -avoid-version -shared
+
+TESTS_ENVIRONMENT = \
+ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ PYTHONPATH=$(builddir):$(builddir)/.libs \
+ TMPDIR=$(top_builddir) \
+ PYTHON=$(PYTHON)
+
+TESTS = run-bindtests run-python-tests
+
+endif