|
Packit |
21b7a2 |
# Makefile for libxml2 python library
|
|
Packit |
21b7a2 |
AUTOMAKE_OPTIONS = 1.4 foreign
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
SUBDIRS = . tests
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
docsdir = $(datadir)/doc/libxml2-python-$(LIBXML_VERSION)
|
|
Packit |
21b7a2 |
dist_docs_DATA = TODO
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
EXTRA_DIST = \
|
|
Packit |
21b7a2 |
setup.py \
|
|
Packit |
21b7a2 |
generator.py \
|
|
Packit |
21b7a2 |
libxml.py \
|
|
Packit |
21b7a2 |
libxml2-export.c \
|
|
Packit |
21b7a2 |
libxml2-python-api.xml \
|
|
Packit |
21b7a2 |
libxml2class.py \
|
|
Packit |
21b7a2 |
libxml2class.txt
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
if WITH_PYTHON
|
|
Packit |
21b7a2 |
AM_CPPFLAGS = \
|
|
Packit |
21b7a2 |
-I$(top_builddir)/include \
|
|
Packit |
21b7a2 |
-I$(top_srcdir)/include \
|
|
Packit |
21b7a2 |
-I$(PYTHON_INCLUDES)
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
python_LTLIBRARIES = libxml2mod.la
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
libxml2mod_la_SOURCES = libxml.c libxml_wrap.h libxml2-py.h libxml2-py.c types.c
|
|
Packit |
21b7a2 |
libxml2mod_la_LDFLAGS = $(CYGWIN_EXTRA_LDFLAGS) $(WIN32_EXTRA_LDFLAGS) -module -avoid-version \
|
|
Packit |
21b7a2 |
$(top_builddir)/libxml2.la $(CYGWIN_EXTRA_PYTHON_LIBADD) $(WIN32_EXTRA_PYTHON_LIBADD) $(PYTHON_LIBS)
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
BUILT_SOURCES = libxml2-export.c libxml2-py.h libxml2-py.c
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
# libxml.c #includes libxml2-export.c
|
|
Packit |
21b7a2 |
libxml.$(OBJEXT): libxml2-export.c
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
libxml2.py: $(srcdir)/libxml.py libxml2class.py
|
|
Packit |
21b7a2 |
cat $(srcdir)/libxml.py `test -f libxml2class.py || echo $(srcdir)/`libxml2class.py > $@
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
dist_python_DATA = \
|
|
Packit |
21b7a2 |
drv_libxml2.py \
|
|
Packit |
21b7a2 |
libxml2.py
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
CLEANFILES = *.pyc
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
MAINTAINERCLEANFILES = libxml2.py libxml2class.*
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
API_DESC = $(top_srcdir)/doc/libxml2-api.xml $(srcdir)/libxml2-python-api.xml
|
|
Packit |
21b7a2 |
GENERATED = libxml2class.py libxml2class.txt $(BUILT_SOURCES)
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
$(GENERATED): $(srcdir)/generator.py $(API_DESC)
|
|
Packit |
21b7a2 |
$(PYTHON) $(srcdir)/generator.py $(srcdir)
|
|
Packit |
21b7a2 |
endif
|
|
Packit |
21b7a2 |
|
|
Packit |
21b7a2 |
tests test: all
|
|
Packit |
21b7a2 |
cd tests && $(MAKE) tests
|