Sha256: 15b4035f0bebff2efddf68166ab3a63cb03a78b79cdc4739ce245fd9a0e57d8a

Contents?: true

Size: 1.09 KB

Versions: 20

Compression:

Stored size: 1.09 KB

Contents

require "bundler/gem_tasks"
require "rake/testtask"

Rake::TestTask.new(:test) do |t|
  t.libs << "test"
  t.libs << "lib"
  t.test_files = FileList["test/**/*_test.rb"]
end

task :compile do
  sh 'cd ext/cumo && ruby extconf.rb && make && make build-ctest'
end

task :ctest do
  sh 'cd ext/cumo && ruby extconf.rb && make run-ctest'
end

task :clean do
  sh 'cd ext/cumo && make clean'
end

task :docs do
  dir = "ext/cumo"
  srcs = %w[array.c data.c index.c math.c narray.c rand.c struct.c].map{|s| File.join(dir, "narray", s)}
  srcs += %w[cublas.c driver.c nvrtc.c runtime.c memory_pool.cpp].map{|s| File.join(dir, "cuda", s) }
  srcs << File.join(dir, "narray", "types/*.c")
  srcs << "lib/cumo/narray/extra.rb"
  sh "cd ext/cumo; ruby extconf.rb; make src"
  sh "rm -rf docs .yardoc; yard doc -o docs -m markdown -r README.md #{srcs.join(' ')}"
end
task :doc => :docs

task :gdb do
  sh "gdb -x run.gdb --args ruby -I. ./test.rb"
end

task :default => [:clobber, :compile, :test]

desc 'Open an irb session preloaded with the gem library'
task :console do
  sh 'irb -rubygems -I lib'
end
task :c => :console

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
cumo-0.4.3 Rakefile
cumo-0.4.2 Rakefile
cumo-0.4.1 Rakefile
cumo-0.4.0 Rakefile
cumo-0.3.5 Rakefile
cumo-0.3.4 Rakefile
cumo-0.3.3 Rakefile
cumo-0.3.2 Rakefile
cumo-0.3.1 Rakefile
cumo-0.3.0 Rakefile
cumo-0.3.0.pre1 Rakefile
cumo-0.2.5 Rakefile
cumo-0.2.4 Rakefile
cumo-0.2.3 Rakefile
cumo-0.2.2 Rakefile
cumo-0.2.1 Rakefile
cumo-0.2.0 Rakefile
cumo-0.1.2 Rakefile
cumo-0.1.1 Rakefile
cumo-0.1.0 Rakefile