Opened 12 years ago
Closed 12 years ago
#10940 closed defect (fixed)
libxslt-1.1.27 breaks building on Fedora rawhide
Reported by: | sergiomb | Owned by: | |
---|---|---|---|
Component: | webservices | Version: | VirtualBox 4.2.0 |
Keywords: | Cc: | ||
Guest type: | other | Host type: | other |
Description
Fedora rawhide updated libxslt from 1.1.26 to 1.1.27 and I got this error, when I use --enable-webservice :
/usr/bin/xsltproc -o /builddir/build/BUILD/VirtualBox-4.2.0/obj/obj/webservice/typemap.dat /builddir/build/BUILD/VirtualBox-4.2.0/src/VBox/Main/webservice/websrv-typemap.xsl /builddir/build/BUILD/VirtualBox-4.2.0/obj/obj/webservice/VirtualBox.xidl compilation error: file /builddir/build/BUILD/VirtualBox-4.2.0/src/VBox/Main/webservice/websrv-wsdl.xsl line 962 element attribute xsl:attribute: The attribute name 'xmlns' is not allowed.
Attachments (1)
Change History (7)
comment:1 by , 12 years ago
comment:2 by , 12 years ago
yeah , seems this bug :
https://bugzilla.gnome.org/show_bug.cgi?id=587360
http://bugzilla-attachments.gnome.org/attachment.cgi?id=223568
Thanks for the tip.
comment:3 by , 12 years ago
The patch of bug #587360, was applied on libxslt 1.27
@@ -4070,7 +4072,17 @@ xsltElement(xsltTransformContextPtr ctxt, xmlNodePtr node, * Find/create a matching ns-decl in the result tree. */ if (nsName != NULL) { - copy->ns = xsltGetSpecialNamespace(ctxt, inst, nsName, prefix, copy); + if (xmlStrEqual(prefix, BAD_CAST "xmlns")) { + /* Don't use a prefix of "xmlns" */ + xmlChar *pref = xmlStrdup(BAD_CAST "ns_1"); + + copy->ns = xsltGetSpecialNamespace(ctxt, inst, nsName, pref, copy); + + xmlFree(pref); + } else { + copy->ns = xsltGetSpecialNamespace(ctxt, inst, nsName, prefix, + copy); + } } else if ((copy->parent != NULL) && (copy->parent->type == XML_ELEMENT_NODE) && (copy->parent->ns != NULL))
I think this is the part of the patch which leads to this bug (The attribute name 'xmlns' is not allowed).
but can't find any solution that makes VirtualBox compiles.
by , 12 years ago
Attachment: | virtualbox-4.2.4-xmlns.patch added |
---|
comment:4 by , 12 years ago
I've attached a patch which seems to fix the problem here.
It removes the use of the default namespace from the affected XSLTs, and makes all references to the WSDL namespace explicit as well.
This allows me to build and run virtualbox-4.2.4 on gentoo (see https://bugs.gentoo.org/show_bug.cgi?id=436246) with phpvirtualbox (i.e., using vboxwebsrv).
Seen it with current MacPorts as well. Seems to be related to these libxslt changes: https://mail.gnome.org/archives/xslt/2012-September/msg00002.html