serde 0.0.4 → 0.0.5
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
- data/.gitignore +1 -1
- data/lib/rustc_installer.rb +6 -2
- data/lib/serde.rb +2 -2
- data/serde.gemspec +1 -1
- metadata +1 -2
- data/bin/.keep +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b9a20ecd160bb069728abdb182b0c30cc350e3ea34086619d3cb25d203756fe5
|
|
4
|
+
data.tar.gz: 662cf714c4d34b64f7f5e48ab7e9c9cd48e3f5bae4e9848c38c95cacdc9b85d0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0ea50d8d7ce45cfd829f52c601a07cd8f0a1fa739bcd9c0306214d5842679345f42dbb612e1b2216c8b06d80d958b3a6e6a1b4669b0146387bd8d052e98bc0a9
|
|
7
|
+
data.tar.gz: ae8c748c3615f615cab72b721610f3ee80eac07dbd94cb0031b705a379306a8ec9885a1cbe7df5e8cf31a6b596e94a978bd7766227e6bf06cf2ab02773f63441
|
data/.gitignore
CHANGED
data/lib/rustc_installer.rb
CHANGED
|
@@ -44,6 +44,8 @@ cputype =
|
|
|
44
44
|
|
|
45
45
|
rustc_name = "rustc-beta-#{cputype}-#{ostype}"
|
|
46
46
|
ruststd_name = "rust-std-beta-#{cputype}-#{ostype}"
|
|
47
|
+
cargo_name = "cargo-beta-#{cputype}-#{ostype}"
|
|
48
|
+
|
|
47
49
|
TAR_LONGLINK = '././@LongLink'
|
|
48
50
|
DESTINATION = File.expand_path('../.rustc', __dir__)
|
|
49
51
|
|
|
@@ -83,14 +85,16 @@ Dir.mktmpdir do |dir|
|
|
|
83
85
|
Dir.chdir(dir) do
|
|
84
86
|
# manifest = Net::HTTP.get(URI('https://static.rust-lang.org/dist/channel-rust-beta.toml'))
|
|
85
87
|
# puts manifest
|
|
88
|
+
FileUtils.rm(File.expand_path('../bin/cargo', __dir__)) rescue nil
|
|
86
89
|
|
|
87
90
|
download_and_extract(rustc_name)
|
|
88
91
|
download_and_extract(ruststd_name)
|
|
92
|
+
download_and_extract(cargo_name)
|
|
89
93
|
|
|
90
94
|
# TODO: windows?
|
|
91
95
|
FileUtils.ln_s(
|
|
92
|
-
"#{DESTINATION}/#{
|
|
93
|
-
File.expand_path('../bin/
|
|
96
|
+
"#{DESTINATION}/#{cargo_name}/cargo/bin/cargo",
|
|
97
|
+
File.expand_path('../bin/cargo', __dir__),
|
|
94
98
|
)
|
|
95
99
|
end
|
|
96
100
|
end
|
data/lib/serde.rb
CHANGED
|
@@ -39,8 +39,8 @@ module Serde
|
|
|
39
39
|
bin_path = File.expand_path('../bin', __dir__)
|
|
40
40
|
|
|
41
41
|
# rubocop:disable Metrics/LineLength
|
|
42
|
-
`
|
|
43
|
-
`cd #{rust_path}; #{bin_path}/
|
|
42
|
+
# `cd #{rust_path}; #{bin_path}/rustc --edition=2018 --crate-name serde_rb src/lib.rs --crate-type staticlib --crate-type cdylib --emit=dep-info,link -C opt-level=3 -C metadata=aff563bf4af79579 --out-dir #{rust_path}/target/release -L dependency=#{rust_path}/target/release/deps --extern serde=#{rust_path}/target/release/deps/libserde-6a9e4ab445963d7f.rlib --extern serde_derive=#{rust_path}/target/release/deps/libserde_derive-20596753c2ed9015.dylib --extern serde_json=#{rust_path}/target/release/deps/libserde_json-489658cb61f64325.rlib -L #{root_path}/.rustc/rust-std-beta-x86_64-apple-darwin/rust-std-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib`
|
|
43
|
+
`cd #{rust_path}; #{bin_path}/cargo build --release`
|
|
44
44
|
# rubocop:enable Metrics/LineLength
|
|
45
45
|
`cp #{rust_path}/target/release/libserde_rb*.a #{dir}/serde_rb/libserde_rb.a`
|
|
46
46
|
`cd #{dir}/serde_rb; ruby extconf.rb; make clean; make`
|
data/serde.gemspec
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: serde
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Alexander Komarov
|
|
@@ -108,7 +108,6 @@ files:
|
|
|
108
108
|
- README.md
|
|
109
109
|
- Rakefile
|
|
110
110
|
- bench/bench.rb
|
|
111
|
-
- bin/.keep
|
|
112
111
|
- examples/app/new.rb
|
|
113
112
|
- lib/rubygems_plugin.rb
|
|
114
113
|
- lib/rustc_installer.rb
|
data/bin/.keep
DELETED
|
File without changes
|