mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-10-24 13:33:01 +03:00
build: Add separate configuration option for RELAX NG
Support for RELAX NG used to be enabled together with XML Schema support (--with-schemas). Now there's a separate option and a new feature macro LIBXML_RELAXNG_ENABLED.
This commit is contained in:
46
testapi.c
46
testapi.c
@@ -142,7 +142,7 @@ int main(int argc, char **argv) {
|
||||
#ifdef LIBXML_CATALOG_ENABLED
|
||||
xmlInitializeCatalog();
|
||||
#endif
|
||||
#ifdef LIBXML_SCHEMAS_ENABLED
|
||||
#ifdef LIBXML_RELAXNG_ENABLED
|
||||
xmlRelaxNGInitTypes();
|
||||
#endif
|
||||
|
||||
@@ -852,6 +852,8 @@ static void desret_xmlSchemaParserCtxtPtr(xmlSchemaParserCtxtPtr val) {
|
||||
}
|
||||
static void desret_xmlSchemaTypePtr(xmlSchemaTypePtr val ATTRIBUTE_UNUSED) {
|
||||
}
|
||||
#endif
|
||||
#ifdef LIBXML_RELAXNG_ENABLED
|
||||
static void desret_xmlRelaxNGParserCtxtPtr(xmlRelaxNGParserCtxtPtr val) {
|
||||
xmlRelaxNGFreeParserCtxt(val);
|
||||
}
|
||||
@@ -17535,7 +17537,7 @@ static int
|
||||
test_xmlRelaxNGDump(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED) && defined(LIBXML_OUTPUT_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED) && defined(LIBXML_OUTPUT_ENABLED)
|
||||
int mem_base;
|
||||
FILE * output; /* the file output */
|
||||
int n_output;
|
||||
@@ -17574,7 +17576,7 @@ static int
|
||||
test_xmlRelaxNGDumpTree(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED) && defined(LIBXML_OUTPUT_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED) && defined(LIBXML_OUTPUT_ENABLED)
|
||||
int mem_base;
|
||||
FILE * output; /* the file output */
|
||||
int n_output;
|
||||
@@ -17608,21 +17610,21 @@ test_xmlRelaxNGDumpTree(void) {
|
||||
return(test_ret);
|
||||
}
|
||||
|
||||
#ifdef LIBXML_SCHEMAS_ENABLED
|
||||
#ifdef LIBXML_RELAXNG_ENABLED
|
||||
|
||||
#define gen_nb_xmlRelaxNGParserCtxtPtr 1
|
||||
#define gen_xmlRelaxNGParserCtxtPtr(no, nr) NULL
|
||||
#define des_xmlRelaxNGParserCtxtPtr(no, val, nr)
|
||||
#endif
|
||||
|
||||
#ifdef LIBXML_SCHEMAS_ENABLED
|
||||
#ifdef LIBXML_RELAXNG_ENABLED
|
||||
|
||||
#define gen_nb_xmlRelaxNGValidityErrorFunc_ptr 1
|
||||
#define gen_xmlRelaxNGValidityErrorFunc_ptr(no, nr) NULL
|
||||
#define des_xmlRelaxNGValidityErrorFunc_ptr(no, val, nr)
|
||||
#endif
|
||||
|
||||
#ifdef LIBXML_SCHEMAS_ENABLED
|
||||
#ifdef LIBXML_RELAXNG_ENABLED
|
||||
|
||||
#define gen_nb_xmlRelaxNGValidityWarningFunc_ptr 1
|
||||
#define gen_xmlRelaxNGValidityWarningFunc_ptr(no, nr) NULL
|
||||
@@ -17634,7 +17636,7 @@ static int
|
||||
test_xmlRelaxNGGetParserErrors(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlRelaxNGParserCtxtPtr ctxt; /* a Relax-NG validation context */
|
||||
@@ -17684,7 +17686,7 @@ test_xmlRelaxNGGetParserErrors(void) {
|
||||
return(test_ret);
|
||||
}
|
||||
|
||||
#ifdef LIBXML_SCHEMAS_ENABLED
|
||||
#ifdef LIBXML_RELAXNG_ENABLED
|
||||
|
||||
#define gen_nb_xmlRelaxNGValidCtxtPtr 1
|
||||
#define gen_xmlRelaxNGValidCtxtPtr(no, nr) NULL
|
||||
@@ -17696,7 +17698,7 @@ static int
|
||||
test_xmlRelaxNGGetValidErrors(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlRelaxNGValidCtxtPtr ctxt; /* a Relax-NG validation context */
|
||||
@@ -17751,7 +17753,7 @@ static int
|
||||
test_xmlRelaxNGInitTypes(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
|
||||
@@ -17778,7 +17780,7 @@ static int
|
||||
test_xmlRelaxNGNewDocParserCtxt(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
xmlRelaxNGParserCtxtPtr ret_val;
|
||||
xmlDocPtr doc; /* a preparsed document tree */
|
||||
@@ -17812,7 +17814,7 @@ static int
|
||||
test_xmlRelaxNGNewMemParserCtxt(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
xmlRelaxNGParserCtxtPtr ret_val;
|
||||
const char * buffer; /* a pointer to a char array containing the schemas */
|
||||
@@ -17856,7 +17858,7 @@ static int
|
||||
test_xmlRelaxNGNewParserCtxt(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
xmlRelaxNGParserCtxtPtr ret_val;
|
||||
const char * URL; /* the location of the schema */
|
||||
@@ -17960,7 +17962,7 @@ static int
|
||||
test_xmlRelaxNGValidateDoc(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlRelaxNGValidCtxtPtr ctxt; /* a Relax-NG validation context */
|
||||
@@ -18001,7 +18003,7 @@ static int
|
||||
test_xmlRelaxNGValidateFullElement(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlRelaxNGValidCtxtPtr ctxt; /* the validation context */
|
||||
@@ -18049,7 +18051,7 @@ static int
|
||||
test_xmlRelaxNGValidatePopElement(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlRelaxNGValidCtxtPtr ctxt; /* the RelaxNG validation context */
|
||||
@@ -18097,7 +18099,7 @@ static int
|
||||
test_xmlRelaxNGValidatePushCData(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlRelaxNGValidCtxtPtr ctxt; /* the RelaxNG validation context */
|
||||
@@ -18148,7 +18150,7 @@ static int
|
||||
test_xmlRelaxNGValidatePushElement(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlRelaxNGValidCtxtPtr ctxt; /* the validation context */
|
||||
@@ -18196,7 +18198,7 @@ static int
|
||||
test_xmlRelaxParserSetFlag(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlRelaxNGParserCtxtPtr ctxt; /* a RelaxNG parser context */
|
||||
@@ -33080,7 +33082,7 @@ static int
|
||||
test_xmlTextReaderRelaxNGSetSchema(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_READER_ENABLED) && defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_READER_ENABLED) && defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlTextReaderPtr reader; /* the xmlTextReaderPtr used */
|
||||
@@ -33121,7 +33123,7 @@ static int
|
||||
test_xmlTextReaderRelaxNGValidate(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_READER_ENABLED) && defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_READER_ENABLED) && defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlTextReaderPtr reader; /* the xmlTextReaderPtr used */
|
||||
@@ -33162,7 +33164,7 @@ static int
|
||||
test_xmlTextReaderRelaxNGValidateCtxt(void) {
|
||||
int test_ret = 0;
|
||||
|
||||
#if defined(LIBXML_READER_ENABLED) && defined(LIBXML_SCHEMAS_ENABLED)
|
||||
#if defined(LIBXML_READER_ENABLED) && defined(LIBXML_RELAXNG_ENABLED)
|
||||
int mem_base;
|
||||
int ret_val;
|
||||
xmlTextReaderPtr reader; /* the xmlTextReaderPtr used */
|
||||
|
||||
Reference in New Issue
Block a user