From: Tim Wilkinson (tim@transvirtual.com)
Date: Thu Feb 11 1999 - 16:58:11 EST
Yeah this is a problem - you need to use libungif 4.0 with the new version of kaffe since it contains some useful
hooks to get the GIF data - and as you've seen without it it won't compile and it's not possible to fall back on
the old system anymore (we were shipping bits of a fixed-up gif library before which probably meant we should pay
Unisys money or something).
We should detect this and either ignore gif and/or report the version problem.
Tim
Godmar Back wrote:
> The latest snap doesn't compile because of a problem in imggif.c
> that may be caused by an old version of gif_lib.h on my system (?)
> Specifically, GifFileType does not have a UserData element.
>
> In imggif.c, it says:
>
> typedef struct {
> unsigned char *buf;
> unsigned char *p;
> long remain;
> } BufferSource;
>
> int
> readGifBuffer ( GifFileType *gf, GifByteType* buf, int length )
> {
> BufferSource *psource = (BufferSource*)gf->UserData;
>
> if ( psource && (psource->remain >= length) ) {
> memcpy( buf, psource->p, length);
> psource->p += length;
> psource->remain -= length;
>
> return length;
> }
> else {
> return 0;
> }
> }
>
> However, my gif_lib.h file:
>
> /******************************************************************************
> * In order to make life a little bit easier when using the GIF file format, *
> * this library was written, and which does all the dirty work... *
> * *
> * Written by Gershon Elber, Jun. 1989 *
> * Hacks by Eric S. Raymond, Sep. 1992 *
> *******************************************************************************
> * History: *
> * 14 Jun 89 - Version 1.0 by Gershon Elber. *
> * 3 Sep 90 - Version 1.1 by Gershon Elber (Support for Gif89, Unique names). *
> * 15 Sep 90 - Version 2.0 by Eric S. Raymond (Changes to suoport GIF slurp) *
> * 26 Jun 96 - Version 3.0 by Eric S. Raymond (Full GIF89 support)
> ******************************************************************************/
>
> says:
>
> typedef struct GifFileType {
> int SWidth, SHeight, /* Screen dimensions. */
> SColorResolution, /* How many colors can we generate? */
> SBackGroundColor; /* I hope you understand this one... */
> ColorMapObject *SColorMap; /* NULL if not exists. */
> int ImageCount; /* Number of current image */
> GifImageDesc Image; /* Block describing current image */
> struct SavedImage *SavedImages; /* Use this to accumulate file state */
> VoidPtr Private; /* Don't mess with this! */
> } GifFileType;
>
> and hence
>
> /n/marker/x/gback/transvirtual/kaffe/libraries/clib/awt/X/imggif.c: In function `readGifBuffer':
> /n/marker/x/gback/transvirtual/kaffe/libraries/clib/awt/X/imggif.c:170: structure has no member named `UserData'
>
> Do I have an outdated version? What version do I need? Should we check in
> configure.in for that version?
>
> - Godmar
-- Tim Wilkinson Tel: +1 510 704 1660 Transvirtual Technologies, Inc., Fax: +1 510 704 1893 Berkeley, CA, USA. Email: tim@transvirtual.com
This archive was generated by hypermail 2b29 : Sat Sep 23 2000 - 19:58:06 EDT