[Rake-devel] Building native extensions with Rake

Luis Lavena luislavena at gmail.com
Tue Nov 18 12:52:03 EST 2008


Hello everybody,

I'm working on a series of tasks that ease the compilation of Ruby C
Extensions with Rake. The goal of these tasks are ease the building
and compilation of Ruby C extensions, also looking into be
merged/integrated into Rake.

http://github.com/luislavena/rake-compiler/tree/master

Until now, every gem developer generates and implements the building
in the way they like, some of them hardcode information about the
tools and their environments which proven to be problematic for other
developers, both *nix or Windows side.

Since generation of gems has been bundled with Rake for quite some
time, I believe that adding tasks for building extensions to Rake will
be something all rubysts will appreciate.

At this time I'm working on the "native" task that will hook with
"gem" one allowing the developers package their platform gems.

The idea is be able to extend :gem and :package tasks without
requiring the developer define additional instructions in their
Rakefile.

However, I spotted two issues:

* Is not possible "extend" package_files property of GemPackageTask to
hook at runtime the needed changes.
* Task arguments get overwritten across tasks.

First one can be workaround with some hacks, which I'll push to my
repo later today.

The second one I exposed previously and I'll love some feedback if
this is intentional or undesired side-effect (ala: bug).

http://rubyforge.org/pipermail/rake-devel/2008-November/000649.html

Jim: would you bless this work to be included into Rake itself? Right
now is been driven by features (Cucumber) and specs, but I could
change that and add TU if is a requirement.

Thanks in advance for your time.
-- 
Luis Lavena
AREA 17
-
Human beings, who are almost unique in having the ability to learn from
the experience of others, are also remarkable for their apparent
disinclination to do so.
Douglas Adams


More information about the Rake-devel mailing list