[FFmpeg-devel] [PATCH 2/4] Define __EXTENSIONS__ to enable struct ip_mreq access on OpenSolaris.

Måns Rullgård mans
Sun Sep 28 15:23:57 CEST 2008


Diego 'Flameeyes' Petten? <flameeyes at gmail.com> writes:

> Like for recent GLIBC versions, even OpenSolaris hides the ip_mreq
> structure by default on C99/POSIX.1-2001 code, to access it, the
> __EXTENSIONS__ macro has to be defined.
>
> Define it so that udp.c builds properly on OpenSolaris.
> ---
>
>  libavformat/udp.c |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
>
> diff --git a/libavformat/udp.c b/libavformat/udp.c
> index 6a2e642..7c8fef9 100644
> --- a/libavformat/udp.c
> +++ b/libavformat/udp.c
> @@ -25,6 +25,7 @@
>   */
>
>  #define _BSD_SOURCE     /* Needed for using struct ip_mreq with recent glibc */
> +#define __EXTENSIONS__  /* Needed for using struct ip_mreq with OpenSolaris */

Might this have some unpleasant side-effects on other systems?  I
wouldn't put it beyond glibc to do something really nasty...

-- 
M?ns Rullg?rd
mans at mansr.com




More information about the ffmpeg-devel mailing list