diff options
author | Arun Raghavan <arun@arunraghavan.net> | 2016-09-04 10:12:52 +0300 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2016-09-04 10:12:52 +0300 |
commit | a5cdde9119f038a1eb365aca20faa9741a38e788 (patch) | |
tree | cb762eb3485d4698e5debe89521c3b30fd1f0b8a | |
parent | fc41dd802f499ab4fc73c720a2f35803b5b995a8 (diff) |
playback/player/android: Switch to building against universal packages
-rw-r--r-- | playback/player/android/app/build.gradle | 2 | ||||
-rw-r--r-- | playback/player/android/app/src/main/jni/Android.mk | 23 | ||||
-rw-r--r-- | playback/player/android/app/src/main/jni/Application.mk | 1 | ||||
-rw-r--r-- | playback/player/android/gradle.properties | 3 |
4 files changed, 14 insertions, 15 deletions
diff --git a/playback/player/android/app/build.gradle b/playback/player/android/app/build.gradle index 50b135e..5119ca3 100644 --- a/playback/player/android/app/build.gradle +++ b/playback/player/android/app/build.gradle @@ -7,7 +7,7 @@ def getNdkCommandLine(ndkRoot, target) { if (project.hasProperty('gstAndroidRoot')) gstRoot = project.gstAndroidRoot else - gstRoot = System.properties['user.home'] + '/cerbero/dist/android_arm' + throw new GradleException('"gstAndroidRoot" must be defined in your gradle properties to the top level directory of the unpacked universal GStreamer Android binaries') if (ndkRoot == null) throw new GradleException('NDK not configured') diff --git a/playback/player/android/app/src/main/jni/Android.mk b/playback/player/android/app/src/main/jni/Android.mk index 65e2044..593eaae 100644 --- a/playback/player/android/app/src/main/jni/Android.mk +++ b/playback/player/android/app/src/main/jni/Android.mk @@ -9,25 +9,22 @@ LOCAL_SHARED_LIBRARIES := gstreamer_android LOCAL_LDLIBS := -llog -landroid include $(BUILD_SHARED_LIBRARY) +ifndef GSTREAMER_ROOT_ANDROID +$(error GSTREAMER_ROOT_ANDROID is not defined!) +endif + ifeq ($(TARGET_ARCH_ABI),armeabi) -GSTREAMER_ROOT := $(GSTREAMER_ROOT_ARM) +GSTREAMER_ROOT := $(GSTREAMER_ROOT_ANDROID)/arm else ifeq ($(TARGET_ARCH_ABI),armeabi-v7a) -GSTREAMER_ROOT := $(GSTREAMER_ROOT_ARMV7) +GSTREAMER_ROOT := $(GSTREAMER_ROOT_ANDROID)/armv7 else ifeq ($(TARGET_ARCH_ABI),arm64-v8a) -GSTREAMER_ROOT := $(GSTREAMER_ROOT_ARM64) +GSTREAMER_ROOT := $(GSTREAMER_ROOT_ANDROID)/arm64 else ifeq ($(TARGET_ARCH_ABI),x86) -GSTREAMER_ROOT := $(GSTREAMER_ROOT_X86) +GSTREAMER_ROOT := $(GSTREAMER_ROOT_ANDROID)/x86 else ifeq ($(TARGET_ARCH_ABI),x86_64) -GSTREAMER_ROOT := $(GSTREAMER_ROOT_X86_64) +GSTREAMER_ROOT := $(GSTREAMER_ROOT_ANDROID)/x86_64 else -$(error Target arch ABI not supported) -endif - -ifndef GSTREAMER_ROOT -ifndef GSTREAMER_ROOT_ANDROID -$(error GSTREAMER_ROOT_ANDROID is not defined!) -endif -GSTREAMER_ROOT := $(GSTREAMER_ROOT_ANDROID) +$(error Target arch ABI not supported: $(TARGET_ARCH_ABI)) endif GSTREAMER_NDK_BUILD_PATH := $(GSTREAMER_ROOT)/share/gst-android/ndk-build/ diff --git a/playback/player/android/app/src/main/jni/Application.mk b/playback/player/android/app/src/main/jni/Application.mk index 87c0990..9e74937 100644 --- a/playback/player/android/app/src/main/jni/Application.mk +++ b/playback/player/android/app/src/main/jni/Application.mk @@ -1 +1,2 @@ APP_PLATFORM = 15 +APP_ABI = armeabi armeabi-v7a arm64-v8a x86 x86_64 diff --git a/playback/player/android/gradle.properties b/playback/player/android/gradle.properties index 1d3591c..a2a6ee4 100644 --- a/playback/player/android/gradle.properties +++ b/playback/player/android/gradle.properties @@ -15,4 +15,5 @@ # When configured, Gradle will run in incubating parallel mode. # This option should only be used with decoupled projects. More details, visit # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects -# org.gradle.parallel=true
\ No newline at end of file +# org.gradle.parallel=true +gstAndroidRoot=/home/slomo/Projects/gstreamer/head/gst-examples/playback/player/gst-android |