[Scons-users] How to create multiple tasks/jobs from a single builder invocation
Matano, Rocco
Rocco.Matano at baslerweb.com
Wed May 14 02:46:28 EDT 2014
I have written a number of custom scons builders and I think I understand the basic concepts of those.
But now I am facing a task that I don't know how to solve. I would like to write a custom builder that takes
a list of source files and creates a single scons task / job for each source file, so that scons will work off
those tasks in parallel if '--jobs=N' was given on the command line.
When compiling C files like this
objs = env.Object(source=['file1.c', 'file2.c', 'file3.c', 'file4.c'])
that parallelism is achieved out of the box.
I would like to write a builder that also achieves that. I would like to be able to invoke that builder similarly:
targets = env.CustumBuilder(source=['file1.ext', 'file2.ext', 'file3.ext', 'file4.ext'])
So my question is:
What do I have to do when writing a custom builder in order to achieve that parallelism?
Regards,
Rocco
Rocco Matano
Senior Software Developer
Basler AG
An der Strusbek 60-62
22926 Ahrensburg
Germany
Tel. +49 4102 463 384
Fax +49 4102 463 46 384
Rocco.Matano at baslerweb.com
www.baslerweb.com
Vorstand: Dr.-Ing. Dietmar Ley (Vorsitzender) · John P. Jennings · Arndt Bake · Hardy Mehl
Aufsichtsratsvorsitzender: Norbert Basler
Basler AG · Amtsgericht Lübeck HRB 4090 · Ust-IdNr.: DE 135 098 121 · Steuer-Nr.: 30 292 04497 · WEEE-Reg.-Nr. DE 83888045
More information about the Scons-users
mailing list