Skip to content

Commit 8872638

Browse files
committed
update README
1 parent d4a35f9 commit 8872638

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

README.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,11 @@ This project is based on [facebook/android-jsc](https://github.com/facebook/andr
2323
## Build instructions
2424

2525
1. Clone this repo
26-
1. Update the config section under `package.json` to the desired build configuration
27-
1. `npm run download`: downloads all needed sources
28-
1. `npm run start`: builds jsc (this might take some time...)
26+
2. `npm run clean` will clean everything (artifacts, downloaded sources)
27+
3. Update the config section under `package.json` to the desired build configuration
28+
4. Update patches if needed (don't forget to update the `printVersion` patch in jsc.patch)
29+
5. `npm run download`: downloads all needed sources
30+
6. `npm run start`: builds jsc (this might take some time...)
2931

3032
The zipfile containing the android-jsc AAR will be available at `/dist`.
3133
The library is packaged as a local Maven repository containing AAR files that include the binaries.
@@ -36,6 +38,8 @@ JSC library built using this project is distributed over npm: [npm/jsc-android](
3638
The library is packaged as a local Maven repository containing AAR files that include the binaries.
3739
Please refer to the section below in order to learn how your app can consume this format.
3840

41+
On load, JSC prints the version out to logcat, under "JavaScriptCore.Version" tag.
42+
3943
## How to use it with my React Native app
4044

4145
Follow steps below in order for your React Native app to use new version of JSC VM on android:

patches/jsc.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ diff -aur target-org/webkit/Source/JavaScriptCore/API/JSBase.cpp target/webkit/S
258258
+extern "C" int __android_log_print(int prio, const char *tag, const char *fmt, ...);
259259
+__attribute__((constructor))
260260
+void printVersion() {
261-
+ __android_log_print(3, "JavaScriptCore-Version", "%s", "224109.1.0");
261+
+ __android_log_print(3, "JavaScriptCore.Version", "%s", "224109.1.0");
262262
+}
263263
diff -aur target-org/webkit/Source/JavaScriptCore/CMakeLists.txt target/webkit/Source/JavaScriptCore/CMakeLists.txt
264264
--- target-org/webkit/Source/JavaScriptCore/CMakeLists.txt 2017-10-16 15:19:26.000000000 +0300

0 commit comments

Comments
 (0)