[vlc-devel] [PATCH 01/12] rename libiomx-<sdk_str> to libiomx.<sdk_int>
Thomas Guillem
thomas at gllm.fr
Fri Nov 14 17:10:16 CET 2014
---
Makefile | 4 +--
libvlc/jni/Android.mk | 40 +++++++++++++++---------------
libvlc/src/org/videolan/libvlc/LibVLC.java | 10 ++++----
3 files changed, 27 insertions(+), 27 deletions(-)
diff --git a/Makefile b/Makefile
index 1870d4c..3c0c2c5 100644
--- a/Makefile
+++ b/Makefile
@@ -15,12 +15,12 @@ LIBVLC_LIBS = libvlcjni
ifneq ($(HAVE_64),1)
# Can't link with 32bits symbols.
# Not a problem since MediaCodec should work on 64bits devices (android-21)
-LIBVLC_LIBS += libiomx-ics libiomx-hc libiomx-gingerbread
+LIBVLC_LIBS += libiomx.14 libiomx.13 libiomx.10
endif
# The following iomx libs are used for DEBUG only.
# (after android Jelly Bean, we prefer to use MediaCodec instead of iomx)
-#LIBVLC_LIBS += libiomx-kk libiomx-jbmr2
+#LIBVLC_LIBS += libiomx.19 libiomx.18
LIBVLCJNI= $(addprefix $(SRC)/obj/local/$(ARCH)/,$(addsuffix .so,$(LIBVLC_LIBS)))
diff --git a/libvlc/jni/Android.mk b/libvlc/jni/Android.mk
index 0ce845e..4425516 100644
--- a/libvlc/jni/Android.mk
+++ b/libvlc/jni/Android.mk
@@ -95,46 +95,46 @@ LIBIOMX_SRC_FILES_COMMON += ../$(VLC_SRC_DIR)/modules/video_output/android/nativ
endif
# no hwbuffer for gingerbread
-LIBIOMX_INCLUDES_gingerbread := $(LIBIOMX_INCLUDES_COMMON) \
+LIBIOMX_INCLUDES_10 := $(LIBIOMX_INCLUDES_COMMON) \
$(ANDROID_SYS_HEADERS_GINGERBREAD)/frameworks/base/include \
$(ANDROID_SYS_HEADERS_GINGERBREAD)/system/core/include \
$(ANDROID_SYS_HEADERS_GINGERBREAD)/hardware/libhardware/include
-LIBIOMX_LDLIBS_gingerbread := $(LIBIOMX_LDLIBS_COMMON)
-LIBIOMX_CFLAGS_gingerbread := $(LIBIOMX_CFLAGS_COMMON) -DANDROID_API=10
+LIBIOMX_LDLIBS_10 := $(LIBIOMX_LDLIBS_COMMON)
+LIBIOMX_CFLAGS_10 := $(LIBIOMX_CFLAGS_COMMON)
-LIBIOMX_INCLUDES_hc := $(LIBIOMX_INCLUDES_COMMON) \
+LIBIOMX_INCLUDES_13 := $(LIBIOMX_INCLUDES_COMMON) \
$(ANDROID_SYS_HEADERS_HC)/frameworks/base/include \
$(ANDROID_SYS_HEADERS_HC)/frameworks/base/native/include \
$(ANDROID_SYS_HEADERS_HC)/system/core/include \
$(ANDROID_SYS_HEADERS_HC)/hardware/libhardware/include
-LIBIOMX_LDLIBS_hc := $(LIBIOMX_LDLIBS_COMMON)
-LIBIOMX_CFLAGS_hc := $(LIBIOMX_CFLAGS_COMMON) -DANDROID_API=13
+LIBIOMX_LDLIBS_13 := $(LIBIOMX_LDLIBS_COMMON)
+LIBIOMX_CFLAGS_13 := $(LIBIOMX_CFLAGS_COMMON)
-LIBIOMX_INCLUDES_ics := $(LIBIOMX_INCLUDES_COMMON) \
+LIBIOMX_INCLUDES_14 := $(LIBIOMX_INCLUDES_COMMON) \
$(ANDROID_SYS_HEADERS_ICS)/frameworks/base/include \
$(ANDROID_SYS_HEADERS_ICS)/frameworks/base/native/include \
$(ANDROID_SYS_HEADERS_ICS)/system/core/include \
$(ANDROID_SYS_HEADERS_ICS)/hardware/libhardware/include
-LIBIOMX_LDLIBS_ics := $(LIBIOMX_LDLIBS_COMMON) $(LIBIOMX_LDLIBS_HWBUFFER)
-LIBIOMX_CFLAGS_ics := $(LIBIOMX_CFLAGS_COMMON) -DANDROID_API=14
+LIBIOMX_LDLIBS_14 := $(LIBIOMX_LDLIBS_COMMON) $(LIBIOMX_LDLIBS_HWBUFFER)
+LIBIOMX_CFLAGS_14 := $(LIBIOMX_CFLAGS_COMMON)
-LIBIOMX_SRC_FILES_jbmr2 := $(LIBIOMX_SRC_FILES_COMMON) $(LIBIOMX_SRC_FILES_HWBUFFER)
-LIBIOMX_INCLUDES_jbmr2 := $(LIBIOMX_INCLUDES_COMMON) \
+LIBIOMX_SRC_FILES_18 := $(LIBIOMX_SRC_FILES_COMMON) $(LIBIOMX_SRC_FILES_HWBUFFER)
+LIBIOMX_INCLUDES_18 := $(LIBIOMX_INCLUDES_COMMON) \
$(ANDROID_SYS_HEADERS_JBMR2)/frameworks/native/include \
$(ANDROID_SYS_HEADERS_JBMR2)/frameworks/av/include \
$(ANDROID_SYS_HEADERS_JBMR2)/system/core/include \
$(ANDROID_SYS_HEADERS_JBMR2)/hardware/libhardware/include
-LIBIOMX_LDLIBS_jbmr2 := $(LIBIOMX_LDLIBS_COMMON) $(LIBIOMX_LDLIBS_HWBUFFER)
-LIBIOMX_CFLAGS_jbmr2 := $(LIBIOMX_CFLAGS_COMMON) $(LIBIOMX_CFLAGS_HWBUFFER) -DANDROID_API=18
+LIBIOMX_LDLIBS_18 := $(LIBIOMX_LDLIBS_COMMON) $(LIBIOMX_LDLIBS_HWBUFFER)
+LIBIOMX_CFLAGS_18 := $(LIBIOMX_CFLAGS_COMMON) $(LIBIOMX_CFLAGS_HWBUFFER)
-LIBIOMX_SRC_FILES_kk := $(LIBIOMX_SRC_FILES_COMMON) $(LIBIOMX_SRC_FILES_HWBUFFER)
-LIBIOMX_INCLUDES_kk := $(LIBIOMX_INCLUDES_COMMON) \
+LIBIOMX_SRC_FILES_19 := $(LIBIOMX_SRC_FILES_COMMON) $(LIBIOMX_SRC_FILES_HWBUFFER)
+LIBIOMX_INCLUDES_19 := $(LIBIOMX_INCLUDES_COMMON) \
$(ANDROID_SYS_HEADERS_KK)/frameworks/native/include \
$(ANDROID_SYS_HEADERS_KK)/frameworks/av/include \
$(ANDROID_SYS_HEADERS_KK)/system/core/include \
$(ANDROID_SYS_HEADERS_KK)/hardware/libhardware/include
-LIBIOMX_LDLIBS_kk := $(LIBIOMX_LDLIBS_COMMON) $(LIBIOMX_LDLIBS_HWBUFFER)
-LIBIOMX_CFLAGS_kk := $(LIBIOMX_CFLAGS_COMMON) $(LIBIOMX_CFLAGS_HWBUFFER) -DANDROID_API=19
+LIBIOMX_LDLIBS_19 := $(LIBIOMX_LDLIBS_COMMON) $(LIBIOMX_LDLIBS_HWBUFFER)
+LIBIOMX_CFLAGS_19 := $(LIBIOMX_CFLAGS_COMMON) $(LIBIOMX_CFLAGS_HWBUFFER)
define build_iomx
include $(CLEAR_VARS)
@@ -142,10 +142,10 @@ LOCAL_MODULE := $(1)
LOCAL_SRC_FILES := $(LIBIOMX_SRC_FILES_COMMON)
LOCAL_C_INCLUDES := $(LIBIOMX_INCLUDES_$(2))
LOCAL_LDLIBS := $(LIBIOMX_LDLIBS_$(2))
-LOCAL_CFLAGS := $(LIBIOMX_CFLAGS_$(2))
+LOCAL_CFLAGS := $(LIBIOMX_CFLAGS_$(2)) -DANDROID_API=$(2)
include $(BUILD_SHARED_LIBRARY)
endef
# call build_iomx for each libiomx-* in LIBVLC_LIBS
-$(foreach IOMX_MODULE,$(filter libiomx-%,$(LIBVLC_LIBS)), \
- $(eval $(call build_iomx,$(IOMX_MODULE),$(subst libiomx-,,$(IOMX_MODULE)))))
+$(foreach IOMX_MODULE,$(filter libiomx.%,$(LIBVLC_LIBS)), \
+ $(eval $(call build_iomx,$(IOMX_MODULE),$(subst libiomx.,,$(IOMX_MODULE)))))
diff --git a/libvlc/src/org/videolan/libvlc/LibVLC.java b/libvlc/src/org/videolan/libvlc/LibVLC.java
index 790855a..cebad99 100644
--- a/libvlc/src/org/videolan/libvlc/LibVLC.java
+++ b/libvlc/src/org/videolan/libvlc/LibVLC.java
@@ -115,15 +115,15 @@ public class LibVLC {
static {
try {
if (Build.VERSION.SDK_INT <= Build.VERSION_CODES.GINGERBREAD_MR1)
- System.loadLibrary("iomx-gingerbread");
+ System.loadLibrary("iomx.10");
else if (Build.VERSION.SDK_INT <= Build.VERSION_CODES.HONEYCOMB_MR2)
- System.loadLibrary("iomx-hc");
+ System.loadLibrary("iomx.13");
else if (Build.VERSION.SDK_INT <= Build.VERSION_CODES.JELLY_BEAN_MR1)
- System.loadLibrary("iomx-ics");
+ System.loadLibrary("iomx.14");
else if (Build.VERSION.SDK_INT <= Build.VERSION_CODES.JELLY_BEAN_MR2)
- System.loadLibrary("iomx-jbmr2");
+ System.loadLibrary("iomx.18");
else if (Build.VERSION.SDK_INT <= Build.VERSION_CODES.KITKAT)
- System.loadLibrary("iomx-kk");
+ System.loadLibrary("iomx.19");
} catch (Throwable t) {
// No need to warn if it isn't found, when we intentionally don't build these except for debug
if (Build.VERSION.SDK_INT <= Build.VERSION_CODES.ICE_CREAM_SANDWICH_MR1)
--
2.1.1
More information about the vlc-devel
mailing list