Permalink
Browse files

Move run_ruby, compile_ruby to main Rakefile and set RBX_RUNTIME

  • Loading branch information...
1 parent 524404c commit c5b5a97390312dcee95594989ad664eb362f702d @drbrain drbrain committed Aug 28, 2008
Showing with 27 additions and 26 deletions.
  1. +27 −0 Rakefile
  2. +0 −26 rakelib/kernel.rake
View
@@ -16,6 +16,33 @@ RUBINIUS_BASE = File.expand_path(File.dirname(__FILE__))
task :default => %w[build vm:test]
+desc "Compile the given ruby file into a .rbc file"
+task :compile_ruby, :file do |task, args|
+ file = args[:file]
+ raise ArgumentError, 'compile_ruby requires a file name' if file.nil?
+
+ rbc = file + 'c'
+
+ compile_ruby file, rbc
+end
+task :compile_ruby => 'kernel:build' # HACK argument + dependency is broken
+
+desc "Run the given ruby fil ewith the vm"
+task :run_ruby, :file do |task, args|
+ file = args[:file]
+ raise ArgumentError, 'compile_ruby requires a file name' if file.nil?
+
+ rbc = file + 'c'
+
+ compile_ruby file, rbc
+
+ ENV['PROBE'] = 'yes' if $verbose
+ ENV['RBX_RUNTIME'] = File.join File.dirname(__FILE__), 'runtime'
+
+ sh 'vm/vm', rbc
+end
+task :run_ruby => 'kernel:build' # HACK argument + dependency is broken
+
# BUILD TASKS
# task :stable_compiler do
View
@@ -189,29 +189,3 @@ namespace :kernel do
end
-desc "Compile the given ruby file into a .rbc file"
-task :compile_ruby, :file do |task, args|
- file = args[:file]
- raise ArgumentError, 'compile_ruby requires a file name' if file.nil?
-
- rbc = file + 'c'
-
- compile_ruby file, rbc
-end
-task :compile_ruby => 'kernel:build' # HACK argument + dependency is broken
-
-desc "Run the given ruby fil ewith the vm"
-task :run_ruby, :file do |task, args|
- file = args[:file]
- raise ArgumentError, 'compile_ruby requires a file name' if file.nil?
-
- rbc = file + 'c'
-
- compile_ruby file, rbc
-
- ENV['PROBE'] = 'yes' if $verbose
-
- sh 'vm/vm', rbc
-end
-task :run_ruby => 'kernel:build' # HACK argument + dependency is broken
-

0 comments on commit c5b5a97

Please sign in to comment.