Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / libraries / SDL2_mixer / SDL_mixer-2.0-incompatible-pointer-comparison-fix.patch
blob76fff3fa63e25e28bd80c8b2d56a825924b7e413
1 --- a/music_mpg123.c 2018-10-31 10:59:00.000000000 -0400
2 +++ b/music_mpg123.c 2023-09-05 21:31:51.529191521 -0400
3 @@ -48,7 +48,11 @@
4 int (*mpg123_open_handle)(mpg123_handle *mh, void *iohandle);
5 const char* (*mpg123_plain_strerror)(int errcode);
6 void (*mpg123_rates)(const long **list, size_t *number);
7 +#if (MPG123_API_VERSION >= 45) /* api (but not abi) change as of mpg123-1.26.0 */
8 + int (*mpg123_read)(mpg123_handle *mh, void *outmemory, size_t outmemsize, size_t *done );
9 +#else
10 int (*mpg123_read)(mpg123_handle *mh, unsigned char *outmemory, size_t outmemsize, size_t *done );
11 +#endif
12 int (*mpg123_replace_reader_handle)( mpg123_handle *mh, ssize_t (*r_read) (void *, void *, size_t), off_t (*r_lseek)(void *, off_t, int), void (*cleanup)(void*) );
13 off_t (*mpg123_seek)( mpg123_handle *mh, off_t sampleoff, int whence );
14 const char* (*mpg123_strerror)(mpg123_handle *mh);
15 @@ -95,7 +99,11 @@
16 FUNCTION_LOADER(mpg123_open_handle, int (*)(mpg123_handle *mh, void *iohandle))
17 FUNCTION_LOADER(mpg123_plain_strerror, const char* (*)(int errcode))
18 FUNCTION_LOADER(mpg123_rates, void (*)(const long **list, size_t *number));
19 +#if (MPG123_API_VERSION >= 45) /* api (but not abi) change as of mpg123-1.26.0 */
20 + FUNCTION_LOADER(mpg123_read, int (*)(mpg123_handle *mh, void *outmemory, size_t outmemsize, size_t *done ))
21 +#else
22 FUNCTION_LOADER(mpg123_read, int (*)(mpg123_handle *mh, unsigned char *outmemory, size_t outmemsize, size_t *done ))
23 +#endif
24 FUNCTION_LOADER(mpg123_replace_reader_handle, int (*)( mpg123_handle *mh, ssize_t (*r_read) (void *, void *, size_t), off_t (*r_lseek)(void *, off_t, int), void (*cleanup)(void*) ))
25 FUNCTION_LOADER(mpg123_seek, off_t (*)( mpg123_handle *mh, off_t sampleoff, int whence ))
26 FUNCTION_LOADER(mpg123_strerror, const char* (*)(mpg123_handle *mh))