rb_sys 0.9.36 → 0.9.37
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.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +1 -1
- data/lib/rb_sys/mkmf.rb +18 -5
- data/lib/rb_sys/version.rb +1 -1
- data.tar.gz.sig +0 -0
- metadata +3 -3
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 48d0c6470452d832b1a10ac1aa49228a2185a36de7c551a6e97dd2f04490dfeb
|
|
4
|
+
data.tar.gz: 1d97ff8351afaff9adad083b07647f5ee6964329b7b224b99ec99640d5908f57
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b2da23aee398cb88673aa7d392999f054a6b76d307e9a564d41f3fd7ab86b5fe7e71ec69e91875a7c1aa09b7e358383c36affd52e722cdb79a1e5529eca66a89
|
|
7
|
+
data.tar.gz: 94d67086625a8e8fd4f99f987b050f547ad4f540995cf77624593a48c7344664c3cc5200c3fe6ed145ee684e4e863f1bdeb552a82a14af0fc11f4be701a7b109
|
checksums.yaml.gz.sig
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
g���3#5�㾭$q��v:�e�gE�BЗ��I���������1ľ}�SB{>��|��@�@0��d�HR[Ɖ��[�#cgT�C(�l��:��9]�����[��Q�'Α��S�Z_��0;��v���5��(1֣�q�f�K�h�":�8�n��Q���||H7v^-�O��g��ޗ��ap��r�Hp5f����)X��yr
|
data/lib/rb_sys/mkmf.rb
CHANGED
|
@@ -10,6 +10,8 @@ require_relative "mkmf/config"
|
|
|
10
10
|
module RbSys
|
|
11
11
|
# Helper class for creating Rust Makefiles
|
|
12
12
|
module Mkmf
|
|
13
|
+
GLOBAL_RUSTFLAGS = ["--cfg=rb_sys_gem"]
|
|
14
|
+
|
|
13
15
|
# Helper for building Rust extensions by creating a Ruby compatible makefile
|
|
14
16
|
# for Rust. By using this class, your rust extension will be 100% compatible
|
|
15
17
|
# with the rake-compiler gem, which allows for easy cross compilation.
|
|
@@ -62,6 +64,7 @@ module RbSys
|
|
|
62
64
|
|
|
63
65
|
#{conditional_assign("RB_SYS_CARGO_PROFILE", builder.profile)}
|
|
64
66
|
#{conditional_assign("RB_SYS_CARGO_FEATURES", builder.features.join(","))}
|
|
67
|
+
#{conditional_assign("RB_SYS_GLOBAL_RUSTFLAGS", GLOBAL_RUSTFLAGS.join(" "))}
|
|
65
68
|
#{conditional_assign("RB_SYS_EXTRA_RUSTFLAGS", builder.extra_rustflags.join(" "))}
|
|
66
69
|
|
|
67
70
|
# Set dirname for the profile, since the profiles do not directly map to target dir (i.e. dev -> debug)
|
|
@@ -105,7 +108,7 @@ module RbSys
|
|
|
105
108
|
#{endif_stmt}
|
|
106
109
|
|
|
107
110
|
#{env_vars(builder)}
|
|
108
|
-
#{export_env("RUSTFLAGS", "$(
|
|
111
|
+
#{export_env("RUSTFLAGS", "$(RB_SYS_GLOBAL_RUSTFLAGS) $(RB_SYS_EXTRA_RUSTFLAGS) $(RUSTFLAGS)")}
|
|
109
112
|
|
|
110
113
|
FORCE: ;
|
|
111
114
|
|
|
@@ -113,13 +116,11 @@ module RbSys
|
|
|
113
116
|
\t$(ECHO) creating target directory \\($(@)\\)
|
|
114
117
|
\t$(Q) $(MAKEDIRS) $(TARGET_DIR)
|
|
115
118
|
|
|
116
|
-
|
|
117
|
-
\t$(ECHO) generating $(@)
|
|
118
|
-
\t$(Q) ($(COPY) $(srcdir)/$(TARGET).def $@ 2> /dev/null) || (echo EXPORTS && echo $(TARGET_ENTRY)) > $@
|
|
119
|
+
#{deffile_definition}
|
|
119
120
|
|
|
120
121
|
#{optional_rust_toolchain(builder)}
|
|
121
122
|
|
|
122
|
-
$(RUSTLIB): $(DEFFILE) FORCE
|
|
123
|
+
$(RUSTLIB): #{deffile_definition ? "$(DEFFILE) " : nil}FORCE
|
|
123
124
|
\t$(ECHO) generating $(@) \\("$(RB_SYS_CARGO_PROFILE)"\\)
|
|
124
125
|
\t$(Q) #{full_cargo_command}
|
|
125
126
|
|
|
@@ -185,6 +186,18 @@ module RbSys
|
|
|
185
186
|
cargo_command
|
|
186
187
|
end
|
|
187
188
|
|
|
189
|
+
def deffile_definition
|
|
190
|
+
warn("EXPORT_PREFIX is not defined, please require \"mkmf\" before requiring \"rb_sys/mkmf\"") unless defined?(EXPORT_PREFIX)
|
|
191
|
+
|
|
192
|
+
return unless defined?(EXPORT_PREFIX) && EXPORT_PREFIX
|
|
193
|
+
|
|
194
|
+
@deffile_definition ||= <<~MAKE
|
|
195
|
+
$(DEFFILE): $(TARGET_DIR)
|
|
196
|
+
\t$(ECHO) generating $(@)
|
|
197
|
+
\t$(Q) ($(COPY) $(srcdir)/$(TARGET).def $@ 2> /dev/null) || (echo EXPORTS && echo $(TARGET_ENTRY)) > $@
|
|
198
|
+
MAKE
|
|
199
|
+
end
|
|
200
|
+
|
|
188
201
|
def optional_rust_toolchain(builder)
|
|
189
202
|
<<~MAKE
|
|
190
203
|
#{conditional_assign("RB_SYS_FORCE_INSTALL_RUST_TOOLCHAIN", builder.force_install_rust_toolchain)}
|
data/lib/rb_sys/version.rb
CHANGED
data.tar.gz.sig
CHANGED
|
Binary file
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rb_sys
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.9.
|
|
4
|
+
version: 0.9.37
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ian Ker-Seymer
|
|
@@ -30,7 +30,7 @@ cert_chain:
|
|
|
30
30
|
Rl+ASkq2/1i07TkBpCf+2hq66+h/hx+/Y/KrUzXfe0jtvil0WESkJT2kqRqHWNhD
|
|
31
31
|
9GKBxaQlXokNDtWCm1/gl6cD8WRZ0N5S4ZGJT1FLLsA=
|
|
32
32
|
-----END CERTIFICATE-----
|
|
33
|
-
date: 2022-11-
|
|
33
|
+
date: 2022-11-07 00:00:00.000000000 Z
|
|
34
34
|
dependencies: []
|
|
35
35
|
description:
|
|
36
36
|
email:
|
|
@@ -72,7 +72,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
72
72
|
- !ruby/object:Gem::Version
|
|
73
73
|
version: '0'
|
|
74
74
|
requirements: []
|
|
75
|
-
rubygems_version: 3.
|
|
75
|
+
rubygems_version: 3.4.0.dev
|
|
76
76
|
signing_key:
|
|
77
77
|
specification_version: 4
|
|
78
78
|
summary: Helpers for compiling Rust extensions for ruby
|
metadata.gz.sig
CHANGED
|
Binary file
|