Applied the last patches from Gary, cleanup, activated threading all user
* include/libxml/SAX.h include/libxml/globals.h include/libxml/parser.h
include/libxml/parserInternals.h include/libxml/tree.h
include/libxml/xmlerror.h HTMLparser.c SAX.c error.c globals.c
nanoftp.c nanohttp.c parser.c parserInternals.c testDocbook.c
testHTML.c testSAX.c tree.c uri.c xlink.c xmlmemory.c:
Applied the last patches from Gary, cleanup, activated threading
all user accessible global variables are now handled in globals.[ch]
Still a bit rought but make tests passes with either
--with-threads defined at configure time or not.
* Makefile.am example/Makefile.am: added globals.[ch] and threads
linking options
Daniel
diff --git a/build_glob.py b/build_glob.py
index fbf45c1..33856cd 100755
--- a/build_glob.py
+++ b/build_glob.py
@@ -78,9 +78,9 @@
writeline(global_functions_hdr,"(*(__"+fields[1]+"()))")
writeline(global_functions_hdr,"#else")
if len(fields) == 3:
- writeline(global_functions_hdr,"extern "+fields[0]+" "+fields[1]+fields[2]+";")
+ writeline(global_functions_hdr,"LIBXML_DLL_IMPORT extern "+fields[0]+" "+fields[1]+fields[2]+";")
else:
- writeline(global_functions_hdr,"extern "+fields[0]+" "+fields[1]+";")
+ writeline(global_functions_hdr,"LIBXML_DLL_IMPORT extern "+fields[0]+" "+fields[1]+";")
writeline(global_functions_hdr,"#endif")
# Update the implementation file
writeline(global_functions_impl)
@@ -96,7 +96,7 @@
writeline(global_functions_impl, " if (IS_MAIN_THREAD)")
writeline(global_functions_impl, "\treturn (&"+fields[1]+");")
writeline(global_functions_impl, " else")
- writeline(global_functions_impl, "\treturn (&get_glob_struct()->"+fields[1]+");")
+ writeline(global_functions_impl, "\treturn (&xmlGetGlobalState()->"+fields[1]+");")
writeline(global_functions_impl, "}")
# Terminate the header file with appropriate boilerplate
writeline(global_functions_hdr)