numo-openblas 0.4.2 → 0.4.3
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/CHANGELOG.md +4 -0
- data/ext/numo/openblas/extconf.rb +7 -30
- data/lib/numo/openblas/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2fdbbab5dab6f7be0c058002b0fa93957d435b26f9d59168d6086fd0d4fba781
|
4
|
+
data.tar.gz: b685c5c97e3a48845d470cb9bed44568f7343a38516984a0fb6a9d62bc0955ce
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c9321441ce9d109dc259e9970719f41443f7edbe0103b4bb01c3f67c6b7713e353cbc35d6971fbb861eea4b43503e67874d6e75462e7b012bc12ea29af7b2464
|
7
|
+
data.tar.gz: 4cc439f37deb7065352931943106c00cdaa0322521860567c727bf4f4b88816b28857c509a1485482e29e7478677816bf472b59fa0573f22df790914cb1b5212
|
data/CHANGELOG.md
CHANGED
@@ -8,23 +8,18 @@ require 'open-uri'
|
|
8
8
|
require 'open3'
|
9
9
|
require 'rubygems/package'
|
10
10
|
|
11
|
-
OPENBLAS_VER = '0.3.
|
12
|
-
OPENBLAS_KEY = '
|
11
|
+
OPENBLAS_VER = '0.3.17'
|
12
|
+
OPENBLAS_KEY = '0de2c8a2feb12183cce6222f1e963f7e254a23a2'
|
13
13
|
OPENBLAS_URI = "https://github.com/xianyi/OpenBLAS/archive/v#{OPENBLAS_VER}.tar.gz"
|
14
14
|
OPENBLAS_DIR = File.expand_path(__dir__ + '/../../../vendor')
|
15
15
|
|
16
16
|
unless File.exist?("#{OPENBLAS_DIR}/installed_#{OPENBLAS_VER}")
|
17
|
-
puts "Downloading OpenBLAS #{OPENBLAS_VER}."
|
18
17
|
URI.open(OPENBLAS_URI) do |rf|
|
19
18
|
File.open("#{OPENBLAS_DIR}/tmp/openblas.tgz", 'wb') { |sf| sf.write(rf.read) }
|
20
19
|
end
|
21
20
|
|
22
|
-
if OPENBLAS_KEY != Digest::SHA1.file("#{OPENBLAS_DIR}/tmp/openblas.tgz").to_s
|
23
|
-
puts 'SHA1 digest of downloaded file does not match.'
|
24
|
-
exit(1)
|
25
|
-
end
|
21
|
+
abort('SHA1 digest of downloaded file does not match.') if OPENBLAS_KEY != Digest::SHA1.file("#{OPENBLAS_DIR}/tmp/openblas.tgz").to_s
|
26
22
|
|
27
|
-
puts 'Unpacking OpenBLAS tar.gz file.'
|
28
23
|
Gem::Package::TarReader.new(Zlib::GzipReader.open("#{OPENBLAS_DIR}/tmp/openblas.tgz")) do |tar|
|
29
24
|
tar.each do |entry|
|
30
25
|
next unless entry.file?
|
@@ -39,38 +34,20 @@ unless File.exist?("#{OPENBLAS_DIR}/installed_#{OPENBLAS_VER}")
|
|
39
34
|
end
|
40
35
|
|
41
36
|
Dir.chdir("#{OPENBLAS_DIR}/tmp/OpenBLAS-#{OPENBLAS_VER}") do
|
42
|
-
puts 'Building OpenBLAS. This could take a while...'
|
43
37
|
mkstdout, _mkstderr, mkstatus = Open3.capture3("make -j#{Etc.nprocessors}")
|
44
38
|
File.open("#{OPENBLAS_DIR}/tmp/openblas.log", 'w') { |f| f.puts(mkstdout) }
|
45
|
-
unless mkstatus.success?
|
46
|
-
puts 'Failed to build OpenBLAS.'
|
47
|
-
puts 'Check the openblas.log file for more details:'
|
48
|
-
puts "#{OPENBLAS_DIR}/tmp/openblas.log"
|
49
|
-
exit(1)
|
50
|
-
end
|
39
|
+
abort("Failed to build OpenBLAS. Check the openblas.log file for more details: #{OPENBLAS_DIR}/tmp/openblas.log") unless mkstatus.success?
|
51
40
|
|
52
|
-
puts 'Installing OpenBLAS.'
|
53
41
|
insstdout, _insstderr, insstatus = Open3.capture3("make install PREFIX=#{OPENBLAS_DIR}")
|
54
42
|
File.open("#{OPENBLAS_DIR}/tmp/openblas.log", 'a') { |f| f.puts(insstdout) }
|
55
|
-
unless insstatus.success?
|
56
|
-
puts 'Failed to install OpenBLAS.'
|
57
|
-
puts 'Check the openblas.log file for more details:'
|
58
|
-
puts "#{OPENBLAS_DIR}/tmp/openblas.log"
|
59
|
-
exit(1)
|
60
|
-
end
|
43
|
+
abort("Failed to install OpenBLAS. Check the openblas.log file for more details: #{OPENBLAS_DIR}/tmp/openblas.log") unless insstatus.success?
|
61
44
|
|
62
45
|
FileUtils.touch("#{OPENBLAS_DIR}/installed_#{OPENBLAS_VER}")
|
63
46
|
end
|
64
47
|
end
|
65
48
|
|
66
|
-
unless find_library('openblas', nil, "#{OPENBLAS_DIR}/lib")
|
67
|
-
puts 'libopenblas is not found.'
|
68
|
-
exit(1)
|
69
|
-
end
|
49
|
+
abort('libopenblas is not found.') unless find_library('openblas', nil, "#{OPENBLAS_DIR}/lib")
|
70
50
|
|
71
|
-
unless find_header('openblas_config.h', nil, "#{OPENBLAS_DIR}/include")
|
72
|
-
puts 'openblas_config.h is not found.'
|
73
|
-
exit(1)
|
74
|
-
end
|
51
|
+
abort('openblas_config.h is not found.') unless find_header('openblas_config.h', nil, "#{OPENBLAS_DIR}/include")
|
75
52
|
|
76
53
|
create_makefile('numo/openblas/openblas')
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: numo-openblas
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- yoshoku
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-08-
|
11
|
+
date: 2021-08-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: numo-linalg
|