-
-
Notifications
You must be signed in to change notification settings - Fork 32k
build: commit some android build and test fixtures #57748
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
thunder-coding
wants to merge
2
commits into
nodejs:main
Choose a base branch
from
thunder-coding:android-fixes
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
diff --git a/common.gypi b/common.gypi | ||
index 5e39ad3f09..1e535f48a8 100644 | ||
--- a/common.gypi | ||
+++ b/common.gypi | ||
@@ -520,11 +520,11 @@ | ||
}], | ||
['_toolset=="host"', { | ||
'conditions': [ | ||
- [ 'host_arch=="ia32"', { | ||
+ [ 'host_arch=="ia32" or (target_arch=="ia32" or target_arch=="arm")', { | ||
'cflags': [ '-m32' ], | ||
'ldflags': [ '-m32' ], | ||
}], | ||
- [ 'host_arch=="x64"', { | ||
+ [ 'host_arch=="x64" and (target_arch=="x64" or target_arch=="arm64")', { | ||
'cflags': [ '-m64' ], | ||
'ldflags': [ '-m64' ], | ||
}], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,50 @@ | ||
--- trap-handler.h 2022-08-11 09:01:23.384000000 +0800 | ||
+++ fixed-trap-handler.h 2022-08-11 09:09:15.352000000 +0800 | ||
@@ -17,23 +17,7 @@ | ||
diff --git a/deps/v8/src/trap-handler/trap-handler.h b/deps/v8/src/trap-handler/trap-handler.h | ||
index 74967a00c1..d4f3b40269 100644 | ||
--- a/deps/v8/src/trap-handler/trap-handler.h | ||
+++ b/deps/v8/src/trap-handler/trap-handler.h | ||
@@ -17,45 +17,7 @@ namespace v8 { | ||
namespace internal { | ||
namespace trap_handler { | ||
|
||
-// X64 on Linux, Windows, MacOS, FreeBSD. | ||
-#if V8_HOST_ARCH_X64 && V8_TARGET_ARCH_X64 && \ | ||
- ((V8_OS_LINUX && !V8_OS_ANDROID) || V8_OS_WIN || V8_OS_DARWIN || \ | ||
- V8_OS_FREEBSD) | ||
-#define V8_TRAP_HANDLER_SUPPORTED true | ||
-// Arm64 (non-simulator) on Mac. | ||
-#elif V8_TARGET_ARCH_ARM64 && V8_HOST_ARCH_ARM64 && V8_OS_DARWIN | ||
-// Arm64 (non-simulator) on Mac and Linux. | ||
-#elif V8_TARGET_ARCH_ARM64 && V8_HOST_ARCH_ARM64 && \ | ||
- (V8_OS_DARWIN || (V8_OS_LINUX && !V8_OS_ANDROID)) | ||
-#define V8_TRAP_HANDLER_SUPPORTED true | ||
-// Arm64 simulator on x64 on Linux, Mac, or Windows. | ||
-// | ||
-// The simulator case uses some inline assembly code, which cannot be | ||
-// compiled with MSVC, so don't enable the trap handler in that case. | ||
-// (MSVC #defines _MSC_VER, but so does Clang when targeting Windows, hence | ||
-// the check for __clang__.) | ||
-#elif V8_TARGET_ARCH_ARM64 && V8_HOST_ARCH_X64 && \ | ||
- (V8_OS_LINUX || V8_OS_DARWIN) | ||
- (V8_OS_LINUX || V8_OS_DARWIN || V8_OS_WIN) && \ | ||
- (!defined(_MSC_VER) || defined(__clang__)) | ||
-#define V8_TRAP_HANDLER_VIA_SIMULATOR | ||
-#define V8_TRAP_HANDLER_SUPPORTED true | ||
-// Loong64 (non-simulator) on Linux. | ||
-#elif V8_TARGET_ARCH_LOONG64 && V8_HOST_ARCH_LOONG64 && V8_OS_LINUX | ||
-#define V8_TRAP_HANDLER_SUPPORTED true | ||
-// Loong64 simulator on x64 on Linux | ||
-#elif V8_TARGET_ARCH_LOONG64 && V8_HOST_ARCH_X64 && V8_OS_LINUX | ||
-#define V8_TRAP_HANDLER_VIA_SIMULATOR | ||
-#define V8_TRAP_HANDLER_SUPPORTED true | ||
-// RISCV64 (non-simulator) on Linux. | ||
-#elif V8_TARGET_ARCH_RISCV64 && V8_HOST_ARCH_RISCV64 && V8_OS_LINUX && \ | ||
- !V8_OS_ANDROID | ||
-#define V8_TRAP_HANDLER_SUPPORTED true | ||
-// RISCV64 simulator on x64 on Linux | ||
-#elif V8_TARGET_ARCH_RISCV64 && V8_HOST_ARCH_X64 && V8_OS_LINUX | ||
-#define V8_TRAP_HANDLER_VIA_SIMULATOR | ||
-#define V8_TRAP_HANDLER_SUPPORTED true | ||
-// Everything else is unsupported. | ||
-#else | ||
#define V8_TRAP_HANDLER_SUPPORTED false | ||
-#endif | ||
// Setup for shared library export. | ||
#if defined(BUILDING_V8_SHARED) && defined(V8_OS_WIN) | ||
|
||
#if V8_OS_ANDROID && V8_TRAP_HANDLER_SUPPORTED | ||
// It would require some careful security review before the trap handler |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
diff --git a/tools/v8_gypfiles/v8.gyp b/tools/v8_gypfiles/v8.gyp | ||
index 1dd0b971d4..36b7c704dd 100644 | ||
--- a/tools/v8_gypfiles/v8.gyp | ||
+++ b/tools/v8_gypfiles/v8.gyp | ||
@@ -1989,12 +1989,12 @@ | ||
], | ||
}, { # 'OS!="win"' | ||
'conditions': [ | ||
- ['_toolset == "host" and host_arch == "x64" or _toolset == "target" and target_arch=="x64"', { | ||
+ ['_toolset == "host" and host_arch == "x64" and (target_arch == "x64" or target_arch == "arm64") or (_toolset == "target" and target_arch == "x64")', { | ||
'sources': [ | ||
'<(V8_ROOT)/src/heap/base/asm/x64/push_registers_asm.cc', | ||
], | ||
}], | ||
- ['_toolset == "host" and host_arch == "ia32" or _toolset == "target" and target_arch=="ia32"', { | ||
+ ['_toolset == "host" and host_arch == "x64" and (target_arch == "arm" or target_arch == "ia32") or (_toolset == "target" and target_arch == "ia32")', { | ||
'sources': [ | ||
'<(V8_ROOT)/src/heap/base/asm/ia32/push_registers_asm.cc', | ||
], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe both
v8.gyp.patch
andcommon.gypi.patch
should be actually committed rather than being left as patch files. The reason why I made them as patch files is because I find them quite hacky and smelly. Would like to know what approach do you guys prefer.