node-aix-ppc64 21.5.0 → 21.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -80,6 +80,7 @@
80
80
 
81
81
  #include <functional>
82
82
  #include <memory>
83
+ #include <optional>
83
84
  #include <ostream>
84
85
 
85
86
  // We cannot use __POSIX__ in this header because that's only defined when
@@ -659,6 +660,33 @@ enum Flags : uint64_t {
659
660
  };
660
661
  } // namespace EnvironmentFlags
661
662
 
663
+ enum class SnapshotFlags : uint32_t {
664
+ kDefault = 0,
665
+ // Whether code cache should be generated as part of the snapshot.
666
+ // Code cache reduces the time spent on compiling functions included
667
+ // in the snapshot at the expense of a bigger snapshot size and
668
+ // potentially breaking portability of the snapshot.
669
+ kWithoutCodeCache = 1 << 0,
670
+ };
671
+
672
+ struct SnapshotConfig {
673
+ SnapshotFlags flags = SnapshotFlags::kDefault;
674
+
675
+ // When builder_script_path is std::nullopt, the snapshot is generated as a
676
+ // built-in snapshot instead of a custom one, and it's expected that the
677
+ // built-in snapshot only contains states that reproduce in every run of the
678
+ // application. The event loop won't be run when generating a built-in
679
+ // snapshot, so asynchronous operations should be avoided.
680
+ //
681
+ // When builder_script_path is an std::string, it should match args[1]
682
+ // passed to CreateForSnapshotting(). The embedder is also expected to use
683
+ // LoadEnvironment() to run a script matching this path. In that case the
684
+ // snapshot is generated as a custom snapshot and the event loop is run, so
685
+ // the snapshot builder can execute asynchronous operations as long as they
686
+ // are run to completion when the snapshot is taken.
687
+ std::optional<std::string> builder_script_path;
688
+ };
689
+
662
690
  struct InspectorParentHandle {
663
691
  virtual ~InspectorParentHandle() = default;
664
692
  };
@@ -870,7 +898,8 @@ class NODE_EXTERN CommonEnvironmentSetup {
870
898
  MultiIsolatePlatform* platform,
871
899
  std::vector<std::string>* errors,
872
900
  const std::vector<std::string>& args = {},
873
- const std::vector<std::string>& exec_args = {});
901
+ const std::vector<std::string>& exec_args = {},
902
+ const SnapshotConfig& snapshot_config = {});
874
903
  EmbedderSnapshotData::Pointer CreateSnapshot();
875
904
 
876
905
  struct uv_loop_s* event_loop() const;
@@ -905,7 +934,8 @@ class NODE_EXTERN CommonEnvironmentSetup {
905
934
  std::vector<std::string>*,
906
935
  const EmbedderSnapshotData*,
907
936
  uint32_t flags,
908
- std::function<Environment*(const CommonEnvironmentSetup*)>);
937
+ std::function<Environment*(const CommonEnvironmentSetup*)>,
938
+ const SnapshotConfig* config = nullptr);
909
939
  };
910
940
 
911
941
  // Implementation for CommonEnvironmentSetup::Create
@@ -131,7 +131,7 @@ NAPI_EXTERN napi_status NAPI_CDECL
131
131
  napi_create_external_buffer(napi_env env,
132
132
  size_t length,
133
133
  void* data,
134
- napi_finalize finalize_cb,
134
+ node_api_nogc_finalize finalize_cb,
135
135
  void* finalize_hint,
136
136
  napi_value* result);
137
137
  #endif // NODE_API_NO_EXTERNAL_BUFFERS_ALLOWED
@@ -159,20 +159,20 @@ napi_create_async_work(napi_env env,
159
159
  napi_async_work* result);
160
160
  NAPI_EXTERN napi_status NAPI_CDECL napi_delete_async_work(napi_env env,
161
161
  napi_async_work work);
162
- NAPI_EXTERN napi_status NAPI_CDECL napi_queue_async_work(napi_env env,
162
+ NAPI_EXTERN napi_status NAPI_CDECL napi_queue_async_work(node_api_nogc_env env,
163
163
  napi_async_work work);
164
- NAPI_EXTERN napi_status NAPI_CDECL napi_cancel_async_work(napi_env env,
164
+ NAPI_EXTERN napi_status NAPI_CDECL napi_cancel_async_work(node_api_nogc_env env,
165
165
  napi_async_work work);
166
166
 
167
167
  // version management
168
168
  NAPI_EXTERN napi_status NAPI_CDECL
169
- napi_get_node_version(napi_env env, const napi_node_version** version);
169
+ napi_get_node_version(node_api_nogc_env env, const napi_node_version** version);
170
170
 
171
171
  #if NAPI_VERSION >= 2
172
172
 
173
173
  // Return the current libuv event loop for a given environment
174
174
  NAPI_EXTERN napi_status NAPI_CDECL
175
- napi_get_uv_event_loop(napi_env env, struct uv_loop_s** loop);
175
+ napi_get_uv_event_loop(node_api_nogc_env env, struct uv_loop_s** loop);
176
176
 
177
177
  #endif // NAPI_VERSION >= 2
178
178
 
@@ -181,11 +181,11 @@ napi_get_uv_event_loop(napi_env env, struct uv_loop_s** loop);
181
181
  NAPI_EXTERN napi_status NAPI_CDECL napi_fatal_exception(napi_env env,
182
182
  napi_value err);
183
183
 
184
- NAPI_EXTERN napi_status NAPI_CDECL
185
- napi_add_env_cleanup_hook(napi_env env, napi_cleanup_hook fun, void* arg);
184
+ NAPI_EXTERN napi_status NAPI_CDECL napi_add_env_cleanup_hook(
185
+ node_api_nogc_env env, napi_cleanup_hook fun, void* arg);
186
186
 
187
- NAPI_EXTERN napi_status NAPI_CDECL
188
- napi_remove_env_cleanup_hook(napi_env env, napi_cleanup_hook fun, void* arg);
187
+ NAPI_EXTERN napi_status NAPI_CDECL napi_remove_env_cleanup_hook(
188
+ node_api_nogc_env env, napi_cleanup_hook fun, void* arg);
189
189
 
190
190
  NAPI_EXTERN napi_status NAPI_CDECL
191
191
  napi_open_callback_scope(napi_env env,
@@ -209,7 +209,7 @@ napi_create_threadsafe_function(napi_env env,
209
209
  size_t max_queue_size,
210
210
  size_t initial_thread_count,
211
211
  void* thread_finalize_data,
212
- napi_finalize thread_finalize_cb,
212
+ node_api_nogc_finalize thread_finalize_cb,
213
213
  void* context,
214
214
  napi_threadsafe_function_call_js call_js_cb,
215
215
  napi_threadsafe_function* result);
@@ -228,18 +228,18 @@ napi_acquire_threadsafe_function(napi_threadsafe_function func);
228
228
  NAPI_EXTERN napi_status NAPI_CDECL napi_release_threadsafe_function(
229
229
  napi_threadsafe_function func, napi_threadsafe_function_release_mode mode);
230
230
 
231
- NAPI_EXTERN napi_status NAPI_CDECL
232
- napi_unref_threadsafe_function(napi_env env, napi_threadsafe_function func);
231
+ NAPI_EXTERN napi_status NAPI_CDECL napi_unref_threadsafe_function(
232
+ node_api_nogc_env env, napi_threadsafe_function func);
233
233
 
234
- NAPI_EXTERN napi_status NAPI_CDECL
235
- napi_ref_threadsafe_function(napi_env env, napi_threadsafe_function func);
234
+ NAPI_EXTERN napi_status NAPI_CDECL napi_ref_threadsafe_function(
235
+ node_api_nogc_env env, napi_threadsafe_function func);
236
236
 
237
237
  #endif // NAPI_VERSION >= 4
238
238
 
239
239
  #if NAPI_VERSION >= 8
240
240
 
241
241
  NAPI_EXTERN napi_status NAPI_CDECL
242
- napi_add_async_cleanup_hook(napi_env env,
242
+ napi_add_async_cleanup_hook(node_api_nogc_env env,
243
243
  napi_async_cleanup_hook hook,
244
244
  void* arg,
245
245
  napi_async_cleanup_hook_handle* remove_handle);
@@ -252,7 +252,7 @@ napi_remove_async_cleanup_hook(napi_async_cleanup_hook_handle remove_handle);
252
252
  #if NAPI_VERSION >= 9
253
253
 
254
254
  NAPI_EXTERN napi_status NAPI_CDECL
255
- node_api_get_module_file_name(napi_env env, const char** result);
255
+ node_api_get_module_file_name(node_api_nogc_env env, const char** result);
256
256
 
257
257
  #endif // NAPI_VERSION >= 9
258
258
 
@@ -23,7 +23,7 @@
23
23
  #define SRC_NODE_VERSION_H_
24
24
 
25
25
  #define NODE_MAJOR_VERSION 21
26
- #define NODE_MINOR_VERSION 5
26
+ #define NODE_MINOR_VERSION 6
27
27
  #define NODE_PATCH_VERSION 0
28
28
 
29
29
  #define NODE_VERSION_IS_LTS 0
@@ -1,5 +1,5 @@
1
1
  /* zlib.h -- interface of the 'zlib' general purpose compression library
2
- version 1.3, August 18th, 2023
2
+ version 1.3.0.1, August xxth, 2023
3
3
 
4
4
  Copyright (C) 1995-2023 Jean-loup Gailly and Mark Adler
5
5
 
@@ -37,12 +37,12 @@
37
37
  extern "C" {
38
38
  #endif
39
39
 
40
- #define ZLIB_VERSION "1.3"
41
- #define ZLIB_VERNUM 0x1300
40
+ #define ZLIB_VERSION "1.3.0.1-motley"
41
+ #define ZLIB_VERNUM 0x1301
42
42
  #define ZLIB_VER_MAJOR 1
43
43
  #define ZLIB_VER_MINOR 3
44
44
  #define ZLIB_VER_REVISION 0
45
- #define ZLIB_VER_SUBREVISION 0
45
+ #define ZLIB_VER_SUBREVISION 1
46
46
 
47
47
  /*
48
48
  The 'zlib' compression library provides in-memory compression and
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-aix-ppc64",
3
- "version": "v21.5.0",
3
+ "version": "v21.6.0",
4
4
  "description": "node",
5
5
  "bin": {
6
6
  "node": "bin/node"
@@ -82,6 +82,9 @@ Allow file system read access when using the permission model.
82
82
  .It Fl -allow-fs-write
83
83
  Allow file system write access when using the permission model.
84
84
  .
85
+ .It Fl -allow-addons
86
+ Allow using native addons when using the permission model.
87
+ .
85
88
  .It Fl -allow-child-process
86
89
  Allow spawning process when using the permission model.
87
90
  .