Skip to content

Commit

Permalink
fix building ruby-build rubies
Browse files Browse the repository at this point in the history
  • Loading branch information
hone committed Dec 19, 2012
1 parent 1749a0f commit b2cd9df
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Rakefile
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ def install_gem(gem, version)
end end


def build_ruby_command(name, output, prefix, usr_dir, tmpdir, rubygems = nil) def build_ruby_command(name, output, prefix, usr_dir, tmpdir, rubygems = nil)
vulcan_prefix = "/app/vendor/#{output}"
build_command = [ build_command = [
# need to move libyaml/libffi to dirs we can see # need to move libyaml/libffi to dirs we can see
"mv #{usr_dir} /tmp", "mv #{usr_dir} /tmp",
Expand All @@ -65,7 +66,7 @@ def build_ruby_command(name, output, prefix, usr_dir, tmpdir, rubygems = nil)
build_command << "mv #{prefix} /app/vendor/#{output}" if prefix != "/app/vendor/#{output}" build_command << "mv #{prefix} /app/vendor/#{output}" if prefix != "/app/vendor/#{output}"
build_command = build_command.join(" && ") build_command = build_command.join(" && ")


sh "vulcan build -v -o #{output}.tgz --prefix #{prefix} --source #{name} --command=\"#{build_command}\"" sh "vulcan build -v -o #{output}.tgz --prefix #{vulcan_prefix} --source #{name} --command=\"#{build_command}\""
s3_upload(tmpdir, output) s3_upload(tmpdir, output)
end end


Expand Down Expand Up @@ -178,7 +179,7 @@ task "ruby:install", :version do |t, args|
# build ruby # build ruby
if major_ruby == "1.8" if major_ruby == "1.8"
output = "ruby-build-#{version}" output = "ruby-build-#{version}"
prefix = "/app/vendor/ruby-build-#{version}" prefix = "/tmp/ruby-#{version}"
build_ruby_command(full_name, output, prefix, usr_dir, tmpdir, rubygems) build_ruby_command(full_name, output, prefix, usr_dir, tmpdir, rubygems)
end end
end end
Expand Down

0 comments on commit b2cd9df

Please sign in to comment.