[FFmpeg-devel] FFmpeg and Solaris: offset_t conflict

Diego Biurrun diego
Fri Oct 3 02:02:54 CEST 2008

On Fri, Oct 03, 2008 at 12:26:08AM +0100, M?ns Rullg?rd wrote:
> flameeyes at gmail.com (Diego 'Flameeyes' Petten?) writes:
> > Under solaris the offset_t type is actually declared by the system
> > headers, which means that the definition in FFmpeg itself is redefining
> > a system type.
> >
> > I have no idea why it does not have an ff_ prefix, but I think it should
> > have; unfortunately this change would break API since the offset_t file
> > would be disappearing on Linux and other OSes and subtly change under
> > Solaris.
> >
> > I'm not attaching a patch since it would be 61k and I'm not sure what
> > the best course of action would be for this. For what matters, the
> > change can be generated with a simple GNU sed command line:
> >
> > sed -i -e 's:\<offset_t\>:ff_offset_t:g' libavformat/*.{c,h}
> Something clearly needs to be done.  Is there any reason for not using
> int64_t directly?  Gratuitous use of typedef only makes code harder to
> read.

Can't we check for it and typedef it conditionally similar to what we do
for socklen_t?


More information about the ffmpeg-devel mailing list