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

Delta Between Two Patch Sets: libadblockplus-android/jni/Android.mk

Issue 29557565: Issue 5800 - Add option to specify a list of V8 libraries (Closed)
Left Patch Set: Using comma as separator, README changes Created Sept. 29, 2017, 11:44 a.m.
Right Patch Set: moved 'packagingOptions' section to dynamic linking 'if' branch only Created Nov. 2, 2017, 11:30 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
LEFTRIGHT
1 LOCAL_PATH := $(call my-dir) 1 LOCAL_PATH := $(call my-dir)
2 2
3 # Report configuration 3 # Report configuration
4 ifeq ($(SHARED_V8_LIB_FILENAMES),) 4 ifeq ($(SHARED_V8_LIB_FILENAMES),)
5 # static 5 # static
6 $(info [Configuration] Linking statically with built-in v8) 6 $(info [Configuration] Linking statically with built-in v8)
7 else 7 else
8 # dynamic 8 # dynamic
9 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 10 define info_define
13 $(info [Configuration] Linking dynamically with shared v8 library ./libadblo ckplus-binaries/android_$(TARGET_ARCH_ABI)/$1) 11 $(info [Configuration] Linking dynamically with shared v8 library ./libadblo ckplus-binaries/android_$(TARGET_ARCH_ABI)/$1)
14 endef 12 endef
15 $(foreach item,$(SHARED_V8_LIB_FILENAMES_LIST),$(eval $(call info_define,$(item) ))) 13 $(foreach item,$(SHARED_V8_LIB_FILENAMES),$(eval $(call info_define,$(item))))
16 endif 14 endif
17 15
18 # libadblockplus.a 16 # libadblockplus.a
19 include $(CLEAR_VARS) 17 include $(CLEAR_VARS)
20 18
21 LOCAL_MODULE := libadblockplus 19 LOCAL_MODULE := libadblockplus
22 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libadblo ckplus.a 20 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libadblo ckplus.a
23 21
24 include $(PREBUILT_STATIC_LIBRARY) 22 include $(PREBUILT_STATIC_LIBRARY)
25 23
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 LOCAL_MODULE := v8-snapshot 62 LOCAL_MODULE := v8-snapshot
65 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_sn apshot.a 63 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/libv8_sn apshot.a
66 64
67 include $(PREBUILT_STATIC_LIBRARY) 65 include $(PREBUILT_STATIC_LIBRARY)
68 66
69 else 67 else
70 # dynamic 68 # dynamic
71 69
72 # prebuilt shared libraries v8 70 # prebuilt shared libraries v8
73 71
74 SHARED_V8_LIB_FILENAMES_LIST = $(subst $(comma), ,$(SHARED_V8_LIB_FILENAMES))
75 define libv8_define 72 define libv8_define
76 include $(CLEAR_VARS) 73 include $(CLEAR_VARS)
77 74
78 LOCAL_MODULE := $1 75 LOCAL_MODULE := $1
79 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/$1 76 LOCAL_SRC_FILES := ./libadblockplus-binaries/android_$(TARGET_ARCH_ABI)/$1
80 77
81 include $(PREBUILT_SHARED_LIBRARY) 78 include $(PREBUILT_SHARED_LIBRARY)
82 endef 79 endef
83 $(foreach item,$(SHARED_V8_LIB_FILENAMES_LIST),$(eval $(call libv8_define,$(item )))) 80 $(foreach item,$(SHARED_V8_LIB_FILENAMES),$(eval $(call libv8_define,$(item))))
84 81
85 endif 82 endif
86 83
87 include $(CLEAR_VARS) 84 include $(CLEAR_VARS)
88 85
89 LOCAL_MODULE := libadblockplus-jni 86 LOCAL_MODULE := libadblockplus-jni
90 LOCAL_SRC_FILES := JniLibrary.cpp 87 LOCAL_SRC_FILES := JniLibrary.cpp
91 LOCAL_SRC_FILES += JniPlatform.cpp 88 LOCAL_SRC_FILES += JniPlatform.cpp
92 LOCAL_SRC_FILES += JniJsEngine.cpp JniFilterEngine.cpp JniJsValue.cpp 89 LOCAL_SRC_FILES += JniJsEngine.cpp JniFilterEngine.cpp JniJsValue.cpp
93 LOCAL_SRC_FILES += JniFilter.cpp JniSubscription.cpp JniEventCallback.cpp 90 LOCAL_SRC_FILES += JniFilter.cpp JniSubscription.cpp JniEventCallback.cpp
94 LOCAL_SRC_FILES += JniLogSystem.cpp JniWebRequest.cpp 91 LOCAL_SRC_FILES += JniLogSystem.cpp JniWebRequest.cpp
95 LOCAL_SRC_FILES += JniUpdateAvailableCallback.cpp JniUpdateCheckDoneCallback.cpp 92 LOCAL_SRC_FILES += JniUpdateAvailableCallback.cpp JniUpdateCheckDoneCallback.cpp
96 LOCAL_SRC_FILES += JniFilterChangeCallback.cpp JniCallbacks.cpp Utils.cpp 93 LOCAL_SRC_FILES += JniFilterChangeCallback.cpp JniCallbacks.cpp Utils.cpp
97 LOCAL_SRC_FILES += JniNotification.cpp JniShowNotificationCallback.cpp 94 LOCAL_SRC_FILES += JniNotification.cpp JniShowNotificationCallback.cpp
98 LOCAL_SRC_FILES += JniIsAllowedConnectionTypeCallback.cpp 95 LOCAL_SRC_FILES += JniIsAllowedConnectionTypeCallback.cpp
99 96
100 LOCAL_CPP_FEATURES := exceptions 97 LOCAL_CPP_FEATURES := exceptions
101 LOCAL_CPPFLAGS += -std=c++11 98 LOCAL_CPPFLAGS += -std=c++11
102 99
103 LOCAL_C_INCLUDES := jni/libadblockplus-binaries/include/ 100 LOCAL_C_INCLUDES := jni/libadblockplus-binaries/include/
104 101
105 LOCAL_STATIC_LIBRARIES := libadblockplus v8-libplatform 102 LOCAL_STATIC_LIBRARIES := libadblockplus v8-libplatform
106 103
107 ifeq ($(SHARED_V8_LIB_FILENAMES),) 104 ifeq ($(SHARED_V8_LIB_FILENAMES),)
108 # static 105 # static
109 LOCAL_STATIC_LIBRARIES += v8-base v8-snapshot v8-libsampler v8-libbase 106 LOCAL_STATIC_LIBRARIES += v8-base v8-snapshot v8-libsampler v8-libbase
110 else 107 else
111 # dynamic 108 # dynamic
112 SHARED_V8_LIB_FILENAMES_LIST = $(subst $(comma), ,$(SHARED_V8_LIB_FILENAMES)) 109 LOCAL_STATIC_LIBRARIES += $(SHARED_V8_LIB_FILENAMES)
113 LOCAL_STATIC_LIBRARIES += $(SHARED_V8_LIB_FILENAMES_LIST)
114 endif 110 endif
115 111
116 include $(BUILD_SHARED_LIBRARY) 112 include $(BUILD_SHARED_LIBRARY)
LEFTRIGHT

Powered by Google App Engine
This is Rietveld