[vlc-devel] [PATCH] src: Makefile.am: link to android_support on android

Alexandre Janniaux ajanni at videolabs.io
Thu Feb 13 17:09:14 CET 2020


Hi,

What is the preferred way? I put it there because I prefer
reading Makefile than autotools scripts. But to be honest
I don't know which one would be the more idiomatic or the
benefit of one way over the other.

Just for the context that I forgot, This link flag is
currently not used because we don't produce linked binaries
for android from this repository, but I made some work to
move the build script in this repository and have dynamic
libraries.

Regards,
--
Alexandre Janniaux
Videolabs

On Thu, Feb 13, 2020 at 04:47:12PM +0100, Steve Lhomme wrote:
> You could do it in the configure.ac in the android part like this:
>
> VLC_ADD_LIBS([libvlccore],[-landroid_support -lc++abi])
>
> Maybe the availability could also be checked.
>
> On 2020-02-13 15:57, Alexandre Janniaux wrote:
> > libvlccore needs functions like newlocale, which are available through
> > the -landroid_support link flag. As it also depends upon C++ runtime
> > libraries, especially for operator new and delete, link -lc++abi too.
> > ---
> >   src/Makefile.am | 6 ++++++
> >   1 file changed, 6 insertions(+)
> >
> > diff --git a/src/Makefile.am b/src/Makefile.am
> > index b6c5996837..d5035c5700 100644
> > --- a/src/Makefile.am
> > +++ b/src/Makefile.am
> > @@ -395,6 +395,12 @@ libvlccore_la_LIBADD = $(LIBS_libvlccore) \
> >   	$(LTLIBINTL) $(LTLIBICONV) \
> >   	$(IDN_LIBS) $(SOCKET_LIBS) $(LIBRT) $(LIBDL) $(LIBM)
> > +if HAVE_ANDROID
> > +# Android support exports newlocale, but it's written in C++
> > +# with calls to operator new/delete.
> > +libvlccore_la_LIBADD += -landroid_support -lc++abi
> > +endif
> > +
> >   if HAVE_WIN32
> >   libvlccore_la_SOURCES += \
> >   	win32/dirs.c \
> > --
> > 2.25.0
> >
> > _______________________________________________
> > 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