[rspec-devel] Building Cucumber for Java on Windows

Luis Lavena luislavena at gmail.com
Mon May 18 08:26:48 EDT 2009

2009/5/18 Trond Marius Øvstetun <trond at ovstetun.no>:
> Hi.
> I am having problems running the rake tasks for Cucumber for Java on
> Windows.
> When I run "jruby -S rake gem" in Cygwin I get the following stack:

The first thing is that you're running JRuby inside Cygwin. all batch
file calls will be intercepted by cygwin and not by the OS, thus

> [...]
> mvn clean package
> /usr/bin/sh: call: command not found
> rake aborted!

"call" is an internal command of Windows interpreter, that should have
work on a plain console.
> When I run in the regular cmd-shell:
> C:\Users\ovstetun\Mesan\fagArbeid\cucumber_java\cucumber-java>jruby -S rake
> gem --trace
> (in C:/Users/ovstetun/Mesan/fagArbeid/cucumber_java/cucumber-java)
> [...]
> Are these known problems? Anything to fix?
> So far I have changed the rake-tasks the following:
> task :jar do
>   # sh 'mvn clean package'
>   mv "target/cucumber-java-#{Cucumber::Java::VERSION::STRING}.jar", 'lib'
> end
> Then things work as long as I remember to run mvn package between each
> execution of rake gem..
> Any tips to making this work?

Can you upgrade to rake 0.8.7? There are known problems of
Kernel::system() on Windows that got fixed several versions after
0.8.4. Also, latest 0.8.7 fixed issues when calling shell commands
form JRuby.

gem update rake

Luis Lavena
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éry

More information about the rspec-devel mailing list