GNOME Bugzilla – Bug 797242
GStreamer Android fails to build with latest NDK (r18)
Last modified: 2018-10-03 15:37:18 UTC
I updated Android Studio to latest SDK and NDK, and tried to build the Android tutorials, as well as the gst-examples with Android Studio on mac. I tried this with both the 1.14.2 and 1.14.3 SDK package. With the latest NDK (18.0.5002713) every attempt to build results in the following error: Build command failed. Error while executing process /Users/<username>/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/<path to project>/android/app/src/main/jni/Android.mk NDK_APPLICATION_MK=/Users/<path to project>/android/app/src/main/jni/Application.mk APP_ABI=x86 NDK_ALL_ABIS=x86 NDK_DEBUG=1 APP_PLATFORM=android-23 NDK_OUT=/Users/<path to project>/android/app/build/intermediates/ndkBuild/safekeep/debug/obj NDK_LIBS_OUT=/Users/<path to project>/android/app/build/intermediates/ndkBuild/safekeep/debug/lib NDK_APPLICATION_MK=src/main/jni/Application.mk GSTREAMER_JAVA_SRC_DIR=src/main/java GSTREAMER_ROOT_ANDROID=/Users/<path to android sdk>/gstreamer-1.0-android-universal-1.14.2 GSTREAMER_ASSETS_DIR=src/main/assets /Users/<path to project>/android/app/build/intermediates/ndkBuild/<targetname>/debug/obj/local/x86/libgstvideoplayer.so} [x86] Compile : gstvideoplayer <= GstBackend.c GStreamer : [GEN] => gst-build-x86/gstreamer_android.c GStreamer : [COMPILE] => gst-build-x86/gstreamer_android.c clang: error: argument unused during compilation: ‘--gcc-toolchain=/Users/<username>/Library/Android/sdk/ndk-bundle/toolchains/x86-4.9/prebuilt/darwin-x86_64’ [-Werror,-Wunused-command-line-argument] make: *** [gst-build-x86/gstreamer_android.o] Error 1 With NDK (17.2.4988734) the builds succeed as expected. Since you're recommending in your documentation to update to the latest NDK, I believe this should be addressed.
Thanks for taking the time to report this. This particular bug has already been reported into our bug tracking system, but please feel free to report any further bugs you find. *** This bug has been marked as a duplicate of bug 759737 ***