On 05/01/2016 01:35 PM, Daniel Veillard wrote:
So as said a few weeks ago, I'm starting the process for a new release,
I tagged in git a release candidate 1, and pushed to the server the
signed tarball and rpms for rc1:
ftp://xmlsoft.org/xml/
So give it some testing, thanks !
Hi Daniel,
As the OS400 C compiler is not C99 compliant, local declarations can
only appear at the beginning of a block.
RC1 then fails compiling: see commit
https://git.gnome.org/browse/libxml2/commit/?id=cad102b861f74d56e3f6e710c466cf1a38a5db56,
xmlschemastypes.c, "const int stringType =" ...
Please find a patch for it in attachment.
Everything else seem OK on OS/400: compiles and runs after applying this
patch.
Regards,
Patrick
>From d176b6afddb6b8efd42a83ac77537a2a119db713 Mon Sep 17 00:00:00 2001
From: Patrick Monnerat <patrick.monne...@dh.com>
Date: Mon, 2 May 2016 17:30:21 +0200
Subject: [PATCH] xmlschemastypes.c: OS400 C compiler is not C99 compliant. It
only supports local variable declarations at the beginning of a block.
---
xmlschemastypes.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/xmlschemastypes.c b/xmlschemastypes.c
index 60f5414..093051d 100644
--- a/xmlschemastypes.c
+++ b/xmlschemastypes.c
@@ -5307,6 +5307,7 @@ xmlSchemaValidateFacetInternal(xmlSchemaFacetPtr facet,
xmlSchemaWhitespaceValueType ws)
{
int ret;
+ int stringType;
if (facet == NULL)
return(-1);
@@ -5324,8 +5325,8 @@ xmlSchemaValidateFacetInternal(xmlSchemaFacetPtr facet,
* the datatype.
* See https://www.w3.org/TR/xmlschema-2/#rf-pattern
*/
- const int stringType = val && ((val->type >= XML_SCHEMAS_STRING && val->type <= XML_SCHEMAS_NORMSTRING)
- || (val->type >= XML_SCHEMAS_TOKEN && val->type <= XML_SCHEMAS_NCNAME));
+ stringType = val && ((val->type >= XML_SCHEMAS_STRING && val->type <= XML_SCHEMAS_NORMSTRING)
+ || (val->type >= XML_SCHEMAS_TOKEN && val->type <= XML_SCHEMAS_NCNAME));
ret = xmlRegexpExec(facet->regexp,
(stringType && val->value.str) ? val->value.str : value);
if (ret == 1)
--
1.9.3
_______________________________________________
xml mailing list, project page http://xmlsoft.org/
xml@gnome.org
https://mail.gnome.org/mailman/listinfo/xml