[Scons-users] dynamic flow handling

Bill Deegan bill at baddogconsulting.com
Mon Sep 16 13:52:52 EDT 2019


Did you ever get a full comprehension of how SCons works from our
discussion on IRC?


On Mon, Sep 16, 2019 at 10:40 AM daggs <daggs at gmx.com> wrote:

> Greetings,
>
> I'm trying to build flow that given a tar file, it will unpack it, patch
> it prepare, compile and install.
> thing is, not all the tar files are the same, some are kbuild based, some
> configure, some are simple makefile and some are cmake.
> for kbuild I need to copy and exiting config and run make oldconfig. for
> configure, I need to run configure and maybe reconfigure some of the pre
> configure were changed.
> maybe the right way is to have a constant flow with targets for all
> possiblities and if a step isn't needed, than I can force the stage to be
> dummy
>
> Dagg.
>
> *Sent:* Monday, September 16, 2019 at 6:32 PM
> *From:* "Bill Deegan" <bill at baddogconsulting.com>
> *To:* "SCons users mailing list" <scons-users at scons.org>
> *Subject:* Re: [Scons-users] dynamic flow handling
> Once you add the dependencies to the tree you cannot modify it.
> (well at least the means to do so would be reaching way into the code and
> not supported or advised)
>
> You need to give us a concrete example of what you mean by "code that runs
> some form of detection"
>
> On Mon, Sep 16, 2019 at 4:39 AM daggs <daggs at gmx.com> wrote:
>
>> Greetings,
>>
>> I'm working on a scons based project that works as follows, there are 5
>> steps, a,b,c,d,e
>> each of them is a builder.
>> upon scons calling, I do the following:
>> target_a = env.Call_a(target_a, obj, ...)
>> target_b = env.Call_b(target_b, target_a, ...)
>> target_c = env.Call_c(target_c, target_b, ...)
>> target_d = env.Call_d(target_d, target_c, ...)
>> target_e = env.Call_e(target_e, target_d, ...)
>>
>> this results in the following tree:
>>   +-output
>>   | +-output/r
>>   |   +-output/r/build
>>   |   | +-output/r/build/src
>>   |   |   +-output/r/build/src/flow
>>   |   |     +-target_e
>>   |   |     | +-target_d
>>   |   |     |   +-target_c
>>   |   |     |     +-target_b
>>   |   |     |       +-target_a
>>   |   |     |         +-obj
>>
>> here is where it gets complicated, in Call_c, there is a code that runs
>> some form of detection and upon that, there might be a need to change the
>> flow a bit, for example, copy a file and the call Call_d with different
>> params.
>> e.g.:
>>   +-output
>>   | +-output/r
>>   |   +-output/r/build
>>   |   | +-output/r/build/src
>>   |   |   +-output/r/build/src/flow
>>   |   |     +-target_e
>>   |   |     | +-target_d
>>   |   |     |   +-target_c
>>   |   |     |     +-copy_file
>>   |   |     |       +-target_d
>>   |   |     |         +-target_b
>>   |   |     |           +-target_a
>>   |   |     |             +-obj
>>
>> or even, call another new builder named t.
>>
>> is there a way todo so?
>>
>> Thanks,
>>
>> Dagg.
>> _______________________________________________
>> Scons-users mailing list
>> Scons-users at scons.org
>> https://pairlist4.pair.net/mailman/listinfo/scons-users
>
> _______________________________________________ Scons-users mailing list
> Scons-users at scons.org
> https://pairlist4.pair.net/mailman/listinfo/scons-users
> _______________________________________________
> Scons-users mailing list
> Scons-users at scons.org
> https://pairlist4.pair.net/mailman/listinfo/scons-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist4.pair.net/pipermail/scons-users/attachments/20190916/c367bdc5/attachment.html>


More information about the Scons-users mailing list