[gtk-vnc-devel] Suncc generate bad macro defination for blt.h
- From: Halton Huo <Halton Huo Sun COM>
- To: gtk-vnc-devel lists sourceforge net
- Subject: [gtk-vnc-devel] Suncc generate bad macro defination for blt.h
- Date: Fri, 26 Oct 2007 15:47:58 +0800
Hi there,
I'm trying to build gtk-vnc trunk code on Solaris using suncc, but met error message as following:
$/ws/onnv-tools-prc/SUNWspro/SS11/bin/cc -DHAVE_CONFIG_H -I. -I.. -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/X11/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/sfw/include -I/usr/sfw/include/freetype2 -I/usr/include/libpng12 -DSYSCONFDIR=\"/export/home/halton/work/dist/etc\" -I/usr/include/ast -g -c gvnc.c -KPIC -DPIC -o .libs/libgtk_vnc_1_0_la-gvnc.o
"blt.h", line 9: syntax error before or at: uint8
"blt.h", line 9: warning: undefined or missing type for: uint8
When I generate with "-E" and grep gvnc_fill_fast_, it give me
static void gvnc_fill_fast_8x8 ( struct gvnc * gvnc , uint8 _t * sp ,
gvnc_fill_fast_8x8 ( gvnc , bg , x , y , width , height );
gvnc_fill_fast_8x8 ( gvnc , fg ,
static void gvnc_fill_fast_8x16 ( struct gvnc * gvnc , uint8 _t * sp ,
gvnc_fill_fast_8x16 ( gvnc , bg , x , y , width , height );
gvnc_fill_fast_8x16 ( gvnc , fg ,
suncc generate "uint8 _t" instead of "uint8_t", while gcc does well. Too bad.
I've asked suncc email, no response yet.
Now I found a method to make suncc and gcc work both, and have a patch now,
please check the attachment.
Regards,
Halton.
diff -r d6f1a50dbb0b src/blt.h
--- a/src/blt.h Sun Oct 21 17:11:07 2007 -0300
+++ b/src/blt.h Thu Oct 25 22:33:04 2007 +0800
@@ -1,5 +1,5 @@
-#define src_pixel_t SPLICE(uint, SPLICE(SRC, _t))
-#define dst_pixel_t SPLICE(uint, SPLICE(DST, _t))
+#define src_pixel_t SPLICE(SPLICE(uint, SRC), _t)
+#define dst_pixel_t SPLICE(SPLICE(uint, DST), _t)
#define SUFFIX() SPLICE(SRC,SPLICE(x,DST))
#define BLIT SPLICE(gvnc_blt_, SUFFIX())
#define FILL SPLICE(gvnc_fill_, SUFFIX())
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]