koffi 2.10.1 → 2.12.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.
- package/CHANGELOG.md +314 -99
- package/README.md +1 -0
- package/build/koffi/darwin_arm64/koffi.node +0 -0
- package/build/koffi/darwin_x64/koffi.node +0 -0
- package/build/koffi/freebsd_arm64/koffi.node +0 -0
- package/build/koffi/freebsd_ia32/koffi.node +0 -0
- package/build/koffi/freebsd_x64/koffi.node +0 -0
- package/build/koffi/linux_arm64/koffi.node +0 -0
- package/build/koffi/linux_armhf/koffi.node +0 -0
- package/build/koffi/linux_ia32/koffi.node +0 -0
- package/build/koffi/linux_loong64/koffi.node +0 -0
- package/build/koffi/linux_riscv64d/koffi.node +0 -0
- package/build/koffi/linux_x64/koffi.node +0 -0
- package/build/koffi/musl_x64/koffi.node +0 -0
- package/build/koffi/openbsd_ia32/koffi.node +0 -0
- package/build/koffi/openbsd_x64/koffi.node +0 -0
- package/build/koffi/win32_arm64/koffi.node +0 -0
- package/build/koffi/win32_ia32/koffi.node +0 -0
- package/build/koffi/win32_x64/koffi.node +0 -0
- package/doc/assets.ini +1 -1
- package/doc/{flaat/flaat.css → flat/flat.css} +2 -0
- package/doc/{flaat → flat}/normal.css +125 -31
- package/doc/{flaat → flat}/print.css +1 -2
- package/doc/flat/reset.css +41 -0
- package/doc/{flaat → flat}/small.css +5 -2
- package/doc/{flaat/flaat.js → flat/static.js} +21 -10
- package/doc/pages/contribute.md +3 -3
- package/doc/pages/output.md +32 -1
- package/doc/pages/packaging.md +5 -5
- package/doc/pages/platforms.md +2 -0
- package/doc/pages/pointers.md +75 -0
- package/doc/static/koffi.css +3 -2
- package/index.js +35 -9
- package/indirect.js +25 -9
- package/package.json +2 -2
- package/src/cnoke/src/tools.js +6 -0
- package/src/core/libcc/libcc.hh +3 -1
- package/src/koffi/CMakeLists.txt +2 -0
- package/src/koffi/src/abi_loong64.cc +23 -0
- package/src/koffi/src/abi_loong64_asm.S +240 -0
- package/src/koffi/src/abi_riscv64.cc +2 -2
- package/src/koffi/src/ffi.cc +39 -0
- package/src/koffi/src/ffi.hh +1 -1
- package/src/koffi/src/util.hh +21 -5
- package/build/koffi/linux_riscv64/koffi.node +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -5,112 +5,171 @@
|
|
|
5
5
|
|
|
6
6
|
## Koffi 2
|
|
7
7
|
|
|
8
|
+
### Koffi 2.12
|
|
9
|
+
|
|
10
|
+
#### Koffi 2.12.0
|
|
11
|
+
|
|
12
|
+
*Released on 2025-06-19*
|
|
13
|
+
|
|
14
|
+
- Support LoongArch64 architecture (thanks to [wjh-la](https://github.com/wjh-la))
|
|
15
|
+
- Fix wrong path for RISC-V 64 prebuild
|
|
16
|
+
|
|
17
|
+
### Koffi 2.11
|
|
18
|
+
|
|
19
|
+
#### Koffi 2.11.0
|
|
20
|
+
|
|
21
|
+
*Released on 2025-04-09*
|
|
22
|
+
|
|
23
|
+
- Add `koffi.view()` to [access memory without copy](pointers#external-buffers-views)
|
|
24
|
+
- Various documentation fixes and improvements
|
|
25
|
+
|
|
8
26
|
### Koffi 2.10
|
|
9
27
|
|
|
10
|
-
#### Koffi 2.10.1
|
|
28
|
+
#### Koffi 2.10.1
|
|
29
|
+
|
|
30
|
+
*Released on 2025-01-24*
|
|
11
31
|
|
|
12
32
|
- Fix detection of ARM32 in build script in some cases
|
|
13
33
|
- Fix wrong path for ARM32 prebuild
|
|
14
34
|
|
|
15
|
-
#### Koffi 2.10.0
|
|
35
|
+
#### Koffi 2.10.0
|
|
36
|
+
|
|
37
|
+
*Released on 2024-12-22*
|
|
16
38
|
|
|
17
39
|
- Allow [redefinition of opaque types](misc#circular-references) to concrete struct or union
|
|
40
|
+
- Clear out executable stack bit from ELF targets (`-z noexecstack`)
|
|
18
41
|
- Update documentation style
|
|
19
42
|
|
|
20
43
|
### Koffi 2.9
|
|
21
44
|
|
|
22
|
-
#### Koffi 2.9.2
|
|
45
|
+
#### Koffi 2.9.2
|
|
46
|
+
|
|
47
|
+
*Released on 2024-11-08*
|
|
23
48
|
|
|
24
49
|
- Fix non-aligned pointers when pushing UTF-16 and UTF-32 string parameters
|
|
25
50
|
- Various documentation fixes and improvements
|
|
26
51
|
|
|
27
|
-
#### Koffi 2.9.1
|
|
52
|
+
#### Koffi 2.9.1
|
|
53
|
+
|
|
54
|
+
*Released on 2024-09-23*
|
|
28
55
|
|
|
29
56
|
- Fix x86 32-bit support regression in 2.9.0
|
|
30
57
|
- Add missing TS definition for `koffi.alloc()`
|
|
31
58
|
- Support `koffi.load(null)` in TS definition file
|
|
32
59
|
|
|
33
|
-
#### Koffi 2.9.0
|
|
60
|
+
#### Koffi 2.9.0
|
|
61
|
+
|
|
62
|
+
*Released on 2024-07-22*
|
|
34
63
|
|
|
35
64
|
- Add support for char32_t and wchar_t (wide) strings
|
|
36
65
|
- Include Linux/musl x64 prebuild (based on Alpine)
|
|
37
66
|
|
|
38
67
|
### Koffi 2.8
|
|
39
68
|
|
|
40
|
-
#### Koffi 2.8.11
|
|
69
|
+
#### Koffi 2.8.11
|
|
70
|
+
|
|
71
|
+
*Released on 2024-06-19*
|
|
41
72
|
|
|
42
73
|
- Work around MSVC compiler bug introduced in Visual Studio 17.10
|
|
43
74
|
|
|
44
75
|
> [!WARNING]
|
|
45
76
|
> Use on platforms without pre-built binaries is broken in Koffi 2.8.10, skip this version.
|
|
46
77
|
|
|
47
|
-
#### Koffi 2.8.9
|
|
78
|
+
#### Koffi 2.8.9
|
|
79
|
+
|
|
80
|
+
*Released on 2024-05-17*
|
|
48
81
|
|
|
49
82
|
- Fix ABI issue regarding bool return values on x86_64 (and possibly other platforms)
|
|
50
83
|
|
|
51
|
-
#### Koffi 2.8.8
|
|
84
|
+
#### Koffi 2.8.8
|
|
85
|
+
|
|
86
|
+
*Released on 2024-04-26*
|
|
52
87
|
|
|
53
88
|
- Support use of buffers with mismatched size (truncation or zero-filling)
|
|
54
89
|
|
|
55
|
-
#### Koffi 2.8.7
|
|
90
|
+
#### Koffi 2.8.7
|
|
91
|
+
|
|
92
|
+
*Released on 2024-04-23*
|
|
56
93
|
|
|
57
94
|
- Improve compatibility with SEHOP on Windows ([@longhun12346](https://github.com/longhun12346))
|
|
58
95
|
|
|
59
|
-
#### Koffi 2.8.6
|
|
96
|
+
#### Koffi 2.8.6
|
|
97
|
+
|
|
98
|
+
*Released on 2024-04-12*
|
|
60
99
|
|
|
61
100
|
- Support [loading library](functions#loading-options) with RTLD_DEEPBIND where supported
|
|
62
101
|
|
|
63
|
-
#### Koffi 2.8.5
|
|
102
|
+
#### Koffi 2.8.5
|
|
103
|
+
|
|
104
|
+
*Released on 2024-04-11*
|
|
64
105
|
|
|
65
106
|
- Prevent obviously invalid type and member names
|
|
66
107
|
- Fix possible infinite loop / UB for `koffi.load()` errors on POSIX systems
|
|
67
108
|
- Fix null return value instead of exception for some errors in `koffi.load()` on Windows
|
|
68
109
|
|
|
69
|
-
#### Koffi 2.8.4
|
|
110
|
+
#### Koffi 2.8.4
|
|
111
|
+
|
|
112
|
+
*Released on 2024-04-09*
|
|
70
113
|
|
|
71
114
|
- Use simpler workaround for Node 20.12+ and 21.6+ to avoid excessive memory use
|
|
72
115
|
|
|
73
116
|
> [!WARNING]
|
|
74
117
|
> Some pre-built binaries are missing in Koffi 2.8.3, skip this version.
|
|
75
118
|
|
|
76
|
-
#### Koffi 2.8.2
|
|
119
|
+
#### Koffi 2.8.2
|
|
120
|
+
|
|
121
|
+
*Released on 2024-04-07*
|
|
77
122
|
|
|
78
123
|
- Support [loading library](functions#loading-options) with RTLD_GLOBAL on POSIX platforms
|
|
79
124
|
|
|
80
|
-
#### Koffi 2.8.1
|
|
125
|
+
#### Koffi 2.8.1
|
|
126
|
+
|
|
127
|
+
*Released on 2024-04-04*
|
|
81
128
|
|
|
82
129
|
- Fix incompatibility with Node 20.12+ and 21.6+
|
|
83
130
|
|
|
84
|
-
#### Koffi 2.8.0
|
|
131
|
+
#### Koffi 2.8.0
|
|
132
|
+
|
|
133
|
+
*Released on 2024-02-12*
|
|
85
134
|
|
|
86
135
|
- Support pushing pointers for string arguments
|
|
87
136
|
- Add `koffi.alloc()` for [stable pointers](output#stable-pointers)
|
|
88
137
|
|
|
89
138
|
### Koffi 2.7
|
|
90
139
|
|
|
91
|
-
#### Koffi 2.7.4
|
|
140
|
+
#### Koffi 2.7.4
|
|
141
|
+
|
|
142
|
+
*Released on 2024-02-04*
|
|
92
143
|
|
|
93
144
|
- Support callbacks happening on main thread but outside JS call (such as during event loop)
|
|
94
145
|
- Improve stability after `koffi.reset()`
|
|
95
146
|
- Expose internal Node/NAPI `env` pointer
|
|
96
147
|
- Name main Koffi API functions
|
|
97
148
|
|
|
98
|
-
#### Koffi 2.7.3
|
|
149
|
+
#### Koffi 2.7.3
|
|
150
|
+
|
|
151
|
+
*Released on 2024-01-26*
|
|
99
152
|
|
|
100
153
|
- Support decoding NULL terminated arrays
|
|
101
154
|
|
|
102
|
-
#### Koffi 2.7.2
|
|
155
|
+
#### Koffi 2.7.2
|
|
156
|
+
|
|
157
|
+
*Released on 2024-01-15*
|
|
103
158
|
|
|
104
159
|
- Add missing TypeScript declaration for `koffi.free()`
|
|
105
160
|
- Fix TypeScript declaration of `koffi.encode()`
|
|
106
161
|
- Try to improve compatibility with webpack
|
|
107
162
|
|
|
108
|
-
#### Koffi 2.7.1
|
|
163
|
+
#### Koffi 2.7.1
|
|
164
|
+
|
|
165
|
+
*Released on 2024-01-02*
|
|
109
166
|
|
|
110
167
|
- Support C-like `int[3]` syntax for [fixed array types](input#fixed-size-c-arrays)
|
|
111
168
|
- Refuse type specifiers with invalid tokens at the end (previously ignored)
|
|
112
169
|
|
|
113
|
-
#### Koffi 2.7.0
|
|
170
|
+
#### Koffi 2.7.0
|
|
171
|
+
|
|
172
|
+
*Released on 2023-12-21*
|
|
114
173
|
|
|
115
174
|
- Support alternative [callback calling convention](callbacks#callback-types) in classic syntax
|
|
116
175
|
- Change syntax for [calling conventions](functions#calling-conventions) with classic syntax
|
|
@@ -118,20 +177,28 @@
|
|
|
118
177
|
|
|
119
178
|
### Koffi 2.6
|
|
120
179
|
|
|
121
|
-
#### Koffi 2.6.12
|
|
180
|
+
#### Koffi 2.6.12
|
|
181
|
+
|
|
182
|
+
*Released on 2023-12-11*
|
|
122
183
|
|
|
123
184
|
- Fix possible crash introduced in Koffi 2.6.11
|
|
124
185
|
|
|
125
|
-
#### Koffi 2.6.11
|
|
186
|
+
#### Koffi 2.6.11
|
|
187
|
+
|
|
188
|
+
*Released on 2023-12-05*
|
|
126
189
|
|
|
127
190
|
- Speed up resolving simple and often used type names
|
|
128
191
|
- Fix use of optional length argument with [koffi.encode()](variables#encode-to-c-memory)
|
|
129
192
|
|
|
130
|
-
#### Koffi 2.6.10
|
|
193
|
+
#### Koffi 2.6.10
|
|
194
|
+
|
|
195
|
+
*Released on 2023-11-29*
|
|
131
196
|
|
|
132
197
|
- Protect GetLastError() value from Node.js and V8 on Windows
|
|
133
198
|
|
|
134
|
-
#### Koffi 2.6.9
|
|
199
|
+
#### Koffi 2.6.9
|
|
200
|
+
|
|
201
|
+
*Released on 2023-11-25*
|
|
135
202
|
|
|
136
203
|
- Search in DLL directory for additional dependencies on Windows
|
|
137
204
|
- Ignore prototype properties when making structs or unions
|
|
@@ -141,32 +208,44 @@
|
|
|
141
208
|
> [!WARNING]
|
|
142
209
|
> Loading Win32 system libraries can fail in Koffi 2.6.8, skip this version.
|
|
143
210
|
|
|
144
|
-
#### Koffi 2.6.6
|
|
211
|
+
#### Koffi 2.6.6
|
|
212
|
+
|
|
213
|
+
*Released on 2023-10-28*
|
|
145
214
|
|
|
146
215
|
- Better handle errors while making struct or union types
|
|
147
216
|
|
|
148
|
-
#### Koffi 2.6.5
|
|
217
|
+
#### Koffi 2.6.5
|
|
218
|
+
|
|
219
|
+
*Released on 2023-10-28*
|
|
149
220
|
|
|
150
221
|
- Allow self-referential structs and unions
|
|
151
222
|
- Fix rare Node.js "FATAL ERROR" with some invalid type specifiers
|
|
152
223
|
|
|
153
|
-
#### Koffi 2.6.4
|
|
224
|
+
#### Koffi 2.6.4
|
|
225
|
+
|
|
226
|
+
*Released on 2023-10-26*
|
|
154
227
|
|
|
155
228
|
- Fix build issue with recent Visual Studio versions
|
|
156
229
|
|
|
157
|
-
#### Koffi 2.6.3
|
|
230
|
+
#### Koffi 2.6.3
|
|
231
|
+
|
|
232
|
+
*Released on 2023-10-17*
|
|
158
233
|
|
|
159
234
|
- Add indirect loading script to help some bundlers
|
|
160
235
|
|
|
161
236
|
> [!WARNING]
|
|
162
237
|
> Pre-built binaries don't work correctly in Koffi 2.6.2, skip this version.
|
|
163
238
|
|
|
164
|
-
#### Koffi 2.6.1
|
|
239
|
+
#### Koffi 2.6.1
|
|
240
|
+
|
|
241
|
+
*Released on 2023-09-18*
|
|
165
242
|
|
|
166
243
|
- Support string direction qualifiers in classic function definitions
|
|
167
244
|
- Fix possible off-by-one array access when parsing type name
|
|
168
245
|
|
|
169
|
-
#### Koffi 2.6.0
|
|
246
|
+
#### Koffi 2.6.0
|
|
247
|
+
|
|
248
|
+
*Released on 2023-09-13*
|
|
170
249
|
|
|
171
250
|
**New features:**
|
|
172
251
|
|
|
@@ -181,21 +260,29 @@
|
|
|
181
260
|
|
|
182
261
|
### Koffi 2.5
|
|
183
262
|
|
|
184
|
-
#### Koffi 2.5.20
|
|
263
|
+
#### Koffi 2.5.20
|
|
264
|
+
|
|
265
|
+
*Released on 2023-08-31*
|
|
185
266
|
|
|
186
267
|
- Fix possible crash with async registered callbacks introduced in Koffi 2.5.19
|
|
187
268
|
- Various documentation fixes and improvements
|
|
188
269
|
|
|
189
|
-
#### Koffi 2.5.19
|
|
270
|
+
#### Koffi 2.5.19
|
|
271
|
+
|
|
272
|
+
*Released on 2023-08-29*
|
|
190
273
|
|
|
191
274
|
- Create thread-safe function broker lazily
|
|
192
275
|
- Add [koffi.reset()](misc#reset-internal-state) for type names and async broker
|
|
193
276
|
|
|
194
|
-
#### Koffi 2.5.18
|
|
277
|
+
#### Koffi 2.5.18
|
|
278
|
+
|
|
279
|
+
*Released on 2023-08-27*
|
|
195
280
|
|
|
196
281
|
- Fix compatibility with Electron
|
|
197
282
|
|
|
198
|
-
#### Koffi 2.5.16
|
|
283
|
+
#### Koffi 2.5.16
|
|
284
|
+
|
|
285
|
+
*Released on 2023-08-25*
|
|
199
286
|
|
|
200
287
|
- Run Koffi tests through usual index.js entry point
|
|
201
288
|
- Fix DLL error when using Koffi from NW.js on Windows
|
|
@@ -204,21 +291,29 @@
|
|
|
204
291
|
> [!WARNING]
|
|
205
292
|
> Pre-built binaries don't work correctly in Koffi 2.5.13 to 2.5.15, skip those versions.
|
|
206
293
|
|
|
207
|
-
#### Koffi 2.5.12
|
|
294
|
+
#### Koffi 2.5.12
|
|
295
|
+
|
|
296
|
+
*Released on 2023-08-21*
|
|
208
297
|
|
|
209
298
|
- Fix native module bundling for FreeBSD ARM64 and Linux RISC-V 64
|
|
210
299
|
- Increase maximum number of parameters to 64
|
|
211
300
|
|
|
212
|
-
#### Koffi 2.5.11
|
|
301
|
+
#### Koffi 2.5.11
|
|
302
|
+
|
|
303
|
+
*Released on 2023-08-03*
|
|
213
304
|
|
|
214
305
|
- Support casting function pointers with [koffi.as()](pointers#handling-void-pointers)
|
|
215
306
|
- Build in C++20 mode
|
|
216
307
|
|
|
217
|
-
#### Koffi 2.5.10
|
|
308
|
+
#### Koffi 2.5.10
|
|
309
|
+
|
|
310
|
+
*Released on 2023-08-01*
|
|
218
311
|
|
|
219
312
|
- Fix CMake regression when client has to build Koffi
|
|
220
313
|
|
|
221
|
-
#### Koffi 2.5.9
|
|
314
|
+
#### Koffi 2.5.9
|
|
315
|
+
|
|
316
|
+
*Released on 2023-07-28*
|
|
222
317
|
|
|
223
318
|
**Main changes:**
|
|
224
319
|
|
|
@@ -230,43 +325,61 @@
|
|
|
230
325
|
- Add missing unload() export to TS file
|
|
231
326
|
- Add export for koffi.types in TS file
|
|
232
327
|
|
|
233
|
-
#### Koffi 2.5.8
|
|
328
|
+
#### Koffi 2.5.8
|
|
329
|
+
|
|
330
|
+
*Released on 2023-07-26*
|
|
234
331
|
|
|
235
332
|
- Add more search paths for native Koffi modules
|
|
236
333
|
- Add section [about bundling](start#bundling-koffi) to documentation
|
|
237
334
|
|
|
238
|
-
#### Koffi 2.5.7
|
|
335
|
+
#### Koffi 2.5.7
|
|
336
|
+
|
|
337
|
+
*Released on 2023-07-19*
|
|
239
338
|
|
|
240
339
|
- Point package to new repository
|
|
241
340
|
|
|
242
|
-
#### Koffi 2.5.6
|
|
341
|
+
#### Koffi 2.5.6
|
|
342
|
+
|
|
343
|
+
*Released on 2023-07-19*
|
|
243
344
|
|
|
244
345
|
- Increase limit of output parameters from 16 to 32
|
|
245
346
|
|
|
246
|
-
#### Koffi 2.5.5
|
|
347
|
+
#### Koffi 2.5.5
|
|
348
|
+
|
|
349
|
+
*Released on 2023-07-17*
|
|
247
350
|
|
|
248
351
|
- Support decoding non-char null-terminated arrays
|
|
249
352
|
|
|
250
|
-
#### Koffi 2.5.4
|
|
353
|
+
#### Koffi 2.5.4
|
|
354
|
+
|
|
355
|
+
*Released on 2023-07-14*
|
|
251
356
|
|
|
252
357
|
- Fix `koffi.pointer()` not accepting disposable types
|
|
253
358
|
- Fix potential issues when making pointers to anonymous types
|
|
254
359
|
|
|
255
|
-
#### Koffi 2.5.3
|
|
360
|
+
#### Koffi 2.5.3
|
|
361
|
+
|
|
362
|
+
*Released on 2023-07-05*
|
|
256
363
|
|
|
257
364
|
- Add missing union exports in TS definition file
|
|
258
365
|
- Fix some parameter names in TS definition file
|
|
259
366
|
|
|
260
|
-
#### Koffi 2.5.2
|
|
367
|
+
#### Koffi 2.5.2
|
|
368
|
+
|
|
369
|
+
*Released on 2023-07-04*
|
|
261
370
|
|
|
262
371
|
- Default initialize unset object/struct members
|
|
263
372
|
|
|
264
|
-
#### Koffi 2.5.1
|
|
373
|
+
#### Koffi 2.5.1
|
|
374
|
+
|
|
375
|
+
*Released on 2023-06-20*
|
|
265
376
|
|
|
266
377
|
- Fix crash with some struct types in System V 64 ABI
|
|
267
378
|
- Always use direct passthrough for buffer arguments
|
|
268
379
|
|
|
269
|
-
#### Koffi 2.5.0
|
|
380
|
+
#### Koffi 2.5.0
|
|
381
|
+
|
|
382
|
+
*Released on 2023-06-20*
|
|
270
383
|
|
|
271
384
|
**New features:**
|
|
272
385
|
|
|
@@ -279,12 +392,16 @@
|
|
|
279
392
|
|
|
280
393
|
### Koffi 2.4
|
|
281
394
|
|
|
282
|
-
#### Koffi 2.4.2
|
|
395
|
+
#### Koffi 2.4.2
|
|
396
|
+
|
|
397
|
+
*Released on 2023-06-04*
|
|
283
398
|
|
|
284
399
|
- Support calling variadic function pointers
|
|
285
400
|
- Add documentation for function pointers
|
|
286
401
|
|
|
287
|
-
#### Koffi 2.4.1
|
|
402
|
+
#### Koffi 2.4.1
|
|
403
|
+
|
|
404
|
+
*Released on 2023-06-03*
|
|
288
405
|
|
|
289
406
|
**Main changes:**
|
|
290
407
|
|
|
@@ -301,49 +418,69 @@
|
|
|
301
418
|
|
|
302
419
|
### Koffi 2.3
|
|
303
420
|
|
|
304
|
-
#### Koffi 2.3.20
|
|
421
|
+
#### Koffi 2.3.20
|
|
422
|
+
|
|
423
|
+
*Released on 2023-05-15*
|
|
305
424
|
|
|
306
425
|
- Support explicit library unloading with `lib.unload()`
|
|
307
426
|
|
|
308
|
-
#### Koffi 2.3.19
|
|
427
|
+
#### Koffi 2.3.19
|
|
428
|
+
|
|
429
|
+
*Released on 2023-04-21*
|
|
309
430
|
|
|
310
431
|
- Actually allow non-ambiguous [string] values for `void *` arguments
|
|
311
432
|
|
|
312
|
-
#### Koffi 2.3.18
|
|
433
|
+
#### Koffi 2.3.18
|
|
434
|
+
|
|
435
|
+
*Released on 2023-04-21*
|
|
313
436
|
|
|
314
437
|
- Fix possible crash on exit caused by unregistered callbacks
|
|
315
438
|
|
|
316
|
-
#### Koffi 2.3.17
|
|
439
|
+
#### Koffi 2.3.17
|
|
440
|
+
|
|
441
|
+
*Released on 2023-04-20*
|
|
317
442
|
|
|
318
443
|
- Allow strings for input `void *`, `int8_t *` and `int16_t *` pointer arguments
|
|
319
444
|
- Support using `[string]` (single-element string arrays) for polymorphic input/output arguments
|
|
320
445
|
|
|
321
|
-
#### Koffi 2.3.16
|
|
446
|
+
#### Koffi 2.3.16
|
|
447
|
+
|
|
448
|
+
*Released on 2023-04-11*
|
|
322
449
|
|
|
323
450
|
- Fix Windows ARM64 build to work with official Node.js version
|
|
324
451
|
- Compile Windows builds with Visual Studio 2022 17.5.3
|
|
325
452
|
- Support null in `koffi.free()` and `koffi.address()`
|
|
326
453
|
|
|
327
|
-
#### Koffi 2.3.15
|
|
454
|
+
#### Koffi 2.3.15
|
|
455
|
+
|
|
456
|
+
*Released on 2023-04-10*
|
|
328
457
|
|
|
329
458
|
- Improve manual decoding of 0-terminated strings
|
|
330
459
|
- Add checks around array conversion hints
|
|
331
460
|
|
|
332
|
-
#### Koffi 2.3.14
|
|
461
|
+
#### Koffi 2.3.14
|
|
462
|
+
|
|
463
|
+
*Released on 2023-04-05*
|
|
333
464
|
|
|
334
465
|
- Add `koffi.errno()` function to get and set current errno value
|
|
335
466
|
- Add `koffi.os.errno` object with valid errno codes
|
|
336
467
|
|
|
337
|
-
#### Koffi 2.3.13
|
|
468
|
+
#### Koffi 2.3.13
|
|
469
|
+
|
|
470
|
+
*Released on 2023-03-30*
|
|
338
471
|
|
|
339
472
|
- Add `koffi.address()` to get the raw value of a wrapper pointer
|
|
340
473
|
|
|
341
|
-
#### Koffi 2.3.12
|
|
474
|
+
#### Koffi 2.3.12
|
|
475
|
+
|
|
476
|
+
*Released on 2023-03-30*
|
|
342
477
|
|
|
343
478
|
- Fix broken syntax in TS definition file
|
|
344
479
|
- Add missing exported properties in TS file
|
|
345
480
|
|
|
346
|
-
#### Koffi 2.3.11
|
|
481
|
+
#### Koffi 2.3.11
|
|
482
|
+
|
|
483
|
+
*Released on 2023-03-30*
|
|
347
484
|
|
|
348
485
|
**Main changes:**
|
|
349
486
|
|
|
@@ -355,27 +492,37 @@
|
|
|
355
492
|
- Avoid using `statx()` to allow compilation with glibc < 2.28
|
|
356
493
|
- Reorganize NPM package files to be less convoluted
|
|
357
494
|
|
|
358
|
-
#### Koffi 2.3.9
|
|
495
|
+
#### Koffi 2.3.9
|
|
496
|
+
|
|
497
|
+
*Released on 2023-03-10*
|
|
359
498
|
|
|
360
499
|
- Relicense under MIT license
|
|
361
500
|
|
|
362
|
-
#### Koffi 2.3.8
|
|
501
|
+
#### Koffi 2.3.8
|
|
502
|
+
|
|
503
|
+
*Released on 2023-02-28*
|
|
363
504
|
|
|
364
505
|
- Disable non-ready union support
|
|
365
506
|
- Simplify Windows stack allocation and drop NOACCESS and GUARD pages
|
|
366
507
|
- Adjust Windows TEB SEH chain and GuaranteedStackBytes for Koffi calls
|
|
367
508
|
|
|
368
|
-
#### Koffi 2.3.7
|
|
509
|
+
#### Koffi 2.3.7
|
|
510
|
+
|
|
511
|
+
*Released on 2023-02-27*
|
|
369
512
|
|
|
370
513
|
- Fix missing require in index.js ([@gastonFrecceroNapse](https://github.com/gastonFrecceroNapse))
|
|
371
514
|
- Reduce NPM package bloat (from 65 MB to 20 MB) caused by changes in 2.3.6
|
|
372
515
|
|
|
373
|
-
#### Koffi 2.3.6
|
|
516
|
+
#### Koffi 2.3.6
|
|
517
|
+
|
|
518
|
+
*Released on 2023-02-26*
|
|
374
519
|
|
|
375
520
|
- Fix broken TS definition file
|
|
376
521
|
- Keep all prebuilt binaries and load correct one at runtime
|
|
377
522
|
|
|
378
|
-
#### Koffi 2.3.5
|
|
523
|
+
#### Koffi 2.3.5
|
|
524
|
+
|
|
525
|
+
*Released on 2023-02-24*
|
|
379
526
|
|
|
380
527
|
**Main fixes:**
|
|
381
528
|
|
|
@@ -391,11 +538,15 @@
|
|
|
391
538
|
- Mark optional properties in TS TypeInfo class
|
|
392
539
|
- Minor performance improvements
|
|
393
540
|
|
|
394
|
-
#### Koffi 2.3.4
|
|
541
|
+
#### Koffi 2.3.4
|
|
542
|
+
|
|
543
|
+
*Released on 2023-01-31*
|
|
395
544
|
|
|
396
545
|
- Fix error when installing Koffi on Windows (2.3.2)
|
|
397
546
|
|
|
398
|
-
#### Koffi 2.3.2
|
|
547
|
+
#### Koffi 2.3.2
|
|
548
|
+
|
|
549
|
+
*Released on 2023-01-30*
|
|
399
550
|
|
|
400
551
|
**Main changes:**
|
|
401
552
|
|
|
@@ -408,13 +559,17 @@
|
|
|
408
559
|
- Avoid CNoke dependency
|
|
409
560
|
- Clear out development dependencies from package.json
|
|
410
561
|
|
|
411
|
-
#### Koffi 2.3.1
|
|
562
|
+
#### Koffi 2.3.1
|
|
563
|
+
|
|
564
|
+
*Released on 2023-01-30*
|
|
412
565
|
|
|
413
566
|
- Error out when trying to use ambiguous `void *` arguments (input and/or output)
|
|
414
567
|
- Adjust TypeScript definitions ([@insraq](https://github.com/insraq))
|
|
415
568
|
- Fix possible crash when parsing invalid prototype
|
|
416
569
|
|
|
417
|
-
#### Koffi 2.3.0
|
|
570
|
+
#### Koffi 2.3.0
|
|
571
|
+
|
|
572
|
+
*Released on 2023-01-25*
|
|
418
573
|
|
|
419
574
|
**Main changes:**
|
|
420
575
|
|
|
@@ -433,21 +588,29 @@
|
|
|
433
588
|
|
|
434
589
|
### Koffi 2.2
|
|
435
590
|
|
|
436
|
-
#### Koffi 2.2.5
|
|
591
|
+
#### Koffi 2.2.5
|
|
592
|
+
|
|
593
|
+
*Released on 2023-01-23*
|
|
437
594
|
|
|
438
595
|
- Relicense Koffi under LGPL 3.0
|
|
439
596
|
|
|
440
|
-
#### Koffi 2.2.4
|
|
597
|
+
#### Koffi 2.2.4
|
|
598
|
+
|
|
599
|
+
*Released on 2023-01-19*
|
|
441
600
|
|
|
442
601
|
- Fix memory leak on Windows (in Koffi 2.2.3) when running many async calls
|
|
443
602
|
- Reorganize documentation pages
|
|
444
603
|
|
|
445
|
-
#### Koffi 2.2.3
|
|
604
|
+
#### Koffi 2.2.3
|
|
605
|
+
|
|
606
|
+
*Released on 2023-01-17*
|
|
446
607
|
|
|
447
608
|
- Support native code that uses [Structured Exception Handling (SEH)](https://learn.microsoft.com/en-us/cpp/cpp/structured-exception-handling-c-cpp) on Windows (x86, x64 and ARM64)
|
|
448
609
|
- Try to use ebp/rbp as frame pointer in x86/x64 ASM code
|
|
449
610
|
|
|
450
|
-
#### Koffi 2.2.2
|
|
611
|
+
#### Koffi 2.2.2
|
|
612
|
+
|
|
613
|
+
*Released on 2023-01-14*
|
|
451
614
|
|
|
452
615
|
**Main fixes:**
|
|
453
616
|
|
|
@@ -461,11 +624,15 @@
|
|
|
461
624
|
- Check N-API version when module is loaded
|
|
462
625
|
- Optimize callback unregistration
|
|
463
626
|
|
|
464
|
-
#### Koffi 2.2.1
|
|
627
|
+
#### Koffi 2.2.1
|
|
628
|
+
|
|
629
|
+
*Released on 2022-12-21*
|
|
465
630
|
|
|
466
631
|
- Fix crash when [calling callback again after FFI call inside previous callback](https://github.com/Koromix/rygel/issues/15)
|
|
467
632
|
|
|
468
|
-
#### Koffi 2.2.0
|
|
633
|
+
#### Koffi 2.2.0
|
|
634
|
+
|
|
635
|
+
*Released on 2022-12-20*
|
|
469
636
|
|
|
470
637
|
**New features:**
|
|
471
638
|
|
|
@@ -481,11 +648,15 @@
|
|
|
481
648
|
|
|
482
649
|
### Koffi 2.1
|
|
483
650
|
|
|
484
|
-
#### Koffi 2.1.5
|
|
651
|
+
#### Koffi 2.1.5
|
|
652
|
+
|
|
653
|
+
*Released on 2022-11-27*
|
|
485
654
|
|
|
486
655
|
- Add missing README file to NPM package
|
|
487
656
|
|
|
488
|
-
#### Koffi 2.1.4
|
|
657
|
+
#### Koffi 2.1.4
|
|
658
|
+
|
|
659
|
+
*Released on 2022-11-25*
|
|
489
660
|
|
|
490
661
|
**Main changes:**
|
|
491
662
|
|
|
@@ -494,21 +665,29 @@
|
|
|
494
665
|
|
|
495
666
|
**Other changes:**
|
|
496
667
|
|
|
497
|
-
- Moved Koffi to a new repository: https://
|
|
668
|
+
- Moved Koffi to a new repository: https://codeberg.org/Koromix/rygel/
|
|
498
669
|
|
|
499
|
-
#### Koffi 2.1.3
|
|
670
|
+
#### Koffi 2.1.3
|
|
671
|
+
|
|
672
|
+
*Released on 2022-10-31*
|
|
500
673
|
|
|
501
674
|
- Support up to 16 output parameters (instead of 8)
|
|
502
675
|
|
|
503
|
-
#### Koffi 2.1.2
|
|
676
|
+
#### Koffi 2.1.2
|
|
677
|
+
|
|
678
|
+
*Released on 2022-10-31*
|
|
504
679
|
|
|
505
680
|
- Support up to 8 output parameters (instead of 4)
|
|
506
681
|
|
|
507
|
-
#### Koffi 2.1.1
|
|
682
|
+
#### Koffi 2.1.1
|
|
683
|
+
|
|
684
|
+
*Released on 2022-08-16*
|
|
508
685
|
|
|
509
686
|
- Fix potential memory allocation bugs
|
|
510
687
|
|
|
511
|
-
#### Koffi 2.1.0
|
|
688
|
+
#### Koffi 2.1.0
|
|
689
|
+
|
|
690
|
+
*Released on 2022-08-13*
|
|
512
691
|
|
|
513
692
|
**Main changes:**
|
|
514
693
|
|
|
@@ -528,11 +707,15 @@
|
|
|
528
707
|
|
|
529
708
|
### Koffi 2.0
|
|
530
709
|
|
|
531
|
-
#### Koffi 2.0.1
|
|
710
|
+
#### Koffi 2.0.1
|
|
711
|
+
|
|
712
|
+
*Released on 2022-07-30*
|
|
532
713
|
|
|
533
714
|
- Return `undefined` (instead of null) for `void` functions
|
|
534
715
|
|
|
535
|
-
#### Koffi 2.0.0
|
|
716
|
+
#### Koffi 2.0.0
|
|
717
|
+
|
|
718
|
+
*Released on 2022-07-29*
|
|
536
719
|
|
|
537
720
|
**Major new features:**
|
|
538
721
|
|
|
@@ -560,15 +743,21 @@ Consult the [migration guide](migration) for more information.
|
|
|
560
743
|
|
|
561
744
|
### Koffi 1.3
|
|
562
745
|
|
|
563
|
-
#### Koffi 1.3.12
|
|
746
|
+
#### Koffi 1.3.12
|
|
747
|
+
|
|
748
|
+
*Released on 2022-07-27*
|
|
564
749
|
|
|
565
750
|
- Fix support for Yarn package manager
|
|
566
751
|
|
|
567
|
-
#### Koffi 1.3.11
|
|
752
|
+
#### Koffi 1.3.11
|
|
753
|
+
|
|
754
|
+
*Released on 2022-07-26*
|
|
568
755
|
|
|
569
756
|
- Fix broken parsing of `void *` when used for first parameter
|
|
570
757
|
|
|
571
|
-
#### Koffi 1.3.10
|
|
758
|
+
#### Koffi 1.3.10
|
|
759
|
+
|
|
760
|
+
*Released on 2022-07-25*
|
|
572
761
|
|
|
573
762
|
**Main fixes:**
|
|
574
763
|
|
|
@@ -580,11 +769,15 @@ Consult the [migration guide](migration) for more information.
|
|
|
580
769
|
|
|
581
770
|
- Various documentation fixes and improvements
|
|
582
771
|
|
|
583
|
-
#### Koffi 1.3.9
|
|
772
|
+
#### Koffi 1.3.9
|
|
773
|
+
|
|
774
|
+
*Released on 2022-07-15*
|
|
584
775
|
|
|
585
776
|
- Fix prebuild compatibility with Electron on Windows x64
|
|
586
777
|
|
|
587
|
-
#### Koffi 1.3.8
|
|
778
|
+
#### Koffi 1.3.8
|
|
779
|
+
|
|
780
|
+
*Released on 2022-07-12*
|
|
588
781
|
|
|
589
782
|
**Main changes:**
|
|
590
783
|
|
|
@@ -595,7 +788,9 @@ Consult the [migration guide](migration) for more information.
|
|
|
595
788
|
|
|
596
789
|
- Fix and harmonize a few error messages
|
|
597
790
|
|
|
598
|
-
#### Koffi 1.3.7
|
|
791
|
+
#### Koffi 1.3.7
|
|
792
|
+
|
|
793
|
+
*Released on 2022-07-07*
|
|
599
794
|
|
|
600
795
|
**Main fixes:**
|
|
601
796
|
|
|
@@ -608,7 +803,9 @@ Consult the [migration guide](migration) for more information.
|
|
|
608
803
|
- Add str/str16 type aliases for string/string16
|
|
609
804
|
- Various documentation fixes and improvements
|
|
610
805
|
|
|
611
|
-
#### Koffi 1.3.6
|
|
806
|
+
#### Koffi 1.3.6
|
|
807
|
+
|
|
808
|
+
*Released on 2022-07-01*
|
|
612
809
|
|
|
613
810
|
**Main fixes:**
|
|
614
811
|
|
|
@@ -620,7 +817,9 @@ Consult the [migration guide](migration) for more information.
|
|
|
620
817
|
- Prebuild with Clang for Windows x64 and Linux x64 binaries
|
|
621
818
|
- Various documentation improvements
|
|
622
819
|
|
|
623
|
-
#### Koffi 1.3.5
|
|
820
|
+
#### Koffi 1.3.5
|
|
821
|
+
|
|
822
|
+
*Released on 2022-06-25*
|
|
624
823
|
|
|
625
824
|
**Main changes:**
|
|
626
825
|
|
|
@@ -632,11 +831,15 @@ Consult the [migration guide](migration) for more information.
|
|
|
632
831
|
- Reduce default async memory stack and heap size
|
|
633
832
|
- Various documentation improvements
|
|
634
833
|
|
|
635
|
-
#### Koffi 1.3.4
|
|
834
|
+
#### Koffi 1.3.4
|
|
835
|
+
|
|
836
|
+
*Released on 2022-06-24*
|
|
636
837
|
|
|
637
838
|
- Fix possible OpenBSD i386 crash with `(void)` functions
|
|
638
839
|
|
|
639
|
-
#### Koffi 1.3.3
|
|
840
|
+
#### Koffi 1.3.3
|
|
841
|
+
|
|
842
|
+
*Released on 2022-06-24*
|
|
640
843
|
|
|
641
844
|
**Main fixes:**
|
|
642
845
|
|
|
@@ -648,16 +851,22 @@ Consult the [migration guide](migration) for more information.
|
|
|
648
851
|
- Disable unsafe compiler optimizations
|
|
649
852
|
- Various documentation improvements
|
|
650
853
|
|
|
651
|
-
#### Koffi 1.3.2
|
|
854
|
+
#### Koffi 1.3.2
|
|
855
|
+
|
|
856
|
+
*Released on 2022-06-23*
|
|
652
857
|
|
|
653
858
|
- Support compilation in C++14 mode (graceful degradation)
|
|
654
859
|
- Support older toolchains on Linux (tested on Debian 9)
|
|
655
860
|
|
|
656
|
-
#### Koffi 1.3.1
|
|
861
|
+
#### Koffi 1.3.1
|
|
862
|
+
|
|
863
|
+
*Released on 2022-06-22*
|
|
657
864
|
|
|
658
865
|
- The prebuilt binary is tested when Koffi is installed, and a rebuild happens if it fails to load
|
|
659
866
|
|
|
660
|
-
#### Koffi 1.3.0
|
|
867
|
+
#### Koffi 1.3.0
|
|
868
|
+
|
|
869
|
+
*Released on 2022-06-22*
|
|
661
870
|
|
|
662
871
|
**Major changes:**
|
|
663
872
|
|
|
@@ -675,15 +884,21 @@ Consult the [migration guide](migration) for more information.
|
|
|
675
884
|
|
|
676
885
|
### Koffi 1.2
|
|
677
886
|
|
|
678
|
-
#### Koffi 1.2.4
|
|
887
|
+
#### Koffi 1.2.4
|
|
888
|
+
|
|
889
|
+
*Released on 2022-06-12*
|
|
679
890
|
|
|
680
891
|
- Windows ARM64 is now supported
|
|
681
892
|
|
|
682
|
-
#### Koffi 1.2.3
|
|
893
|
+
#### Koffi 1.2.3
|
|
894
|
+
|
|
895
|
+
*Released on 2022-06-11*
|
|
683
896
|
|
|
684
897
|
- A prebuilt binary for macOS ARM64 (M1) is now included
|
|
685
898
|
|
|
686
|
-
#### Koffi 1.2.1
|
|
899
|
+
#### Koffi 1.2.1
|
|
900
|
+
|
|
901
|
+
*Released on 2022-06-11*
|
|
687
902
|
|
|
688
903
|
This entry documents changes since version 1.1.0.
|
|
689
904
|
|