make the allocation be per-thread a configure option fixed compilation

* include/libxml/globals.h configure.in global.data: make
  the allocation be per-thread a configure option
* encoding.c include/libxml/parser.h: fixed compilation
  errors
Daniel
diff --git a/encoding.c b/encoding.c
index 781d8da..a9495c4 100644
--- a/encoding.c
+++ b/encoding.c
@@ -44,6 +44,7 @@
 #include <libxml/HTMLparser.h>
 #endif
 #include <libxml/xmlerror.h>
+#include <libxml/globals.h>
 
 static xmlCharEncodingHandlerPtr xmlUTF16LEHandler = NULL;
 static xmlCharEncodingHandlerPtr xmlUTF16BEHandler = NULL;