Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 24 Nov 2003 20:59:19 +0100
From:      Adriaan de Groot <adridg@cs.kun.nl>
To:        kde@freebsd.org, amd64@freebsd.org
Cc:        Kris Kennaway <kris@obsecurity.org>
Subject:   Re: [kde-freebsd] arts-1.1.4,1 broken on amd64
Message-ID:  <200311242059.19644.adridg@cs.kun.nl>
In-Reply-To: <Pine.GSO.4.44.0311240942010.1258-100000@wn4.sci.kun.nl>
References:  <Pine.GSO.4.44.0311240942010.1258-100000@wn4.sci.kun.nl>

next in thread | previous in thread | raw e-mail | index | archive | help

--Boundary-00=_XMmw/50/6/LrePe
Content-Type: text/plain;
  charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

On Monday 24 November 2003 09:46, Adriaan de Groot wrote:
> On Mon, 24 Nov 2003, Lauri Watts wrote:
> > On Monday 24 November 2003 01.36, Kris Kennaway wrote:
> > > http://bento.freebsd.org/errorlogs/amd64-5-latest/arts-1.1.4,1.log
> > >
> > > Can you please investigate ASAP?

> Someone complained vaguely about this already on the amd64 list, but
> didn't provide any specifics, also not after being prompted.
>
> > There's a patch added, orginally to make it build on amd64:
> > patch-flow-gsl-gslglib.c
>
> FWIW, arts builds straight from CVS with no tweaks of any kind for me on
> amd64. I'll try to grab the port today and see what it does when I get
> home.

My bad, it _didn't_ build from CVS without tweaks, I needed to define the 
correct form of G_VA_COPY for the amd64 (which uses the standard va_copy 
macro .. count on glib to suffer from NIH). I've attached two patches:

1) va.diff adds #    define G_VA_COPY(ap1, ap2)   va_copy(ap1,ap2) in relevant 
places.

2) stringcat.diff removes a bunch of G_STRLOCs from the code, since those 
expand to __FUNCTION__, and concatenating __FUNCTION__ with constant strings 
is deprecated.

Kris, as usual I haven't the slightest idea as to how to get this into FBSD in 
a sensible fashion. Bug a committer about it. I'll push it into upstream CVS, 
though. I called them files/patch-flow-gsl-VA_COPY and 
files/patch-flow-gsl-gslglib.c-2 and it both configures and builds.


-- 
pub  1024D/FEA2A3FE 2002-06-18 Adriaan de Groot <groot@kde.org>
            If the door is ajar, can we fill it with door-jamb?

--Boundary-00=_XMmw/50/6/LrePe
Content-Type: text/x-diff;
  charset="iso-8859-1";
  name="stringcat.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename="stringcat.diff"

Index: flow/gsl/gslglib.c
===================================================================
RCS file: /home/kde/arts/flow/gsl/gslglib.c,v
retrieving revision 1.15.2.1
diff -u -3 -p -r1.15.2.1 gslglib.c
--- flow/gsl/gslglib.c	12 Dec 2002 16:14:49 -0000	1.15.2.1
+++ flow/gsl/gslglib.c	24 Nov 2003 19:42:08 -0000
@@ -2057,7 +2057,7 @@ printf_string_upper_bound (const gchar *
 		   */
 		case '$':
 		  if (may_warn)
-		    g_warning (G_STRLOC ": unable to handle positional parameters (%%n$)");
+		    g_warning (": unable to handle positional parameters (%%n$)");
 		  len += 1024; /* try adding some safety padding */
 		  break;
 
@@ -2222,7 +2222,7 @@ printf_string_upper_bound (const gchar *
 		  /*          n   .   dddddddddddddddddddddddd   E   +-  eeee */
 		  conv_len += 1 + 1 + MAX (24, spec.precision) + 1 + 1 + 4;
                   if (may_warn && spec.mod_extra_long)
-		    g_warning (G_STRLOC ": unable to handle long double, collecting double only");
+		    g_warning (": unable to handle long double, collecting double only");
 #ifdef HAVE_LONG_DOUBLE
 #error need to implement special handling for long double
 #endif
@@ -2265,7 +2265,7 @@ printf_string_upper_bound (const gchar *
 		  if (spec.mod_long)
 		    {
 		      if (may_warn)
-			g_warning (G_STRLOC": unable to handle wide char strings");
+			g_warning (": unable to handle wide char strings");
 		      len += 1024; /* try adding some safety padding */
 		    }
 		  break;
@@ -2296,7 +2296,7 @@ printf_string_upper_bound (const gchar *
 		  break;
 		default:
 		  if (may_warn)
-		    g_warning (G_STRLOC": unable to handle `%c' while parsing format",
+                    g_warning (": unable to handle `%c' while parsing format",
 			       c);
 		  break;
 		}

--Boundary-00=_XMmw/50/6/LrePe
Content-Type: text/x-diff;
  charset="iso-8859-1";
  name="va.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename="va.diff"

Index: flow/gsl/gslglib.h
===================================================================
RCS file: /home/kde/arts/flow/gsl/gslglib.h,v
retrieving revision 1.20
diff -u -3 -p -r1.20 gslglib.h
--- flow/gsl/gslglib.h	24 Sep 2002 18:55:16 -0000	1.20
+++ flow/gsl/gslglib.h	24 Nov 2003 19:41:45 -0000
@@ -513,6 +513,8 @@ gboolean g_path_is_absolute (const gchar
 #    define G_VA_COPY(ap1, ap2)   (*(ap1) = *(ap2))
 #  elif defined (G_VA_COPY_AS_ARRAY)
 #    define G_VA_COPY(ap1, ap2)   g_memmove ((ap1), (ap2), sizeof (va_list))
+#  elif defined (va_copy)
+#    define G_VA_COPY(ap1, ap2)   va_copy(ap1,ap2)
 #  else /* va_list is a pointer */
 #    define G_VA_COPY(ap1, ap2)   ((ap1) = (ap2))
 #  endif /* va_list is a pointer */
Index: mcop/debug.cc
===================================================================
RCS file: /home/kde/arts/mcop/debug.cc,v
retrieving revision 1.7.2.3
diff -u -3 -p -r1.7.2.3 debug.cc
--- mcop/debug.cc	12 Dec 2002 16:17:37 -0000	1.7.2.3
+++ mcop/debug.cc	24 Nov 2003 19:41:46 -0000
@@ -385,6 +385,8 @@ typedef struct _GString GString;
 #    define G_VA_COPY(ap1, ap2)   (*(ap1) = *(ap2))
 #  elif defined (G_VA_COPY_AS_ARRAY)
 #    define G_VA_COPY(ap1, ap2)   g_memmove ((ap1), (ap2), sizeof (va_list))
+#  elif defined (va_copy)
+#    define G_VA_COPY(ap1, ap2)   va_copy(ap1,ap2)
 #  else /* va_list is a pointer */
 #    define G_VA_COPY(ap1, ap2)   ((ap1) = (ap2))
 #  endif /* va_list is a pointer */

--Boundary-00=_XMmw/50/6/LrePe--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200311242059.19644.adridg>