[98917] trunk/dports/textproc/libxslt

ryandesign at macports.org ryandesign at macports.org
Sat Oct 20 16:50:01 PDT 2012


Revision: 98917
          http://trac.macports.org//changeset/98917
Author:   ryandesign at macports.org
Date:     2012-10-20 16:50:01 -0700 (Sat, 20 Oct 2012)
Log Message:
-----------
libxslt: update to 1.1.27 with an upstream patch to fix a regression (#36499)

Modified Paths:
--------------
    trunk/dports/textproc/libxslt/Portfile

Added Paths:
-----------
    trunk/dports/textproc/libxslt/files/
    trunk/dports/textproc/libxslt/files/fix-namespace-regression.diff

Modified: trunk/dports/textproc/libxslt/Portfile
===================================================================
--- trunk/dports/textproc/libxslt/Portfile	2012-10-20 23:47:30 UTC (rev 98916)
+++ trunk/dports/textproc/libxslt/Portfile	2012-10-20 23:50:01 UTC (rev 98917)
@@ -4,7 +4,7 @@
 PortSystem      1.0
 
 name            libxslt
-version         1.1.26
+version         1.1.27
 categories      textproc
 license         MIT
 platforms       darwin
@@ -26,9 +26,8 @@
 # gnome mirrors only have up to 1.1.22, ticket #17737
 #                gnome:sources/${name}/[strsed ${version} {/\.[0-9]*$//}]/
 
-checksums       md5     e61d0364a30146aaa3001296f853b2b9 \
-                sha1    69f74df8228b504a87e2b257c2d5238281c65154 \
-                rmd160  fc7630352ae5772d25fc8132a373d477fb8d8d5f
+checksums       rmd160  004d6ce93e714ae436c93d85a275b0b901e0a7e7 \
+                sha256  b6a8d9a421f2630999ca91d9f8c091ee8ea2d580e6be84c1d21b2a45e11e7e26
 
 depends_lib     port:libiconv \
                 port:libxml2 \
@@ -42,6 +41,9 @@
 
 use_parallel_build  yes
 
+patch.pre_args  -p1
+patchfiles      fix-namespace-regression.diff
+
 pre-configure {
     reinplace s|need_relink=yes|need_relink=no| ${worksrcpath}/ltmain.sh
 }

Added: trunk/dports/textproc/libxslt/files/fix-namespace-regression.diff
===================================================================
--- trunk/dports/textproc/libxslt/files/fix-namespace-regression.diff	                        (rev 0)
+++ trunk/dports/textproc/libxslt/files/fix-namespace-regression.diff	2012-10-20 23:50:01 UTC (rev 98917)
@@ -0,0 +1,117 @@
+From be264bd3034b352a7c768ba62bf62cca22d074d9 Mon Sep 17 00:00:00 2001
+From: Nick Wellnhofer <wellnhofer at aevum.de>
+Date: Fri, 28 Sep 2012 19:04:39 +0000
+Subject: Fix regression: Default namespace not correctly used
+
+https://bugzilla.gnome.org/show_bug.cgi?id=684564
+---
+diff --git a/libxslt/transform.c b/libxslt/transform.c
+index de2ef3c..35701de 100644
+--- a/libxslt/transform.c
++++ b/libxslt/transform.c
+@@ -4075,7 +4075,7 @@ xsltElement(xsltTransformContextPtr ctxt, xmlNodePtr node,
+         } else if (xmlStrEqual(prefix, BAD_CAST "xml")) {
+             prefix = NULL;
+         }
+-    } else if (prefix != NULL) {
++    } else {
+ 	xmlNsPtr ns;
+ 	/*
+ 	* SPEC XSLT 1.0:
+@@ -4090,11 +4090,13 @@ xsltElement(xsltTransformContextPtr ctxt, xmlNodePtr node,
+ 	    * TODO: Check this in the compilation layer in case it's a
+ 	    * static value.
+ 	    */
+-            xsltTransformError(ctxt, NULL, inst,
+-                "xsl:element: The QName '%s:%s' has no "
+-                "namespace binding in scope in the stylesheet; "
+-                "this is an error, since the namespace was not "
+-                "specified by the instruction itself.\n", prefix, name);
++            if (prefix != NULL) {
++                xsltTransformError(ctxt, NULL, inst,
++                    "xsl:element: The QName '%s:%s' has no "
++                    "namespace binding in scope in the stylesheet; "
++                    "this is an error, since the namespace was not "
++                    "specified by the instruction itself.\n", prefix, name);
++            }
+ 	} else
+ 	    nsName = ns->href;
+     }
+diff --git a/tests/docs/Makefile.am b/tests/docs/Makefile.am
+index 9e2204f..12a97a8 100644
+--- a/tests/docs/Makefile.am
++++ b/tests/docs/Makefile.am
+@@ -168,6 +168,7 @@ EXTRA_DIST =	\
+ 	bug-167.xml \
+ 	bug-168.xml \
+ 	bug-169.xml \
++	bug-179.xml \
+ 	character.xml \
+ 	array.xml \
+ 	items.xml
+diff --git a/tests/docs/bug-179.xml b/tests/docs/bug-179.xml
+new file mode 100644
+index 0000000..69d62f2
+--- a/dev/null
++++ b/tests/docs/bug-179.xml
+@@ -0,0 +1 @@
++<doc/>
+diff --git a/tests/general/Makefile.am b/tests/general/Makefile.am
+index 364fdd9..762eca9 100644
+--- a/tests/general/Makefile.am
++++ b/tests/general/Makefile.am
+@@ -186,6 +186,7 @@ EXTRA_DIST = \
+     bug-176.out bug-176.xsl \
+     bug-177.out bug-177.xsl \
+     bug-178.out bug-178.xsl \
++    bug-179.out bug-179.xsl \
+     character.out character.xsl \
+     character2.out character2.xsl \
+     itemschoose.out itemschoose.xsl \
+diff --git a/tests/general/bug-179.out b/tests/general/bug-179.out
+new file mode 100644
+index 0000000..0a7e67d
+--- a/dev/null
++++ b/tests/general/bug-179.out
+@@ -0,0 +1,9 @@
++<?xml version="1.0"?>
++<root xmlns="my::namespace">
++  <foo>...</foo>
++  <bar>...</bar>
++  <foobar>...</foobar>
++  <baz>...</baz>
++  <doc>...</doc>
++  <baz>...</baz>
++</root>
+diff --git a/tests/general/bug-179.xsl b/tests/general/bug-179.xsl
+new file mode 100644
+index 0000000..5847e9a
+--- a/dev/null
++++ b/tests/general/bug-179.xsl
+@@ -0,0 +1,24 @@
++<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
++                              xmlns="my::namespace">
++
++<xsl:variable name="var">baz</xsl:variable>
++
++<xsl:output indent="yes"/>
++
++<xsl:template match="/">
++    <root> <!-- This is in the correct namespace "my::namespace" -->
++        <foo>...</foo> <!-- OK. -->
++        <xsl:element name="bar">...</xsl:element> <!-- Still okay. -->
++
++        <!-- Wrong! These are without namespace. -->
++        <xsl:element name="{concat('foo', 'bar')}">...</xsl:element>
++        <xsl:element name="{$var}">...</xsl:element>
++        <xsl:element name="{local-name(*)}">...</xsl:element>
++
++        <!-- Explicitly setting the namespace fixes this. -->
++        <xsl:element name="{$var}" namespace="my::namespace">...</xsl:element>
++    </root>
++</xsl:template>
++
++</xsl:stylesheet>
++
+--
+cgit v0.9.0.2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20121020/0ff13e43/attachment.html>


More information about the macports-changes mailing list