Left: | ||
Right: |
OLD | NEW |
---|---|
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 comma = , | |
sergei
2017/10/02 09:12:02
should it be called something like shared_v8_lib_s
anton
2017/10/02 09:22:04
Does not matter for me. Should i rename?
| |
11 SHARED_V8_LIB_FILENAMES_LIST = $(subst $(comma), ,$(SHARED_V8_LIB_FILENAMES)) | |
sergei
2017/10/02 10:08:01
Sorry, didn't pay attention to it before. What was
sergei
2017/10/02 12:06:52
It's three times here and there is even no need in
diegocarloslima
2017/10/10 13:40:51
Yeah, I agree that for sake of simplicity, just a
| |
12 define info_define | |
13 $(info [Configuration] Linking dynamically with shared v8 library ./libadblo ckplus-binaries/android_$(TARGET_ARCH_ABI)/$1) | |
14 endef | |
15 $(foreach item,$(SHARED_V8_LIB_FILENAMES_LIST),$(eval $(call info_define,$(item) ))) | |
16 endif | |
17 | |
18 # libadblockplus.a | |
3 include $(CLEAR_VARS) | 19 include $(CLEAR_VARS) |
4 | 20 |
5 LOCAL_MODULE := libadblockplus | 21 LOCAL_MODULE := libadblockplus |
6 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libadblo ckplus.a | 22 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libadblo ckplus.a |
7 | 23 |
8 include $(PREBUILT_STATIC_LIBRARY) | 24 include $(PREBUILT_STATIC_LIBRARY) |
9 | 25 |
26 # libv8-platform.a | |
27 include $(CLEAR_VARS) | |
28 | |
29 LOCAL_MODULE := v8-libplatform | |
30 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bplatform.a | |
31 | |
32 include $(PREBUILT_STATIC_LIBRARY) | |
33 | |
34 ifeq ($(SHARED_V8_LIB_FILENAMES),) | |
35 # static | |
36 | |
37 # libv8-libsampler.a | |
10 include $(CLEAR_VARS) | 38 include $(CLEAR_VARS) |
11 | 39 |
12 LOCAL_MODULE := v8-libsampler | 40 LOCAL_MODULE := v8-libsampler |
13 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bsampler.a | 41 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bsampler.a |
14 | 42 |
15 include $(PREBUILT_STATIC_LIBRARY) | 43 include $(PREBUILT_STATIC_LIBRARY) |
16 | 44 |
45 # libv8-base.a | |
17 include $(CLEAR_VARS) | 46 include $(CLEAR_VARS) |
18 | 47 |
19 LOCAL_MODULE := v8-base | 48 LOCAL_MODULE := v8-base |
20 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_ba se.a | 49 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_ba se.a |
21 | 50 |
22 include $(PREBUILT_STATIC_LIBRARY) | 51 include $(PREBUILT_STATIC_LIBRARY) |
23 | 52 |
53 # libv8_libbase.a | |
24 include $(CLEAR_VARS) | 54 include $(CLEAR_VARS) |
25 | 55 |
26 LOCAL_MODULE := v8-libbase | 56 LOCAL_MODULE := v8-libbase |
27 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bbase.a | 57 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_li bbase.a |
28 | 58 |
29 include $(PREBUILT_STATIC_LIBRARY) | 59 include $(PREBUILT_STATIC_LIBRARY) |
30 | 60 |
31 include $(CLEAR_VARS) | 61 # 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) | 62 include $(CLEAR_VARS) |
39 | 63 |
40 LOCAL_MODULE := v8-snapshot | 64 LOCAL_MODULE := v8-snapshot |
41 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_sn apshot.a | 65 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_sn apshot.a |
42 | 66 |
43 include $(PREBUILT_STATIC_LIBRARY) | 67 include $(PREBUILT_STATIC_LIBRARY) |
44 | 68 |
69 else | |
70 # dynamic | |
71 | |
72 # prebuilt shared libraries v8 | |
73 | |
74 SHARED_V8_LIB_FILENAMES_LIST = $(subst $(comma), ,$(SHARED_V8_LIB_FILENAMES)) | |
75 define libv8_define | |
76 include $(CLEAR_VARS) | |
77 | |
78 LOCAL_MODULE := $1 | |
79 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/$1 | |
80 | |
81 include $(PREBUILT_SHARED_LIBRARY) | |
82 endef | |
83 $(foreach item,$(SHARED_V8_LIB_FILENAMES_LIST),$(eval $(call libv8_define,$(item )))) | |
84 | |
85 endif | |
86 | |
45 include $(CLEAR_VARS) | 87 include $(CLEAR_VARS) |
46 | 88 |
47 LOCAL_MODULE := libadblockplus-jni | 89 LOCAL_MODULE := libadblockplus-jni |
48 LOCAL_SRC_FILES := JniLibrary.cpp | 90 LOCAL_SRC_FILES := JniLibrary.cpp |
49 LOCAL_SRC_FILES += JniPlatform.cpp | 91 LOCAL_SRC_FILES += JniPlatform.cpp |
50 LOCAL_SRC_FILES += JniJsEngine.cpp JniFilterEngine.cpp JniJsValue.cpp | 92 LOCAL_SRC_FILES += JniJsEngine.cpp JniFilterEngine.cpp JniJsValue.cpp |
51 LOCAL_SRC_FILES += JniFilter.cpp JniSubscription.cpp JniEventCallback.cpp | 93 LOCAL_SRC_FILES += JniFilter.cpp JniSubscription.cpp JniEventCallback.cpp |
52 LOCAL_SRC_FILES += JniLogSystem.cpp JniWebRequest.cpp | 94 LOCAL_SRC_FILES += JniLogSystem.cpp JniWebRequest.cpp |
53 LOCAL_SRC_FILES += JniUpdateAvailableCallback.cpp JniUpdateCheckDoneCallback.cpp | 95 LOCAL_SRC_FILES += JniUpdateAvailableCallback.cpp JniUpdateCheckDoneCallback.cpp |
54 LOCAL_SRC_FILES += JniFilterChangeCallback.cpp JniCallbacks.cpp Utils.cpp | 96 LOCAL_SRC_FILES += JniFilterChangeCallback.cpp JniCallbacks.cpp Utils.cpp |
55 LOCAL_SRC_FILES += JniNotification.cpp JniShowNotificationCallback.cpp | 97 LOCAL_SRC_FILES += JniNotification.cpp JniShowNotificationCallback.cpp |
56 LOCAL_SRC_FILES += JniIsAllowedConnectionTypeCallback.cpp | 98 LOCAL_SRC_FILES += JniIsAllowedConnectionTypeCallback.cpp |
57 | 99 |
58 LOCAL_CPP_FEATURES := exceptions | 100 LOCAL_CPP_FEATURES := exceptions |
59 LOCAL_CPPFLAGS += -std=c++11 | 101 LOCAL_CPPFLAGS += -std=c++11 |
60 | 102 |
61 LOCAL_C_INCLUDES := jni/libadblockplus-binaries/include/ | 103 LOCAL_C_INCLUDES := jni/libadblockplus-binaries/include/ |
62 LOCAL_STATIC_LIBRARIES := libadblockplus v8-base v8-snapshot v8-libsampler v8-li bplatform v8-libbase | 104 |
105 LOCAL_STATIC_LIBRARIES := libadblockplus v8-libplatform | |
106 | |
107 ifeq ($(SHARED_V8_LIB_FILENAMES),) | |
108 # static | |
109 LOCAL_STATIC_LIBRARIES += v8-base v8-snapshot v8-libsampler v8-libbase | |
110 else | |
111 # dynamic | |
112 SHARED_V8_LIB_FILENAMES_LIST = $(subst $(comma), ,$(SHARED_V8_LIB_FILENAMES)) | |
113 LOCAL_STATIC_LIBRARIES += $(SHARED_V8_LIB_FILENAMES_LIST) | |
114 endif | |
63 | 115 |
64 include $(BUILD_SHARED_LIBRARY) | 116 include $(BUILD_SHARED_LIBRARY) |
OLD | NEW |