summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
authorMike Hommey <glandium@debian.org>2005-03-27 13:13:58 +0000
committerMike Hommey <glandium@debian.org>2005-03-27 13:13:58 +0000
commit50e5b428562964b1eb2f876370058b34b47c5e90 (patch)
treec66bcae6dbbce07128ee881353ff60090524462c /Makefile.am
parenta7457388701e6ccba9091ba3ec09505dc903b758 (diff)
downloadlibxml2-50e5b428562964b1eb2f876370058b34b47c5e90.tar.gz
Load /tmp/tmp.XJZ6qc/libxml2-2.6.18 intoupstream/2.6.18
packages/libxml2/branches/upstream/current.
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am50
1 files changed, 42 insertions, 8 deletions
diff --git a/Makefile.am b/Makefile.am
index 92dd8b9..c857b62 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -123,7 +123,14 @@ noinst_LTLIBRARIES = testdso.la
testdso_la_SOURCES = testdso.c
testdso_la_LDFLAGS = -module -rpath $(libdir)
-testapi.c: $(srcdir)/gentest.py doc/libxml2-api.xml
+# that one forces the rebuild when "make rebuild" is run on doc/
+rebuild_testapi:
+ -@(if [ "$(PYTHON)" != "" ] ; then \
+ $(PYTHON) $(srcdir)/gentest.py $(srcdir) ; fi )
+
+# that one is just to make sure it is rebuilt if missing
+# but adding the dependances generate mess
+testapi.c:
-@(if [ "$(PYTHON)" != "" ] ; then \
$(PYTHON) $(srcdir)/gentest.py $(srcdir) ; fi )
@@ -141,7 +148,7 @@ check-local: all tests
testall : tests SVGtests SAXtests
-tests: XMLtests XMLenttests NStests IDtests Errtests APItests @READER_TEST@ @TEST_SAX@ @TEST_PUSH@ @TEST_HTML@ @TEST_PHTML@ @TEST_VALID@ URItests @TEST_XPATH@ @TEST_XPTR@ @TEST_XINCLUDE@ @TEST_C14N@ @TEST_DEBUG@ @TEST_CATALOG@ @TEST_REGEXPS@ @TEST_SCHEMAS@ @TEST_THREADS@ Timingtests @TEST_VTIME@ @PYTHON_TESTS@ @TEST_MODULES@
+tests: XMLtests XMLenttests NStests IDtests Errtests APItests @READER_TEST@ @TEST_SAX@ @TEST_PUSH@ @TEST_HTML@ @TEST_PHTML@ @TEST_VALID@ URItests @TEST_PATTERN@ @TEST_XPATH@ @TEST_XPTR@ @TEST_XINCLUDE@ @TEST_C14N@ @TEST_DEBUG@ @TEST_CATALOG@ @TEST_REGEXPS@ @TEST_SCHEMAS@ @TEST_THREADS@ Timingtests @TEST_VTIME@ @PYTHON_TESTS@ @TEST_MODULES@
@(if [ "@PYTHON_SUBDIR@" != "" ] ; then cd python ; \
$(MAKE) MAKEFLAGS+=--silent tests ; fi)
@(cd doc/examples ; $(MAKE) MAKEFLAGS+=--silent tests)
@@ -149,7 +156,7 @@ tests: XMLtests XMLenttests NStests IDtests Errtests APItests @READER_TEST@ @TES
valgrind:
@echo '## Running the regression tests under Valgrind'
@echo '## Go get a cup of coffee it is gonna take a while ...'
- $(MAKE) CHECKER='valgrind -q' tests
+ $(MAKE) CHECKER='valgrind' tests
APItests: testapi$(EXEEXT)
@echo "## Running the API regression tests this may take a little while"
@@ -354,15 +361,14 @@ Errtests : xmllint$(EXEEXT)
echo New test file $$name ; \
$(CHECKER) $(top_builddir)/xmllint --stream $$i \
2> $(srcdir)/result/errors/$$name.str \
- > $(srcdir)/result/errors/$$name ; \
+ > /dev/null ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0"; \
else \
- log=`$(CHECKER) $(top_builddir)/xmllint --stream $$i 2> error.$$name > result.$$name ; \
+ log=`$(CHECKER) $(top_builddir)/xmllint --stream $$i 2> error.$$name > /dev/null ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0"; \
- diff $(srcdir)/result/errors/$$name result.$$name ; \
diff $(srcdir)/result/errors/$$name.str error.$$name` ; \
if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \
- rm result.$$name error.$$name ; \
+ rm error.$$name ; \
fi ; fi ; done)
Docbtests : xmllint$(EXEEXT)
@@ -979,6 +985,8 @@ RelaxNGPythonTests:
@(if [ -x $(PYTHON) ] ; then \
PYTHONPATH=$(top_builddir)/python:$(top_builddir)/python/.libs:$$PYTHONPATH ; \
export PYTHONPATH; \
+ LD_LIBRARY_PATH="$(top_builddir)/.libs:$$LD_LIBRARY_PATH" ; \
+ export LD_LIBRARY_PATH; \
echo "## Relax-NG Python based test suite 1" ; \
$(CHECKER) $(PYTHON) $(srcdir)/check-relaxng-test-suite.py ; \
echo "## Relax-NG Python based test suite 2" ; \
@@ -989,12 +997,38 @@ SchemasPythonTests:
@(if [ -x $(PYTHON) ] ; then \
PYTHONPATH=$(top_builddir)/python:$(top_builddir)/python/.libs:$$PYTHONPATH; \
export PYTHONPATH; \
+ LD_LIBRARY_PATH="$(top_builddir)/.libs:$$LD_LIBRARY_PATH" ; \
+ export LD_LIBRARY_PATH; \
echo "## XML Schemas datatypes Python based test suite" ; \
echo "## It is normal to see 6 errors reported" ; \
$(CHECKER) $(PYTHON) $(srcdir)/check-xsddata-test-suite.py ; \
fi)
@(if [ -x $(PYTHON) -a -d xstc ] ; then cd xstc ; $(MAKE) CHECKER="$(CHECKER)" MAKEFLAGS+=--silent pytests ; fi)
+Patterntests: xmllint$(EXEEXT)
+ @(echo > .memdump)
+ @echo "## Pattern regression tests"
+ -@(for i in $(srcdir)/test/pattern/*.pat ; do \
+ name=`basename $$i .pat`; \
+ if [ -f $(srcdir)/test/pattern/$$name.xml ] ; then \
+ if [ ! -f $(srcdir)/result/pattern/$$name ] ; then \
+ rm -f result.$$name ; \
+ echo New test file $$name ; \
+ for pat in `cat $$i` ; do \
+ $(CHECKER) $(top_builddir)/xmllint --walker --pattern $$pat $(srcdir)/test/pattern/$$name.xml >> $(srcdir)/result/pattern/$$name ; \
+ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
+ done ;\
+ else \
+ rm -f result.$$name ; \
+ lst=`cat $$i` ; \
+ log=`for pat in $$lst ; do $(CHECKER) $(top_builddir)/xmllint --walker --pattern $$pat $(srcdir)/test/pattern/$$name.xml 2>&1 >> result.$$name ; \
+ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
+ done ;\
+ diff $(srcdir)/result/pattern/$$name result.$$name` ; \
+ if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \
+ rm result.$$name ; \
+ fi ; fi ; done ;)
+
ModuleTests: testModule$(EXEEXT) testdso.la
@echo "## Module tests"
@(./testModule$(EXEEXT))
@@ -1004,7 +1038,7 @@ cleanup:
dist-hook: cleanup libxml2.spec
-cp libxml2.spec $(distdir)
- (cd $(srcdir) ; tar -cf - --exclude CVS win32 macos vms test result SAXresult ) | (cd $(distdir); tar xf -)
+ (cd $(srcdir) ; tar -cf - --exclude CVS win32 macos vms bakefile test result SAXresult ) | (cd $(distdir); tar xf -)
dist-source: distdir
$(AMTAR) -chof - --exclude test --exclude result $(distdir) | GZIP=$(GZIP_ENV) gzip -c >`echo "$(distdir)" | sed "s+libxml2+libxml2-sources+"`.tar.gz