Subject: pkg/29065: one more patch needed for net/ethereal-0.10.9 for netbsd-1-6
To: None <pkg-manager@netbsd.org, gnats-admin@netbsd.org,>
From: Greg A. Woods <woods@weird.com>
List: pkgsrc-bugs
Date: 01/24/2005 18:46:00
>Number:         29065
>Category:       pkg
>Synopsis:       one more patch needed for net/ethereal-0.10.9 for netbsd-1-6
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jan 24 18:46:00 +0000 2005
>Originator:     Greg A. Woods
>Release:        pkgsrc-2004Q4
>Organization:
Planix, Inc.; Toronto, Ontario; Canada
>Environment:
System: NetBSD  1.6.2_STABLE
>Description:

	There's a syntax error in the new net/ethereal-0.10.9 which
	perhaps GCC-3.x is somewhat more lax about than it should be.

>How-To-Repeat:

Making all in mate
/bin/sh ../../libtool --mode=compile cc -DHAVE_CONFIG_H  -I. -I. -I../.. -I../..  -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2 -I/usr/local/include -I/usr/include -I/usr/include -I/usr/pkg/include -O2 -march=pentiumpro -g -Dnetbsd1 -pipe -I/usr/pkg/include -I/usr/pkg/include -Dnetbsdelf -I/usr/pkg/include -I. -I/usr/pkg/include   -DINET6 -D_U_="__attribute__((unused))" -Wall -W  -O2 -march=pentiumpro -g -pipe -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2 -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/freetype2 -I/usr/local/include -I/usr/pkg/include/glib/glib-2.0 -I/usr/pkg/lib/glib-2.0/include   -I/usr/include -I/usr/include -I/usr/pkg/include -O2 -march=pentiumpro -g -Dnetbsd1 -pipe -I/usr/pkg/include -I/usr/pkg/include -Dnetbsdelf -I/usr/pkg/include -I. -I/usr/pkg/include -c -o packet-mate.lo packet-mate.c
mkdir .libs
 cc -DHAVE_CONFIG_H -I. -I../.. -I/var/package-obj/net/ethereal/work/.buildlink/include -I/var/package-obj/net/ethereal/work/.buildlink/include/freetype2 -O2 -march=pentiumpro -g -Dnetbsd1 -pipe -Dnetbsdelf -DINET6 "-D_U_=__attribute__((unused))" -Wall -W -O2 -march=pentiumpro -g -pipe -I/var/package-obj/net/ethereal/work/.buildlink/include/glib/glib-2.0 -I/var/package-obj/net/ethereal/work/.buildlink/lib/glib-2.0/include -O2 -march=pentiumpro -g -pipe -c packet-mate.c  -fPIC -DPIC -o .libs/packet-mate.o
In file included from packet-mate.c:33:
mate.h:327: parse error before `,'
packet-mate.c: In function `init_mate':
packet-mate.c:244: `mate_packet' undeclared (first use in this function)
packet-mate.c:244: (Each undeclared identifier is reported only once
packet-mate.c:244: for each function it appears in.)
*** Error code 1

Stop.
make: stopped in /build/package-obj/net/ethereal/work/ethereal-0.10.9/plugins/mate
*** Error code 1

Stop.
make: stopped in /build/package-obj/net/ethereal/work/ethereal-0.10.9/plugins
*** Error code 1

Stop.
make: stopped in /build/package-obj/net/ethereal/work/ethereal-0.10.9
*** Error code 1

Stop.
make: stopped in /build/package-obj/net/ethereal/work/ethereal-0.10.9
*** Error code 1

Stop.
make: stopped in /building/work/woods/m-NetBSD-pkgsrc-2004q4/net/ethereal
*** Error code 1

Stop.
make: stopped in /building/work/woods/m-NetBSD-pkgsrc-2004q4/net/ethereal

>Fix:

cvs diff: Diffing net/ethereal
Index: net/ethereal/Makefile
===================================================================
RCS file: /cvs/master/m-NetBSD/main/pkgsrc/net/ethereal/Makefile,v
retrieving revision 1.100.2.1
diff -u -r1.100.2.1 Makefile
--- net/ethereal/Makefile	21 Jan 2005 06:41:53 -0000	1.100.2.1
+++ net/ethereal/Makefile	24 Jan 2005 18:42:51 -0000
@@ -26,6 +26,7 @@
 USE_X11=		YES
 USE_PERL5=		build
 
+USE_GNU_TOOLS=		make
 USE_LIBTOOL=		YES
 SHLIBTOOL_OVERRIDE=	libtool
 
@@ -45,6 +46,10 @@
 
 .include "../../mk/bsd.prefs.mk"
 
+# it is now pretty much impossible to build this thing static-linked
+#
+LDSTATIC=		# empty
+
 .if ${OPSYS} == "Darwin"
 USE_BUILTIN.libpcap=	no
 .endif
Index: net/ethereal/distinfo
===================================================================
RCS file: /cvs/master/m-NetBSD/main/pkgsrc/net/ethereal/distinfo,v
retrieving revision 1.31.2.1
diff -u -r1.31.2.1 distinfo
--- net/ethereal/distinfo	21 Jan 2005 06:41:53 -0000	1.31.2.1
+++ net/ethereal/distinfo	24 Jan 2005 18:33:54 -0000
@@ -2,3 +2,4 @@
 
 SHA1 (ethereal-0.10.9.tar.bz2) = fc27a93f4c19dcc4278968b376e0b33e7d756998
 Size (ethereal-0.10.9.tar.bz2) = 5499000 bytes
+SHA1 (patch-zz) = b956cf498daf7f44b14d2b6efa32ea4d66609032
cvs diff: Diffing net/ethereal/patches
Index: net/ethereal/patches/patch-zz
===================================================================
RCS file: net/ethereal/patches/patch-zz
diff -N net/ethereal/patches/patch-zz
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ net/ethereal/patches/patch-zz	24 Jan 2005 18:33:48 -0000
@@ -0,0 +1,11 @@
+--- work/ethereal-0.10.9/plugins/mate/mate.h.orig	Mon Jan 17 21:39:21 2005
++++ work/ethereal-0.10.9/plugins/mate/mate.h	Mon Jan 24 13:30:14 2005
+@@ -324,7 +324,7 @@
+ extern void initialize_mate_runtime(void);
+ extern mate_pdu* mate_get_pdus(guint32 framenum);
+ extern void mate_analyze_frame(packet_info *pinfo, proto_tree* tree);
+-extern int mate_packet(void* _U_, packet_info* _U_, epan_dissect_t* _U_,const void* _U_);
++extern int mate_packet(void*, packet_info*, epan_dissect_t*,const void*);
+ 
+ /* from mate_setup.c */
+ extern mate_config* mate_make_config(guint8* filename);