Skip to content

Commit bc4365f

Browse files
darindvmutafov
authored andcommitted
Added x86_64 architecture (#1449)
1 parent ca66602 commit bc4365f

12 files changed

Lines changed: 18410 additions & 4 deletions

File tree

test-app/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ android {
232232
if (onlyX86) {
233233
abiFilters 'x86'
234234
} else {
235-
abiFilters 'x86', 'armeabi-v7a', 'arm64-v8a'
235+
abiFilters 'x86', 'x86_64', 'armeabi-v7a', 'arm64-v8a'
236236
}
237237
}
238238
dexOptions {
15.9 MB
Binary file not shown.

test-app/app/src/main/assets/app/tests/testNativeModules.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,11 @@ describe("Tests native modules)", function () {
1010
if (lcArch.indexOf("arm") > -1) {
1111
arch = "arm";
1212
} else if (lcArch.indexOf("aarch64") > -1) {
13-
arch = (com.tns.Runtime.getPointerSize() == 4) ? "arm" : "arm64";
13+
arch = (com.tns.Runtime.getPointerSize() == 4) ? "arm" : "arm64";
1414
} else if (lcArch.indexOf("i686") > -1) {
1515
arch = "x86";
16+
} else if (lcArch.indexOf("x86_64") > -1) {
17+
arch = "x86_64";
1618
} else {
1719
throw new Error("Unsupported architecture=" + sysArch);
1820
}

test-app/runtime/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,9 +206,10 @@ MESSAGE(STATUS "# CMAKE_CXX_FLAGS: " ${CMAKE_CXX_FLAGS})
206206
target_link_libraries(NativeScript ${PROJECT_SOURCE_DIR}/src/main/libs/${ANDROID_ABI}/libzip.a)
207207
target_link_libraries(NativeScript ${PROJECT_SOURCE_DIR}/src/main/libs/${ANDROID_ABI}/libv8.a)
208208

209-
if("${ANDROID_ABI}" MATCHES "armeabi-v7a" OR "${ANDROID_ABI}" MATCHES "x86")
209+
if("${ANDROID_ABI}" MATCHES "armeabi-v7a$" OR "${ANDROID_ABI}" MATCHES "x86$")
210210
# On API Level 19 and lower we need to link with android_support
211211
# because it contains some implementation of functions such as "strtoll" and "strtoul"
212+
MESSAGE(STATUS "# Linking with libandroid_support.a")
212213
target_link_libraries(NativeScript ${ANDROID_NDK_ROOT}/sources/cxx-stl/llvm-libc++/libs/${ANDROID_ABI}/libandroid_support.a)
213214
endif()
214215

test-app/runtime/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ android {
7575
if (onlyX86) {
7676
abiFilters 'x86'
7777
} else {
78-
abiFilters 'x86', 'armeabi-v7a', 'arm64-v8a'
78+
abiFilters 'x86', 'x86_64', 'armeabi-v7a', 'arm64-v8a'
7979
}
8080
}
8181
}
389 KB
Binary file not shown.
620 KB
Binary file not shown.
638 KB
Binary file not shown.

test-app/runtime/src/main/libs/x86_64/include/natives_blob.h

Lines changed: 253 additions & 0 deletions
Large diffs are not rendered by default.

test-app/runtime/src/main/libs/x86_64/include/snapshot_blob.h

Lines changed: 18150 additions & 0 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)