[Rake-devel] How to execute before the '.o' => '.f90' tasks?
Andrew Chen
meihome at gmail.com
Tue Jan 8 11:32:54 EST 2008
Hi,
First time to the list. Thanks for your good work.
I'm trying to use Rake to compile some FORTRAN and C codes.
I have a task:
rule '.o' => '.f90' do |t|
sh "#{$compiler} -c -o #{t.name} #{t.source} -module #{$build_dir}"
end
But I have another task: generate_code, this task will make some more
.f90 source files.
I want to my generate code task to be executed before my rule '.o'
Rake::Task[:gen].invoke if Rake::Task.task_defined?('gen')
How to do that?
Thanks
~Andrew Chen
More information about the Rake-devel
mailing list