On Sunday 28 February 2010 11:23:30 pm Marcus Meissner wrote:
A library should be ever built against one model and not change function ABI depending on a preprocessor define ... This will just break in funny ways.
In libmpg123 1.10.0 it does not do evil hacks for me, it has #if 0 around these parts (see the header included in the patch). Seems to have been an earlier try.
I believe it puts #if 0 when the lib is built without _FILE_OFFSET_BITS=64. In my mpg123.h (which is built with _FILE_OFFSET_BITS=64), it has #if 1.
Seems newer versions/trunk just takes the base function name and appends the _FILE_OFFSET_BITS value, which still causes ABI issues http://mpg123.de/cgi-bin/viewvc.cgi/trunk/src/libmpg123/mpg123.h.in
That's the remaining thing that bugs me about mpg123, how it has a different ABI with the same lib version depending on its build options. libFLAC and libvorbisfile, at least, have the sense to use a 64-bit offset type explicitly, instead of using off_t.