[Scons-users] Get a list of emitted targets from the previous run

Erik Kazandjian erik.kazandjian at gmail.com
Wed Jun 16 03:38:31 EDT 2021


Hi Bill,

I would definitely like to have a chat with you on this but I have no idea
what you mean with 'the discord server'

Cheers

Erik

On Tue, 15 Jun 2021 at 23:33, Bill Deegan <bill at baddogconsulting.com> wrote:

> Erik,
>
> Here's what I'd do.
> It's a little hacky.
> In your emitter if the flag to parse is set to parse, add all the parsed
> info to your source node via source[0].attributes.pyang
> Then in your action (probably actionlist), add a python action to write
> that info to a file.
> Make sure you add that file name as a sideeffect when parsing.
>
> When the flag is set, you can read that file in in your emitter.
>
> I think that should work.
> If you want to interactively discuss, please hop on the discord server.
>
> Please consider contributing the tool to scons-contrib repo?
>
> Hope that helps.
> -Bill
>
>
>
> On Tue, Jun 15, 2021 at 1:04 PM Erik Kazandjian <erik.kazandjian at gmail.com>
> wrote:
>
>> Hi Bill
>>
>> I'm parsing in process using the pyang library. The reason for parsing in
>> the emitter phase is because other files include the generated headers. The
>> generated c++files are given as sources to the library builders.  That's is
>> why I do this in the emitter phase to declare all files that Will je
>> generated and get the dependency tree right
>>
>> Cheers
>>
>> Erik
>>
>> Op di 15 jun. 2021 18:26 schreef Bill Deegan <bill at baddogconsulting.com>:
>>
>>> Erik,
>>>
>>> Why are you parsing the file in the emitter phase?
>>> Also, please tell me that you're not doing your generation in process,
>>> but rather shelling out to a python (or other script) to generate..
>>>
>>> -Bill
>>>
>>> On Mon, Jun 14, 2021 at 11:56 PM Erik Kazandjian <
>>> erik.kazandjian at gmail.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> In our project we have added some custom builder (with emitters and
>>>> actions) to parse yang files and generate C++ out of that. As more and more
>>>> yang files are added and getting complexer I would like to have the
>>>> possibility (with a command line option) to by pass this yang parsing in
>>>> the emitter pagase. Of course if I woud just return [], source in my
>>>> emitter all my SConscripts would see the generated targewts as empty and
>>>> create empty libraries (which gives linker issues). So my question is,
>>>> suppose I have this command line option activated, is there a way to see
>>>> which targets were emitted in the previous build so I can return them
>>>> without having to do the yang analysis.
>>>>
>>>> Regards
>>>>
>>>> Erik
>>>> _______________________________________________
>>>> 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
>>
> _______________________________________________
> 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/20210616/7e20726f/attachment.htm>


More information about the Scons-users mailing list