-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathRakefile
More file actions
36 lines (30 loc) · 681 Bytes
/
Rakefile
File metadata and controls
36 lines (30 loc) · 681 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
require 'rake'
require 'fileutils'
MRUBY_CONFIG_PATH = File.expand_path(ENV["MRUBY_CONFIG"] || "build_config.rb")
file :mruby do
unless File.directory?('mruby')
sh "git clone --depth=1 https://github.com/mruby/mruby.git"
end
end
desc "compile binary"
task :compile => :mruby do
Dir.chdir("mruby") do
ENV["MRUBY_CONFIG"] = MRUBY_CONFIG_PATH
sh "rake all"
end
end
desc "test"
task :test => :mruby do
Dir.chdir("mruby") do
ENV["MRUBY_CONFIG"] = MRUBY_CONFIG_PATH
sh "rake all test"
end
end
desc "cleanup"
task :clean do
Dir.chdir("mruby") do
ENV["MRUBY_CONFIG"] = MRUBY_CONFIG_PATH
sh "rake deep_clean"
end
end
task :default => :test