re2 2.10.0-x86-mingw32 → 2.12.0-x86-mingw32

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: bb3d236cb2b175f832821a64dd4c8cb889115087f527c219fbd9441ef6bd84fd
4
- data.tar.gz: 6cc94a9ce7783233bfe355dce18beb3cf0d009360ac4765ef300f49a96609a11
3
+ metadata.gz: ceb063f822b1a0d45036803276a5e794ffa0798aeca9d24bdf04c257b50f34af
4
+ data.tar.gz: 9bfce242bbfe074f3f824d9da681428dbcb401489cee6d347fd3f6b58bdd6ab4
5
5
  SHA512:
6
- metadata.gz: 3364bbc76dbc35e63931db55bac5327bde1707281d37d99895edb2da8d82f9f7ced3d9c5362745dbdeee47d157b158b419eb5506ea8b8abf537f7289ed3bfcaf
7
- data.tar.gz: 724f4f37e1d11511548cfbe07476dde6092bc1956c3bd2a40dfc0606dc71487af270ab0b67b2f6d541235bfbd12efe145ae78ee5c2db282a166328f47ccb9a7f
6
+ metadata.gz: 56bd1fd7231a960df87dc7ea1b7dbd84cd4fad868d7b2857f5dfead0a897a5bbe3c2a168da63575abd348f768cd0c758796a56832472863354270ecd1a117381
7
+ data.tar.gz: fc588134d3b5c4aefc91f28c3f63eb5076400187333971974a9ec0350b96c1676340d0dc756ab4a021c4d5ea133d45f88874f344a6f365f7cd80327cb05ffad1
data/Gemfile CHANGED
@@ -5,3 +5,7 @@ source "https://rubygems.org"
5
5
  gemspec
6
6
 
7
7
  gem "rake", "> 12.3.2"
8
+
9
+ group :memcheck, optional: true do
10
+ gem "ruby_memcheck"
11
+ end
data/README.md CHANGED
@@ -6,8 +6,8 @@ Python".
6
6
 
7
7
  [![Build Status](https://github.com/mudge/re2/actions/workflows/tests.yml/badge.svg?branch=main)](https://github.com/mudge/re2/actions)
8
8
 
9
- **Current version:** 2.10.0
10
- **Bundled RE2 version:** libre2.11 (2024-04-01)
9
+ **Current version:** 2.12.0
10
+ **Bundled RE2 version:** libre2.11 (2024-06-01)
11
11
 
12
12
  ```ruby
13
13
  RE2('h.*o').full_match?("hello") #=> true
@@ -261,7 +261,7 @@ This gem requires the following to run:
261
261
 
262
262
  It supports the following RE2 ABI versions:
263
263
 
264
- * libre2.0 (prior to release 2020-03-02) to libre2.11 (2023-07-01 to 2024-04-01)
264
+ * libre2.0 (prior to release 2020-03-02) to libre2.11 (2023-07-01 to 2024-06-01)
265
265
 
266
266
  ### Native gems
267
267
 
@@ -279,18 +279,18 @@ Where possible, a pre-compiled native gem will be provided for the following pla
279
279
  SHA256 checksums are included in the [release notes](https://github.com/mudge/re2/releases) for each version and can be checked with `sha256sum`, e.g.
280
280
 
281
281
  ```console
282
- $ gem fetch re2 -v 2.9.0
283
- Fetching re2-2.9.0-arm64-darwin.gem
284
- Downloaded re2-2.9.0-arm64-darwin
285
- $ sha256sum re2-2.9.0-arm64-darwin.gem
286
- 91dcc103257d7abb0ee832d673267cee48be7194883fed502b1407d2779c3499 re2-2.9.0-arm64-darwin.gem
282
+ $ gem fetch re2 -v 2.11.0
283
+ Fetching re2-2.11.0-arm64-darwin.gem
284
+ Downloaded re2-2.11.0-arm64-darwin
285
+ $ sha256sum re2-2.11.0-arm64-darwin.gem
286
+ 206c1caf4700d95d68e5e8ee18351541d941099e2e9300117f9fb65246a974b6 re2-2.11.0-arm64-darwin.gem
287
287
  ```
288
288
 
289
289
  [GPG](https://www.gnupg.org/) signatures are attached to each release (the assets ending in `.sig`) and can be verified if you import [our signing key `0x39AC3530070E0F75`](https://mudge.name/39AC3530070E0F75.asc) (or fetch it from a public keyserver, e.g. `gpg --keyserver keyserver.ubuntu.com --recv-key 0x39AC3530070E0F75`):
290
290
 
291
291
  ```console
292
- $ gpg --verify re2-2.9.0-arm64-darwin.gem.sig re2-2.9.0-arm64-darwin.gem
293
- gpg: Signature made Thu 29 Feb 14:00:55 2024 GMT
292
+ $ gpg --verify re2-2.11.0-arm64-darwin.gem.sig re2-2.11.0-arm64-darwin.gem
293
+ gpg: Signature made Tue 30 Apr 17:52:13 2024 BST
294
294
  gpg: using RSA key 702609D9C790F45B577D7BEC39AC3530070E0F75
295
295
  gpg: Good signature from "Paul Mucur <mudge@mudge.name>" [unknown]
296
296
  gpg: aka "Paul Mucur <paul@ghostcassette.com>" [unknown]
data/Rakefile CHANGED
@@ -1,40 +1,23 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require 'rake/extensiontask'
4
- require 'rspec/core/rake_task'
5
4
  require 'rake_compiler_dock'
6
- require 'yaml'
5
+ require 'rspec/core/rake_task'
7
6
 
8
7
  require_relative 'ext/re2/recipes'
9
8
 
10
- CLEAN.include FileList['**/*{.o,.so,.dylib,.bundle}'],
11
- FileList['**/extconf.h'],
12
- FileList['**/Makefile'],
13
- FileList['pkg/']
14
-
15
- CLOBBER.include FileList['**/tmp'],
16
- FileList['**/*.log'],
17
- FileList['doc/**'],
18
- FileList['tmp/']
19
- CLOBBER.add("ports/*").exclude(%r{ports/archives$})
20
-
21
- RE2_GEM_SPEC = Gem::Specification.load('re2.gemspec')
22
-
23
- task :prepare do
24
- puts "Preparing project for gem building..."
25
- recipes = load_recipes
26
- recipes.each { |recipe| recipe.download }
27
- end
9
+ re2_gemspec = Gem::Specification.load('re2.gemspec')
10
+ abseil_recipe, re2_recipe = load_recipes
28
11
 
29
- task gem: :prepare
12
+ # Add Abseil and RE2's latest archives to the gem files. (Note these will be
13
+ # removed from the precompiled native gems.)
14
+ abseil_archive = File.join("ports/archives", File.basename(abseil_recipe.files[0][:url]))
15
+ re2_archive = File.join("ports/archives", File.basename(re2_recipe.files[0][:url]))
30
16
 
31
- Gem::PackageTask.new(RE2_GEM_SPEC) do |p|
32
- p.need_zip = false
33
- p.need_tar = false
34
- end
17
+ re2_gemspec.files << abseil_archive
18
+ re2_gemspec.files << re2_archive
35
19
 
36
- CROSS_RUBY_VERSIONS = %w[3.3.0 3.2.0 3.1.0 3.0.0 2.7.0 2.6.0].join(':')
37
- CROSS_RUBY_PLATFORMS = %w[
20
+ cross_platforms = %w[
38
21
  aarch64-linux
39
22
  arm-linux
40
23
  arm64-darwin
@@ -46,13 +29,15 @@ CROSS_RUBY_PLATFORMS = %w[
46
29
  x86_64-linux
47
30
  ].freeze
48
31
 
49
- ENV['RUBY_CC_VERSION'] = CROSS_RUBY_VERSIONS
32
+ ENV['RUBY_CC_VERSION'] = %w[3.3.0 3.2.0 3.1.0 3.0.0 2.7.0 2.6.0].join(':')
33
+
34
+ Gem::PackageTask.new(re2_gemspec).define
50
35
 
51
- Rake::ExtensionTask.new('re2', RE2_GEM_SPEC) do |e|
36
+ Rake::ExtensionTask.new('re2', re2_gemspec) do |e|
52
37
  e.cross_compile = true
53
38
  e.cross_config_options << '--enable-cross-build'
54
39
  e.config_options << '--disable-system-libraries'
55
- e.cross_platform = CROSS_RUBY_PLATFORMS
40
+ e.cross_platform = cross_platforms
56
41
  e.cross_compiling do |spec|
57
42
  spec.files.reject! { |path| File.fnmatch?('ports/*', path) }
58
43
  spec.dependencies.reject! { |dep| dep.name == 'mini_portile2' }
@@ -61,72 +46,45 @@ end
61
46
 
62
47
  RSpec::Core::RakeTask.new(:spec)
63
48
 
64
- namespace 'gem' do
65
- def gem_builder(platform)
66
- # use Task#invoke because the pkg/*gem task is defined at runtime
67
- Rake::Task["native:#{platform}"].invoke
68
- Rake::Task["pkg/#{RE2_GEM_SPEC.full_name}-#{Gem::Platform.new(platform)}.gem"].invoke
49
+ begin
50
+ require 'ruby_memcheck'
51
+ require 'ruby_memcheck/rspec/rake_task'
52
+
53
+ namespace :spec do
54
+ RubyMemcheck::RSpec::RakeTask.new(valgrind: :compile)
69
55
  end
56
+ rescue LoadError
57
+ # Only define the spec:valgrind task if ruby_memcheck is installed
58
+ end
70
59
 
71
- CROSS_RUBY_PLATFORMS.each do |platform|
72
- # The Linux x86 image (ghcr.io/rake-compiler/rake-compiler-dock-image:1.3.0-mri-x86_64-linux)
73
- # is based on CentOS 7 and has two versions of cmake installed:
74
- # a 2.8 version in /usr/bin and a 3.25 in /usr/local/bin. The latter is needed by abseil.
75
- cmake =
76
- case platform
77
- when 'x86_64-linux', 'x86-linux'
78
- '/usr/local/bin/cmake'
79
- else
80
- 'cmake'
81
- end
82
-
83
- desc "build native gem for #{platform} platform"
60
+ namespace :gem do
61
+ cross_platforms.each do |platform|
62
+
63
+ # Compile each platform's native gem, packaging up the result. Note we add
64
+ # /usr/local/bin to the PATH as it contains the newest version of CMake in
65
+ # the rake-compiler-dock images.
66
+ desc "Compile and build native gem for #{platform} platform"
84
67
  task platform do
85
68
  RakeCompilerDock.sh <<~SCRIPT, platform: platform, verbose: true
86
69
  gem install bundler --no-document &&
87
70
  bundle &&
88
- bundle exec rake gem:#{platform}:builder CMAKE=#{cmake}
71
+ bundle exec rake native:#{platform} pkg/#{re2_gemspec.full_name}-#{Gem::Platform.new(platform)}.gem PATH="/usr/local/bin:$PATH"
89
72
  SCRIPT
90
73
  end
91
-
92
- namespace platform do
93
- desc "build native gem for #{platform} platform (guest container)"
94
- task 'builder' do
95
- gem_builder(platform)
96
- end
97
- end
98
74
  end
99
-
100
- desc 'build all native gems'
101
- multitask 'native' => CROSS_RUBY_PLATFORMS
102
- end
103
-
104
- def add_file_to_gem(relative_source_path)
105
- dest_path = File.join(gem_build_path, relative_source_path)
106
- dest_dir = File.dirname(dest_path)
107
-
108
- mkdir_p dest_dir unless Dir.exist?(dest_dir)
109
- rm_f dest_path if File.exist?(dest_path)
110
- safe_ln relative_source_path, dest_path
111
-
112
- RE2_GEM_SPEC.files << relative_source_path
113
75
  end
114
76
 
115
- def gem_build_path
116
- File.join 'pkg', RE2_GEM_SPEC.full_name
77
+ # Set up file tasks for Abseil and RE2's archives so they are automatically
78
+ # downloaded when required by the gem task.
79
+ file abseil_archive do
80
+ abseil_recipe.download
117
81
  end
118
82
 
119
- def add_vendored_libraries
120
- dependencies = YAML.load_file(File.join(File.dirname(__FILE__), 'dependencies.yml'))
121
- abseil_archive = File.join('ports', 'archives', "#{dependencies['abseil']['version']}.tar.gz")
122
- libre2_archive = File.join('ports', 'archives', "re2-#{dependencies['libre2']['version']}.tar.gz")
123
-
124
- add_file_to_gem(abseil_archive)
125
- add_file_to_gem(libre2_archive)
83
+ file re2_archive do
84
+ re2_recipe.download
126
85
  end
127
86
 
128
- task gem_build_path do
129
- add_vendored_libraries
130
- end
87
+ task default: :spec
131
88
 
132
- task default: [:compile, :spec]
89
+ CLEAN.add("lib/**/*.{o,so,bundle}", "pkg")
90
+ CLOBBER.add("ports")
data/dependencies.yml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  libre2:
3
- version: '2024-04-01'
4
- sha256: 3f6690c3393a613c3a0b566309cf04dc381d61470079b653afc47c67fb898198
3
+ version: '2024-06-01'
4
+ sha256: 7326c74cddaa90b12090fcfc915fe7b4655723893c960ee3c2c66e85c5504b6c
5
5
  abseil:
6
- version: '20240116.1'
7
- sha256: 3c743204df78366ad2eaf236d6631d83f6bc928d1705dd0000b872e53b73dc6a
6
+ version: '20240116.2'
7
+ sha256: 733726b8c3a6d39a4120d7e45ea8b41a434cdacde401cba500f14236c49b39dc
data/ext/re2/extconf.rb CHANGED
@@ -226,8 +226,6 @@ module RE2
226
226
  .shellsplit
227
227
  .map { |flag| flag.delete_prefix('-L') }
228
228
 
229
- $LIBPATH = static_library_paths | $LIBPATH
230
-
231
229
  # Replace all -l flags that can be found in one of the static library
232
230
  # paths with the absolute path instead.
233
231
  minimal_pkg_config(pc_file, '--libs-only-l', '--static')
data/ext/re2/recipes.rb CHANGED
@@ -9,7 +9,7 @@
9
9
  # Released under the BSD Licence, please see LICENSE.txt
10
10
 
11
11
  PACKAGE_ROOT_DIR = File.expand_path('../..', __dir__)
12
- REQUIRED_MINI_PORTILE_VERSION = '~> 2.8.5' # keep this version in sync with the one in the gemspec
12
+ REQUIRED_MINI_PORTILE_VERSION = '~> 2.8.7' # keep this version in sync with the one in the gemspec
13
13
 
14
14
  def load_recipes
15
15
  require 'yaml'
data/lib/2.6/re2.so CHANGED
Binary file
data/lib/2.7/re2.so CHANGED
Binary file
data/lib/3.0/re2.so CHANGED
Binary file
data/lib/3.1/re2.so CHANGED
Binary file
data/lib/3.2/re2.so CHANGED
Binary file
data/lib/3.3/re2.so CHANGED
Binary file
data/lib/re2/version.rb CHANGED
@@ -10,5 +10,5 @@
10
10
 
11
11
 
12
12
  module RE2
13
- VERSION = "2.10.0"
13
+ VERSION = "2.12.0"
14
14
  end
data/re2.gemspec CHANGED
@@ -40,8 +40,8 @@ Gem::Specification.new do |s|
40
40
  "spec/re2/set_spec.rb",
41
41
  "spec/re2/scanner_spec.rb"
42
42
  ]
43
- s.add_development_dependency("rake-compiler", "~> 1.2.5")
44
- s.add_development_dependency("rake-compiler-dock", "~> 1.4.0")
43
+ s.add_development_dependency("rake-compiler", "~> 1.2.7")
44
+ s.add_development_dependency("rake-compiler-dock", "~> 1.5.0")
45
45
  s.add_development_dependency("rspec", "~> 3.2")
46
- s.add_runtime_dependency("mini_portile2", "~> 2.8.5") # keep version in sync with extconf.rb
46
+ s.add_runtime_dependency("mini_portile2", "~> 2.8.7") # keep version in sync with extconf.rb
47
47
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: re2
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.10.0
4
+ version: 2.12.0
5
5
  platform: x86-mingw32
6
6
  authors:
7
7
  - Paul Mucur
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2024-04-01 00:00:00.000000000 Z
12
+ date: 2024-06-02 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rake-compiler
@@ -17,28 +17,28 @@ dependencies:
17
17
  requirements:
18
18
  - - "~>"
19
19
  - !ruby/object:Gem::Version
20
- version: 1.2.5
20
+ version: 1.2.7
21
21
  type: :development
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
25
  - - "~>"
26
26
  - !ruby/object:Gem::Version
27
- version: 1.2.5
27
+ version: 1.2.7
28
28
  - !ruby/object:Gem::Dependency
29
29
  name: rake-compiler-dock
30
30
  requirement: !ruby/object:Gem::Requirement
31
31
  requirements:
32
32
  - - "~>"
33
33
  - !ruby/object:Gem::Version
34
- version: 1.4.0
34
+ version: 1.5.0
35
35
  type: :development
36
36
  prerelease: false
37
37
  version_requirements: !ruby/object:Gem::Requirement
38
38
  requirements:
39
39
  - - "~>"
40
40
  - !ruby/object:Gem::Version
41
- version: 1.4.0
41
+ version: 1.5.0
42
42
  - !ruby/object:Gem::Dependency
43
43
  name: rspec
44
44
  requirement: !ruby/object:Gem::Requirement