Hey,
I recently wrote a small plugin for rubygems that will use the MacRuby compiler
to compile *.rb files when you install a gem.
It is usable, but very simple right now; I would like to make it more powerful
in a few different ways and I'm not sure which would be good. Things I think I
could do (I have not looked at the rubygems source code in depth yet, so I'm
not sure what I am allowed to do using the proper API):
- A gemspec property (e.g. spec.compile_for_macruby = true)
- A gem command:
gem compile nokogiri
gem compile —remove-original-files nokogiri
• I can’t remove the original *.rb files and leave *.rbo files
by default because of how rubygems identifies gems (unless I modify gemspec
files)
- A gem install option
gem install —compile nokogiri
I’m not sure which is best, perhaps all of them will get implemented, but I was
wondering what the communities thoughts were about compiling gems; especially
since the gemspec option won't work if the community never uses it.
The repo is located at https://github.com/ferrous26/rubygems-compile
--
Mark Rada
[email protected]
_______________________________________________
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel