diff options
author | marino <marino@pkgsrc.org> | 2012-08-18 08:04:25 +0000 |
---|---|---|
committer | marino <marino@pkgsrc.org> | 2012-08-18 08:04:25 +0000 |
commit | 4c2b76d7e51c9c28839c281579b5679c2476611f (patch) | |
tree | ee4e2090ff173298cf7bed8bd5c4f9a24f95d34e | |
parent | c9e4aeab3669cf29370d660a7fab044f94abc3ca (diff) | |
download | pkgsrc-4c2b76d7e51c9c28839c281579b5679c2476611f.tar.gz |
x11/xcb-util-image: Fix build for some compilers.
gcc44 complains "control reaches end of non-void function" on DragonFly
Apparently gcc45+ recognizes the assert, but for those compilers that don't,
putting a dummy return value won't hurt anything and it fixes the build
at least for gcc 4.4.
-rw-r--r-- | x11/xcb-util-image/distinfo | 3 | ||||
-rw-r--r-- | x11/xcb-util-image/patches/patch-image_xcb__image.c | 26 |
2 files changed, 28 insertions, 1 deletions
diff --git a/x11/xcb-util-image/distinfo b/x11/xcb-util-image/distinfo index 041b23f524a..593c79c90fa 100644 --- a/x11/xcb-util-image/distinfo +++ b/x11/xcb-util-image/distinfo @@ -1,5 +1,6 @@ -$NetBSD: distinfo,v 1.1 2012/08/12 21:19:06 wiz Exp $ +$NetBSD: distinfo,v 1.2 2012/08/18 08:04:25 marino Exp $ SHA1 (xcb-util-image-0.3.9.tar.bz2) = afeba6230400fe8bec6076fd07bf20a8e412bbb5 RMD160 (xcb-util-image-0.3.9.tar.bz2) = c666b87e20eaa703697df758e1d0e26aec2d62a4 Size (xcb-util-image-0.3.9.tar.bz2) = 310947 bytes +SHA1 (patch-image_xcb__image.c) = d0a956fc8786f03c8cce9d87f748cc02d3a8ac21 diff --git a/x11/xcb-util-image/patches/patch-image_xcb__image.c b/x11/xcb-util-image/patches/patch-image_xcb__image.c new file mode 100644 index 00000000000..5cbef864462 --- /dev/null +++ b/x11/xcb-util-image/patches/patch-image_xcb__image.c @@ -0,0 +1,26 @@ +$NetBSD: patch-image_xcb__image.c,v 1.1 2012/08/18 08:04:25 marino Exp $ + +gcc44 complains "control reaches end of non-void function" on DragonFly +Apparently gcc45+ recognizes the assert, but for those compilers that don't, +putting a dummy return value won't hurt anything. + +--- image/xcb_image.c.orig 2011-06-30 08:05:22.000000000 +0000 ++++ image/xcb_image.c +@@ -187,6 +187,8 @@ xcb_image_create_native (xcb_connection_ + assert(0); + } + assert(0); ++/* gcc44 complains "control reaches end of non-void function", fix below */ ++ return (-1); + } + + +@@ -750,6 +752,8 @@ xcb_image_get_pixel (xcb_image_t *image, + return pixel; + default: + assert(0); ++/* gcc44 complains "control reaches end of non-void function", fix below */ ++ return (-1); + } + } + |