On 3/14/2012 11:07 AM, stefano franchi wrote:
> Compilation of player fails on a recently updated archlinux 64 system with:
>
> /home/stefano/builds/player/src/player-3.0.2/server/drivers/shell/readlog.cc:
> In member function ‘virtual void ReadLog::Main()’:
> /home/stefano/builds/player/src/player-3.0.2/server/drivers/shell/readlog.cc:668:43:
> error: cannot convert ‘FILE* {aka _IO_FILE*}’ to ‘gzFile’ for argument
> ‘1’ to ‘off_t gzseek(gzFile, off_t, int)’
> /home/stefano/builds/player/src/player-3.0.2/server/drivers/shell/readlog.cc:714:62:
> error: cannot convert ‘FILE* {aka _IO_FILE*}’ to ‘gzFile’ for argument
> ‘1’ to ‘char* gzgets(gzFile, char*, int)’
> make[2]: *** [server/libplayerdrivers/CMakeFiles/playerdrivers.dir/__/drivers/shell/readlog.o]
> Error 1
> make[1]: *** [server/libplayerdrivers/CMakeFiles/playerdrivers.dir/all] Error 2
> make: *** [all] Error 2
>
> This may be related to the API change in zlib from 1.2.5 to 1.2.6,
> which is now installed on my system. According to another archlinux
> user, there has been a change in zlib.h in 1.2.6:
>
> - typedef voidp gzFile; /* opaque gzip file descriptor */
> + typedef struct gzFile_s *gzFile; /* semi-opaque gzip file descriptor */
>
>
> However, this is as far as I got. I took a look at readlog.cc, but I
> don't know how to fix the two offending lines (assuming I got the
> diagnosis right).
>
>
> Cheers,
>
> Stefano
>
>
According to a patch[1] I found for a related error, it looks like you
need to cast the FILE* pointers to gzFile. For example, in readlog.cc
you'd probably have to change the line
ret = gzseek(this->file,0,SEEK_SET);
to
ret = gzseek((gzFile)this->file,0,SEEK_SET);
I don't have access to an arch box at the moment, so I can't test it
myself. Let me know how it goes, if it works we'll put the fix into SVN.
Rich
------------------------------------------------------------------------------
This SF email is sponsosred by:
Try Windows Azure free for 90 days Click Here
http://p.sf.net/sfu/sfd2d-msazure_______________________________________________
Playerstage-users mailing list
Playerstage-users@...
https://lists.sourceforge.net/lists/listinfo/playerstage-users