about summary refs log tree commit diff stats
path: root/src
diff options
context:
space:
mode:
authorptitSeb <sebastien.chev@gmail.com>2022-12-31 14:31:07 +0100
committerptitSeb <sebastien.chev@gmail.com>2022-12-31 14:31:07 +0100
commit3d3ab0fedc2b98f7adb84e898ffb32f24a2a1a6a (patch)
treeb4c6edd5099134b83817405c1a41ca3ad1926441 /src
parentd21efb51ce3e8f9db18b3a023298372007696f92 (diff)
downloadbox64-3d3ab0fedc2b98f7adb84e898ffb32f24a2a1a6a.tar.gz
box64-3d3ab0fedc2b98f7adb84e898ffb32f24a2a1a6a.zip
Added a bunch of libexpat wrapped function (for Heroic Launcher / Legendary)
Diffstat (limited to 'src')
-rw-r--r--src/wrapped/generated/functions_list.txt23
-rw-r--r--src/wrapped/generated/wrappedexpattypes.h25
-rwxr-xr-xsrc/wrapped/wrappedexpat.c600
-rwxr-xr-xsrc/wrapped/wrappedexpat_private.h86
4 files changed, 690 insertions, 44 deletions
diff --git a/src/wrapped/generated/functions_list.txt b/src/wrapped/generated/functions_list.txt
index 87ec1b7f..d5f5a5a3 100644
--- a/src/wrapped/generated/functions_list.txt
+++ b/src/wrapped/generated/functions_list.txt
@@ -2362,9 +2362,32 @@ wrappeddbusglib1:
   - dbus_g_proxy_begin_call_with_timeout
 wrappedexpat:
 - vFpp:
+  - XML_SetAttlistDeclHandler
   - XML_SetCharacterDataHandler
+  - XML_SetCommentHandler
+  - XML_SetDefaultHandler
+  - XML_SetDefaultHandlerExpand
+  - XML_SetElementDeclHandler
+  - XML_SetEndCdataSectionHandler
+  - XML_SetEndDoctypeDeclHandler
+  - XML_SetEndElementHandler
+  - XML_SetEndNamespaceDeclHandler
+  - XML_SetEntityDeclHandler
+  - XML_SetExternalEntityRefHandler
+  - XML_SetNotStandaloneHandler
+  - XML_SetNotationDeclHandler
+  - XML_SetProcessingInstructionHandler
+  - XML_SetSkippedEntityHandler
+  - XML_SetStartCdataSectionHandler
+  - XML_SetStartDoctypeDeclHandler
+  - XML_SetStartElementHandler
+  - XML_SetStartNamespaceDeclHandler
+  - XML_SetUnparsedEntityDeclHandler
+  - XML_SetXmlDeclHandler
 - vFppp:
   - XML_SetElementHandler
+  - XML_SetNamespaceDeclHandler
+  - XML_SetUnknownEncodingHandler
 wrappedfaudio:
 - vFpp:
   - FAudio_UnregisterForCallbacks
diff --git a/src/wrapped/generated/wrappedexpattypes.h b/src/wrapped/generated/wrappedexpattypes.h
index 132b46b2..7abf2030 100644
--- a/src/wrapped/generated/wrappedexpattypes.h
+++ b/src/wrapped/generated/wrappedexpattypes.h
@@ -15,7 +15,30 @@ typedef void (*vFpp_t)(void*, void*);
 typedef void (*vFppp_t)(void*, void*, void*);
 
 #define SUPER() ADDED_FUNCTIONS() \
+	GO(XML_SetAttlistDeclHandler, vFpp_t) \
 	GO(XML_SetCharacterDataHandler, vFpp_t) \
-	GO(XML_SetElementHandler, vFppp_t)
+	GO(XML_SetCommentHandler, vFpp_t) \
+	GO(XML_SetDefaultHandler, vFpp_t) \
+	GO(XML_SetDefaultHandlerExpand, vFpp_t) \
+	GO(XML_SetElementDeclHandler, vFpp_t) \
+	GO(XML_SetEndCdataSectionHandler, vFpp_t) \
+	GO(XML_SetEndDoctypeDeclHandler, vFpp_t) \
+	GO(XML_SetEndElementHandler, vFpp_t) \
+	GO(XML_SetEndNamespaceDeclHandler, vFpp_t) \
+	GO(XML_SetEntityDeclHandler, vFpp_t) \
+	GO(XML_SetExternalEntityRefHandler, vFpp_t) \
+	GO(XML_SetNotStandaloneHandler, vFpp_t) \
+	GO(XML_SetNotationDeclHandler, vFpp_t) \
+	GO(XML_SetProcessingInstructionHandler, vFpp_t) \
+	GO(XML_SetSkippedEntityHandler, vFpp_t) \
+	GO(XML_SetStartCdataSectionHandler, vFpp_t) \
+	GO(XML_SetStartDoctypeDeclHandler, vFpp_t) \
+	GO(XML_SetStartElementHandler, vFpp_t) \
+	GO(XML_SetStartNamespaceDeclHandler, vFpp_t) \
+	GO(XML_SetUnparsedEntityDeclHandler, vFpp_t) \
+	GO(XML_SetXmlDeclHandler, vFpp_t) \
+	GO(XML_SetElementHandler, vFppp_t) \
+	GO(XML_SetNamespaceDeclHandler, vFppp_t) \
+	GO(XML_SetUnknownEncodingHandler, vFppp_t)
 
 #endif // __wrappedexpatTYPES_H_
diff --git a/src/wrapped/wrappedexpat.c b/src/wrapped/wrappedexpat.c
index 58127004..4891e375 100755
--- a/src/wrapped/wrappedexpat.c
+++ b/src/wrapped/wrappedexpat.c
@@ -98,6 +98,490 @@ static void* find_CharData_Fct(void* fct)
     printf_log(LOG_NONE, "Warning, no more slot for expat CharData callback\n");
     return NULL;
 }
+// StartNamespaceDecl ...
+#define GO(A)   \
+static uintptr_t my_StartNamespaceDecl_fct_##A = 0;                                 \
+static void my_StartNamespaceDecl_##A(void* data, void* name, void* attr)           \
+{                                                                               \
+    RunFunction(my_context, my_StartNamespaceDecl_fct_##A, 3, data, name, attr);    \
+}
+SUPER()
+#undef GO
+static void* find_StartNamespaceDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_StartNamespaceDecl_fct_##A == (uintptr_t)fct) return my_StartNamespaceDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_StartNamespaceDecl_fct_##A == 0) {my_StartNamespaceDecl_fct_##A = (uintptr_t)fct; return my_StartNamespaceDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat StartNamespaceDecl callback\n");
+    return NULL;
+}
+// EndNamespaceDecl ...
+#define GO(A)   \
+static uintptr_t my_EndNamespaceDecl_fct_##A = 0;                       \
+static void my_EndNamespaceDecl_##A(void* data, void* name)             \
+{                                                          \
+    RunFunction(my_context, my_EndNamespaceDecl_fct_##A, 2, data, name);\
+}
+SUPER()
+#undef GO
+static void* find_EndNamespaceDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_EndNamespaceDecl_fct_##A == (uintptr_t)fct) return my_EndNamespaceDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_EndNamespaceDecl_fct_##A == 0) {my_EndNamespaceDecl_fct_##A = (uintptr_t)fct; return my_EndNamespaceDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat EndNamespaceDecl callback\n");
+    return NULL;
+}
+// StartElement ...
+#define GO(A)   \
+static uintptr_t my_StartElement_fct_##A = 0;                                 \
+static void my_StartElement_##A(void* data, void* name, void* attr)           \
+{                                                                               \
+    RunFunction(my_context, my_StartElement_fct_##A, 3, data, name, attr);    \
+}
+SUPER()
+#undef GO
+static void* find_StartElement_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_StartElement_fct_##A == (uintptr_t)fct) return my_StartElement_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_StartElement_fct_##A == 0) {my_StartElement_fct_##A = (uintptr_t)fct; return my_StartElement_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat StartElement callback\n");
+    return NULL;
+}
+// EndElement ...
+#define GO(A)   \
+static uintptr_t my_EndElement_fct_##A = 0;                       \
+static void my_EndElement_##A(void* data, void* name)             \
+{                                                          \
+    RunFunction(my_context, my_EndElement_fct_##A, 2, data, name);\
+}
+SUPER()
+#undef GO
+static void* find_EndElement_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_EndElement_fct_##A == (uintptr_t)fct) return my_EndElement_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_EndElement_fct_##A == 0) {my_EndElement_fct_##A = (uintptr_t)fct; return my_EndElement_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat EndElement callback\n");
+    return NULL;
+}
+// CharacterData ...
+#define GO(A)   \
+static uintptr_t my_CharacterData_fct_##A = 0;                              \
+static void my_CharacterData_##A(void* data, void* name, int len)           \
+{                                                                           \
+    RunFunction(my_context, my_CharacterData_fct_##A, 3, data, name, len);  \
+}
+SUPER()
+#undef GO
+static void* find_CharacterData_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_CharacterData_fct_##A == (uintptr_t)fct) return my_CharacterData_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_CharacterData_fct_##A == 0) {my_CharacterData_fct_##A = (uintptr_t)fct; return my_CharacterData_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat CharacterData callback\n");
+    return NULL;
+}
+// ProcessingInstruction ...
+#define GO(A)   \
+static uintptr_t my_ProcessingInstruction_fct_##A = 0;                      \
+static void my_ProcessingInstruction_##A(void* a, void* b, void* c)         \
+{                                                                           \
+    RunFunction(my_context, my_ProcessingInstruction_fct_##A, 3, a, b, c);  \
+}
+SUPER()
+#undef GO
+static void* find_ProcessingInstruction_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_ProcessingInstruction_fct_##A == (uintptr_t)fct) return my_ProcessingInstruction_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_ProcessingInstruction_fct_##A == 0) {my_ProcessingInstruction_fct_##A = (uintptr_t)fct; return my_ProcessingInstruction_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat ProcessingInstruction callback\n");
+    return NULL;
+}
+// Comment ...
+#define GO(A)   \
+static uintptr_t my_Comment_fct_##A = 0;                    \
+static void my_Comment_##A(void* a, void* b)                \
+{                                                           \
+    RunFunction(my_context, my_Comment_fct_##A, 2, a, b);   \
+}
+SUPER()
+#undef GO
+static void* find_Comment_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_Comment_fct_##A == (uintptr_t)fct) return my_Comment_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_Comment_fct_##A == 0) {my_Comment_fct_##A = (uintptr_t)fct; return my_Comment_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat Comment callback\n");
+    return NULL;
+}
+// StartCdataSection ...
+#define GO(A)   \
+static uintptr_t my_StartCdataSection_fct_##A = 0;                     \
+static void my_StartCdataSection_##A(void* data)                       \
+{                                                                      \
+    RunFunction(my_context, my_StartCdataSection_fct_##A, 1, data);    \
+}
+SUPER()
+#undef GO
+static void* find_StartCdataSection_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_StartCdataSection_fct_##A == (uintptr_t)fct) return my_StartCdataSection_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_StartCdataSection_fct_##A == 0) {my_StartCdataSection_fct_##A = (uintptr_t)fct; return my_StartCdataSection_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat StartCdataSection callback\n");
+    return NULL;
+}
+// EndCdataSection ...
+#define GO(A)   \
+static uintptr_t my_EndCdataSection_fct_##A = 0;                   \
+static void my_EndCdataSection_##A(void* data)                     \
+{                                                                  \
+    RunFunction(my_context, my_EndCdataSection_fct_##A, 1, data);  \
+}
+SUPER()
+#undef GO
+static void* find_EndCdataSection_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_EndCdataSection_fct_##A == (uintptr_t)fct) return my_EndCdataSection_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_EndCdataSection_fct_##A == 0) {my_EndCdataSection_fct_##A = (uintptr_t)fct; return my_EndCdataSection_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat EndCdataSection callback\n");
+    return NULL;
+}
+// Default ...
+#define GO(A)   \
+static uintptr_t my_Default_fct_##A = 0;                              \
+static void my_Default_##A(void* data, void* name, int len)           \
+{                                                                     \
+    RunFunction(my_context, my_Default_fct_##A, 3, data, name, len);  \
+}
+SUPER()
+#undef GO
+static void* find_Default_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_Default_fct_##A == (uintptr_t)fct) return my_Default_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_Default_fct_##A == 0) {my_Default_fct_##A = (uintptr_t)fct; return my_Default_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat Default callback\n");
+    return NULL;
+}
+// StartDoctypeDecl ...
+#define GO(A)   \
+static uintptr_t my_StartDoctypeDecl_fct_##A = 0;                               \
+static void my_StartDoctypeDecl_##A(void* a, void* b, void* c, void* d, int e)  \
+{                                                                               \
+    RunFunction(my_context, my_StartDoctypeDecl_fct_##A, 5, a, b, c, d, e);     \
+}
+SUPER()
+#undef GO
+static void* find_StartDoctypeDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_StartDoctypeDecl_fct_##A == (uintptr_t)fct) return my_StartDoctypeDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_StartDoctypeDecl_fct_##A == 0) {my_StartDoctypeDecl_fct_##A = (uintptr_t)fct; return my_StartDoctypeDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat StartDoctypeDecl callback\n");
+    return NULL;
+}
+// EndDoctypeDecl ...
+#define GO(A)   \
+static uintptr_t my_EndDoctypeDecl_fct_##A = 0;                     \
+static void my_EndDoctypeDecl_##A(void* data)                       \
+{                                                                   \
+    RunFunction(my_context, my_EndDoctypeDecl_fct_##A, 1, data);    \
+}
+SUPER()
+#undef GO
+static void* find_EndDoctypeDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_EndDoctypeDecl_fct_##A == (uintptr_t)fct) return my_EndDoctypeDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_EndDoctypeDecl_fct_##A == 0) {my_EndDoctypeDecl_fct_##A = (uintptr_t)fct; return my_EndDoctypeDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat EndDoctypeDecl callback\n");
+    return NULL;
+}
+// EntityDecl ...
+#define GO(A)   \
+static uintptr_t my_EntityDecl_fct_##A = 0;                                                                 \
+static void my_EntityDecl_##A(void* a, void* b, int c, void* d, int e, void* f, void* g, void* h, void* i)  \
+{                                                                                                           \
+    RunFunction(my_context, my_EntityDecl_fct_##A, 9, a, b, c, d, e, f, g, h, i);                           \
+}
+SUPER()
+#undef GO
+static void* find_EntityDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_EntityDecl_fct_##A == (uintptr_t)fct) return my_EntityDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_EntityDecl_fct_##A == 0) {my_EntityDecl_fct_##A = (uintptr_t)fct; return my_EntityDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat EntityDecl callback\n");
+    return NULL;
+}
+// ElementDecl ...
+#define GO(A)   \
+static uintptr_t my_ElementDecl_fct_##A = 0;                        \
+static void my_ElementDecl_##A(void* a, void* b, void* c)           \
+{                                                                   \
+    RunFunction(my_context, my_ElementDecl_fct_##A, 3, a, b, c);    \
+}
+SUPER()
+#undef GO
+static void* find_ElementDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_ElementDecl_fct_##A == (uintptr_t)fct) return my_ElementDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_ElementDecl_fct_##A == 0) {my_ElementDecl_fct_##A = (uintptr_t)fct; return my_ElementDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat ElementDecl callback\n");
+    return NULL;
+}
+// UnknownEncoding ...
+#define GO(A)   \
+static uintptr_t my_UnknownEncoding_fct_##A = 0;                                    \
+static int my_UnknownEncoding_##A(void* a, void* b, void* c)                        \
+{                                                                                   \
+    return (int)RunFunction(my_context, my_UnknownEncoding_fct_##A, 3, a, b, c);    \
+}
+SUPER()
+#undef GO
+static void* find_UnknownEncoding_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_UnknownEncoding_fct_##A == (uintptr_t)fct) return my_UnknownEncoding_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_UnknownEncoding_fct_##A == 0) {my_UnknownEncoding_fct_##A = (uintptr_t)fct; return my_UnknownEncoding_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat UnknownEncoding callback\n");
+    return NULL;
+}
+// UnparsedEntityDecl ...
+#define GO(A)   \
+static uintptr_t my_UnparsedEntityDecl_fct_##A = 0;                                         \
+static void my_UnparsedEntityDecl_##A(void* a, void* b, void* c, void* d, void* e, void* f) \
+{                                                                                           \
+    RunFunction(my_context, my_UnparsedEntityDecl_fct_##A, 6, a, b, c, d, e, f);            \
+}
+SUPER()
+#undef GO
+static void* find_UnparsedEntityDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_UnparsedEntityDecl_fct_##A == (uintptr_t)fct) return my_UnparsedEntityDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_UnparsedEntityDecl_fct_##A == 0) {my_UnparsedEntityDecl_fct_##A = (uintptr_t)fct; return my_UnparsedEntityDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat UnparsedEntityDecl callback\n");
+    return NULL;
+}
+// NotationDecl ...
+#define GO(A)   \
+static uintptr_t my_NotationDecl_fct_##A = 0;                                   \
+static void my_NotationDecl_##A(void* a, void* b, void* c, void* d, void* e)    \
+{                                                                               \
+    RunFunction(my_context, my_NotationDecl_fct_##A, 5, a, b, c, d, e);         \
+}
+SUPER()
+#undef GO
+static void* find_NotationDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_NotationDecl_fct_##A == (uintptr_t)fct) return my_NotationDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_NotationDecl_fct_##A == 0) {my_NotationDecl_fct_##A = (uintptr_t)fct; return my_NotationDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat NotationDecl callback\n");
+    return NULL;
+}
+// NotStandalone ...
+#define GO(A)   \
+static uintptr_t my_NotStandalone_fct_##A = 0;                              \
+static int my_NotStandalone_##A(void* data)                                 \
+{                                                                           \
+    return (int)RunFunction(my_context, my_NotStandalone_fct_##A, 1, data); \
+}
+SUPER()
+#undef GO
+static void* find_NotStandalone_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_NotStandalone_fct_##A == (uintptr_t)fct) return my_NotStandalone_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_NotStandalone_fct_##A == 0) {my_NotStandalone_fct_##A = (uintptr_t)fct; return my_NotStandalone_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat NotStandalone callback\n");
+    return NULL;
+}
+// ExternalEntityRef ...
+#define GO(A)   \
+static uintptr_t my_ExternalEntityRef_fct_##A = 0;                                          \
+static int my_ExternalEntityRef_##A(void* a, void* b, void* c, void* d, void* e)            \
+{                                                                                           \
+    return (int)RunFunction(my_context, my_ExternalEntityRef_fct_##A, 5, a, b, c, d, e);    \
+}
+SUPER()
+#undef GO
+static void* find_ExternalEntityRef_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_ExternalEntityRef_fct_##A == (uintptr_t)fct) return my_ExternalEntityRef_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_ExternalEntityRef_fct_##A == 0) {my_ExternalEntityRef_fct_##A = (uintptr_t)fct; return my_ExternalEntityRef_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat ExternalEntityRef callback\n");
+    return NULL;
+}
+// XmlDecl ...
+#define GO(A)   \
+static uintptr_t my_XmlDecl_fct_##A = 0;                        \
+static void my_XmlDecl_##A(void* a, void* b, void* c, int d)    \
+{                                                               \
+    RunFunction(my_context, my_XmlDecl_fct_##A, 4, a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_XmlDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_XmlDecl_fct_##A == (uintptr_t)fct) return my_XmlDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_XmlDecl_fct_##A == 0) {my_XmlDecl_fct_##A = (uintptr_t)fct; return my_XmlDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat XmlDecl callback\n");
+    return NULL;
+}
+// AttlistDecl ...
+#define GO(A)   \
+static uintptr_t my_AttlistDecl_fct_##A = 0;                                        \
+static void my_AttlistDecl_##A(void* a, void* b, void* c, void* d, void* e, int f)  \
+{                                                                                   \
+    RunFunction(my_context, my_AttlistDecl_fct_##A, 6, a, b, c, d, e, f);           \
+}
+SUPER()
+#undef GO
+static void* find_AttlistDecl_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_AttlistDecl_fct_##A == (uintptr_t)fct) return my_AttlistDecl_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_AttlistDecl_fct_##A == 0) {my_AttlistDecl_fct_##A = (uintptr_t)fct; return my_AttlistDecl_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat AttlistDecl callback\n");
+    return NULL;
+}
+// SkippedEntity ...
+#define GO(A)   \
+static uintptr_t my_SkippedEntity_fct_##A = 0;                      \
+static void my_SkippedEntity_##A(void* a, void* b, int c)           \
+{                                                                   \
+    RunFunction(my_context, my_SkippedEntity_fct_##A, 3, a, b, c);  \
+}
+SUPER()
+#undef GO
+static void* find_SkippedEntity_Fct(void* fct)
+{
+    if(!fct) return fct;
+    if(GetNativeFnc((uintptr_t)fct))  return GetNativeFnc((uintptr_t)fct);
+    #define GO(A) if(my_SkippedEntity_fct_##A == (uintptr_t)fct) return my_SkippedEntity_##A;
+    SUPER()
+    #undef GO
+    #define GO(A) if(my_SkippedEntity_fct_##A == 0) {my_SkippedEntity_fct_##A = (uintptr_t)fct; return my_SkippedEntity_##A; }
+    SUPER()
+    #undef GO
+    printf_log(LOG_NONE, "Warning, no more slot for expat SkippedEntity callback\n");
+    return NULL;
+}
 #undef SUPER
 
 EXPORT void my_XML_SetElementHandler(x64emu_t* emu, void* p, void* start, void* end)
@@ -110,6 +594,122 @@ EXPORT void my_XML_SetCharacterDataHandler(x64emu_t* emu, void* p, void* h)
     my->XML_SetCharacterDataHandler(p, find_CharData_Fct(h));
 }
 
+EXPORT void my_XML_SetNamespaceDeclHandler(x64emu_t* emu, void* p, void* start, void* end)
+{
+    my->XML_SetNamespaceDeclHandler(p, find_StartNamespaceDecl_Fct(start), find_EndNamespaceDecl_Fct(end));
+}
+
+EXPORT void my_XML_SetEntityDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetEntityDeclHandler(p, find_EntityDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetStartDoctypeDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetStartDoctypeDeclHandler(p, find_StartDoctypeDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetEndDoctypeDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetEndDoctypeDeclHandler(p, find_EndDoctypeDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetElementDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetElementDeclHandler(p, find_ElementDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetDefaultHandlerExpand(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetDefaultHandlerExpand(p, find_Default_Fct(f));
+}
+
+EXPORT void my_XML_SetCommentHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetCommentHandler(p, find_Comment_Fct(f));
+}
+
+EXPORT void my_XML_SetProcessingInstructionHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetProcessingInstructionHandler(p, find_ProcessingInstruction_Fct(f));
+}
+
+EXPORT void my_XML_SetStartElementHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetStartElementHandler(p, find_StartElement_Fct(f));
+}
+
+EXPORT void my_XML_SetEndElementHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetEndElementHandler(p, find_EndElement_Fct(f));
+}
+
+EXPORT void my_XML_SetUnknownEncodingHandler(x64emu_t* emu, void* p, void* f, void* d)
+{
+    my->XML_SetUnknownEncodingHandler(p, find_UnknownEncoding_Fct(f), d);
+}
+
+EXPORT void my_XML_SetUnparsedEntityDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetUnparsedEntityDeclHandler(p, find_UnparsedEntityDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetNotationDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetNotationDeclHandler(p, find_NotationDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetStartNamespaceDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetStartNamespaceDeclHandler(p, find_StartNamespaceDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetEndNamespaceDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetEndNamespaceDeclHandler(p, find_EndNamespaceDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetStartCdataSectionHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetStartCdataSectionHandler(p, find_StartCdataSection_Fct(f));
+}
+
+EXPORT void my_XML_SetEndCdataSectionHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetEndCdataSectionHandler(p, find_EndCdataSection_Fct(f));
+}
+
+EXPORT void my_XML_SetDefaultHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetDefaultHandler(p, find_Default_Fct(f));
+}
+
+EXPORT void my_XML_SetNotStandaloneHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetNotStandaloneHandler(p, find_NotStandalone_Fct(f));
+}
+
+EXPORT void my_XML_SetExternalEntityRefHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetExternalEntityRefHandler(p, find_ExternalEntityRef_Fct(f));
+}
+
+EXPORT void my_XML_SetXmlDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetXmlDeclHandler(p, find_XmlDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetAttlistDeclHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetAttlistDeclHandler(p, find_AttlistDecl_Fct(f));
+}
+
+EXPORT void my_XML_SetSkippedEntityHandler(x64emu_t* emu, void* p, void* f)
+{
+    my->XML_SetSkippedEntityHandler(p, find_SkippedEntity_Fct(f));
+}
+
+
 #define CUSTOM_INIT \
     getMy(lib);
 
diff --git a/src/wrapped/wrappedexpat_private.h b/src/wrapped/wrappedexpat_private.h
index 0fe1ba80..c57ad352 100755
--- a/src/wrapped/wrappedexpat_private.h
+++ b/src/wrapped/wrappedexpat_private.h
@@ -5,67 +5,67 @@
 //GO(_INTERNAL_trim_to_complete_utf8_characters, 
 //GO(XML_DefaultCurrent, 
 GO(XML_ErrorString, pFi)
-//GO(XML_ExpatVersion, 
-//GO(XML_ExpatVersionInfo, 
-//GO(XML_ExternalEntityParserCreate, 
-//GO(XML_FreeContentModel, 
-//GO(XML_GetBase, 
-//GO(XML_GetBuffer, 
+GO(XML_ExpatVersion, pFv)
+GO(XML_ExpatVersionInfo, pFp)   // return a struct of 3 int. Use shadow pointer on ARM64 and x86_64
+GO(XML_ExternalEntityParserCreate, pFppp)
+GO(XML_FreeContentModel, vFpp)
+GO(XML_GetBase, pFp)
+GO(XML_GetBuffer, pFpi)
 //GO(XML_GetCurrentByteCount, 
-//GO(XML_GetCurrentByteIndex, 
-//GO(XML_GetCurrentColumnNumber, 
+GO(XML_GetCurrentByteIndex, lFp)
+GO(XML_GetCurrentColumnNumber, LFp)
 GO(XML_GetCurrentLineNumber, iFp)
 GO(XML_GetErrorCode, iFp)
-//GO(XML_GetFeatureList, 
+GO(XML_GetFeatureList, pFv)
 //GO(XML_GetIdAttributeIndex, 
-//GO(XML_GetInputContext, 
+GO(XML_GetInputContext, pFppp)
 //GO(XML_GetParsingStatus, 
-//GO(XML_GetSpecifiedAttributeCount, 
+GO(XML_GetSpecifiedAttributeCount, iFp)
 //GO(XML_MemFree, 
 //GO(XML_MemMalloc, 
 //GO(XML_MemRealloc, 
 GO(XML_Parse, iFppii)
-//GO(XML_ParseBuffer, 
+GO(XML_ParseBuffer, iFpii)
 GO(XML_ParserCreate, pFp)
-//GO(XML_ParserCreate_MM, 
+GO(XML_ParserCreate_MM, pFpppp) // return a structure
 //GO(XML_ParserCreateNS, 
 GO(XML_ParserFree, vFp)
 //GO(XML_ParserReset, 
 //GO(XML_ResumeParser, 
-//GO(XML_SetAttlistDeclHandler, 
-//GO(XML_SetBase, 
+GOM(XML_SetAttlistDeclHandler, vFEpp)
+GO(XML_SetBase, iFpp)
 //GO(XML_SetCdataSectionHandler, 
 GOM(XML_SetCharacterDataHandler, vFEpp)
-//GO(XML_SetCommentHandler, 
-//GO(XML_SetDefaultHandler, 
-//GO(XML_SetDefaultHandlerExpand, 
+GOM(XML_SetCommentHandler, vFEpp)
+GOM(XML_SetDefaultHandler, vFEpp)
+GOM(XML_SetDefaultHandlerExpand, vFEpp)
 //GO(XML_SetDoctypeDeclHandler, 
-//GO(XML_SetElementDeclHandler, 
+GOM(XML_SetElementDeclHandler, vFEpp)
 GOM(XML_SetElementHandler, vFEppp)
-//GO(XML_SetEncoding, 
-//GO(XML_SetEndCdataSectionHandler, 
-//GO(XML_SetEndDoctypeDeclHandler, 
-//GO(XML_SetEndElementHandler, 
-//GO(XML_SetEndNamespaceDeclHandler, 
-//GO(XML_SetEntityDeclHandler, 
-//GO(XML_SetExternalEntityRefHandler, 
+GO(XML_SetEncoding, iFpp)
+GOM(XML_SetEndCdataSectionHandler, vFEpp)
+GOM(XML_SetEndDoctypeDeclHandler, vFEpp)
+GOM(XML_SetEndElementHandler, vFEpp)
+GOM(XML_SetEndNamespaceDeclHandler, vFEpp)
+GOM(XML_SetEntityDeclHandler, vFEpp)
+GOM(XML_SetExternalEntityRefHandler, vFEpp)
 //GO(XML_SetExternalEntityRefHandlerArg, 
-//GO(XML_SetHashSalt, 
-//GO(XML_SetNamespaceDeclHandler, 
-//GO(XML_SetNotationDeclHandler, 
-//GO(XML_SetNotStandaloneHandler, 
-//GO(XML_SetParamEntityParsing, 
-//GO(XML_SetProcessingInstructionHandler, 
-//GO(XML_SetReturnNSTriplet, 
-//GO(XML_SetSkippedEntityHandler, 
-//GO(XML_SetStartCdataSectionHandler, 
-//GO(XML_SetStartDoctypeDeclHandler, 
-//GO(XML_SetStartElementHandler, 
-//GO(XML_SetStartNamespaceDeclHandler, 
-//GO(XML_SetUnknownEncodingHandler, 
-//GO(XML_SetUnparsedEntityDeclHandler, 
+GO(XML_SetHashSalt, iFpL)
+GOM(XML_SetNamespaceDeclHandler, vFEppp)
+GOM(XML_SetNotationDeclHandler, vFEpp)
+GOM(XML_SetNotStandaloneHandler, vFEpp)
+GO(XML_SetParamEntityParsing, iFpi)
+GOM(XML_SetProcessingInstructionHandler, vFEpp)
+GO(XML_SetReturnNSTriplet, vFpi)
+GOM(XML_SetSkippedEntityHandler, vFEpp)
+GOM(XML_SetStartCdataSectionHandler, vFEpp)
+GOM(XML_SetStartDoctypeDeclHandler, vFEpp)
+GOM(XML_SetStartElementHandler, vFEpp)
+GOM(XML_SetStartNamespaceDeclHandler, vFEpp)
+GOM(XML_SetUnknownEncodingHandler, vFEppp)
+GOM(XML_SetUnparsedEntityDeclHandler, vFEpp)
 GO(XML_SetUserData, vFpp)
-//GO(XML_SetXmlDeclHandler, 
-//GO(XML_StopParser, 
-//GO(XML_UseForeignDTD, 
+GOM(XML_SetXmlDeclHandler, vFEpp)
+GO(XML_StopParser, iFpi)
+GO(XML_UseForeignDTD, iFpi)
 //GO(XML_UseParserAsHandlerArg,