summaryrefslogtreecommitdiff
path: root/devel/gdb/patches
diff options
context:
space:
mode:
authorrillig <rillig@pkgsrc.org>2008-01-06 19:25:09 +0000
committerrillig <rillig@pkgsrc.org>2008-01-06 19:25:09 +0000
commitf5cc18c0caebca8142b826fcbb23422593f2b356 (patch)
tree85fcb621483257553a314f865389a9e8548b5e20 /devel/gdb/patches
parentc891b8517f9011391ced7db96f23a9d83b3c909d (diff)
downloadpkgsrc-f5cc18c0caebca8142b826fcbb23422593f2b356.tar.gz
Some changes take a long time. This package had been broken since two
years. The fix was trivially copied from devel/coconut, which had the same problem concerning an "invalid lvalue in increment".
Diffstat (limited to 'devel/gdb/patches')
-rw-r--r--devel/gdb/patches/patch-ob25
1 files changed, 25 insertions, 0 deletions
diff --git a/devel/gdb/patches/patch-ob b/devel/gdb/patches/patch-ob
new file mode 100644
index 00000000000..aa8a6d3c589
--- /dev/null
+++ b/devel/gdb/patches/patch-ob
@@ -0,0 +1,25 @@
+$NetBSD: patch-ob,v 1.1 2008/01/06 19:25:10 rillig Exp $
+
+gcc4 complained:
+gdbtypes.c:2961: error: invalid lvalue in increment
+
+--- include/obstack.h.orig 2001-01-21 00:02:00.000000000 +0000
++++ include/obstack.h 2007-11-30 21:04:44.000000000 +0000
+@@ -421,7 +421,7 @@ __extension__ \
+ ({ struct obstack *__o = (OBSTACK); \
+ if (__o->next_free + sizeof (void *) > __o->chunk_limit) \
+ _obstack_newchunk (__o, sizeof (void *)); \
+- *((void **)__o->next_free)++ = ((void *)datum); \
++ *((*(void ***)&(__o->next_free)))++ = ((void *)datum); \
+ (void) 0; })
+
+ # define obstack_int_grow(OBSTACK,datum) \
+@@ -429,7 +429,7 @@ __extension__ \
+ ({ struct obstack *__o = (OBSTACK); \
+ if (__o->next_free + sizeof (int) > __o->chunk_limit) \
+ _obstack_newchunk (__o, sizeof (int)); \
+- *((int *)__o->next_free)++ = ((int)datum); \
++ *((*(int **)&(__o->next_free)))++ = ((int)datum); \
+ (void) 0; })
+
+ # define obstack_ptr_grow_fast(h,aptr) (*((void **) (h)->next_free)++ = (void *)aptr)