bigdecimal 3.1.1 → 3.1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9ca183be10a5ec4ff2ecb2c13e25b5ae7768606813eb0aa14b72bcbf4addc819
4
- data.tar.gz: 1de83bfe351a536294d4f68991a7028003bb13077736649172f18f535999d769
3
+ metadata.gz: 4107ae2a3ed84ad02b56f2f57c31087185545454e53089e8176a23bd829c5177
4
+ data.tar.gz: 392489743d1863336597fc19039c1fd0077c5735b096de799f8adf61a5c29dbe
5
5
  SHA512:
6
- metadata.gz: e7c452da2ccece706e3991c6f5476552eb17d7de056396b084e563d711c1f060c4716ecb4960c2b07a7aa321b5afdd8b5473323c57b1f5f51561a813163de0e7
7
- data.tar.gz: 946a0327cdaf66dc01e92861629d0b5dda5daeaa8e4e5e4b1f8eb2f6873cad015f91ac352b9c28bdd88243835fcc5aa56e0e02ab8519872ece1590e1359012c8
6
+ metadata.gz: 337fb13844251d627cecd341da3bc0a23b0addcc0b83f49f76e3fc0796852e24d71291712b270c79e3cb9e729bd2d831e4ca303a46dd4c7446404de6175b1f86
7
+ data.tar.gz: 4d2b9734294ff4f154df4012bd8f21964e3627b29ade7c716079ad6a74c19713a0a0a287cb57315d642cac7fe9b521db21104e9ea89eef745babcf292b7a67d2
data/bigdecimal.gemspec CHANGED
@@ -1,28 +1,29 @@
1
1
  # coding: utf-8
2
2
 
3
+ name = File.basename(__FILE__, '.*')
4
+ source_version = ["", "ext/#{name}/"].find do |dir|
5
+ begin
6
+ break File.foreach(File.join(__dir__, "#{dir}#{name}.c")) {|line|
7
+ break $1.sub("-", ".") if /^#define\s+#{name.upcase}_VERSION\s+"(.+)"/o =~ line
8
+ }
9
+ rescue Errno::ENOENT
10
+ end
11
+ end or raise "can't find #{name.upcase}_VERSION"
12
+
3
13
  Gem::Specification.new do |s|
4
- s.name = "bigdecimal"
5
- s.version = "3.1.1"
14
+ s.name = name
15
+ s.version = source_version
6
16
  s.authors = ["Kenta Murata", "Zachary Scott", "Shigeo Kobayashi"]
7
17
  s.email = ["mrkn@mrkn.jp"]
8
18
 
9
19
  s.summary = "Arbitrary-precision decimal floating-point number library."
10
20
  s.description = "This library provides arbitrary-precision decimal floating-point number class."
11
21
  s.homepage = "https://github.com/ruby/bigdecimal"
12
- s.license = "Ruby"
22
+ s.licenses = ["Ruby", "BSD-2-Clause"]
13
23
 
14
24
  s.require_paths = %w[lib]
15
- s.extensions = %w[ext/bigdecimal/extconf.rb]
16
25
  s.files = %w[
17
26
  bigdecimal.gemspec
18
- ext/bigdecimal/bigdecimal.c
19
- ext/bigdecimal/bigdecimal.h
20
- ext/bigdecimal/bits.h
21
- ext/bigdecimal/feature.h
22
- ext/bigdecimal/missing.c
23
- ext/bigdecimal/missing.h
24
- ext/bigdecimal/missing/dtoa.c
25
- ext/bigdecimal/static_assert.h
26
27
  lib/bigdecimal.rb
27
28
  lib/bigdecimal/jacobian.rb
28
29
  lib/bigdecimal/ludcmp.rb
@@ -33,6 +34,21 @@ Gem::Specification.new do |s|
33
34
  sample/nlsolve.rb
34
35
  sample/pi.rb
35
36
  ]
37
+ if Gem::Platform === s.platform and s.platform =~ 'java' or RUBY_ENGINE == 'jruby'
38
+ s.platform = 'java'
39
+ else
40
+ s.extensions = %w[ext/bigdecimal/extconf.rb]
41
+ s.files += %w[
42
+ ext/bigdecimal/bigdecimal.c
43
+ ext/bigdecimal/bigdecimal.h
44
+ ext/bigdecimal/bits.h
45
+ ext/bigdecimal/feature.h
46
+ ext/bigdecimal/missing.c
47
+ ext/bigdecimal/missing.h
48
+ ext/bigdecimal/missing/dtoa.c
49
+ ext/bigdecimal/static_assert.h
50
+ ]
51
+ end
36
52
 
37
53
  s.required_ruby_version = Gem::Requirement.new(">= 2.5.0")
38
54
  end