[FFmpeg-devel] [PATCH] MinGW configure version checks

Stefano Sabatini stefano.sabatini-lala
Thu Oct 30 20:19:06 CET 2008


On date Sunday 2008-10-26 23:48:36 +0100, Stefano Sabatini encoded:
> On date Sunday 2008-10-26 20:23:16 +0000, M?ns Rullg?rd encoded:
> > Stefano Sabatini <stefano.sabatini-lala at poste.it> writes:
> > 
> > > On date Tuesday 2008-10-21 19:43:48 +0200, V?ctor Paesa encoded:
> > >> Hi,
> > >> 
> > >> David DeHaven said:
> > >> > On Oct 20, 2008, at 5:21 AM, Stefano Sabatini wrote:
> > >> >>> Index: configure
> > >> >>> ===================================================================
> > >> >>> --- configure	(revision 15638)
> > >> >>> +++ configure	(working copy)
> > >> >>> @@ -1316,6 +1316,10 @@
> > >> >>>         SHFLAGS='-shared -Wl,--output-def,$$(@:$(SLIBSUF)=.def) -
> > >> >>> Wl,--enable-runtime-pseudo-reloc -Wl,--enable-auto-image-base'
> > >> >>>         objformat="win32"
> > >> >>>         enable dos_paths
> > >> >>> +        check_cpp_condition _mingw.h "(__MINGW32_MAJOR_VERSION >
> > >> >>> 3) || (__MINGW32_MAJOR_VERSION == 3 && __MINGW32_MINOR_VERSION >=
> > >> >>> 15)" ||
> > >> >>> +            die "ERROR: MinGW runtime version must be >= 3.15." +
> > >> >>>     check_cpp_condition w32api.h "(__W32API_MAJOR_VERSION > 3)   ||
> > >> >>> (__W32API_MAJOR_VERSION == 3 && __W32API_MINOR_VERSION >= 12)" || +
> > >> >>>          die "ERROR: w32api version must be >= 3.12."
> > >> >>>         ;;
> > >> >>>     cygwin*)
> > >> >>>         target_os=cygwin
> > >> >>
> > >> >> My MinGW isn't working and I'm quite busy this week, so if there is
> > >> >> someone which can test the patch please do it, otherwise I'll do it
> > >> >> when I'll have more time to set up MinGW, but I don't know when this
> > >> >> will happen.
> > >> >
> > >> >
> > >> > I can check...
> > >> >
> > >> > mingwrt 3.15.1 + w32api 3.12: success
> > >> > mingwrt 3.14 + w32api 3.12: fail!
> > >> > mingwrt 3.15 + w32api 3.9: fail!
> > >> >
> > >> > Seems OK to me.
> > >> 
> > >> I cross-compiled for MinGW32 under Cygwin:
> > >> 
> > >> mingw-runtime 3.15.1-1 + w32api 3.12-1 : success
> > >> mingw-runtime 3.15.1-1 + w32api 3.11-1 : dies
> > >> 
> > >> so far that's fine.
> > >> 
> > >> But I believe the w32api>=3.12 is only required by the vfw stuff (capture
> > >> and Avisynth).
> > >> Hence the condition to die should check if one of either vfwcap_demuxer or
> > >> avisynth is enabled.
> > >
> > > Please check the patch below.
> > >
> > > Regards.
> > > -- 
> > > FFmpeg = Fast & Fiendish Meaningful Pitiful Elaborated Gadget
> > >
> > > Index: configure
> > > ===================================================================
> > > --- configure	(revision 15712)
> > > +++ configure	(working copy)
> > > @@ -1402,6 +1402,11 @@
> > >          SHFLAGS='-shared -Wl,--output-def,$$(@:$(SLIBSUF)=.def) -Wl,--enable-runtime-pseudo-reloc -Wl,--enable-auto-image-base'
> > >          objformat="win32"
> > >          enable dos_paths
> > > +        check_cpp_condition _mingw.h "(__MINGW32_MAJOR_VERSION > 3) || (__MINGW32_MAJOR_VERSION == 3 && __MINGW32_MINOR_VERSION >= 15)" ||
> > > +            die "ERROR: MinGW runtime version must be >= 3.15."
> > > +        { enabled avisynth || enabled vfwcap_demuxer; } &&
> > 
> > enabled_any
> 
> Fixed.
>  
> > > +            check_cpp_condition w32api.h "(__W32API_MAJOR_VERSION > 3) || (__W32API_MAJOR_VERSION == 3 && __W32API_MINOR_VERSION >= 12)" ||
> > > +            die "ERROR: if avisynth or vfwcap_demuxer is enabled then w32api version must be >= 3.12."
> > 
> > "ERROR: avisynth and vfwcap_demuxer require w32api 3.12 or later" or
> > similar sounds better to me.
> 
> OK.
> 
> Oh, and I missed again the error of the last time, fixed.
> 
> Regards.
> -- 
> FFmpeg = Fostering and Friendly Monstrous Prodigious Esoteric Genius

> Index: configure
> ===================================================================
> --- configure	(revision 15712)
> +++ configure	(working copy)
> @@ -1402,6 +1402,11 @@
>          SHFLAGS='-shared -Wl,--output-def,$$(@:$(SLIBSUF)=.def) -Wl,--enable-runtime-pseudo-reloc -Wl,--enable-auto-image-base'
>          objformat="win32"
>          enable dos_paths
> +        check_cpp_condition _mingw.h "(__MINGW32_MAJOR_VERSION > 3) || (__MINGW32_MAJOR_VERSION == 3 && __MINGW32_MINOR_VERSION >= 15)" ||
> +            die "ERROR: MinGW runtime version must be >= 3.15."
> +        enabled_any avisynth vfwcap_demuxer &&
> +            { check_cpp_condition w32api.h "(__W32API_MAJOR_VERSION > 3) || (__W32API_MAJOR_VERSION == 3 && __W32API_MINOR_VERSION >= 12)" ||
> +              die "ERROR: avisynth and vfwcap_demuxer require w32api version 3.12 or later"; }
>          ;;
>      cygwin*)
>          target_os=cygwin

I'll apply it at the end of the next weekend if there are no
objections, regards.
-- 
FFmpeg = Faboulous & Faboulous Multipurpose Portable Enhanced Gadget




More information about the ffmpeg-devel mailing list