ffi 1.15.5-x64-mingw32 → 1.16.0-x64-mingw32
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +54 -0
- data/Gemfile +1 -1
- data/README.md +3 -2
- data/Rakefile +10 -7
- data/ffi.gemspec +2 -2
- data/lib/2.5/ffi_c.so +0 -0
- data/lib/2.6/ffi_c.so +0 -0
- data/lib/2.7/ffi_c.so +0 -0
- data/lib/3.0/ffi_c.so +0 -0
- data/lib/ffi/autopointer.rb +7 -22
- data/lib/ffi/compat.rb +43 -0
- data/lib/ffi/data_converter.rb +2 -2
- data/lib/ffi/dynamic_library.rb +89 -0
- data/lib/ffi/enum.rb +18 -11
- data/lib/ffi/ffi.rb +3 -0
- data/lib/ffi/function.rb +71 -0
- data/lib/ffi/library.rb +55 -71
- data/lib/ffi/library_path.rb +109 -0
- data/lib/ffi/managedstruct.rb +1 -1
- data/lib/ffi/platform/aarch64-windows/types.conf +52 -0
- data/lib/ffi/platform/hppa1.1-linux/types.conf +178 -0
- data/lib/ffi/platform/hppa2.0-linux/types.conf +178 -0
- data/lib/ffi/platform/loongarch64-linux/types.conf +141 -0
- data/lib/ffi/platform/sw_64-linux/types.conf +141 -0
- data/lib/ffi/platform.rb +15 -13
- data/lib/ffi/struct.rb +2 -1
- data/lib/ffi/struct_layout.rb +1 -1
- data/lib/ffi/struct_layout_builder.rb +1 -1
- data/lib/ffi/types.rb +30 -5
- data/lib/ffi/variadic.rb +19 -8
- data/lib/ffi/version.rb +1 -1
- metadata +20 -12
- data/lib/2.4/ffi_c.so +0 -0
- /data/lib/ffi/platform/{sparc64-linux → sparcv9-linux}/types.conf +0 -0
data/lib/ffi/variadic.rb
CHANGED
@@ -54,16 +54,27 @@ module FFI
|
|
54
54
|
invoker = self
|
55
55
|
params = "*args"
|
56
56
|
call = "call"
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
57
|
+
mname = mname.to_sym
|
58
|
+
mod.module_eval <<-code, __FILE__, __LINE__
|
59
|
+
@ffi_functions = {} unless defined?(@ffi_functions)
|
60
|
+
@ffi_functions[#{mname.inspect}] = invoker
|
61
|
+
|
62
|
+
def self.#{mname}(#{params})
|
63
|
+
@ffi_functions[#{mname.inspect}].#{call}(#{params})
|
64
|
+
end
|
65
|
+
|
66
|
+
define_method(#{mname.inspect}, &method(#{mname.inspect}))
|
65
67
|
code
|
66
68
|
invoker
|
67
69
|
end
|
70
|
+
|
71
|
+
# Retrieve Array of parameter types
|
72
|
+
#
|
73
|
+
# This method returns an Array of FFI types accepted as function parameters.
|
74
|
+
#
|
75
|
+
# @return [Array<FFI::Type>]
|
76
|
+
def param_types
|
77
|
+
[*@fixed, Type::Builtin::VARARGS]
|
78
|
+
end
|
68
79
|
end
|
69
80
|
end
|
data/lib/ffi/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ffi
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.16.0
|
5
5
|
platform: x64-mingw32
|
6
6
|
authors:
|
7
7
|
- Wayne Meissner
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-09-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -30,14 +30,14 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '1.
|
33
|
+
version: '1.1'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '1.
|
40
|
+
version: '1.1'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rake-compiler-dock
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -80,7 +80,6 @@ files:
|
|
80
80
|
- README.md
|
81
81
|
- Rakefile
|
82
82
|
- ffi.gemspec
|
83
|
-
- lib/2.4/ffi_c.so
|
84
83
|
- lib/2.5/ffi_c.so
|
85
84
|
- lib/2.6/ffi_c.so
|
86
85
|
- lib/2.7/ffi_c.so
|
@@ -90,12 +89,16 @@ files:
|
|
90
89
|
- lib/ffi/autopointer.rb
|
91
90
|
- lib/ffi/buffer.rb
|
92
91
|
- lib/ffi/callback.rb
|
92
|
+
- lib/ffi/compat.rb
|
93
93
|
- lib/ffi/data_converter.rb
|
94
|
+
- lib/ffi/dynamic_library.rb
|
94
95
|
- lib/ffi/enum.rb
|
95
96
|
- lib/ffi/errno.rb
|
96
97
|
- lib/ffi/ffi.rb
|
98
|
+
- lib/ffi/function.rb
|
97
99
|
- lib/ffi/io.rb
|
98
100
|
- lib/ffi/library.rb
|
101
|
+
- lib/ffi/library_path.rb
|
99
102
|
- lib/ffi/managedstruct.rb
|
100
103
|
- lib/ffi/memorypointer.rb
|
101
104
|
- lib/ffi/platform.rb
|
@@ -104,9 +107,12 @@ files:
|
|
104
107
|
- lib/ffi/platform/aarch64-freebsd12/types.conf
|
105
108
|
- lib/ffi/platform/aarch64-linux/types.conf
|
106
109
|
- lib/ffi/platform/aarch64-openbsd/types.conf
|
110
|
+
- lib/ffi/platform/aarch64-windows/types.conf
|
107
111
|
- lib/ffi/platform/arm-freebsd/types.conf
|
108
112
|
- lib/ffi/platform/arm-freebsd12/types.conf
|
109
113
|
- lib/ffi/platform/arm-linux/types.conf
|
114
|
+
- lib/ffi/platform/hppa1.1-linux/types.conf
|
115
|
+
- lib/ffi/platform/hppa2.0-linux/types.conf
|
110
116
|
- lib/ffi/platform/i386-cygwin/types.conf
|
111
117
|
- lib/ffi/platform/i386-darwin/types.conf
|
112
118
|
- lib/ffi/platform/i386-freebsd/types.conf
|
@@ -118,6 +124,7 @@ files:
|
|
118
124
|
- lib/ffi/platform/i386-solaris/types.conf
|
119
125
|
- lib/ffi/platform/i386-windows/types.conf
|
120
126
|
- lib/ffi/platform/ia64-linux/types.conf
|
127
|
+
- lib/ffi/platform/loongarch64-linux/types.conf
|
121
128
|
- lib/ffi/platform/mips-linux/types.conf
|
122
129
|
- lib/ffi/platform/mips64-linux/types.conf
|
123
130
|
- lib/ffi/platform/mips64el-linux/types.conf
|
@@ -137,9 +144,10 @@ files:
|
|
137
144
|
- lib/ffi/platform/s390x-linux/types.conf
|
138
145
|
- lib/ffi/platform/sparc-linux/types.conf
|
139
146
|
- lib/ffi/platform/sparc-solaris/types.conf
|
140
|
-
- lib/ffi/platform/
|
147
|
+
- lib/ffi/platform/sparcv9-linux/types.conf
|
141
148
|
- lib/ffi/platform/sparcv9-openbsd/types.conf
|
142
149
|
- lib/ffi/platform/sparcv9-solaris/types.conf
|
150
|
+
- lib/ffi/platform/sw_64-linux/types.conf
|
143
151
|
- lib/ffi/platform/x86_64-cygwin/types.conf
|
144
152
|
- lib/ffi/platform/x86_64-darwin/types.conf
|
145
153
|
- lib/ffi/platform/x86_64-dragonflybsd/types.conf
|
@@ -184,7 +192,7 @@ metadata:
|
|
184
192
|
wiki_uri: https://github.com/ffi/ffi/wiki
|
185
193
|
source_code_uri: https://github.com/ffi/ffi/
|
186
194
|
mailing_list_uri: http://groups.google.com/group/ruby-ffi
|
187
|
-
post_install_message:
|
195
|
+
post_install_message:
|
188
196
|
rdoc_options:
|
189
197
|
- "--exclude=ext/ffi_c/.*\\.o$"
|
190
198
|
- "--exclude=ffi_c\\.(bundle|so)$"
|
@@ -194,18 +202,18 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
194
202
|
requirements:
|
195
203
|
- - ">="
|
196
204
|
- !ruby/object:Gem::Version
|
197
|
-
version: '2.
|
205
|
+
version: '2.5'
|
198
206
|
- - "<"
|
199
207
|
- !ruby/object:Gem::Version
|
200
|
-
version: 3.
|
208
|
+
version: 3.1.dev
|
201
209
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
202
210
|
requirements:
|
203
211
|
- - ">="
|
204
212
|
- !ruby/object:Gem::Version
|
205
213
|
version: '0'
|
206
214
|
requirements: []
|
207
|
-
rubygems_version: 3.3.
|
208
|
-
signing_key:
|
215
|
+
rubygems_version: 3.3.26
|
216
|
+
signing_key:
|
209
217
|
specification_version: 4
|
210
218
|
summary: Ruby FFI
|
211
219
|
test_files: []
|
data/lib/2.4/ffi_c.so
DELETED
Binary file
|
File without changes
|