Skip to content

Commit 0aeab4b

Browse files
author
Zachary Scott
committed
Prefer mruby_root over the constant defined in mruby's Rakefile
1 parent 0a6630e commit 0aeab4b

2 files changed

Lines changed: 7 additions & 7 deletions

File tree

Rakefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ load "#{mruby_root}/Rakefile"
1515

1616
desc "compile all the binaries"
1717
task :compile => [:mruby, :all] do
18-
%W(#{MRUBY_ROOT}/build/host/bin/#{APP_NAME} #{MRUBY_ROOT}/build/i686-pc-linux-gnu/#{APP_NAME}").each do |bin|
18+
%W(#{mruby_root}/build/host/bin/#{APP_NAME} #{mruby_root}/build/i686-pc-linux-gnu/#{APP_NAME}").each do |bin|
1919
sh "strip --strip-unneeded #{bin}" if File.exist?(bin)
2020
end
2121
end
@@ -25,8 +25,8 @@ namespace :test do
2525
# only build mtest for host
2626
task :mtest => [:compile] + MRuby.targets.values.map {|t| t.build_mrbtest_lib_only? ? nil : t.exefile("#{t.build_dir}/test/mrbtest") }.compact do
2727
# in order to get mruby/test/t/synatx.rb __FILE__ to pass,
28-
# we need to make sure the tests are built relative from MRUBY_ROOT
29-
load "#{MRUBY_ROOT}/test/mrbtest.rake"
28+
# we need to make sure the tests are built relative from mruby_root
29+
load "#{mruby_root}/test/mrbtest.rake"
3030
MRuby.each_target do |target|
3131
# only run unit tests here
3232
target.enable_bintest = false

mrblib/setup.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,7 @@ def rakefile
308308
309309
desc "compile binary"
310310
task :compile => [:mruby, :all] do
311-
%W(\#{MRUBY_ROOT}/build/host/bin/\#{APP_NAME} \#{MRUBY_ROOT}/build/i686-pc-linux-gnu/\#{APP_NAME}").each do |bin|
311+
%W(\#{mruby_root}/build/host/bin/\#{APP_NAME} \#{mruby_root}/build/i686-pc-linux-gnu/\#{APP_NAME}").each do |bin|
312312
sh "strip --strip-unneeded \#{bin}" if File.exist?(bin)
313313
end
314314
end
@@ -317,10 +317,10 @@ def rakefile
317317
desc "run mruby & unit tests"
318318
# only build mtest for host
319319
task :mtest => [:compile] + MRuby.targets.values.map {|t| t.build_mrbtest_lib_only? ? nil : t.exefile("\#{t.build_dir}/test/mrbtest") }.compact do
320-
# mruby-io tests expect to be in MRUBY_ROOT
320+
# mruby-io tests expect to be in mruby_root
321321
# in order to get mruby/test/t/synatx.rb __FILE__ to pass,
322-
# we need to make sure the tests are built relative from MRUBY_ROOT
323-
load "\#{MRUBY_ROOT}/test/mrbtest.rake"
322+
# we need to make sure the tests are built relative from mruby_root
323+
load "\#{mruby_root}/test/mrbtest.rake"
324324
MRuby.each_target do |target|
325325
# only run unit tests here
326326
target.enable_bintest = false

0 commit comments

Comments
 (0)