summaryrefslogtreecommitdiffhomepage
path: root/Rakefile
diff options
context:
space:
mode:
Diffstat (limited to 'Rakefile')
-rw-r--r--Rakefile20
1 files changed, 12 insertions, 8 deletions
diff --git a/Rakefile b/Rakefile
index 52b4c75c1..9a0a69ec6 100644
--- a/Rakefile
+++ b/Rakefile
@@ -52,15 +52,19 @@ task :default => :all
bin_path = ENV['INSTALL_DIR'] || "#{MRUBY_ROOT}/bin"
-depfiles = MRuby.targets['host'].bins.map do |bin|
- install_path = MRuby.targets['host'].exefile("#{bin_path}/#{bin}")
- source_path = MRuby.targets['host'].exefile("#{MRuby.targets['host'].build_dir}/bin/#{bin}")
-
- file install_path => source_path do |t|
- install_D t.prerequisites.first, t.name
+if MRuby.targets['host']
+ target = MRuby.targets['host']
+ depfiles = target.bins.map do |bin|
+ install_path = target.exefile("#{bin_path}/#{bin}")
+ source_path = target.exefile("#{target.build_dir}/bin/#{bin}")
+
+ file install_path => source_path do |t|
+ install_D t.prerequisites.first, t.name
+ end
+ install_path
end
-
- install_path
+else
+ depfiles = []
end
MRuby.each_target do |target|