[cairo] Changes for OpenWatcom compatibility

Doodle doodle at scenergy.dfmk.hu
Fri Aug 19 00:29:03 PDT 2005


Hi all,

Here are some changes I had to make to be able to compile
the libraries with OpenWatcom.

Is is possibile to put these changes into the official
source code?

So, changes in Cairo (0.9.2):
- The OpenWatcom compiler complains about cairoint.h line 222,
   ("typedef enum _cairo_clip_mode cairo_clip_mode_t;")
   that it doesn't know about _cairo_clip_mode. I've moved the
   following lines from cairo_clip_private.h to cairoint.h to
   solve it:

   typedef enum cairo_clip_mode {
       CAIRO_CLIP_MODE_PATH,
       CAIRO_CLIP_MODE_REGION,
       CAIRO_CLIP_MODE_MASK
   } cairo_clip_mode_t;

   Is there a reason for keeping this typedef separate in
   cairo_clip_private.h while all the other typedefs are
   in cairoint.h?

Changes in libsvg (0.1.4):
- OW doesn't like the _svg_image_read_png() function in svg_image.c,
   because it can't handle arrays which are defined with size from a
   variable (PNG_SIG_SIZE). However, this variable never changes,
   so I've changed line 216 from
   "static const int PNG_SIG_SIZE 8;"
   to
   "#define PNG_SIG_SIZE 8"

- There are some function declaraions at the beginning of
   svg_parser_expat.c, which functions are implemented in a different
   .c file. These functions are declared to be static, which is
   clearly an error, because their implementation can not be found
   in this .c file (and OW complains about it).

   The static keyword has to be removed from these function declarations.



Doodle



More information about the cairo mailing list