re2 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/README.md +2 -2
  2. data/Rakefile +3 -1
  3. data/ext/re2/re2.cc +3 -0
  4. metadata +21 -8
data/README.md CHANGED
@@ -6,11 +6,11 @@ A Ruby binding to [re2][], an "efficient, principled regular expression library"
6
6
  Installation
7
7
  ------------
8
8
 
9
- You will need [re2][] installed in its default location of /usr/local as well as a C++ compiler such as [gcc][] (on Debian and Ubuntu, this is provided by the [build-essential][] package).
9
+ You will need [re2][] installed as well as a C++ compiler such as [gcc][] (on Debian and Ubuntu, this is provided by the [build-essential][] package).
10
10
 
11
11
  If you are using a packaged Ruby distribution, make sure you also have the Ruby header files installed such as those provided by the [ruby-dev][] package on Debian and Ubuntu.
12
12
 
13
- You can then install the library via RubyGems: `gem install re2`
13
+ You can then install the library via RubyGems with `gem install re2` or `gem install re2 -- --with-re2-dir=/opt/local/re2` if re2 is not installed in the default location of `/usr/local/`.
14
14
 
15
15
  Usage
16
16
  -----
data/Rakefile CHANGED
@@ -7,7 +7,9 @@ rescue LoadError
7
7
  require 'rake/testtask'
8
8
  end
9
9
 
10
- Rake::ExtensionTask.new('re2')
10
+ Rake::ExtensionTask.new('re2') do |e|
11
+ # e.config_options << "--with-re2-dir=/opt/local/re2"
12
+ end
11
13
 
12
14
  Rake::TestTask.new do |t|
13
15
  t.test_files = FileList["test/*_test.rb"]
data/ext/re2/re2.cc CHANGED
@@ -33,6 +33,9 @@ extern "C" {
33
33
  void
34
34
  re2_free(re2_pattern* self)
35
35
  {
36
+ if (self->pattern) {
37
+ delete self->pattern;
38
+ }
36
39
  free(self);
37
40
  }
38
41
 
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: re2
3
3
  version: !ruby/object:Gem::Version
4
- hash: 29
4
+ hash: 27
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 1
10
- version: 0.0.1
9
+ - 2
10
+ version: 0.0.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Paul Mucur
@@ -15,11 +15,24 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-07-27 00:00:00 +01:00
18
+ date: 2010-07-28 00:00:00 +01:00
19
19
  default_executable:
20
- dependencies: []
21
-
22
- description:
20
+ dependencies:
21
+ - !ruby/object:Gem::Dependency
22
+ name: rake-compiler
23
+ prerelease: false
24
+ requirement: &id001 !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ hash: 3
30
+ segments:
31
+ - 0
32
+ version: "0"
33
+ type: :development
34
+ version_requirements: *id001
35
+ description: Ruby bindings to re2, "an efficient, principled regular expression library".
23
36
  email: ruby.re2@librelist.com
24
37
  executables: []
25
38
 
@@ -67,6 +80,6 @@ rubyforge_project:
67
80
  rubygems_version: 1.3.7
68
81
  signing_key:
69
82
  specification_version: 3
70
- summary: Ruby bindings to re2
83
+ summary: Ruby bindings to re2.
71
84
  test_files:
72
85
  - test/re2_test.rb