Subject: pkg/33425: textproc/libxml2 Sun Studio CC fails to build
To: None <pkg-manager@netbsd.org, gnats-admin@netbsd.org,>
From: None <jakerosoft@gmail.com>
List: pkgsrc-bugs
Date: 05/04/2006 19:15:00
>Number:         33425
>Category:       pkg
>Synopsis:       textproc/libxml2 Sun Studio CC fails to build
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu May 04 19:15:00 +0000 2006
>Originator:     Jake Kupersmith
>Release:        pkgsrc-current
>Organization:
>Environment:
SunOS frylock 5.10 Generic_118822-25 sun4u sparc SUNW,Ultra-60

>Description:
On Solaris 10, using latest Sun Studio compilers.  relaxng.c fails to build.
>How-To-Repeat:
 cc -DHAVE_CONFIG_H -I. -I./include -I/var/db/work/textproc/libxml2/work/.buildlink/include -xO3 -xtarget=ultra2 -xarch=v8plusa -Xa -xc99=all -c relaxng.c  -KPIC -DPIC -o .libs/relaxng.o
"relaxng.c", line 7397: operands have incompatible types:
         pointer to unsigned char ":" pointer to char
cc: acomp failed for relaxng.c
gmake[2]: *** [relaxng.lo] Error 1
gmake[2]: Leaving directory `/var/db/work/textproc/libxml2/work/libxml2-2.6.24'
gmake[1]: *** [all-recursive] Error 1

>Fix:
--- relaxng.c.orig      Thu May  4 15:07:17 2006
+++ relaxng.c   Thu May  4 15:12:46 2006
@@ -7394,7 +7394,7 @@
     if (root == NULL) {
         xmlRngPErr(ctxt, (xmlNodePtr) doc,
                   XML_RNGP_EMPTY, "xmlRelaxNGParse: %s is empty\n",
-                   (ctxt->URL ? ctxt->URL : "schemas"), NULL);
+                   (ctxt->URL ? ctxt->URL : (unsigned char *)"schemas"), NULL);
        
         xmlFreeDoc(ctxt->document);
         ctxt->document = NULL;