diff options
Diffstat (limited to 'lib/rubygems/ext/ext_conf_builder.rb')
-rw-r--r-- | lib/rubygems/ext/ext_conf_builder.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/rubygems/ext/ext_conf_builder.rb b/lib/rubygems/ext/ext_conf_builder.rb index f53661c733..5112eb8e2f 100644 --- a/lib/rubygems/ext/ext_conf_builder.rb +++ b/lib/rubygems/ext/ext_conf_builder.rb @@ -39,6 +39,7 @@ class Gem::Ext::ExtConfBuilder < Gem::Ext::Builder run cmd, results ENV["DESTDIR"] = nil + ENV["RUBYOPT"] = rubyopt siteconf.unlink make dest_path, results @@ -49,14 +50,14 @@ class Gem::Ext::ExtConfBuilder < Gem::Ext::Builder destent.exist? or File.rename(ent.path, destent.path) end end - - results ensure ENV["RUBYOPT"] = rubyopt ENV["DESTDIR"] = destdir end end - t.unlink if t + t.unlink if t and t.path + + results ensure FileUtils.rm_rf tmp_dest if tmp_dest end |