[Android] buildsystem: remove usage of GRADLE_VLC_SRC_DIRS

Steve Lhomme git at videolan.org
Mon Jun 16 13:47:41 UTC 2025


vlc-android | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Thu Jun 12 09:56:03 2025 +0200| [a382cce22146b9bd80a2c6fbf08e4ffee8f3f1a4] | committer: Duncan McNamara

buildsystem: remove usage of GRADLE_VLC_SRC_DIRS

In libvlcjni VLC_OUT_PATH is set to <vlc>/build-android-<triplet>/ndk and only contains temporary files:
- libvlcjni-modules.c
- libvlcjni-symbols.c
They are not used in the java build.

There is not VLC_OUT_PATH/libs folder after libvlcjni is built.
libvlcjni.so is in libvlcjni/jni/libs which we already handle.

And when building in Android Studio we would add a folder "null" in the srcDir (via libvlcjni/libvlc/build.gradle).

> https://code.videolan.org/videolan/vlc-android/commit/a382cce22146b9bd80a2c6fbf08e4ffee8f3f1a4
---

 buildsystem/compile.sh | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/buildsystem/compile.sh b/buildsystem/compile.sh
index b50af577c5..e8b25225e7 100755
--- a/buildsystem/compile.sh
+++ b/buildsystem/compile.sh
@@ -355,8 +355,6 @@ if [ "$NO_ML" != 1 ]; then
     cp -a medialibrary/jni/obj/local/${ANDROID_ABI}/*.so ${OUT_DBG_DIR}
 fi
 
-GRADLE_VLC_SRC_DIRS="$VLC_OUT_PATH/libs"
-
 ##################
 # Compile the UI #
 ##################
@@ -379,7 +377,7 @@ if [ -n "$M2_REPO" ]; then
 fi
 
 if [ "$BUILD_LIBVLC" = 1 ];then
-    GRADLE_VLC_SRC_DIRS="$GRADLE_VLC_SRC_DIRS" GRADLE_ABI=$GRADLE_ABI ./gradlew ${gradle_prop} -p ${VLC_LIBJNI_PATH}/libvlc assemble${BUILDTYPE}
+    GRADLE_ABI=$GRADLE_ABI ./gradlew ${gradle_prop} -p ${VLC_LIBJNI_PATH}/libvlc assemble${BUILDTYPE}
     RUN=0
 elif [ "$BUILD_MEDIALIB" = 1 ]; then
     GRADLE_ABI=$GRADLE_ABI ./gradlew ${gradle_prop} -p medialibrary assemble${BUILDTYPE}
@@ -391,14 +389,14 @@ else
         ACTION="assemble"
     fi
     TARGET="${ACTION}${BUILDTYPE}"
-    GRADLE_VLC_SRC_DIRS="$GRADLE_VLC_SRC_DIRS" ./gradlew ${gradle_prop} $TARGET
+    ./gradlew ${gradle_prop} $TARGET
     if [ "$BUILDTYPE" = "Release" ] && [ "$ACTION" = "assemble" ]; then
         TARGET="bundle${BUILDTYPE}"
-        GRADLE_VLC_SRC_DIRS="$GRADLE_VLC_SRC_DIRS" ./gradlew ${gradle_prop} $TARGET
+        ./gradlew ${gradle_prop} $TARGET
     fi
     if [ "$TEST" = 1 ]; then
         TARGET="application:vlc-android:install${BUILDTYPE}AndroidTest"
-        GRADLE_VLC_SRC_DIRS="$GRADLE_VLC_SRC_DIRS" ./gradlew ${gradle_prop} $TARGET
+        ./gradlew ${gradle_prop} $TARGET
 
         echo -e "\n===================================\nRun following for UI tests:"
         echo "adb shell am instrument -w -m -e clearPackageData true   -e package org.videolan.vlc -e debug false org.videolan.vlc.debug.test/org.videolan.vlc.MultidexTestRunner 1> result_UI_test.txt"



More information about the Android mailing list