Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: libadblockplus-android/jni/Android.mk

Issue 29557565: Issue 5800 - Add option to specify a list of V8 libraries (Closed)
Patch Set: Renamed env. variable Created Sept. 29, 2017, 8:27 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« README.md ('K') | « README.md ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 LOCAL_PATH := $(call my-dir) 1 LOCAL_PATH := $(call my-dir)
2 2
3 # Report configuration
4 ifeq ($(SHARED_V8_LIB_FILENAMES),)
5 # static
6 $(info [Configuration] Linking statically with built-in v8)
7 else
8 # dynamic
9
10 SHARED_V8_LIB_FILENAMES_LIST = $(subst :, ,$(SHARED_V8_LIB_FILENAMES))
11 define info_define
12 $(info [Configuration] Linking dynamically with shared v8 library ./libadblo ckplus-binaries/android_$(TARGET_ARCH_ABI)/$1)
13 endef
14 $(foreach item,$(SHARED_V8_LIB_FILENAMES_LIST),$(eval $(call info_define,$(item) )))
15 endif
16
17 # libadblockplus.a
3 include $(CLEAR_VARS) 18 include $(CLEAR_VARS)
4 19
5 LOCAL_MODULE := libadblockplus 20 LOCAL_MODULE := libadblockplus
6 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libadblo ckplus.a 21 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libadblo ckplus.a
7 22
8 include $(PREBUILT_STATIC_LIBRARY) 23 include $(PREBUILT_STATIC_LIBRARY)
9 24
25 # libv8-platform.a
26 include $(CLEAR_VARS)
27
28 LOCAL_MODULE := v8-libplatform
29 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bplatform.a
30
31 include $(PREBUILT_STATIC_LIBRARY)
32
33 ifeq ($(SHARED_V8_LIB_FILENAMES),)
34 # static
35
36 # libv8-libsampler.a
10 include $(CLEAR_VARS) 37 include $(CLEAR_VARS)
11 38
12 LOCAL_MODULE := v8-libsampler 39 LOCAL_MODULE := v8-libsampler
13 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bsampler.a 40 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bsampler.a
14 41
15 include $(PREBUILT_STATIC_LIBRARY) 42 include $(PREBUILT_STATIC_LIBRARY)
16 43
44 # libv8-base.a
17 include $(CLEAR_VARS) 45 include $(CLEAR_VARS)
18 46
19 LOCAL_MODULE := v8-base 47 LOCAL_MODULE := v8-base
20 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_ba se.a 48 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_ba se.a
21 49
22 include $(PREBUILT_STATIC_LIBRARY) 50 include $(PREBUILT_STATIC_LIBRARY)
23 51
52 # libv8_libbase.a
24 include $(CLEAR_VARS) 53 include $(CLEAR_VARS)
25 54
26 LOCAL_MODULE := v8-libbase 55 LOCAL_MODULE := v8-libbase
27 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bbase.a 56 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bbase.a
28 57
29 include $(PREBUILT_STATIC_LIBRARY) 58 include $(PREBUILT_STATIC_LIBRARY)
30 59
31 include $(CLEAR_VARS) 60 # libv8_snapshot.a
32
33 LOCAL_MODULE := v8-libplatform
34 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bplatform.a
35
36 include $(PREBUILT_STATIC_LIBRARY)
37
38 include $(CLEAR_VARS) 61 include $(CLEAR_VARS)
39 62
40 LOCAL_MODULE := v8-snapshot 63 LOCAL_MODULE := v8-snapshot
41 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_sn apshot.a 64 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_sn apshot.a
42 65
43 include $(PREBUILT_STATIC_LIBRARY) 66 include $(PREBUILT_STATIC_LIBRARY)
44 67
68 else
69 # dynamic
70
71 # prebuilt shared libraries v8
72
73 SHARED_V8_LIB_FILENAMES_LIST = $(subst :, ,$(SHARED_V8_LIB_FILENAMES))
74 define libv8_define
75 include $(CLEAR_VARS)
76
77 LOCAL_MODULE := $1
78 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/$1
79
80 include $(PREBUILT_SHARED_LIBRARY)
81 endef
82 $(foreach item,$(SHARED_V8_LIB_FILENAMES_LIST),$(eval $(call libv8_define,$(item ))))
83
84 endif
85
45 include $(CLEAR_VARS) 86 include $(CLEAR_VARS)
46 87
47 LOCAL_MODULE := libadblockplus-jni 88 LOCAL_MODULE := libadblockplus-jni
48 LOCAL_SRC_FILES := JniLibrary.cpp 89 LOCAL_SRC_FILES := JniLibrary.cpp
49 LOCAL_SRC_FILES += JniPlatform.cpp 90 LOCAL_SRC_FILES += JniPlatform.cpp
50 LOCAL_SRC_FILES += JniJsEngine.cpp JniFilterEngine.cpp JniJsValue.cpp 91 LOCAL_SRC_FILES += JniJsEngine.cpp JniFilterEngine.cpp JniJsValue.cpp
51 LOCAL_SRC_FILES += JniFilter.cpp JniSubscription.cpp JniEventCallback.cpp 92 LOCAL_SRC_FILES += JniFilter.cpp JniSubscription.cpp JniEventCallback.cpp
52 LOCAL_SRC_FILES += JniLogSystem.cpp JniWebRequest.cpp 93 LOCAL_SRC_FILES += JniLogSystem.cpp JniWebRequest.cpp
53 LOCAL_SRC_FILES += JniUpdateAvailableCallback.cpp JniUpdateCheckDoneCallback.cpp 94 LOCAL_SRC_FILES += JniUpdateAvailableCallback.cpp JniUpdateCheckDoneCallback.cpp
54 LOCAL_SRC_FILES += JniFilterChangeCallback.cpp JniCallbacks.cpp Utils.cpp 95 LOCAL_SRC_FILES += JniFilterChangeCallback.cpp JniCallbacks.cpp Utils.cpp
55 LOCAL_SRC_FILES += JniNotification.cpp JniShowNotificationCallback.cpp 96 LOCAL_SRC_FILES += JniNotification.cpp JniShowNotificationCallback.cpp
56 LOCAL_SRC_FILES += JniIsAllowedConnectionTypeCallback.cpp 97 LOCAL_SRC_FILES += JniIsAllowedConnectionTypeCallback.cpp
57 98
58 LOCAL_CPP_FEATURES := exceptions 99 LOCAL_CPP_FEATURES := exceptions
59 LOCAL_CPPFLAGS += -std=c++11 100 LOCAL_CPPFLAGS += -std=c++11
60 101
61 LOCAL_C_INCLUDES := jni/libadblockplus-binaries/include/ 102 LOCAL_C_INCLUDES := jni/libadblockplus-binaries/include/
62 LOCAL_STATIC_LIBRARIES := libadblockplus v8-base v8-snapshot v8-libsampler v8-li bplatform v8-libbase 103
104 LOCAL_STATIC_LIBRARIES := libadblockplus v8-libplatform
105
106 ifeq ($(SHARED_V8_LIB_FILENAMES),)
107 # static
108 LOCAL_STATIC_LIBRARIES += v8-base v8-snapshot v8-libsampler v8-libbase
109 else
110 # dynamic
111 SHARED_V8_LIB_FILENAMES_LIST = $(subst :, ,$(SHARED_V8_LIB_FILENAMES))
112 LOCAL_STATIC_LIBRARIES += $(SHARED_V8_LIB_FILENAMES_LIST)
113 endif
63 114
64 include $(BUILD_SHARED_LIBRARY) 115 include $(BUILD_SHARED_LIBRARY)
OLDNEW
« README.md ('K') | « README.md ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld