mirror of
https://github.com/ruby-opencv/ruby-opencv
synced 2023-03-27 23:22:12 -04:00
change library file path to load
This commit is contained in:
parent
d75ae5a19c
commit
ba32cc36ba
1 changed files with 1 additions and 2 deletions
|
@ -2,9 +2,8 @@ require (File.dirname(__FILE__) + '/opencv/version')
|
|||
|
||||
if RUBY_PLATFORM =~ /mingw|mswin/
|
||||
major, minor, subminor = RUBY_VERSION.split('.')
|
||||
version_dir = (major.to_i >= 2) ? '2.0' : '1.9'
|
||||
begin
|
||||
require "#{version_dir}/opencv.so"
|
||||
require "#{major}.#{minor}/opencv.so"
|
||||
rescue LoadError
|
||||
require 'opencv.so'
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue