Skip to content

Commit aafeb93

Browse files
wkozyra95DanielZlotin
authored andcommitted
2.22.2 update (#65)
1 parent 673c006 commit aafeb93

File tree

5 files changed

+30
-31
lines changed

5 files changed

+30
-31
lines changed

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ Follow steps below in order for your React Native app to use new version of JSC
4848
1. Add `jsc-android` to the "dependencies" section in your `package.json`:
4949
```diff
5050
dependencies {
51-
+ "jsc-android": "225067.x.x",
51+
+ "jsc-android": "237548.x.x",
5252
```
5353

5454
then run `npm install` or `yarn` (depending which npm client you use) in order for the new dependency to be installed in `node_modules`
@@ -78,7 +78,7 @@ allprojects {
7878

7979
+configurations.all {
8080
+ resolutionStrategy {
81-
+ force 'org.webkit:android-jsc:r225067'
81+
+ force 'org.webkit:android-jsc:r237548'
8282
+ }
8383
+}
8484

@@ -109,7 +109,7 @@ To use this variant instead replace the third installation step with:
109109
+ resolutionStrategy {
110110
+ eachDependency { DependencyResolveDetails details ->
111111
+ if (details.requested.name == 'android-jsc') {
112-
+ details.useTarget group: details.requested.group, name: 'android-jsc-intl', version: 'r225067'
112+
+ details.useTarget group: details.requested.group, name: 'android-jsc-intl', version: 'r237548'
113113
+ }
114114
+ }
115115
+ }

measure/scripts/measure.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,6 @@ function getDensity() {
135135
}
136136

137137
function getScreenSize() {
138-
const size = exec.execSyncRead(`adb shell wm size | grep -Eo "\\d+x\\d+"`, true);
138+
const size = exec.execSyncRead(`adb shell wm size | grep -Eo "[0-9]+x[0-9]+"`, true);
139139
return size.split('x');
140140
}

package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "jsc-android",
3-
"version": "225067.0.0",
3+
"version": "237548.0.0",
44
"description": "Pre-build version of JavaScriptCore to be used by React Native apps",
55
"repository": {
66
"type": "git",
@@ -26,7 +26,7 @@
2626
"start": "./scripts/start.sh"
2727
},
2828
"config": {
29-
"webkitGTK": "2.19.2",
29+
"webkitGTK": "2.22.2",
3030
"chromiumICUCommit": "b34251f8b762f8e2112a89c587855ca4297fed96"
3131
}
3232
}

patches/intl/icu-disabled.patch

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
diff -aur target-icucollator/webkit/Source/WTF/wtf/CMakeLists.txt target/webkit/Source/WTF/wtf/CMakeLists.txt
22
--- target-icucollator/webkit/Source/WTF/wtf/CMakeLists.txt 2017-07-11 13:16:20.800299018 +0200
33
+++ target/webkit/Source/WTF/wtf/CMakeLists.txt 2017-07-11 13:17:20.743222116 +0200
4-
@@ -331,7 +331,7 @@
4+
@@ -331,9 +331,8 @@
55
endif ()
66

77
list(APPEND WTF_SOURCES
8+
unicode/CollatorDefault.cpp
9+
810
- unicode/icu/CollatorICU.cpp
9-
+ unicode/CollatorDefault.cpp
1011
)
1112
set(WTF_SYSTEM_INCLUDE_DIRECTORIES
1213
${ICU_INCLUDE_DIRS}

patches/jsc.patch

+21-23
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ diff -aur target-org/webkit/Source/cmake/OptionsJSCOnly.cmake target/webkit/Sour
8686
-endif ()
8787
+set(ENABLE_API_TESTS OFF)
8888
+set(ENABLE_SAMPLING_PROFILER OFF)
89-
+set(ENABLE_DFG_JIT OFF)
89+
+set(ENABLE_DFG_JIT ON)
9090
+set(ENABLE_FTL_JIT OFF)
9191
+set(ENABLE_JIT ON)
9292

@@ -113,9 +113,9 @@ diff -aur target-org/webkit/Source/JavaScriptCore/CMakeLists.txt target/webkit/S
113113
# Force staging of shared scripts, even if they aren't directly used to build JavaScriptCore.
114114

115115
diff -aur target-org/webkit/Source/WTF/wtf/unix/LanguageUnix.cpp target/webkit/Source/WTF/wtf/unix/LanguageUnix.cpp
116-
--- target-org/webkit/Source/WTF/wtf/unix/LanguageUnix.cpp 2017-09-08 02:11:21.000000000 +0300
117-
+++ target/webkit/Source/WTF/wtf/unix/LanguageUnix.cpp 2018-06-14 15:41:18.000000000 +0300
118-
@@ -24,22 +24,25 @@
116+
--- target-org/webkit/Source/WTF/wtf/unix/LanguageUnix.cpp 2016-10-08 05:31:15.000000000 +0200
117+
+++ target/webkit/Source/WTF/wtf/unix/LanguageUnix.cpp 2017-07-11 11:34:55.962374878 +0200
118+
@@ -24,22 +24,27 @@
119119
#include <locale.h>
120120
#include <wtf/Vector.h>
121121
#include <wtf/text/WTFString.h>
@@ -131,25 +131,26 @@ diff -aur target-org/webkit/Source/WTF/wtf/unix/LanguageUnix.cpp target/webkit/S
131131
- String localeDefault(setlocale(LC_CTYPE, nullptr));
132132
- if (localeDefault.isEmpty() || equalIgnoringASCIICase(localeDefault, "C") || equalIgnoringASCIICase(localeDefault, "POSIX"))
133133
+ char buf[2 * (PROP_VALUE_MAX + 1)];
134+
+
134135
+ int locale_len = __system_property_get("persist.sys.locale", buf);
135136
+ if (locale_len == 0) {
136137
+ int lang_len = __system_property_get("persist.sys.language", buf);
137138
+ if(lang_len == 0) {
138-
return ASCIILiteral("en-US");
139-
-
140-
- String normalizedDefault = localeDefault;
141-
- normalizedDefault.replace('_', '-');
142-
- normalizedDefault.truncate(normalizedDefault.find('.'));
143-
- return normalizedDefault;
139+
return "en-US"_s;
144140
+ }
145141
+ int country_len = __system_property_get("persist.sys.country", buf + lang_len + 1);
146142
+ if(country_len != 0) {
147143
+ buf[lang_len] = '-';
148144
+ }
149145
+ }
146+
147+
- String normalizedDefault = localeDefault;
148+
- normalizedDefault.replace('_', '-');
149+
- normalizedDefault.truncate(normalizedDefault.find('.'));
150+
- return normalizedDefault;
150151
+ return String(buf);
151152
}
152-
153+
153154
Vector<String> platformUserPreferredLanguages()
154155
diff -aur target-org/webkit/Source/WTF/wtf/StackTrace.cpp target/webkit/Source/WTF/wtf/StackTrace.cpp
155156
--- target-org/webkit/Source/WTF/wtf/StackTrace.cpp 2017-04-25 04:53:49.000000000 +0200
@@ -195,15 +196,15 @@ diff -aur target-org/webkit/Source/WTF/wtf/unicode/CollatorDefault.cpp target/we
195196
diff -aur org/target/webkit/Source/cmake/OptionsCommon.cmake target/webkit/Source/cmake/OptionsCommon.cmake
196197
--- target-org/webkit/Source/cmake/OptionsCommon.cmake 2017-11-15 16:28:52.120093206 +0100
197198
+++ target/webkit/Source/cmake/OptionsCommon.cmake 2017-04-09 02:50:32.875166000 +0200
198-
@@ -255,7 +255,7 @@
199+
@@ -115,7 +115,7 @@
199200

200201
# Check for headers
201-
_HAVE_CHECK_INCLUDE(HAVE_ERRNO_H errno.h)
202-
-_HAVE_CHECK_INCLUDE(HAVE_LANGINFO_H langinfo.h)
203-
+#_HAVE_CHECK_INCLUDE(HAVE_LANGINFO_H langinfo.h)
204-
_HAVE_CHECK_INCLUDE(HAVE_MMAP sys/mman.h)
205-
_HAVE_CHECK_INCLUDE(HAVE_PTHREAD_NP_H pthread_np.h)
206-
_HAVE_CHECK_INCLUDE(HAVE_STRINGS_H strings.h)
202+
WEBKIT_CHECK_HAVE_INCLUDE(HAVE_ERRNO_H errno.h)
203+
-WEBKIT_CHECK_HAVE_INCLUDE(HAVE_LANGINFO_H langinfo.h)
204+
+#WEBKIT_CHECK_HAVE_INCLUDE(HAVE_LANGINFO_H langinfo.h)
205+
WEBKIT_CHECK_HAVE_INCLUDE(HAVE_MMAP sys/mman.h)
206+
WEBKIT_CHECK_HAVE_INCLUDE(HAVE_PTHREAD_NP_H pthread_np.h)
207+
WEBKIT_CHECK_HAVE_INCLUDE(HAVE_STRINGS_H strings.h)
207208
diff -aur target-org/webkit/Source/cmake/FindICU.cmake target/webkit/Source/cmake/FindICU.cmake
208209
--- target-org/webkit/Source/cmake/FindICU.cmake 2018-07-24 15:41:23.452474811 +0200
209210
+++ target/webkit/Source/cmake/FindICU.cmake 2018-07-12 15:53:44.611542333 +0200
@@ -259,13 +260,12 @@ diff -aur target-org/webkit/Source/cmake/FindICU.cmake target/webkit/Source/cmak
259260
diff -aur target-org/webkit/Source/JavaScriptCore/CMakeLists.txt target/webkit/Source/JavaScriptCore/CMakeLists.txt
260261
--- target-org/webkit/Source/JavaScriptCore/CMakeLists.txt 2018-07-25 09:56:23.662494914 +0200
261262
+++ target/webkit/Source/JavaScriptCore/CMakeLists.txt 2018-07-18 12:55:24.726736260 +0200
262-
@@ -1072,6 +1072,8 @@
263+
@@ -118,5 +118,7 @@
263264
set(JavaScriptCore_LIBRARIES
264265
WTF${DEBUG_SUFFIX}
265266
${ICU_I18N_LIBRARIES}
266267
+ ${ICU_LIBRARIES}
267268
+ ${ICU_DATA_LIBRARIES}
268-
${LLVM_LIBRARIES}
269269
)
270270

271271
diff -aur target-org/webkit/Source/JavaScriptCore/API/JSBase.cpp target/webkit/Source/JavaScriptCore/API/JSBase.cpp
@@ -284,12 +284,10 @@ diff -aur target-org/webkit/Source/JavaScriptCore/API/JSBase.cpp target/webkit/S
284284
diff -aur target-org/webkit/Source/JavaScriptCore/CMakeLists.txt target/webkit/Source/JavaScriptCore/CMakeLists.txt
285285
--- target-org/webkit/Source/JavaScriptCore/CMakeLists.txt 2017-10-16 15:19:26.000000000 +0300
286286
+++ target/webkit/Source/JavaScriptCore/CMakeLists.txt 2018-10-09 14:44:23.000000000 +0300
287-
@@ -1073,6 +1073,8 @@
287+
@@ -119,4 +119,6 @@
288288
WTF${DEBUG_SUFFIX}
289289
${ICU_I18N_LIBRARIES}
290-
${LLVM_LIBRARIES}
291290
+ log
292291
)
293292
+add_definitions(-DJSC_VERSION="${JSC_VERSION}")
294293

295-
set(JavaScriptCore_SCRIPTS_SOURCES_DIR "${JAVASCRIPTCORE_DIR}/Scripts")

0 commit comments

Comments
 (0)