Android-x86
Fork
Donation

  • R/O
  • HTTP
  • SSH
  • HTTPS

external-ffmpeg: Commit

external/ffmpeg


Commit MetaInfo

Revisión6baa9aeb3944522f6e1e4024328f8673b0ebc418 (tree)
Tiempo2017-06-08 00:42:32
AutorChih-Wei Huang <cwhuang@linu...>
CommiterChih-Wei Huang

Log Message

android: clean up makefiles

Move common variables to the top makefile. No need to define them
on including each time.

Export ffmpeg include paths by LOCAL_EXPORT_C_INCLUDE_DIRS.

Use LOCAL_PROPRIETARY_MODULE to put libraries to /vendor.

Cambiar Resumen

Diferencia

--- a/Android.mk
+++ b/Android.mk
@@ -1,5 +1,5 @@
11 #
2-# Copyright (C) 2013 The Android-x86 Open Source Project
2+# Copyright (C) 2013-2017 The Android-x86 Open Source Project
33 #
44 # Licensed under the GNU General Public License Version 2 or later.
55 # You may not use this file except in compliance with the License.
@@ -8,4 +8,13 @@
88 # http://www.gnu.org/licenses/gpl.html
99 #
1010
11+FFMPEG_DIR := $(call my-dir)/
12+
13+define RESET
14+$(1) :=
15+$(1)-yes :=
16+endef
17+
18+FF_VARS := FFLIBS OBJS ARMV5TE-OBJS ARMV6-OBJS VFP-OBJS NEON-OBJS MIPSFPU-OBJS MIPS32R2-OBJS MIPSDSPR1-OBJS MIPSDSPR2-OBJS ALTIVEC-OBJS VIS-OBJS MMX-OBJS YASM-OBJS
19+
1120 include $(call all-subdir-makefiles)
--- a/android/build.mk
+++ b/android/build.mk
@@ -1,5 +1,5 @@
11 #
2-# Copyright (C) 2013 The Android-x86 Open Source Project
2+# Copyright (C) 2013-2017 The Android-x86 Open Source Project
33 #
44 # Licensed under the GNU General Public License Version 2 or later.
55 # You may not use this file except in compliance with the License.
@@ -51,15 +51,16 @@ LOCAL_MODULE := lib$(NAME)
5151 LOCAL_MODULE_TAGS := optional
5252 LOCAL_MODULE_CLASS := SHARED_LIBRARIES
5353 LOCAL_ARM_MODE := arm
54-ifdef TARGET_2ND_ARCH
55-LOCAL_MODULE_PATH_32 := $(TARGET_OUT_VENDOR)/lib
56-LOCAL_MODULE_PATH_64 := $(TARGET_OUT_VENDOR)/lib64
57-else
58-LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_SHARED_LIBRARIES)
59-endif
54+LOCAL_PROPRIETARY_MODULE := true
6055
6156 LOCAL_SRC_FILES := $(C_FILES) $(S_FILES)
6257
58+LOCAL_C_INCLUDES := \
59+ $(FFMPEG_DIR)android/include \
60+ $(FFMPEG_DIR)
61+
62+LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_C_INCLUDES)
63+
6364 LOCAL_CFLAGS += \
6465 -O3 -std=c99 -fno-math-errno -fno-signed-zeros -fomit-frame-pointer \
6566 -Wno-pointer-to-int-cast -Wstrict-prototypes -Wempty-body -Wno-parentheses \
--- a/android/ffmpeg.mk
+++ b/android/ffmpeg.mk
@@ -1,5 +1,5 @@
11 #
2-# Copyright (C) 2013 The Android-x86 Open Source Project
2+# Copyright (C) 2013-2017 The Android-x86 Open Source Project
33 #
44 # Licensed under the GNU General Public License Version 2 or later.
55 # You may not use this file except in compliance with the License.
@@ -8,17 +8,6 @@
88 # http://www.gnu.org/licenses/gpl.html
99 #
1010
11-ifndef FFMPEG_DIR
12-FFMPEG_DIR := $(dir $(call my-dir))
13-endif
14-
15-define RESET
16-$(1) :=
17-$(1)-yes :=
18-endef
19-
20-FF_VARS := FFLIBS OBJS ARMV5TE-OBJS ARMV6-OBJS VFP-OBJS NEON-OBJS MIPSFPU-OBJS MIPS32R2-OBJS MIPSDSPR1-OBJS MIPSDSPR2-OBJS ALTIVEC-OBJS VIS-OBJS MMX-OBJS YASM-OBJS
21-
2211 FFMPEG_ARCH := $(TARGET_ARCH)
2312
2413 FFMPEG_2ND_ARCH := false
@@ -47,12 +36,6 @@ ifeq ($(FFMPEG_2ND_ARCH), true)
4736 FFMPEG_ARCH_VARIANT := $(TARGET_2ND_ARCH_VARIANT)
4837 endif
4938
50-# bionic include must be the first
51-LOCAL_C_INCLUDES := \
52- bionic/libc/include \
53- $(FFMPEG_DIR)android/include \
54- $(FFMPEG_DIR) \
55-
5639 ifneq ($(filter x86 x86_64, $(FFMPEG_ARCH)),)
5740 TARGET_CONFIG := config-$(FFMPEG_ARCH)-$(FFMPEG_ARCH_VARIANT).h
5841 else
--- a/libavutil/Android.mk
+++ b/libavutil/Android.mk
@@ -19,6 +19,8 @@ LOCAL_SHARED_LIBRARIES += \
1919 libva-android
2020 endif
2121
22+LOCAL_C_INCLUDES += bionic/libc/include
23+
2224 LOCAL_MULTILIB := $(FFMPEG_MULTILIB)
2325
2426 include $(BUILD_SHARED_LIBRARY)
@@ -34,6 +36,8 @@ LOCAL_SHARED_LIBRARIES += \
3436 libva-android
3537 endif
3638
39+LOCAL_C_INCLUDES += bionic/libc/include
40+
3741 LOCAL_MULTILIB := $(FFMPEG_MULTILIB)
3842
3943 include $(BUILD_SHARED_LIBRARY)
Show on old repository browser