asterism-zenoh 0.1.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 +7 -0
- data/LICENSE +21 -0
- data/README.md +180 -0
- data/ZENOH_C_PIN +31 -0
- data/ext/asterism_zenoh/extconf.rb +98 -0
- data/ext/asterism_zenoh/zenoh.c +1553 -0
- data/ext/asterism_zenoh/zenoh_c.rb +175 -0
- data/lib/asterism/zenoh/global.rb +5 -0
- data/lib/asterism/zenoh/version.rb +6 -0
- data/lib/asterism/zenoh.rb +6 -0
- data/licenses/zenoh-c/LICENSE-APACHE +202 -0
- data/licenses/zenoh-c/NOTICE.md +40 -0
- metadata +62 -0
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
# Finds the prebuilt zenoh-c release for this machine, downloads it and
|
|
2
|
+
# checks it against ZENOH_C_PIN. Used by extconf.rb (at `gem install`) and by
|
|
3
|
+
# the Rakefile (`rake zenoh_c:fetch`). Standard library only: net/http for
|
|
4
|
+
# the download (redirects followed, proxies from the usual environment
|
|
5
|
+
# variables), zlib for the zip archive (no unzip, curl or git needed).
|
|
6
|
+
#
|
|
7
|
+
# Environment:
|
|
8
|
+
# ZENOH_C_DIR use this zenoh-c (include/ and lib/) instead
|
|
9
|
+
# ASTERISM_ZENOH_C_MIRROR download from this base instead of the GitHub
|
|
10
|
+
# releases: <base>/<tag>/<asset>. An http(s) or
|
|
11
|
+
# file:// URL, or a local directory.
|
|
12
|
+
require "digest"
|
|
13
|
+
require "fileutils"
|
|
14
|
+
require "net/http"
|
|
15
|
+
require "rbconfig"
|
|
16
|
+
require "tmpdir"
|
|
17
|
+
require "uri"
|
|
18
|
+
require "zlib"
|
|
19
|
+
|
|
20
|
+
module ZenohCFetch
|
|
21
|
+
class Error < StandardError; end
|
|
22
|
+
|
|
23
|
+
PIN_FILE = File.expand_path("../../ZENOH_C_PIN", __dir__)
|
|
24
|
+
MIRROR_ENV = "ASTERISM_ZENOH_C_MIRROR"
|
|
25
|
+
MAX_REDIRECTS = 10
|
|
26
|
+
|
|
27
|
+
module_function
|
|
28
|
+
|
|
29
|
+
def pin
|
|
30
|
+
@pin ||= File.readlines(PIN_FILE).each_with_object({}) do |l, h|
|
|
31
|
+
next if l.start_with?("#") || !l.include?(":")
|
|
32
|
+
k, v = l.split(":", 2)
|
|
33
|
+
h[k.strip] = v.strip
|
|
34
|
+
end
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# The pinned machines, as the keys of ZENOH_C_PIN (asset.<key>).
|
|
38
|
+
def supported
|
|
39
|
+
pin.keys.grep(/\Aasset\./).map { |k| k.delete_prefix("asset.") }
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
# The key of this machine in ZENOH_C_PIN, or nil when it is not known.
|
|
43
|
+
def platform_key(cpu = RbConfig::CONFIG["host_cpu"], os = RbConfig::CONFIG["host_os"])
|
|
44
|
+
arch = case cpu
|
|
45
|
+
when /\A(x86_64|amd64|x64)\z/ then "x86_64"
|
|
46
|
+
when /\A(aarch64|arm64)\z/ then "aarch64"
|
|
47
|
+
end
|
|
48
|
+
return nil unless arch
|
|
49
|
+
case os
|
|
50
|
+
when /linux-musl/ then "#{arch}-linux-musl"
|
|
51
|
+
when /linux/ then "#{arch}-linux"
|
|
52
|
+
when /darwin/ then "#{arch}-darwin"
|
|
53
|
+
end
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# The shared library's file name on this machine.
|
|
57
|
+
def lib_name(os = RbConfig::CONFIG["host_os"])
|
|
58
|
+
os =~ /darwin/ ? "libzenohc.dylib" : "libzenohc.so"
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
def help
|
|
62
|
+
"Point the build at a zenoh-c of your own (its include/ and lib/, release #{pin['tag']}):\n" \
|
|
63
|
+
" ZENOH_C_DIR=/path/to/zenoh-c gem install asterism-zenoh\n" \
|
|
64
|
+
" (or: gem install asterism-zenoh -- --with-zenoh-c-dir=/path/to/zenoh-c)\n" \
|
|
65
|
+
"Prebuilt zenoh-c releases: #{pin['repo']}/releases/tag/#{pin['tag']}\n" \
|
|
66
|
+
"To download from a mirror instead: #{MIRROR_ENV}=<base> (fetches <base>/#{pin['tag']}/<asset>)."
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
def url_for(asset)
|
|
70
|
+
base = ENV[MIRROR_ENV].to_s
|
|
71
|
+
base = "#{pin['repo']}/releases/download" if base.empty?
|
|
72
|
+
"#{base.chomp('/')}/#{pin['tag']}/#{asset}"
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
# Downloads the pinned release for `key`, checks its sha256 and unpacks
|
|
76
|
+
# include/ and the shared library into `dest`. Returns a description of
|
|
77
|
+
# what was fetched. Raises Error with a message for the user.
|
|
78
|
+
def fetch(dest, key = platform_key, log: $stdout)
|
|
79
|
+
unless key && pin["asset.#{key}"]
|
|
80
|
+
raise Error, "no prebuilt zenoh-c is pinned for this machine " \
|
|
81
|
+
"(#{RbConfig::CONFIG['host_cpu']}-#{RbConfig::CONFIG['host_os']}); " \
|
|
82
|
+
"pinned: #{supported.join(', ')}.\n#{help}"
|
|
83
|
+
end
|
|
84
|
+
asset = pin["asset.#{key}"]
|
|
85
|
+
sha = pin["sha256.#{key}"] or raise Error, "ZENOH_C_PIN has no sha256 for #{key}"
|
|
86
|
+
url = url_for(asset)
|
|
87
|
+
Dir.mktmpdir("zenoh-c") do |tmp|
|
|
88
|
+
zip = File.join(tmp, asset)
|
|
89
|
+
log&.puts "fetching zenoh-c #{pin['tag']} (#{key}): #{url}"
|
|
90
|
+
begin
|
|
91
|
+
download(url, zip)
|
|
92
|
+
rescue StandardError => e
|
|
93
|
+
raise Error, "cannot download #{url}: #{e.message} (#{e.class})\n#{help}"
|
|
94
|
+
end
|
|
95
|
+
got = Digest::SHA256.file(zip).hexdigest
|
|
96
|
+
unless got == sha
|
|
97
|
+
raise Error, "sha256 mismatch for #{asset}: got #{got}, pinned #{sha} (ZENOH_C_PIN). " \
|
|
98
|
+
"Not using it.\n#{help}"
|
|
99
|
+
end
|
|
100
|
+
log&.puts "sha256 #{got} OK"
|
|
101
|
+
FileUtils.rm_rf(dest)
|
|
102
|
+
unzip(zip, dest) { |name| name.start_with?("include/") || name == "lib/#{lib_name}" }
|
|
103
|
+
end
|
|
104
|
+
%w[include/zenoh.h].push("lib/#{lib_name}").each do |f|
|
|
105
|
+
raise Error, "the archive #{asset} has no #{f}" unless File.file?(File.join(dest, f))
|
|
106
|
+
end
|
|
107
|
+
{ "tag" => pin["tag"], "platform" => key, "asset" => asset, "sha256" => sha, "url" => url }
|
|
108
|
+
end
|
|
109
|
+
|
|
110
|
+
def download(url, path, redirects = MAX_REDIRECTS)
|
|
111
|
+
uri = URI(url)
|
|
112
|
+
if uri.scheme.nil? || uri.scheme == "file"
|
|
113
|
+
src = uri.scheme ? URI.decode_www_form_component(uri.path) : url
|
|
114
|
+
raise Error, "no such file: #{src}" unless File.file?(src)
|
|
115
|
+
return FileUtils.cp(src, path)
|
|
116
|
+
end
|
|
117
|
+
raise Error, "unsupported URL scheme: #{uri.scheme}" unless %w[http https].include?(uri.scheme)
|
|
118
|
+
Net::HTTP.start(uri.host, uri.port, use_ssl: uri.scheme == "https",
|
|
119
|
+
open_timeout: 30, read_timeout: 120) do |http|
|
|
120
|
+
http.request_get(uri.request_uri) do |res|
|
|
121
|
+
case res
|
|
122
|
+
when Net::HTTPRedirection
|
|
123
|
+
raise Error, "too many redirects" if redirects <= 0
|
|
124
|
+
loc = res["location"] or raise Error, "redirect without a location"
|
|
125
|
+
return download(URI.join(url, loc).to_s, path, redirects - 1)
|
|
126
|
+
when Net::HTTPSuccess
|
|
127
|
+
File.open(path, "wb") { |f| res.read_body { |chunk| f.write(chunk) } }
|
|
128
|
+
else
|
|
129
|
+
raise Error, "HTTP #{res.code} #{res.message}"
|
|
130
|
+
end
|
|
131
|
+
end
|
|
132
|
+
end
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# Extracts the entries for which the block is true. Reads the central
|
|
136
|
+
# directory; stored and deflated entries; checks each entry's CRC-32.
|
|
137
|
+
def unzip(zip, dest)
|
|
138
|
+
File.open(zip, "rb") do |f|
|
|
139
|
+
size = f.size
|
|
140
|
+
tail = [size, 65_557].min
|
|
141
|
+
f.seek(size - tail)
|
|
142
|
+
buf = f.read(tail)
|
|
143
|
+
eocd = buf.rindex("PK\x05\x06".b) or raise Error, "not a zip archive: #{zip}"
|
|
144
|
+
count, cd_size, cd_off = buf[eocd + 10, 10].unpack("vVV")
|
|
145
|
+
raise Error, "zip64 archives are not supported" if cd_off == 0xFFFFFFFF
|
|
146
|
+
f.seek(cd_off)
|
|
147
|
+
cd = f.read(cd_size)
|
|
148
|
+
pos = 0
|
|
149
|
+
count.times do
|
|
150
|
+
raise Error, "bad zip central directory" unless cd[pos, 4] == "PK\x01\x02".b
|
|
151
|
+
method, _t, _d, crc, csize, usize, nlen, elen, clen = cd[pos + 10, 24].unpack("vvvVVVvvv")
|
|
152
|
+
local = cd[pos + 42, 4].unpack1("V")
|
|
153
|
+
name = cd[pos + 46, nlen]
|
|
154
|
+
pos += 46 + nlen + elen + clen
|
|
155
|
+
next if name.end_with?("/") || !yield(name)
|
|
156
|
+
raise Error, "unsafe path in zip: #{name}" if name.start_with?("/") || name.split("/").include?("..")
|
|
157
|
+
f.seek(local)
|
|
158
|
+
lh = f.read(30)
|
|
159
|
+
raise Error, "bad zip local header: #{name}" unless lh[0, 4] == "PK\x03\x04".b
|
|
160
|
+
f.seek(local + 30 + lh[26, 2].unpack1("v") + lh[28, 2].unpack1("v"))
|
|
161
|
+
data = f.read(csize)
|
|
162
|
+
data = case method
|
|
163
|
+
when 0 then data
|
|
164
|
+
when 8 then Zlib::Inflate.new(-Zlib::MAX_WBITS).inflate(data)
|
|
165
|
+
else raise Error, "zip entry #{name}: compression method #{method} is not supported"
|
|
166
|
+
end
|
|
167
|
+
raise Error, "zip entry #{name}: size mismatch" unless data.bytesize == usize
|
|
168
|
+
raise Error, "zip entry #{name}: CRC mismatch" unless Zlib.crc32(data) == crc
|
|
169
|
+
out = File.join(dest, name)
|
|
170
|
+
FileUtils.mkdir_p(File.dirname(out))
|
|
171
|
+
File.binwrite(out, data)
|
|
172
|
+
end
|
|
173
|
+
end
|
|
174
|
+
end
|
|
175
|
+
end
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
# Asterism::Zenoh for CRuby: the Zenoh binding of Asterism, over zenoh-c.
|
|
2
|
+
# The same Ruby API as the mruby / PicoRuby gem (picoruby-asterism-zenoh):
|
|
3
|
+
# see README.md. Receiving is polled (each_pending / each_reply) from the
|
|
4
|
+
# application's own thread; nothing calls into Ruby behind its back.
|
|
5
|
+
require_relative "zenoh/version"
|
|
6
|
+
require_relative "asterism_zenoh"
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
|
|
2
|
+
Apache License
|
|
3
|
+
Version 2.0, January 2004
|
|
4
|
+
http://www.apache.org/licenses/
|
|
5
|
+
|
|
6
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
7
|
+
|
|
8
|
+
1. Definitions.
|
|
9
|
+
|
|
10
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
11
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
|
+
|
|
13
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
14
|
+
the copyright owner that is granting the License.
|
|
15
|
+
|
|
16
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
17
|
+
other entities that control, are controlled by, or are under common
|
|
18
|
+
control with that entity. For the purposes of this definition,
|
|
19
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
20
|
+
direction or management of such entity, whether by contract or
|
|
21
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
22
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
23
|
+
|
|
24
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
25
|
+
exercising permissions granted by this License.
|
|
26
|
+
|
|
27
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
28
|
+
including but not limited to software source code, documentation
|
|
29
|
+
source, and configuration files.
|
|
30
|
+
|
|
31
|
+
"Object" form shall mean any form resulting from mechanical
|
|
32
|
+
transformation or translation of a Source form, including but
|
|
33
|
+
not limited to compiled object code, generated documentation,
|
|
34
|
+
and conversions to other media types.
|
|
35
|
+
|
|
36
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
37
|
+
Object form, made available under the License, as indicated by a
|
|
38
|
+
copyright notice that is included in or attached to the work
|
|
39
|
+
(an example is provided in the Appendix below).
|
|
40
|
+
|
|
41
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
42
|
+
form, that is based on (or derived from) the Work and for which the
|
|
43
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
44
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
45
|
+
of this License, Derivative Works shall not include works that remain
|
|
46
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
47
|
+
the Work and Derivative Works thereof.
|
|
48
|
+
|
|
49
|
+
"Contribution" shall mean any work of authorship, including
|
|
50
|
+
the original version of the Work and any modifications or additions
|
|
51
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
52
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
53
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
54
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
55
|
+
means any form of electronic, verbal, or written communication sent
|
|
56
|
+
to the Licensor or its representatives, including but not limited to
|
|
57
|
+
communication on electronic mailing lists, source code control systems,
|
|
58
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
59
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
60
|
+
excluding communication that is conspicuously marked or otherwise
|
|
61
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
62
|
+
|
|
63
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
64
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
65
|
+
subsequently incorporated within the Work.
|
|
66
|
+
|
|
67
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
68
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
69
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
70
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
71
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
72
|
+
Work and such Derivative Works in Source or Object form.
|
|
73
|
+
|
|
74
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
75
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
76
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
77
|
+
(except as stated in this section) patent license to make, have made,
|
|
78
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
79
|
+
where such license applies only to those patent claims licensable
|
|
80
|
+
by such Contributor that are necessarily infringed by their
|
|
81
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
82
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
83
|
+
institute patent litigation against any entity (including a
|
|
84
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
85
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
86
|
+
or contributory patent infringement, then any patent licenses
|
|
87
|
+
granted to You under this License for that Work shall terminate
|
|
88
|
+
as of the date such litigation is filed.
|
|
89
|
+
|
|
90
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
91
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
92
|
+
modifications, and in Source or Object form, provided that You
|
|
93
|
+
meet the following conditions:
|
|
94
|
+
|
|
95
|
+
(a) You must give any other recipients of the Work or
|
|
96
|
+
Derivative Works a copy of this License; and
|
|
97
|
+
|
|
98
|
+
(b) You must cause any modified files to carry prominent notices
|
|
99
|
+
stating that You changed the files; and
|
|
100
|
+
|
|
101
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
102
|
+
that You distribute, all copyright, patent, trademark, and
|
|
103
|
+
attribution notices from the Source form of the Work,
|
|
104
|
+
excluding those notices that do not pertain to any part of
|
|
105
|
+
the Derivative Works; and
|
|
106
|
+
|
|
107
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
108
|
+
distribution, then any Derivative Works that You distribute must
|
|
109
|
+
include a readable copy of the attribution notices contained
|
|
110
|
+
within such NOTICE file, excluding those notices that do not
|
|
111
|
+
pertain to any part of the Derivative Works, in at least one
|
|
112
|
+
of the following places: within a NOTICE text file distributed
|
|
113
|
+
as part of the Derivative Works; within the Source form or
|
|
114
|
+
documentation, if provided along with the Derivative Works; or,
|
|
115
|
+
within a display generated by the Derivative Works, if and
|
|
116
|
+
wherever such third-party notices normally appear. The contents
|
|
117
|
+
of the NOTICE file are for informational purposes only and
|
|
118
|
+
do not modify the License. You may add Your own attribution
|
|
119
|
+
notices within Derivative Works that You distribute, alongside
|
|
120
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
121
|
+
that such additional attribution notices cannot be construed
|
|
122
|
+
as modifying the License.
|
|
123
|
+
|
|
124
|
+
You may add Your own copyright statement to Your modifications and
|
|
125
|
+
may provide additional or different license terms and conditions
|
|
126
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
127
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
128
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
129
|
+
the conditions stated in this License.
|
|
130
|
+
|
|
131
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
132
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
133
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
134
|
+
this License, without any additional terms or conditions.
|
|
135
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
136
|
+
the terms of any separate license agreement you may have executed
|
|
137
|
+
with Licensor regarding such Contributions.
|
|
138
|
+
|
|
139
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
140
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
141
|
+
except as required for reasonable and customary use in describing the
|
|
142
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
143
|
+
|
|
144
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
145
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
146
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
147
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
148
|
+
implied, including, without limitation, any warranties or conditions
|
|
149
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
150
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
151
|
+
appropriateness of using or redistributing the Work and assume any
|
|
152
|
+
risks associated with Your exercise of permissions under this License.
|
|
153
|
+
|
|
154
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
155
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
156
|
+
unless required by applicable law (such as deliberate and grossly
|
|
157
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
158
|
+
liable to You for damages, including any direct, indirect, special,
|
|
159
|
+
incidental, or consequential damages of any character arising as a
|
|
160
|
+
result of this License or out of the use or inability to use the
|
|
161
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
162
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
163
|
+
other commercial damages or losses), even if such Contributor
|
|
164
|
+
has been advised of the possibility of such damages.
|
|
165
|
+
|
|
166
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
167
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
168
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
169
|
+
or other liability obligations and/or rights consistent with this
|
|
170
|
+
License. However, in accepting such obligations, You may act only
|
|
171
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
172
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
173
|
+
defend, and hold each Contributor harmless for any liability
|
|
174
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
175
|
+
of your accepting any such warranty or additional liability.
|
|
176
|
+
|
|
177
|
+
END OF TERMS AND CONDITIONS
|
|
178
|
+
|
|
179
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
180
|
+
|
|
181
|
+
To apply the Apache License to your work, attach the following
|
|
182
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
183
|
+
replaced with your own identifying information. (Don't include
|
|
184
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
185
|
+
comment syntax for the file format. We also recommend that a
|
|
186
|
+
file or class name and description of purpose be included on the
|
|
187
|
+
same "printed page" as the copyright notice for easier
|
|
188
|
+
identification within third-party archives.
|
|
189
|
+
|
|
190
|
+
Copyright [yyyy] [name of copyright owner]
|
|
191
|
+
|
|
192
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
193
|
+
you may not use this file except in compliance with the License.
|
|
194
|
+
You may obtain a copy of the License at
|
|
195
|
+
|
|
196
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
197
|
+
|
|
198
|
+
Unless required by applicable law or agreed to in writing, software
|
|
199
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
200
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
201
|
+
See the License for the specific language governing permissions and
|
|
202
|
+
limitations under the License.
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Notices for Eclipse zenoh-c
|
|
2
|
+
|
|
3
|
+
This content is produced and maintained by the Eclipse zenoh project.
|
|
4
|
+
|
|
5
|
+
* Project home: https://projects.eclipse.org/projects/iot.zenoh
|
|
6
|
+
|
|
7
|
+
## Trademarks
|
|
8
|
+
|
|
9
|
+
Eclipse zenoh is trademark of the Eclipse Foundation.
|
|
10
|
+
Eclipse, and the Eclipse Logo are registered trademarks of the Eclipse Foundation.
|
|
11
|
+
|
|
12
|
+
## Copyright
|
|
13
|
+
|
|
14
|
+
All content is the property of the respective authors or their employers.
|
|
15
|
+
For more information regarding authorship of content, please consult the
|
|
16
|
+
listed source code repository logs.
|
|
17
|
+
|
|
18
|
+
## Declared Project Licenses
|
|
19
|
+
|
|
20
|
+
This program and the accompanying materials are made available under the
|
|
21
|
+
terms of the Eclipse Public License 2.0 which is available at
|
|
22
|
+
http://www.eclipse.org/legal/epl-2.0, or the Apache License, Version 2.0
|
|
23
|
+
which is available at https://www.apache.org/licenses/LICENSE-2.0.
|
|
24
|
+
|
|
25
|
+
SPDX-License-Identifier: EPL-2.0 OR Apache-2.0
|
|
26
|
+
|
|
27
|
+
## Source Code
|
|
28
|
+
|
|
29
|
+
The project maintains the following source code repositories:
|
|
30
|
+
|
|
31
|
+
* https://github.com/eclipse-zenoh/zenoh.git
|
|
32
|
+
* https://github.com/eclipse-zenoh/zenoh-c.git
|
|
33
|
+
* https://github.com/eclipse-zenoh/zenoh-java.git
|
|
34
|
+
* https://github.com/eclipse-zenoh/zenoh-go.git
|
|
35
|
+
* https://github.com/eclipse-zenoh/zenoh-python.git
|
|
36
|
+
|
|
37
|
+
## Third-party Content
|
|
38
|
+
|
|
39
|
+
*To be completed...*
|
|
40
|
+
|
metadata
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: asterism-zenoh
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 0.1.0
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Katsuhiko Kageyama
|
|
8
|
+
autorequire:
|
|
9
|
+
bindir: bin
|
|
10
|
+
cert_chain: []
|
|
11
|
+
date: 2026-10-08 00:00:00.000000000 Z
|
|
12
|
+
dependencies: []
|
|
13
|
+
description: Sessions, put / subscribe, get / queryable, liveliness and attachments,
|
|
14
|
+
received by polling. The same Ruby API as Asterism's mruby / PicoRuby binding. The
|
|
15
|
+
C extension is compiled at install time against the official prebuilt zenoh-c release
|
|
16
|
+
for the machine, downloaded and checked against a pinned sha256.
|
|
17
|
+
email:
|
|
18
|
+
executables: []
|
|
19
|
+
extensions:
|
|
20
|
+
- ext/asterism_zenoh/extconf.rb
|
|
21
|
+
extra_rdoc_files: []
|
|
22
|
+
files:
|
|
23
|
+
- LICENSE
|
|
24
|
+
- README.md
|
|
25
|
+
- ZENOH_C_PIN
|
|
26
|
+
- ext/asterism_zenoh/extconf.rb
|
|
27
|
+
- ext/asterism_zenoh/zenoh.c
|
|
28
|
+
- ext/asterism_zenoh/zenoh_c.rb
|
|
29
|
+
- lib/asterism/zenoh.rb
|
|
30
|
+
- lib/asterism/zenoh/global.rb
|
|
31
|
+
- lib/asterism/zenoh/version.rb
|
|
32
|
+
- licenses/zenoh-c/LICENSE-APACHE
|
|
33
|
+
- licenses/zenoh-c/NOTICE.md
|
|
34
|
+
homepage: https://github.com/ruby-asterism/asterism-zenoh
|
|
35
|
+
licenses:
|
|
36
|
+
- MIT
|
|
37
|
+
- Apache-2.0
|
|
38
|
+
metadata:
|
|
39
|
+
homepage_uri: https://github.com/ruby-asterism/asterism-zenoh
|
|
40
|
+
source_code_uri: https://github.com/ruby-asterism/asterism-zenoh
|
|
41
|
+
bug_tracker_uri: https://github.com/ruby-asterism/asterism-zenoh/issues
|
|
42
|
+
rubygems_mfa_required: 'true'
|
|
43
|
+
post_install_message:
|
|
44
|
+
rdoc_options: []
|
|
45
|
+
require_paths:
|
|
46
|
+
- lib
|
|
47
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
48
|
+
requirements:
|
|
49
|
+
- - ">="
|
|
50
|
+
- !ruby/object:Gem::Version
|
|
51
|
+
version: '3.2'
|
|
52
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
53
|
+
requirements:
|
|
54
|
+
- - ">="
|
|
55
|
+
- !ruby/object:Gem::Version
|
|
56
|
+
version: '0'
|
|
57
|
+
requirements: []
|
|
58
|
+
rubygems_version: 3.4.19
|
|
59
|
+
signing_key:
|
|
60
|
+
specification_version: 4
|
|
61
|
+
summary: 'Asterism::Zenoh: an unofficial Zenoh binding for Ruby (over zenoh-c)'
|
|
62
|
+
test_files: []
|