[Scons-users] use of abspath

Mats Wichmann mats at wichmann.us
Fri Aug 11 14:34:19 EDT 2017


On 08/11/2017 12:01 PM, Bill Deegan wrote:
> is FOO_SRC going to end up in a list of sources for a builder?

yes.

> If so,
> 
> src_files = [ File(s) for s in list_of_local_src_files]  # where entries in
> list are like 'blah.c'
> Should suffice.

well, the first step is sort of like that, so in foo/bar/src we may see

    ca_common_src = [
        'caconnectivitymanager.c',
        'cainterfacecontroller.c',
        'camessagehandler.c',
        'canetworkconfigurator.c',
        'caprotocolmessage.c',
        'caqueueingthread.c',
        'caretransmission.c',
    ]

    connectivity_env.AppendUnique(CA_SRC=ca_common_src)

but then based on options, that script may go on and invoke a script a
further level down, which does the dance I mentioned.  I know it's
trying to stuff the subdir name in with those files - because the
builder is eventually invoked at the higher level - without hardcoding it.


More information about the Scons-users mailing list