Skip to content
This repository has been archived by the owner on Dec 4, 2023. It is now read-only.

Commit

Permalink
Rake task to build binary gem for native platform
Browse files Browse the repository at this point in the history
  • Loading branch information
cowboyd committed Jun 14, 2012
1 parent 795b66a commit aeaad34
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Rakefile
Expand Up @@ -21,5 +21,12 @@ task :sanity => [:clean, :compile] do
sh %q{ruby -Ilib -e "require 'v8'"}
end

desc "Build therubyracer-#{V8::VERSION}-#{Gem::Platform.new(RUBY_PLATFORM)}.gem into the pkg directory"
task "build:native" => :build do
require "rubygems/compiler"
compiler = Gem::Compiler.new("pkg/therubyracer-#{V8::VERSION}.gem", File.expand_path('../pkg', __FILE__))
compiler.compile
end

task :default => :spec

1 change: 1 addition & 0 deletions therubyracer.gemspec
Expand Up @@ -20,5 +20,6 @@ Gem::Specification.new do |gem|

gem.add_development_dependency "rake"
gem.add_development_dependency "rake-compiler"
gem.add_development_dependency "gem-compiler"
gem.add_development_dependency "rspec", "~> 2.0"
end

0 comments on commit aeaad34

Please sign in to comment.