Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

Commit

Permalink
patches: bump to 12.22.5 and 16.7.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jesec committed Aug 20, 2021
1 parent 925111b commit d0e9788
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 38 deletions.
File renamed without changes.
18 changes: 9 additions & 9 deletions patches/node.v14.17.5.cpp.patch
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@

--- node/lib/child_process.js
+++ node/lib/child_process.js
@@ -126,7 +126,7 @@ function fork(modulePath /* , args, options */) {
@@ -150,7 +150,7 @@ function fork(modulePath /* , args, options */) {
options.execPath = options.execPath || process.execPath;
options.shell = false;

Expand Down Expand Up @@ -205,7 +205,7 @@ index 0000000000..fb2d47f52b
+}());
--- node/lib/internal/bootstrap/pre_execution.js
+++ node/lib/internal/bootstrap/pre_execution.js
@@ -17,7 +17,12 @@ const { Buffer } = require('buffer');
@@ -18,7 +18,12 @@ const { Buffer } = require('buffer');
const { ERR_MANIFEST_ASSERT_INTEGRITY } = require('internal/errors').codes;
const assert = require('internal/assert');

Expand All @@ -218,7 +218,7 @@ index 0000000000..fb2d47f52b
// Patch the process object with legacy properties and normalizations
patchProcessObject(expandArgv1);
setupTraceCategoryState();
@@ -86,7 +91,7 @@ function patchProcessObject(expandArgv1) {
@@ -87,7 +92,7 @@ function patchProcessObject(expandArgv1) {
process.argv[0] = process.execPath;

if (expandArgv1 && process.argv[1] &&
Expand All @@ -229,7 +229,7 @@ index 0000000000..fb2d47f52b
try {
--- node/lib/internal/modules/cjs/loader.js
+++ node/lib/internal/modules/cjs/loader.js
@@ -84,7 +84,7 @@ const fs = require('fs');
@@ -83,7 +83,7 @@ const fs = require('fs');
const internalFS = require('internal/fs/utils');
const path = require('path');
const { sep } = path;
Expand Down Expand Up @@ -346,7 +346,7 @@ index 0000000000..fb2d47f52b
using v8::Value;
using v8::WeakCallbackInfo;
using v8::WeakCallbackType;
@@ -685,11 +686,12 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
@@ -686,11 +687,12 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
Local<ArrayBufferView> cached_data_buf;
bool produce_cached_data = false;
Local<Context> parsing_context = context;
Expand All @@ -360,15 +360,15 @@ index 0000000000..fb2d47f52b
CHECK(args[2]->IsNumber());
line_offset = args[2].As<Integer>();
CHECK(args[3]->IsNumber());
@@ -708,6 +710,7 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
@@ -709,6 +711,7 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
CHECK_NOT_NULL(sandbox);
parsing_context = sandbox->context();
}
+ sourceless = args[7]->IsTrue();
} else {
line_offset = Integer::New(isolate, 0);
column_offset = Integer::New(isolate, 0);
@@ -762,6 +765,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
@@ -763,6 +766,10 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
ShouldNotAbortOnUncaughtScope no_abort_scope(env);
Context::Scope scope(parsing_context);

Expand All @@ -379,7 +379,7 @@ index 0000000000..fb2d47f52b
MaybeLocal<UnboundScript> v8_script = ScriptCompiler::CompileUnboundScript(
isolate,
&source,
@@ -778,6 +785,13 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
@@ -779,6 +786,13 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
contextify_script);
return;
}
Expand All @@ -393,7 +393,7 @@ index 0000000000..fb2d47f52b
contextify_script->script_.Reset(isolate, v8_script.ToLocalChecked());

Local<Context> env_context = env->context();
@@ -804,6 +818,11 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
@@ -805,6 +819,11 @@ void ContextifyScript::New(const FunctionCallbackInfo<Value>& args) {
env->cached_data_produced_string(),
Boolean::New(isolate, cached_data_produced)).Check();
}
Expand Down
35 changes: 8 additions & 27 deletions patches/node.v16.4.1.cpp.patch → patches/node.v16.7.0.cpp.patch
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
}],
--- node/deps/v8/include/v8.h
+++ node/deps/v8/include/v8.h
@@ -9965,6 +9965,10 @@ class V8_EXPORT V8 {
@@ -10053,6 +10053,10 @@ class V8_EXPORT V8 {
char** argv,
bool remove_flags);

Expand Down Expand Up @@ -56,7 +56,7 @@
RegisteredExtension::RegisteredExtension(std::unique_ptr<Extension> extension)
--- node/deps/v8/src/codegen/compiler.cc
+++ node/deps/v8/src/codegen/compiler.cc
@@ -2875,7 +2875,7 @@ MaybeHandle<SharedFunctionInfo> Compiler::GetSharedFunctionInfoForScript(
@@ -2832,7 +2832,7 @@ MaybeHandle<SharedFunctionInfo> Compiler::GetSharedFunctionInfoForScript(
maybe_result = compilation_cache->LookupScript(
source, script_details.name_obj, script_details.line_offset,
script_details.column_offset, origin_options, language_mode);
Expand All @@ -67,7 +67,7 @@
compile_timer.set_consuming_code_cache();
--- node/deps/v8/src/objects/js-function.cc
+++ node/deps/v8/src/objects/js-function.cc
@@ -915,6 +915,9 @@ Handle<String> JSFunction::ToString(Handle<JSFunction> function) {
@@ -954,6 +954,9 @@ Handle<String> JSFunction::ToString(Handle<JSFunction> function) {
Handle<Object> maybe_class_positions = JSReceiver::GetDataProperty(
function, isolate->factory()->class_positions_symbol());
if (maybe_class_positions->IsClassPositions()) {
Expand All @@ -79,7 +79,7 @@
int start_position = class_positions.start();
--- node/deps/v8/src/objects/shared-function-info-inl.h
+++ node/deps/v8/src/objects/shared-function-info-inl.h
@@ -575,6 +575,14 @@ bool SharedFunctionInfo::ShouldFlushBytecode(BytecodeFlushMode mode) {
@@ -569,6 +569,14 @@ bool SharedFunctionInfo::ShouldFlushBytecode(BytecodeFlushMode mode) {
Object data = function_data(kAcquireLoad);
if (!data.IsBytecodeArray()) return false;

Expand Down Expand Up @@ -114,7 +114,7 @@
std::unique_ptr<Utf16CharacterStream> stream(
--- node/deps/v8/src/snapshot/code-serializer.cc
+++ node/deps/v8/src/snapshot/code-serializer.cc
@@ -445,12 +445,10 @@ SerializedCodeData::SanityCheckResult SerializedCodeData::SanityCheck(
@@ -444,12 +444,10 @@ SerializedCodeData::SanityCheckResult SerializedCodeData::SanityCheck(
uint32_t magic_number = GetMagicNumber();
if (magic_number != kMagicNumber) return MAGIC_NUMBER_MISMATCH;
uint32_t version_hash = GetHeaderValue(kVersionHashOffset);
Expand Down Expand Up @@ -201,7 +201,7 @@ index 0000000000..fb2d47f52b
// TODO(joyeecheung): this is also necessary for workers when they deserialize
// this toggle from the snapshot.
reconnectZeroFillToggle();
@@ -99,7 +104,8 @@ function patchProcessObject(expandArgv1) {
@@ -101,7 +106,8 @@ function patchProcessObject(expandArgv1) {
process.argv[0] = process.execPath;

if (expandArgv1 && process.argv[1] &&
Expand All @@ -213,7 +213,7 @@ index 0000000000..fb2d47f52b
try {
--- node/lib/internal/modules/cjs/loader.js
+++ node/lib/internal/modules/cjs/loader.js
@@ -84,7 +84,7 @@ const fs = require('fs');
@@ -86,7 +86,7 @@ const fs = require('fs');
const internalFS = require('internal/fs/utils');
const path = require('path');
const { sep } = path;
Expand Down Expand Up @@ -253,28 +253,9 @@ index 0000000000..fb2d47f52b
} catch (e) {
throw e; /* node-do-not-add-exception-line */
}
--- node/node.gyp
+++ node/node.gyp
@@ -31,6 +31,7 @@
'lib/internal/bootstrap/environment.js',
'lib/internal/bootstrap/loaders.js',
'lib/internal/bootstrap/node.js',
+ 'lib/internal/bootstrap/pkg.js',
'lib/internal/bootstrap/pre_execution.js',
'lib/internal/bootstrap/switches/does_own_process_state.js',
'lib/internal/bootstrap/switches/does_not_own_process_state.js',
@@ -1050,7 +1051,7 @@
'config.gypi'
],
'outputs': [
- '<(SHARED_INTERMEDIATE_DIR)/node_javascript.cc',
+ '<(SHARED_INTERMEDIATE_DIR)/node_js.cc',
],
'action': [
'python', '<@(_inputs)',
--- node/src/inspector_agent.cc
+++ node/src/inspector_agent.cc
@@ -682,8 +682,6 @@ bool Agent::Start(const std::string& path,
@@ -681,8 +681,6 @@ bool Agent::Start(const std::string& path,
StartIoThreadAsyncCallback));
uv_unref(reinterpret_cast<uv_handle_t*>(&start_io_thread_async));
start_io_thread_async.data = this;
Expand Down
4 changes: 2 additions & 2 deletions patches/patches.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"v16.4.1": ["node.v16.4.1.cpp.patch"],
"v16.7.0": ["node.v16.7.0.cpp.patch"],
"v14.17.5": ["node.v14.17.5.cpp.patch"],
"v12.22.2": ["node.v12.22.2.cpp.patch"],
"v12.22.5": ["node.v12.22.5.cpp.patch"],
"v10.24.1": ["node.v10.24.1.cpp.patch"],
"v8.17.0": ["node.v8.17.0.cpp.patch"]
}

0 comments on commit d0e9788

Please sign in to comment.