digest 3.1.0.pre3 → 3.1.0

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: a901be021123562b80812ad783e1e6cb9d44a3d3082b38304860722b1de65b8d
4
- data.tar.gz: d22dfd3515b87aa626b52a096240fab8ebe635eb0ee43edc1ce595c6ae6901a8
3
+ metadata.gz: 7207f387ca787774225cd9df57fae5c62761095cbe5976d3b0e92844ce700add
4
+ data.tar.gz: 7c5bdbbac47aa05a44bc9bc37a4519a4eb7c062dfc781dd8b4c6b567a6596aa1
5
5
  SHA512:
6
- metadata.gz: 4f06a8c82073b0ae69a6f6a0292a92bcca0e13af7f751cc98471769c71efcd5f5cd2cfa45ad9b3b7d1b574b7ce7b442ee85f75391de1376f9180499dd682c002
7
- data.tar.gz: 3a53dbbcd44edacf5ea23a326a27474715693ea6064d9ed5211790fcf2af12669a9115219cf8cd83bda99d5a0c4790bd9d7a9062b4b3f29de0e4b3c2bc15f16d
6
+ metadata.gz: b589e6eb9462f1e9572ba5186840437f85bf6c5c7a12665ef3b6b6d0848a2e372f1df9b228a49b6e5321ca280353cf5de652ad5404af5cc200c4fe301ce37760
7
+ data.tar.gz: 40f9583406b3f58ff6f22c8af4a2a414db6753b472201d22471eca5df1c16ca5563ca56700357a3165250505697a9fa58e6f73da7c0baf8ea56a5e12589aff3e
@@ -4,4 +4,8 @@
4
4
 
5
5
  require "mkmf"
6
6
 
7
+ $INSTALLFILES = {
8
+ "digest.h" => "$(HDRDIR)"
9
+ } if $extmk
10
+
7
11
  create_makefile("digest")
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Digest
4
- VERSION = "3.1.0.pre3"
4
+ VERSION = "3.1.0"
5
5
  end
data/lib/digest.rb CHANGED
@@ -1,25 +1,23 @@
1
1
  # frozen_string_literal: false
2
2
 
3
- # The gem and bundle commands (except for bundle exec) first load
4
- # digest via openssl and then load gems, so if this is installed via
5
- # gem, we are overwriting the default version of digest. Beware not
6
- # to break it or cause redefinition warnings.
7
- #
8
- # When we introduce incompatible changes and overwriting is not an
9
- # option, and given that the default version does not have security
10
- # defects, we may just give up and let those commands just use the
11
- # default version of digest.
12
- #
13
- # return if defined?(Digest) && caller_locations.any? { |l|
14
- # %r{/(rubygems/gem_runner|bundler/cli)\.rb}.match?(l.path)
15
- # }
3
+ if defined?(Digest) &&
4
+ /\A(?:2\.|3\.0\.[0-2]\z)/.match?(RUBY_VERSION) &&
5
+ caller_locations.any? { |l|
6
+ %r{/(rubygems/gem_runner|bundler/cli)\.rb}.match?(l.path)
7
+ }
8
+ # Before Ruby 3.0.3/3.1.0, the gem and bundle commands used to load
9
+ # the digest library before loading additionally installed gems, so
10
+ # you will get constant redefinition warnings and unexpected
11
+ # implementation overwriting if we proceed here. Avoid that.
12
+ return
13
+ end
16
14
 
17
15
  require 'digest/version'
18
16
  require 'digest/loader'
19
17
 
20
18
  module Digest
21
19
  # A mutex for Digest().
22
- REQUIRE_MUTEX ||= Thread::Mutex.new
20
+ REQUIRE_MUTEX = Thread::Mutex.new
23
21
 
24
22
  def self.const_missing(name) # :nodoc:
25
23
  case name
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: digest
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.0.pre3
4
+ version: 3.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Akinori MUSHA
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-10-24 00:00:00.000000000 Z
11
+ date: 2021-12-24 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Provides a framework for message digest libraries.
14
14
  email:
@@ -28,12 +28,10 @@ files:
28
28
  - ext/digest/bubblebabble/bubblebabble.c
29
29
  - ext/digest/bubblebabble/extconf.rb
30
30
  - ext/digest/defs.h
31
- - ext/digest/depend
32
31
  - ext/digest/digest.c
33
32
  - ext/digest/digest.h
34
33
  - ext/digest/digest_conf.rb
35
34
  - ext/digest/extconf.rb
36
- - ext/digest/install_headers.rb
37
35
  - ext/digest/lib/digest/loader.rb
38
36
  - ext/digest/lib/digest/sha2/loader.rb
39
37
  - ext/digest/md5/extconf.rb
@@ -76,11 +74,11 @@ required_ruby_version: !ruby/object:Gem::Requirement
76
74
  version: 2.5.0
77
75
  required_rubygems_version: !ruby/object:Gem::Requirement
78
76
  requirements:
79
- - - ">"
77
+ - - ">="
80
78
  - !ruby/object:Gem::Version
81
- version: 1.3.1
79
+ version: '0'
82
80
  requirements: []
83
- rubygems_version: 3.2.22
81
+ rubygems_version: 3.2.32
84
82
  signing_key:
85
83
  specification_version: 4
86
84
  summary: Provides a framework for message digest libraries.
data/ext/digest/depend DELETED
@@ -1,3 +0,0 @@
1
- do-install-rb: do-install-headers
2
- do-install-headers:
3
- $(Q) $(RUBY) install_headers.rb $(srcdir)/digest.h $(DESTDIR)$(HDRDIR)
@@ -1,13 +0,0 @@
1
- require "fileutils"
2
-
3
- *files, dest = ARGV
4
-
5
- if File.exist?(File.join(dest, "ruby.h"))
6
- warn "installing header files"
7
-
8
- files.each { |file|
9
- FileUtils.install file, dest, mode: 0644, verbose: true
10
- }
11
- else
12
- warn "not installing header files when installed as an external library"
13
- end