Henrik Thostrup Jensen wrote:

Hi again :-)

2009/3/13 Henrik Thostrup Jensen <[email protected]>:
Hi

2009/3/13 Ittay Dror <[email protected]>:
Henrik Thostrup Jensen wrote:
When executing this task buildr will start to compile the code, but
will get the dependencies wrong, compiling the module in incorrect
order, causing a build failure. When the task is re-run the order is

can you specify what the wrong and right orders are? what are the errors you
see?
The sgas:xmldb module gets build before sgas:iterator, even though the
xmldb modules
specifies iterator under compile.with. Line 261

Okay, I've tracked down the problem to some files not getting copied
resulting in no java src directory (we generate the stubs one place,
copy them to java src dir and the copy our own on top). However I need
to specify a task dependency in a project. I tried doing a naive

desc 'xmldb' => :code_copy do... but that didn't work. How do I do this?
it's hard to reply because the url you gave for the buildfile is not responding.

according to the snippet above, you're trying to create a dependency through 'desc', which is just defining the description of a task.

using 'define' instead is not good either. since it means code_copy will be done before the project is defined.

what you want is to create a dependency from compile. something like:
define 'xmldb'
  compile.enhance([:code_copy])
  ...
end

also note that the compile task can accept multiple source directories (normally it works from [:source, :main, :java]), so instead of copying to the main source directory you can write: compile(<path to generated sources>) (you can use path_to or _ for project relative paths. ).

ittay


--
Tikal <http://www.tikalk.com>
Tikal Project <http://tikal.sourceforge.net>

Reply via email to