Commit 09deb066 authored by Mike Hommey's avatar Mike Hommey

Load /tmp/tmp.BmUFjT/libxml2-2.6.13 into

packages/libxml2/branches/upstream/current.
parent c14c53a3
This diff is collapsed.
...@@ -2091,6 +2091,7 @@ htmlNewDocNoDtD(const xmlChar *URI, const xmlChar *ExternalID) { ...@@ -2091,6 +2091,7 @@ htmlNewDocNoDtD(const xmlChar *URI, const xmlChar *ExternalID) {
cur->ids = NULL; cur->ids = NULL;
cur->refs = NULL; cur->refs = NULL;
cur->_private = NULL; cur->_private = NULL;
cur->charset = XML_CHAR_ENCODING_UTF8;
if ((ExternalID != NULL) || if ((ExternalID != NULL) ||
(URI != NULL)) (URI != NULL))
xmlCreateIntSubset(cur, BAD_CAST "html", ExternalID, URI); xmlCreateIntSubset(cur, BAD_CAST "html", ExternalID, URI);
...@@ -5647,6 +5648,8 @@ htmlReadMemory(const char *buffer, int size, const char *URL, const char *encodi ...@@ -5647,6 +5648,8 @@ htmlReadMemory(const char *buffer, int size, const char *URL, const char *encodi
ctxt = xmlCreateMemoryParserCtxt(buffer, size); ctxt = xmlCreateMemoryParserCtxt(buffer, size);
if (ctxt == NULL) if (ctxt == NULL)
return (NULL); return (NULL);
if (ctxt->sax != NULL)
memcpy(ctxt->sax, &htmlDefaultSAXHandler, sizeof(xmlSAXHandlerV1));
return (htmlDoRead(ctxt, URL, encoding, options, 0)); return (htmlDoRead(ctxt, URL, encoding, options, 0));
} }
......
...@@ -17,7 +17,7 @@ bin_SCRIPTS=xml2-config ...@@ -17,7 +17,7 @@ bin_SCRIPTS=xml2-config
lib_LTLIBRARIES = libxml2.la lib_LTLIBRARIES = libxml2.la
libxml2_la_LIBADD = @THREAD_LIBS@ @Z_LIBS@ $(ICONV_LIBS) @M_LIBS@ @WIN32_EXTRA_LIBADD@ libxml2_la_LIBADD = @THREAD_LIBS@ @Z_LIBS@ $(ICONV_LIBS) @M_LIBS@ @WIN32_EXTRA_LIBADD@
libxml2_la_LDFLAGS = @WIN32_EXTRA_LDFLAGS@ -version-info @LIBXML_VERSION_INFO@ libxml2_la_LDFLAGS = @CYGWIN_EXTRA_LDFLAGS@ @WIN32_EXTRA_LDFLAGS@ -version-info @LIBXML_VERSION_INFO@
if WITH_TRIO_SOURCES if WITH_TRIO_SOURCES
libxml2_la_SOURCES = SAX.c entities.c encoding.c error.c parserInternals.c \ libxml2_la_SOURCES = SAX.c entities.c encoding.c error.c parserInternals.c \
...@@ -123,8 +123,9 @@ check-local: all tests ...@@ -123,8 +123,9 @@ check-local: all tests
testall : tests SVGtests SAXtests testall : tests SVGtests SAXtests
tests: XMLtests XMLenttests NStests IDtests Errtests @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@ tests: XMLtests XMLenttests NStests IDtests Errtests @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@
@(if [ "@PYTHON_SUBDIR@" != "" ] ; then cd python ; $(MAKE) tests ; fi) @(if [ "@PYTHON_SUBDIR@" != "" ] ; then cd python ; \
@(cd doc/examples ; $(MAKE) tests) $(MAKE) MAKEFLAGS+=--silent tests ; fi)
@(cd doc/examples ; $(MAKE) MAKEFLAGS+=--silent tests)
valgrind: valgrind:
@echo '## Running the regression tests under Valgrind' @echo '## Running the regression tests under Valgrind'
...@@ -469,7 +470,22 @@ XIncludetests : xmllint$(EXEEXT) ...@@ -469,7 +470,22 @@ XIncludetests : xmllint$(EXEEXT)
$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude $$i > $(srcdir)/result/XInclude/$$name 2> $(srcdir)/result/XInclude/$$name.err ; \ $(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude $$i > $(srcdir)/result/XInclude/$$name 2> $(srcdir)/result/XInclude/$$name.err ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \ else \
log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude $$i > result.$$name 2>error.$$name | grep -v 'failed to load external entity' ; \ log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude $$i > result.$$name 2>error.$$name ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/XInclude/$$name result.$$name ; \
diff $(srcdir)/result/XInclude/$$name.err error.$$name` ; \
if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \
rm result.$$name error.$$name ; \
fi ; fi ; done)
-@(for i in $(srcdir)/test/XInclude/docs/* ; do \
name=`basename $$i`; \
if [ ! -d $$i ] ; then \
if [ ! -f $(srcdir)/result/XInclude/$$name ] ; then \
echo New test file $$name ; \
$(CHECKER) $(top_builddir)/xmllint --nowarning --noxincludenode $$i > $(srcdir)/result/XInclude/$$name 2> $(srcdir)/result/XInclude/$$name.err ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \
log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --noxincludenode $$i > result.$$name 2>error.$$name ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/XInclude/$$name result.$$name ; \ diff $(srcdir)/result/XInclude/$$name result.$$name ; \
diff $(srcdir)/result/XInclude/$$name.err error.$$name` ; \ diff $(srcdir)/result/XInclude/$$name.err error.$$name` ; \
...@@ -486,7 +502,22 @@ XIncludetests : xmllint$(EXEEXT) ...@@ -486,7 +502,22 @@ XIncludetests : xmllint$(EXEEXT)
$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > $(srcdir)/result/XInclude/$$name.rdr ; \ $(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > $(srcdir)/result/XInclude/$$name.rdr ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \ else \
log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > result.$$name 2>error.$$name | grep -v 'failed to load external entity' ; \ log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > result.$$name 2>error.$$name ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/XInclude/$$name.err error.$$name ; \
diff $(srcdir)/result/XInclude/$$name.rdr result.$$name` ; \
if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \
rm result.$$name error.$$name ; \
fi ; fi ; done)
-@(for i in $(srcdir)/test/XInclude/docs/* ; do \
name=`basename $$i`; \
if [ ! -d $$i ] ; then \
if [ ! -f $(srcdir)/result/XInclude/$$name.rdr ] ; then \
echo New test file $$name ; \
$(CHECKER) $(top_builddir)/xmllint --nowarning --noxincludenode --stream --debug $$i > $(srcdir)/result/XInclude/$$name.rdr ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \
log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > result.$$name 2>error.$$name ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/XInclude/$$name.err error.$$name ; \ diff $(srcdir)/result/XInclude/$$name.err error.$$name ; \
diff $(srcdir)/result/XInclude/$$name.rdr result.$$name` ; \ diff $(srcdir)/result/XInclude/$$name.rdr result.$$name` ; \
...@@ -504,14 +535,15 @@ Scripttests : xmllint$(EXEEXT) ...@@ -504,14 +535,15 @@ Scripttests : xmllint$(EXEEXT)
if [ -f $$xml ] ; then \ if [ -f $$xml ] ; then \
if [ ! -f $(srcdir)/result/scripts/$$name ] ; then \ if [ ! -f $(srcdir)/result/scripts/$$name ] ; then \
echo New test file $$name ; \ echo New test file $$name ; \
$(CHECKER) $(top_builddir)/xmllint --shell $$xml < $$i > $(srcdir)/result/scripts/$$name ; \ $(CHECKER) $(top_builddir)/xmllint --shell $$xml < $$i > $(srcdir)/result/scripts/$$name 2> $(srcdir)/result/scripts/$$name.err ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \ else \
log=`$(CHECKER) $(top_builddir)/xmllint --shell $$xml < $$i 2>&1 > result.$$name ; \ log=`$(CHECKER) $(top_builddir)/xmllint --shell $$xml < $$i > result.$$name 2> result.$$name.err ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/scripts/$$name result.$$name` ; \ diff $(srcdir)/result/scripts/$$name result.$$name ; \
diff $(srcdir)/result/scripts/$$name.err result.$$name.err` ; \
if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \ if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \
rm result.$$name ; \ rm result.$$name result.$$name.err ; \
fi ; fi ; done) fi ; fi ; done)
Catatests : xmlcatalog$(EXEEXT) Catatests : xmlcatalog$(EXEEXT)
...@@ -756,7 +788,7 @@ Automatatests: testAutomata$(EXEEXT) ...@@ -756,7 +788,7 @@ Automatatests: testAutomata$(EXEEXT)
$(srcdir)/dba100000.xml: dbgenattr.pl $(srcdir)/dba100000.xml: dbgenattr.pl
@echo "## generating dba100000.xml" @echo "## generating dba100000.xml"
@($(top_srcdir)/dbgenattr.pl 100000 > $(srcdir)/dba100000.xml) @($(PERL) $(top_srcdir)/dbgenattr.pl 100000 > $(srcdir)/dba100000.xml)
Timingtests: xmllint$(EXEEXT) $(srcdir)/dba100000.xml Timingtests: xmllint$(EXEEXT) $(srcdir)/dba100000.xml
@echo "## Timing tests to try to detect performance" @echo "## Timing tests to try to detect performance"
...@@ -935,6 +967,7 @@ SchemasPythonTests: ...@@ -935,6 +967,7 @@ SchemasPythonTests:
PYTHONPATH=$(top_builddir)/python:$(top_builddir)/python/.libs:$$PYTHONPATH; \ PYTHONPATH=$(top_builddir)/python:$(top_builddir)/python/.libs:$$PYTHONPATH; \
export PYTHONPATH; \ export PYTHONPATH; \
echo "## XML Schemas datatypes Python based test suite" ; \ 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 ; \ $(CHECKER) $(PYTHON) $(srcdir)/check-xsddata-test-suite.py ; \
fi) fi)
...@@ -945,11 +978,14 @@ dist-hook: cleanup libxml2.spec ...@@ -945,11 +978,14 @@ dist-hook: cleanup libxml2.spec
-cp libxml2.spec $(distdir) -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 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
cleantar: cleantar:
@(rm -f libxml*.tar.gz COPYING.LIB) @(rm -f libxml*.tar.gz COPYING.LIB)
rpm: cleanup cleantar rpm: cleanup cleantar
@(unset CDPATH ; $(MAKE) dist && rpmbuild -ta $(distdir).tar.gz) @(unset CDPATH ; $(MAKE) dist-source dist && rpmbuild -ta $(distdir).tar.gz)
## We create xml2Conf.sh here and not from configure because we want ## We create xml2Conf.sh here and not from configure because we want
## to get the paths expanded correctly. Macros like srcdir are given ## to get the paths expanded correctly. Macros like srcdir are given
...@@ -978,7 +1014,8 @@ EXTRA_DIST = xml2-config.in xml2Conf.sh.in libxml.spec.in libxml2.spec \ ...@@ -978,7 +1014,8 @@ EXTRA_DIST = xml2-config.in xml2Conf.sh.in libxml.spec.in libxml2.spec \
trionan.c trionan.h triostr.c triostr.h trio.c trio.h \ trionan.c trionan.h triostr.c triostr.h trio.c trio.h \
triop.h triodef.h libxml.h elfgcchack.h \ triop.h triodef.h libxml.h elfgcchack.h \
testThreadsWin32.c genUnicode.py TODO_SCHEMAS \ testThreadsWin32.c genUnicode.py TODO_SCHEMAS \
dbgen.pl dbgenattr.pl regressions.py regressions.xml dbgen.pl dbgenattr.pl regressions.py regressions.xml \
$(CVS_EXTRA_DIST)
pkgconfigdir = $(libdir)/pkgconfig pkgconfigdir = $(libdir)/pkgconfig
...@@ -999,3 +1036,6 @@ install-data-local: ...@@ -999,3 +1036,6 @@ install-data-local:
-@INSTALL@ -m 0644 $(srcdir)/testSAX.c $(DESTDIR)$(EXAMPLES_DIR) -@INSTALL@ -m 0644 $(srcdir)/testSAX.c $(DESTDIR)$(EXAMPLES_DIR)
-@INSTALL@ -m 0644 $(srcdir)/testHTML.c $(DESTDIR)$(EXAMPLES_DIR) -@INSTALL@ -m 0644 $(srcdir)/testHTML.c $(DESTDIR)$(EXAMPLES_DIR)
-@INSTALL@ -m 0644 $(srcdir)/testXPath.c $(DESTDIR)$(EXAMPLES_DIR) -@INSTALL@ -m 0644 $(srcdir)/testXPath.c $(DESTDIR)$(EXAMPLES_DIR)
tst: tst.c
$(CC) $(CFLAGS) -Iinclude -o tst tst.c .libs/libxml2.a -lpthread -lm -lz
...@@ -245,6 +245,8 @@ CXXCPP = @CXXCPP@ ...@@ -245,6 +245,8 @@ CXXCPP = @CXXCPP@
CXXDEPMODE = @CXXDEPMODE@ CXXDEPMODE = @CXXDEPMODE@
CXXFLAGS = @CXXFLAGS@ CXXFLAGS = @CXXFLAGS@
CYGPATH_W = @CYGPATH_W@ CYGPATH_W = @CYGPATH_W@
CYGWIN_EXTRA_LDFLAGS = @CYGWIN_EXTRA_LDFLAGS@
CYGWIN_EXTRA_PYTHON_LIBADD = @CYGWIN_EXTRA_PYTHON_LIBADD@
DEBUG_OBJ = @DEBUG_OBJ@ DEBUG_OBJ = @DEBUG_OBJ@
DEFS = @DEFS@ DEFS = @DEFS@
DEPDIR = @DEPDIR@ DEPDIR = @DEPDIR@
...@@ -277,6 +279,7 @@ LIBXML_MAJOR_VERSION = @LIBXML_MAJOR_VERSION@ ...@@ -277,6 +279,7 @@ LIBXML_MAJOR_VERSION = @LIBXML_MAJOR_VERSION@
LIBXML_MICRO_VERSION = @LIBXML_MICRO_VERSION@ LIBXML_MICRO_VERSION = @LIBXML_MICRO_VERSION@
LIBXML_MINOR_VERSION = @LIBXML_MINOR_VERSION@ LIBXML_MINOR_VERSION = @LIBXML_MINOR_VERSION@
LIBXML_VERSION = @LIBXML_VERSION@ LIBXML_VERSION = @LIBXML_VERSION@
LIBXML_VERSION_EXTRA = @LIBXML_VERSION_EXTRA@
LIBXML_VERSION_INFO = @LIBXML_VERSION_INFO@ LIBXML_VERSION_INFO = @LIBXML_VERSION_INFO@
LIBXML_VERSION_NUMBER = @LIBXML_VERSION_NUMBER@ LIBXML_VERSION_NUMBER = @LIBXML_VERSION_NUMBER@
LN_S = @LN_S@ LN_S = @LN_S@
...@@ -294,6 +297,7 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ ...@@ -294,6 +297,7 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_VERSION = @PACKAGE_VERSION@ PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SEPARATOR = @PATH_SEPARATOR@
PATTERN_TEST = @PATTERN_TEST@ PATTERN_TEST = @PATTERN_TEST@
PERL = @PERL@
PYTHON = @PYTHON@ PYTHON = @PYTHON@
PYTHON_INCLUDES = @PYTHON_INCLUDES@ PYTHON_INCLUDES = @PYTHON_INCLUDES@
PYTHON_SITE_PACKAGES = @PYTHON_SITE_PACKAGES@ PYTHON_SITE_PACKAGES = @PYTHON_SITE_PACKAGES@
...@@ -423,7 +427,7 @@ INCLUDES = -I$(top_builddir)/include -I@srcdir@/include @THREAD_CFLAGS@ @Z_CFLAG ...@@ -423,7 +427,7 @@ INCLUDES = -I$(top_builddir)/include -I@srcdir@/include @THREAD_CFLAGS@ @Z_CFLAG
bin_SCRIPTS = xml2-config bin_SCRIPTS = xml2-config
lib_LTLIBRARIES = libxml2.la lib_LTLIBRARIES = libxml2.la
libxml2_la_LIBADD = @THREAD_LIBS@ @Z_LIBS@ $(ICONV_LIBS) @M_LIBS@ @WIN32_EXTRA_LIBADD@ libxml2_la_LIBADD = @THREAD_LIBS@ @Z_LIBS@ $(ICONV_LIBS) @M_LIBS@ @WIN32_EXTRA_LIBADD@
libxml2_la_LDFLAGS = @WIN32_EXTRA_LDFLAGS@ -version-info @LIBXML_VERSION_INFO@ libxml2_la_LDFLAGS = @CYGWIN_EXTRA_LDFLAGS@ @WIN32_EXTRA_LDFLAGS@ -version-info @LIBXML_VERSION_INFO@
@WITH_TRIO_SOURCES_FALSE@libxml2_la_SOURCES = SAX.c entities.c encoding.c error.c parserInternals.c \ @WITH_TRIO_SOURCES_FALSE@libxml2_la_SOURCES = SAX.c entities.c encoding.c error.c parserInternals.c \
@WITH_TRIO_SOURCES_FALSE@ parser.c tree.c hash.c list.c xmlIO.c xmlmemory.c uri.c \ @WITH_TRIO_SOURCES_FALSE@ parser.c tree.c hash.c list.c xmlIO.c xmlmemory.c uri.c \
@WITH_TRIO_SOURCES_FALSE@ valid.c xlink.c HTMLparser.c HTMLtree.c debugXML.c xpath.c \ @WITH_TRIO_SOURCES_FALSE@ valid.c xlink.c HTMLparser.c HTMLtree.c debugXML.c xpath.c \
...@@ -511,7 +515,8 @@ EXTRA_DIST = xml2-config.in xml2Conf.sh.in libxml.spec.in libxml2.spec \ ...@@ -511,7 +515,8 @@ EXTRA_DIST = xml2-config.in xml2Conf.sh.in libxml.spec.in libxml2.spec \
trionan.c trionan.h triostr.c triostr.h trio.c trio.h \ trionan.c trionan.h triostr.c triostr.h trio.c trio.h \
triop.h triodef.h libxml.h elfgcchack.h \ triop.h triodef.h libxml.h elfgcchack.h \
testThreadsWin32.c genUnicode.py TODO_SCHEMAS \ testThreadsWin32.c genUnicode.py TODO_SCHEMAS \
dbgen.pl dbgenattr.pl regressions.py regressions.xml dbgen.pl dbgenattr.pl regressions.py regressions.xml \
$(CVS_EXTRA_DIST)
pkgconfigdir = $(libdir)/pkgconfig pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libxml-2.0.pc pkgconfig_DATA = libxml-2.0.pc
...@@ -1338,8 +1343,9 @@ check-local: all tests ...@@ -1338,8 +1343,9 @@ check-local: all tests
testall : tests SVGtests SAXtests testall : tests SVGtests SAXtests
tests: XMLtests XMLenttests NStests IDtests Errtests @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@ tests: XMLtests XMLenttests NStests IDtests Errtests @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@
@(if [ "@PYTHON_SUBDIR@" != "" ] ; then cd python ; $(MAKE) tests ; fi) @(if [ "@PYTHON_SUBDIR@" != "" ] ; then cd python ; \
@(cd doc/examples ; $(MAKE) tests) $(MAKE) MAKEFLAGS+=--silent tests ; fi)
@(cd doc/examples ; $(MAKE) MAKEFLAGS+=--silent tests)
valgrind: valgrind:
@echo '## Running the regression tests under Valgrind' @echo '## Running the regression tests under Valgrind'
...@@ -1684,7 +1690,22 @@ XIncludetests : xmllint$(EXEEXT) ...@@ -1684,7 +1690,22 @@ XIncludetests : xmllint$(EXEEXT)
$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude $$i > $(srcdir)/result/XInclude/$$name 2> $(srcdir)/result/XInclude/$$name.err ; \ $(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude $$i > $(srcdir)/result/XInclude/$$name 2> $(srcdir)/result/XInclude/$$name.err ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \ else \
log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude $$i > result.$$name 2>error.$$name | grep -v 'failed to load external entity' ; \ log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude $$i > result.$$name 2>error.$$name ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/XInclude/$$name result.$$name ; \
diff $(srcdir)/result/XInclude/$$name.err error.$$name` ; \
if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \
rm result.$$name error.$$name ; \
fi ; fi ; done)
-@(for i in $(srcdir)/test/XInclude/docs/* ; do \
name=`basename $$i`; \
if [ ! -d $$i ] ; then \
if [ ! -f $(srcdir)/result/XInclude/$$name ] ; then \
echo New test file $$name ; \
$(CHECKER) $(top_builddir)/xmllint --nowarning --noxincludenode $$i > $(srcdir)/result/XInclude/$$name 2> $(srcdir)/result/XInclude/$$name.err ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \
log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --noxincludenode $$i > result.$$name 2>error.$$name ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/XInclude/$$name result.$$name ; \ diff $(srcdir)/result/XInclude/$$name result.$$name ; \
diff $(srcdir)/result/XInclude/$$name.err error.$$name` ; \ diff $(srcdir)/result/XInclude/$$name.err error.$$name` ; \
...@@ -1701,7 +1722,22 @@ XIncludetests : xmllint$(EXEEXT) ...@@ -1701,7 +1722,22 @@ XIncludetests : xmllint$(EXEEXT)
$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > $(srcdir)/result/XInclude/$$name.rdr ; \ $(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > $(srcdir)/result/XInclude/$$name.rdr ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \ else \
log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > result.$$name 2>error.$$name | grep -v 'failed to load external entity' ; \ log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > result.$$name 2>error.$$name ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/XInclude/$$name.err error.$$name ; \
diff $(srcdir)/result/XInclude/$$name.rdr result.$$name` ; \
if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \
rm result.$$name error.$$name ; \
fi ; fi ; done)
-@(for i in $(srcdir)/test/XInclude/docs/* ; do \
name=`basename $$i`; \
if [ ! -d $$i ] ; then \
if [ ! -f $(srcdir)/result/XInclude/$$name.rdr ] ; then \
echo New test file $$name ; \
$(CHECKER) $(top_builddir)/xmllint --nowarning --noxincludenode --stream --debug $$i > $(srcdir)/result/XInclude/$$name.rdr ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \
log=`$(CHECKER) $(top_builddir)/xmllint --nowarning --xinclude --stream --debug $$i > result.$$name 2>error.$$name ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/XInclude/$$name.err error.$$name ; \ diff $(srcdir)/result/XInclude/$$name.err error.$$name ; \
diff $(srcdir)/result/XInclude/$$name.rdr result.$$name` ; \ diff $(srcdir)/result/XInclude/$$name.rdr result.$$name` ; \
...@@ -1719,14 +1755,15 @@ Scripttests : xmllint$(EXEEXT) ...@@ -1719,14 +1755,15 @@ Scripttests : xmllint$(EXEEXT)
if [ -f $$xml ] ; then \ if [ -f $$xml ] ; then \
if [ ! -f $(srcdir)/result/scripts/$$name ] ; then \ if [ ! -f $(srcdir)/result/scripts/$$name ] ; then \
echo New test file $$name ; \ echo New test file $$name ; \
$(CHECKER) $(top_builddir)/xmllint --shell $$xml < $$i > $(srcdir)/result/scripts/$$name ; \ $(CHECKER) $(top_builddir)/xmllint --shell $$xml < $$i > $(srcdir)/result/scripts/$$name 2> $(srcdir)/result/scripts/$$name.err ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
else \ else \
log=`$(CHECKER) $(top_builddir)/xmllint --shell $$xml < $$i 2>&1 > result.$$name ; \ log=`$(CHECKER) $(top_builddir)/xmllint --shell $$xml < $$i > result.$$name 2> result.$$name.err ; \
grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\ grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0";\
diff $(srcdir)/result/scripts/$$name result.$$name` ; \ diff $(srcdir)/result/scripts/$$name result.$$name ; \
diff $(srcdir)/result/scripts/$$name.err result.$$name.err` ; \
if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \ if [ -n "$$log" ] ; then echo $$name result ; echo $$log ; fi ; \
rm result.$$name ; \ rm result.$$name result.$$name.err ; \
fi ; fi ; done) fi ; fi ; done)
Catatests : xmlcatalog$(EXEEXT) Catatests : xmlcatalog$(EXEEXT)
...@@ -1971,7 +2008,7 @@ Automatatests: testAutomata$(EXEEXT) ...@@ -1971,7 +2008,7 @@ Automatatests: testAutomata$(EXEEXT)
$(srcdir)/dba100000.xml: dbgenattr.pl $(srcdir)/dba100000.xml: dbgenattr.pl
@echo "## generating dba100000.xml" @echo "## generating dba100000.xml"
@($(top_srcdir)/dbgenattr.pl 100000 > $(srcdir)/dba100000.xml) @($(PERL) $(top_srcdir)/dbgenattr.pl 100000 > $(srcdir)/dba100000.xml)
Timingtests: xmllint$(EXEEXT) $(srcdir)/dba100000.xml Timingtests: xmllint$(EXEEXT) $(srcdir)/dba100000.xml
@echo "## Timing tests to try to detect performance" @echo "## Timing tests to try to detect performance"
...@@ -2150,6 +2187,7 @@ SchemasPythonTests: ...@@ -2150,6 +2187,7 @@ SchemasPythonTests:
PYTHONPATH=$(top_builddir)/python:$(top_builddir)/python/.libs:$$PYTHONPATH; \ PYTHONPATH=$(top_builddir)/python:$(top_builddir)/python/.libs:$$PYTHONPATH; \
export PYTHONPATH; \ export PYTHONPATH; \
echo "## XML Schemas datatypes Python based test suite" ; \ 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 ; \ $(CHECKER) $(PYTHON) $(srcdir)/check-xsddata-test-suite.py ; \
fi) fi)
...@@ -2160,11 +2198,14 @@ dist-hook: cleanup libxml2.spec ...@@ -2160,11 +2198,14 @@ dist-hook: cleanup libxml2.spec
-cp libxml2.spec $(distdir) -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 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
cleantar: cleantar:
@(rm -f libxml*.tar.gz COPYING.LIB) @(rm -f libxml*.tar.gz COPYING.LIB)
rpm: cleanup cleantar rpm: cleanup cleantar
@(unset CDPATH ; $(MAKE) dist && rpmbuild -ta $(distdir).tar.gz) @(unset CDPATH ; $(MAKE) dist-source dist && rpmbuild -ta $(distdir).tar.gz)
xml2Conf.sh: xml2Conf.sh.in Makefile xml2Conf.sh: xml2Conf.sh.in Makefile
sed -e 's?\@XML_LIBDIR\@?$(XML_LIBDIR)?g' \ sed -e 's?\@XML_LIBDIR\@?$(XML_LIBDIR)?g' \
...@@ -2182,6 +2223,9 @@ install-data-local: ...@@ -2182,6 +2223,9 @@ install-data-local:
-@INSTALL@ -m 0644 $(srcdir)/testSAX.c $(DESTDIR)$(EXAMPLES_DIR) -@INSTALL@ -m 0644 $(srcdir)/testSAX.c $(DESTDIR)$(EXAMPLES_DIR)
-@INSTALL@ -m 0644 $(srcdir)/testHTML.c $(DESTDIR)$(EXAMPLES_DIR) -@INSTALL@ -m 0644 $(srcdir)/testHTML.c $(DESTDIR)$(EXAMPLES_DIR)
-@INSTALL@ -m 0644 $(srcdir)/testXPath.c $(DESTDIR)$(EXAMPLES_DIR) -@INSTALL@ -m 0644 $(srcdir)/testXPath.c $(DESTDIR)$(EXAMPLES_DIR)
tst: tst.c
$(CC) $(CFLAGS) -Iinclude -o tst tst.c .libs/libxml2.a -lpthread -lm -lz
# Tell versions [3.59,3.63) of GNU make to not export all variables. # Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded. # Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT: .NOEXPORT:
...@@ -9,7 +9,53 @@ to help those - More testing on RelaxNG ...@@ -9,7 +9,53 @@ to help those - More testing on RelaxNG
- Finishing up XML - Finishing up XML
Schemas Schemas
There is the list of public releases: The change log at
ChangeLog.html
describes the recents commits
to the CVS at
http://cvs.gnome.org/viewcvs/libxml2/
code base.There is the list of public releases:
2.6.13: Aug 31 2004:
- build fixes: Windows and zlib (Igor Zlatkovic), -O flag with gcc,
Solaris compiler warning, fixing RPM BuildRequires,
- fixes: DTD loading on Windows (Igor), Schemas error reports APIs
(Kasimier Buchcik), Schemas validation crash, xmlCheckUTF8 (William Brack
and Julius Mittenzwei), Schemas facet check (Kasimier), default namespace
problem (William), Schemas hexbinary empty values, encoding error could
genrate a serialization loop.
- Improvements: Schemas validity improvements (Kasimier), added --path
and --load-trace options to xmllint
- documentation: tutorial update (John Fleck)
2.6.12: Aug 22 2004:
- build fixes: fix --with-minimum, elfgcchack.h fixes (Peter
Breitenlohner), perl path lookup (William), diff on Solaris (Albert
Chin), some 64bits cleanups.
- Python: avoid a warning with 2.3 (William Brack), tab and space mixes
(William), wrapper generator fixes (William), Cygwin support (Gerrit P.
Haase), node wrapper fix (Marc-Antoine Parent), XML Schemas support
(Torkel Lyng)
- Schemas: a lot of bug fixes and improvements from Kasimier Buchcik
- fixes: RVT fixes (William), XPath context resets bug (William), memory
debug (Steve Hay), catalog white space handling (Peter Breitenlohner),
xmlReader state after attribute reading (William), structured error
handler (William), XInclude generated xml:base fixup (William), Windows
memory reallocation problem (Steve Hay), Out of Memory conditions
handling (William and Olivier Andrieu), htmlNewDoc() charset bug,
htmlReadMemory init (William), a posteriori validation DTD base
(William), notations serialization missing, xmlGetNodePath (Dodji),
xmlCheckUTF8 (Diego Tartara), missing line numbers on entity
(William)
- improvements: DocBook catalog build scrip (William), xmlcatalog tool
(Albert Chin), xmllint --c14n option, no_proxy environment (Mike Hommey),
xmlParseInNodeContext() addition, extend xmllint --shell, allow XInclude
to not generate start/end nodes, extend xmllint --version to include CVS
tag (William)
- documentation: web pages fixes, validity API docs fixes (William)
schemas API fix (Eric Haszlakiewicz), xmllint man page (John Fleck)
2.6.11: July 5 2004: 2.6.11: July 5 2004:
- Schemas: a lot of changes and improvements by Kasimier Buchcik for - Schemas: a lot of changes and improvements by Kasimier Buchcik for
attributes, namespaces and simple types. attributes, namespaces and simple types.
...@@ -18,12 +64,12 @@ There is the list of public releases: ...@@ -18,12 +64,12 @@ There is the list of public releases:
- portability: Windows binary package change (Igor Zlatkovic), Catalog - portability: Windows binary package change (Igor Zlatkovic), Catalog
path on Windows path on Windows
- documentation: update to the tutorial (John Fleck), xmllint return code - documentation: update to the tutorial (John Fleck), xmllint return code
(John Fleck), man pages (Ville Skytta), (John Fleck), man pages (Ville Skytta),
- bug fixes: C14N bug serializing namespaces (Aleksey Sanin), testSAX - bug fixes: C14N bug serializing namespaces (Aleksey Sanin), testSAX
properly initialize the library (William), empty node set in XPath properly initialize the library (William), empty node set in XPath
(William), xmlSchemas errors (William), invalid charref problem pointed (William), xmlSchemas errors (William), invalid charref problem pointed
by Morus Walter, XInclude xml:base generation (William), Relax-NG bug by Morus Walter, XInclude xml:base generation (William), Relax-NG bug
with div processing (William), XPointer and xml:base problem(William), with div processing (William), XPointer and xml:base problem(William),
Reader and entities, xmllint return code for schemas (William), reader Reader and entities, xmllint return code for schemas (William), reader
streaming problem (Steve Ball), DTD serialization problem (William), streaming problem (Steve Ball), DTD serialization problem (William),
libxml.m4 fixes (Mike Hommey), do not provide destructors as methods on libxml.m4 fixes (Mike Hommey), do not provide destructors as methods on
......
...@@ -44,6 +44,20 @@ ...@@ -44,6 +44,20 @@
"Unimplemented block at %s:%d\n", \ "Unimplemented block at %s:%d\n", \
__FILE__, __LINE__); __FILE__, __LINE__);
/*
* xmlSAX2ErrMemory:
* @ctxt: an XML validation parser context
* @msg: a string to accompany the error message
*/
static void
xmlSAX2ErrMemory(xmlParserCtxtPtr ctxt, const char *msg) {
if ((ctxt->sax != NULL) && (ctxt->sax->error != NULL))
ctxt->sax->error(ctxt->userData, "%s: out of memory\n", msg);
ctxt->errNo = XML_ERR_NO_MEMORY;
ctxt->instate = XML_PARSER_EOF;
ctxt->disableSAX = 1;
}
/** /**
* xmlValidError: * xmlValidError:
* @ctxt: an XML validation parser context * @ctxt: an XML validation parser context
...@@ -214,6 +228,8 @@ xmlSAX2InternalSubset(void *ctx, const xmlChar *name, ...@@ -214,6 +228,8 @@ xmlSAX2InternalSubset(void *ctx, const xmlChar *name,
} }
ctxt->myDoc->intSubset = ctxt->myDoc->intSubset =
xmlCreateIntSubset(ctxt->myDoc, name, ExternalID, SystemID); xmlCreateIntSubset(ctxt->myDoc, name, ExternalID, SystemID);