Added target to run checks based on xmlwf and James Clark's test cases.
This is not run by "make check" since it requires unzip, wget, and network
access to set up the tests. Use "make run-xmltext" to run the tests.
Revise the data accumulation to be at least a little separated from the
actual test code. Not pretty & lacking in internal documentation, but
allows the test code to be a bit more readable.
Take advantage of XML_ParserReset(): Instead of creating new parsers in
run_*_check(), reset the parser between uses in the one place its actually
needed.
XML_ParserReset(): New function. Reset a parser to be used again, without
having to incur memory allocation costs for subsequent parses.
This closes SF patch #450608, contributed by David Crowley.
_xml_failure(): Clean up the output message so the first line doesn't
wrap in the typical case.
CharData typedef: If count is less than 0, consider it "unset". This
is used in the new support to check attribute values.
accumulate_characters(): Handle storage->count < 0. Allow XML_Char
to be more than one byte.
accumulate_attribute(): New function: store the value of the first
attribute encountered in parsing. This needs the concept of a
CharData that is unset to allow capturing a value that is an empty
string.
check_characters(): Handle storage->count < 0. Allow XML_Char to be
more than one byte.
run_character_check(): Create a local parser so that both
run_character_check() and run_attribute_check() can be used in a
single test function.
run_attribute_check(): New function: check that the value of the
first attribute in a document matches the expected value.
Check in SF patch #476929: Fix XML_SetReturnNSTriplet().
This is slightly modified from the submitted patch to ensure a variable is
never used uninitialized.
Patch contributed by Karl Waclawek.
basic_setup(): Remove bogus assumption that all tests would use US-ASCII
data; let Expat determine the proper encoding from the XML source text.
Added several tests relating to supposed mis-interpretation of Latin-1;
these show that Expat (at least in the CVS version) is properly decoding
the Latin-1 text and generating the proper UTF-8 output.
Greg Stein [Fri, 7 Dec 2001 10:19:31 +0000 (10:19 +0000)]
* Switch to a single, top-level Makefile (simplification, consistency)
* use libtool to compile/link all programs
* remove */Makefile.in and remove them from configure
* remove autom4te.cache after running autoconf
* remove .o from the FILEMAP logic in configure and the Make system;
provides more flexibility in the Makefile to use it
* for VPATH builds: create the build subdirs by running
"make mkdir-init" from the configure script
* adjust .cvsignore files to account for presence of .libs now
Added a test to make sure that whitespace in ENTITIES, IDREFS, and NMTOKENS
attributes is properly collapsed according to Section 3.3.3 of the spec.
This is the first even slightly complicated test; boy are these painful in
C! Had to add a test of a helper routine as well; that just uses assertions
since the test framework should not be dealing with tests of the tester,
just of Expat.
Added a helper to make the failure messages more useful when Expat produces
an unexpected error code; we now include the error message and location from
Expat. This is mostly useful when developing a new test.
Added tests that some basic encodings are recognized and the corresponding
BOM marks do not cause core dumps. The UTF-8 BOM bug was fixed a while ago,
but a regression test is always a good idea.
Added a test that ensures the parser reports an out-of-place XML declaration.
(Originally written to attempt to tickle a different bug, but useful as a
regression test even though Expat has been doing the right thing.)
As long as SourceForge is changing their logo, we can look really slick too.
A little geometric twiddle can take us a long way toward fame & fortune! ;-)
Be more careful about deciding which filemap implementation to use for
xmlwf. Part of SF patch #465018.
Only add the -fexceptions option when the version of GCC we're using
actually supports it. This relates to & partially solves SF bug #445893;
see also SF bug #419585 for why the option was originally added.
Revert previous change and use an alternate approach, this time actually
tested on one of the platforms that exhibited the problem this tries to
fix. Solution contributed by Michael C. Maggio; thanks!
Abandon the use of directory names as target names; there are enough
platforms for which .PHONY is not implemented that this causes the build to
be tedious for those users, leading to bug reports.
Greg Stein [Thu, 23 Aug 2001 13:26:37 +0000 (13:26 +0000)]
Simplify the version handling some more by breaking the release process out
of the makefile into a separate script -- the script can do much more and
the makefile dependencies were not used anyways (just serving to obfuscate).
Greg Stein [Thu, 23 Aug 2001 11:27:26 +0000 (11:27 +0000)]
* stop using aclocal.m4 and directly sinclude() the .m4 files into the
configure script. don't "clean" it and remove it from .cvsignore.
Note: to avoid problems in developer dirs, we nuke the file in
buildconf.sh for now; we'll stop doing that at some future time.
[idea from ASF]
* look for glibtoolize, in addition to libtoolize (e.g. the MacOS X platform
names it differently). [patch from ASF]
* conftools/missing is not needed
* use "exit 0" in buildconf.sh to help calling scripts. [patch from ASF]
Added a note to the XML_GetCurrentByteCount() function that it returns 0
for the end tag event when an empty-element tag is used. Noted on
expat-discuss by Michael Isard.
Remove all traces of the XMLCALLBACK macro -- there appears to be no way
to add __cdecl to a typedef of a function type that MSVC does not complain
about. Callback implementations may need to add explicit __cdecl
annotations in sources not compiled with the C calling convention as the
default.
Make sure that XMLPARSEAPI specifies the calling convention when building
under MSVC -- this is needed when using the pre-compiled DLL with projects
built using a different calling convention.
XMLPARSEAPI now takes the return type as a parameter and inserts annotations
on both sides of the type to make sure the compiler is happy. A new
macro, XMLCALLBACK, is used to perform similar annotation of the callback
function types, which do not need the dllimport/dllexport annotations but
do still need the __cdecl annotation.