Browse Source

buildsystem: libvlc: move lua linkage hack

In libVLC 3.x, the lua contrib didn't expose a pkg-config file so it
wasn't picked by the pkg-config probing in the compile-libvlc.sh script.

The plan is to expose it on libVLC 4.x, so to keep compatibility with
both version only add the lua link library if the pkg-config file
doesn't exist.

(cherry picked from commit fd4d934ad3)
3.3.x
Alexandre Janniaux 6 years ago
committed by Nicolas Pomepuy
parent
commit
8abb66e356
  1. 9
      buildsystem/compile-libvlc.sh

9
buildsystem/compile-libvlc.sh

@ -645,6 +645,14 @@ rm ${REDEFINED_VLC_MODULES_DIR}/syms
VLC_MODULES=$(avlc_find_modules ${REDEFINED_VLC_MODULES_DIR})
VLC_CONTRIB_LDFLAGS=$(for i in $(/bin/ls $VLC_CONTRIB/lib/pkgconfig/*.pc); do avlc_pkgconfig --libs $i; done |xargs)
# Lua contrib doesn't expose a pkg-config file with libvlc 3.x and is
# not probed by the previous command in VLC_CONTRIB_LDFLAGS, so probe
# whether it was detected or add it manually to the LDFLAGS.
if ! avlc_pkgconfig --exists lua; then
VLC_CONTRIB_LDFLAGS="$VLC_CONTRIB_LDFLAGS '$VLC_CONTRIB/lib/liblua.a'"
fi
echo -e "ndk-build vlc"
touch $VLC_OUT_PATH/dummy.cpp
@ -666,7 +674,6 @@ LOCAL_LDLIBS := \
$(VLC_CONTRIB_LDFLAGS) \
-ldl -lz -lm -llog \
-la52 -ljpeg \
-llua \
$(VLC_LDFLAGS)
LOCAL_CXXFLAGS := -std=c++11
include $(BUILD_SHARED_LIBRARY)

Loading…
Cancel
Save