[vlc-devel] [PATCH] contrib: don't pass compiler environment variables to Meson when cross compiling

Alexandre Janniaux ajanni at videolabs.io
Tue Dec 17 15:11:43 CET 2019


Hi,

This is a variation over patches from Marvin there, after
meson has been fixed to support this correctly:

https://mailman.videolan.org/pipermail/vlc-devel/2019-September/127942.html

LGTM for me,

Regards,
--
Alexandre Janniaux
Videolabs

On Tue, Dec 17, 2019 at 02:50:29PM +0100, Steve Lhomme wrote:
> This patch makes the "package/win32: use VLC_EXTRA_CFLAGS environment
> variable" patch unneeded.
>
> Only the extra compiler flags can be added separately. It also makes the use
> of CFLAGS in the environment work safely when cross compiling with Meson
> (they are in the cross compiler).
>
> Thanks to Alexandre Janniaux and Marvin Scholz for the help.
>
> On 2019-12-17 14:46, Steve Lhomme wrote:
> > So it doesn't try to use them with the native compiler
> > ---
> >   contrib/src/main.mak | 11 ++++++-----
> >   1 file changed, 6 insertions(+), 5 deletions(-)
> >
> > diff --git a/contrib/src/main.mak b/contrib/src/main.mak
> > index 7d701626ba4..575f8548144 100644
> > --- a/contrib/src/main.mak
> > +++ b/contrib/src/main.mak
> > @@ -410,17 +410,18 @@ ifeq ($(V),1)
> >   CMAKE += -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON
> >   endif
> > -MESON = meson --default-library static --prefix "$(PREFIX)" --backend ninja \
> > -	-Dlibdir=lib
> > +ifdef HAVE_CROSS_COMPILE
> > +MESON = CFLAGS= CXXFLAGS= LDFLAGS= CPPFLAGS= meson --cross-file $(abspath crossfile.meson)
> > +else
> > +MESON = meson
> > +endif
> > +MESON += --default-library static --prefix "$(PREFIX)" --backend ninja -Dlibdir=lib
> >   ifndef WITH_OPTIMIZATION
> >   MESON += --buildtype debug
> >   else
> >   MESON += --buildtype release
> >   endif
> > -ifdef HAVE_CROSS_COMPILE
> > -MESON += --cross-file $(abspath crossfile.meson)
> > -endif
> >   ifdef GPL
> >   REQUIRE_GPL =
> > --
> > 2.17.1
> >
> > _______________________________________________
> > vlc-devel mailing list
> > To unsubscribe or modify your subscription options:
> > https://mailman.videolan.org/listinfo/vlc-devel
> >
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel


More information about the vlc-devel mailing list