[ANN] rake-compiler 0.7.0 Released

L

Luis Lavena

rake-compiler version 0.7.0 has been released!

* <http://github.com/luislavena/rake-compiler>
* <http://rubyforge.org/projects/rake-compiler>

=3D rake-compiler

rake-compiler aims to help Gem developers deal with Ruby extensions, simpli=
fying
code and reducing duplication.

It followss *convention over configuration* and sets a standardized structu=
re to
build and package both C and Java extensions in your gems.

This is the result of experiences dealing with several Gems that required n=
ative
extensions across platforms and different user configurations where details=
like
portability and clarity of code were lacking.

=3D=3D An Overview

Let's summarize what rake-compiler provides:

* No custom rake tasks required. Less code duplication and errors.

* Painlessly build extensions on different platforms (Linux, OSX and Window=
s).

* Painlessly build extensions for different Ruby implementations (JRuby,
Rubinius and MRI).

* Allow multiple extensions be compiled inside the same gem.

* Mimics RubyGems installation process, so helps as a test environment.

* Simplify cross platform compilation of extensions (target Windows from Li=
nux).

Changes:

=3D=3D=3D 0.7.0 / 2009-12-08

* Enhancements
* Allow generation of JRuby extensions. Thanks to Alex Coles (myabc) for =
the
contribution.
This will allow, with proper JDK tools, cross compilation of JRuby gems
from MRI.

Rake::JavaExtensionTask.new('my_java_extension', GEM_SPEC) do |ext|
# most of ExtensionTask options can be used
# plus, java_compiling:
ext.java_compiling do |gem_spec|
gem_spec.post_install_message =3D "This is a native JRuby gem!"
end
end

Please note that cross-compiling JRuby gems requires either JRUBY_HOME =
or
JRUBY_PARENT_CLASSPATH environment variables being properly set.

* Allow alteration of the Gem Specification when cross compiling. Closes =
GH-3
This is useful to indicate a custom requirement message, like DLLs
installation or similar.

Rake::ExtensionTask.new('my_extension', GEM_SPEC) do |ext|
ext.cross_compile =3D true
# ...
ext.cross_compiling do |gem_spec|
gem_spec.post_install_message =3D "You've installed a binary
version of this gem"
end
end

* Bugfixes
* Detect GNU make independently of distribution based naming.
Thanks to flori for patches.
* Usage of #dup to duplicate gemspec instead of YAML dumping.
* No longer support Ruby older than 1.8.6
* No longer support RubyGems older than 1.3.5
* Force definition of binary directory and executables. Closes GH-11
* Workaround path with spaces issues using relative paths. Closes GH-6
* Removed gemspec, GitHub gems no more

* Known issues
* Usage of rake-compiler under projects with Jeweler requires some tweaks
Please read issue GH-73 for Jeweler:
http://github.com/technicalpickles/jeweler/issues#issue/73

For a workaround, look here:
http://gist.github.com/251663

--=20
Luis Lavena
AREA 17
-
Perfection in design is achieved not when there is nothing more to add,
but rather when there is nothing more to take away.
Antoine de Saint-Exup=E9ry
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,009
Latest member
GidgetGamb

Latest Threads

Top