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

Side by Side Diff: README.md

Issue 29810565: Issue 6750 - Update libadblockplus dependency to revision hg:70579fb48a6c (Closed)
Patch Set: Updated revisions, README Created June 21, 2018, 1:34 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | dependencies » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 Adblock Plus Library for Android 1 Adblock Plus Library for Android
2 ================================ 2 ================================
3 3
4 An Android library project, tests and demo application for AdblockWebView widget . 4 An Android library project, tests and demo application for AdblockWebView widget .
5 5
6 ## Updating the dependencies 6 ## Updating the dependencies
7 7
8 Adblock Plus for Android has dependencies that aren't in this repository. 8 Adblock Plus for Android has dependencies that aren't in this repository.
9 To update those, call: 9 To update those, call:
10 10
11 ./ensure_dependencies.py 11 ./ensure_dependencies.py
12 12
13 ## Library 13 ## Library
14 14
15 An Android library that provides the core functionality of Adblock Plus. 15 An Android library that provides the core functionality of Adblock Plus.
16 You can find it in the 'libadblockplus-android' directory. 16 You can find it in the 'libadblockplus-android' directory.
17 17
18 ### Building 18 ### Building
19 19
20 #### Requirements 20 #### Requirements
21 21
22 * [The Android SDK](https://developer.android.com/sdk) 22 * [The Android SDK](https://developer.android.com/sdk)
23 * Android SDK Build tools 25.0.0 23 * Android SDK Build tools 25.0.0
24 * [The Android NDK, 16b](https://developer.android.com/ndk) 24 * [The Android NDK, 16b](https://developer.android.com/ndk)
25 25
26 Edit 'buildToolsVersion' in 'build.gradle' files if necessary. 26 Edit 'buildToolsVersion' in 'build.gradle' files if necessary.
27 27
28 #### Building of libadblockplus
29
30 First, we need to build `V8` required for `libadblockplus`.
31 See `libadblockplus/README` or V8 documentation on how to build V8 or
32 fetch precompiled one. Run in 'libadblockplus' directory:
33
34 make TARGET_OS=android TARGET_ARCH=arm Configuration=release get-prebuilt-v8
35 make TARGET_OS=android TARGET_ARCH=ia32 Configuration=release get-prebuilt-v 8
36
37 Then we can build `libadblockplus`:
38
39 make TARGET_OS=android TARGET_ARCH=arm SUB_ACTION=libadblockplus Configurati on=release
40 make TARGET_OS=android TARGET_ARCH=ia32 SUB_ACTION=libadblockplus Configurat ion=release
41
28 #### Building from command-line 42 #### Building from command-line
29 43
30 In the project root directory create the file _local.properties_ and set 44 In the project root directory create the file _local.properties_ and set
31 _sdk.dir_ and _ndk.dir_ to where you installed it, e.g.: 45 _sdk.dir_ and _ndk.dir_ to where you installed it, e.g.:
32 46
33 sdk.dir = /some/where/sdk 47 sdk.dir = /some/where/sdk
34 ndk.dir = /some/where/ndk 48 ndk.dir = /some/where/ndk
35 49
36 In the project root directory run: 50 In the project root directory run:
37 51
(...skipping 20 matching lines...) Expand all
58 Note 72 Note
59 73
60 [Configuration] Building project in /tmp 74 [Configuration] Building project in /tmp
61 75
62 output while building 76 output while building
63 77
64 ### Building with prebuilt shared V8 78 ### Building with prebuilt shared V8
65 79
66 This can be desired to use product's V8 (let's say Chromium) instead of built-in V8. 80 This can be desired to use product's V8 (let's say Chromium) instead of built-in V8.
67 Put prebuilt shared V8 library file(s) in ARCH directories and set `SHARED_V8_LI B_FILENAMES` 81 Put prebuilt shared V8 library file(s) in ARCH directories and set `SHARED_V8_LI B_FILENAMES`
68 environment variable before building. You can pass multiple filenames, separated with space. 82 environment variable and `SHARED_V8_LIB_DIR` before building.
83 You can pass multiple filenames in `SHARED_V8_LIB_FILENAMES`, separated with spa ce.
69 Libadblockplus is required to be linked with that library file(s). 84 Libadblockplus is required to be linked with that library file(s).
70 85
71 For example: 86 For example:
72 87
73 SHARED_V8_LIB_FILENAMES=libv8.cr.so ./gradlew clean assemble 88 SHARED_V8_LIB_FILENAMES=libv8.cr.so SHARED_V8_LIB_DIR="/tmp/shared_v8" ./gra dlew clean assembleAbi_arm
74 89
75 or 90 or
76 91
77 SHARED_V8_LIB_FILENAMES="libv8.cr.so libfoo.so" ./gradlew clean assemble 92 SHARED_V8_LIB_FILENAMES="libv8.cr.so libv8_libbase.cr.so libv8_libplatform.c r.so" SHARED_V8_LIB_DIR="/tmp/shared_v8" ./gradlew clean assembleAbi_arm
78 93
79 for multiple library files. 94 for multiple library files.
80 95
81 Note 96 Note
82 97
83 [Configuration] Excluding shared v8 library libv8.cr.so from AAR 98 [Configuration] Excluding shared v8 library libv8.cr.so from AAR
84 ... 99 ...
85 [Configuration] Linking dynamically with shared v8 library ./libadblockplus- binaries/android_armeabi-v7a/libv8.cr.so 100 [Configuration] Linking dynamically with shared v8 library /tmp/shared_v8/re lease/libv8.cr.so
86 ... 101 ...
87 102
88 output while building. 103 output while building.
89 104
90 Set `SHARED_V8_LIB_DIR` environment variable as full absolute path to pass
91 specific directory instead of default one (`libadblockplus-android/jni/libadbloc kplus-binaries`).
92
93 ### Building for single ARCH 105 ### Building for single ARCH
94 106
95 By default libadblockplus-android is built for both ARM and x86 and it can be fi ltered when 107 By default libadblockplus-android is built for both ARM and x86 and it can be fi ltered when
96 building end-user android application. However sometimes it can be desired to bu ild 108 building end-user android application. However sometimes it can be desired to bu ild
97 "libadblockplus-android.aar" for single ARCH. 109 "libadblockplus-android.aar" for single ARCH.
98 110
99 Pass `abi_arm` or `abi_x86` to build it for single arch or `abi_all` for all ARC Hs: 111 Pass `abi_arm` or `abi_x86` to build it for single arch or `abi_all` for all ARC Hs:
100 112
101 `./gradlew clean assembleAbi_arm` 113 `./gradlew clean assembleAbi_arm`
102 114
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 274
263 ### Building 275 ### Building
264 276
265 Make sure _Library_ requirements are present. 277 Make sure _Library_ requirements are present.
266 278
267 In the project root directory run: 279 In the project root directory run:
268 280
269 ./gradlew assemble 281 ./gradlew assemble
270 282
271 This will generate *.apk in the 'libadblockplus-android-webviewapp/build/outputs /apk/' directory. 283 This will generate *.apk in the 'libadblockplus-android-webviewapp/build/outputs /apk/' directory.
OLDNEW
« no previous file with comments | « no previous file | dependencies » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld