or-tools 0.6.2 → 0.6.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/ext/or-tools/extconf.rb +1 -6
- data/ext/or-tools/vendor.rb +25 -4
- data/lib/or_tools/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a94dfe67ccc7166a4ab27cbf5747d332452715db7ad302fa325ef7b5b270ef12
|
4
|
+
data.tar.gz: 36aacbdbf3be07f26e8711bc0ec00d8c1ac929288c62661f7425c721eb827c5d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9c66c41c7b34b75f09725bbf74c04e7d7a9c2eee5251cc294480baa9a4f8a1a0fcde3534f75f3462d69fdc7c97ec5367dac1cf5fae210351ae731c1cb3c4d5f3
|
7
|
+
data.tar.gz: c8cc4f3c87e7199f9322caa714435699e000be1888f33e2c6b1121aa72dfab1d8b10ba8100fd3ff64b6dcc43853c2b36485922cab2f3b0268ec8cddb1fe15bdc
|
data/CHANGELOG.md
CHANGED
data/ext/or-tools/extconf.rb
CHANGED
@@ -25,12 +25,7 @@ end
|
|
25
25
|
|
26
26
|
$INCFLAGS << " -I#{inc}"
|
27
27
|
|
28
|
-
$LDFLAGS
|
29
|
-
$LDFLAGS << " -L#{lib}"
|
28
|
+
$LDFLAGS.prepend("-Wl,-rpath,#{rpath} -L#{lib} ")
|
30
29
|
raise "OR-Tools not found" unless have_library("ortools")
|
31
30
|
|
32
|
-
Dir["#{lib}/libabsl_*.a"].each do |lib|
|
33
|
-
$LDFLAGS << " #{lib}"
|
34
|
-
end
|
35
|
-
|
36
31
|
create_makefile("or_tools/ext")
|
data/ext/or-tools/vendor.rb
CHANGED
@@ -121,12 +121,33 @@ end
|
|
121
121
|
download_checksum = Digest::SHA256.file(download_path).hexdigest
|
122
122
|
raise "Bad checksum: #{download_checksum}" if download_checksum != checksum
|
123
123
|
|
124
|
-
# extract - can't use Gem::Package#extract_tar_gz from RubyGems
|
125
|
-
# since it limits filenames to 100 characters (doesn't support UStar format)
|
126
124
|
path = File.expand_path("../../tmp/or-tools", __dir__)
|
127
125
|
FileUtils.mkdir_p(path)
|
128
|
-
|
129
|
-
|
126
|
+
|
127
|
+
# extract - can't use Gem::Package#extract_tar_gz from RubyGems
|
128
|
+
# since it limits filenames to 100 characters (doesn't support UStar format)
|
129
|
+
# for space, only keep licenses, include, and shared library
|
130
|
+
Dir.mktmpdir do |extract_path|
|
131
|
+
tar_args = Gem.win_platform? ? ["--force-local"] : []
|
132
|
+
system "tar", "zxf", download_path, "-C", extract_path, "--strip-components=1", *tar_args
|
133
|
+
|
134
|
+
# licenses
|
135
|
+
license_files = Dir.glob("**/*{LICENSE,LICENCE,NOTICE,COPYING,license,licence,notice,copying}*", base: extract_path)
|
136
|
+
raise "License not found" unless license_files.any?
|
137
|
+
license_files.each do |file|
|
138
|
+
FileUtils.mkdir_p(File.join(path, File.dirname(file)))
|
139
|
+
FileUtils.cp(File.join(extract_path, file), File.join(path, file))
|
140
|
+
end
|
141
|
+
|
142
|
+
# include
|
143
|
+
FileUtils.cp_r(File.join(extract_path, "include"), File.join(path, "include"))
|
144
|
+
|
145
|
+
# shared library
|
146
|
+
FileUtils.mkdir(File.join(path, "lib"))
|
147
|
+
Dir.glob("lib/libortools.{dylib,so}", base: extract_path) do |file|
|
148
|
+
FileUtils.cp(File.join(extract_path, file), File.join(path, file))
|
149
|
+
end
|
150
|
+
end
|
130
151
|
|
131
152
|
# export
|
132
153
|
$vendor_path = path
|
data/lib/or_tools/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: or-tools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrew Kane
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-03-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rice
|
@@ -92,7 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
92
92
|
- !ruby/object:Gem::Version
|
93
93
|
version: '0'
|
94
94
|
requirements: []
|
95
|
-
rubygems_version: 3.3.
|
95
|
+
rubygems_version: 3.3.7
|
96
96
|
signing_key:
|
97
97
|
specification_version: 4
|
98
98
|
summary: Operations research tools for Ruby
|