Top Level Namespace

Defined Under Namespace

Modules: AddMapWithIndex, CVFFI, Enumerable, Mkrf, Opencv Classes: Matrix, Vector

Instance Method Summary collapse

Instance Method Details

#coreObject

An omnibus file which brings in all the core/* sub-files



3
# File 'lib/opencv-ffi/core/point.rb', line 3

require 'core'

#old_setup_extensionObject



4
# File 'ext/mkrf-rakehelper-monkey.rb', line 4

alias :old_setup_extension :setup_extension

#rake(rakedir, args = nil) ⇒ Object



18
19
20
21
22
23
24
25
26
# File 'ext/mkrf-rakehelper-monkey.rb', line 18

def rake( rakedir, args = nil )
  Dir.chdir( rakedir ) do
    if args
      sh "rake #{args}"
    else
      sh 'rake'
    end
  end
end

#setup_extension(dir, extension) ⇒ Object



28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# File 'ext/mkrf-rakehelper-monkey.rb', line 28

def setup_extension(dir, extension)

  old_setup_extension( dir, extension )

  ext_dir = "ext/#{dir}"
  ext_so = "#{ext_dir}/#{extension}.#{Config::CONFIG['DLEXT']}"

  task ext_so => FileList["#{ext_dir}/**/*.c*", "#{ext_dir}/mkrf_conf.rb"]

  Mkrf::all_libs << extension.to_sym

  namespace extension.to_sym do

    desc "Run \"rake clean\" in #{ext_dir}"
    task :clean do
      rake ext_dir, 'clean'
    end

    desc "Run \"rake clobber\" in #{ext_dir}"
    task :clobber do
      rake extd_dir, 'clobber'
    end
  end

end