fixing #307823 and a couple of assorted bugs fixed conditionals in

* testapi.c runsuite.c runtest.c: fixing #307823 and a couple of
  assorted bugs
* python/generator.py python/libxml2-python-api.xml: fixed
  conditionals in generator too
* doc/apibuild.py doc/libxml2-api.xml doc/* elfgcchack.h: some
  cleanups too and rebuilt
Daniel
diff --git a/runsuite.c b/runsuite.c
index 2ec4ffb..23e98a5 100644
--- a/runsuite.c
+++ b/runsuite.c
@@ -19,6 +19,7 @@
 #include <libxml/parserInternals.h>
 #include <libxml/tree.h>
 #include <libxml/uri.h>
+#if defined(LIBXML_SCHEMAS_ENABLED) && defined(LIBXML_XPATH_ENABLED)
 #include <libxml/xmlreader.h>
 
 #include <libxml/xpath.h>
@@ -1099,3 +1100,9 @@
 
     return(ret);
 }
+#else /* !SCHEMAS */
+int
+main(int argc ATTRIBUTE_UNUSED, char **argv ATTRIBUTE_UNUSED) {
+    fprintf(stderr, "runsuite requires support for schemas and xpath in libxml2\n");
+}
+#endif