Navigation Menu

Skip to content

Commit

Permalink
Put the AOT compiler in the MacRuby namespace
Browse files Browse the repository at this point in the history
Also update code which called the Compiler
  • Loading branch information
ferrous26 committed Jun 2, 2011
1 parent d5d1e6f commit f7d6fa4
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion bin/ruby_deploy
Expand Up @@ -153,7 +153,7 @@ class Deployer
next if base == 'rb_main'
obj = File.join(File.dirname(source), base + '.rbo')
if !File.exist?(obj) or File.mtime(source) > File.mtime(obj)
instance = Compiler.new(bundle: true, output: obj, files: [source], archs: app_archs)
instance = MacRuby::Compiler.new(bundle: true, output: obj, files: [source], archs: app_archs)
begin
instance.run
rescue
Expand Down
6 changes: 3 additions & 3 deletions bin/rubyc
Expand Up @@ -24,7 +24,7 @@ require 'rbconfig'
# :bundle:: boolean indicating the output should be compiled, assembled, and
# linked as a loadable object file
# :dont_link:: boolean indicating if the output file should be linked
# :archs:: array of architectures to compile for; see Compiler::VALID_ARCHS
# :archs:: array of architectures to compile for; see MacRuby::Compiler::VALID_ARCHS
# :files:: array of files to compile
# :internal:: used internally by the MacRuby build system to set miniruby
# as the compiler
Expand All @@ -34,10 +34,10 @@ require 'rbconfig'
#
# becomes:
# load File.join(RbConfig::CONFIG['bindir'], 'macrubyc')
# instance = Compiler.new( bundle: true, output: 'program.rbo', files: ['program.rb'] )
# instance = MacRuby::Compiler.new( bundle: true, output: 'program.rbo', files: ['program.rb'] )
# instance.run

class Compiler
class MacRuby::Compiler
VALID_ARCHS = ['i386', 'x86_64']

# Misc.
Expand Down
8 changes: 4 additions & 4 deletions lib/rake/compiletask.rb
Expand Up @@ -63,10 +63,10 @@ def define
number_of_files += 1
end

Compiler.new(output: compiled_name,
bundle: true,
files: [source]
).run
MacRuby::Compiler.new(output: compiled_name,
bundle: true,
files: [source]
).run
end

if @verbose
Expand Down

0 comments on commit f7d6fa4

Please sign in to comment.