pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/36322: x11/Xaw-Xpm doesn't build on NetBSD-current
>Number: 36322
>Category: pkg
>Synopsis: x11/Xaw-Xpm doesn't build on NetBSD-current
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sun May 13 21:35:02 +0000 2007
>Originator: Holger Weiss
>Release: NetBSD 4.99.19
>Organization:
Individual Network Berlin e.V.
>Environment:
System: NetBSD pandora.jhweiss.de 4.99.19 NetBSD 4.99.19 (PANDORA) #2: Sun May
6 04:02:02 CEST 2007
holger%pandora.jhweiss.de@localhost:/usr/build/obj/sys/arch/i386/compile/PANDORA
i386
Architecture: i386
Machine: i386
>Description:
GCC 4.x doesn't accept casting an lvalue, therefore building x11/Xaw-Xpm
bails out with the following error at various places on (at least)
NetBSD-current:
| cc -c -I. -I/usr/pkg/include -I/usr/X11R6/include -DCSRG_BASED
-DFUNCPROTO=15 -DNARROWPROTO -DHAS_WCHAR_H -DHAS_WCTYPE_H -DNO_WIDEC_H
-DARROW_SCROLLBAR -DUSEGRAY -DSUN_AUDIO -O2 -fno-strict-aliasing Command.c
-o unshared/Command.o
| Command.c: In function 'SetValues':
| Command.c:656: error: invalid lvalue in assignment
| Command.c:666: error: invalid lvalue in assignment
| Command.c: In function 'Realize':
| Command.c:720: error: invalid lvalue in assignment
| Command.c:728: error: invalid lvalue in assignment
|
| [wrapper.sh] note: The real command line, after the pkgsrc wrapper, was:
| /usr/pkgsrc/x11/Xaw-Xpm/work.pandora/.gcc/bin/gcc -c -I.
-I/usr/pkgsrc/x11/Xaw-Xpm/work.pandora/.buildlink/include
-I/usr/pkgsrc/x11/Xaw-Xpm/work.pandora/.x11-buildlink/include -DCSRG_BASED
-DFUNCPROTO=15 -DNARROWPROTO -DHAS_WCHAR_H -DHAS_WCTYPE_H -DNO_WIDEC_H
-DARROW_SCROLLBAR -DUSEGRAY -DSUN_AUDIO -O2 -fno-strict-aliasing Command.c -o
unshared/Command.o -L/usr/pkgsrc/x11/Xaw-Xpm/work.pandora/.buildlink/lib
After fixing those, building x11/Xaw-Xpm fails as follows:
| cc -c -I. -I/usr/pkg/include -I/usr/X11R6/include -DCSRG_BASED
-DFUNCPROTO=15 -DNARROWPROTO -DHAS_WCHAR_H -DHAS_WCTYPE_H -DNO_WIDEC_H
-DARROW_SCROLLBAR -DUSEGRAY -DSUN_AUDIO -O2 -fno-strict-aliasing laylex.c -o
unshared/laylex.o
| laylex.l:65: error: static declaration of 'count' follows non-static
declaration
| laylex.l:28: error: previous implicit declaration of 'count' was here
| laylex.l: In function 'LayYYlook':
| laylex.l:557: warning: incompatible implicit declaration of built-in function
'exit'
| laylex.l:577: warning: incompatible implicit declaration of built-in function
'exit'
| laylex.l:595: warning: incompatible implicit declaration of built-in function
'exit'
| laylex.l:613: warning: incompatible implicit declaration of built-in function
'exit'
|
| [wrapper.sh] note: The real command line, after the pkgsrc wrapper, was:
| /usr/pkgsrc/x11/Xaw-Xpm/work.pandora/.gcc/bin/gcc -c -I.
-I/usr/pkgsrc/x11/Xaw-Xpm/work.pandora/.buildlink/include
-I/usr/pkgsrc/x11/Xaw-Xpm/work.pandora/.x11-buildlink/include -DCSRG_BASED
-DFUNCPROTO=15 -DNARROWPROTO -DHAS_WCHAR_H -DHAS_WCTYPE_H -DNO_WIDEC_H
-DARROW_SCROLLBAR -DUSEGRAY -DSUN_AUDIO -O2 -fno-strict-aliasing laylex.c -o
unshared/laylex.o -L/usr/pkgsrc/x11/Xaw-Xpm/work.pandora/.buildlink/lib
>How-To-Repeat:
Using GCC 4.x:
$ cd pkgsrc/x11/Xaw-Xpm && make
>Fix:
The following patch fixes compilation on NetBSD-current:
Index: distinfo
===================================================================
RCS file: /cvsroot/pkgsrc/x11/Xaw-Xpm/distinfo,v
retrieving revision 1.5
diff -u -r1.5 distinfo
--- distinfo 29 Jan 2007 18:36:29 -0000 1.5
+++ distinfo 13 May 2007 21:07:17 -0000
@@ -3,10 +3,13 @@
SHA1 (Xaw-XPM-1.1.tar.gz) = 8d85d0a96c86f46da9dcf21eef8daf3a7dd64c7f
RMD160 (Xaw-XPM-1.1.tar.gz) = a97a08af7459ada39c7b97a69cf1b05d3e570343
Size (Xaw-XPM-1.1.tar.gz) = 1188556 bytes
-SHA1 (patch-aa) = b220f322f3a8a82400144defecb65bb2121ba997
+SHA1 (patch-aa) = 0f92a521da3a12374c72f580ee5d74b93648d88f
SHA1 (patch-ab) = a2e4249ab6d9dce2b98452cf60c0d49e281cde7b
SHA1 (patch-ac) = 4bf9c4870a2b1fcc32a5a2809763da8c14a55d19
SHA1 (patch-ad) = b1de4e1008c0b5791df3c32e5520b7823d203237
SHA1 (patch-ae) = 9e163e8daa63099f732292a00449202dd54b7ddd
SHA1 (patch-af) = 993be70d46216dff66b6710f001351e2e0ccf929
-SHA1 (patch-ag) = da8c9e1348ae7b1bf97cf47cca6fb9e1a8c8cf6d
+SHA1 (patch-ag) = 417fd798660f9d6a71b7075222a3b00d4b206ae1
+SHA1 (patch-ah) = 765004798816b3bd6d3641fcd5246d0621658f75
+SHA1 (patch-ai) = bd97e186cb8b51c0cd0a37938ceb875d85c3bb19
+SHA1 (patch-aj) = 14255172936fe1ad86ade735ced898293b94170e
Index: patches/patch-aa
===================================================================
RCS file: /cvsroot/pkgsrc/x11/Xaw-Xpm/patches/patch-aa,v
retrieving revision 1.3
diff -u -r1.3 patch-aa
--- patches/patch-aa 28 Jun 1999 09:11:13 -0000 1.3
+++ patches/patch-aa 13 May 2007 21:07:17 -0000
@@ -3,8 +3,84 @@
Handle wide signal masks.
--- Xpm.c.orig Tue Nov 26 13:40:26 1996
-+++ Xpm.c Mon Jun 28 10:04:57 1999
-@@ -206,9 +206,8 @@
++++ Xpm.c
+@@ -46,7 +46,7 @@ char directory[MAXPATHLEN];
+ }
+ chdir(directory);
+ }
+- (PixmapNode *)PixList.first = (PixmapNode *)pixnode;
++ PixList.first = (PixmapNode *)pixnode;
+ pixnode->next = NULL;
+ PixList.n_entries = 1;
+ pixnode->filename = filename;
+@@ -55,18 +55,18 @@ char directory[MAXPATHLEN];
+
+ /* Is the pixmap already in the list? */
+
+- (PixmapNode *)pixnode = (PixmapNode *)PixList.first;
++ pixnode = (PixmapNode *)PixList.first;
+ for(;;)
+ {
+ if(strncmp(filename,pixnode->filename, MAXPATHLEN) == 0)
+ return((Pixmap *)&pixnode->pixmap);
+ if(pixnode->next == NULL) break;
+- (PixmapNode *)pixnode = (PixmapNode *)pixnode->next;
++ pixnode = (PixmapNode *)pixnode->next;
+ }
+
+ /* Didnt find the pixmap...make a new one */
+
+- (PixmapNode *)pixnew = (void *)malloc(sizeof(PixmapNode));
++ pixnew = (void *)malloc(sizeof(PixmapNode));
+
+ XGetWindowAttributes(XtDisplay(w)
,DefaultRootWindow(XtDisplay(w)),&root_att);
+ orig_att.closeness=65536;
+@@ -86,7 +86,7 @@ char directory[MAXPATHLEN];
+ }
+ chdir(directory);
+ }
+- (PixmapNode *)pixnode->next = (PixmapNode *)pixnew;
++ pixnode->next = (PixmapNode *)pixnew;
+ pixnew->filename = filename;
+ pixnew->next = NULL;
+ return((Pixmap *)&pixnew->pixmap);
+@@ -105,7 +105,7 @@ XpmAttributes orig_att;
+ char error_buf[BUFSIZ];
+ char directory[MAXPATHLEN];
+
+- (PixmapNode *)pixnode = (PixmapNode *)PixList.first;
++ pixnode = (PixmapNode *)PixList.first;
+ for(;;)
+ {
+ if(strncmp(filename,pixnode->filename, MAXPATHLEN) == 0)
+@@ -114,7 +114,7 @@ char directory[MAXPATHLEN];
+ break;
+ }
+ if(pixnode->next == NULL) break;
+- (PixmapNode *)pixnode = (PixmapNode *)pixnode->next;
++ pixnode = (PixmapNode *)pixnode->next;
+ }
+ if(found)
+ {
+@@ -140,7 +140,7 @@ char directory[MAXPATHLEN];
+ }
+ else
+ {
+- (PixmapNode *)pixnew = (void *)malloc(sizeof(PixmapNode));
++ pixnew = (void *)malloc(sizeof(PixmapNode));
+ XGetWindowAttributes(XtDisplay(w)
,DefaultRootWindow(XtDisplay(w)),&root_att);
+ orig_att.closeness=65536;
+ orig_att.colormap=root_att.colormap;
+@@ -159,7 +159,7 @@ char directory[MAXPATHLEN];
+ }
+ chdir(directory);
+ }
+- (PixmapNode *)pixnode->next = (PixmapNode *)pixnew;
++ pixnode->next = (PixmapNode *)pixnew;
+ pixnew->filename = filename;
+ pixnew->next = NULL;
+ return((Pixmap *)&pixnew->mask);
+@@ -206,9 +206,8 @@ char *soundfile;
sigchld.
*/
new.sa_handler=SigHandle;
Index: patches/patch-ag
===================================================================
RCS file: /cvsroot/pkgsrc/x11/Xaw-Xpm/patches/patch-ag,v
retrieving revision 1.1
diff -u -r1.1 patch-ag
--- patches/patch-ag 29 Jan 2007 18:36:29 -0000 1.1
+++ patches/patch-ag 13 May 2007 21:07:17 -0000
@@ -11,7 +11,15 @@
extern int LayYYlineno;
struct LayYYsvf {
struct LayYYwork *LayYYstoff;
-@@ -68,6 +68,16 @@ static char *LayYYsourcebase, *LayYYsour
+@@ -61,6 +61,7 @@ extern struct LayYYsvf LayYYsvec[], *Lay
+ #include "LayoutP.h"
+ #include "laygram.h"
+ static char *LayYYsourcebase, *LayYYsource;
++static int count (char *, char);
+
+ #define input() (*LayYYsource++)
+ #define unput(c) (--LayYYsource)
+@@ -68,6 +69,16 @@ static char *LayYYsourcebase, *LayYYsour
# define YYNEWLINE 10
LayYYlex(){
int nstr; extern int LayYYprevious;
Index: patches/patch-ah
===================================================================
RCS file: patches/patch-ah
diff -N patches/patch-ah
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-ah 13 May 2007 21:07:17 -0000
@@ -0,0 +1,40 @@
+$NetBSD$
+
+--- Command.c.orig 1996-11-11 09:38:27.000000000 -0000
++++ Command.c
+@@ -651,7 +651,7 @@ Cardinal *num_args;
+ if(oldcbw->command.setpixmap != cbw->command.setpixmap &&
+ cbw->command.setpixmap != None)
+ {
+- (CommandWidget)cbw->command.setpix =
++ cbw->command.setpix =
+ InsertPixmap(cbw, ((CommandWidget)cbw)->command.setpixmap,
+
((CommandWidget)cbw)->simple.pixdir);
+ if ((Pixmap)*cbw->command.setpix == (Pixmap)NULL)
+@@ -661,7 +661,7 @@ Cardinal *num_args;
+ if(oldcbw->command.hlpixmap != cbw->command.hlpixmap &&
+ cbw->command.hlpixmap != None)
+ {
+- (CommandWidget)cbw->command.hlpix =
++ cbw->command.hlpix =
+ InsertPixmap(cbw, ((CommandWidget)cbw)->command.hlpixmap,
+ ((CommandWidget)cbw)->simple.pixdir);
+ if ((Pixmap)*cbw->command.hlpix == (Pixmap)NULL)
+@@ -715,7 +715,7 @@ static void Realize(w, valueMask, attrib
+
+ if(cbw->command.setpixmap != None)
+ {
+- (Pixmap *)cbw->command.setpix =
++ cbw->command.setpix =
+ (Pixmap *)InsertPixmap(w, cbw->command.setpixmap,
+
cbw->simple.pixdir);
+ if( (Pixmap) *cbw->command.setpix == (Pixmap)NULL)
+@@ -723,7 +723,7 @@ static void Realize(w, valueMask, attrib
+ }
+ if(cbw->command.hlpixmap != None)
+ {
+- (Pixmap *)cbw->command.hlpix =
++ cbw->command.hlpix =
+ (Pixmap *)InsertPixmap(w, cbw->command.hlpixmap,
+
cbw->simple.pixdir);
+ if( (Pixmap) *cbw->command.hlpix == (Pixmap)NULL)
Index: patches/patch-ai
===================================================================
RCS file: patches/patch-ai
diff -N patches/patch-ai
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-ai 13 May 2007 21:07:17 -0000
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- Panner.c.orig 1996-10-26 07:59:58.000000000 -0000
++++ Panner.c
+@@ -556,7 +556,7 @@ static void Realize (gw, valuemaskp, att
+ (gw, valuemaskp, attr);
+ if(pw->panner.sliderpixmap != None)
+ {
+- (Pixmap *)((PannerWidget)pw)->panner.spix =
++ ((PannerWidget)pw)->panner.spix =
+ (Pixmap *)InsertPixmap(pw, ((PannerWidget)pw)->panner.sliderpixmap,
+
((PannerWidget)pw)->simple.pixdir);
+ if((Pixmap)*((PannerWidget)pw)->panner.spix == (Pixmap)NULL)
Index: patches/patch-aj
===================================================================
RCS file: patches/patch-aj
diff -N patches/patch-aj
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-aj 13 May 2007 21:07:17 -0000
@@ -0,0 +1,13 @@
+$NetBSD$
+
+--- Scrollbar.c.orig 1996-11-26 09:07:53.000000000 -0000
++++ Scrollbar.c
+@@ -1086,7 +1086,7 @@ static void Realize (w, valueMask, attri
+ }
+ if(((ScrollbarWidget)sbw)->scrollbar.thumbpixmap != None)
+ {
+- (Pixmap *)((ScrollbarWidget)sbw)->scrollbar.thumbpix =
++ ((ScrollbarWidget)sbw)->scrollbar.thumbpix =
+ InsertPixmap(sbw,
((ScrollbarWidget)sbw)->scrollbar.thumbpixmap,
+
((ScrollbarWidget)sbw)->simple.pixdir);
+ if((Pixmap)*sbw->scrollbar.thumbpix == (Pixmap)NULL)
Home |
Main Index |
Thread Index |
Old Index