headers MAINTENANCE headers/include cleanup

- add missing extern "C" in some of the public headers for use in C++
- includes cleanup and fix ordering
diff --git a/tests/utests/schema/test_printer_yin.c b/tests/utests/schema/test_printer_yin.c
index 9991e0f..7ab8b0e 100644
--- a/tests/utests/schema/test_printer_yin.c
+++ b/tests/utests/schema/test_printer_yin.c
@@ -18,6 +18,7 @@
 #include <cmocka.h>
 
 #include <stdio.h>
+#include <stdlib.h>
 #include <string.h>
 
 #include "../../src/context.h"
diff --git a/tests/utests/schema/test_schema.c b/tests/utests/schema/test_schema.c
index b330a7d..559b193 100644
--- a/tests/utests/schema/test_schema.c
+++ b/tests/utests/schema/test_schema.c
@@ -18,11 +18,14 @@
 #include <setjmp.h>
 #include <cmocka.h>
 
+#include <string.h>
+
 #include "../../../src/common.h"
 #include "../../../src/context.h"
+#include "../../../src/log.h"
+#include "../../../src/parser_yin.h"
 #include "../../../src/tree_schema.h"
 #include "../../../src/tree_schema_internal.h"
-#include "../../../src/parser_yin.h"
 #include "../../../src/xml.h"