Modified: MacRuby/trunk/bin/ruby_deploy (2928 => 2929)
--- MacRuby/trunk/bin/ruby_deploy 2009-10-30 06:50:54 UTC (rev 2928)
+++ MacRuby/trunk/bin/ruby_deploy 2009-10-30 19:05:50 UTC (rev 2929)
@@ -69,6 +69,14 @@
dirs << 'lib/ruby/Gems' # TODO add gems support
dirs.each { |x| rm_rf(File.join(app_macruby_usr, x)) }
+ # Only keep the Current version of the MacRuby.framework copy.
+ Dir.glob(File.join(app_macruby, 'Versions/*')).select { |x|
+ base = File.basename(x)
+ base != MACRUBY_VERSION and base != 'Current'
+ }.each { |x|
+ rm_rf(x)
+ }
+
# Hack the application binaries to link against the MacRuby.framework copy.
patterns = [File.join(@app_bundle, 'Contents/MacOS/*'), File.join(app_macruby_usr, 'lib/ruby/**/*.{bundle,rbo}')]
patterns.each do |pat|