lancelot 0.3.4 → 0.4.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.
- checksums.yaml +4 -4
- data/Rakefile +39 -6
- data/ext/lancelot/Cargo.lock +5625 -0
- data/ext/lancelot/Cargo.toml +8 -8
- data/ext/lancelot/src/conversion.rs +49 -44
- data/ext/lancelot/src/dataset.rs +120 -107
- data/ext/lancelot/src/lib.rs +5 -5
- data/ext/lancelot/src/schema.rs +10 -12
- data/lib/lancelot/version.rb +1 -1
- data/lib/lancelot.rb +14 -1
- metadata +4 -6
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d6f3e8538cc95fc2db6e6f5968998c67b367c7c6c840303d51362494e90feb7f
|
|
4
|
+
data.tar.gz: 44152d9aa613f53f2eaa945fa480a9b7116bdd4dd39cbecfe7a134fefcbd81ca
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8078f10a7b8b06de136461476cd81daa989b974e784f0685abf022f9e0ef10997debc4dd76bfbf23d80f22146295920ae27fbcada3322675f104bdbefcf94afc
|
|
7
|
+
data.tar.gz: 0de47573553ccebcf27abf111f884092695f22b52d94a36d0f7a422d0df6c9d992e2ae69a55a93f8e3a4fe40cfed2a7468a769a585274b00efeb2c0fea5229af
|
data/Rakefile
CHANGED
|
@@ -1,20 +1,53 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
require "bundler/gem_tasks"
|
|
4
|
-
require "
|
|
5
|
-
|
|
6
|
-
RSpec::Core::RakeTask.new(:spec)
|
|
4
|
+
require "rake/extensiontask"
|
|
7
5
|
|
|
8
|
-
|
|
6
|
+
# Dev-only tooling (rspec, standard) is absent from the precompiled-gem build
|
|
7
|
+
# environment (the cross-gem container and the `gem build` step install only the
|
|
8
|
+
# runtime deps). Guard each require so loading the Rakefile to drive `native:<plat>`
|
|
9
|
+
# / `compile` never explodes on a missing development gem. The tasks they define are
|
|
10
|
+
# only registered when the gem is present.
|
|
11
|
+
begin
|
|
12
|
+
require "rspec/core/rake_task"
|
|
13
|
+
RSpec::Core::RakeTask.new(:spec)
|
|
14
|
+
rescue LoadError
|
|
15
|
+
# rspec unavailable (e.g. precompiled-gem build) -> skip the :spec task.
|
|
16
|
+
end
|
|
9
17
|
|
|
10
|
-
|
|
18
|
+
begin
|
|
19
|
+
require "standard/rake"
|
|
20
|
+
rescue LoadError
|
|
21
|
+
# standard unavailable -> skip its rake tasks.
|
|
22
|
+
end
|
|
11
23
|
|
|
12
24
|
task build: :compile
|
|
13
25
|
|
|
26
|
+
# Load the gemspec ONCE and hand it to Rake::ExtensionTask so that, in addition to
|
|
27
|
+
# the plain `compile` task, rake-compiler generates the per-platform `native:<plat>`
|
|
28
|
+
# tasks the precompiled-gem release pipeline drives (e.g. native:x86_64-linux).
|
|
14
29
|
GEMSPEC = Gem::Specification.load("lancelot.gemspec")
|
|
15
30
|
|
|
16
31
|
Rake::ExtensionTask.new("lancelot", GEMSPEC) do |ext|
|
|
17
32
|
ext.lib_dir = "lib/lancelot"
|
|
33
|
+
# Enable cross-compilation so `rake native:<platform>` exists for every platform
|
|
34
|
+
# the release matrix builds. The linux legs run inside rb-sys-dock; arm64-darwin
|
|
35
|
+
# builds natively on an Apple-Silicon runner.
|
|
36
|
+
ext.cross_compile = true
|
|
37
|
+
ext.cross_platform = %w[
|
|
38
|
+
x86_64-linux
|
|
39
|
+
aarch64-linux
|
|
40
|
+
arm64-darwin
|
|
41
|
+
]
|
|
18
42
|
end
|
|
19
43
|
|
|
20
|
-
task
|
|
44
|
+
# Default task: only depend on tasks that always exist. `spec`/`standard` are
|
|
45
|
+
# conditionally defined above, so reference them lazily to avoid a hard failure
|
|
46
|
+
# when the dev gems are absent.
|
|
47
|
+
desc "Compile, then run specs and the linter when available"
|
|
48
|
+
task :default do
|
|
49
|
+
Rake::Task["clobber"].invoke
|
|
50
|
+
Rake::Task["compile"].invoke
|
|
51
|
+
Rake::Task["spec"].invoke if Rake::Task.task_defined?("spec")
|
|
52
|
+
Rake::Task["standard"].invoke if Rake::Task.task_defined?("standard")
|
|
53
|
+
end
|