ropencv 0.0.9 → 0.0.10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/ext/helper.rb +9 -7
  2. data/manifest.xml +12 -0
  3. data/ropencv.gemspec +2 -2
  4. metadata +3 -2
@@ -55,7 +55,7 @@ def find_opencv
55
55
  # find opencv header path
56
56
  out = IO.popen("pkg-config --cflags-only-I opencv")
57
57
  paths = out.read.split("-I").delete_if(&:empty?).map do |i|
58
- i.gsub("\n","").gsub(" ","").gsub("opencv","")
58
+ i.gsub("\n","").gsub(" ","")
59
59
  end
60
60
  raise "Cannot find OpenCV" if paths.empty?
61
61
 
@@ -93,13 +93,15 @@ def find_opencv
93
93
 
94
94
  # check that all headers are available
95
95
  headers = headers.map do |i|
96
- path = File.join(paths[0],i)
97
- if !File.exist?(path)
98
- ::Rbind.log.info "OpenCV version does not support #{path}"
99
- nil
96
+ path = paths.find do |p|
97
+ p = File.join(p,i)
98
+ File.exist?(p)
99
+ end
100
+ if path
101
+ File.join(path,i)
100
102
  else
101
- path
102
- end
103
+ ::Rbind.log.info "OpenCV version does not support #{path}"
104
+ end
103
105
  end.compact
104
106
  Rbind.log.info "found opencv #{opencv_version}: #{paths[0]}"
105
107
  [opencv_version,headers]
@@ -0,0 +1,12 @@
1
+ <package>
2
+ <description brief="ruby bindings for opencv">
3
+
4
+ </description>
5
+ <author>Alexander Duda/Alexander.Duda@dfki.de</author>
6
+ <license></license>
7
+ <url>http://</url>
8
+ <logo>http://</logo>
9
+
10
+ <depend package="external/opencv" />
11
+ <depend package="tools/rbind" />
12
+ </package>
@@ -1,7 +1,7 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'ropencv'
3
- s.version = '0.0.9'
4
- s.date = '2013-08-13'
3
+ s.version = '0.0.10'
4
+ s.date = '2013-08-15'
5
5
  s.platform = Gem::Platform::RUBY
6
6
  s.authors = ['Alexander Duda']
7
7
  s.email = ['Alexander.Duda@dfki.de']
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: ropencv
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.9
5
+ version: 0.0.10
6
6
  platform: ruby
7
7
  authors:
8
8
  - Alexander Duda
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2013-08-13 00:00:00 Z
13
+ date: 2013-08-15 00:00:00 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rbind
@@ -66,6 +66,7 @@ files:
66
66
  - ext/src/rbind.pc.in
67
67
  - lib/ropencv.rb
68
68
  - lib/ropencv/ropencv_ruby.rb
69
+ - manifest.xml
69
70
  - ropencv.gemspec
70
71
  - test/suite.rb
71
72
  - test/test_mat.rb